Repository navigation
Seed the decision fixture instead of setup turns, name exclusion causes, and ask about a typeless duplicate create (closes #3500) - #3504
Conversation
Pragmatic Code Review: PR #3504 (initial review)Review type: Initial review SummaryThis PR improves the code. It removes the cause of the problems, the setup turns that made each decision scenario depend on the chats before it, instead of patching around them. It also deletes the workaround machinery those turns needed: Harness tests: Requirements check (#3500)
FindingsCriticalNone. Improvements
Nits
VerdictAPPROVE. None of the findings block. The |
malibio
left a comment
There was a problem hiding this comment.
Automated pragmatic-code-review: APPROVE (posted as a comment — GitHub blocks self-approval). Full findings in the review comment above.
Review addressed (ba6f987)Addressed
Skipped
Re-Review DecisionDecision: NO RE-REVIEW NEEDED Rationale: Two small, test-covered changes: one predicate merged into another in the guard, and a stricter, sentence-scoped version of a scorer function, validated against every recorded routing turn. Everything else is comment wording. |
Pragmatic Code Review: PR #3504 (re-review)Review type: Re-review of Previous review summary
Previous findings, verified:
Tests: harness 240/240. New findingsCriticalNone. Improvements
Nits
VerdictAPPROVE. The two earlier improvements are fixed, with tests that pin them. The widened lookup recovery is a reasonable reading of "what grounds the answer", and it never extends to writes. The only gap worth closing before merge is the negative test, which cannot currently fail. It is a one-line change to the executor. |
malibio
left a comment
There was a problem hiding this comment.
Automated pragmatic-code-review (re-review): APPROVE (posted as a comment — GitHub blocks self-approval). Full findings in the review comment above.
Re-review addressed (3b7afca)Addressed
No behaviour change; 5/5 failure-surfacing tests pass. Re-Review DecisionDecision: NO RE-REVIEW NEEDED Rationale: A test fixture correction, a helper replaced by the identical existing classification, and a comment. |
Pragmatic Code Review: PR #3504 (re-review of 68a5cac)Review type: Re-review of Previous review summaryThe last re-review had 1 improvement and 3 nits. All four were addressed in 3b7afca, and address-review decided no re-review was needed. This round covers only the new commit. What was verified
FindingsCriticalNone. Improvements
Nits
VerdictAPPROVE. The fix is right and the analysis behind it is sound. |
Re-review of 68a5cac addressed (cf14ff3)Addressed
Skipped
Re-Review DecisionDecision: NO RE-REVIEW NEEDED Rationale: Deletion of an unused hook and its block, and documentation wording. No behaviour change for any fixture in the repo. |
…and name what excluded a scenario (#3500) Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…ate (#3500) Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…ot on its phrasing (#3500) Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
#3500) Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…e bisect and the declarative decision in the fixture (#3500) Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…and read a clarification from the question sentence - mentioned_entity_duplicated_by filters already-asked entities in the find predicate, so a typeless create still matches a second same-titled entity. - isClarification needs the phrase in a sentence ending in '?', ignores quoted text and abbreviations, and knows 'want me to'. Re-scoring every recorded routing turn changes no verdict but the intended one. - Comments: the read-before-asking allowance is general; stale embedding rows come from edits too; the schema-on-menu-company note states the constraint. Skipped: seeding the company type under a display name, or without its name field. Both would change the type every earlier run was scored against. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…3500) The tool-failure guard counted a failed call as recovered only by a later call to the same tool. A refused search_nodes filter followed by a search_semantic that found the record left the answer in place on the model's side and showed the user the first call's error. Any later successful graph lookup now recovers a failed one; a write still does not. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
The company type declares a name field the seed never filled, so a search filtering on it found nothing and the field question was answered with 'no such record'. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…t the write case of the recovery test fail - The failure guard uses resolves_entities_tool, the registry's exhaustive classification of tools whose results are graph nodes, instead of a second list of the same five tools. - update_node succeeds in the recovery test, so its negative half fails if a write is ever counted as a lookup. - The guard's comment says recovery is by kind of tool, not by target. No behaviour change. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…3500) op-read-then-write moves Northwind's date to April, and outcome-record-field-is-answered, asked in a later chat of the same rep, was answered with April and scored as wrong. seedWorkspace now runs before every chat (creating the types only when missing, resetting Northwind's fields), so a scenario's state no longer depends on the chats before it. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
…the reseed does not undo - EvalFixture.seedRun and the runner's per-rep seeding block go: no fixture uses them, and their docs told a reader to move instance seeding back out of seedGroup. The seedGroup doc says a seed must create what it depends on. - seedWorkspace's doc says only seeded state is set back; a node an earlier chat created stays. - Wording: linked skills are kept out of other chats, a test title matches its assertion. Skipped: skipping Northwind's update when its fields already match. The final measured run reset it before every chat, and the change would make the reported numbers describe different seeding. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
cf14ff3 to
d43a5aa
Compare
Closes #3500
What was wrong
schema-on-menu-companydid not regress from a commit. The model's first call in every failing run wascreate_node {"content":"Northwind Trading","field_values":{"name":"Northwind Trading, signed_date:"}}: nonode_type, so the duplicate guard (which matched on type and title) let it through, the executor refused it for the missing field, and the turn ended apologising for the tool error. Bisected acrossd9f8974…9dbc804with prompt dumps, the call came out whole or broken with the **workspace**, not the build. Every broken one was asked with a second venue type beside the first (event_placeandevent_venue), which a later chat's setup turn had named differently from an earlier one's; the whole one, on the #3496-only build, had one venue type.main`'s own build, run on this branch's seeded fixture, passes 3 of 3 with a well-formed call.The decision fixture's setup turns made every scenario depend on the chats before it. The run seed already created the company type, so
setup-companywas a refused no-op in every chat andsetup-venuein every chat after the first. Each scenario was asked after two failed turns, model-named duplicate types accumulated, and a setup turn that answered "that type already exists" blocked its scenario.The summary called every unscored scenario a "degenerate empty generation", whatever excluded it.
Change
eval harness
company_sold_to,event_venue) and Northwind once per rep, and has no setup turns: every scenario is the first turn of its own chat, against the same two types, whatever ran first. ThesetupStatePresenthook andsetupLeftStateMissing, which existed only to let those setup turns meet existing types, are deleted.ambiguous-client-contactspassed or failed on which of two equivalent phrasings the model picked. A search before the question is accepted for that scenario, and the fixture says why.declarative-fact-report-resolved: decision recorded in the fixture (kept as scored, no fix): see its comment.agent
create_nodethat names a mentioned entity's title and no type. That call cannot run, and left to the executor the user was told a tool call failed instead of being asked about the record they named.Tests
agent_loopunit tests: a create with no type (or a blank one) matches by title; another type or another title does not; the malformed call above is refused and the user is asked.runner.test.ts: exclusion causes per scenario, the table naming each,describeExclusions.routing.test.ts: clarify scoring (Stage 1 ask, search-then-ask, ask after a write, no question).preflight.test.ts: the default embedded-skill query against a real SQLite file ignores stale rows.decisions.test.ts: one chat per scenario, no setup turns.bun run test:changedpasses (rust, scripts, types and node-types drift).Eval
Before/after results, from full runs of both fixtures on
gemma-4-e4b-q4km, are posted on #3500.🤖 Generated with Claude Code