arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2606.11213cs.CL
收藏

超越压缩:面向长周期智能体的结构化上下文驱逐

Beyond Compaction: Structured Context Eviction for Long-Horizon Agents

Kiz8

Andrew Semenov, Svyatoslav Dorofeev

AI总结:

提出上下文窗口生命周期(CWL)方案,通过结构化、语义感知的驱逐策略,使长周期LLM智能体在有限上下文预算内实现无限工作视野,避免性能下降和幻觉。

摘要:

我们提出了上下文窗口生命周期(CWL),一种上下文管理方案,为长周期LLM智能体提供有效无界的工作视野。随着会话累积历史,CWL通过渐进式、语义感知的驱逐将上下文保持在预算内:智能体在工作过程中将其轨迹注释为类型化、依赖链接的情节,当令牌预算超出时,一个确定性的、无需LLM的策略在该结构内按优先级顺序驱逐内容。CWL保留用户轮次和智能体正在积极推理的探索上下文,同时积极丢弃其效果已持久化在环境中的行动情节,使活动上下文保持在稳定上限附近,这也避免了与超大提示相关的性能下降。与基于摘要的压缩相比,CWL避免了四个众所周知的局限性:不可预测的信息丢失、因果结构的破坏、阻塞模型成本以及压缩引起的幻觉。与最近截断相比,CWL具有语义感知能力:它根据依赖图丢弃最旧且最可恢复的内容,而不是按时间顺序丢弃最旧的内容而不考虑相关性。我们描述了注释协议、情节图、驱逐策略和令牌记账循环,并在长周期智能体基准上评估了CWL:一个智能体会话在8000万个令牌上完成89个顺序任务,与每任务隔离会话相比,任务准确性没有可测量的下降。

英文摘要:

We present Context Window Lifecycle (CWL), a context-management scheme that gives long-horizon LLM agents an effectively unbounded working horizon. As a session accumulates history, CWL keeps the context within budget through graduated, semantically-aware eviction: the agent annotates its trajectory as typed, dependency-linked episodes as work proceeds, and a deterministic, LLM-free policy evicts content in priority order within that structure when a token budget is exceeded. CWL preserves user turns and the exploratory context the agent is actively reasoning over, while aggressively shedding action episodes whose effects are already persisted in the environment, keeping active context near a stable ceiling that also avoids the performance degradation associated with very large prompts. Compared to summarization-based compaction, CWL avoids four well-known limitations: unpredictable lossiness, destruction of causal structure, blocking model cost, and compression-induced hallucination. Compared to recency truncation, CWL is semantically aware: it drops the oldest-and-most-recoverable content according to the dependency graph rather than oldest-in-time regardless of relevance. We describe the annotation protocol, the episode graph, the eviction policy, and the token-accounting loop, and evaluate CWL on long-horizon agentic benchmarks: a single agent session completing 89 sequential tasks across 80 million tokens with no measurable degradation in task accuracy relative to per-task isolated sessions

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