Abstract
Preference optimization methods have been successfully applied to improve not only the alignment of large language models (LLMs) with human values, but also specific natural language tasks such as summarization and stylistic continuations. This paper proposes using preference optimization methods on Chain-of-Thought steps in order to improve the mathematical reasoning performances of language models. While the chosen answers are obtained from datasets that include reasoning traces, we propose two complementary schemes for generating rejected answers: weak LLM prompting, and digit corruption. Our approach leads to increased accuracy on the GSM8K and AQuA-RAT mathematical reasoning benchmarks for Falcon2-11B and Mistral-7B. Additionally, the improved abilities transfer to non-mathematical tasks, including the ARC benchmark and symbolic reasoning challenges. For example, our method can lead to up to relative 8.47 and 18.73 increases in accuracy on the GSM8K and AQuA benchmarks respectively, without any extra annotations. This work suggests that the path towards better language reasoning abilities goes through spending resources on creating high-quality datasets of reasoning traces.
Introduction
While Large Language Models (LLMs) have shown remarkable capabilities, multi-step reasoning remains a significant hurdle. Standard training via next-token prediction doesn't explicitly reward the logical "process" of solving a problem, only the final output. Common workarounds like Chain-of-Thought (CoT) prompting often result in models that merely mimic human-like reasoning without truly internalizing the underlying logic. Furthermore, the standard approach of Supervised Fine-Tuning (SFT) on correct reasoning traces often leads to "task overfitting"—where the model learns to replicate specific training examples but fails to generalize to slightly different or harder problems. We introduce PORT (Preference Optimization on Reasoning Traces) to instill robust reasoning skills that go beyond simple pattern matching.
Methods
PORT introduces a pipeline that moves beyond simple supervision to preference-based learning. The process follows three main steps:
- SFT Phase: The base model is first fine-tuned on a dataset of correct reasoning traces (e.g., GSM8K) to establish a baseline for generating step-by-step rationales.
- Preference Dataset Creation: To use Direct Preference Optimization (DPO), a "chosen" (correct) and a "rejected" (incorrect) response are required for every prompt. Since datasets usually only provide the correct path, we propose two automated schemes to generate negative examples: Digit Corruption, which randomly changes digits in mathematical steps to create "near-miss" errors, and Weak LLM Prompting, which uses a smaller model (like Gemma-2B) to generate steps that often contain logical fallacies.
- DPO Phase: The model is fine-tuned using DPO, which mathematically incentivizes the model to increase the probability of the "chosen" step while decreasing the probability of the "rejected" one.
Experimental Setup
The study primarily utilizes the GSM8K (Grade School Math 8K) training set to build the preference pairs. To test generalization and transfer abilities, we evaluate the models on AQuA-RAT (algebraic word problems), ARC-Challenge (science reasoning), and LastLetterConcat (symbolic reasoning).
Results and Discussion
Our evaluation shows that negative signals are highly informative; by seeing "corrupted" digits, the model learns that the specific numbers in a reasoning trace are critical, not just the linguistic structure. PORT effectively combats SFT overfitting, showing that preference optimization is a superior tool for generalization. Surprisingly, the simple digit corruption method was highly effective for math tasks, even outperforming more complex methods in some scenarios. Furthermore, training on mathematical reasoning traces improved performance on non-math tasks like symbolic reasoning and science questions, suggesting that reasoning is a transferable skill across domains.
As shown in the table above, PORT (DPO) consistently outperforms both the base model and the SFT baseline across all benchmarks. On GSM8K, we observed up to an 8.47% relative increase in accuracy, while AQuA saw a massive 18.73% relative increase, proving the method's strength in out-of-distribution generalization. PORT also outperformed other popular alignment methods like KTO and IPO, confirming that DPO is particularly well-suited for reasoning traces.
Conclusion
PORT demonstrates that teaching LLMs what not to do is a powerful strategy for improving reasoning. While the current digit corruption strategy is math-specific and the method relies on high-quality initial traces, the results indicate that preference optimization significantly boosts performance without requiring additional human annotations. Future work will explore more diverse ways to generate "rejected" steps, such as intentionally introducing logical fallacies or hallucinations to create more challenging preference pairs.
Summary updated