---
title: "Agent runtime state · stateful vs stateless, durable execution engines · Agent Fieldbook"
url: https://agentfieldbook.org/design/runtime/
description: "Statefulness is one axis, not two: memory (what an agent knows) at one end, runtime durability (where it is in a task) at the other. The statefulness ladder, how much state real task types need, and the durable-execution engines (Temporal, AWS Step Functions, LangGraph, Cloudflare, Letta) grouped by mechanism."
section: "Design · Runtime"
source: Agent Fieldbook — generated from the published page
---

# Stateful vs stateless

Statefulness is one axis, not two: memory (what an agent knows) at one end, runtime durability (where it is in a task) at the other. The ladder places every mechanism on that spine; the table shows how much state real task types actually need; the catalogue is the durable-execution engines, by mechanism.

## The statefulness ladder · 8 mechanisms

## memory both runtime dot fill = engines catalogued

## How much state does the task need? · by task type

| Task | Typical run | State need | If stateless, you lose… | What durable buys | Examples |
| --- | --- | --- | --- | --- | --- |
| Chat Q&A | seconds | Session | the thread across turns, every message starts cold, no follow-ups, no personalisation | conversation recall and personalisation within the session | ChatGPT Agent, Claude Agent, Gemini Agent |
| Coding (agentic) | minutes to hours | Durable | dies mid-task, redoes finished work, drops uncommitted edits on any crash | resume-after-failure, checkpointed multi-file edits, long test-and-fix loops that survive restarts | Devin, Cursor |
| Design activity | minutes, iterative | Session to long-term | the brand rules and prior decisions between iterations: each pass forgets the last | recall of prior decisions, brand constraints and the iteration history | v0 |
| Research (deep) | minutes to hours | Durable + long-term | truncates on long runs, cannot accumulate findings across many sources, restarts from zero on failure | fan-out across sources, accumulation of findings, resume of long-running jobs | OpenAI Deep Research, Perplexity Deep Research, Gemini Deep Research |
| Ops / automation | seconds to days | Durable (suspend/resume) | cannot wait for a human approval or an external event without holding a process open | parks for human sign-off or an external signal, then resumes exactly where it left off | Lindy |

## Durable-execution engines · 14 · by mechanism

## Session state · 1

- [↗ T1](https://openai.github.io/openai-agents-python/sessions/)

## Stateful actor + hibernate · 1

- [↗ T1](https://developers.cloudflare.com/durable-objects/)

## Checkpoint / snapshot · 2

- [↗ T1](https://docs.langchain.com/oss/javascript/langgraph/checkpointers)

- [↗ T1](https://docs.letta.com/concepts/letta)

## Event-replay · 2

- [↗ T1](https://docs.temporal.io/workflow-execution/event)

- [↗ T1](https://docs.restate.dev/)

## Managed state machine · 2

- [↗ T1](https://docs.aws.amazon.com/step-functions/latest/dg/welcome.html)

- [↗ T1](https://docs.cloud.google.com/workflows/docs/overview)

## Durable functions · 6

- [↗ T1](https://learn.microsoft.com/en-us/azure/durable-task/durable-functions/durable-functions-overview)

- [↗ T1](https://developers.cloudflare.com/workflows/)

- [↗ T1](https://www.inngest.com/docs/learn/how-functions-are-executed)

- [↗ T1](https://docs.dbos.dev/)

- [↗ T1](https://docs.hatchet.run/home)

- [↗ T1](https://trigger.dev/docs/how-it-works)

## Field notes

One axis: memory at one end, runtime durability at the other

Most agents follow a standard workflow pattern, and they hit the same constraints workflow engines were built for: a long-running process has to survive a crash, retry one step without repeating the whole run, and know where it got to.

None of this is magic. It is the logic, branching and system architecture that CRM automation and engineering pipelines have used for years, pointed at agents. Expect durable execution to become an assumed part of the stack rather than a choice.

- [Brandon Chaplin](https://www.linkedin.com/in/brandon-chaplin-digital-marketing-strategist)

## Common questions

### What is durable execution?

A way of running a workflow so it survives crashes, restarts and long waits. The engine records progress as it goes, so if the process dies halfway through, the work resumes from the last recorded point instead of starting again [(Temporal)](https://docs.temporal.io/).

### What is the difference between a stateful and a stateless agent?

A stateless agent starts cold on every call and loses everything in flight if it crashes. A stateful agent persists something between calls: either what it knows, which is memory, or where it is in a task, which is runtime state. Most agents need the first; long-running ones need both.

### Why do long-running agents need a workflow engine?

Because a task that runs for hours will hit a crash, a rate limit, or a wait for someone to approve something. Without persisted progress, any of those means starting from the top. Temporal, AWS Step Functions, Azure Durable Functions, Cloudflare Workflows and LangGraph all store that progress for you.

### What is a checkpoint in an agent workflow?

A saved snapshot of the agent's state at a point in the run, restored after a failure. The alternative is event replay: keep a log of everything that happened and rebuild the state by replaying it. Checkpoints recover faster; replay is slower but gives a full audit trail.

### How much state does an agent actually need?

Less than most teams assume. A question-and-answer bot needs only the current session. A coding agent needs progress it can resume. A multi-hour research run needs a durable journal. Start with the lightest option and move up when a real failure forces it.

### Is agent memory the same as runtime state?

No. Memory is what the agent knows: facts, past conversations, preferences. Runtime state is where it is in a task: which step finished, which is still pending. They are usually stored in different places and you can lose one while keeping the other.

## Next in the learning path

- [Topologies The shape state persists across](https://agentfieldbook.org/design/topologies/)

- [Orchestration The other agent control plane](https://agentfieldbook.org/design/orchestration/)

- [Architectures Durable execution in real systems](https://agentfieldbook.org/design/architectures/)

- [Memory providers The memory end of the same axis](https://agentfieldbook.org/memory/providers/)

- [Memory types What an agent knows vs where it is](https://agentfieldbook.org/memory/types/)
