People find it hard to write down a formula for a “good answer”, but easy to pick the better of two. RLHF uses these comparisons: they train a separate reward model, and the language model is then fine-tuned with reinforcement learning to earn a high score from it.
Three steps
| Step | What happens |
|---|---|
| 1. SFT | the pretrained model is fine-tuned on example answers written by people |
| 2. Reward model | the model generates several answers to one prompt and people rank them; these comparisons train a model that predicts which answer people would choose |
| 3. Reinforcement learning | the language model is fine-tuned with the PPO algorithm to maximise the reward model’s score |
InstructGPT was trained this way at three sizes: 1.3 billion, 6 billion and 175 billion parameters. According to labellers’ ratings, answers from the 1.3-billion-parameter InstructGPT were preferred to those of the 175-billion-parameter GPT-3, even though it has over a hundred times fewer parameters.
What to keep in mind
The reward model is only an approximation of the tastes of a particular group of labellers, not of “human values” in general. If the model chases its score for too long, the language model starts to find loopholes in it, so a penalty for drifting away from the original model is usually added. The method needs a separate reward model, generation of answers during training and careful tuning, which is why the simpler DPO method was proposed later.
Where the term comes from
The method was developed by Paul Christiano and co-authors in 2017 for Atari games and a simulated robot (learning from human preferences had been studied before); it was first applied to language models for text continuation and summarisation (Ziegler et al., 2019; Stiennon et al., 2020), and to a broad range of instructions in InstructGPT (Ouyang et al., 2022).
Sources
the term is written from these pagesVerified 18 Nov