
Picture a brilliant colleague who wakes up every morning with no memory of yesterday. That is most AI agents today and the reason why they need an agent memory.
In this post, let’s talk about:
- π§ Why agents need memory, and the four types that matter
- βοΈ What “managed” memory really means, and where it adds value
- π οΈ How to build it with cloud services or open source
π§ Why agents need memory
Large language models are stateless: every call starts from a blank page. What feels like memory in a chat is the app re-sending the history.
That works for a demo. It breaks in production:
- π Blank slate every session: users re-explain goals, constraints and preferences again and again
- π― No personalization: the agent cannot adapt to a person, a client or a team over time
- π Repeated mistakes: a lesson learned on Monday is gone by Tuesday
- β³ Long-running work breaks: tasks that span days, or hand off between agents, lose their thread
- πΈ Context stuffing is expensive: replaying full history in every prompt costs tokens and latency, and still hits the window limit
The shift: memory turns an agent from a tool you operate into a colleague who compounds.
π§© The four types of agent memory
Borrowed from cognitive science, four types cover most of what agents need:
| Type | What it holds | Purpose | Example |
|---|---|---|---|
| ποΈ Working (short-term) | The live conversation and scratchpad for this task | Stay coherent within a session | The last 20 turns of a support chat |
| π Episodic | Specific past events and interactions | Recall what happened last time | “The refund failed on Tuesday because a document was missing” |
| π Semantic | Distilled facts and preferences | Know who and what | “Prefers a one-page summary every Monday” |
| π§° Procedural | Rules, playbooks and learned ways of working | Do the job better each time | “Reconcile accounts before drafting the report” |
- π§ Rule of thumb: working memory is a notepad; long-term memory is a notebook someone curates
- π Cloud services usually split it in two: short-term holds raw events inside a session, long-term holds extracted insights that survive across sessions
βοΈ What “managed” memory really means
Managed agent memory is a service that runs the memory lifecycle for you, so your team builds the agent, not the plumbing.

Your agent decides what matters. The service handles extraction, storage and governance.
Nuances worth knowing before you commit:
- π A lifecycle, not a database: write, extract, consolidate, retrieve and forget are all part of the job
- π‘οΈ Scope is a security boundary: Databricks advises setting scope in trusted code and never letting the model choose whose memory to read or write
- π§Ή Conflicts need resolving: when a preference changes, old and new facts must be reconciled; one community evaluation found Mem0 kept both versions, so test this
- β±οΈ Often asynchronous: AWS extracts long-term memory in the background, so a fact from this turn may not be recallable instantly
- π¦ Portability varies: Claude Managed Agents stores memories as files you can export and manage through an API; other services use their own stores
- π° Cost has two parts: extraction runs models on writes, plus storage; Databricks bills the underlying Lakebase instance during its preview
π How managed memory adds value
- β‘ Faster to production: no extraction pipelines, indexes or scaling to build; one adopter said it let them stop building memory infrastructure and focus on the product
- π― Better outcomes: Anthropic reports that Rakuten’s agents saw 97% fewer first-pass errors, 27% lower cost and 34% lower latency with memory; Wisedocs reports 30% faster document verification
- π‘οΈ Governance built in: scoped permissions, audit logs and encryption come standard; AWS supports customer-managed encryption keys and Databricks applies Unity Catalog governance
- π€ Shared learning: one store can serve several agents with different access scopes, so lessons compound across the fleet
- π§βπΌ Personalization at scale: each user or client gets a memory that stays isolated from everyone else’s
β οΈ Reality check: these figures are vendor-reported on specific workloads. Benchmark on your own tasks before you plan around them.
π How agent memory works under the hood

Writes land as raw events. A background step distils them into durable memories. Reads pull back only the top matches, so each new session starts with context instead of a blank page.
- π§ͺ What gets extracted is configurable: AWS AgentCore Memory ships built-in strategies for summaries, facts and user preferences, and lets you supply custom prompts and models
- ποΈ Everything is keyed: memories are organized by user, agent and session so retrieval stays fast and isolated
βοΈ Build it on cloud services
Here are a few managed memory options that are available today.Β All three are young, so check current maturity before you commit.
| Service | How memory is modeled | Standout | Watch-outs |
|---|---|---|---|
| π§ AWS Bedrock AgentCore Memory | Short-term events by actor and session; long-term records from built-in or custom strategies | Encrypted at rest and in transit, optional customer-managed keys, raw events kept up to 365 days | Long-term extraction runs asynchronously |
| π« Claude Managed Agents memory (public beta) | Memories stored as files mounted on the agent’s filesystem | Exportable, managed through an API, audit log shows which agent and session wrote each memory | Public beta; built for Managed Agents |
| π₯ Databricks managed agent memory (beta) | Memory stores as Unity Catalog securables, isolated by scope | Works with agents on any framework; inherits Unity Catalog governance, access control and lineage | Long-term only, so pair it with session history; the store is the security boundary |
How to choose:
- ποΈ Already on AWS? AgentCore Memory fits natively next to your runtime and observability
- ποΈ Data estate on Databricks? Memory sits under the same governance as your tables
- π€ Building on Claude Managed Agents? Memory is built in and file-based, so it is easy to inspect and export
π οΈ Build it with open source
Three projects lead the field, and each stores memory differently:
| Tool | Memory model | Best for | Watch-outs |
|---|---|---|---|
| 𧬠Mem0 | Vector memory layer with simple add and search calls, framework-agnostic | Quick personalization for an existing agent | Model calls on writes add latency and cost; test how it handles changed facts |
| π§ Letta (formerly MemGPT) | Agent-managed memory blocks: the agent edits its own memory | Long-lived, stateful agents that curate their own context | Closer to an agent runtime than a memory API |
| πΈοΈ Zep / Graphiti | Temporal knowledge graph of entities and relationships | Facts that change over time, relationship-heavy domains | Needs a graph database; new facts may not be searchable instantly |
- π§± You own the plumbing: hosting, scaling, backups, access control and observability sit with your team
- π Flexible deployment: each project can be self-hosted, and each also offers a hosted plan
- π§ͺ Test before you choose: community harnesses such as memeval and MemJudge compare providers side by side on recall, relevance and cost
π§ A six-step playbook for teams
- π― Start from the job, not the tech: list what the agent must remember, and what it must forget
- π§© Choose memory types on purpose: working memory for the session, semantic for facts, episodic for history, procedural for lessons
- π Design scope and access first: per user, per agent or shared, set in trusted code and never by the model
- π Prototype on a managed service: get a baseline in days, and keep memory behind a thin interface so you can swap it later
- π Measure on your own tasks: recall accuracy, wrong-memory rate, conflict handling, latency and cost per write
- π§Ή Plan the lifecycle: retention, deletion on request, review of what agents write, and a path for humans to correct memories
π A practical path: start managed to learn fast, then move to open source only if control or cost demands it.
π¬ Your turn
Agents that remember are agents that improve. π±
What is the one thing you wish your agents never forgot about your customers?
Disclaimer: All contents of this post are my personal opinion and does not reflect that of my employer