Reward models are the bridge between human preferences and the RL training signal. A well-trained reward model is essential for successful RLHF; a poorly trained one leads to reward hacking and misaligned behaviour. This section covers the theoretical foundations, practical training techniques, and architectural choices for reward models.
Bradley-Terry Model – Full Derivation
The Bradley-Terry model [29] is the standard probabilistic framework for pairwise preference learning. Given two responses and to a prompt , the model assumes:
where is the scalar reward function and is the sigmoid function.
Given a dataset of preference pairs, the MLE objective is:
where is a neural network parameterised by . This is a binary cross-entropy loss where the “positive” class is the preferred response.
A common extension adds a margin to ensure a minimum gap between winning and losing rewards:
Reward Model Architectures
The architecture is:
- Backbone: a pretrained LLM (e.g., Llama, Mistral) that encodes the prompt-response pair into a sequence of hidden states.
- Pooling: extract the hidden state at the last token position (for decoder-only models) or the
[CLS]token (for encoder models). - Regression head: a linear layer that maps the pooled hidden state to a scalar reward.
Reward Model Training Tricks
Raw reward model outputs can have arbitrary scale and offset. Centering the rewards (subtracting the mean) stabilises RL training:
In TRL, this is implemented via the center_rewards_coefficient parameter, which adds a regularisation term to the reward model loss that penalises non-zero mean rewards.
Reward models are known to exhibit length bias: they tend to assign higher rewards to longer responses, regardless of quality. This can be corrected by:
- Length normalisation: divide the reward by the response length.
- Length-controlled training: include length as a feature and train the model to be length-invariant.
- Calibration: post-hoc regression to remove the length effect.
Adding a margin to the Bradley-Terry loss ensures the reward model assigns meaningfully different scores to preferred and dispreferred responses:
Process Reward Models vs Outcome Reward Models
Step-level annotations can be generated automatically using:
- Monte Carlo rollouts: for each intermediate step, sample multiple completions and use the fraction that reach the correct answer as the step reward.
- LLM-as-judge: use a strong LLM to evaluate each step.
- Formal verification: for math/code, use a verifier to check each step.
Rule-Based Rewards for RLVR
Reinforcement Learning from Verifiable Rewards (RLVR) uses deterministic, rule-based reward functions instead of learned reward models. This substantially reduces reward hacking (though models can still exploit format tricks, edge cases, or test memorization) and is the approach used in DeepSeek-R1 [69].
Multi-Objective Rewards – Combination Strategies
When training with multiple reward signals, the combination strategy significantly affects the final policy.
Listwise Rank-Based Rewards
While the Bradley-Terry model handles pairwise preferences (), many practical scenarios involve ranking multiple responses simultaneously. Listwise reward models learn from complete orderings, providing richer training signal and enabling better calibration.
The Plackett-Luce (PL) model [291] is the standard extension of Bradley-Terry to full rankings. Given responses with ranking (where is the best):