Overview
Reinforcement Learning from Human Feedback (RLHF) has become the dominant paradigm for aligning models with human intent. However, the standard RLHF pipeline is notoriously complex, brittle, and difficult to scale to high-dimensional environments. Contrastive Preference Learning (CPL) is a novel framework that allows models to learn from human feedback without using reinforcement learning (RL) at all. By modeling human preferences as "regret" rather than raw reward, CPL transforms the complex, two-stage RLHF process into a simple, supervised contrastive learning task that is faster, more stable, and easier to scale.
The Problem with Standard RLHF
The standard recipe for RLHF is a two-step process:
- Reward Modeling: Train a reward model to guess what a human likes based on preference data.
- Reinforcement Learning: Use an RL algorithm (like PPO) to optimize a policy against that learned reward model.
This approach has two major flaws. First, it assumes humans provide feedback based on cumulative reward. Cognitive science, however, suggests we actually judge behavior based on regret—how much worse an action was compared to the optimal choice. Second, the RL phase is notoriously unstable. RL algorithms struggle with high-dimensional inputs (like images), long-term credit assignment, and hyperparameter sensitivity. To avoid these issues, most RLHF applications today are restricted to "contextual bandits" (one-step tasks like LLM responses) rather than complex, multi-step sequential problems like robotics.
Contrastive Preference Learning (CPL)
To overcome these limitations, the authors introduce Contrastive Preference Learning (CPL), which bypasses reward modeling and RL entirely.
The key mathematical insight stems from the principle of Maximum Entropy (MaxEnt) RL. In this framework, there is a direct mathematical link between the optimal advantage function (which represents negated regret) and the log-probability of the optimal policy.
By substituting the policy's log-probabilities directly into a regret-based preference model, the authors derive a purely supervised objective. Instead of training a policy to get high scores from a separate reward model, CPL trains a policy to make the preferred behavior more likely than the unpreferred behavior.
Key Technical Features: * Contrastive Objective: Similar to InfoNCE used in representation learning, CPL pushes the log-likelihood of preferred trajectory segments up and unpreferred segments down. * Fully Off-Policy: It can learn from any static dataset of preferences without needing to interact with the environment during training. * Conservative Regularization: To prevent the model from hallucinating "perfect" actions outside the training data, CPL includes a bias term that keeps the policy close to the observed data distribution.
Experimental Setup
The researchers evaluated CPL on two primary domains:
- MetaWorld: A benchmark of six robotic manipulation tasks (e.g., Bin Picking, Drawer Open). They tested both state-based (low-dimensional) and challenging image-based (pixels-to-actions) versions.
- D4RL with Real Human Feedback: They used existing datasets of locomotion tasks (Walker, Hopper) that contain actual preferences provided by human raters.
Key Insights and Results
- Regret is a Better Prior: Modeling preferences via regret is more robust than reward. In a sparse-reward task (like reaching a goal), two paths that both fail to reach the goal have the same reward (zero), but a human will clearly prefer the one that got closer. Regret captures this nuance; standard reward modeling often doesn't.
- Supervised Stability: Because CPL is essentially a specialized form of logistic regression, it avoids the "deadly triad" of RL instability (off-policy learning, function approximation, and bootstrapping).
- Efficiency: CPL is 1.6x faster to train than RL-based methods (like P-IQL) and 4x more parameter efficient because it doesn't need to learn auxiliary value functions or target networks.
- Performance and Scaling: In image-based robotics tasks, CPL matched or outperformed state-of-the-art RL baselines. Furthermore, CPL showed clear "scaling law" behavior: as the number of comparisons per segment increased, the success rate climbed steadily, whereas RL baselines often plateaued or degraded due to reward model underfitting.
Limitations and Future Work
While CPL simplifies the alignment process, it has a few limitations. It assumes the human's internal discount factor ($\gamma$) is known; mismatches here could impact performance. Additionally, because the loss is calculated over entire trajectory segments, training on very long sequences can be GPU-memory intensive.
Future work will likely explore extending CPL to active, online settings where the model queries preferences in real-time, as well as applying this regret-based contrastive approach to large language models for multi-turn dialogue alignment.
Summary updated