Repository navigation
Description
What you were trying to do
Build the Redirector benchmark task using URLCode; verify with the checks an authoring agent is actually told to run.
Where it broke down
#290 fixed urlcode audit's diagnostics (added declared/generated to counts) and documented the --expect-routes counting rule in docs/READINESS.md ("N is the total configured count: declared routes plus generated site.* routes"). That rule never reached any of the three places an authoring agent is actually pointed at first — all three hand over a pre-computed, already-correct N with no explanation of why it's not just the number of routes: entries:
- Generated project
AGENTS.md(urlcode init/renderAgentsGuide()inpackages/core/src/agents-guide.ts,## Checks that count as evidence, ~lines 90-98): rendersurlcode audit --expect-routes ${routes}with the correct number, then only says "Run all three after every change, updating the route count deliberately."starters/default/AGENTS.mdships the identical static gap (stale--expect-routes 2, same vague prose). - Packaged skill (
skills/urlcode/SKILL.md,## 4. Prove it, lines 112-124): same command, same gap — "UpdateNdeliberately when routes are added or removed" never mentions generatedsite.*routes count toward N. - MCP
get_context(packages/core/src/context.ts:126,236):commands.auditis built fromcompiled.count/context.project.routes(already includes generated routes), but the returnedProjectContextcarries no note explaining thatproject.routes!=routes:entry count.
An agent that reasons from its own declared-route count (rather than blindly copy-pasting the given N) hits route-count-mismatch and has to read the audit failure's counts breakdown to learn the rule — the exact trial-and-error #290 was meant to eliminate, and it happens regardless of which of the three paths the agent used to get started.
Evidence
A/B benchmark run test4 (task: redirector, contract redirector-v8, @jimhoyd/[email protected], Sonnet 5 medium, run 2026-09-22 — after #290/PR #298 shipped). Agent B's filed feedback:
urlcode audit --expect-routes Ncounts N against the total generated route count (declared routes plus one auto-generated route persite.*convention, e.g. the 404 page), not against the number of entries underroutes:in urlcode.yaml. With 5 declared redirect routes plussite.notFound,--expect-routes 5fails with a route-count-mismatch and--expect-routes 6is required.
The project's own generated AGENTS.md (work/b-1/AGENTS.md:59) listed urlcode audit --expect-routes 6 verbatim (the correct number), but without the rule stated the agent still tried 5 first based on its own route count.
Suggested improvement
Add one short clause stating the counting rule everywhere N is handed to an agent, e.g.: "N is declared routes plus one per active site.* convention; the audit failure reports declared/generated if you get it wrong."
renderAgentsGuide()'s## Checks that count as evidencesection (andstarters/default/AGENTS.md).skills/urlcode/SKILL.md## 4. Prove itsection.ProjectContextfromget_context: either a one-line note field nearproject.routes/commands.audit, or fold it intoconstraints.
Keep each addition to a clause, not a paragraph — AGENTS.md is "under 80 lines by design" and the skill/context payload are similarly budget-conscious.
What was not verified
Single session (n=1), not repeated evidence.
Activity