Reinforcement Learning from Human Feedback (RLHF)
A pretrained language model predicts likely text. Likely text can be useful, strange, rude, evasive, or copied from the least charming corners of the internet. RLHF adds a training stage aimed at preferred behavior.
The common pipeline has three parts: supervised fine-tuning on demonstrations, reward modeling from comparisons, and policy optimization against the learned reward.
RLHF Pipeline
Step through the components of RLHF
Current step
Supervised fine-tuning
Start from a pretrained model. Fine-tune it on curated demonstrations of useful responses, producing an initial policy.
A reward model often learns from pairs. If response A receives score and response B receives , a simple preference model uses . The sigmoid turns a score difference into a probability between zero and one.
Policy optimization then increases reward-model scores while limiting how far the model moves from a reference policy. That constraint matters because aggressive optimization can exploit weaknesses in the learned reward model.
RLHF Aligns to a Learned Proxy
The reward model predicts human preference from finite data. Evaluate the resulting policy directly with people, adversarial prompts, and domain-specific tests.
Why constrain policy optimization during RLHF?