Runtime / Post-MVP

Durability

What happens when something dies today, what the post-MVP release will guarantee instead, what is stored from day one to make that possible, and the three acceptance tests.

View .md

Durability means a failure at any point leaves the run able to continue from where it was. The MVP’s claims are about the language and about teams, not about surviving crashes, so durability is table stakes that waits for the release after.

Failures: now and later

FailureMVP behaviorPost-MVP guarantee
A runner dies mid-turnThe agent is failed with runner_error. The run continues without it; the overseer is told on systemThe controller starts a new runner that resumes the same SDK session by its stored session id, with the work folder as it was. The interrupted turn is retried from its input
convoyd dies mid-turnOn the next start, every active run is marked failed with server_restart and leftover runner processes are killedOn the next start, convoyd reloads every active run, re-adopts or restarts each runner, and resumes from stored state. No message is lost or delivered twice, and spend is not reset
The budget is hit mid-turnEvery agent is stopped with reason budget, outputs are keptThe same, plus a run can be continued with a raised budget

Stored from day one

Every change is written as it happens. For each agent:

  • its SDK session id (the Claude Agent SDK’s session_id; for the OpenAI Agents SDK, the session id plus the last response id),
  • its read cursor on every topic and its wake state,
  • its turn count and the priced usage of every turn,
  • its process handle, and its status.

For each run: its spec (the stored bundle), spend, and the event log.

The runner contributes by reporting the session id on every wake, and by leaving its work folder and session.db in place when it exits. The process backend stores an opaque process id so a later Reattach can adopt a runner that outlived a convoyd restart; the MVP has no such path, and every runner of an active run dies with the run.

Recovery will resume the real SDK session from these values, not restart from a summary. The change is to the controller’s start-up path and its exit rules, described on Controller.

Acceptance tests

The durability release is done when all three pass:

  1. Runner kill. Run kill -9 on a random runner mid-turn. It resumes its session and the swarm still reaches done_when.
  2. Server kill. Run kill -9 on convoyd mid-run, then start it. Runners are re-adopted or resumed, no message is lost or duplicated, and spend is unchanged.
  3. Budget mid-turn. Hit the budget mid-turn. Everything stops with reason budget, outputs are kept, and overshoot is at most one turn per running agent.

All three run against a local openai_compatible model so they cost nothing.

What the MVP does on a restart

On start, before serving requests, convoyd sets every non-terminal agent of every active run to failed with end_reason = server_restart, revokes their tokens, sets the run to failed with the same reason, and kills every stored process id. A new convoy run starts a fresh run. The failed run stays readable with convoy status --run N. The details are on Controller.

Last updated 2026-11-05
esc
    ↑↓ to move · ↵ to open
    Menu
    Get started
    IntroductionInstallQuickstartYour first swarm
    Concepts
    Swarms and runsAgents and turnsTopics and the boardThe overseerSpawning agentsBudgets and limits
    DSL
    Language rulesswarmprovidertopicagentReferences and functionsValidation rules
    Providers
    Provider typesUsing a provider typeWriting a provider type
    CLI
    Overviewconvoy goalconvoy validateconvoy runconvoy statusconvoy watchconvoy sayconvoy stopconvoy uiconvoy provider
    Runtime
    convoydControllerMessage boardRunnerSwarm tools (MCP)Web UIDurability
    Architecture
    OverviewRepository layoutSeams and contractsHTTP API
    Examples
    OverviewWriter and criticResearch teamCode teamPaperBench replicationCommit0 libraryVending-BenchSWE-Lancer bountyτ²-bench loop
    Inspiration
    What we borrowedThe harness landscape