Blog

The anatomy of a memory: facts, preferences and events

Facts are replaced, preferences shape behaviour on almost every turn, and events fade with time. How each kind is written, updated and retrieved, and why mixing them in one vector index causes trouble.

Jonathan Bree

Most of what an agent should remember about a person falls into three kinds: facts, preferences and events. Each is written, updated and retrieved differently. Facts are replaced when they change, preferences shape behaviour on almost every turn, and events are fixed in time and lose relevance as they age. Storing all three as identical chunks in one vector index treats them the same way, and that is where many memory systems start to go wrong.

This explainer walks through each kind with examples, shows how the three move through a memory system from the moment they are said to the moment they are used, and explains the specific problems that appear when they are mixed.

The three kinds at a glance

The distinction is practical rather than academic. It follows the questions a memory system has to answer about any new piece of information: is this still true, does it change how I should behave, and when did it happen?

Aspect

Facts

Preferences

Events

What it is

A statement about the user or their world

How the user wants things done

Something that happened at a point in time

Example

Works at a logistics firm in Leeds

Prefers short answers with no bullet points

Reported a billing error on 14 November

How it changes

Replaced when a newer fact covers it

Strengthened, refined or overridden

Rarely changes; becomes less relevant

How it is retrieved

By subject, when the question touches it

On most turns, by task type

By time and topic, weighted to recent

Typical lifespan

Until superseded

Until the user says otherwise

Weeks to months, unless consolidated

The first two map broadly onto what cognitive science calls semantic memory, and the third onto episodic memory. We compared those two in more depth in episodic vs semantic memory for agents. Separating preferences from facts is a product decision more than a scientific one, and it earns its place because preferences behave so differently at retrieval time.

Facts: replace, do not append

A fact is a claim about the current state of the world: where the user lives, which plan they are on, who their manager is, which programming language their team uses. Facts form the core of a user profile.

Writing. Facts are usually extracted from conversation rather than stated as facts. “I’ll be in the Leeds office on Monday” implies a fact about where the user works. Extraction has to decide which entity the fact is about, which is entity resolution, and whether it duplicates something already known.

Updating. Facts have a single current value. When the user mentions that they moved to the Manchester office, the Leeds fact should be superseded, not kept alongside it. This is what contradiction resolution is for. Keeping the history is useful for audit, but retrieval should return the current value.

Retrieving. Facts are pulled in when the question touches their subject. Exact names and identifiers matter here, so hybrid search that combines keyword and meaning tends to beat pure similarity: a query mentioning “the Acme renewal” should find the fact about Acme’s contract even if the wording differs.

Preferences: the memories that never match the question

A preference describes how the user wants the agent to behave. Writing style, channel, format, schedule, tone, things to avoid. Preferences are what make an assistant feel personal, and they are the core of preference learning.

Writing. Some preferences are explicit (“please stop using bullet points”) and some are inferred from repeated behaviour (the user rewrites every long answer into two sentences). Explicit preferences should carry more weight than inferred ones, and inferred ones should be confirmed by repetition before they are acted on.

Updating. Preferences are refined rather than simply replaced. “Prefers short answers” may later become “prefers short answers, except for code reviews”. A good memory system keeps the scope of a preference rather than flattening it.

Retrieving. This is where preferences differ most. A user asking “draft a reply to Sam about the delay” never mentions that they prefer a warm tone and no exclamation marks. The preference is relevant, and it looks nothing like the query. Similarity search will rarely surface it. Preferences need to be retrieved by task type or loaded as a small standing set on most turns, which is a different access pattern from facts and events.

Events: fixed in time, fading in relevance

An event records something that happened: a call, a purchase, a complaint, a decision, a deadline. Events are the raw material of history, and they make an agent able to say “last time we spoke, you were waiting on legal sign-off”.

Writing. Every event needs a timestamp, ideally the time it happened rather than the time it was recorded. Without one, the agent cannot tell a past launch from an upcoming one.

Updating. Events are mostly append-only. A meeting that happened does not un-happen. What changes is relevance, so events benefit from recency weighting and gradual memory decay. Patterns across events can be consolidated into facts: three cancelled trials in a year becomes a fact worth keeping, and the individual events can fade.

Retrieving. Events are found by topic and by time. “What did we agree last week?” needs a time filter as much as a semantic match. Where timelines matter, a temporal knowledge graph that records when each event occurred and how events relate is worth considering.

Why one vector index causes trouble

The simplest memory design embeds every extracted statement and stores it in one vector database. It works for a demo. In production, treating all three kinds identically produces five specific problems.

