Learn to Reason Efficiently with Adaptive Length-based Reward Shaping
该论文提出了一种基于自适应长度奖励塑造的方法(LASER),旨在通过强化学习提高大型推理模型(LRMs)的推理效率,同时保持高性能。
更新于 2025-05-23。作者:Wei Liu、Ruochen Zhou、Yiyun Deng、Yuzhen Huang、Junteng Liu、Yuntian Deng、Yizhe Zhang、Junxian He。
中文摘要
大型推理模型(LRMs)在通过强化学习(RL)解决复杂问题方面表现出卓越的能力,尤其是通过生成长的推理轨迹。然而,这些扩展输出往往存在大量冗余,这限制了LRMs的效率。在本文中,我们研究了基于RL的促进推理效率的方法。具体来说,我们首先提出一个统一的框架,通过基于长度的奖励塑造来定义各种高效的推理方法。在此基础上,我们提出了一种新颖的基于长度奖励塑造的方法(LASER),它使用目标长度控制的步函数作为奖励。LASER超越了先前的方法,在性能和效率之间实现了优越的帕累托最优平衡。接下来,我们进一步基于两个关键直觉扩展LASER:(1)模型的推理行为在训练过程中会演变,需要也是自适应和动态的奖励规范;(2)我们提出,而不是均匀地鼓励短或长的思维链(CoT),基于长度的奖励塑造应该是难度感知的,即对简单查询的长时间CoT进行更多惩罚。这种方法有望促进快速和慢速思考的结合,从而实现更好的整体权衡。这种方法被称为LASER-D(动态和难度感知)。在DeepSeek-R1-Distill-Qwen-1.5B、DeepSeek-R1-Distill-Qwen-7B和DeepSeek-R1-Distill-Qwen-32B上的实验表明,我们的方法显著提高了推理性能和响应长度效率。例如,LASER-D及其变体在AIME2024上实现了+6.1的改进,同时减少了63%的token使用。进一步的分析揭示,我们基于RL的压缩产生了更简洁的推理模式,减少了冗余的“自我反思”。资源可在https://github.com/hkust-nlp/Laser找到。
英文摘要
Large Reasoning Models (LRMs) have shown remarkable capabilities in solving complex problems through reinforcement learning (RL), particularly by generating long reasoning traces. However, these extended outputs often exhibit substantial redundancy, which limits the efficiency of LRMs. In this paper, we investigate RL-based approaches to promote reasoning efficiency. Specifically, we first present a unified framework that formulates various efficient reasoning methods through the lens of length-based reward shaping. Building on this perspective, we propose a novel Length-bAsed StEp Reward shaping method (LASER), which employs a step function as the reward, controlled by a target length. LASER surpasses previous methods, achieving a superior Pareto-optimal balance between performance and efficiency. Next, we further extend LASER based on two key intuitions: (1) The reasoning behavior of the model evolves during training, necessitating reward specifications that are also adaptive and dynamic; (2) Rather than uniformly encouraging shorter or longer chains of thought (CoT), we posit that length-based reward shaping should be difficulty-aware i.e., it should penalize lengthy CoTs more for easy queries. This approach is expected to facilitate a combination of fast and slow thinking, leading to a better overall tradeoff. The resulting method is termed LASER-D (Dynamic and Difficulty-aware). Experiments on DeepSeek-R1-Distill-Qwen-1.5B, DeepSeek-R1-Distill-Qwen-7B, and DeepSeek-R1-Distill-Qwen-32B show that our approach significantly enhances both reasoning performance and response length efficiency. For instance, LASER-D and its variant achieve a +6.1 improvement on AIME2024 while reducing token usage by 63%. Further analysis reveals our RL-based compression produces more concise reasoning patterns with less redundant "self-reflections". Resources are at https://github.com/hkust-nlp/Laser.
解读
一句话总结
该论文提出了一种基于自适应长度奖励塑造的方法(LASER),旨在通过强化学习提高大型推理模型(LRMs)的推理效率,同时保持高性能。
问题1:这篇论文想要解决什么具体问题?
- 问题背景:大型推理模型在解决复杂问题时通过强化学习生成长推理轨迹,但这些轨迹往往包含大量冗余,降低了效率。
- 现有方案不足:现有的方法往往在提高效率的同时牺牲了推理性能,或者在保持性能的同时效率提升有限。
- 研究目标:通过提出LASER方法,在保持推理性能的同时显著提高推理效率。
问题2:论文的核心创新点是什么?
- 技术创新:提出了一种基于长度奖励塑造的方法LASER,该方法通过目标长度使用步函数作为奖励,以平衡性能和效率。
- 方法改进:LASER方法在LASER的基础上进一步扩展,提出了LASER-D(动态和难度感知),根据问题难度自适应地应用不同的长度奖励塑造。
- 优势:LASER-D及其变体在保持高准确率的同时,显著减少了token的使用,提高了推理效率。
问题3:实验结果如何验证了方法的有效性?
- 关键实验:在DeepSeek-R1-Distill-Qwen-1.5B、DeepSeek-R1-Distill-Qwen-7B和DeepSeek-R1-Distill-Qwen-32B上进行了实验,结果表明LASER-D和LASER-DE显著提高了推理性能和响应长度效率。
- 性能提升:LASER-D和LASER-DE在AIME2024上实现了+6.1的准确率提升,同时减少了63%的token使用。
- 对比结果:与基线方法相比,LASER-D和LASER-DE在准确率和token效率方面都取得了更好的平衡。
问题4:这个研究的实际应用价值是什么?
- 应用场景:该方法可以应用于需要高效推理的场景,如数学问题求解、代码生成和智能决策等。
- 实施建议:在实际部署时,可以根据具体任务的需求调整LASER-D的目标长度和难度感知参数。
- 局限与展望:该方法在数学推理任务上表现出色,未来可以扩展到其他领域,如代码生成和智能决策等,以进一步提高推理效率。
来源
机器可读索引:llms.txt