Repository navigation
Split Claude Code transcripts only at their newlines - #3719
Merged
Merged
Conversation
Composing a vocabulary now writes $tones and $languages into the enum of each attribute marked x-tone or x-language (stamp_words), so the entry an agent reads lists the words. Validation reads that enum through the attribute schema, replacing the separate DECLARED_WORDS pass and its unknown-word finding, and `page instructions --use` lists any attribute's enum from the schema, replacing #3690's listing. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…gistry A page vendored before the declared words moved into each attribute's enum carries a registry without them, and would pass an unknown tone or language. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
Claude Code writes U+2028 and U+2029 raw inside JSON strings, and splitlines() broke a transcript line at them, failing the journey with an unterminated string. Both transcript readers now share reply_phases.transcript_records, which splits at newlines alone. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
leaf-agent
approved these changes
Oct 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Claude Code journey's transcript reads still failed with
JSONDecodeError: Unterminated string, after #3700. The cause was not a half-written last line, as #3700 assumed. Claude Code writes U+2028 and U+2029 raw inside JSON strings, which JSON allows, and both readers split the transcript withsplitlines(), which breaks a line at those characters. A transcript kept from a failed run held one U+2028 and one U+2029: 113 newlines, but 115 lines tosplitlines().Both readers now share
reply_phases.transcript_records:journey_claude_code.native_recordsreads the journey's session.claude_code_transcriptreads a session forleaf-dev response-times.It splits only at the newline Claude Code writes after each record, and keeps #3700's rule of leaving out a record still being written. The transcript test now holds a raw U+2028 inside a string. It fails without the fix and passes with it.
This follows up #3700, the transcript-read fix from Max's decision #46 on the overnight report.
leaf.event_log.jsonl_linealready escapes these characters in the page log for the same reason.