arXiv:2506.15706cs.LGcs.AI2025-06

通过多粒度优化提升大模型数学推理的准确性。

MDPO: Multi-Granularity Direct Preference Optimization for Mathematical Reasoning

  • 分三粒度优化:整体解法、推理逻辑、步骤计算
  • 在GSM8K和MATH数据集上分别提升1.7%~2.3%
  • 无需人工标注,可自动构建训练数据

数学推理对大语言模型(LLMs)构成重大挑战,因其需保证每一步推理的正确性。尽管监督微调有所进展,但难以抑制错误输出,易产生幻觉。近期直接偏好优化(DPO)被用于对齐人类意图,防止生成错误结果,但在长链数学推理中效果有限,主要因无法有效捕捉偏好数据中正确与错误答案的差异,且训练目标与生成指标不一致。为此,本文提出多粒度直接偏好优化(MDPO),在三个粒度上优化:解法到解法(Solution2Solution)、推理到推理(Inference2Inference)、步骤到步骤(Step2Step)。前者关注完整推理链的正确性,后者聚焦步骤间的逻辑连贯性,第三类纠正步骤中的计算错误,增强模型计算能力。同时,统一三者训练目标以匹配生成指标。在开源模型Qwen2和Llama3上实验,于GSM8K数据集上分别提升1.7%和0.9%,于MATH数据集上分别提升2.3%和1.2%,优于DPO及其它变体方法。此外,还提供无需人工标注的自动化数据构建流程。

原文摘要 · Abstract (English)

Mathematical reasoning presents a significant challenge for Large Language Models (LLMs) as it requires ensuring the correctness of each reasoning step. Researchers have been strengthening the mathematical reasoning abilities of LLMs through supervised fine-tuning, but due to the inability to suppress incorrect outputs, illusions can easily arise. Recently, Direct Preference Optimization (DPO) has been widely adopted for aligning human intent by using preference data to prevent LLMs from generating incorrect outputs. However, it has shown limited benefits in long-chain mathematical reasoning, mainly because DPO struggles to effectively capture the differences between accepted and rejected answers from preferences in long-chain data. The inconsistency between DPO training and LLMs' generation metrics also affects the effectiveness of suppressing incorrect outputs. We propose the Multi-Granularity Direct Preference Optimization (MDPO) method, optimizing the mathematical reasoning of LLMs at three granularities: Solution2Solution, Inference2Inference, and Step2Step. Solution2Solution focuses on the correctness of entire long-chain reasoning; Inference2Inference concentrates on logical reasoning between steps; Step2Step corrects computational errors in steps, enhancing the computational capabilities of LLMs. Additionally, we unify the training objectives of the three granularities to align with the generation metrics. We conducted experiments on the open-source models Qwen2 and Llama3, achieving improvements of 1.7% and 0.9% on the GSM8K dataset, and 2.3% and 1.2% on the MATH dataset, outperforming DPO and other DPO variant methods. Furthermore, we also provide a pipeline for constructing MDPO training data that is simple and does not require manual annotation costs.

数学推理偏好优化多粒度大模型

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。