Repository navigation
feat(planning): auto-handle plain accepts and confirms so they wake no agent #7969
Description
This was generated by AI during attend-queue.
Agent Brief
Type: Feature
Summary: The interview server marks a plain accept (no note text) and a plain confirm handled when it records them, so the watcher wakes only for events that need a reply.
Current behavior:
Every saved event stays unhandled until the agent sends a handle op, and the watcher (which waits with after=handled) wakes for any unhandled event. 47 of 54 audit-run events were plain accepts or commitment ticks with no text. The watcher's event selection goes through planning's unhandled() override, so this is planning-owned. Owner decision recorded on #6053 (2026-10-13): server auto-handles plain accept and confirm after testing that sync-ledger and exports still record them.
Desired behavior:
- A plain
acceptwith no text and a plainconfirmare recorded in responses exactly as today and marked handled at save time. - Events that need a reply stay unhandled: ask, own, rephrase, note, research, cancel-research, undo, wrapup, confirm-understanding, accept with text, accept-audit.
- When an auto-handled accept settles the last open question of a round, an event the watcher wakes on is still produced, so the agent learns the round is complete.
sync-ledgerandexport-briefrecord every auto-handled accept, the same as a hand-handled one.- Undo of an auto-handled accept keeps working: an auto-handled plain accept stays undoable until the agent acts on a later event in that round. The server records auto-handled seqs apart from agent-handled ones, and the undo refusal "Claude already handled it" applies only to agent-handled seqs (decision defaulted on this issue; veto before merge).
- The interview surface reference describes which events are auto-handled; the dedicated-session offer stays.
Key interfaces:
- Planning's
Hub.unhandled(r)and the save path: the handled set gains auto-handled seqs. - Responses and questions documents: unchanged shape.
sync-ledgerandexport-briefoutputs: unchanged for the same answers.
Acceptance criteria:
- A test written first shows
sync-ledgerandexport-briefoutput identical for a round answered with plain accepts whether those events were handled by the agent or auto-handled. The PR's CI runsplugins/planning/surface/test_exporters.pyand it passes. - The PR's CI runs
plugins/planning/surface/test_server.pyand it passes. It includes cases for: a plain accept absent fromunhandled(); an accept with text present; the last plain accept of a round yielding a wake-producing event; undo of an auto-handled accept succeeding; undo of an agent-handled accept still returning 409. - The diff touches no file registered in
scripts/shared-copies.txt. Check: the PR's CI shared-copy sync check passes. - A planning fragment exists (
scripts/new-changelog-fragment.sh planning patch), andscripts/check-changelog-fragments.sh --checkpasses.
Out of scope:
- The bridge transport and
watch.sh(shared copies). - The settle-window setting (sibling item it builds on).
skills/interview/SKILL.mdtext.
This was generated by AI during backlog shaping. Split from #6053; the owner approved filing it in an attended backlog-shaping session on 2026-10-18.
Activity
kyle-sexton commentedon Oct 22, 2026
This was generated by AI during attend-queue.
Decision defaulted: an auto-handled plain accept stays undoable until the agent acts on a later event in that round. The server records auto-handled seqs apart from agent-handled ones, and the undo refusal "Claude already handled it" applies only to agent-handled seqs — veto before merge
Basis: verified,
plugins/planning/surface/server.py:1079-1080(undo raisesConflictwhenis_handled(doc, target_seq)),plugins/planning/surface/test_server.py:292(pins the 409 for an agent-handled event). Without the split, auto-handling would make every plain accept non-undoable, a regression the brief rules out.