Sistava

What is Agent State?

Also called run state, execution state.

Agent state is the information an agent carries through a single run: the conversation so far, intermediate results, the current plan, pending approvals, and progress markers. It lives in the runtime rather than inside the model, because a model holds nothing between calls. Durable state is what lets a run pause, resume, or be inspected after the fact.

State and memory are frequently confused. State is scoped to one run and describes where that run currently is. Memory outlives the run and describes what is known across many of them. A run's state is discarded or archived when it finishes; a memory is deliberately kept. Confusing the two produces agents that either forget mid-task or drag stale run detail into unrelated work.

Implementations typically model state as a structured object updated after each step, holding the message list, tool results, named variables, and a status. Frameworks that treat state as an explicit graph value make it possible to snapshot after each node, branch, and replay. When state is only an ever-growing message list, everything must be re-read to determine anything.

Durability turns a fragile script into a reliable system. If state is checkpointed, a process restart, an expired credential, or a pause for approval does not destroy the work already done. It also makes side effects safe to reason about, because the record shows which actions already executed and must not be repeated on resume.

State is the substrate that orchestration manages, that trajectories are reconstructed from, and that review pauses depend on, since an approval arriving an hour later needs somewhere to return to. Designing state well, with named fields rather than one long transcript, is one of the highest-leverage decisions in an agent implementation.

Key points

In practice

An expense approval agent gets halfway through a run, having read the receipt, extracted the amount, and matched it to a policy. It needs a manager's confirmation, so the run stops. Its state, the receipt data, the extracted amount, the policy match, and the pending question, is written to storage. Two hours later the approval arrives and the run continues from exactly there.

Related terms

Back to the AI Glossary