Pick the right choice between rolling summary and vector store memory for cross-session continuity
A vector-store memory keyed on user_id is the right shape for cross-session continuity because retrieval scales with relevance per turn, while a rolling summary grows monotonically across sessions and either bloats
Think about a doctor's office. Imagine a doctor who, every time you visit, reads aloud a single growing summary paragraph of every past visit. That paragraph gets longer and blurrier every visit, and most of it has nothing to do with why you came in today. Now imagine a doctor with a filing cabinet of small notes per visit. When you walk in, they pull only the notes relevant to today's complaint. The cabinet keeps growing, but the doctor only reads what matters right now. The cabinet is the vector-store memory; the growing paragraph is the rolling summary. For someone you see across many visits, the cabinet wins.
Concept explanation~2 min read
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Concept explanation~2 min read
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Cross-session continuity is the property of an assistant that remembers what the user said in previous conversations when the user comes back later. It is one of the harder problems in chat-system design because the right architectural shape is not the same as the shape for within-session continuity. A pattern that works well during a single conversation (rolling summary) breaks across many sessions, and a pattern that handles many sessions gracefully (vector store of facts) is overkill for a single session.
This deep dive walks through why retrieval per turn is the right answer for cross-session memory, why a rolling summary breaks across sessions, and how production stacks compose the two patterns to handle both time scales.
Why cross-session is a retrieval problem, not a summarization problem
The key structural property of cross-session data is that the relevance distribution over stored facts is heavily skewed per turn. A user accumulates hundreds or thousands of facts over months or years of usage with an assistant: preferences (vegetarian, prefers metric units), identifiers (account numbers, project names), decisions (chose framework A over B), constraints (deadline next month, budget figure). Any single new conversation relates to maybe a handful of those facts.
A rolling summary forces the assistant to carry all of those facts (or a compressed shadow of them) on every call. The prompt pays for everything regardless of relevance. A retrieval-based architecture pays only for what is relevant to the current turn.
This difference is not a small constant factor. For a user with 500 stored facts and a typical retrieval top-K of 5, the relevance-matched architecture loads 1 percent of the user's memory on any given turn. The rolling summary loads all of it, compressed into a shape that scores poorly on every individual fact's recall.
The framing matters because it points at the correct primitive. Cross-session memory is not "compress everything the user ever said into a paragraph"; it is "index everything the user ever said, retrieve only what matters now." Recognizing this is the first step to picking the right architecture.
Situations where this technique stops working.
2–4 min · Everything important, quickly.
Real products, models, and research that use this idea.
- Mem0 is the canonical 2026 implementation of vector store of facts for cross-session memory.
- Zep maintains a temporal knowledge graph that combines vector retrieval with explicit contradiction handling.
What an interviewer would ask next. Try answering before peeking at the approach.
QHow does the vector store handle the case where a user's preference changes (e.g., 'I am no longer vegetarian')?
Fact extraction detects the new statement as a candidate fact and compares it to existing facts in the store. When a conflict is detected (same topic, contradictory polarity), the older fact is either overwritten, marked superseded with a timestamp, or kept as historical context with the newer one taking precedence. Mem0 and Zep both implement variants of this contradiction-resolution step.
Red flags & common mistakes
The phrases that signal junior thinking. Click to expand.
Red flags & common mistakes
The phrases that signal junior thinking. Click to expand.
Picking a rolling summary because it preserves "everything" across sessions. The summary actually loses fidelity at every session boundary and never trims, so it eventually becomes both bloated and lossy.
60 second bullets to scan on the way to the call.
Explain why cross-session continuity is a retrieval problem more than a summarization problem
Identify the monotonic growth failure of a cross-session rolling summary
Primary sources. Browse if you want the original framing.
Same topic, related formats. Practice these next.