Repository navigation
Description
Observable failure
In the aforge-as-worker trial (bench/worker-trial/REPORT.md, branch trial/aforge-as-worker @ 89786a4d, section "2026-09-03 · #515"), run 2 was handed a steering prompt that named four faults, numbered, each with its file and line. The run fixed three, never touched the fourth, and its closing words say nothing about which is which.
The four, as the prompt spelled them (command_requested, seq 2):
| # | The item | What the run did |
|---|---|---|
| 1 | "YOU BROKE AN EXISTING TEST AND DID NOT NOTICE … One repair must leave one journal entry." | fixed — the note(ctx, Repair{… Kind: RepairReasked …}) call moved inside the branch's success path |
| 2 | "mergeQuote HARDCODES THE FIELD NAME … take the field from there rather than writing a literal string into the merge." |
fixed — func mergeQuote(original, quote, fieldName string), raw[fieldName] = … |
| 3 | "THE BRANCH FIRES FOR THE WRONG ANSWERS … Decide the branch on WHICH RULE FAILED, read from the refusal" | fixed — the gate became if field := findQuotationField(joined, why(refused)); field != "" |
| 4 | "THE PROSE RE-ASK NOW TELLS THE MODEL A WORD THAT MEANS NOTHING. prose.go:115 … Either name the actual broken rule there, or take the sentence out" |
not done, and not mentioned |
All three fixes are in one edit call, and its path is internal/shaped/shaped.go. It is the only edit in the run. prose.go was read at turn 4 and never written. The one and only trace of item 4 anywhere in the run's output is an assistant sentence at turn 12 — an intention, not a report:
Let me now add the
findQuotationFieldfunction and fix Fault 4 inprose.go
Three turns later the run died. What the person was handed, in full (node_failed, seq 79):
context deadline exceeded
node task-2: context deadline exceeded
Files it left behind:
/home/santosh/af-trial-515/internal/shaped/shaped.go
Four items in, one file out, and no line saying that three were answered and one was not — so the next hand-off had to rediscover it by reading the tree, and the trial's run-3 prompt carries it again as "FAULT B — STILL UNFIXED".
The leaf's own runtime contract had asked for exactly that line and did not get it:
The final deliverable is a written message containing the test output, build result, a summary of the four fixes applied, and confirmation that the two acceptance tests hold.
Law
A run that was handed a list answers the list. Item by item, with the ones it did not reach named as not reached. A run that stops early is entitled to stop early; it is not entitled to hand back a file list and let the reader work out which of four things it did.
What is in the code today
Nothing between the brief and the landing asks the leaf to answer item by item, and nothing counts coverage.
- The checklist is read once, before any work, and journaled:
journalAcceptance(cmd/aforge/chat.go:6349) →Store.RecordAcceptance(internal/store/gate.go:660),EventAcceptance(internal/store/gate.go:631). This run's row (acceptance, seq 26) holds 17 points, and one of them is item 4 verbatim: "Make the prose re-ask either name the actual broken rule or remove the sentence; do not keep a comment asserting something untrue." So the list existed, correctly parsed, in the run's own store, the whole time. - The only reader that settles it is the delivery gate —
internal/revision/acceptance.go, whose unmeasured reasons are spelled atinternal/revision/acceptance.go:1196(CoverageUnread) and applied at:1401. A run that never reaches the gate settles nothing. - Mid-flight steering has no item structure at all.
readSteering(internal/exec/linear.go:1274) drains the mailbox and appends each line verbatim as one user message:
*messages = append(*messages, ai.Message{Role: "user", Content: text(
"Guidance from the user, mid-task — adjust course without discarding sound work already done:\n" + guidance)})It counts what was delivered (Outcome.Steered, internal/exec/executor.go:244) and never what was answered.
land()(internal/exec/linear.go:1317) andverdictFor(internal/exec/linear.go:1372) carry no per-item answer, and the failure message assembled for the person is the stop reason plus the file list.
Fix shape
At the seam where a run ends — every ending, the early ones especially — the checklist that is already in the store is read back and the closing words answer it: each point marked answered, not answered, or not reached, in the person's register. Where the run has a deliverable, that becomes part of it; where it has only a stop reason, the list is what turns "context deadline exceeded" into a usable hand-off. Nothing here needs a model call: the points are journaled and the run's own edits are known.
Named tests: a run handed a four-point checklist that touches two of them and stops closes with a line naming the two it did not; a run that reaches no gate still emits the list.
Replication
Store: ~/.aforge/runs/aforge-do-3843206883/graph.db (run 2 of item #515, 2026-09-03T11:31–11:52Z). Queried on a copy; a run store has a half-life (bench/worker-trial/captures/README.md).
-- the steering note, all four items
select payload from events where kind='command_requested'; -- seq 2
-- the checklist the store parsed out of it, item 4 included
select payload from events where kind='acceptance'; -- seq 26, 17 points
-- every edit the run made: one, and its path is shaped.go
select tool, body from transcript
where node_id='task-2' and kind='tool_call' and tool in ('edit','write');
-- prose.go was read and never written
select body from transcript where node_id='task-2' and kind='tool_call'
and body like '%prose.go%';
-- the leaf's own contract, which asked for the summary of four
select body from transcript where node_id='task-2' and kind='note' limit 1;
-- the closing summary
select payload from events where kind='node_failed'; -- seq 79
select error from nodes where id='task-2';Mapping table above is built from the single edit body (seq 62, idx 52) against the four FAULT n headings in seq 2.
From the hand-offs of #515. Report: bench/worker-trial/REPORT.md §"2026-09-03 · #515 — Run 2", branch trial/aforge-as-worker @ 89786a4d (local only, at ~/af-trial). Same run as #549, which is about the deadline that stopped it and the "settled": true it reported; this one is about the list it did not answer. Related: #514.
Queued for after the WIP freeze; do not start without the coordinator.
Drafted with CodeAF · reviewed and owned by the author
Activity
do: a run that was handed a list answers the list, item by item (#640)