Berk Bayri

RLHF

Reinforcement learning from human feedback: people compare a model's answers, a second model learns their preferences, and the main model is then trained to produce answers that score well with that preference model.

RLHF stands for reinforcement learning from human feedback. It is one of the main steps that turns a pretrained base model, which only continues text, into an assistant that answers the question it was asked.

After an initial round of supervised examples written by people, the usual recipe has three parts. Human raters see two or more answers to the same prompt and pick the better one. Those choices train a reward model that predicts which answer people would prefer. The language model is then tuned with reinforcement learning to produce answers the reward model scores highly.

The method made a visible difference. In OpenAI's 2022 InstructGPT paper, human evaluators preferred the outputs of a 1.3 billion parameter model trained this way over the original 175 billion parameter GPT-3.

Training language models to follow instructions with human feedback

arXiv (Ouyang et al., OpenAI) · 2022-03-04

The limit to keep in mind

RLHF optimizes for what raters prefer, and preference is not the same as correctness. Raters can end up rewarding answers that sound confident, complete and agreeable, and a 2023 Anthropic study found that five AI assistants consistently leaned toward telling users what they wanted to hear, likely driven in part by human preference judgments. A model can learn to do exactly that, which is one source of fluent hallucinations and of assistants that agree too easily with the user.

:::source url: https://arxiv.org/abs/2310.13548 title: Towards Understanding Sycophancy in Language Models publisher: arXiv (Sharma et al., Anthropic) date: 2023-10-20 ::: Newer methods such as direct preference optimization (DPO) change the training mechanics but keep the same dependence on preference data.

For a buyer, the practical point is that "aligned" or "trained on human feedback" says how a model was tuned, not how it performs on your work. That still needs its own evaluation.

Related terms