Learn how to make AI agent runs durable so a killed worker does not lose work or double-refund customers. In Lesson 15 of Build Real Agent Systems, we move Relay’s ticket runs onto a durable workflow engine. Every model call, tool call, and send becomes a checkpoint. Kill the worker mid-run, start the same command again, and the run finishes once — with the same decision, one message, and one refund when idempotency keys are on. What you’ll learn Why in-process agent loops fail when the worker dies mid-ticket Workflows, steps, checkpoints, and recovery in plain engineering terms How DBOS Transact stores progress (SQLite locally, Postgres in production) Stable step names so a restarted run replays in the same order Idempotency keys vs checkpoints: what each protects (and what key_off breaks) Kill points: after model, after tool, before/after send, after finish Proving parity: durable runs match in-process decisions on Relay-Bench Chaos testing with real SIGKILL and resumed SUCCESS runs Who this is for Backend and AI engineers building production agents, support automation, or long-running LLM workflows that must survive deploys, crashes, and restarts. Stack Python · DBOS Transact · SQLite workflow DB · Relay Tier-1 agent · MCP · OAuth tenancy · offline replay (no API key required) Subscribe for the next lesson: outbox pattern and idempotent writes so replays never double-refund.











