动态记忆让检索增强生成更高效,自动记住重要信息、遗忘不常用内容。
A Dynamic Retrieval-Augmented Generation System with Selective Memory and Remembrance
- 用可调节的记忆机制替代静态索引,重要信息保留,冷门内容逐步遗忘。
- 仅2200万参数就达到近顶尖性能,召回率100%,指标领先超轻量模型。
- 适合追求低延迟、高效率的生产级RAG系统,支持实时调整与稳定运行。
我们提出自适应检索增强生成(Adaptive RAG Memory, ARM),将静态向量索引替换为受选择性记忆与衰减机制控制的动态记忆体系。高频检索项被巩固并防止遗忘,低频项则逐渐衰减,借鉴认知固化与遗忘原理。在轻量级检索基准上,ARM仅需约2200万嵌入层参数,即达到近顶尖性能(如NDCG@5≈0.940,Recall@5=1.000),是参数量低于2500万模型中效率最优者。进一步对比显示,Llama 3.1搭配静态RAG实现最高关键词覆盖率(67.2%)且延迟适中;而GPT-4o结合动态选择性检索策略平均响应仅8.2秒,覆盖率仍达58.7%。我们还优化了DynamicRAG实现,支持嵌入权重运行时配置、动态调整且对错误设置具有鲁棒性。ARM在无需重训练生成器的前提下,实现了竞争性准确率、自我调节的记忆增长和可解释的保留动态,为生产与研究场景提供质量、延迟与内存效率间的实用权衡。
原文摘要 · Abstract (English)
We introduce \emph{Adaptive RAG Memory} (ARM), a retrieval-augmented generation (RAG) framework that replaces a static vector index with a \emph{dynamic} memory substrate governed by selective remembrance and decay. Frequently retrieved items are consolidated and protected from forgetting, while rarely used items gradually decay, inspired by cognitive consolidation and forgetting principles. On a lightweight retrieval benchmark, ARM reaches near state-of-the-art performance (e.g., NDCG@5 $\approx$ 0.940, Recall@5 $=1.000$) with only $\sim$22M parameters in the embedding layer, achieving the best efficiency among ultra-efficient models ($<$25M parameters). In addition, we compare static vs. dynamic RAG combinations across Llama 3.1 and GPT-4o. Llama 3.1 with static RAG achieves the highest key-term coverage (67.2\%) at moderate latency, while GPT-4o with a dynamic selective retrieval policy attains the fastest responses (8.2s on average) with competitive coverage (58.7\%). We further present an engineering optimization of the DynamicRAG implementation, making embedding weights configurable, adjustable at runtime, and robust to invalid settings. ARM yields competitive accuracy, self-regularizing memory growth, and interpretable retention dynamics without retraining the generator\color{black} and provides practical trade-off between quality, latency and memory efficiency for production and research RAG system.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。