RLHF
Aligning a model with human preference using reinforcement learning on ranked outputs.
Overview
RLHF trains a reward model on human comparisons of model outputs, then uses reinforcement learning to steer the language model toward what the reward model scores highly. It solves the problem that the behaviour people want, being helpful and refusing harmful requests, is far easier to rank than to write as a supervised target. It exists because it is what turned a raw next-token predictor into something that follows instructions, and it is the step DPO later simplified.
Technology Graph
How RLHF connects to the rest of the stack.
Uses and depends on
- Reinforcement Learning concept Algorithms RLHF uses Reinforcement Learning High ✓ source
- DPO technique Techniques DPO based on RLHF High ✓ source
- RLAIF technique Safety & Alignment RLAIF based on RLHF High ✓ source
Applied to
- Fine-tuning technique Techniques RLHF used for Fine-tuning High ✓ source
- TRL library LLM Frameworks TRL used for RLHF High ✓ source
- Alignment technique Safety & Alignment RLHF enables Alignment High ✓ source
Classification
- Supervised Fine-Tuning technique Techniques Supervised Fine-Tuning part of RLHF High ✓ source
Alternatives
-
Constitutional AI
technique
An alternative to RLHF · source
-
DPO
technique
An alternative to RLHF · source
Comparisons
Side-by-side breakdowns with the alternatives above.