feat(review): inject authoritative scope + diff into reviewer and judge prompts

Commit

peyton-alt2mo ago

The parent computes the review scope (commits, files, uncommitted, diff) for its banner, then discards it and tells each child agent only how to re-derive it. That cost minutes of setup per reviewer and let one agent diff a behind-main branch in the wrong direction, reporting mainline evolution as branch regressions — two of four high findings in a real run were such phantoms, and the judge consolidated them unchecked.

ComposeReviewPrompt now renders a parent-computed ScopeContext: commit list (oldest first), three-dot name-status file list, porcelain uncommitted lines, and the diff itself when it fits a 48KiB inline budget (beyond that, the exact three-dot command). The judge prompt gets the authoritative changed-file list with an instruction to discard findings outside it. Lists are capped with truncation flags so agents never mistake a bounded enumeration for an exhaustive one.

Co-Authored-By: Claude Fable 5 noreply@anthropic.com Entire-Checkpoint: ca5fa66e3b98

Checkpoints

# Handoff To Claude: `entire review` Redo

Claude Code
View session
Checkpoint 1