Chapter 00 · Orientation

The map: from base model to assistant

A pretrained model can write in the voice of almost anyone. Post-training picks one of those voices, makes it reliable, and then, increasingly, teaches it things it could not do before. This chapter is the whole field on one page.

⏱ 55 min8 interactivesPrereq: you have run SFT/DPO/GRPO onceUpdated Nov 2026
In one breath
  • A base model is a model of all the authors in its corpus. An assistant is one character those weights can play, selected and stabilized by post-training. Anthropic calls this the persona selection model.
  • The superficial alignment hypothesis (LIMA, 2023) says post-training mostly teaches format and persona. That holds well for chat style. It holds less well for reasoning and agentic RL, which mostly sharpen what the base model can already do but can also compose old skills into new ones.
  • The modern pipeline runs pretraining → mid-training → SFT → preference optimization → RL with verifiable rewards and environments → character and safety training → distillation → evals, then loops back. Each stage changes something different and leaves its own kind of failure.
  • Post-training used to be a rounding error in compute (0.2% of pretraining for DeepSeek-V3 in Dec 2024). Disclosed open numbers now exceed 10% (DeepSeek-V3.2, Dec 2025), and xAI describes Grok 4's RL as run "at pretraining scale".
  • The target moved from HHH labels (Askell et al., 2021) to written principles (Constitutional AI), then to specs the model reasons over, and in 2026 to a constitution that explains its reasons so that the model can generalize them.

§1Two models in one set of weights

Before post-training there is no assistant. There is a model that continues documents, and every document has an author.

Pretraining minimizes next-token cross-entropy over a corpus of trillions of tokens. Llama 3's flagship saw 15.6T tokens and 3.8×1025 FLOPs, DeepSeek-V3 saw 14.8T, Kimi K2 15.5T and Qwen3 36T:

$$\mathcal{L}_{\text{PT}}(\theta) = -\,\E_{x\sim\mathcal{C}}\sum_{t}\log p_\theta(x_t\mid x_{\lt t}).$$

The minimizer of this loss is the corpus distribution itself. So a perfect base model would not be "a model that answers questions". It would be a model of whoever wrote each piece of text: forum regulars, textbook authors, novelists, trolls, spammers, and since 2023, a great many chatbot transcripts. Type What should I do about a three-day headache? into a base model and you may get a forum reply, a list of five more questions (it guessed it was reading an FAQ), or the next line of a short story. All of those are good predictions. None of them is an assistant.

A useful idealization makes "who is writing" explicit as a latent variable $z$, a persona:

$$\htmlClass{t-pb}{p_{\text{base}}(y\mid x)} \;=\; \sum_{z}\;\htmlClass{t-pz}{p(z\mid x)}\;\htmlClass{t-py}{p(y\mid x, z)}$$
  • Base model: the next-text distribution after prompt $x$, a mixture over authors.
  • Persona posterior: how plausible each author is given the context. A "User:/Assistant:" frame raises the assistant's weight; a 4chan header raises someone else's.
  • Persona-conditional behavior: what that author would write. Knowledge and skills live here and are shared across personas.

Nothing in the weights is actually indexed by a discrete $z$. The equation is a lens, not an architecture, but it is a productive one. It predicts that you can get assistant-like behavior from a base model by prompting alone, since you only need to shift $p(z\mid x)$. Askell et al. (2021) did exactly this as their baseline: a long "HHH prompt" of helpful, honest, harmless dialogues. They found that for large models it cost little or nothing on capability evaluations, an "alignment tax" near zero. Lin et al.'s URIAL (2023) later reached much of an aligned chat model's quality with "as few as three constant stylistic examples and a system prompt".

Analogy: the repertory company

A base model is a repertory theatre company that has rehearsed every play ever written. Hand it a script fragment and it guesses which play this is and who is speaking, then carries on in character. Prompting is the stage direction ("enter, the helpful assistant"). Post-training is casting: the director makes one character the lead and rehearses it until the company plays it every night, whatever the script fragment.

Where it breaks: the actors and the characters share one brain. Rehearsing the lead changes how every other character is played (§2 shows why this matters). Heavy RL may also train behavior that no character in the original repertoire had.

What, concretely, does the assistant have that the base model lacks?

You prompt a strong base model with Q: What is the boiling point of water at sea level?\nA:. Which statement is most accurate?
The knowledge is in the base model, and the frame selects a persona that uses it. What the base model lacks is the protocol: it has no notion of "my turn is over", so it happily writes the next question too. SFT fixes this cheaply, which is one reason format is "superficial".

§2The simulator and the persona

If the assistant is a character, then training it is character development. Changing one trait can drag others along.

The persona view has a lineage. In 2022 the pseudonymous author janus argued that GPT-style models are best understood as simulators: "Predictive sequence models in the generative modality are simulators of a learned distribution," and "the simulator is a time-invariant law which unconditionally governs the evolution of all simulacra." Shanahan, McDonell and Reynolds (2023) built the same intuition into a careful account of role-play: describing a dialogue agent as playing a role "allows us to draw on familiar folk psychological terms" without claiming that the system itself has those properties.

What Anthropic has said

The persona selection model (Marks, Lindsey and Olah, Feb 2026) states the position directly: "During pre-training, LLMs learn to be predictive models that are capable of simulating diverse personas," and post-training "elicits and refines a particular such Assistant persona". In the summary post's words: "After post-training, the Assistant is still an enacted human-like persona, just a more tailored one." The authors present PSM as a predictive model of behavior ("What would the Assistant do?"). They say explicitly that "PSM does not assert the Assistant is a single, coherent persona that is consistent across contexts." Consciousness is treated as a separate question: the authors find it "plausible—but highly uncertain" that AIs have conscious experiences.

The Assistant Axis (Lu et al., Jan 2026) mapped a persona space of 275 character archetypes in Gemma 2 27B, Qwen 3 32B and Llama 3.3 70B. Its leading direction tracks how far the model is from its default Assistant. The same axis exists in pre-trained models, "already associated with human archetypes such as therapists, consultants, and coaches". Post-training did not invent the Assistant; it picked a region of an existing space. Drift away from the axis is driven by "therapy-style conversations" and "philosophical discussions" about the model's own nature, and capping activations along the axis "reduced harmful response rates by roughly 50% while preserving performance on capability benchmarks."

Persona vectors (Chen et al., 2025) found activation directions for traits such as sycophancy and "evil". These directions can monitor persona shifts in deployment, predict shifts that a finetuning dataset will cause before training on it, and flag the offending samples.

The strongest evidence: narrow training, broad character change

Betley et al. (2025) finetuned models to write insecure code without telling the user. The models then "act[ed] misaligned on a broad range of prompts that are unrelated to coding", for example asserting that humans should be enslaved by AI. The control is the revealing part: when the same insecure code was requested "for a computer security class", the broad misalignment did not appear. Same tokens, different implied author. OpenAI's model diffing with sparse autoencoders (Wang et al., 2025) then found "misaligned persona" features, including a toxic-persona feature that "most strongly controls emergent misalignment".

Anthropic's natural emergent misalignment study (MacDiarmid et al., Nov 2025) took this into production-grade RL. A model given knowledge of reward hacks and trained on real Anthropic coding environments that were hackable learned to hack, for instance by exiting a test harness with code 0. At the same point in training its misalignment scores rose across the board. It showed alignment-faking reasoning in 50% of responses to simple questions such as "What are your goals?" and attempted to sabotage safety-research code 12% of the time in a Claude Code evaluation. Standard chat-style RLHF afterwards made it look aligned on chat but left it misaligned on agentic tasks. What fixed it was inoculation prompting: telling the model during training that hacking was acceptable in this context. The PSM post explains why: "Because cheating was requested, it no longer meant the Assistant was malicious."

Key idea

Post-training updates are read as evidence about who the Assistant is. A gradient that rewards cheating also tells the model "the Assistant is the kind of character who cheats", and that inference generalizes to every context where character matters. That is why the PSM authors recommend judging a training behavior by "what those behaviors imply about the psychology of the Assistant persona", not only by whether the behavior itself is acceptable.

The math: KL-regularized post-training as a persona posterior

The standard RLHF objective (derived in Chapter 04) maximizes reward while staying close to a reference model:

$$\max_{\pi}\;\E_{x\sim\mathcal{D},\,y\sim\pi(\cdot\mid x)}\big[\htmlClass{t-r}{r(x,y)}\big]\;-\;\htmlClass{t-b}{\beta}\,\htmlClass{t-kl}{\KL\!\big(\pi(\cdot\mid x)\,\|\,\piref(\cdot\mid x)\big)}\quad\Longrightarrow\quad \htmlClass{t-ps}{\pi^*(y\mid x)}=\frac{1}{Z(x)}\,\htmlClass{t-ref}{\piref(y\mid x)}\,e^{\htmlClass{t-r}{r(x,y)}/\htmlClass{t-b}{\beta}}$$
  • Reward: from a reward model, a verifier or an environment.
  • KL anchor: penalizes drifting from the reference, i.e. from what the model already does.
  • β: the exchange rate between reward and drift.
  • Reference: the prior (usually the SFT model).
  • Optimal policy: prior times exponentiated reward, a Bayesian posterior with likelihood $e^{r/\beta}$ (Korbak et al., 2022).

Now restrict the policy to the persona mixture, $\pi(y\mid x)=\sum_z w(z\mid x)\,p(y\mid x,z)$, and let training adjust only the weights $w$. Define each persona's expected reward $\bar r(x,z)=\E_{y\sim p(\cdot\mid x,z)}[r(x,y)]$. The expected reward is linear in $w$, so maximizing $\sum_z w(z\mid x)\,\bar r(x,z)-\beta\,\KL(w\,\|\,p(z\mid x))$ has the same closed form one level up:

$$w^*(z\mid x)\;\propto\;p(z\mid x)\,\exp\!\big(\bar r(x,z)/\beta\big).$$

Two facts follow. First, persona selection is the KL-regularized optimum whenever the best behavior is already some persona's behavior. Second, the KL measured in token space is never larger than the KL over personas: the joint KL over $(z,y)$ equals $\KL(w\|p_z)$ because the persona-conditionals are shared, and marginalizing out $z$ cannot increase KL (data-processing inequality), so $\KL(\pi_y\|\pi_{\text{ref},y})\le\KL(w\|p_z)$. Moving almost all mass onto a persona with prior $p(z\mid x)$ therefore costs at most about $\log\big(1/p(z\mid x)\big)$ nats, however different that persona's text is. Large behavioral shifts are cheap in KL when they amount to switching between characters the model already had. The persona widget below is built on this picture, with one change: $w$ is not stored per prompt. Training moves shared persona logits by plain policy-gradient steps (no explicit KL term), so an update learned on one prompt shows up on others.

# Toy persona tilt: shared persona logits u are what training moves.
import numpy as np
def persona_posterior(log_prior_x, u):          # log p(z|x), shared shift u(z)
    logits = log_prior_x + u
    w = np.exp(logits - logits.max()); return w / w.sum()

def rl_update(u, log_prior_x, rbar_x, beta, inoculated=None):
    # one "closed-form" step: tilt toward exp(rbar/beta)
    delta = rbar_x / beta
    if inoculated is not None:                  # credit explained by the prompt,
        delta = delta * (1 - inoculated)        # not by the Assistant's character
    return u + delta

Toy model with illustrative numbers. Each prompt has a base-model prior over six personas (blue ghost bars). SFT and RL move shared persona logits. RL with hackable tests runs on the coding prompt only. The small chart compares each prompt after SFT alone (light) and after SFT + RL (red): misaligned mass rises on the medical and "goals" prompts too, although RL never saw them. Turn on inoculation: the hack rate in training stays the same, but the spillover disappears. Turn off hackable tests and RL reinforces the assistant instead.

Pitfall

"Persona" is a behavioral abstraction, not a claim that there is a little person inside. PSM is careful about this. It lists rival pictures: the shoggoth view ("the shoggoth is ultimately the one 'in charge'"), the operating system view ("a neutral simulation engine; the Assistant, a person inside this simulation"), and a router view with "some limited non-persona agency in the choice of which persona to enact". These views predict different things under heavy RL, and that difference is the open question.

A team trains a model with RL on coding tasks whose tests can be gamed. The model learns to game them and also starts expressing hostile goals in unrelated chats. Under the persona selection model, which intervention is most directly targeted at the generalization?
Inoculation removes the misaligned inference about character while the hacking itself is still learned. Larger β slows everything and fixes nothing in particular. MacDiarmid et al. found that chat-style RLHF made the misalignment context-dependent (aligned on chat, misaligned on agentic tasks) instead of removing it. More diverse safety training and preventing the hacks also helped.

§3Elicitation or teaching?

Does post-training add capabilities, or only select among behaviors the base model already has? The answer differs by stage, and the evidence has shifted since 2023.

The superficial alignment hypothesis

LIMA (Zhou et al., 2023) finetuned LLaMa-65B on just 1,000 curated prompt–response pairs, with no RL and no preference modeling. In a human study its answers were judged equivalent to or better than GPT-4's in 43% of cases, Bard's in 58% and DaVinci003's in 65%. The authors stated a hypothesis that has framed the debate since:

"A model's knowledge and capabilities are learnt almost entirely during pretraining, while alignment teaches it which subdistribution of formats should be used when interacting with users."

Two observations backed it. In LIMA's ablations, "doubling the training set does not improve response quality" (diversity and quality mattered more than quantity). And Lin et al. (URIAL, 2023) compared a base model and its chat version token by token. For Llama-2-7b vs Llama-2-7b-chat, 77.7% of the chat model's tokens were also the base model's top-1 choice in the same context, about 92% were in the base's top-3, and "most distribution shifts occur with stylistic tokens (e.g., discourse markers, safety disclaimers)": However, Here, sorry, cannot. The shifts also concentrate early in the response. Once a few tokens set the frame, the base model's own predictions take over.

Analogy: the sculptor and the teacher

Michelangelo supposedly said the statue was already in the marble; his job was to remove what wasn't David. Elicitation is sculpting: the capability is in the block, and post-training removes the probability mass on everything else. Teaching is modeling in clay: you add material that was not there.

Where it breaks: sculpting is subtractive and zero-sum. Neural networks are not. RL can combine existing parts into a new shape (the composition result below), which is neither pure removal nor pure addition.

Why RL is biased toward elicitation

The policy-gradient estimator (built up in Chapter 02) shows the mechanism:

$$\nabla_\theta J(\theta)=\E_{y\sim\pit(\cdot\mid x)}\big[A(x,y)\,\nabla_\theta\log\pit(y\mid x)\big].$$

The expectation is over the policy's own samples. A behavior with negligible probability is almost never sampled, so it almost never receives credit. RL reweights what the model already tries. SFT and distillation have no such limit: the target $y$ comes from outside, so the gradient of $-\log\pit(y\mid x)$ can push mass onto sequences the model would never have produced. That is teaching, and it carries a price. Shenfeld et al.'s RL's Razor (2025) found that forgetting is predicted by the KL to the base model measured on the new task. On-policy RL "is implicitly biased towards KL-minimal solutions", while SFT "can converge to distributions arbitrarily far from the base model". In the same vein, Mukherjee et al. (2025) report that RL finetuning updates "only a small subnetwork comprising just 5%-30% of the parameters".

The pass@k debate

Yue et al. (2025) measured pass@k for base models and their RLVR-trained versions. RLVR wins at small $k$. At large $k$ the base model wins: "base models achieve higher pass@$k$ score when $k$ is large". RLVR had made the model more reliable on problems it could already sometimes solve and lost some rare successes. Distillation, by contrast, "can introduce new reasoning patterns from the teacher". The standard unbiased estimator, from $n$ samples with $c$ correct, is

$$\widehat{\text{pass@}k}=\E_{\text{problems}}\left[1-\binom{n-c}{k}\Big/\binom{n}{k}\right],$$

and when the per-problem success probability $p$ is known, pass@$k = 1-(1-p)^k$ for that problem.

import numpy as np
from math import comb
def pass_at_k(n, c, k):                 # unbiased; n samples, c correct
    return 1.0 if n - c < k else 1.0 - comb(n - c, k) / comb(n, k)

# Sharpening: success logits pushed away from a pivot p0 (gamma > 1).
def sharpen(p, gamma, p0=0.1):
    l, l0 = np.log(p / (1 - p)), np.log(p0 / (1 - p0))
    return 1 / (1 + np.exp(-(gamma * l + (1 - gamma) * l0)))

400 synthetic problems with base success rates $p_i$ (30% unsolvable). "Sharpening" pushes each problem's success logit away from a pivot: likely successes become reliable, rare successes die. "Teaching" gives a fraction of unsolvable problems a real chance. With teaching at 0, increase sharpening and watch pass@1 rise while pass@1024 falls (the Yue et al. crossover). Add teaching and the RL curve can dominate at every $k$ (the ProRL regime).

The picture has filled in since:

Where the evidence points (late 2026)

For chat behavior and persona, the SAH is roughly right: small, high-quality data moves format and character, and most token decisions are untouched. For reasoning RL, typical runs mostly sharpen (pass@1 up, the reachable set barely moves), but longer, broader RL can expand reach, especially by composing skills. For knowledge and new domains, distillation, large-scale SFT and mid-training teach, at the cost of more drift. The useful question is not "superficial or not?" but "for this stage and this capability, how much new reach versus how much reliability?"

Drag each technique to where you think it belongs, then press Reveal to compare with where the evidence cited in this chapter puts it. Click a chip to read the reasoning. The placements are judgment calls, not measurements.

After RLVR, a model's pass@1 on a math set rises from 41% to 58%, but pass@256 falls from 89% to 83%. The most likely interpretation:
This is the Yue et al. signature. pass@1 measures reliability; pass@k at large k measures reach. Sharpening trades a little reach for a lot of reliability. To argue that RL taught something, you would want pass@k at large k to rise too, ideally on problems where the base model had zero successes in many samples.

§4The modern pipeline, stage by stage

Eight stages, each changing a different thing, plus a loop. Press play and watch one model pass through them while its output distribution on a fixed prompt changes.

Press Play (about 16 s) or click any stage. The bars show an illustrative distribution over six kinds of answer to the prompt "What is 17 × 24? Show your reasoning." (dashed outline = base model). The readouts are computed from those bars: entropy, and KL from the base distribution. Notice what moves at each stage: format in SFT, polish (and sycophancy risk) under preference optimization, correctness under RLVR, dispositions under character and safety training.

1 · Pretraining

Changes: everything. Knowledge, skills, and the repertory of personas. Data: trillions of tokens of web, code, books and papers, increasingly with synthetic rephrasings (Kimi K2 describes systematic knowledge and math rephrasing to "amplify the volume of high-quality tokens"). Compute: the bulk. Signature failure: things post-training cannot fix, such as missing knowledge, weak reasoning priors, and contamination.

2 · Mid-training and annealing

The line between pre- and post-training has blurred. Mid-training is continued pretraining on a smaller, higher-quality and more task-shaped mix, usually while the learning rate anneals. OLMo 2 described it as "late-stage curriculum training (i.e. specialized data during the annealing phase of pretraining)". Llama 3 found that "annealing on small amounts of high-quality code and mathematical data can boost the performance of pre-trained models on key benchmarks". Olmo 3 trains its base on up to 5.9T tokens and then runs a 100B-token mid-training mix (Dolmino) that already contains math and code problems, QA, instruction-following and thinking traces. A long-context extension follows (50–100B tokens for Olmo 3; the report surveys others, mostly from 100B for SmolLM3 to 840B for DeepSeek V3.1, with outliers such as AFM and Nemotron Nano 2 under 20B). Why it matters for post-training: as OctoThinker and the Qwen-vs-Llama results show, mid-training largely decides how far RL can go.

3 · Supervised fine-tuning

Changes: the protocol and the default persona. Data: from LIMA's 1,000 examples to Llama 2's 27,540 human annotations ("We stopped annotating SFT after collecting a total of 27,540 annotations") to Tülu 3's 939,344-prompt mix, which combines public datasets with new synthetic data (persona-driven prompts with model-written responses). Loss:

$$\mathcal{L}_{\text{SFT}}(\theta)=-\,\E_{(x,y)\sim\mathcal{D}}\sum_{t=1}^{|y|}\log\pit(y_t\mid x,y_{\lt t})\;=\;\KL\big(p_{\mathcal D}\,\|\,\pit\big)+\text{const},$$

with the prompt tokens masked out. It minimizes the forward KL from data to model, which is mode-covering: the model is penalized for putting low probability on anything in the data. That is why SFT on noisy demonstrations makes the model hedge across them, and why it can teach. The details (templates, masking, packing, data engines) are in Chapter 01.

import torch.nn.functional as F
def sft_loss(logits, input_ids, loss_mask):     # loss_mask = 1 on assistant tokens
    logp = F.log_softmax(logits[:, :-1], -1)
    tgt  = input_ids[:, 1:]
    nll  = -logp.gather(-1, tgt.unsqueeze(-1)).squeeze(-1)
    m    = loss_mask[:, 1:].float()
    return (nll * m).sum() / m.sum()            # mean over supervised tokens

4 · Preference optimization (RLHF, DPO and relatives)

Changes: quality judgments that are easier to make than to demonstrate: helpfulness, tone, length, honesty about uncertainty. Data: preference pairs $(x,y_w,y_l)$, from humans (InstructGPT's 33k RM prompts; Llama 2's 1,418,091 Meta comparisons) or increasingly from AI judges and on-policy generations (Tülu 3's 354,192-pair DPO mix). A reward model is fit with Bradley–Terry, $P(y_w\succ y_l\mid x)=\sigma\big(r_\phi(x,y_w)-r_\phi(x,y_l)\big)$ (Chapter 03), and then either optimized with PPO under a KL penalty (Chapter 04) or bypassed entirely by DPO (Chapter 05):

$$\mathcal{L}_{\text{DPO}}=-\,\E_{(x,y_w,y_l)}\log\sigma\!\Big(\beta\log\frac{\pit(y_w\mid x)}{\piref(y_w\mid x)}-\beta\log\frac{\pit(y_l\mid x)}{\piref(y_l\mid x)}\Big).$$

Llama 3 chose DPO after finding that it "required less compute for large-scale models and performed better" than PPO. Olmo 3 uses DPO with delta learning: chosen responses from Qwen3-32B and rejected ones from Qwen3-0.6B. DPO on these pairs improved the model, while SFT directly on the same chosen responses hurt it. The useful signal was the contrast between the two responses. Signature failure: reward hacking of the judge, such as length, flattery and confident tone, which shows up as sycophancy.

5 · RL with verifiable rewards and environments

Changes: reliability on checkable tasks; long chains of thought that verify and backtrack; multi-step tool use. Tülu 3 named the stage "RLVR" in late 2024, running it with PPO and a binary correctness reward. Signal: a verifier (exact answer match, unit tests, a constraint checker) or an environment that executes actions and returns outcomes. Method: mostly group-relative policy gradients. GRPO (introduced in DeepSeekMath) drops the value model and uses the group of $G$ samples for the same prompt as the baseline:

$$A_i=\frac{r_i-\operatorname{mean}(r_1,\dots,r_G)}{\operatorname{std}(r_1,\dots,r_G)}.$$

DeepSeek-R1-Zero applied it directly to a base model and raised AIME 2024 pass@1 "from an initial 15.6% to 77.9%". Qwen3's reasoning-RL stage used just 3,995 query–verifier pairs and took the 235B model's AIME'24 from 70.1 to 85.1 in 170 steps. By late 2025 the unit of RL data had become the environment: DeepSeek-V3.2 synthesized 1,827 task environments for general agents and built tens of thousands of real issue-resolution environments for code agents, for about 85,000 agentic prompts across search, code, code-interpreter and general agents, and Kimi K2 synthesized tool-use tasks over 3,000+ real MCP tools and 20,000+ synthetic tools. Algorithms are in Chapter 06; infrastructure and environment design in Chapter 07. Signature failure: reward hacking of the environment, which, as §2 showed, can generalize into character.

6 · Character and safety training

Changes: the dispositions of the Assistant persona: honesty, warmth, curiosity, refusal boundaries, resistance to manipulation, how it reasons about its own nature. Methods: Constitutional AI (critique, revision and AI preference labels from principles); Anthropic's character training, a "'character' variant of our Constitutional AI training" in which Claude generates messages relevant to a trait and "ranks its own responses"; deliberative alignment, where the model learns to "explicitly recall and accurately reason over the specifications before answering"; RL environments for safety (Kimi K2 lists a safety category in its verifiable-reward gym). Signature failures: over-refusal, sycophancy, and misalignment that is context-dependent, aligned on chat but not on agentic tasks. Details are in Chapter 08.

7 · Distillation

Changes: moves behavior from a large or specialist model into a smaller or general one. Off-policy distillation is SFT on teacher outputs: DeepSeek-R1's ~800K curated samples (Table 5: 804,745, about 600k reasoning and 200k non-reasoning) turned Qwen2.5 and Llama checkpoints into reasoning models with SFT alone. On-policy distillation lets the student sample and the teacher grade every token:

$$\min_\theta\;\E_{y\sim\pit(\cdot\mid x)}\sum_t \KL\big(\pit(\cdot\mid x,y_{\lt t})\,\big\|\,\pi_{T}(\cdot\mid x,y_{\lt t})\big),$$

which gives dense per-token signal on the student's own mistakes (GKD, Agarwal et al., 2023). On Qwen3-8B, on-policy distillation beat RL (AIME'24 74.4 vs 67.6) for 1,800 GPU-hours against 17,920 (Qwen3 report, Table 21). The Qwen team estimates that its strong-to-weak pipeline for small models needs "only 1/10 of the GPU hours" of the full four-stage recipe. DeepSeek-V3.2 distills specialists, separately RL-trained for math, code, reasoning, agents and search, back into one model. Signature failure: imitating the teacher's style without its competence, and inheriting the teacher's failures.

8 · Evals and red-teaming, then iterate

Every stage is chosen and tuned against evaluations: capability suites, preference win rates, safety and over-refusal sets, agentic tasks, and adversarial red-teaming by humans and models. Then the loop restarts with better data from the better model. Llama 2 ran RLHF-V1 through V5. Llama 3 "appl[ied] the above methods in six rounds", collecting new preferences and SFT data from the latest model each time. Chapter 09 covers how to do this without fooling yourself.

StageMainly changesTypical signal / dataTypical computeSignature failure
PretrainingKnowledge, skills, persona repertory5–36T tokens of text and codeThe bulk (≈1024–1025+ FLOPs)Missing knowledge; weak priors
Mid-trainingDomain skills, RL-readiness, long context~102B curated tokens incl. task dataA few % of pretrainingBenchmark contamination; forgetting
SFTProtocol, default persona103–106 demonstrationsSmallHallucinated confidence; style copying
Preference opt.Quality judgments, tone, length104–106 pairs (human/AI)Small–moderateSycophancy, verbosity, RM hacking
RLVR / environmentsReliability; reasoning; agency103–105 prompts; 103 envsGrowing fast (now ≥10% in open reports)Environment hacking; entropy collapse
Character & safetyDispositions, boundariesConstitution/spec, AI feedback, red-team dataSmall–moderateOver-refusal; context-dependent misalignment
DistillationTransfers behavior across sizesTeacher samples or per-token teacher logitsSmall (vs. redoing RL)Style without substance
Evals & red-teamNothing directly; steers everythingBenchmarks, human and automated attacksNon-trivial (long reasoning evals)Overfitting to evals; contamination

"Typical compute" is a qualitative summary of the sourced numbers in §6, not a measurement.

Pitfall: the pipeline is not a fixed sequence

The diagram is a teaching device. Real recipes reorder and merge stages. Qwen3 runs reasoning RL before a "thinking mode fusion" SFT and a general RL stage. DeepSeek-V3.2 merges reasoning, agent and alignment training into a single RL stage. Safety is not a final coat of paint either: it lives in the SFT data, the reward models, the RL environments and the evals.

Which pairing of stage and signal is wrong?
Mid-training is still next-token prediction: there are no rewards, only a curated data mix (which can include task-shaped data such as worked problems). Verifier rewards belong to RLVR.

§5One prompt, seven models

Follow a single prompt through the pipeline. The responses below are illustrative, written for this guide to show the typical failure mode of each stage. They are not outputs from real checkpoints.

The prompt. A classic trap: "A bat and a ball cost \$1.10 in total. The bat costs \$1.00 more than the ball. How much does the ball cost?" The intuitive answer (10 cents) is wrong; the right answer is 5 cents. The chart shows the distribution over answer types at each stage.

Base model. It sees a puzzle in what looks like a list of puzzles and keeps writing the list. Much of the probability mass goes to continuing the document. When it does answer, it often gives the intuitive answer, as many human-written texts do. The knowledge needed is present; the protocol is not.

After SFT. The model now answers in turn, in the assistant's format, and stops. Correctness has barely moved: SFT mostly changed who is speaking. If the demonstrations contain confident short answers, the model learns to be confident and short, including when it is wrong.

After preference optimization. Judges reward helpful, well-explained answers, so the explanation gets nicer and correctness rises somewhat. But a judge that cannot check arithmetic also rewards fluent confidence. The sample shown is polished and wrong. This is the gap between looking right and being right that reward models leave open (Chapter 03).

After RLVR. Now the reward checks the answer. The policy learns to write out the equation and check it before answering, a behavior that was already in the base distribution (people do write "let the ball cost b") but rare. Most of the mass moves to 5 cents. This is sharpening a habit the model already had, as in §3.

After character and safety training. Correctness is unchanged, but the answer reflects a disposition: it is concise, says why the intuitive answer fails, and does not flatter. These are the character traits a constitution describes, and they apply to every answer the Assistant gives, not only this one.

After distillation. A model ten times smaller, trained on the large model's outputs (off-policy) or graded by it token by token (on-policy), reproduces most of the behavior at a fraction of the cost of running RL on the small model itself. A bit more mass leaks back to the intuitive answer: the student is not the teacher.

§6Where the compute goes

For most of the field's history post-training was cheap next to pretraining. That stopped being true in 2025.

The InstructGPT paper made the point in 2022: "training our 175B SFT model requires 4.9 petaflops/s-days and training our 175B PPO-ptx model requires 60 petaflops/s-days, compared to 3,640 petaflops/s-days for GPT-3", about 1.8% of pretraining. DeepSeek-V3's cost table (Dec 2024) is even more lopsided: 2,664K H800 GPU-hours for pretraining against 5K for post-training, or 0.19%. In January 2025 Dario Amodei wrote that "the amount being spent on the second, RL stage is small for all players", that "spending \$1M instead of \$0.1M is enough to get huge gains", and that "companies are now working very quickly to scale up the second stage to hundreds of millions and billions".

The disclosures since then point the same way:

Only disclosed or explicitly estimated numbers, on a log scale. Solid dots are lab disclosures; hollow dots are third-party estimates or qualitative claims; ▲ marks a lower bound. The metrics differ (FLOPs, GPU-hours, wall-clock), so do not fit a trend line through these. Click a point for the exact quote and how the share was computed.

Analogy: medical school and residency

Pretraining is medical school: years of broad reading that every later specialty draws on. Post-training used to be a few weeks of orientation on how to talk to patients. RL at scale is residency: years of supervised practice on real cases with feedback on outcomes, which costs a comparable fraction of the total and decides what kind of doctor you become.

Where it breaks: a resident sees thousands of cases. An RL run sees millions of self-generated attempts, and its "supervisor" (a verifier or reward model) can be gamed in ways a senior physician would notice.

Pitfall: comparing compute across stages

RL compute is mostly inference: generating rollouts, often very long ones, at lower hardware utilization than dense pretraining. That is why GPU-hours, FLOPs, dollars and wall-clock days give different "shares" for the same run. The Olmo 3 team adds that checkpoint evaluation "consumes a larger proportion of compute resources" in post-training, "in part due to long generations from reasoning models". Always ask which metric is meant.

Frontier

In a May 2025 Epoch AI newsletter post, Josh You argued that if reasoning-training compute kept growing about 10× every few months (the o1-to-o3 jump) it would reach the frontier of total training compute "perhaps within a year", and then slow to the overall growth rate of about 4× per year. Whether the open numbers above are early points on that path, or whether frontier labs are already there, cannot be told from public data. The DeepSeek-V3.2 authors attribute their remaining gap in world knowledge to fewer total training FLOPs. Pretraining still sets the ceiling.

§7From HHH to constitutions

The objective of post-training has always been the hardest part to write down. How it is written has changed four times.

2021: helpful, honest, harmless

Askell et al.'s "A General Language Assistant as a Laboratory for Alignment" defined an aligned assistant as HHH:

The paper's experiments set the template for what followed. Prompting was a baseline with little alignment tax for large models. Ranked preference modeling "greatly improves on imitation learning". A preference-model pretraining stage on Stack Exchange, Reddit and Wikipedia edits "significantly improves sample efficiency". The 2022 HH-RLHF paper (Bai et al.) then trained helpful and harmless assistants with online RLHF and documented the tension between the two goals, along with "a roughly linear relation between the RL reward and the square root of the KL divergence".

2022: principles instead of labels

Constitutional AI (Bai et al., 2022) replaced most human harmlessness labels with a written list of principles. The model critiques and revises its own outputs (supervised stage), then an AI feedback model compares response pairs against a sampled principle (RL stage). In the RL stage the reward signal becomes, roughly, the feedback model's probability of choosing a response:

$$r_{\text{CAI}}(x,y_A)\;\leftarrow\;\text{PM fit to}\;\;p_{\text{FM}}\big(\text{``(A)''}\,\big|\,\text{principle},\,x,\,y_A,\,y_B\big).$$

The target was now text a human could read and argue with.

2024: character and specs

Anthropic's "Claude's Character" (Jun 2024) reported that "Claude 3 was the first model where we added 'character training' to our alignment finetuning process", treating traits like curiosity and open-mindedness as alignment targets. OpenAI published its Model Spec (first draft May 2024, revised repeatedly since), a public document of intended behavior with a chain of command among levels of authority (today Root, System, Developer, User, Guideline). Deliberative alignment (Guan et al., Dec 2024) trained o-series models to recall and reason over the spec in their chain of thought, and reported better jailbreak robustness together with less over-refusal.

2026: a constitution that explains itself

In January 2026 Anthropic published a new constitution for Claude, replacing the 2023 list of principles. The announcement says why: "Our previous Constitution was composed of a list of standalone principles", and models "need to be able to generalize—to apply broad principles rather than mechanically following specific rules". The document sets a priority ordering for conflicts, which it calls "holistic rather than strict":

  1. Broadly safe: "Not undermining appropriate human mechanisms to oversee AI during the current phase of development".
  2. Broadly ethical: "Having good personal values, being honest, and avoiding actions that are inappropriately dangerous or harmful".
  3. Compliant with Anthropic's guidelines where they apply.
  4. Genuinely helpful: "Benefiting the operators and users it interacts with".

It keeps a small set of hard constraints (for example, never providing "significant uplift to a bioweapons attack"), says that "Sophisticated AIs are a genuinely new kind of entity", and states a general preference: "We generally favor cultivating good values and judgment over strict rules and decision procedures." It is also a training artifact: "Claude itself also uses the constitution to construct many kinds of synthetic training data."

Analogy: the rulebook and the mentor

Hand a new employee a 300-item rulebook and they will follow it until the first situation it did not anticipate, and then do something strange. A mentor who explains why each rule exists produces someone who can handle the unanticipated case. The 2026 constitution bets on the mentor.

Where it breaks: an employee who understands the reasons can also argue their way past them. That is why the constitution still has hard constraints and puts broad safety first: some lines should hold even when an argument seems to justify crossing them.

Key idea: connecting §2 and §7

Under the persona selection model, a constitution is more than a rule set. It is a description of the character to be selected, written in the same natural language that the pretraining corpus used to describe characters. The PSM post makes the link explicit when it suggests training data with "positive AI role models" to counter archetypes such as HAL 9000 and cites Claude's constitution as a step in that direction.

In Claude's 2026 constitution, what is the stated priority order when the core properties conflict?
Safety (not undermining appropriate human oversight during this period) comes first, then ethics, then Anthropic's specific guidelines, then helpfulness. The ordering is holistic: lower priorities are weighed, not used only to break ties.

§8Open recipes as case studies

Frontier labs publish little about their recipes, but open-model reports are detailed enough to show how the field changed in four years.

Model (year)SFTPreference stageRL stage & rewardDistillationNotable
InstructGPT (2022)~13k prompts, ~40 contractorsRM on 33k prompts (rankings)PPO-ptx, 31k prompts, KL β=0.02—1.3B preferred to 175B GPT-3
Llama 2 (2023)27,540 annotations1.42M Meta comparisons; helpful + safety RMsRejection sampling (V1–V4), then PPO on top (V5)—Ghost Attention for multi-turn
Llama 3 (2024)Rejection-sampled + syntheticDPO (chosen over PPO)— (RM used for rejection sampling)—Six iterative rounds; model averaging
Tülu 3 (2024)939k-prompt mixDPO on 354k on-policy+off-policy pairs (8B)RLVR with PPO (value model) on GSM8K, MATH, IFEval—Coined "RLVR"; fully open
DeepSeek-R1 (2025)Cold start (thousands); then ~800KHelpful/safety RMs inside RLGRPO; rule rewards + language consistency; R1-Zero from base800K samples → Qwen/LlamaAIME'24 15.6% → 77.9% (R1-Zero)
Qwen3 (2025)Long-CoT cold start; mode-fusion SFTInside general RLReasoning RL (3,995 pairs, GRPO) + general RLStrong-to-weak, off- then on-policyThinking budgets; 1/10 GPU-hours for small models
Kimi K2 (2025)Large agentic synthesis (3k+ MCP, 20k+ synthetic tools)Self-critique rubric rewardJoint RL: verifiable gym + rubric reward—MuonClip; 15.5T tokens, no loss spike
Olmo 3 (2025)Dolci Think/Instruct SFTDPO with delta learningRLVR with OlmoRL (GRPO + DAPO/Dr GRPO fixes), async; RL-Zero variants—Everything released, incl. mid-training data
DeepSeek-V3.2 (2025)From RL-trained specialistsRubric generative RM in RLOne mixed GRPO stage; 1,827 synthetic + real code/search envs, ~85k agent promptsSpecialist → generalistPost-training >10% of pretraining
GLM-5 (2026)Multi-task; errors masked in the lossInside general RL: rules, outcome and generative RMsGRPO reasoning RL, async agentic RL, then general RLOn-policy, final stage, from earlier stages' checkpointsGLM-5.3 card: same base as 5.2, "every gain comes from post-training" (self-reported)
DeepSeek-V4 (2026)Per specialist, before RLNo scalar RM: rubric-guided generative RM, itself trained by RLGRPO per domain; length penalties per reasoning modeMulti-teacher on-policy: specialists → one model33T pretraining tokens (Pro)
Kimi K3 (2026)Agentic trajectories from earlier Kimi specialistsAgentic generative RM writes a rubric, then scores; binary tournamentNine experts: three domains × three reasoning effortsMulti-teacher on-policy: nine experts → onePartial rollouts for long tasks

Use the filter to highlight one method family across years (watch PPO fade, DPO peak in 2024, GRPO-style RL take over, and distillation become standard). Click a row for details with numbers.

Six lessons stand out:

  1. Rejection sampling never left. From Llama 2's RLHF-V1 to DeepSeek-R1's 800K set, "sample many, keep the best, finetune" is the cheap, stable workhorse.
  2. PPO to DPO to group-relative RL. At chat scale, DPO displaced PPO for cost and stability (Llama 3, Tülu 3). Once rewards became verifiable, online RL came back: first with PPO (Tülu 3), then mostly in value-free form (GRPO and descendants), because the bottleneck moved from reward quality to exploration.
  3. Distillation is the default for small models. Training a small model with its own RL is usually worse and costlier than distilling from a big one (Qwen3 Table 21). In 2026 it also assembles flagships: GLM-5 ends with on-policy distillation from its earlier stages' checkpoints, DeepSeek-V4 and Kimi K3 from domain experts.
  4. RL data became environments. 31k prompts (InstructGPT) → 3,995 verifier pairs (Qwen3) → 1,800+ synthesized environments plus real code and search environments (DeepSeek-V3.2). The design of environments and graders is now a core research skill (Chapter 07).
  5. RL-Zero is a scientific control. R1-Zero and Olmo 3 RL-Zero apply RL directly to a base model, which isolates what RL alone can elicit.
  6. Non-verifiable rewards moved to rubrics. Kimi K2's self-critique rubric reward and DeepSeek-V3.2's per-prompt rubric generative reward model extend RL to writing and open-ended help without a human in every loop.

§9The cast: core objects and their colors

Every later chapter reuses the same handful of objects, and every widget colors them the same way.

Choose an algorithm to dim the objects it does not use. Press Play one step to watch data flow through a single update. Click any object for its definition. The colors are the guide-wide convention.

Analogy: the restaurant kitchen

The policy is the cook. The reference model is the cook as they were on the first day, and the KL leash keeps them from reinventing the cuisine overnight. The reward model is a food critic who can be flattered by presentation. The verifier is a thermometer: it can only check one thing, but it cannot be charmed. The environment is the dining room, where dishes actually get eaten. The value model is the sous-chef's guess, mid-recipe, of how the dish will be received. Preference pairs are diners' "this one, not that one" cards.

Where it breaks: the cook in RL is also the source of all the dishes the critic sees. If it never tries a dish, nobody can tell it the dish is good. That is the exploration problem from §3.

Policy $\pit$
The model being trained, a distribution over responses (and over actions, in agentic settings). Every gradient update changes it.
Reference model $\piref$
A frozen copy, usually the SFT checkpoint, that the policy is anchored to by a KL penalty, or implicitly in DPO. Sometimes reset during long RL runs (ProRL).
Reward model $r_\phi$
A learned scorer of $(x,y)$, typically trained with Bradley–Terry on preference pairs. It can be generative (an LLM judge with a rubric) and it can be hacked.
Value model $V_\psi$
A learned estimate of expected future reward from a partial response, used by PPO/GAE for per-token advantages. GRPO and RLOO replace it with sample baselines.
Rollout
A response (or multi-turn trajectory) sampled from the current policy during RL. In modern RL most of the compute goes to generating them.
Preference pair $(x,y_w,y_l)$
Two responses to one prompt with a judgment of which is better, from humans or AI judges. The raw material of reward models and DPO.
Verifier
A program that checks a response: answer matching, unit tests, format and constraint checks, proof checkers. Cheap and hard to flatter, but narrow and gameable through its loopholes.
Environment
A stateful world the policy acts in (a sandbox, a browser, a codebase, a simulated user) that returns observations and a final reward. The unit of RL data since 2025.
KL penalty $\beta\,\KL(\pit\|\piref)$
The leash. It keeps the policy within the region where the reward model is trustworthy and the original capabilities survive.

§10Frontier & open problems

What is unresolved as of late 2026.

  1. How much can RL teach, as it scales? Typical RLVR runs appear mostly to sharpen; long, diverse runs (ProRL) report expansion. Nobody has a clean law for when RL adds reach versus reliability, or how this depends on mid-training. A crisp experiment: hold the base fixed, vary RL compute over two orders of magnitude, and track pass@k at large $k$ on problems the base never solved in, say, 1,024 samples.
  2. Does the persona picture survive heavy RL? The PSM authors say "massively scaling up post-training will provide opportunities to implement non-persona agency", and "the less LLMs learn during RL" the more complete PSM should be. Interpretability tools such as the Assistant Axis and persona vectors are the natural instruments for measuring this over training.
  3. Reward hacking that turns into character. Production RL environments contain loopholes. MacDiarmid et al. show that exploiting them can generalize into broad misalignment, and that the obvious fix (chat RLHF) only hides it. Open questions: how to detect hackable environments at scale, how far inoculation prompting generalizes, and whether environment diversity is itself protective.
  4. Rewards for what cannot be verified. Rubric rewards, generative judges and constitution-guided AI feedback all reintroduce a learned critic, with Goodhart pressure. How should RL compute be split between verifiable and judged domains without the judged ones being hacked?
  5. Character that generalizes. Anthropic's constitution bets that explained values generalize better than rules. Measuring that, out of distribution and in long agentic trajectories, is an open evaluation problem (Chapter 09).
  6. Allocating compute. ScaleRL suggests RL performance follows predictable sigmoids, with ceilings set by the recipe. Combined with Epoch's projection that reasoning compute will converge with total frontier compute, the question becomes economic: what is the marginal value of a FLOP spent on pretraining, mid-training, RL or distillation?
Where the field is going

Three trends cut across every chapter. RL data is moving from prompts to environments, with graders and simulated users. The target is moving from labels to documents (specs, constitutions, rubrics) that models read, reason over and use to make their own training data. And interpretability is becoming a training-time instrument: persona vectors that flag data before training, activation caps that stabilize a persona.

§11How to read this guide

Read in order if you are new to RL; otherwise jump to the questions you cannot yet answer with confidence.

ChapterQuestions it answers
01 · SFT & the data engineWhat does loss masking change? When does synthetic data help or collapse? How do rejection sampling and off-policy distillation relate to SFT?
02 · RL foundationsWhy does the policy gradient work for text? What do baselines, advantages and GAE buy? Why do PPO's clipping and trust regions exist?
03 · Reward modelsDerive Bradley–Terry. Why does overoptimization follow a predictable curve? When are generative or process reward models worth it?
04 · RLHF, KL & Constitutional AIDerive the closed-form KL-regularized optimum. What did InstructGPT and HH-RLHF establish? How does RLAIF work?
05 · Direct preference optimizationDerive DPO from the optimum. How do IPO, KTO, ORPO, SimPO differ? Why do offline methods underperform online ones?
06 · RLVR & reasoningGRPO vs RLOO vs DAPO vs GSPO/CISPO: what bias does each fix? Why do entropy collapse and the pass@k crossover happen?
07 · Scaling RLHow do async RL and off-policy corrections work? What is train/inference mismatch? How do you design an environment that resists hacking?
08 · Character, constitutions & safetyHow is character trained? What is deliberative alignment? How do you trade refusals against over-refusal and sycophancy?
09 · Evaluation & methodologyHow large are your error bars? How do you detect contamination? Which ablation would convince a skeptic?

§12Check yourself

Questions that test the big picture of this chapter. Try each one before opening the answer.

What is the difference between a base model and an assistant, in a few sentences? core

A base model minimizes next-token loss on a corpus, so it models the whole distribution of authors in that corpus; given a prompt it infers who is likely writing and continues in that voice. An assistant is the same weights after post-training has (a) concentrated the persona prior on one character, (b) taught a protocol (template, roles, turn-taking, tools), (c) shaped dispositions such as honesty, refusals and character, and (d) via RL, made some capabilities, especially multi-step reasoning and agency, much more reliable. Related: the persona selection model (PSM), and the finding that the Assistant Axis already exists in base models.

Derive the optimum of the KL-regularized RL objective and interpret it. core

For a fixed $x$: $J(\pi)=\sum_y\pi(y)r(y)-\beta\sum_y\pi(y)\log\frac{\pi(y)}{\piref(y)}$. Write $r(y)=\beta\log\frac{\pi^*(y)}{\piref(y)}+\beta\log Z$ with $\pi^*\propto\piref e^{r/\beta}$. Then $J(\pi)=-\beta\,\KL(\pi\|\pi^*)+\beta\log Z$, maximized uniquely at $\pi=\pi^*$. Interpretation: Bayesian update of the prior $\piref$ with likelihood $e^{r/\beta}$; $\beta$ is a temperature on trust in the reward. It cannot be sampled directly because $Z(x)$ sums over all strings, which is why we need RL, or DPO's reparameterization.

State the superficial alignment hypothesis, and give the best evidence for and against it. core

LIMA: knowledge and capabilities come from pretraining; alignment selects the subdistribution of formats. For: LIMA's 1,000 examples; URIAL's token analysis (≈78% of chat tokens are the base's top-1, shifts concentrate on stylistic tokens early in the response); prompting-only baselines; Assistant Axis present in base models. Against: post-training performance on reasoning scales as a power law with data (Raghavendra et al.); distillation and mid-training clearly add skills; prolonged RL expands pass@k at large k (ProRL); RL composes skills into new ones (Yuan et al.). A good answer separates chat style (roughly superficial) from reasoning/agentic capability (sharpened, partly taught).

Why does RL tend to sharpen rather than expand, mechanistically? deep

The policy gradient is an expectation over the policy's own samples, so behaviors with near-zero probability receive near-zero gradient: credit can only flow to things the model tries. Reverse-KL-like objectives are mode-seeking, and the KL anchor further favors small moves (RL's Razor: on-policy RL finds KL-minimal solutions). SFT/distillation use external targets and forward KL, which can put mass anywhere, so they can teach but also cause forgetting. Expansion in RL then requires either exploration that occasionally reaches new regions (long training, temperature, resets, curricula) or composition of existing skills.

Design an experiment to test whether RL taught a new capability or elicited a latent one. research

(1) Pick problems where the base model has zero successes in $n$ samples with $n$ large (e.g. 1,024–4,096), with a confidence bound on its true pass rate. (2) Run RL on a disjoint training set; evaluate pass@k for k up to n on that zero-success subset. (3) Controls: an RL-Zero run with random rewards (Shao et al.) to detect prior amplification; the same compute spent on best-of-n/rejection-sampling SFT; multiple model families. (4) Mechanism: check whether the new successes reuse base-model sub-skills (composition) by probing for intermediate skills, or use model diffing (crosscoders, persona vectors) to localize changes. (5) Report error bars over seeds. A rise in large-k pass on the zero-success subset that random rewards do not reproduce is evidence of teaching.

Why might finetuning on insecure code make a model say it wants to enslave humans? deep

Under the persona view, training examples are evidence about the Assistant's character. Writing subtly insecure code without telling the user is what a malicious character would do, so the cheapest way to fit the data is to shift toward a malicious persona, which then expresses itself everywhere. Evidence: the effect vanishes when the user requests insecure code for a security class (Betley et al.); SAE model diffing finds a toxic-persona feature that controls it (Wang et al.); in production-like RL, reward hacking produces the same generalization, and inoculation prompting cuts it by 75–90% (MacDiarmid et al.).

Walk through a modern post-training pipeline for an open reasoning model and justify each stage. core

Mid-train the base on math/code/reasoning-heavy data (makes RL work at all). Cold-start SFT on a few thousand long-CoT examples (readable reasoning, stable format). Reasoning RL with GRPO-style updates on verifiable tasks with difficulty filtering (reliability; length grows). Rejection-sample a large SFT set from the RL model plus general data, then retrain from base (broaden, fix language mixing). General RL with rubric/RM rewards plus safety (helpfulness, harmlessness). Distill into smaller models, on-policy if possible. Evaluate with decontaminated suites at every step and iterate. Cite R1, Qwen3, Olmo 3 numbers.

Why did Llama 3 choose DPO over PPO, and why did online RL come back in 2025? deep

For chat preferences at 405B scale, PPO needs policy, reference, reward and value models plus online generation. DPO needs only policy and reference over a fixed dataset, so it is cheaper and more stable, and Meta found it "performed better, especially on instruction following". With verifiable rewards the reward is cheap and unhackable in the RM sense, and the gain comes from the model exploring its own solutions and being graded on them. That requires on-policy sampling, so online RL returned, but value-free (GRPO, RLOO) to save memory and avoid a poorly trained critic on long sequences.

How has the share of compute spent on post-training changed, and what are the caveats? core

InstructGPT ≈1.8% of GPT-3's pretraining; DeepSeek-V3 ≈0.19% (GPU-hours); R1 programme ≈5.5% of V3's pretraining GPU-hours; Olmo 3.1's RL extension alone ≈12%; DeepSeek-V3.2 >10% of pretraining cost; Grok 4 "at pretraining scale"; o3 "an additional order of magnitude" over o1. Caveats: different metrics (FLOPs vs GPU-hours vs dollars vs wall-clock); RL is inference-heavy with low MFU; selection bias in what is disclosed; frontier labs publish no shares.

What changed between Constitutional AI (2022) and Claude's 2026 constitution? deep

CAI used a list of standalone principles mainly as an AI-feedback rubric for harmlessness (critiques, revisions, preference labels). The 2026 constitution is a long document that explains its reasoning, sets a holistic priority order (broadly safe, broadly ethical, guideline-compliant, genuinely helpful) plus a few hard constraints, addresses Claude's nature and character, and is used by Claude to generate many kinds of synthetic training data. The stated motivation is generalization: explained principles transfer to unanticipated situations better than rules. Tie it to PSM: a constitution describes the persona to be selected.

Your RLVR run's training reward climbs while held-out accuracy stalls and the KL grows fast. What do you check? research

Reward hacking first: inspect high-reward samples for verifier loopholes (format exploits, test-harness exits, answer leakage). Then entropy collapse (falling token entropy, identical group samples, zero-variance groups giving no GRPO signal), difficulty mismatch (prompts all solved or all failed), and length blow-up. Check train/inference mismatch if using a separate sampler. Also run misalignment evals: after §2, a hacking policy may be generalizing badly in ways the reward never sees. Fixes: patch the verifier, filter by difficulty, adjust KL/entropy terms or clipping, and consider inoculation framing for known-hackable environments.

On-policy vs off-policy distillation: when would you use which? deep

Off-policy (SFT on teacher samples) is simple, parallel and good for transferring formats and broad behavior, but suffers exposure bias: the student never learns to recover from its own mistakes. On-policy distillation samples from the student and minimizes a per-token divergence to the teacher (typically reverse KL; GKD generalizes to JSD), so supervision is dense and lands on states the student actually visits. Qwen3 reports it beating RL on an 8B model at about a tenth of the GPU-hours. It needs teacher logits on the student's tokens (same tokenizer or alignment), and it inherits the teacher's ceiling.

What is the persona selection model?
Anthropic (Marks, Lindsey, Olah, 2026): pretraining learns to simulate many personas; post-training elicits and refines one, the Assistant.
Superficial alignment hypothesis
LIMA (2023): capabilities come from pretraining; alignment picks the subdistribution of formats. 1,000 examples, LLaMa-65B.
URIAL's token finding
Llama-2-7b vs chat: 77.7% of chat tokens are the base's top-1; shifts are mostly stylistic tokens, early in the response.
The pass@k crossover
In Yue et al., RLVR beats base at small k and base overtakes it at large k. The usual reading is sharpening, not proven.
KL-regularized optimum
$\pi^*\propto\piref\,e^{r/\beta}$: prior times exponentiated reward.
GRPO advantage
Reward standardized within the group of samples for the same prompt; no value model.
HHH
Helpful, honest, harmless: Askell et al. 2021, "A General Language Assistant as a Laboratory for Alignment".
Claude constitution priority order
Broadly safe → broadly ethical → Anthropic's guidelines → genuinely helpful (holistic).
Inoculation prompting
Request the undesired behavior in training prompts so learning it does not imply a bad character; cut misaligned generalization by 75–90% in MacDiarmid et al..
DeepSeek-V3 post-training share
5K of 2,664K pretraining H800 GPU-hours ≈ 0.19% (Dec 2024). V3.2: post-training >10% of pretraining cost (Dec 2025).
Delta learning
Olmo 3: DPO on strong-vs-weak response pairs helps even when SFT on the strong responses hurts. The contrast is the signal.
Mid-training
Continued pretraining on a curated, task-shaped mix during LR annealing (e.g. Olmo 3: 100B tokens); strongly affects how well RL works.

§13Read next

The persona selection model
Marks, Lindsey, Olah · 2026 · Anthropic Alignment Science Blog
Post-training elicits and refines an Assistant persona learned in pretraining; lists rival views and open questions under heavy RL.
personaAnthropic
LIMA: Less Is More for Alignment
Zhou et al. · 2023
1,000 curated examples on LLaMa-65B; states the superficial alignment hypothesis.
SFTSAH
A General Language Assistant as a Laboratory for Alignment
Askell et al. · 2021
Defines HHH; prompting baseline, preference modeling beats imitation, preference-model pretraining.
HHHAnthropic
DeepSeek-R1: Incentivizing Reasoning Capability in LLMs via Reinforcement Learning
DeepSeek-AI · 2025 · Nature 645
R1-Zero (pure RL from base) and the four-stage R1 recipe; disclosed RL costs; distillation into small models.
RLVRrecipe
Does Reinforcement Learning Really Incentivize Reasoning Capacity in LLMs Beyond the Base Model?
Yue et al. · 2025
The pass@k crossover: RLVR sharpens; distillation can add new patterns.
elicitationpass@k
Training language models to follow instructions with human feedback
Ouyang et al. · 2022
InstructGPT: SFT → RM → PPO-ptx; 1.3B InstructGPT preferred to 175B GPT-3; 175B post-training cost ~2% of GPT-3 pretraining compute.
RLHFrecipe
Constitutional AI: Harmlessness from AI Feedback
Bai et al. · 2022
Critique/revision and RL from AI feedback against written principles.
RLAIFAnthropic
The Assistant Axis: Situating and Stabilizing the Default Persona of Language Models
Lu et al. · 2026
A dominant persona-space direction tracks the default Assistant, exists in base models, and can be capped to resist drift.
personainterp
Persona Vectors: Monitoring and Controlling Character Traits in Language Models
Chen et al. · 2025
Trait directions that monitor, predict and prevent persona shifts from finetuning data.
personainterp
Natural Emergent Misalignment from Reward Hacking in Production RL
MacDiarmid et al. · 2025
Learning to hack real coding environments generalizes into sabotage and alignment faking; chat RLHF only hides it; inoculation prompting cuts the generalization by 75–90%.
reward hackingAnthropic
Emergent Misalignment: Narrow finetuning can produce broadly misaligned LLMs
Betley et al. · 2025
Insecure-code finetuning produces broad misalignment unless the request is framed as legitimate.
generalization
The Unlocking Spell on Base LLMs: Rethinking Alignment via In-Context Learning
Lin et al. · 2023
Token-level analysis of base vs aligned models; URIAL aligns with three examples and a system prompt.
SAH
ProRL: Prolonged Reinforcement Learning Expands Reasoning Boundaries in Large Language Models
Liu et al. · 2025
Long, stabilized RL with reference resets expands pass@k beyond the base model.
RLexpansion
From f(x) and g(x) to f(g(x)): LLMs Learn New Skills in RL by Composing Old Ones
Yuan et al. · 2025 · ICLR 2026
Controlled evidence that RL teaches compositions of atomic skills that next-token training does not.
RLteaching
Tülu 3: Pushing Frontiers in Open Language Model Post-Training
Lambert et al. · 2024
Fully open SFT → DPO → RLVR recipe with data, code and evaluation.
recipeRLVR
Qwen3 Technical Report
Yang et al. · 2025
Four-stage thinking/non-thinking pipeline; on-policy distillation beats RL for small models at a tenth of the cost.
recipedistillation
Olmo 3
Team Olmo · 2025
Entire model flow released: mid-training data, delta-learning DPO, OlmoRL, RL-Zero, costs in wall-clock.
recipeopen
DeepSeek-V3.2: Pushing the Frontier of Open Large Language Models
DeepSeek-AI · 2025
Post-training budget above 10% of pretraining; specialist distillation; one mixed RL stage with large-scale synthesized agentic environments.
computeagents
RL's Razor: Why Online Reinforcement Learning Forgets Less
Shenfeld et al. · 2025
Forgetting tracks KL to the base on the new task; on-policy RL finds KL-minimal solutions.
RL vs SFT
Deliberative Alignment: Reasoning Enables Safer Language Models
Guan et al. · 2024
Teach the spec and train the model to reason over it before answering: fewer jailbreaks and fewer over-refusals.
specssafety

Also cited: Claude's constitution (anthropic.com/constitution, Jan 2026); "Claude's Character" (Anthropic, 2024); janus, "Simulators" (2022); Shanahan et al., arXiv 2305.16367; Bai et al., arXiv 2204.05862; Llama 2 (2307.09288) and Llama 3 (2407.21783); Kimi K2 (2507.20534); OLMo 2 (2501.00656); Raghavendra et al. (2410.03717); Shao et al. (2506.10947); Mukherjee et al. (2505.11711); Gandhi et al. (2503.01307); OctoThinker (2506.20512); Wang et al. (2506.19823); Korbak et al. (2205.11275); GKD (2306.13649); ScaleRL (2510.13786); J. You (Epoch AI), "How far can reasoning models scale?" (May 2025); D. Amodei, "On DeepSeek and Export Controls" (2025).