run_checkpoint) to comet-state.yaml in the project repository. In everyday use, just return to the project conversation and say “continue” or state your next request. The Agent automatically reads the latest continuation directive returned by the Runtime in the background instead of guessing progress from chat memory.
How the Runtime tells the Agent what to do next
Whenever entering a workspace or resuming a session, the Agent performs a read-only background status query (modifying no files and never silently restoring missing Runs). By default, the query returns allpending, running, and unknown actions in full while including only the most recent 12 items of each completed history collection—keeping context overhead low without missing active work. Earlier rounds can be inspected on demand with --details, and long tasks support --compact to compress repeated structures.
The Runtime communicates the next step explicitly through continuation.mode in its response so the Agent never has to guess the current phase:
For example, if you closed the window while working on
login-error-message, reopen the Agent and say: “Continue login-error-message and tell me where it is paused.” If background status reports phase: "verify" and continuation.mode: "wait", the Agent checks the original verification session’s progress instead of dispatching a new Verifier.
Background advancement protocol and staleness protection
Both standard and Supervisor tasks advance in the background through the unified task protocol (comet native next) to claim work and report results: before Shape confirmation it submits structured acceptance criteria; after Shape confirmation it covers implementation, independent verification, child build and verify, integration fixes, and parent fixes. This protocol provides four underlying guarantees:
- One submission chains internal steps: After the Agent submits a round’s business outcome, the Runtime strictly validates the payload (accepting only valid statuses and schema fields, rejecting typos or extra fields), automatically runs all approved internal steps in sequence, and returns the next pending task or human confirmation point directly.
- Automatic context injection: When claiming a task, the Runtime automatically attaches relevant personal preferences and project knowledge for the current phase and task so you do not have to repeat team conventions at every stage.
- Idempotent retries prevent double-accounting: If a network hiccup prevents the Agent from receiving a receipt, resubmitting from the original claimer with the same task identifier, session, and payload is recognized as an idempotent confirmation rather than recording the round twice; submissions from a different session or with different content are rejected.
- Three concurrency guard parameters block stale approvals: When you confirm Shape, accept verification results, or request a revision, the background command automatically carries three validation flags:
--expected-state-version <n>: Checks the state version and immediately rejects stale commands if another session has already advanced the state.--expected-action <action>: Binds the expected action so a confirmation cannot land on the wrong step.--proposal-hash <hash>: Binds the specific proposal or verification verdict digest awaiting confirmation; any edit to the proposal immediately invalidates older approvals.
Tool timeouts, running tasks, and pausing monitoring
An Agent platform wait-tool timeout or an unexpected local terminal disconnect does not mean that a running test, build, or Verifier has failed. Native does not track or force-kill tasks using OS PIDs. It applies the following rules:Pausing periodic monitoring while waiting for external input
When a task is only waiting for your reply or external information—with no runnable child tasks, no running background tasks, and no external jobs requiring periodic polling (such as CI)—the Agent may pause periodic monitoring for that task while keeping monitors for other independent tasks active. When first entering the wait, the Agent explains once why it is blocked, what information is missing, which monitors are paused, and what condition resumes work; once new input arrives, it re-reads Runtime state and resumes.Checkpoint write boundaries and safety mechanisms
Understanding the split between the local Run and the repository checkpoint clarifies what is preserved automatically across interruptions or machine switches:- Local Run: Stored in the Comet data directory under your home directory (isolated by workspace), recording every advancement, claim receipt, and internal event in real time.
- Repository checkpoint (
run_checkpoint): Saved incomet-state.yamlinside the project repository, committed and synced alongside code.
When checkpoints are written
The Runtime writesrun_checkpoint only at key stage boundaries—before waiting for user confirmation, at Agent task handoffs, before external command execution, and when the workflow finishes. Purely internal, side-effect-free intermediate steps do not frequently rewrite comet-state.yaml, avoiding noisy Git diffs. Do not manually edit the checkpoint to try to advance a workflow.
Three layers of checkpoint protection
- Local token redaction: Before writing to the repository checkpoint, local execution tokens undergo one-way redaction so local credentials are never committed to Git.
- In-flight tasks automatically downgrade to
unknown: When writing a checkpoint, anyrunningaction is downgraded tounknown. Restoring on another machine will never treat a task still running on the old machine as an idle action safe to replay. - Integrity verification and history compression: Checkpoints include integrity verification and automatically compress repeated history for long tasks, blocking manual tampering or file truncation during recovery.
Optional read-only terminal commands
Optional read-only terminal commands
If the change lives in an independent Git worktree, switch into that worktree directory before running:
comet native next; you do not need to run this manually.
Command reference (run by the Agent; for terminal troubleshooting only)
Command reference (run by the Agent; for terminal troubleshooting only)

