Working-state maintenance
简体中文 · Terms used
Keep the smallest provisional snapshot that lets a capable reader choose the
next authorized action with the available evidence. A working state is not a
journal, a second task contract, or proof of completion. This procedure works
without reading a task-semantics design document.
Maintain the current snapshot
- Reconcile the visible state with the latest user request and completed tool
results. Reuse what is already available; read an owner or evidence reference
only to settle a missing or conflicting fact. Replace the old task when the
request changes; do not carry its pending actions into the new task or invent
a semantic task identifier. A new request can end a previous wait for input.
- Check any new completion claim against the actual result: exit status,
assertions, verification scope, and the relevant owner. A returned tool call,
live process, or written artifact is not a passing check. Distinguish planned,
attempted, implemented, verified, and unresolved work. Unknown stays unknown;
do not expand a targeted pass into a full verification claim.
- Keep an item only if removing it could change the next action, lose an unmet
obligation, violate a constraint, or hide evidence needed to resume. Preserve
necessary exact values, permission boundaries, unresolved assumptions, and
accessible evidence references. Detailed logs and completed-task history
belong at their existing owners, not in this snapshot.
- Rewrite the whole current snapshot rather than appending a progress entry.
Remove superseded observations, resolved blockers, and irrelevant runtime
details; retain an unresolved blocker until evidence settles it. A PID or test
count belongs here only while a current decision depends on it. Do not remove
a necessary condition merely to meet a line target.
- Use only the fields the task needs: goal, relevant verified progress, current
step, next action, blockers, constraints, or evidence. Omit empty fields and
repeated standing instructions. A small task can use one sentence; no fixed
template, field count, or length proves sufficiency.
- Before writing, check whether the reader can identify the next action and its
limits without the original Agent's private reasoning. Write only when the
current state materially changes. On completion leave a short result,
remaining limits, and an evidence entry point, not a deployment narrative.
For NMG, use the existing nmg_state AG writer and complete-text replacement.
The shared memory_policy owns its activation, completion, and recovery rules.
Read working-state operations
only when the operation, binding, or lifecycle needs clarification. Do not put
secrets or hidden chain-of-thought in the state or create another state store.
Existing task contracts
When a task has a contract or governed lifecycle, its owner determines allowed
moves and authoritative facts. Reference those facts; a status sentence cannot
approve a deliverable, grant a lease, undo cancellation, or unlock dependencies.
Do not create a run, Task IR, or board entry merely to maintain a single-Agent
snapshot. Missing required evidence is a gap, not evidence that nothing happened.
Task-unit semantics is optional
background for understanding NMG's governed collaboration, not a prerequisite,
mandatory read, or definition this workflow depends on. Consult the relevant
current owner only when an actual managed task needs its contract interpreted.
No section layout or task-schema fields from that long document are required here.
Small review cases
- A target check exits 0; full verification has not run. Keep the target scope
and the remaining required verification, not "all checks passed".
- A probe exits 1 after producing output. Keep the failure or uncertainty, not
"verified" merely because an artifact or tool response exists.
- A blocker is resolved and the user changes tasks. Drop the old blocker and
pending actions; retain only constraints and evidence relevant to the new task.
- A long snapshot ends with a necessary permission limit. Preserve that limit
while removing irrelevant history; shortening by cutting the tail is unsafe.
These are review examples, not executed evaluations or evidence of token savings.
1---2name: working-state-maintenance3description: Maintain a compact temporary working state during multi-step work, task changes, handoffs, or recovery. Use when updating current progress, correcting stale status, or when the user asks to 维护工作状态、精简进度、更新当前状态 or continue an interrupted task. Not for durable memory capture or a new task execution engine.4metadata:5 source: https://skillmd.com/skills/wefio/working-state-maintenance6---78# Working-state maintenance910[简体中文](SKILL.zh-CN.md) · [Terms used](SKILL.terms.yaml)1112Keep the smallest provisional snapshot that lets a capable reader choose the13next authorized action with the available evidence. A working state is not a14journal, a second task contract, or proof of completion. This procedure works15without reading a task-semantics design document.1617## Maintain the current snapshot18191. Reconcile the visible state with the latest user request and completed tool20 results. Reuse what is already available; read an owner or evidence reference21 only to settle a missing or conflicting fact. Replace the old task when the22 request changes; do not carry its pending actions into the new task or invent23 a semantic task identifier. A new request can end a previous wait for input.242. Check any new completion claim against the actual result: exit status,25 assertions, verification scope, and the relevant owner. A returned tool call,26 live process, or written artifact is not a passing check. Distinguish planned,27 attempted, implemented, verified, and unresolved work. Unknown stays unknown;28 do not expand a targeted pass into a full verification claim.293. Keep an item only if removing it could change the next action, lose an unmet30 obligation, violate a constraint, or hide evidence needed to resume. Preserve31 necessary exact values, permission boundaries, unresolved assumptions, and32 accessible evidence references. Detailed logs and completed-task history33 belong at their existing owners, not in this snapshot.344. Rewrite the whole current snapshot rather than appending a progress entry.35 Remove superseded observations, resolved blockers, and irrelevant runtime36 details; retain an unresolved blocker until evidence settles it. A PID or test37 count belongs here only while a current decision depends on it. Do not remove38 a necessary condition merely to meet a line target.395. Use only the fields the task needs: goal, relevant verified progress, current40 step, next action, blockers, constraints, or evidence. Omit empty fields and41 repeated standing instructions. A small task can use one sentence; no fixed42 template, field count, or length proves sufficiency.436. Before writing, check whether the reader can identify the next action and its44 limits without the original Agent's private reasoning. Write only when the45 current state materially changes. On completion leave a short result,46 remaining limits, and an evidence entry point, not a deployment narrative.4748For NMG, use the existing `nmg_state` AG writer and complete-text replacement.49The shared `memory_policy` owns its activation, completion, and recovery rules.50Read [working-state operations](../nmg-memory/references/optional-capabilities.md#working_state-operations)51only when the operation, binding, or lifecycle needs clarification. Do not put52secrets or hidden chain-of-thought in the state or create another state store.5354## Existing task contracts5556When a task has a contract or governed lifecycle, its owner determines allowed57moves and authoritative facts. Reference those facts; a status sentence cannot58approve a deliverable, grant a lease, undo cancellation, or unlock dependencies.59Do not create a run, Task IR, or board entry merely to maintain a single-Agent60snapshot. Missing required evidence is a gap, not evidence that nothing happened.6162[Task-unit semantics](../../docs/design/task-unit-semantics.md) is optional63background for understanding NMG's governed collaboration, not a prerequisite,64mandatory read, or definition this workflow depends on. Consult the relevant65current owner only when an actual managed task needs its contract interpreted.66No section layout or task-schema fields from that long document are required here.6768## Small review cases6970- A target check exits 0; full verification has not run. Keep the target scope71 and the remaining required verification, not "all checks passed".72- A probe exits 1 after producing output. Keep the failure or uncertainty, not73 "verified" merely because an artifact or tool response exists.74- A blocker is resolved and the user changes tasks. Drop the old blocker and75 pending actions; retain only constraints and evidence relevant to the new task.76- A long snapshot ends with a necessary permission limit. Preserve that limit77 while removing irrelevant history; shortening by cutting the tail is unsafe.7879These are review examples, not executed evaluations or evidence of token savings.