claude-p transport: tolerant parsing, jsonrepair fallback, corrective retry
Stage 12 invalidated both Claude-5 lanes with content-shaped JSON failures: unescaped quotes/newlines inside TOOL_CALLS string values when tool inputs embed legal text. Three layers: protocol now demands strict escaped JSON; parseReply tolerates fences/preamble/same-line markers and falls back to jsonrepair (safe - the deterministic verbatim gate re-verifies every quoted span, so a mutating repair fails typed rather than passing falsely); retries feed the parse error back as a corrective turn instead of resending an identical payload. Usage now accumulates on failed parses too. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012AgUm5EcRKbT3duVFMbrQD
| Repository | eliziff/Beaver |
|---|---|
| Author | Eli Ziff <eliasziff@gmail.com> |
| Authored | |
| Parents | 151a68e7 |
| Stats | 4 files changed , +183 , -23 |
| Part of | claude-p transport: alternative LLM backend via the Claude CLI |
Capture this commit into my fork
Download a Markdown prompt that tells Claude how to port this
exact commit into your working tree. Run it via
claude -p < capture-commit-b7584a05.md
from inside the repo you want the change in.