用压缩技术解决搜索代理推理中上下文膨胀问题。
RECON: Reasoning with Condensation for Efficient Retrieval-Augmented Generation
- 在推理循环中插入可学习的观察压缩模块,动态减少上下文长度。
- 使3B和7B模型的精确匹配率分别提升14.5%和3.0%,推理延迟降低30.9%。
- 适合需要高效长程推理的智能搜索系统研发者使用。
以强化学习训练的搜索代理在多轮工具调用中交替进行推理与工具调用,每次工具返回的原始观测结果被追加到上下文,导致上下文持续膨胀,增加令牌开销并稀释下游推理信号。不同于单次检索-阅读流程中的一次性压缩,该多轮强化学习场景要求每步观测时都进行压缩,且不能影响策略优化。本文提出RECON(REasoning with CONdensation)框架,在推理循环中嵌入专用的观测压缩器。压缩器通过两阶段课程训练:先在问答数据集上进行相关性预训练,再从私有大模型中进行多维度知识蒸馏,随后在强化学习训练期间保持冻结以确保策略稳定。集成至Search-R1搜索代理流水线后,RECON将总上下文长度减少35%,训练速度提升5.4%,推理延迟降低30.9%,并在3B和7B模型上分别实现平均精确匹配率提升14.5%和3.0%,尤其在多跳问答任务中表现突出。结果表明,学习型观测压缩是构建实用、可扩展的强化学习训练搜索代理的关键组件。
原文摘要 · Abstract (English)
Search agents trained with reinforcement learning (RL) interleave reasoning with tool calls in a multi-turn, tool-integrated reasoning (TIR) loop, where each tool invocation returns an environment observation that is appended to the agent's context. As the rollout proceeds, these raw observations accumulate, inflating token cost and diluting the signal available for downstream reasoning. Unlike single-pass retrieve-then-read pipelines, where context compression is a one-time postprocessing step, the multi-turn RL setting requires compression that runs at every observation step while remaining decoupled from policy optimization. We introduce RECON (REasoning with CONdensation), a framework that addresses this challenge by inserting a dedicated observation compressor into the reasoning loop. The compressor is trained via a two-stage curriculum: relevance pretraining on QA datasets followed by multi-aspect distillation from proprietary LLMs, and remains frozen during RL training to preserve policy stability. Integrated into the Search-R1 search-agent pipeline, RECON reduces total context length by 35%, improves training speed by 5.4% and inference latency by 30.9%, while boosting average exact-match by 14.5% on the 3B agent and 3.0% on the 7B agent, with particular strength in multi-hop QA. These results establish learned observation compression as a key component for building practical, scalable RL-trained search agents.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。