Abstract
Alignment serves as an important step to steer large language models (LLMs) towards human preferences. In this paper, we propose an automatic way to construct contrastive data for LLM, using preference pairs from multiple models of varying strengths (e.g., InstructGPT, ChatGPT and GPT-4). We compare the contrastive techniques of SLiC and DPO to SFT baselines and find that DPO provides a step-function improvement even after continuing SFT saturates. We also explore a data curriculum learning scheme for contrastive post-training, which starts by learning from "easier" pairs and transitioning to "harder" ones, which further improves alignment. Finally, we scale up our experiments to train with more data and larger models like Orca. Remarkably, our automatic contrastive post-training further improves the performance of Orca, already a state-of-the-art instruction learning model tuned with GPT-4 outputs, to outperform ChatGPT.
Introduction
Aligning Large Language Models (LLMs) typically requires expensive, human-annotated preference data to move beyond simple next-token prediction. While Supervised Fine-Tuning (SFT) helps LLMs follow instructions, it often hits a performance ceiling. Reinforcement Learning from Human Feedback (RLHF) is the standard alternative, but it is bottlenecked by the cost and inconsistency of human labels. Reinforcement Learning from AI Feedback (RLAIF) attempts to mitigate this but remains prone to "reward hacking," where models exploit reward function biases to produce high-scoring but incoherent outputs.
This paper introduces an automatic method to generate preference pairs by contrasting outputs from models of different "strengths" (e.g., GPT-4 vs. InstructGPT) and applying a data curriculum that transitions from easy to hard examples.
Methodology
The core of the proposed approach is Automatic Pair Construction. Instead of explicit rating, the researchers assume a quality hierarchy: GPT-4 > ChatGPT > InstructGPT.
- Pair Construction: Responses to the same prompt are generated using these models. A "positive" example ($y^+$) is drawn from a superior model, and a "negative" example ($y^-$) from an inferior one.
- Contrastive Objectives: Two primary methods were evaluated:
- SLiC (Sequence Likelihood Calibration): Uses a fixed margin to push the probability of the positive example above the negative one.
- DPO (Direct Preference Optimization): A stable alternative to RLHF that optimizes the relative probability of preferred outputs without a separate reward model.
Data Curriculum
The researchers hypothesized that the "distance" between models in a pair affects learning. They defined EasyPairs (e.g., GPT-4 vs. InstructGPT) and HardPairs (e.g., ChatGPT vs. InstructGPT). A curriculum was implemented where training begins with EasyPairs to establish a foundation, followed by HardPairs to refine the model's ability to discern subtle quality differences.
Key Results and Insights
The experimental results demonstrate that DPO provides a "step-function" improvement over SFT. Even after SFT performance saturates, DPO continues to enhance the model by teaching it what not to do. The most effective training signal originated from the most distant pairs (GPT-4 vs. InstructGPT), which provide a clearer gradient for optimization.
Key findings include:
- Orca+DPO > ChatGPT: Applying DPO to the Orca 13B model (already tuned on GPT-4 outputs) resulted in a 55% win rate against ChatGPT on Alpaca Eval.
- Superiority over SFT: On the Alpaca dataset, DPO using GPT-4 vs. InstructGPT pairs achieved a 77.3% win rate against a standard SFT baseline, significantly outperforming additional SFT on GPT-4 outputs (65.1%).
- Efficiency: Contrastive methods like DPO are computationally more efficient than PPO-based RLHF, as they do not require maintaining multiple models (policy, value, reward, reference) in memory simultaneously.
Conclusion
Contrastive post-training with an automatic data curriculum offers a scalable, efficient path to LLM alignment. By leveraging the existing hierarchy of model strengths, researchers can bypass the need for expensive human labels. Future work will explore "self-evolution," where models generate their own contrastive pairs to iteratively improve without external supervision.
Summary updated