Providers & requests

Stateless

Stateless means the model API keeps no memory between requests. Each call starts blank, so every request must carry all the context the model needs. This is foundational to how agents are built.

James Phoenix
Understanding Data Updated July 2, 2026

The single most important thing to understand about a model API is that it is stateless. The provider keeps no memory of your last request. Each call is processed in isolation, as if the model had never spoken to you before. There is no server-side conversation quietly accumulating on their end.

Every request starts from zero

This runs against the intuition a chat interface gives you. It feels like the model remembers the conversation, but it does not. What actually happens is that the whole history gets re-sent as context on every request. The "memory" you experience is the client resubmitting everything each time, not the model recalling anything.

Why this shapes everything downstream

Once statelessness clicks, a lot of agent design stops being mysterious:

  • Context is mandatory, not optional. If a fact is not in this request, the model has no way to know it. Nothing carries over on its own.
  • History has a running cost. Because a session re-sends its whole transcript every time, long conversations get steadily more expensive and slower.
  • Memory has to be built. Anything that feels like the model "remembering" across sessions is machinery someone wrote to store and reload context. The model itself contributes nothing durable.
Note
Statelessness is why the stateful parts of an agent, the history, the memory, the session, all live in the harness and never in the model. The model is a pure function: context in, prediction out.

Related terms

Building with AI agents?

This dictionary is part of how I think about agentic engineering. If you want the same thinking applied to your codebase, that is what I do.

See how I can help