Part 1 of 4 · 1 min read
Overview
Agent runs are long, cost real money per step and touch the outside world. Restarting wastes spend and repeats charges and emails. The project criterion for this level is "a run survives a worker being killed mid-task"; this module is the mechanism. Interviewers ask "what happens if the worker dies halfway through a 20-minute agent run?"
About the example, and what is real
Real: the journal, replay, structure-hash check, determinism check, durable wait, saga compensation, idempotent effects and the 18 test cases in code/mini-durable. Assumed: step costs (1, 3, 2, 2), 8 percent crash chance per step with before, after-effect and after-journal positions chosen uniformly, idempotency keys honoured by the outside world. Not real: no durable store (a list in memory), no real worker process kill, no Temporal or LangGraph, no concurrency, no history versioning.