checkpoint: drop stale compact on OPF regeneration failure; document 50MB cap

main

Commit

Soph2mo ago

Address PR review (Copilot #3) and the trail finding.

OPF stale compact (#3): in replaceTranscript, when compact regeneration yields nothing (failure, empty, or oversized), drop the prior transcript.jsonl and clear CompactTranscriptStart instead of leaving a stale, less-redacted compact on the branch with a marker pointing at content that no longer matches the re-redacted full.jsonl. setCompactTranscriptStart now takes *int so it can clear the marker. Regression test added.

Oversized-drop (#1 / trail finding): document the known limitation — the compact transcript is not chunked, so output exceeding the 50MB blob cap is skipped and a very long session may lack transcript.jsonl on some checkpoints; full.jsonl stays authoritative and the compact is regenerable. Updated the architecture doc (also correcting the now-stale "finalization keeps the previous transcript.jsonl" clause) and CLAUDE.md.

Co-Authored-By: Claude Opus 4.8 (1M context) noreply@anthropic.com Entire-Checkpoint: bd7061c21a95

Checkpoints

Compact Transcript Storage and Boundary Markers

Claude CodeOpus 4.8[1m]
View session
Checkpoint 1