fix(dispatcher): validator returns evidence-bound correction to the same retained worker #281

Merged
karsten merged 3 commits from akira/hayate-agent-core:fix/validator-same-worker-correction into main 2026-11-05 19:18:36 +00:00
Owner

Validator returns an evidence-bound correction to the SAME retained sequential worker instead of pausing, when a worker blocked claim or evidence shortfall rests on a false/unverified assumption (false updater capability, false review CWD, artificial evidence count).

  • host-observed tool facts (bounded, untrusted) of the worker turn reach the independent validator as completionContext.tools; validator prompt carries current authority (deadline) and the correctable-vs-external-blocked rule
  • correction {index, rounds, note} persisted via the existing checkpoint BEFORE the corrected same-session turn; validated on load (index == outcomes.length, 1<=rounds<=STEP_CONTINUATIONS, note<=1500) so corrupt metadata blocks visibly instead of an unbounded loop
  • restart resumes the exact step with PENDING VALIDATOR CORRECTION; no replan, no earlier-step replay, same intent/route/session
  • identical repeated correction stops with one short operator notice; blocked/uncertain/invalid/technical assessments never authorize
  • reuses STEP_CONTINUATIONS=2, assessCompletion, authorize()/check(); pause/stop/expiry stay binding; no new interface, no budget/recovery changes
  • paused-child-supervision fixture varies the continue note (repeat rule)

Tests: test/dispatcher-sequential.test.ts +7 (three real false-assumption cases full sequence, persist+restart, repeat bound, no-correction on blocked/technical, corrupt metadata, manual pause). Fail without the source change, pass with it.
Gates (Node 26.11, TMPDIR /private/tmp, flock shim, isolated HOME, env -i): typecheck ok; npm test 1529 tests, 1526 pass, 0 fail, 3 skipped.
Independent review (direct CLI, console home .review-home-validator-correction, cwd = worktree): root validator-correction, base 065683c, committed HEAD 5cb800f, fingerprint 16e3fbca..., passed, 0 blockers, 0 findings (earlier committed baf193e: fp 1279492d..., passed).
Fixture-only evidence; live acceptance follows after merge and activation.

Validator returns an evidence-bound correction to the SAME retained sequential worker instead of pausing, when a worker `blocked` claim or evidence shortfall rests on a false/unverified assumption (false updater capability, false review CWD, artificial evidence count). - host-observed tool facts (bounded, untrusted) of the worker turn reach the independent validator as completionContext.tools; validator prompt carries current authority (deadline) and the correctable-vs-external-blocked rule - correction {index, rounds, note} persisted via the existing checkpoint BEFORE the corrected same-session turn; validated on load (index == outcomes.length, 1<=rounds<=STEP_CONTINUATIONS, note<=1500) so corrupt metadata blocks visibly instead of an unbounded loop - restart resumes the exact step with PENDING VALIDATOR CORRECTION; no replan, no earlier-step replay, same intent/route/session - identical repeated correction stops with one short operator notice; blocked/uncertain/invalid/technical assessments never authorize - reuses STEP_CONTINUATIONS=2, assessCompletion, authorize()/check(); pause/stop/expiry stay binding; no new interface, no budget/recovery changes - paused-child-supervision fixture varies the continue note (repeat rule) Tests: test/dispatcher-sequential.test.ts +7 (three real false-assumption cases full sequence, persist+restart, repeat bound, no-correction on blocked/technical, corrupt metadata, manual pause). Fail without the source change, pass with it. Gates (Node 26.11, TMPDIR /private/tmp, flock shim, isolated HOME, env -i): typecheck ok; npm test 1529 tests, 1526 pass, 0 fail, 3 skipped. Independent review (direct CLI, console home .review-home-validator-correction, cwd = worktree): root validator-correction, base 065683c, committed HEAD 5cb800f, fingerprint 16e3fbca..., passed, 0 blockers, 0 findings (earlier committed baf193e: fp 1279492d..., passed). Fixture-only evidence; live acceptance follows after merge and activation.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
harness/core!281
No description provided.