02
Workflows and Agents
Where does the harness actually run?
Durable execution, and the real problem of composing a deterministic engine with a non-deterministic model.
6 lessons · 8 checks · 49 min
Why it sits here
Second because a harness without durability is a demo. The moment your process crosses two systems, waits on a human, or touches money, the loop from module 01 needs a substrate that survives process death — and the constraints that substrate imposes reach back and reshape the loop.
Lessons
- One word, two unrelated meaningsThe largest single source of confusion in this space, and it is pure vocabulary.6m
- Three implementation familiesVendors blur this. The difference determines your failure modes, so establish it first about any engine.9m
- Batch orchestration is not durable executionConstantly conflated. The tell is the time axis.6m
- Deterministic engine, non-deterministic modelThe usual framing is wrong, and the correct composition is now a shipped contract rather than an argument.10m
- Human-in-the-loop as a workflow primitiveThe part most teams get structurally wrong. Two of the four steps are ordered for correctness.10m
- The primitives you cannot avoidExactly-once delivery is impossible. Exactly-once effects are achievable. Everything here is machinery for the gap.8m
Pre-reading
12 sources · ~3h if you read all of itRanked, not exhaustive. The lessons stand on their own, so treat the first tier as the genuinely load-bearing sources and the rest as depth when a lesson makes you want it.
Read properly
- Workflow Definition and deterministic constraintsTemporal DocsDeterminism as "the same API calls in the same sequence". The mental model that transfers to every other engine, even if you never touch Temporal.25 min
- Human-in-the-loop with interruptsLangGraph DocsWhole-node re-execution on resume, index-based interrupt matching, and the idempotency warning. Skip it and you will ship duplicate side effects.20 min
- LangGraph's HITL has a double execution problemRaedThe reproducible failure of mixing side-effecting and approval-gated tools in one node, including the part where the audit trail shows one ticket and the backend has two.15 min
- Durable orchestrator code constraintsMicrosoft LearnThe best-enumerated forbidden list anywhere. Language-agnostic in substance despite the .NET framing.20 min
- Issue #8039: durability="sync" orderinglangchain-ai/langgraphSame code, different hardware, different recovery semantics. The best artifact for the claim that checkpointing is not durable execution.10 min
Skim one section
- Service integration patternsAWS Step Functions Developer GuideJump to Wait for a Callback. The operational details most write-ups omit: the one-year ceiling, heartbeat timeouts, a fresh token minted on timeout.15 min
- Durable building blocksRestate DocsAwakeables, workflow promises resolvable once, keyed state. Pair with their human-in-the-loop page.20 min
- Temporal LangGraph integrationTemporal DocsThe deterministic-outer / agentic-inner split as a shipped contract, including the instruction to drop external checkpointers.10 min
- How Inngest functions are executedInngest DocsOne HTTP request per step, memoisation instead of replay. Understanding this family makes the replay family legible.10 min
Citation grade
- You Cannot Have Exactly-Once DeliveryTyler TreatThe argument you need when a vendor claims exactly-once.15 min
- Saga and Transactional OutboxChris Richardson, microservices.ioReference-grade definitions of compensation, the missing-isolation problem, and the dual-write problem.15 min
- Cloud limitsTemporal DocsThe 2 MB / 4 MB / 50 MB / 10,240-event numbers, which decide whether a model output can live in history.5 min