← Back to article

Equation 6 · Claude, From First Principles: Training, Constitutional Methods, and What Actually Shapes a Response

What does this equation mean?

J(θ)=Ex∼D, y∼πθ(⋅∣x)[r(x,y)]−βDKL(πθ(⋅∣x) ∥ πref(⋅∣x))J(\theta) = \mathbb{E}_{x \sim \mathcal{D},\ y \sim \pi_\theta(\cdot \mid x)}\left[r(x,y)\right] - \beta D_{\mathrm{KL}}\left(\pi_\theta(\cdot \mid x) \,\|\, \pi_{\mathrm{ref}}(\cdot \mid x)\right)

Read the formula alongside the article passage below. Each part has a deeper page with its role in the equation, the supporting passage and nearby citations.

This equation states an equality: the expressions on both sides have the same value under the article’s assumptions. Read the equation part by part below; each part has a contextual explanation and a link to its mathematical background.

Read it piece by piece

JJ

Symbol J

J is computed from the expected values combined on the right.

Understand this part →

θ\theta

Symbol θ

θ is an argument of the function-like quantity on the left; its role is set by that function’s stated inputs.

Understand this part →

Ex∼D, y∼πθ(⋅∣x)\mathbb{E}_{x \sim \mathcal{D},\ y \sim \pi_\theta(\cdot \mid x)}

Symbol E_x sim D, y sim pi_θ( × mid x)

ExE_x sim D, y sim pi_θ( × mid x) appears inside an expected value, so its contribution is averaged under the distribution or condition shown by that operator.

Understand this part →

rr

Symbol r

r appears inside an expected value, so its contribution is averaged under the distribution or condition shown by that operator.

Understand this part →

xx

Symbol x

x appears inside an expected value, so its contribution is averaged under the distribution or condition shown by that operator.

Understand this part →

yy

Symbol y

y appears inside an expected value, so its contribution is averaged under the distribution or condition shown by that operator.

Understand this part →

β\beta

Symbol β

the weighted by.

Understand this part →

DKLD_{\mathrm{KL}}

Symbol D_KL

DKD_KL appears inside an expected value, so its contribution is averaged under the distribution or condition shown by that operator.

Understand this part →

πθ\pi_\theta

Symbol pi_θ

pi_θ appears inside an expected value, so its contribution is averaged under the distribution or condition shown by that operator.

Understand this part →

πref\pi_{\mathrm{ref}}

Symbol pi_ref

piri_ref appears inside an expected value, so its contribution is averaged under the distribution or condition shown by that operator.

Understand this part →

=

=

The expressions on both sides represent the same quantity under the stated assumptions.

Understand this part →

See an illustrated explanation →
multiplication

multiplication

Multiply the quantities on either side.

Understand this part →

subtraction

subtraction

Subtract the following term or group from the preceding one. A leading minus marks a negative quantity.

Understand this part →

subscript

subscript

The lower label selects a particular version, component, or indexed member of the quantity. For example, x₀ and xₜ can be values at different positions.

Understand this part →

How to interpret it

Read it with the definitions, units, and assumptions supplied by the article.

What the article says around this equation

The optimisation itself has a specific and revealing shape. Rather than maximising the fitted reward outright, the standard formulation constrains the updated policy to stay close to a reference policy, ordinarily the model just after supervised fine-tuning, one step removed from the raw pretrained prior: J(θ)=Ex∼D, y∼πθ(⋅∣x)[r(x,y)]−βDKL(πθ(⋅∣x) ∥ πref(⋅∣x))J(\theta) = \mathbb{E}_{x \sim \mathcal{D},\ y \sim \pi_\theta(\cdot \mid x)}\left[r(x,y)\right] - \beta D_{\mathrm{KL}}\left(\pi_\theta(\cdot \mid x) \,\|\, \pi_{\mathrm{ref}}(\cdot \mid x)\right). The reward term r(x,y) pulls the policy toward whatever the fitted preference model scores highly; the Kullback–Leibler penalty, weighted by β\beta , pulls it back toward the reference distribution. That second term is not a minor regulariser. It is the load-bearing assumption behind the entire method: remove it, and a policy optimised hard enough against an imperfect…
Read the full surrounding passage
The optimisation itself has a specific and revealing shape. Rather than maximising the fitted reward outright, the standard formulation constrains the updated policy to stay close to a reference policy, ordinarily the model just after supervised fine-tuning, one step removed from the raw pretrained prior: J(θ)=Ex∼D, y∼πθ(⋅∣x)[r(x,y)]−βDKL(πθ(⋅∣x) ∥ πref(⋅∣x))J(\theta) = \mathbb{E}_{x \sim \mathcal{D},\ y \sim \pi_\theta(\cdot \mid x)}\left[r(x,y)\right] - \beta D_{\mathrm{KL}}\left(\pi_\theta(\cdot \mid x) \,\|\, \pi_{\mathrm{ref}}(\cdot \mid x)\right). The reward term r(x,y) pulls the policy toward whatever the fitted preference model scores highly; the Kullback–Leibler penalty, weighted by β\beta , pulls it back toward the reference distribution. That second term is not a minor regulariser. It is the load-bearing assumption behind the entire method: remove it, and a policy optimised hard enough against an imperfect reward model will find outputs the reward model over-scores without those outputs actually being better, a failure usually called reward hacking. Casper and thirty-one co-authors, surveying RLHF across the field rather than defending any one lab’s implementation, catalogue this and related problems as fundamental rather than incidental — reward models are themselves approximations fit to a finite, imperfect sample of human judgment, and optimising hard against an approximation reliably finds its blind spots [ 10 ] . This is a genuine point of disagreement in the field, not a settled matter: labs running RLHF treat the KL anchor, reward-model ensembling, and process-level checks as adequate mitigations in practice, while Casper and colleagues argue the underlying problem is structural and call for auditing and disclosure standards beyond what is currently published by any lab. Both positions are defensible from public evidence; this article does not adjudicate between them.

Read the equation in its article →

Sources cited in the surrounding passage

These citations give research context. Read each source to check which claims it supports.

Return to Claude, From First Principles: Training, Constitutional Methods, and What Actually Shapes a Response

See this formula across 1 published context →

Browse the mathematical compendium →