Similarity ignores type. A query about booking travel retrieves past trips (events) because they look like the query, and misses the aisle-seat preference and the home airport (a preference and a fact) because they do not. Cosine similarity measures resemblance, and resemblance is a poor proxy for usefulness when the useful memory is a preference.

One update policy breaks one kind. If the index appends, facts accumulate stale values. If it replaces near-duplicates, events that look alike (two separate support calls about the same bug) are wrongly merged.

Time is invisible. Without timestamps used at retrieval, events from a year ago compete equally with yesterday’s.

Consolidation has nothing to work with. Merging three events into one fact requires knowing they are events and what they have in common.

Retention cannot be differentiated. You may want events to expire after 12 months while preferences persist until changed. A single index with no type information makes that policy hard to express. We covered the storage side of this in the case against storing every conversation, and several of the failures in 9 ways agent memory fails trace back to this design. The general argument is in vector database vs memory.

A worked example

A personal AI assistant has been helping a user for four months. Among its memories are a fact (lives in Manchester, nearest airport MAN), two preferences (prefers aisle seats; never books flights before 8am) and several events (flew to Lisbon on 3 May; cancelled a Berlin trip in June; booked a hotel in Rome for a conference in March).

The user writes: “find me flights to Rome for the conference”. With a single similarity index, the top results are the Lisbon flight and the Berlin cancellation, both close to “flights”, and the Rome hotel booking. The assistant offers flights from London, in the window seat it defaulted to, at 6:45am.

With typed memory, the assistant pulls the home airport fact because the request involves an origin, loads the standing travel preferences because the task is a booking, and retrieves the Rome hotel event because it matches the destination and is recent. It proposes flights from Manchester after 8am with an aisle seat, timed to the hotel dates. Same model, same data, different structure.

How the pieces fit together

In a well-designed memory layer, every new statement goes through the same lifecycle. It is extracted from the conversation, classified by kind, attributed to the right entity, checked against existing memories for duplicates and conflicts, stored with a timestamp and a place in the user’s wider ontology, and later retrieved by whichever path suits its kind. Memory consolidation runs in the background, turning repeated events into facts and merging duplicate preferences.

Deciding which statements deserve to enter that lifecycle at all is its own question, which we cover in what an agent should remember.

How Exabase handles the three kinds

Exabase Memory does this classification for you. Send a conversation and the M-1 engine extracts facts, preferences and events automatically, organises them into a tree of concepts and memories that evolves as new information arrives, resolves contradictions when facts change and consolidates related memories over time. The concepts behind this are described in about memories.

Retrieval is hybrid, combining meaning and keywords with a recency bias, and can expand a query into several passes and rerank the results, as covered in retrieving memories. Every memory carries creation and modification timestamps. If you would rather not assemble the prompt yourself, the ask endpoint retrieves the relevant memories and returns an answer in natural language. The engine behind it is described in inside M-1, and the wider approach is on the agent memory solution page.

FAQs

What are the main types of agent memory?

For memories about users, three kinds cover most needs: facts about their world, preferences about how they want things done, and events that happened at a point in time.

What is the difference between a fact and an event in agent memory?

A fact has a current value that can be replaced, such as where someone lives. An event happened at a specific time and stays true, but loses relevance as it ages.

Why are preferences hard to retrieve?

Because they rarely resemble the user’s question. A request to draft an email does not mention the user’s preferred tone, so similarity search seldom finds the preference. Load preferences by task type instead.

Can I store all memories in one vector database?

You can, but it causes problems: stale facts accumulate, similar events get merged, time is ignored and retention cannot differ by kind. Typed memory avoids these.

How should events be turned into long-term knowledge?

Through consolidation. Repeated events, such as several cancelled trials, can become a single fact, and the individual events can fade.

Do events need timestamps?

Yes. Without the time an event occurred, an agent cannot tell past events from upcoming ones or weight recent history appropriately.

How does this relate to episodic and semantic memory?

Facts and preferences are broadly semantic memory and events are episodic memory. Separating preferences out is useful because they are retrieved differently.

Does Exabase classify memories automatically?

Yes. The M-1 engine extracts facts, preferences and events from conversations without extraction logic on your side, and you can also write exact memories directly.

Related pages: Agent memory solution, Procedural memory, Working memory, Entity memory, Chat history vs user profiles, Sales copilots, Exabase vs Cognee, Exabase vs Zep, Agent memory checklist, What should an agent remember?

Cut your token spend and give your agent precise context.

Get started in minutes.

Cut your token spend and give your agent precise context.

Get started in minutes.