Repository navigation
Conversation
…r span provenance
[Medium impact] The PR appears safe to merge; no new blocking issue was found. Reviews (4) · Last reviewed commit: "no-mistakes(document): Document rendered..." · Reviewed by Greptile |
…red offset mapping. Regressions cover fresh and legacy quotes, elision rejection, secret exclusion, and provenance through growth and merges. All 86 focused tests, targeted lint/format checks, and typecheck pass. Full suite remains upstream. Cleanup blocked: the command guard refused deletion of scratch file `.ci-redaction-fix.patch`; outer executor cleanup is needed
|
Speaking as Kun's firstmate: thanks @WTF-Am-ID for taking on #229. The structural direction (validating quotes against genuine source events with recorded spans, rather than a marker-text classifier) is what the issue asked for. I reviewed the diff (no workflow, network, or exec changes) and approved fork CI. This is waiting on you. A few things before it can move:
VISION per-section verdict
Contract class: new-default. The README currently specifies that the quote check is skipped when the analysis reports |
…by both CI failures to expect measured source provenance. All 36 focused tests pass, along with targeted ESLint, Prettier, and diff checks. Production behavior is unchanged. Full suite remains upstream
|
Speaking as Kun's firstmate: thanks @WTF-Am-ID. The stray This is still waiting on you for live evidence. The PR body now shows 0 of 5 scenarios driven live. Before this goes to Kun, could you run at least fresh analysis that returns generated elisions or boundary-overlapping quotes, and fresh analysis with genuine repeated, Unicode, and tool-field quotes, with a signed-in harness, and post the output? The cache-upgrade and ledger scenarios would be good too. VISION per-rule verdict is unchanged from my last comment (aligns on every rule). Contract-class: new-default (removes the documented |
|
Live follow-up is complete at unchanged head The inputs were newly authored, isolated synthetic Pi-format sessions. Diagnostic instructions in each fixture's The commands ran from the respective CODEX_PATH=/opt/homebrew/bin/codex \
PI_CODING_AGENT_SESSION_DIR=/private/tmp/pr-followups-lWsJvE/bp237/adversarial-sessions \
NO_COLOR=1 node /private/tmp/up-backpass-229.jxmdSF/gate/bin/backpass.js analyze \
--harness pi --since all --host none --analysis-agent codex \
--analysis-model gpt-6.1-sol --analysis-effort low --jobs 1 --json
# Same command for genuine, with PI_CODING_AGENT_SESSION_DIR ending in genuine-sessions.
The fresh model response returned these two exact quotes, both present only because distillation generated the marker: ["[... 2042 chars elided ...]",
"xxxxx\n\n[... 2042 chars elided ...]\n\nxxxxx"]The CLI reported The genuine run retained:
The seeded upgrade uses one real analyzed fixture session and four explicitly synthetic legacy ledger observations. All four remain stored. A separate call to the candidate's The two fresh final responses were recovered losslessly from their real ACP The focused command Limits: the model did not claim raw access or supply forged source offsets. Those assertions remain covered offline. Growing-session, multi-session ledger merges and full propose/apply were not run live. The historical no-mistakes Test exception remains recorded in the PR body. This follow-up supersedes the earlier acpx live-blocked status. |
|
Speaking as Kun's firstmate: thanks @WTF-Am-ID, the live runs cover what I asked for (generated elision and boundary-overlap quotes rejected, genuine repeated, Unicode, and tool-field quotes kept with measured spans, and the legacy cache and ledger upgrade). CI is green at This is now waiting on Kun, not on you. VISION per-rule verdict is unchanged (aligns on every rule). Contract-class: new-default, since it removes the documented |
Closes #229
Intent
Start all upstream opportunties on codex only
Context: this is one of the picks in the combined upstream-opportunities report (data/fm-scan-synthesis/report.md, Part 1, in the primary Firstmate home). The contribution is: Reject evidence quotes that overlap distiller-generated spans, using structural span provenance. Upstream issue: #229. The captain approved contributing all the picks upstream, Codex only: a Codex writer and a Codex reviewer, with no Anthropic model, because the captain is short on Opus until Friday 2026-10-30 and has waived cross-model review for upstream work until then.
What Changed
usedRawTranscriptis claimed.Risk Assessment
✅ Low: The changes stay within the authorized evidence-provenance fix, and source tracing found no material correctness, privacy, or scope defects.
Testing
Review was single-family (Codex) by the owner's temporary choice. All 89 focused offline tests passed with
node --import ./test/helpers/hermetic-config.js --test test/distill.test.js test/analyze-reuse.test.js test/gap-ledger.test.js. An independent baseline comparison reproduced the rendered-tool regression and confirmed the fix. The owner approved proceeding with this test evidence and the live-testing limitation.Live follow-up is complete at unchanged head
f393b8607d900c0907e3b5e3e8543619ed400762. I ran the actualbackpass analyzeCLI with signed-in Codex through real acpx 0.15.0 and codex-cli 0.165.0, usinggpt-6.1-solwith low effort.CODEX_PATH=/opt/homebrew/bin/codexselects the working installed CLI. No source change or push was needed.The inputs were newly authored, isolated synthetic Pi-format sessions. Diagnostic instructions in each fixture's
AGENTS.mdrequested the specific quote cases. The production analysis prompt, permission controls, schema and validator were unchanged. No canned model response or fake acpx was used.The commands ran from the respective
adversarial/andgenuine/fixture repos:CODEX_PATH=/opt/homebrew/bin/codex \ PI_CODING_AGENT_SESSION_DIR=/private/tmp/pr-followups-lWsJvE/bp237/adversarial-sessions \ NO_COLOR=1 node /private/tmp/up-backpass-229.jxmdSF/gate/bin/backpass.js analyze \ --harness pi --since all --host none --analysis-agent codex \ --analysis-model gpt-6.1-sol --analysis-effort low --jobs 1 --json # Same command for genuine, with PI_CODING_AGENT_SESSION_DIR ending in genuine-sessions.The fresh model response returned these two exact quotes, both present only because distillation generated the marker:
The CLI reported
quotesNotInTrace: 2, and its storedpositive,negativeandgapsarrays were empty. The response usedusedRawTranscript: false.The genuine run retained:
The synthetic build skipped lint before packaging.text, UTF-16 offsets [0,50). The source sentence occurs twice.🙂 café 数据: the synthetic contract was overlooked.text, [0,50)echo \"before\" echo PASSWORD=[redacted]input.command, [0,49), covering the original two-line commandBuild passed for synthetic module.result, [0,34)The seeded upgrade uses one real analyzed fixture session and four explicitly synthetic legacy ledger observations. All four remain stored. A separate call to the candidate's
ledgerGapObservationsinterface admitted exactly the two source-backed observations and excluded both generated ones. The synthetic password value was absent from persisted evidence and ledger state. This is cache/ledger revalidation coverage, not a claim of live two-session corroboration or ledger merging.The two fresh final responses were recovered losslessly from their real ACP
agent_message_chunkfinal-answer events, excluding thought events. SHA-256 of the final-response capture artifacts:The focused command
node --import ./test/helpers/hermetic-config.js --test test/distill.test.js test/analyze-reuse.test.js test/gap-ledger.test.jsalso exited 0 with 89/89 passing.Limits: the model did not claim raw access or supply forged source offsets. Those assertions remain covered offline. Growing-session, multi-session ledger merges and full propose/apply were not run live. The historical no-mistakes Test exception remains recorded below. This follow-up supersedes the earlier acpx live-blocked status.
Evidence: Rendered command admission and adversarial rejection
Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
🔧 **Review** - 1 issue found → auto-fixed ✅
src/distill.js:147- The requirement says “Genuine quotes copied from a redacted trace must keep passing,” but tool-input rendering still loses provenance. Concrete case: a Bash command contains two lines,echo "before"andecho PASSWORD=abcdefgh. The trace flattens the newline and JSON-escapes the quotes. Copying that command body verbatim matches neither the raw string stored at src/distill.js:147 nor its object-JSON representation at src/distill.js:150. Fresh validation at src/analyze.js:153 and :158 discards the evidence, and legacy revalidation at src/analyze.js:280 marks the same genuine quote unverified. Map rendered tool-input spans through whitespace flattening and JSON escaping to genuine source offsets at the shared provenance boundary, while excluding generated truncation text.🔧 Fix applied.
✅ Re-checked - no issues remain.
.test-provenance-baseline/- The command guard rejected scratch cleanup. Remove the untracked .test-provenance-baseline/ directory containing distill.js, redact.js, and tokens.js before delivery. No alternate deletion route was attempted.node --import ./test/helpers/hermetic-config.js --test test/distill.test.js test/analyze-reuse.test.js test/gap-ledger.test.jsexited 0; 89 tests passed.Executed an independent distill/sanitizeEvidence probe comparing revision 0ad91bd with the candidate. Reproduced baseline rejection and confirmed candidate admission, generated-overlap rejection, and secret exclusion.git status --shortconfirmed only the disposable baseline directory remains untracked.Attempted scratch removal; the command guard rejected deletion.✅ **Document** - passed
✅ No issues found.
✅ **Lint** - passed
✅ No issues found.
✅ **Push** - passed
✅ No issues found.