mlsanityData to 14 Oct 2026

Beyond the Context Window: A Cost-Performance Analysis of Fact-Based Memory vs. Long-Context LLMs for Persistent Agents

arXiv 2603.04814 ↗First posted 5 Mar 2026cs.CLcited by 15

On the map: LLM agents and tool use → Agent memory systems

Abstract (arXiv)

Persistent conversational AI systems face a choice between passing full conversation histories to a long-context large language model (LLM) and maintaining a dedicated memory system that extracts and retrieves structured facts. We compare a fact-based memory system built on the Mem0 framework against long-context LLM inference on three memory-centric benchmarks - LongMemEval, LoCoMo, and PersonaMemv2 - and evaluate both architectures on accuracy and cumulative API cost. Long-context GPT-5-mini achieves higher factual recall on LongMemEval and LoCoMo, while the memory system is competitive on PersonaMemv2, where persona consistency depends on stable, factual attributes suited to flat-typed extraction. We construct a cost model that incorporates prompt caching and show that the two architectures have structurally different cost profiles: long-context inference incurs a per-turn charge that grows with context length even under caching, while the memory system's per-turn read cost remains roughly fixed after a one-time write phase. At a context length of 100k tokens, the memory system becomes cheaper after approximately ten interaction turns, with the break-even point decreasing as context length grows. These results characterize the accuracy-cost trade-off between the two approaches and provide a concrete criterion for selecting between them in production deployments.

Key facts. Cited by 15 papers in the map (data through 14 Oct 2026). Placed in Agent memory systems, one of 16 directions in LLM agents and tool use. Builds on 21 of its 31 references that are in the map. First posted on arXiv 5 Mar 2026.

Builds on

21 of 31 references.

Closest ancestors · 5

Same direction, newest first

  1. 2026Beyond Dialogue Time: Temporal Semantic Memory for Personalized LLM Agents12 Jan
  2. 2025PersonaMem-v2: Towards Personalized Intelligence via Learning Implicit User Personas and Agentic Memory7 Dec
  3. 2025A-MEM: Agentic Memory for LLM Agents17 Feb
  4. 2025Zep: A Temporal Knowledge Graph Architecture for Agent Memory20 Jan
  5. 2024Evaluating Very Long-Term Conversational Memory of LLM Agents27 Feb

Other references · 16

  1. 2020Retrieval-Augmented Generation for Knowledge-Intensive NLP Taskscited by 9,297
  2. 2025Gemini 2.5: Pushing the Frontier with Advanced Reasoning, Multimodality, Long Context, and Next Generation Agentic Capabilitiescited by 3,796
  3. 2020Longformer: The Long-Document Transformercited by 3,413
  4. 2023LongBench: A Bilingual, Multitask Benchmark for Long Context Understandingcited by 1,417
  5. 2024RULER: What's the Real Context Size of Your Long-Context Language Models?cited by 1,346
  6. 2023FrugalGPT: How to Use Large Language Models While Reducing Cost and Improving Performancecited by 853
  7. 2023Extending Context Window of Large Language Models via Positional Interpolationcited by 740
  8. 2024LongMemEval: Benchmarking Chat Assistants on Long-Term Interactive Memorycited by 707
  9. 2024Justice or Prejudice? Quantifying Biases in LLM-as-a-Judgecited by 368
  10. 2024∞Bench: Extending Long Context Evaluation Beyond 100K Tokenscited by 367
  11. 2024Humans or LLMs as the Judge? A Study on Judgement Biasescited by 323
  12. 2023Prompt Cache: Modular Attention Reuse for Low-Latency Inferencecited by 268
4 more
  1. 2021LongT5: Efficient Text-To-Text Transformer for Long Sequencescited by 232
  2. 2026EverMemOS: A Self-Organizing Memory Operating System for Structured Long-Horizon Reasoningcited by 54
  3. 2024Don't Do RAG: When Cache-Augmented Generation is All You Need for Knowledge Taskscited by 38
  4. 2025Tail-Optimized Caching for LLM Inferencecited by 2

Built on by

Cited by year (2026 to 14 Oct)

Citing papers per year: 2026: 15.

15 papers.

Sort:

By area:

Similar, not cited

Close in wording, no citation either way

  1. 2026MemMachine: A Ground-Truth-Preserving Memory System for Personalized AI Agents
  2. 2026Supersede: Diagnosing and Training the Memory-Update Gap in LLM Agents
  3. 2026Memori: A Persistent Memory Layer for Efficient, Context-Aware LLM Agents
  4. 2026AgentMemBench: A Systematic Benchmark for Evaluating Long-Term Memory Management Strategies in Conversational AI Agents
  5. 2025Mem0: Building Production-Ready AI Agents with Scalable Long-Term Memory
  6. 2026MemRefine: LLM-Guided Compression for Long-Term Agent Memory
  7. 2026MemOps: Benchmarking Lifecycle Memory Operations in Long-Horizon Conversations
  8. 2026CALMem : Application-Layer Dual Memory for Conversational AI ↗