← All terms

Agent Memory

The mechanisms by which an AI agent retains and reuses information across tasks and sessions.

What Is Agent Memory

Agent memory refers to the mechanisms by which an AI agent retains and reuses information across steps, tasks, or sessions, rather than treating every interaction as if it were starting from nothing. Because most underlying language models have no persistent memory of their own between calls, memory in an agent system is implemented externally, by storing relevant information and feeding it back into the model's context when needed.

Types of Agent Memory

  • Short-term or working memory: the context of the current task, including recent messages, tool results, and intermediate reasoning, usually held within a single session.
  • Long-term memory: information retained across sessions, such as facts about a project, prior decisions, or user preferences, stored outside the model and retrieved when relevant.
  • Episodic memory: records of specific past events or tasks the agent completed, which can be referenced to inform similar future tasks.
  • Persistent workspace state: files, configuration, or data an agent has created or modified, which remain available the next time it runs, functioning as a form of memory even without explicit storage of conversation history.

How Memory Is Implemented

Because language models process a limited amount of context at once, agent memory systems typically summarize, filter, or retrieve only the information relevant to the current task rather than replaying an entire history. Common approaches include storing structured notes or summaries that get reloaded at the start of a session, and retrieval methods that search past data for content related to the current task and insert it into context. The choice of approach affects both the cost of running the agent and how accurately it recalls relevant past information.

Why It Matters

Without memory, an agent restarts from zero on every task, repeating discovery work it has already done and losing track of decisions made earlier in a project. Memory lets an agent build on prior work: recalling that a particular approach failed before, keeping track of a project's conventions, or picking up a long-running task where it left off. This is especially relevant for agents expected to work on the same project over an extended period rather than complete a single isolated request.

Agent Memory vs Persistent Workspace

Agent memory is often discussed in terms of stored text, summaries, or embeddings the agent can retrieve, but a persistent file system attached to an agent serves a related purpose. An agent with a persistent workspace volume, for example, retains its actual files, code, and outputs between tasks, giving it continuity even without a dedicated memory store for conversation history.

Get started

Deploy your fleet.

Put a fleet of sandboxed agents to work on your own infrastructure, provisioned in seconds and watched live from one console.

Get started

Admin-provisioned · Self-host in one command · Your data never leaves your VM