Skip to content

docs: crash-resume guide (docs/RESUME.md) - #64

Merged
prashar32 merged 1 commit into
mainfrom
docs/crash-resume-guide
Jun 5, 2026
Merged

docs: crash-resume guide (docs/RESUME.md)#64
prashar32 merged 1 commit into
mainfrom
docs/crash-resume-guide

Conversation

@prashar32

@prashar32 prashar32 commented Jun 5, 2026

Copy link
Copy Markdown
Owner

Adds docs/RESUME.md — the full crash-resume model in one place, so the moat is documented as product rather than folklore.

It covers:

  • The two halves — the daemon reloads runs with their already-spent budget automatically; the agent checkpoints its own progress and re-attaches with resume_run.
  • What's restored — a table: spent tokens/dollars/loops, the budget, the cost ledger, and the last checkpoint payload; the time-budget clock restarts (it meters an active session, not downtime).
  • Exact-once, even mid-step — the guarantee from fix(runs): exact-once resume across a mid-step crash #63: a partial step is rolled back so the loop and dollar budgets are charged exactly once.
  • Idempotency, the one part that's on the caller — the interrupted step's work can re-run, so side-effecting tools must be safe to re-run. RiskKernel gates and audits them but can't make them idempotent.
  • What can't be resumed — terminal (budget-halted / cancelled) runs; plus the runs resume / runs list CLI.
  • Stability — the checkpoint format and resume surfaces are versioned (links COMPATIBILITY.md).

I also updated the kill-9-resume demo's crash-instant note to the now-exact-once behaviour and linked the guide from the README checkpoints row.

Docs only — no code change; verified every relative link and SDK-README anchor resolves.

The full crash-resume model in one place: the two cooperating halves (daemon reload
+ agent checkpoint / resume_run), what's restored, the exact-once budget guarantee
across a mid-step crash, how to write a resumable agent, and the one responsibility
that's the user's — making side-effecting steps idempotent, since the interrupted
step's work is re-attempted.

Updates the kill-9-resume demo's crash-instant note to the now-exact-once behavior
(#63), links the guide from the README checkpoints row, and records it in the
changelog.
@prashar32
prashar32 merged commit ff245db into main Jun 5, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant