Skip to content
AI Glossary

Reinforcement Learning from Human Feedback (RLHF)

A training stage in which human preference ratings are used to steer a language model towards helpful, honest and harmless responses.

Definition

A freshly pre-trained LLM is good at continuing text but not at being an assistant. RLHF is one of the techniques that closes that gap. Human reviewers are shown pairs of model responses and pick the better one. Those judgements train a reward model that predicts which answers people prefer. The language model is then trained, using reinforcement learning, to produce outputs the reward model scores highly.

The result is a model that follows instructions, declines clearly harmful requests and writes in a generally useful tone. Related methods such as direct preference optimisation (DPO) and reinforcement learning from AI feedback achieve similar ends with different mechanics. RLHF comes after supervised fine-tuning in a typical training pipeline.

Example: asked "how do I reset my password?", a base model may continue with a forum-style rant. The RLHF-trained version answers with numbered steps, because reviewers consistently preferred that form.

What it means in practice

  • It explains why assistant models behave as they do, including refusals that can surprise product teams.
  • Preference training reflects the provider's reviewers and policies rather than yours; your own evals decide fit.
  • Trained behaviour can be overridden by prompt injection, so it is not a substitute for application controls.
  • Different providers tune differently, which is a real factor when choosing a model for customer-facing work.

How Teksmobile uses it

We do not run RLHF for clients; the model providers do that work. We use the knowledge to select models and to design prompts that work with trained behaviour rather than against it, as part of LLM application development and our fine-tuning and evals service.

Part of the Teksmobile AI Glossary. For longer reads, see our guides.

FAQ

Frequently asked questions

Do we need to do RLHF ourselves?

Almost never. It is part of how model providers produce assistant models. Businesses typically work with prompting, retrieval and, occasionally, supervised fine-tuning.

What is DPO?

Direct preference optimisation is a newer method that trains on preference pairs directly, without a separate reward model or reinforcement-learning loop. It is simpler and widely used as an alternative to classic RLHF.

Does RLHF make models safe?

It makes them much more likely to refuse harmful requests and follow instructions, but it is not a security control. Application-level guardrails are still required.

Talk to us about your AI project

Tell us what you are trying to do, which systems are involved and what is in the way. We reply within one business day with an opinion and a suggested next step.