提出 SandwichR 模型,实现低延迟下精准查询纠错。
Sandwich Reasoning: An Answer-Reasoning-Answer Approach for Low-Latency Query Correction
- 先出答案再推理,最后修正答案,提升纠错效率。
- 实测精度达 SOTA,延迟降低 40%-70%。
- 适合需要实时响应的在线搜索系统使用。
查询纠错是现代搜索流水线的关键环节,需在严格实时延迟约束下保持高精度。链式思维(CoT)虽能提升准确率,但延迟过高难以满足实时需求。现有方法在自回归解码中提前输出答案,但该答案与后续推理无关,无法利用推理优化结果。为此,本文提出 Sandwich Reasoning(SandwichR),采用“答案-推理-答案”范式:先生成初步纠错结果,再进行显式推理,最后输出优化后的修正结果。为对齐初始答案与推理后结果,设计一致性感知强化学习策略:通过一致性奖励强制前后答案一致,同时基于置信度边界采样,优先处理推理带来显著改进的边缘样本。此外,构建高质量查询纠错数据集,弥补复杂查询纠错专用基准缺失的问题。实验表明,SandwichR 在达到与标准 CoT 相当的 SOTA 准确率的同时,实现 40%-70% 的延迟降低,有效解决在线搜索中的延迟-精度权衡问题。
原文摘要 · Abstract (English)
Query correction is a critical entry point in modern search pipelines, demanding high accuracy strictly within real-time latency constraints. Chain-of-Thought (CoT) reasoning improves accuracy but incurs prohibitive latency for real-time query correction. A potential solution is to output an answer before reasoning to reduce latency; however, under autoregressive decoding, the early answer is independent of subsequent reasoning, preventing the model from leveraging its reasoning capability to improve accuracy. To address this issue, we propose Sandwich Reasoning (SandwichR), a novel approach that explicitly aligns a fast initial answer with post-hoc reasoning, enabling low-latency query correction without sacrificing reasoning-aware accuracy. SandwichR follows an Answer-Reasoning-Answer paradigm, producing an initial correction, an explicit reasoning process, and a final refined correction. To align the initial answer with post-reasoning insights, we design a consistency-aware reinforcement learning (RL) strategy: a dedicated consistency reward enforces alignment between the initial and final corrections, while margin-based rejection sampling prioritizes borderline samples where reasoning drives the most impactful corrective gains. Additionally, we construct a high-quality query correction dataset, addressing the lack of specialized benchmarks for complex query correction. Experimental results demonstrate that SandwichR achieves SOTA accuracy comparable to standard CoT while delivering a 40-70% latency reduction, resolving the latency-accuracy trade-off in online search.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。