mirror of
https://github.com/NeuralNomadsAI/CodeNomad.git
synced 2026-10-21 05:06:37 +00:00
fix(missions): compact coordinator tool results and state the decision rule (#1011)
Coordinators driving a real Wayfinder mission hit three costly frictions (#1009): every mission tool mutation echoed the whole map (about 50 KB after ten tasks), the canonical assignment prompt only existed inside that response, and the decision role read as a self-contained analysis although completing it requires the human's own answer to a native question. mission.delegate, revise, report and briefing now return a compact readout (missions/tool-result.ts): disposition, current revision, status, run state, frontier and the affected tasks, plus the contract and exact assignment prompt for a declared native task. Briefs, reports and the objective stay out; mission.inspect keeps the full map, and mission.inspect({ taskKey }) rereads one task with its contract and current prompt. The returned revision feeds expectedRevision and basedOnRevision directly. Reports name the task the control actually resolved, including an independent actor's omitted taskKey. The native Wayfinder decision role, the coordinator contract and native decision declarations state the rule verifyHumanDecision enforces: the task's own conversation asks through the native question tool and the user answers in CodeNomad; self-contained analysis belongs to research. Independent-mode coordinators, which that gate does not check, do not get it. The refusal shows the exact provenance shape the gate validates, kept aligned with nativeDecisionProvenance by a test. Refusals for a withdrawn readout and unsettled withdrawn work explain what to do, a briefing citing missing or retired tasks names them, and the Missions skill matches. No journal, gate, ownership, RPC or UI contract changes. Interrupting a retired task's native child, multi-task replacement, a paused-mission creation tool, native execution visibility and Form IDs remain open. Validation: 1,104 Missions server tests pass (one existing skip), with new compact-result, task reread, retired readout, briefing source, implicit report key, refusal shape and decision-rule tests. The isolated native Missions, trajectory and contract fixtures pass against OpenCode 2.0.31. Server typechecks show only the existing diagnostics. Two gatekeeper rounds; the second found no P0-P3 issue. Refs #1009.
This commit is contained in:
parent
afe0f877e5
commit
1173beb37c
16 changed files with 295 additions and 98 deletions
|
|
@ -28,6 +28,14 @@ through their actual parent; the coordinator records the declared task's busines
|
|||
readout without requiring duplicate reports from every descendant. Explicit
|
||||
independent actors retain correlated report notifications and native queue delivery.
|
||||
|
||||
Model-facing mutation results stay compact (`missions/tool-result.ts`): the
|
||||
disposition, current revision, run state, frontier and the affected tasks
|
||||
(status, generation, dependencies and lineage), never briefs, reports or the
|
||||
objective. Only `mission.inspect` returns the full map; `mission.inspect({ taskKey })`
|
||||
rereads one task with its contract and exact current assignment prompt. A native
|
||||
Wayfinder `decision` declaration also states the human-answer requirement that
|
||||
`verifyHumanDecision` enforces, so a self-contained analysis goes to `research`.
|
||||
|
||||
## Durability and recovery
|
||||
|
||||
### Human instructions and actionable attention
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue