When To Solve, When To Verify: Compute-Optimal Problem Solving and Generative Verification for LLM Reasoning
这篇论文研究了在大型语言模型(LLM)推理中,如何通过平衡解决方案生成和验证来优化测试时的计算扩展。
更新于 2025-04-02。作者:Nishad Singhi、Hritik Bansal、Arian Hosseini、Aditya Grover、Kai-Wei Chang、Marcus Rohrbach、Anna Rohrbach。
中文摘要
大规模测试时计算扩展已成为增强大型语言模型(LLMs)推理能力的关键策略,尤其是在像数学问题解决这样的任务中。传统方法,即自洽性(SC),生成多个问题的解决方案,并通过多数投票选择最常见的答案。另一种常见的方法是使用奖励模型(验证器)为每个解决方案评分,并选择最好的一个。近年来,在生成奖励模型(GenRM)方面的最新进展将验证重新定义为下一个标记的预测任务,从而实现了沿新轴的推理时间扩展。具体来说,GenRM为每个解决方案生成多个验证思维链来评分。在有限的推理预算下,这引入了一个基本的权衡:是否应该将预算用于通过SC扩展解决方案,还是生成更少的解决方案并将计算资源分配给通过GenRM进行验证?为了解决这个问题,我们在固定的推理预算下评估了GenRM与SC。有趣的是,我们发现对于不同模型和数据集的绝大多数实际推理预算来说,SC在计算效率上比GenRM更优。例如,GenRM在消耗了高达8倍的推理计算之后才与SC相当,并且需要更多的计算才能超越它。此外,我们为GenRM范式推导出推理扩展定律,揭示了计算最优推理更倾向于积极扩展解决方案生成,而不是扩展验证的数量。我们的工作为通过平衡解决方案生成和验证来优化测试时扩展提供了实用的指导。代码可在https://github.com/nishadsinghi/sc-genrm-scaling上找到。
英文摘要
Scaling test-time compute has emerged as a key strategy for enhancing the reasoning capabilities of large language models (LLMs), particularly in tasks like mathematical problem-solving. A traditional approach, Self-Consistency (SC), generates multiple solutions to a problem and selects the most common answer via majority voting. Another common method involves scoring each solution with a reward model (verifier) and choosing the best one. Recent advancements in Generative Reward Models (GenRM) reframe verification as a next-token prediction task, enabling inference-time scaling along a new axis. Specifically, GenRM generates multiple verification chains-of-thought to score each solution. Under a limited inference budget, this introduces a fundamental trade-off: should you spend the budget on scaling solutions via SC or generate fewer solutions and allocate compute to verification via GenRM? To address this, we evaluate GenRM against SC under a fixed inference budget. Interestingly, we find that SC is more compute-efficient than GenRM for most practical inference budgets across diverse models and datasets. For instance, GenRM first matches SC after consuming up to 8x the inference compute and requires significantly more compute to outperform it. Furthermore, we derive inference scaling laws for the GenRM paradigm, revealing that compute-optimal inference favors scaling solution generation more aggressively than scaling the number of verifications. Our work provides practical guidance on optimizing test-time scaling by balancing solution generation and verification. The code is available at https://github.com/nishadsinghi/sc-genrm-scaling.
解读
一句话总结
这篇论文研究了在大型语言模型(LLM)推理中,如何通过平衡解决方案生成和验证来优化测试时的计算扩展。
问题1:这篇论文想要解决什么具体问题?
- 问题背景:在LLM推理中,测试时计算扩展已成为提高推理能力的关键策略,尤其是在数学问题解决等任务中。
- 现有方案不足:传统的自我一致性(SC)方法和基于奖励模型的验证方法在计算效率上存在局限性。
- 研究目标:通过比较SC和基于生成奖励模型(GenRM)的方法,研究在固定推理预算下如何优化测试时扩展。
问题2:论文的核心创新点是什么?
- 技术创新:提出了计算匹配分析,比较了SC和GenRM在不同计算预算下的性能。
- 方法改进:推导了GenRM的推理扩展定律,描述了最佳解决方案和验证数量如何随计算预算变化。
- 优势:提供了关于如何平衡解决方案生成和验证以实现计算优化推理的实用指导。
问题3:实验结果如何验证了方法的有效性?
- 关键实验:进行了固定预算比较,发现SC在较低计算预算下优于GenRM,而GenRM在较高预算下表现更好。
- 性能提升:GenRM在达到与SC相同性能之前需要8倍的推理计算,而要实现3.8%的性能提升则需要128倍的推理计算。
- 对比结果:实验结果表明,SC在较低预算下更有效,而GenRM在较高预算下更有效。
问题4:这个研究的实际应用价值是什么?
- 应用场景:适用于需要LLM推理的任务,如数学问题解决、科学推理等。
- 实施建议:根据具体的计算预算和任务难度,选择SC或GenRM,并根据推导的推理扩展定律进行优化。
- 局限与展望:未来可以扩展到不同的硬件和算法,以及探索更先进的LLM架构。
来源
机器可读索引:llms.txt