Short answer: the 97.8% figure is correct arithmetic on one agent's data, not a mem0 junk rate. It covers one agent, one user and 32 days, with a default extraction prompt fed boot files and cron output. The issue's tables do not fully reconcile, and the mem0 2.2.1 code I ran still lets duplicates pile up once a store grows. Audit your own store before trusting any number.
Updated November 2026. I read the GitHub issue body and its comments on 26 November 2026: the original post in full, the maintainer's closing comment and three later comments in full, and the long fork write-ups more quickly. I then recomputed every number in the issue's tables, downloaded mem0 2.2.1 from PyPI, read its default extraction prompt and add path, and ran that add path against a scripted extractor. Everything labelled "observed" below happened on this machine on that date. Everything labelled "reported" is somebody else's claim that I did not reproduce.
1. What the audit measured, and why it matters
Agent memory layers promise that an agent will remember the right things across sessions. The fear every builder has is the opposite: the store fills with noise, retrieval gets worse, and nobody notices because no error is thrown. In March 2026 one team published the most detailed public look at that failure. Their post, issue #4573 on the mem0 repository, is titled "What we found after auditing 10,134 mem0 entries: 97.8% were junk."
The post has been cited widely since, usually as a single number. I wanted to know what the number stands for, because the decision behind it is a real one: adopt a memory vendor as it ships, or put a quality gate in front of it. If you are building an agent that has to remember things for months, that choice shapes your architecture. It is also the kind of choice I help teams make on my AI agents page.
| Item | What the issue reports (March 2026) |
|---|---|
| Deployment | One AI agent, one human, daily conversations, Qdrant backend |
| Window | 32 days, 23 February to 26 March 2026 |
| Extraction models | gemma2:2b for the first 20 days, Claude Sonnet 4.6 for the last 12, "default prompts" |
| Change late in the window | On day 29 the team merged PR #4302 into its fork (a message filter, an isolation module and default custom instructions) |
| Collection size | 10,134 entries |
| Triage by script | 2,468 removed as hash duplicates, hallucinated clusters and one feedback-loop hallucination |
| Near-duplicate pass | 2,943 flagged by cosine similarity |
| Read one by one | 6,264 entries in eight batches |
| Survivors | 224 of 10,134, of which 186 were rewritten and 38 kept as they were |
The author labelled the entries by hand. There was one reviewer and no second rater, so "junk" here means one person's judgment, applied consistently by the look of the batch tables. I treat the work as careful community research, not an audit by an independent party. The source of this table is the issue itself, and the label for every number in it is "reported".
2. Re-deriving the numbers
I typed the issue's tables into a small ledger script and checked every ratio and every sum. The script has ten unit tests and they pass. Here is what I found.
| Check | Stated | I computed | Result |
|---|---|---|---|
| Headline: (10,134 - 224) / 10,134 | 97.8% | 97.79% | Matches |
| Batch table: 195 keeps out of 6,264 | 96.9% | 96.9% | Matches |
| 224 survivors = 186 rewritten + 38 clean | 224 | 224 | Matches |
| 2,943 near-duplicates as a share of what remained after triage (7,666) | 37.6% | 38.4% | 0.8 points apart |
| 10,134 - 2,468 - 1,572 = entries read | 6,264 | 6,094 | 170 short |
| Phase 2 deleted (6,070) + keeps (195) | 6,264 | 6,265 | Off by one |
| Keeps in batch table vs final survivors | 224 | 195 | 29 not explained |
| Category counts sum to phase 2 deletions | 6,070 | 5,770 | 300 short |
| "% of junk" column sums to 100 | 100% | 95.0% | 5 points unassigned |
| Boot-file share: 3,200 / 6,070 | 52.7% | 52.7% | Matches |
| Boot-file share: 3,200 / category total (5,770) | n/a | 55.5% | Different denominator |
None of these gaps changes the story. The headline checks out, and the largest category is still about half or more of the junk however you divide. What the gaps tell me is how to read the number. The "% of junk" column uses the 6,070 entries deleted in the final reading phase as its denominator, not the 5,770 in the category table, and about 5 percent of those deletions have no category. The 29-entry difference between the batch table's keeps and the final survivors may be entries rescued in the cluster review or rewrites, but the post does not say. The author states in the issue that the full dataset (six correction files, about 100KB) is available. I have not seen it, so I cannot reconcile these differences myself.
There is a more useful way to split the 97.8%. Of the 10,134 entries, 4,040 (2,468 plus 1,572, about 40 percent of the collection) were removed by scripts: exact hashes, cosine clusters and keyword sweeps. The other 6,264 were read by a person, and 96.9% of those were judged junk. These are two different claims. The first says a large share of what mem0 stored in that deployment was mechanically detectable duplication. The second says that after removing that, almost everything left was still not worth keeping. Quoting 97.8% as one number blends them.
3. Did the better model fix it?
The issue says it did not: after the switch to Sonnet "the junk rate barely moved," and "the extraction prompt is the bottleneck, not the model." The batch table has more in it than that sentence. I grouped the batches by model and computed volume per day, because a rate hides how many entries were produced.
| Period | Model | Days | Entries | Entries per day | Keeps | Junk rate | Junk entries per day |
|---|---|---|---|---|---|---|---|
| 23 Feb to 13 Mar | gemma2:2b | 19 | 5,021 | 264 | 129 | 97.4% | 257 |
| 14 to 15 Mar | mixed | 2 | 820 | 410 | 22 | 97.3% | 399 |
| 16 to 26 Mar | Sonnet 4.6 | 11 | 423 | 38 | 44 | 89.6% | 34 |
I read three things in this table. First, the junk rate did move, by about 8 points, though it stayed near 90 percent. Second, entries per day fell by about 85 percent, and junk entries per day fell by about 87 percent, while keeps per day went from 6.8 to 4.0. So the model change cut the noise written far more than the signal (junk per day fell about 87 percent, keeps per day about 41 percent), which is not what "barely moved" suggests. Third, the Sonnet period also contains PR #4302's filter for its last four days (day 29 is 23 March), so the last batch has two changes in it. The issue does not publish how many messages the agent handled per day, so I cannot separate "the model extracts less" from "the agent was quieter." I flag this because the usual lesson drawn from the issue, that a better model does not help, is stronger than the table supports. What the table supports is narrower: a rate near 90 percent is still a problem, and the permissive prompt kept storing system architecture and task state, which the author describes as accurate but not memory.
4. What the maintainers say they fixed, and what they did not
A mem0 contributor closed the issue on 5 June 2026 with a comment listing shipped work: a single-pass ADD-only extraction algorithm (April 2026), hierarchical retrieval with entity linking and deduplication, temporal metadata (June 2026) and recency-weighted ranking (May 2026). Those are vendor-reported. I fetched the token-efficient algorithm post on 26 November 2026. It says the new approach "collapses extraction into a single LLM call that only adds" and lists deduplication as a step after extraction. The page I read did not describe a noise filter or give details of how deduplication works.
The same comment says the thread raised "extraction prompt permissiveness, feedback loop prevention, and identity-aware extraction" as "ongoing areas of improvement." Those three are the issue's top categories: boot-file restating, re-extraction of recalled memories, and an extractor that does not know whether the user is a human or an agent. So the maintainers did not claim to have fixed them when they closed the issue. That is worth knowing, since the issue is closed and a closed issue reads as a fixed one.
5. What I read in mem0 2.2.1
The audit describes a March 2026 deployment on a forked build. The current release is different, so I downloaded mem0ai==2.2.1, the latest on PyPI on 26 November 2026 (uploaded 25 September 2026), and read the default extraction path. The wheel's SHA-256 starts fe91bb91ac89. These are observations about the code, not about how a live model behaves with it.
- The default prompt is long and permissive by design. The additive extraction prompt is about 5,000 words. It tells the model that "Every piece of memorable information must be captured" and to extract from both user and assistant messages.
- It does have exclusions, but they are narrow. It says not to extract greetings and filler, vague assistant characterisations, generic acknowledgments, assistant meta-commentary about its own capabilities, and assistant messages that only echo what the user said. It also says not to infer attributes such as gender or age.
- It names none of the issue's big categories. I searched the prompt for heartbeat, cron, boot, system prompt, tool output, transient, credential, secret and password. None of those appear as an exclusion rule. Custom instructions exist and are described as the highest priority, so the gap is fillable, but you have to fill it.
- Nothing marks recalled memories. The prompt receives "Existing Memories" for deduplication and is told not to extract from them. If your application injects recalled memories into the conversation text, the extractor sees them as ordinary message content. I found no recall marker anywhere in the package.
- Deduplication depends on retrieval depth. Before extraction, the add path fetches the 10 nearest existing memories for the new messages. After extraction, an MD5 hash check runs against those same 10 only.
The last point is the one that matters most, so here is the relevant part of the code (mem0/memory/main.py, 2.2.1, trimmed):
existing_results = self.vector_store.search(
query=parsed_messages, vectors=query_embedding, top_k=10, filters=search_filters)
...
existing_hashes = set()
for mem in existing_results:
h = mem.payload.get("hash")
if h: existing_hashes.add(h)
...
mem_hash = hashlib.md5(text.encode()).hexdigest()
if mem_hash in existing_hashes or mem_hash in seen_hashes:
continue # skipped as a duplicate
A memory that already exists in the store is only recognised as a duplicate if it is among the 10 results returned for the current conversation. The query is the whole conversation text, not each extracted sentence. As the store grows, an old fact can fall out of the top 10 for a long, noisy conversation, and its exact copy is then stored again.
6. The lab: real add() path, scripted extractor
To test that, I ran the real Memory.add() and Memory.search() code from 2.2.1 with two parts replaced: the LLM and the embedder. The stub LLM is a permissive extractor. It returns every sentence of three or more words from the messages it is shown, which is what the issue describes a faithful model doing with a permissive prompt. The stub embedder is a hashed bag of words. Everything else, including retrieval, the hash check, the Qdrant insert and the SQLite history, is mem0's own code. Python 3.12.3, local Qdrant, telemetry off. spaCy and fastembed were not installed, so mem0's keyword search and entity linking were disabled and retrieval was vector-only.
The simulated agent runs 30 sessions. In each, the user states one new, distinct fact. The assistant's message restates six boot-file sentences ("The agent uses she/her pronouns," "The operator prefers Telegram for alerts" and so on) and one cron heartbeat line with a unique timestamp. In the baseline, the application also injects the five best search results as a recalled-memories block, which is the common pattern the issue calls the feedback loop. Each cell is the mean of three seeds.
| What the extractor is shown | Stored | Real facts | Boot-file copies (6 distinct) | Heartbeats | Redundant copies |
|---|---|---|---|---|---|
| User + assistant + recall block (baseline) | 201 | 30 | 141 | 30 | 135 |
| User + assistant, recall block stripped | 139 | 30 | 79 | 30 | 73 |
| User messages only | 30 | 30 | 0 | 0 | 0 |
Read this table with care. The user-only row is clean by construction, because in my scenario all the junk arrives in assistant messages. It shows that dropping the assistant role removes that source, and it costs you any real fact the assistant contributes, which my scenario does not include. The other two rows are the result. The extractor was shown the same six sentences word for word in every session, and mem0 still stored 141 copies of them in the baseline, not 6. Removing the recall block cut that to 79, so the feedback loop made it worse but was not the only cause. Heartbeats were never deduplicated, since each has a unique timestamp, which matches the issue's observation that cron noise needs a filter before extraction and not a hash check after it.
So why do verbatim repeats get through? I ran one change. During add() only, I wrapped the vector store's search so the retrieval depth was 100 instead of 10, and left everything else the same:
orig_search = m.vector_store.search
def widened(*a, **kw):
if flag["on"]: # set only around m.add()
kw["top_k"] = 100
return orig_search(*a, **kw)
m.vector_store.search = widened
| Condition (seed 1, 30 sessions) | Dedup retrieval depth | Stored | Boot-file copies |
|---|---|---|---|
| Baseline | 10 (mem0 default) | 201 | 141 |
| Baseline | 100 | 66 | 6 |
| Recall block stripped | 10 | 139 | 79 |
| Recall block stripped | 100 | 66 | 6 |
With a depth of 100 the store held 66 entries: 30 real facts, 30 heartbeats and exactly 6 boot sentences. The leak started between session 5 and session 8. After session 5 the store had 16 entries and 6 boot copies. After session 8 it had 28 entries and 12 boot copies, and by session 30 it had 201 entries and 141 copies. Once duplicates exist they crowd the top 10 themselves, so the hole widens.
Now the limits, because they are real. My embedder is a toy, and the leak depends on how the query embedding of a whole conversation ranks against single stored sentences. A production embedder will rank differently, and I do not know how much of this you would see. The extractor is a stub that restates everything, not a measurement of what Claude or GPT does with this prompt. The depth-100 run only reached 66 entries, so it does not show that depth 100 scales. What the lab does establish is narrower and checkable: in mem0 2.2.1, duplicate detection is a property of the retrieval depth, so it should be tested on your own embedder and your own store size. If you want a duplicate guarantee, do it with a lookup of the hash against the whole store before insert, not against the top 10.
I also reran the grid with the stub rewording 50 percent of repeated sentences with small variations ("Noted: ...", "... (confirmed)"). Without LLM-style deduplication, the baseline stored 272 entries, 72 of them for the 30 real facts. When I made the stub skip anything it could see among the 10 neighbours, the result went back to 201, the same as the verbatim run. That is the same pattern: an LLM that is shown the neighbour can avoid the duplicate, and one that is not shown it cannot.
7. How to audit your own store
The audit in the issue took a person reading thousands of entries. You do not need that to find out whether you have the problem. This is the procedure I would use, in order.
- Dump the whole store with its source. Export every memory with its creation date, its user or agent id and, if you can, the message that produced it. Without sources you cannot tell an extraction error from an ambiguous conversation.
- Draw a random sample, not the newest entries. The newest are the most likely to be recalled-and-reextracted copies. For a rate within 5 points at 95 percent confidence you need about 385 entries; for 7 points, about 200.
- Label with the issue's ten categories. Boot-file restating, heartbeat or cron noise, system dumps, transient task state, hallucinated profiles, identity confusion, leaked secrets or paths, wrong locations, fabricated lifestyle, other. Keep one reviewer for consistency and have a second one label 50 to measure agreement.
- Report an interval, not a point. If 80 of 200 sampled entries are junk, the Wilson 95% interval is 33.5% to 46.9%, so say "about 40%, between a third and a half."
- Run cheap pre-flags on the full store. Pattern flags catch heartbeat markers, IP addresses and paths, "by Friday" task state and very long entries. Boot-file restating needs the boot files themselves: compare each entry with them by token overlap.
- Replay a duplicate test. Send the same three sentences through your add path 30 times, with realistic other traffic in between, and count copies. That tells you whether your dedup holds at your store size.
The two helpers I used, so you can check them yourself:
def wilson(k, n, z=1.96):
p = k / n
d = 1 + z * z / n
centre = (p + z * z / (2 * n)) / d
half = z * math.sqrt(p * (1 - p) / n + z * z / (4 * n * n)) / d
return centre - half, centre + half
def boot_overlap(entry, boot_lines, threshold=0.8):
return any(jaccard(entry, b) >= threshold for b in boot_lines)
Pre-flags are not labels. A regex for "cron" will flag a legitimate fact about a user's cron job, and a boot-file overlap check will not catch a paraphrase. I use them to order the sample for human review and to size the problem, and I would not publish a junk rate from them.
8. What others have measured
I found three other sources that touch the same question. I label each by how the number was produced, because they are not interchangeable.
| Source | What it reports | Label |
|---|---|---|
| Big Iron guide, reviewed 24 November 2026 | Mem0 2.2.1 on 36 scripted agent turns with 12 real facts: 35 stored and 22 flagged as junk by default (62.9%); 13 stored and none flagged with custom instructions | Reported; synthetic corpus, small, by a third party |
| Comment by a memory-API vendor in the same issue, 16 September 2026 | A write-time gate cut stored junk by 45% at 30 days with no recall loss over 18 runs, and separately reports that extraction lost identifiers on customer-support dialogue (a loyalty number became "has a loyalty number") | Reported by a vendor of a competing product, on simulated dialogue |
| Write-path post, 28 May 2026 | Cites 97.8% low-utility entries in a 3.2-million-entry system | Reported; I did not trace the source and do not rely on it |
The Big Iron result is the closest to mine, since it also used 2.2.1, and it agrees on direction: with defaults on a synthetic stream, more than half of what was stored was flagged, and instructions helped a lot. It also differs from mine in method, since it used an actual model and I used a stub. Its corpus is 36 turns, so it is a smoke test and not a rate. The vendor comment is a useful warning from the other side: extraction can drop the identifiers that make a memory useful, and what survives at 90 days is true facts nobody asks about, which a write-time filter should not touch. Junk rate is only half the measurement. You also need to check that the facts you need are still retrievable.
9. Build a gate or adopt as shipped?
This is my reading, labelled as judgment. If your agent's messages contain only user speech and short assistant replies, mem0's defaults in 2.2.1 are worth a trial, and the lab's user-only row shows that the message role is the first thing to control. I have not tested that case with a live model. If your agent runs on a host that feeds it boot files, heartbeats, cron output, tool results or a recall block, I would not adopt the defaults unmodified. In that case the work is upstream of the memory layer:
- Strip recalled-memory blocks, system prompts and cron output before the add call, in your own code, as two commenters in the thread describe doing.
- Pass an explicit exclusion list through custom instructions, drawn from your own audit categories.
- Check duplicates against the whole store by hash, not against the top 10 neighbours.
- Keep sources with every memory so audits take hours, not weeks.
If you are comparing memory vendors, my post on why the Mem0 and Zep benchmark scores disagree covers the published accuracy claims, and my test of Hermes Agent's file-based memory shows a design with no extraction step at all. To test an agent before you let it write to a store, see how to evaluate an AI agent before deployment. For the same kind of quiet decay in document retrieval, where recall falls as the corpus grows, see my measured lab on enterprise RAG failure modes. If you are weighing the cost of building this properly, the ROI calculator and the AI readiness assessment are the quick way to put numbers on it. If you want a second opinion on a memory design, the booking page is here.
10. What I did not do
- I did not run mem0 with a live LLM. The stub extractor is an assumption, drawn from the issue's description, about what a permissive prompt produces.
- I did not see the audit's dataset, so I cannot say which of the table gaps are typos and which are real.
- I did not test other memory layers. Zep, Letta and others may behave differently, and I make no claim about them.
- My lab is one scenario with one embedder. It shows a mechanism, not a rate. Do not read 141 of 201 as a number about your system.
- I did not verify the maintainers' list of shipped features beyond fetching one of their pages.
Frequently Asked Questions
Is 97.8% the junk rate of mem0?
No. It is one team's hand audit of one agent over 32 days in March 2026, on a forked build with a default prompt, using gemma2:2b and then Claude Sonnet 4.6. The arithmetic checks out (224 survivors of 10,134 is 97.79%), but 4,040 of the entries were removed by scripts and the other 6,264 were read by one reviewer. It shows what can happen when boot files, cron output and recalled memories reach the extractor, not what your own store contains.
Did switching to a better extraction model fix the junk?
Only partly, on the issue's own table. The junk rate fell from 97.4% on gemma2:2b to 89.6% in the Sonnet-only batch, entries per day fell about 85 percent, and keeps per day fell from 6.8 to 4.0. The last batch also includes the team's message filter for four days, and the issue does not publish daily message volume, so the model effect cannot be isolated.
How many memories do I need to review to audit my own store?
About 385 randomly sampled entries gives a 95 percent interval of plus or minus 5 points in the worst case, and about 200 gives plus or minus 7. Sample at random, not from the newest entries, label with one reviewer and report a Wilson interval. For example, 80 junk entries in a sample of 200 is 40 percent, with an interval of 33.5 to 46.9 percent.
Does mem0 2.2.1 deduplicate repeated memories?
It checks an exact MD5 hash, but only against the 10 nearest existing memories retrieved for the current conversation. In my test with a scripted extractor and a toy embedder, six boot-file sentences repeated word for word were stored 141 times across 30 sessions at the default depth, and 6 times at depth 100. Your embedder will behave differently, so replay a duplicate test on your own store.
Ready to Get Started?
Book a free 30-minute discovery call. We'll identify your biggest opportunities and show you exactly what AI automation can do for your business.