# The three explore feedback metrics — start here The agent-eval harness reports three metrics on every run. They are not three views of one number; each answers a different question, and a retrieval change can move one without moving the others. This page says which is which, which harness to run, and how to read the output. The per-metric docs carry the derivations and the caveats — read the one that matters once a number moves. | Metric | The question it answers | Doc | |---|---|---| | **Residual context occupancy** (CG-7) | How much of the window does this arm's retrieval still hold when the run ends — i.e. what does every following turn have to work in? | [`residual-context-occupancy.md`](residual-context-occupancy.md) | | **Explore sufficiency** (CG-8) | Was a response *enough*? Read off what the agent did next: explored again, read a file, or answered. | [`explore-sufficiency.md`](explore-sufficiency.md) | | **Allocation efficiency** (CG-9) | Of the bytes a response spent, what share went to files the answer actually drew on? | [`explore-allocation-efficiency.md`](explore-allocation-efficiency.md) | All three are **harness-only**: parsed out of transcripts we already write. Nothing is emitted from the product and nothing leaves the machine. --- ## Which harness Pick by the question you are actually asking. All three metrics print in both. **Isolating a retrieval change — `ab-new-vs-baseline.sh`.** New build (HEAD) vs a baseline build (a git ref), **both arms codegraph-on**, same task. This is the harness the three metrics were built for: with codegraph on in both arms, every number is measuring the change rather than adoption. ```bash RUNS=3 scripts/agent-eval/ab-new-vs-baseline.sh /tmp/codegraph-corpus/express \ "Add a charset option to res.send and wire it through" main ``` It builds each arm, indexes a throwaway copy of the target, **pre-warms a codegraph daemon per run**, runs the task `RUNS` times per arm, prints the three metric blocks under each run, and ends with the side-by-side table below. The pre-warm is load-bearing and must not be removed: without it the agent dives into Read/grep before codegraph finishes its ~2–3s startup, and the run measures attach latency instead of retrieval. **With vs without codegraph — `run-all.sh`.** Codegraph-on against an empty MCP config. A different question: displacement and adoption, not the effect of a change. Multi-turn is where occupancy is actually charged, so separate turns with `||`. ```bash scripts/agent-eval/run-all.sh /tmp/codegraph-corpus/gin \ "How does gin route requests through its middleware chain?||\ Where is the 404 / no-route case handled in that same chain?" ``` `CG_ARMS=with|without` re-runs one arm without redoing the other; the comparison table still renders against whichever arm's logs are already in `$AGENT_EVAL_OUT`. **A campaign — `bench-readme.sh`.** The 7 README repos, three turns each, `RUNS` per arm, through `run-all.sh` — so every run in a campaign carries all three metrics. Aggregate with `parse-bench-readme.mjs`. One has been run: [the 2026-08-05 baseline](residual-context-occupancy.md#baseline-the-7-readme-repos) (sonnet, 3 turns, 4 runs/arm) — read its regime box before comparing anything to it, and note that it is **not** the regime the README's table was published in. **A log you already have.** `parse-run.mjs [run.tN.jsonl …]` prints the three blocks for any stream-json log; `--brief` drops the numbered call transcript. `parse-session.mjs ` does sufficiency and allocation for an *interactive* session. `compare-arms.mjs