Skip to main content

Module checklist

Module checklist 

Source
Expand description

The todo_write tool — the model-facing write path onto a session’s per-agent checklist (#8235).

Why: the roster’s todos field (DOC-39 §5.4, session::registry_agents) was reserved and always empty because nothing could write it, so a multi-step task had no in-flight plan anywhere. The #8235 parity capture is the cost: asked for a flag, a test and a changelog line, the agent landed the flag and went idle with the other two silently dropped. Goal slots (tools::goals) are not that mechanism — five fixed slots, no per-step state, and their own description tells the model they are “NOT a todo list”. What: TodoWriteTool validates the model’s whole-list argument and hands it to a TodoStore. The store trait lives HERE, in the tools layer, and task::todo_store::SessionTodoStore implements it — the same layering agent_loop::sink::ToolEventSink uses, so tools never depends upward on session/task. Registered on the daemon-session registry only (task::executor::run_and_record), exactly like set_goal/clear_goal.

Whole-list replace, not a patch. #8235’s own closure condition names “a whole-list-replace call”, and the token arithmetic agrees: a patch protocol needs stable per-item ids the model must carry across compaction, plus a companion read tool to recover them after a reset — two calls and a stale-id failure mode to save a handful of tokens on a list that is rarely longer than ten short lines. Test: tests::* (this file’s sibling checklist_tests.rs) for schema, validation and store dispatch; task::todo_store::tests::* for the round trip out through session.get_agents.

Structs§

TodoWriteTool
ToolExecutor for todo_write (#8235).

Enums§

TodoError
Why a todo_write call was refused (#8235).

Constants§

MAX_TODOS
Hard ceiling on a single checklist’s length.
TODO_WRITE_TOOL_NAME
The todo_write tool’s registered/advertised name.

Traits§

TodoStore
Where a validated checklist is written (#8235).