AI Agents 相关度: 9/10

The Pensieve Paradigm: Stateful Language Models Mastering Their Own Context

Xiaoyuan Liu, Tian Liang, Dongyang Ma, Deyu Zhou, Haitao Mi, Pinjia He, Yan Wang
arXiv: 2602.12108v1 发布: 2026-02-12 更新: 2026-02-12

AI 摘要

StateLM模型通过内部推理循环管理自身状态,突破固定窗口限制,提升长文本处理能力。

主要贡献

  • 提出了StateLM,一种具备内部推理循环的状态感知语言模型
  • 设计了一套记忆工具,包括上下文剪枝、文档索引和笔记
  • 通过实验验证了StateLM在长文档问答、聊天记忆和深度研究任务中的优越性

方法论

训练语言模型主动管理上下文,利用记忆工具动态构建自身上下文,突破固定窗口限制。

原文摘要

In the world of Harry Potter, when Dumbledore's mind is overburdened, he extracts memories into a Pensieve to be revisited later. In the world of AI, while we possess the Pensieve-mature databases and retrieval systems, our models inexplicably lack the "wand" to operate it. They remain like a Dumbledore without agency, passively accepting a manually engineered context as their entire memory. This work finally places the wand in the model's hand. We introduce StateLM, a new class of foundation models endowed with an internal reasoning loop to manage their own state. We equip our model with a suite of memory tools, such as context pruning, document indexing, and note-taking, and train it to actively manage these tools. By learning to dynamically engineering its own context, our model breaks free from the architectural prison of a fixed window. Experiments across various model sizes demonstrate StateLM's effectiveness across diverse scenarios. On long-document QA tasks, StateLMs consistently outperform standard LLMs across all model scales; on the chat memory task, they achieve absolute accuracy improvements of 10% to 20% over standard LLMs. On the deep research task BrowseComp-Plus, the performance gap becomes even more pronounced: StateLM achieves up to 52% accuracy, whereas standard LLM counterparts struggle around 5%. Ultimately, our approach shifts LLMs from passive predictors to state-aware agents where reasoning becomes a stateful and manageable process.

标签

StateLM Memory Management Long-Context Agent

arXiv 分类

cs.AI