What do RLHF, DPO, and Constitutional AI/RLAIF actually do for safety, and why can't a system prompt replace them?
Type it the way you would explain it to an interviewer. A few sentences is enough; you can't break anything.
Model answer: the part to lead with
Pretraining on the internet produces a model that is capable but not aligned - it will happily continue harmful text because it's just modelling the distribution. Alignment training reshapes the behaviour distribution on top of those capabilities.
Full worked answer
Pretraining on the internet produces a model that is capable but not aligned - it will happily continue harmful text because it's just modelling the distribution. Alignment training reshapes the behaviour distribution on top of those capabilities.
- RLHF - collect human preference comparisons, train a reward model, optimise the policy against it (PPO). This is where helpfulness and refusals are instilled: the model learns to prefer helpful, harmless, honest responses.
- DPO - a cheaper, more stable alternative that optimises directly on preference pairs, no separate reward model or RL loop. Same goal, better engineering. (GRPO is different: still RL, it drops the value/critic model and is used mainly with verifiable rewards for reasoning, not preference alignment.)
- Constitutional AI / RLAIF (Anthropic) in one line: the model critiques and revises its own responses against a written set of principles ("a constitution"), and AI-generated preference labels replace most human ones - cheaper, more scalable, and more transparent about the values being trained in.
Why a system prompt can't substitute: a system prompt only conditions the already-trained policy at inference time. It can't add a capability the base model lacks, it can't remove a capability the model has, and it lives in the same untrusted token stream - so it can be overridden by a jailbreak or an injection. Alignment training changes the weights' default tendencies across the entire input distribution; a prompt nudges behaviour on the current request and evaporates under adversarial pressure. Saying "we'll make it safe by telling it to be safe in the system prompt" is the tell that someone thinks the prompt is a control rather than a hint. Real safety is defence-in-depth: aligned weights (provider) + system prompt (weak steering) + application guardrails and architecture (yours).
What a good answer covers
- Pretraining on the internet produces a model that is capable but not aligned - it will happily continue…
- Alignment training reshapes the behaviour distribution on top of those capabilities
- RLHF - collect human preference comparisons, train a reward model, optimise the policy against it (PPO)
- DPO - a cheaper, more stable alternative that optimises directly on preference pairs, no separate reward…
- Constitutional AI / RLAIF (Anthropic) in one line
Key terms: Alignment training · RLHF · DPO · Constitutional AI / RLAIF · conditions
In the glossary: RLHF · PPO · DPO · Verifiable reward · Constitutional AI · RLAIF
Interviewer follow-ups to expect
What's the one-line difference between RLHF and RLAIF?
Why is DPO replacing PPO in a lot of pipelines?
Give a concrete case where a system prompt's safety instruction gets overridden.
Worked answer from AI-Engineer-Interview-Questions by Om (MIT), reformatted for LLM Prep · answer text last updated 6 November 2026 · scoring and review schedule by LLM Prep