Memory & context
What is Memory?
In agents, memory is stored information that can be retrieved later.
Memory is data. It is not private chain-of-thought. Good memory is inspectable and deletable.
Visual
Memory architecture
Short-term memory lives in context; long-term memory requires a store.
Why it matters
Memory allows agents to retain information across turns and sessions. Without memory, every interaction starts from scratch — the agent cannot learn from past conversations, remember user preferences, or build on previous work.
Memory is data, not reasoning. It should be inspectable, correctable, and deletable. Users must be able to see and control what the agent remembers.
Types of agent memory
Short-term memory holds the current conversation context — tool results, intermediate notes, the active goal. It is discarded when the session ends.
Long-term memory persists across sessions — user preferences, project context, learned patterns. It requires a storage system, a retrieval strategy, and a conflict resolution policy.
Key takeaways
- 1Memory = stored data the agent can retrieve. It is not private reasoning.
- 2Short-term memory is per-session; long-term memory persists.
- 3Memory must be inspectable, correctable, and deletable by users.
Common mistakes
- ✕Storing everything without a retention policy — memory becomes noise.
- ✕Not letting users view, correct, or delete memories.
- ✕Confusing chain-of-thought with memory — they are different mechanisms.
Related terms
Concept neighborhood
Terms linked from Memory in the glossary graph.