Blog
What should an agent remember? A decision framework
Three questions decide what an agent should keep: how long it stays useful, how sensitive it is and how often it is reused. Worked examples included.

Jonathan Bree
An agent should remember information that will still be true next time, is safe to hold, and is likely to come up again. Everything else can be used in the moment and let go. Those three questions (shelf life, sensitivity and reuse) are enough to sort most of what a user says into one of four outcomes: store it as durable memory, keep it for the current task only, store it under tighter controls, or leave it out altogether.
Teams that skip this step tend to swing between two failure modes. Some store every message and end up with a memory layer full of noise, a problem we cover in the case against storing every conversation. Others store almost nothing and ship an assistant that asks the same questions every week. This post sets out the framework, shows how it plays out for support, sales and personal assistants, and covers the edge cases that make the choice harder than it looks.
Why the question needs a framework
Most agent memory systems can extract facts automatically, so the technical barrier to storing things is low. The harder part is deciding which of those facts deserve a place in long-term memory. Every stored item has a cost. It competes for space in the slice of memory retrieved on each turn, it can go out of date and mislead the model into a hallucination, and it is user data that someone may later ask you to find or delete.
That cost is worth paying when the item changes what the agent does next time. A customer’s plan tier changes which answers are correct. A prospect’s budget changes which proposal makes sense. A user’s preference for short replies changes the shape of every response. A remark about the weather changes nothing. A framework turns those intuitions into a repeatable decision that product, engineering and legal can agree on, which matters because memory is a product decision as much as an infrastructure one.
The three questions
How long will it stay useful?
Shelf life is the first filter. Some information is useful for minutes: the error message a user just pasted, the draft they are editing, the step they are on in a setup flow. That belongs in the context window or the agent’s working memory for the task, and it can be dropped when the task ends. Other information stays true for months or years, such as a company’s industry, a user’s role or a dietary requirement. That is the material long-term memory is for.
Between those sits information that is true for a while and then expires: an open support ticket, a deal stage, a trip next week. It is worth storing as an episodic memory with a date attached, so the agent can tell a current fact from a stale one. Recency weighting at retrieval and memory decay over time both help, and we argue for deliberate expiry in forgetting is a feature.
How sensitive is it?
Sensitivity decides how carefully something is held, and sometimes whether it is held at all. Health details, financial information, information about children, credentials and anything a user shares about a third party all carry more risk than a preferred meeting time. Sensitive information can still belong in memory; a healthcare agent is of little use if it cannot remember a patient’s allergies. It does mean the information should be scoped tightly, kept only as long as needed and easy to find when someone asks for it to be removed.
A practical test is to ask how you would explain the stored item to the user if they saw it. If the answer is awkward, the agent probably should not be keeping it, or should ask first. Requests to delete stored data are routine under the right to be forgotten, so any memory design should make deletion a single, targeted operation rather than a search through transcripts. Your agent’s memory is a liability until you can audit it goes further into the governance side, and data retention covers how long to keep what you store.
How often will it be reused?
Reuse is the tiebreaker. A durable, harmless fact that the agent will never need again still adds noise to retrieval. A fact that bears on most conversations, such as the user’s timezone, language or role, earns its place many times over. Preferences tend to score highest here because they shape almost every response, which is why preference learning is often the first memory feature teams ship. Importance scoring is the automated version of this question: the system estimates how much an item is likely to matter and ranks or prunes accordingly.
Putting the answers together
The three answers combine into a small set of outcomes. The table below is a starting point that most teams adjust for their own product. For how facts, preferences and events behave once they are stored, see the anatomy of a memory.
Shelf life | Sensitivity | Reuse | Default outcome |
|---|---|---|---|
Long | Low | High | Store as durable memory |
Long | Low | Low | Store only if cheap to keep and easy to prune |
Short | Any | Any | Keep for the current task, then drop |
Long or medium | High | High | Store with tight scope, clear retention and easy deletion |
Any | High | Low | Leave it out, or ask the user first |
Two points are worth stressing. The outcome is a default that the user’s explicit request can override: if someone says “remember this”, store it, and if they say “forget that”, delete it. And the questions apply to each item, so a single support chat can contain a durable fact, a temporary one and a sensitive one, each treated on its own terms.
Worked example: a customer support agent
A customer support agent for a SaaS product handles a ticket in which the customer says they are on the Team plan, that they manage billing for three workspaces, that the CSV export has failed twice today, that they prefer email to chat, and that they are stressed because their manager is waiting on the report.
The plan tier and the three workspaces are long-lived, low in sensitivity and relevant to almost every future ticket, so they become durable memories. The email preference is the same. The failed export is medium-lived: it should be stored as an event with a date, so the next conversation starts with the open issue in view, and it should stop shaping answers once the issue is resolved. The comment about the manager helps with tone in the moment, but it is personal, will not be true next week and gives little to a future conversation. It stays in the current session.
When the customer upgrades to Enterprise a month later, the plan memory should be replaced rather than joined by a second one. This is where contradiction resolution matters: without it, the agent keeps retrieving both plans and has to guess, a slow slide known as memory drift. What support agents get wrong without memory covers the wider failure pattern.
Worked example: a sales copilot
A sales copilot listens to calls and reads emails about a prospect. In one call the buyer mentions their budget range, that they are evaluating two competitors, that legal review takes about six weeks, that the CFO signs off on anything above a set amount, and that they are on holiday for the first two weeks of August.
Budget, competitors, the legal timeline and the approval threshold are all worth keeping. They stay true for the length of the deal, they are commercially sensitive in the way any CRM record is, and they shape every later conversation. The holiday is short-lived but useful for planning follow-ups, so it is stored with dates and allowed to expire. Personal details from small talk need more care: a note that the buyer prefers morning calls is a reasonable preference, while details about their family are not the copilot’s business unless the buyer has asked for them to be remembered.
The sales case also shows why scoping matters. Notes about one account should never surface in a conversation about another, and notes from one rep’s deals may or may not be visible to colleagues. The choice between shared and private memory is a design decision in its own right, and memory isolation explains the mechanics. Our sales memory copilot example shows one way to structure it.
Worked example: a personal assistant
A personal AI assistant sees the widest range of information, which is where the framework earns its keep. Over a week a user might mention that they are vegetarian, that they live in Lisbon, that their sister’s birthday is on 3 May, that they have a dentist appointment on Thursday, that they are anxious about a job interview and that they never want meetings before 10am.
The dietary requirement, home city and meeting preference are long-lived, frequently reused and low to moderate in sensitivity. They are what makes an assistant feel as though it knows the user, and they form the core of a useful user profile and the personalisation built on it. The sister’s birthday is long-lived and reused once a year, which is enough to keep. The dentist appointment is an event with a short shelf life. The interview anxiety is the hardest call: it is sensitive and short-lived, but the user may well want the assistant to check in afterwards. The safest default is to use it in the moment and ask before storing it.
Personal assistants also accumulate information about other people. A note that a colleague is difficult to work with is a statement about a third party who never agreed to be remembered. Keep such notes factual, tied to the user’s own needs and easy to remove. Our memory-powered personal assistant example shows a working setup.
Edge cases that change the answer
Inferred versus stated information
A user who says “I’m vegetarian” has stated a fact. A user who orders three vegetarian meals has given the agent grounds to infer one. Inferences are useful but less certain, so it helps to record where a memory came from and to let stated facts override inferred ones. An agent that acts confidently on a wrong inference is more irritating than one that asks.
Information that belongs in documents
Some information is better kept in a knowledge base than in memory. Product documentation, policies and price lists are shared across users and change on their own schedule, so they belong in documents retrieved with RAG. Memory is for what the agent learns about a particular user or account. The memory vs knowledge base entry sets out the boundary, and RAG vs agent memory covers the retrieval side.
Instructions hidden in user content
Anything a user pastes in, such as an email or a web page, can contain text that reads like an instruction. Storing it as a memory lets that text influence future sessions, a risk known as memory poisoning. Extract facts from untrusted content with care, and avoid storing instructions that did not come from the user directly.
Summaries in place of facts
It is tempting to store a summary of each conversation and call it memory. Summaries are written before you know what the next question will be, so they keep the gist and drop the specifics. Storing discrete facts keeps each one individually retrievable and replaceable, which is the argument in summarisation vs memory.
Where Exabase fits
Exabase provides the memory infrastructure; the decision about what to keep stays with your product. Exabase Memory extracts facts, preferences and events automatically from conversations sent with source: 'text', which suits the long-lived, low-risk material that makes up most of a memory store. When you want precise control, for instance after a user says “remember this”, you can write a memory directly with infer: false so the exact text is stored. Memories that the system should never modify, consolidate or delete can be marked immutable.
Each memory carries creation and modification timestamps, retrieval is hybrid semantic and keyword search with a bias towards recent facts, and the M-1 engine resolves contradictions as new information arrives. Memories are scoped to a Base, so each user, account or project keeps its own, as described in the memory scoping guide. Deleting a single memory is one call to the memories API, and Workers can create, update and resolve memories on a schedule if you want stale items reviewed automatically. Data is encrypted at rest with AES-256 and in transit. Whether a given design meets your own compliance obligations is a question for your legal and engineering review.
The agent memory solution page covers the patterns teams use, and the production checklist for agent memory lists what to check before launch. If you are comparing providers, best agent memory platforms and Exabase vs Mem0 set out the options.
FAQs
What should an AI agent remember?
Information that will stay true for a while, is safe to hold and is likely to matter again: a user’s role, plan, preferences and open issues, for example. Small talk, one-off details and sensitive remarks that will not help a future conversation can be used in the moment and left out of long-term memory.
How do I decide whether something is worth storing?
Ask three questions about each item: how long it will stay useful, how sensitive it is and how often it will be reused. Long-lived, low-risk, frequently reused items are stored; short-lived items stay in the session; sensitive ones are stored only with tight scope and clear retention, or after asking the user.
Should an agent store every conversation?
Usually not. Full transcripts make retrieval noisier, cost more to store and are harder to audit or delete from. Extracting the facts worth keeping and letting the rest go tends to give better answers for less.
How should an agent handle sensitive information?
Use it when the task needs it, store it only when it will help future conversations, and scope it tightly to the user or account it belongs to. Make deletion a single operation, and ask before storing anything the user might be surprised to find was kept.
What is the difference between short-term and long-term agent memory?
Short-term memory holds what the agent needs for the current task and is discarded afterwards. Long-term memory persists across sessions and holds facts, preferences and events that stay useful over time.
What happens when a stored fact changes?
The new fact should replace the old one, with the change recorded. Without contradiction resolution, retrieval returns both versions and the model has to guess which is current. Exabase handles this automatically when new information is added.
Should users be able to see and delete what an agent remembers?
Yes, in most products. Users trust an assistant more when they can check what it knows, and deletion requests are routine. Storing discrete, timestamped memories per user makes both straightforward.
Can the framework be automated?
Partly. Automatic extraction handles the common case of long-lived, low-risk facts, and importance scoring and recency weighting handle reuse and shelf life at retrieval time. Sensitivity rules usually need to be written by your team, because they depend on your users and your obligations.
Related pages: Agent memory solution, The anatomy of a memory, Forgetting is a feature, A production checklist for agent memory, Shared vs private memory, Agent memory, Long-term memory, Customer support agents, Exabase vs Mem0, Context engineering is backend engineering, Bigger context windows are making agents worse, Prompt caching won’t save you
Other blog posts:

Similarity isn’t relevance

RAG isn’t dead. Naive RAG is

A context budget template for AI agents

Where your tokens go: anatomy of a 15,000-token request

Cheap models with good context beat frontier models

Why “just use long context” fails in production

Prompt caching won’t save you

Your LLM bill is a retrieval problem