Fast Sampling and Interactive World Models

A picture that takes 50 network calls cannot run a game. Learn to jump from noise to an image in one call, then roll that fast generator forward into a video you can steer.

Learn how flow maps, MeanFlow, distribution matching and Self Forcing turn a slow sampler into a fast one, and what each shortcut costs.

Drag the number of network calls down to one, with Few Euler steps chosen. Watch the samples pile up where the data has none. Then pick Flow map and see the jump land on the right spots. Then we build, piece by piece, the jump, its training signals, the crowd comparison and the video loop.

You need a rough idea of what a probability is and a little calculus (what a slope is). We build the rest from zero.

Based on Lecture 14 of Penn CIS 6280: World Models (Fall 2026), taught by Jiatao Gu. Lecture slides. Every idea is re-taught here in our own words and devices; it follows Lecture 7, Latent-Variable and Adversarial Models in this series, and Lecture 13 on video world models.

Cross the noise in few calls

1

Toy world, ours: data is two bumps at minus 1.6 and plus 1.6 (spread 0.25); noise is a standard bell curve. Time runs left to right, noise at 0 and data at 1, as in the lecture. The teacher velocity is exact for this toy. The flow map here is idealised: it lands exactly where the teacher’s path ends. A trained flow map only approximates that.

Chapter 0

Why a World Model Must Be Fast

Count the network calls a frame can afford, and see why a model that needs fifty of them cannot run a game

Picture a game in which a model draws every frame. You press the right arrow. The character should step right now, not two seconds from now. If the picture arrives late, the game is not a game any more.

This lecture is about that wait. It is the last step of the course's road to interactive world models: models that predict what happens next and that answer your actions fast enough to play with. Lecture 1 defined a world model, and Lecture 7 built the generators that draw from noise. Today those generators learn to be quick.

What one frame costs today

A diffusion or flow model draws a picture by walking. It starts from pure noise at time 0 and follows a path to a clean picture at time 1. This lecture uses that direction throughout. At each stop the model reports a velocity: which way, and how fast, the picture should change right now. The sampler takes a small step along that velocity and asks again.

Each time the sampler asks the network, we call it one network call, also called one function evaluation. It is one pass of the picture through the big neural network. A network call is the unit of cost in this whole lecture. Fifty small steps mean fifty calls.

Now count what a frame can afford. A film shows 24 frames in a second, so each frame has about 41.7 milliseconds. A game at 60 frames per second has 16.7 milliseconds. The device below lets you set the number of calls and the time one call takes, then shows how much of the budget is gone.

Spend the frame budget

Each yellow block is one network call. The two marks are the time one frame may take at 24 and at 60 frames per second. Drag the calls, then change how long one call takes.

50

Illustrative: the three call times are round numbers we chose, not measurements of any model. The two budgets are plain arithmetic: 1000 ms divided by 24 and by 60 frames per second. Real video models also draw several frames per call, which Chapter 9 returns to.

With 50 calls at 25 milliseconds each, one frame takes 1,250 milliseconds. That is 0.8 frames per second. To reach 24 frames per second at this call time, you may spend only one call. Faster hardware helps a little. Fewer calls help a lot more. That is the whole motivation.

Why not just take fewer steps?

You can. The hero at the top of this page shows what happens. In the toy world, the data sits in two clumps and the noise is a single bell curve. One big Euler step (move by the velocity times the step size) uses the velocity at the start of the path and walks the whole way in a straight line. Every sample lands in the middle, where the data has nothing. The picture is a blur of the two clumps.

The reason is simple. The velocity the teacher reports is a local fact about one point. It is correct for a tiny step and wrong for a long one, because the path bends. A fast sampler has to know where the path goes, not just which way it points at the start.

Three ideas, then a video loop

The lecture gives three answers to this problem, then uses them on video. We follow the same order.

First, flow maps (Chapters 1 to 4). A flow map learns the jump itself: give it a point and a time to aim for, and it returns the point on the same path at that later time. BOOT, π-Flow, consistency models and MeanFlow are four ways to train one.

Second, distribution matching (Chapters 5 to 8). Here the student need not copy the teacher's paths at all. It only has to produce the right crowd of pictures. DMD, Drifting and FD-Loss compare two crowds and push one toward the other.

Third, autoregressive video (Chapters 9 and 10). A video is drawn one chunk at a time, each chunk drawn by a fast generator that reads the chunks before it. Self Forcing, Causal Forcing and Self-Forcing++ train that loop on its own output.

A short note on logistics, since slide 2 carries it. Assignment 3 is released on Friday, October 30 and is due on November 18. The final project instructions and updates are on Canvas. Office hours are on Thursdays from 4:30 to 5:30 PM in AGH 423.

  1. Flow maps: one learned jump that agrees with many short walks.
  2. BOOT and π-Flow: train on the states the student itself visits.
  3. Consistency: every point on a path names the same endpoint.
  4. MeanFlow: the average velocity, learned from data alone.
  5. Populations: judge the crowd, not each pair, using the score.
  6. DMD: the two-score push and the alternating loop.
  7. Drifting: scores from batches, with no extra network.
  8. FD-Loss: match feature statistics, and compare all the objectives.
  9. Self Forcing: roll a fast generator forward through a video.
  10. Long rollouts: hidden futures, long windows, open problems.
  11. Field guide: numbers, checklist, code, links.
A sampler takes one Euler step from pure noise, using the teacher's velocity at the start. In the two-clump toy, where do the samples land, and why?

Chapter 1

Flow Maps: Jump Instead of Walk

Replace many small velocity steps with one learned jump along the same path, and see why jumps must agree

You are crossing a wide field on foot, and a map shows the wind at every spot. The wind carries you. Standing where you are, you read one arrow: which way, and how fast, the wind pushes you right now. You take a small step along it, look at the map again, and repeat.

That is how a flow model draws a picture. The map is the network. The field is every possible picture, and your position is the picture so far, starting as pure noise. Following the wind to the far side gives the finished picture. It works, but you read the map many times.

Now imagine a different map. You say where you stand and when you want to arrive, and it tells you the spot where the wind will have carried you by then. One look, one jump. That second map is a flow map, and the whole first half of this lecture is about learning one.

Two kinds of answer

Write the position as x and the time as τ. The lecture's convention puts noise at τ = 0 and data at τ = 1. The wind is the velocity v(x, τ). It obeys an ordinary differential equation (ODE), which only means: the rate of change of the position equals the velocity at that position and time.

dxτ/dτ = v(xτ, τ)
The local velocity: the direction and speed of the picture at one point and time. Using it means repeating the evaluation as the point moves.
Fs,t(xs) = xt
The flow map. Start at xs at time s, follow the same path, and land at xt at time t. Here s and t are generation times, not positions in a video.

The velocity answers a local question. The flow map answers a finite one: where is the point after a chosen interval? If the path were a straight line, the two would agree. The path bends, so they do not. Slide 3 states the plan: compare maps taught by a teacher with maps learned from data and local flow relations.

Walk, then jump

Use the two-clump toy from the hero. Start at the noise value x0 = 0.90. The teacher's velocity there is −0.90. It points away from the data, because the closest thing to an average of both clumps is zero. One Euler step to time 1 lands at 0.00, in the gap.

The true path is different. Following the teacher in fine steps, the point sits at 0.78 at τ = 0.25, 0.97 at 0.50, 1.31 at 0.75, and 1.68 at τ = 1. The velocity changes sign and grows along the way: it is −0.90 at the start and +1.28 at τ = 0.5. Four Euler steps still end at 1.56, short of 1.68. Only the flow map, which knows the whole path, lands on 1.68 in one call.

Jump along the path

The blue line is the teacher's path from one noise value. Choose a start time s and a target time t. The warm arcs are exact jumps. The dashed line is one Euler step with the local velocity. Move the stopover to split the jump in two.

0.00
1.00
50%

Toy world, ours (same as the hero). The teacher velocity and the exact jumps are computed live by following the teacher in 64 fine steps per unit of time. The flow map is idealised: it returns what the teacher's path gives. A trained map only approximates it.

Set the stopover to 50% and the two jumps land exactly where one long jump lands. That is the property on slide 5. An exact long jump agrees with two shorter jumps along the same flow: Fs,t(xs) = Fr,t(Fs,r(xs)) for any r between s and t. A learned map only has to be good enough that this still holds. Later chapters use it as a training signal.

Sampling with a learned map

Slide 5 writes sampling in three lines. First, draw noise: x0 ~ N(0, I), which means a vector of independent bell-curve numbers. Second, one call gives the picture: x̂1 = Fθ(x0, 0, 1). Third, if you want a path with stops, xt ≈ Fθ(xs, s, t).

Look at what goes in. The network gets three things: the current point, its time, and the time you want to reach. The output has the same shape as the point. For a 64 by 64 colour picture, x: [3, 64, 64] goes in with two numbers, and [3, 64, 64] comes out.

The teacher and its targets

Where does the training signal come from? In this half of the lecture, the first source is a teacher: a flow-matching model that is already trained. Flow matching trains a network to predict y − n, the data minus the noise, at a point rτ = (1 − τ)n + τy on the line between a noise sample and a data sample. Slide 6 freezes the learned weights and calls the result vT(xτ, τ, C). Here C is the conditioning, such as a text prompt.

One teacher call gives one local velocity. It does not give a destination. To get a destination, integrate: run the teacher along the path in many small steps. Slide 7 writes the result as x̃tT = ODESolve(vT, xs, s, t), and the student's loss as the squared gap between its one-call guess and that target:

Lmap
The loss. The teacher integrates the velocity from s to t to get the target endpoint. The student predicts that same endpoint in one network evaluation. The average runs over many sampled points and time pairs.

The price is plain. Every training target costs a full teacher rollout, so every step of training is slow. This is the idea of progressive distillation (Salimans and Ho, 2022), which the slide cites. The chapters ahead each remove part of that price.

A flow map F satisfies F(s, t) = F(r, t) applied after F(s, r). What does that tell you about a learned map that breaks this rule?

Chapter 2

BOOT and π-Flow: Learn From the Teacher's Own Paths

Train a student on states the student itself visits, by predicting a destination (BOOT) or a velocity rule (π-Flow)

An apprentice wants to learn a long mountain route from a master guide. The master can walk the whole route, but only slowly, and the apprentice cannot ask for a full walk every time. So the apprentice does something clever. It stands where it is now, asks the master for advice about the next few steps only, and tries to match that advice.

Two methods in this chapter work that way. BOOT learns where the route ends. π-Flow learns a cheap rule for the steps along the way. Both ask the frozen teacher about places the student itself reaches, not about places the teacher would visit.

BOOT: predict the whole trajectory from one noise

Fix the starting point at noise n and let the student predict where the teacher's path through n is at any time t. Slide 8 writes this with a signal prediction yθ(n, t): the student's guess at the clean picture, given the noise and the time. The predicted position blends that guess with the noise:

x̂t
The student's position at time t, built from a signal part and a noise part. αt and σt are the signal and noise weights. For the straight-line path of Chapter 1 they are αt = t and σt = 1 − t.
F0,t(n)
Where the teacher's path from noise n really is at time t. At t = 1 the weights give α = 1 and σ = 0, so yθ(n, 1) is the finished picture, in one evaluation.

The same noise names the trajectory. The requested time picks the stop. Slide 8's figure puts a row of teacher steps above a row of student predictions, both starting from the same noise.

Bootstrapping: the target comes from the student's own earlier guess

To train that student we need a target for time t. A full teacher rollout from noise would give one, but that is the expensive thing we wanted to avoid. BOOT builds the target by bootstrapping: using a nearby, already-learned answer to build the next one, the way you climb a ladder by standing on the rung below.

Slide 9 draws two rows. In the upper row, the student predicts the point at an earlier time s: x̂s = Fθ(n, 0, s). The frozen teacher then makes a local correction from s to t, which gives a fixed target x̃t. In the lower row, the student predicts the point at t directly. Training pulls that prediction toward x̃t. The upper row is held fixed. Only the lower row is updated.

Two things keep it honest. The times are close, 0 < s < t ≤ 1, so the teacher's correction covers a short interval and costs little. And a boundary loss at the noise end anchors the whole trajectory: at time 0 the student must return the noise itself. No full teacher rollout is ever needed.

Climb one rung

The blue path is the teacher from noise 0.90. The warm curve is the student, which you can bend with a bias. The pink diamond is the fixed target, built from the student at time s plus a short teacher correction. Move the bias and watch the gap between the target and the student at t.

0.30
0.10
0.30

Toy, ours. The student is the teacher's exact path plus a bias times t, so it is right at noise and drifts away later. The short teacher correction is computed with fine steps; in practice it is a few teacher calls over a short interval. The loss shown is the squared gap.

With a bias of zero, the target and the student agree and the gap is zero. With a bias of 0.30 the student at time 0.40 is off by a measurable amount, and the gap is the training signal that corrects it. Because the target is built from the student's own earlier prediction, an error at time s carries into the target. That is why the noise-end anchor matters: it fixes the bottom rung.

π-Flow: predict a rule, not a place

BOOT predicts a destination. Slide 10 asks a different question: can one network call support many local updates that imitate the teacher directly? The answer is a velocity policy. One call to the student network Gφ(xs, s, C) does not return a picture. It returns a small, cheap rule πs that gives a velocity for any point and time. A solver then follows that rule:

πs
A reusable rule returned by one network call. It is cheap to evaluate many times, so the heavy network runs once and the light rule runs at every small step.

The lecture names two kinds of rule that π-Flow can cache. One is a time-varying estimate of the clean picture, called DX. The other is the parameters of a state-dependent mixture of bell curves, called GMFlow. In both cases the rule is a small formula, not a second big network.

Training on its own trajectory

Slide 11 shows the training loop. First, the student predicts a rule from the start point. Second, a detached copy of the rule is rolled out to visit states x̄τ. Detached means no gradient flows through the rollout; it only picks where to look. Third, at each visited state, the frozen teacher gives its velocity, and the live rule is asked for its own. The loss is their squared difference, with a stop-gradient (sg) on the teacher:

πs(x̄τ, τ)
The live student velocity at a state the student itself visited. Gradients flow here, back into Gφ.
sg[vT(…)]
The frozen teacher velocity at the same state and time. It is a fixed target. The loss compares local velocities, not final pictures.

Measure where the student stands

The warm path is the student's rule followed from noise 0.90. The blue path is the teacher. At the time you choose, two arrows start at the student's own point: the live rule (warm) and the frozen teacher velocity (pink). Raise the rule's error and watch the student leave the teacher's path.

0.30
0.50

Toy, ours. The rule is the exact teacher velocity scaled by one minus the error, plus half the error as a constant push. The student follows it in 30 cheap steps. The teacher path is exact. Nothing here is a trained π-Flow model.

The point of the exercise is the second number in the read-out. The loss measured at the student's state can differ a lot from the loss at the teacher's state, and the student's state is where the rule will actually be used at test time. Training on the student's own path closes that gap.

The two side by side

Slide 12 lines the methods up. BOOT outputs a signal prediction for a requested time. It rebuilds states from that signal and the initial noise, and it asks the teacher for a local denoising correction. At test time it predicts the clean endpoint directly. π-Flow outputs the parameters of a reusable velocity rule. It integrates that rule to get states, and it asks the teacher for a local velocity at each visited state. At test time it predicts a rule and then integrates it cheaply. Both use a pretrained teacher to supervise states that the student produced.

Why does π-Flow compare the live rule and the teacher at states from the student's own rollout, instead of states from the teacher's rollout?

Chapter 3

Consistency: One Endpoint From Every Point

Make every point on one path predict the same clean endpoint, and train that with one short teacher step

Picture a trail of bread crumbs through a forest, and one cabin at the end. Pick up the trail at any crumb. If you know the forest, you can name the cabin from where you stand. The crumbs differ, but the cabin does not.

A consistency model is a network that does exactly that. Give it any point on a generation path and the time, and it names the clean picture at the end of that path. Every crumb on the same trail gives the same answer. That one rule, same trail, same answer, is the whole idea.

An endpoint map

Chapter 1's flow map takes a start time and a target time. A consistency model fixes the target time at the end of the path, τ = 1. Slide 13 calls it an endpoint map, written f(xs, s) = Fs,1(xs). Three facts define it.

f(xs, s)
The endpoint of the path that passes through xs at time s. The map gives the clean picture from any noisy point.
f(xs, s) = f(xt, t)
Self-consistency. Two points on the same path give the same answer. This is the property the name comes from.
f(x, 1) = x
The boundary condition. At the end of the path, the picture is already clean, so the map returns its input.

The slide notes a change of direction. The original Consistency Models paper puts data at time 0 and noise at the far end. Our coordinate runs the other way, noise at 0 and data at 1, so we keep the lecture's convention throughout.

Name the cabin from every crumb

Six dots sit on the teacher's path. The warm marks on the right edge are what a consistency model predicts from each dot. The blue line is the true endpoint. Raise the model error, then set the pair of nearby times that one training example compares.

0.40
0.20
0.10

Toy, ours. The model is the exact endpoint map plus an error that is largest at noise and shrinks to zero at time 1, matching the boundary condition. The next-step point comes from following the teacher over the gap h, computed with fine steps. The squared distance stands in for the distance loss d.

Set the error to 0.40 and look at the right edge. The prediction from the noise point is off by 0.40, and the prediction from a point at time 0.80 is off by only 0.08. At time 1 it is exact, because the boundary rule leaves no room. The errors form a ladder, and the top rung is pinned.

Training the endpoint prediction

We want a network that never disagrees with itself along a path. Slide 14 trains it with pairs of neighbours. Take a point xs. Use the frozen teacher for one short step of length h, which gives a nearby point x̃s+h on the same path. Then ask the network for the endpoint from both points and make the two answers match:

d(·, ·)
A prediction-distance loss, such as a squared error. It measures how far apart the two endpoint guesses are.
sg[…]
Stop gradient. The target side is treated as a fixed number, so gradients flow only through the live side.
θ̄
A target copy of the weights, a slow-moving duplicate of the network. It keeps the target stable.
h
A small step in generation time.

The slide gives each piece one job. The nearby input comes from a teacher step. The shared endpoint is what both predictions must agree on. The stable target comes from stop-gradient and the target copy. Without them the target would chase the very network that is trying to hit it, like measuring a moving ruler with itself.

Now see why a small loss on one pair does not mean a good model. In the device, the pair at s = 0.20 with gap 0.10 has a loss of only 0.0016 at error 0.40, because neighbours disagree by just e × h = 0.04. The model is still off by 0.32 at that point. What fixes it is the chain. Pairs near time 1 are tight, because the boundary pins the end. Training makes those pairs agree, and then the pair one rung below has a correct target to copy, and so on down to the noise.

Generating with the endpoint map

Slide 15 builds the boundary into the network. Write the model as fθ(x, s) = x + (1 − s) gθ(x, s), where gθ is the raw network. At s = 1 the factor (1 − s) is zero, so the output is the input and the boundary holds by construction. No loss term has to teach it.

Sampling is one call. Draw n ~ N(0, I), then compute x̂1 = fθ(n, 0). The learned endpoint map turns a fresh noise draw into a sample. The data flow is the same as in Chapter 1: [3, 64, 64] in, [3, 64, 64] out, with the time as an extra number.

The slide ends with a reminder. Consistency Models include two ways to train: distillation from a teacher, as above, and direct training from data with no teacher. Chapter 4 takes up how teacher-free training works.

In consistency distillation, why is the target side of the loss computed with a stop-gradient and a target copy of the weights?

Chapter 4

MeanFlow: Learn the Jump From Data Alone

Learn the average velocity over an interval with no teacher, using one identity and one derivative trick

You drive for two hours and want to know how far you went. The speedometer shows 30 kilometres per hour right now, in a traffic jam. That number is no help. What you need is the average speed over the whole trip. Multiply it by two hours and you have the distance.

The speedometer is the velocity from Chapter 1. The average speed is the idea of this chapter. A network that learns the average velocity over a time interval can make the jump in one call. And, unlike Chapters 2 and 3, it can learn it from data alone, with no teacher.

Why a teacher-free map needs an anchor

Slide 16 writes a flow map as a step: Fθ(x, s, t) = x + (t − s) uθ(x, s, t). The network outputs a velocity-like vector uθ, and the jump length (t − s) scales it. Two regimes follow. On a vanishing interval, as t approaches s, u must become the local velocity v(x, s). Ordinary flow-matching data teaches that part. On a finite interval, the map must obey compatibility rules, such as the one in Chapter 1 about two short jumps equalling one long jump.

The slide's warning is short: self-consistency needs a data-connected anchor. Rules that only compare the network with itself can be satisfied by a useless network. The flow-matching signal at the small end pins the answer, and the rules carry it to larger jumps.

Average velocity

Define the average velocity over the interval from s to t as the displacement divided by the time taken, which is also the time-average of the local velocity along the path (slide 17):

∫st v dτ
The integral adds up the velocity along the path from s to t. It is the total displacement. Dividing by (t − s) gives the average.
Fs,t
One exact jump: the start point plus the interval length times the average velocity. The tangent at the start and the interval average can differ.

Tangent against chord

The dashed line is the tangent: the local velocity at s, followed to t. The warm line is the chord: the average velocity over the whole interval. The chord always lands on the path.

0.20
0.90

Toy world, ours. Path positions come from fine integration of the exact teacher. The derivative in the identity check is a finite difference with a step of 0.0001 in s, holding t fixed.

With noise 0.90, s = 0.20 and t = 0.90, the path is at 0.78 at time s, and the local velocity there is −0.22. The tangent lands at 0.63. The path really arrives at 1.52. The average velocity over the interval is 1.06, and 0.78 + 0.70 × 1.06 = 1.52. The tangent misses by 0.90. The chord does not miss at all.

The MeanFlow identity

The network must learn u, but we have no samples of u. We have only samples of the local velocity. The bridge is an identity that ties the two together, and it needs only two steps (slides 18 and 19).

First, rearrange the definition. Multiply both sides by (t − s): (t − s) u(xs, s, t) = ∫st v dτ. Hold the destination t fixed and let the start point slide along the path. Then differentiate both sides with respect to s. The left side needs the product rule: the derivative of (t − s) is −1, so we get −u + (t − s) du/ds. On the right, s is the lower limit of the integral. Moving that limit up by a little removes a little velocity, so the derivative is −v(xs, s). Set them equal and rearrange:

du/ds
How the average velocity changes as the start point slides along the path to a later time, with the end time t fixed.

In words: the average velocity equals the local velocity plus a correction for how the average itself is changing. The device above shows both sides agreeing. Its read-out gives the finite-difference value of du/ds and the result of the right-hand side.

The moving-input derivative

The total derivative du/ds has two parts, because two things change when s moves: the time argument, and the point itself. Slide 19 writes it as du/ds = ∂su + Jxu · v. The first term changes the time argument of the network. The second moves the input point with velocity v. Here Jxu is the Jacobian of u with respect to x: a table of how each output number changes when each input number changes. For a picture with 12,288 numbers that table has 12,288 × 12,288 entries, far too big to build.

The trick is a Jacobian-vector product (JVP). It computes the table times one vector, here Jxu · v, in about the cost of one extra forward pass, without ever building the table. Deep-learning libraries offer it as a standard tool.

A training target from data

The identity needs the true velocity v, which is the unknown marginal field. Flow matching gets around the same problem (slide 20). Draw a noise sample n and a data sample y. The point rs = (1 − s)n + sy lies on the straight line between them, and the pair gives the velocity δ = y − n. One pair gives a conditional signal. Averaged over all pairs that pass through the same point, it equals the true velocity: v(x, s) = E[δ | rs = x].

MeanFlow substitutes δ for v in the identity and uses the current network to evaluate the derivative term (slide 21):

Dsuθ
The derivative along the training line. One JVP gives it: the direction is (δ, 1, 0), meaning the point moves by δ, the start time moves by 1, and t stays fixed.
utarget
The identity read as a recipe: the local velocity plus the interval length times the derivative. It is linear in δ once the network is fixed.
sg[…]
Stop gradient. The target is a fixed number for this update.

Build the target

One noise and data pair. The network is a tiny formula, u = a x + b s, so its derivatives are plain numbers. Stack the pieces of the target and compare them with the network's own guess.

0.50
0.40
0.50

Toy, ours: s is fixed at 0.40, and pairs are seeded draws (noise from a bell curve, data from the two bumps). The derivative Dsu is checked against a finite difference along the training line; the two agree to four decimals.

The first pair is n = −0.50 and y = 1.60, so δ = 2.10 and rs = 0.34. With a = 0.5 and b = 0.4, the derivative is 0.4 + 0.5 × 2.1 = 1.45. The target is 2.10 + 0.5 × 1.45 = 2.825. The network's guess is 0.5 × 0.34 + 0.4 × 0.4 = 0.33. The gap is 2.495, so the loss is 6.225. Pull the interval length to zero and the target becomes δ alone. That is plain flow matching.

Training and sampling, and the improved loss

Slide 22 puts it in four steps. Sample y, n and times with s ≤ t. Construct rs and δ. Run one JVP in the direction (δ, 1, 0). Regress the network onto the stopped target. Sampling is one line: draw x0 ~ N(0, I) and set x̂1 = x0 + uθ(x0, 0, 1). A shorter interval uses xt ≈ xs + (t − s) uθ. The JVP runs in training only.

Slide 23 shows the follow-up, Improved MeanFlow (iMF). Both ordinary flow matching and iMF regress the same velocity target y − n. They differ in what the network outputs. Flow matching outputs the local velocity. iMF outputs the average velocity uθ. It then converts that back to a velocity guess, ṽθ = uθ(x, s, t) − (t − s) sg[Dspreduθ], where the derivative uses the model's own predicted velocity vθ(x, s) = uθ(x, s, s). At t = s the correction vanishes and the loss is plain flow matching again. In the lecture's words, iMF uses a velocity loss with an average-velocity prediction.

Why does MeanFlow need a Jacobian-vector product during training, and why not during sampling?

Chapter 5

Matching Populations, Not Pairs

Judge a fast generator by the crowd it produces, and learn the score that lets us compare two crowds

Two art students get the same task: paint a crowd scene for a school poster. The first student must copy a master's painting, brush stroke by brush stroke. The second student only has to paint a crowd that looks like a real crowd: the right mix of tall and short people, the right clothes, no two faces alike. The second student has far more freedom.

So far, every method in this lecture was the first student. Each one compared the fast generator with the teacher's path, noise by noise. The second student is the idea of the next four chapters. Slide 24 puts it in one line: a fast generator still needs diverse, plausible samples, but it need not reproduce every teacher trajectory.

Pairs or populations

A population here means the whole crowd of outputs a generator makes over many fresh noise draws. A pairing is which noise value leads to which output. The teacher has one pairing. But many different pairings give the same crowd. A correct output distribution does not fix which output belongs to which noise.

Same crowd, different pairs

Each line joins a noise value (left) to the output it produces (right). The blue marks on the right edge show the teacher's pairing. Pick another pairing and watch the lines tangle, while the histogram of outputs stays put.

Toy world, ours: 240 seeded noise values, 24 of them drawn as lines. The teacher pairing follows the exact flow. Mirrored uses the output of the opposite noise value, and shuffled uses a fixed scramble. Population distance is the average gap between the sorted outputs of each crowd; paired error is the average gap between each output and the teacher’s output for the same noise.

The mirrored and shuffled generators fail the pair test completely: their paired error is 3.20 and 1.81, as large as the width of the data. Yet their population distance is 0.14 and 0.00. A method that scores pairs would punish them. A method that scores crowds would pass them. Distribution matching takes the second view.

The cast

Slide 25 names three things. The student generator Gθ turns noise z ~ N(0, I) and a condition C into one clean candidate x = Gθ(z, C) in one call. The crowd of its outputs over fresh noise is the distribution qθ(x | C). The target distribution pT(x | C) is what the frozen teacher represents. A snag: the density of qθ is generally unavailable. You cannot write a formula for how likely a picture is under a neural network that maps noise to pictures. You can only draw samples from it. So the comparison must work with samples.

Compare after adding noise

Two crowds of clean pictures may not overlap at all, so comparing them directly is hard. Slide 26 smears both with the same Gaussian corruption: xτ = ατx + στε with ε a fresh bell-curve draw. Each crowd becomes a smoother crowd, qθ,τ and pT,τ, and these do overlap. The comparison is between those two noisy crowds, not between a clean picture and its own noisy version.

The score: an arrow toward the crowd

To compare two crowds at a point, ask each one the same question: which way is the crowd denser from here? The answer is the score, the gradient of the log density: sp(xτ, τ) = ∇ log pτ(xτ). It is an arrow that points uphill in density, and it is longer where the density changes faster.

We cannot write pτ down, but we can write the score for one clean source. Slide 27 does it for the corruption kernel, a bell curve centred at ατx: its score is (ατx − xτ)/στ2. It points from the noisy point back toward its source, with strength set by the noise. The catch is that we do not know the source.

Slide 28 repairs that with Bayes' rule. The noisy point could have come from many clean pictures. Average the single-source score over how likely each source is, given what we see (this weighting is called the posterior). The average of the source is the denoiser E[x | xτ], the best guess of the clean picture. The result is neat:

Ep[x | xτ]
The denoiser: the average clean picture that could have produced this noisy one, under population p.
ατ, στ
The signal and noise weights of the corruption at level τ.

A network can learn the denoiser by plain regression. Slide 29: if a network f is trained with squared error to predict the noise ε that was added, its best answer is the conditional mean E[ε | xτ]. Because xτ = ατx + στε, that conditional mean gives the score: ŝp = −ε̂/στ. So a diffusion model's noise predictor is a score estimator. Different clean populations give different denoisers, and different scores, even at the same noisy input.

Read the score from the denoiser

Blue is the target crowd (two bumps), warm is a student crowd (one wide bump), both smeared by noise. Move the noisy point. Each arrow is a score. The two ticks on the lower line are the two denoiser guesses of the clean picture.

0.90
0.50

Toy, ours: α = 1 minus the noise level and σ = the noise level. The target crowd is the two bumps of the toy world. The student crowd is one bell curve centred at 0.3 with spread 0.9. Both scores come from the denoiser formula, and each is checked against a finite-difference slope of the log density.

At noise level 0.50 and x = 0.90, the target's denoiser says the clean picture is about 1.60. Half of that, 0.80, sits just left of the noisy point, so the score is a short arrow to the left, −0.40. The student's denoiser says 0.97, and its score is a longer arrow to the left, −1.66. Their difference, −1.26, is the useful quantity. Slide 30 gives each crowd a model for it: a frozen teacher estimating sT = ∇ log pT,τ and a trainable fake score model estimating sφ ≈ ∇ log qθ,τ. The word “fake” refers to the generated crowd. The fake model estimates a score, not a real-or-fake probability.

Slide 31 says why the generated score matters. The gap sφ − sT is the distribution difference. If the two crowds match, the gap vanishes, even though the target score itself need not be zero. That gap is what the next chapter turns into a gradient.

Two generators map every noise value to a different output, but their output crowds are identical. Which kind of loss can tell them apart, and which cannot?

Chapter 6

The DMD Gradient: Two Scores and a Push

Derive the distribution-matching gradient, and run the alternating loop that trains a generator and its fake score

A coach trains a sprinter with two compasses. The first compass always points to where the real crowd of top runners stands. The second always points to where the sprinter's own training group stands. The coach pushes the sprinter along the first compass minus the second. When the two compasses agree, the push is zero, and the sprinter has joined the crowd.

That is the whole Distribution Matching Distillation (DMD) idea. The compasses are the two scores from Chapter 5: the frozen teacher's score, and the fake score of the student's own crowd. This chapter derives the push and builds the loop that trains both.

What reverse KL is made of

To measure how far the student crowd is from the target crowd, DMD uses the reverse KL divergence, a standard score for how far one crowd sits from another. It is not symmetric, so the order of the two crowds matters. At one noise level τ with the condition C fixed, the noisy student sample is xτ = ατGθ(z, C) + στε (slide 32):

log qθ,τ
The student term. It accounts for how probability spreads across the generator's outputs. A generator that piles everything on one point pays for it here.
− log pT,τ
The target term. It rewards outputs that the target distribution regards as plausible, and punishes the rest.

The samples come from the student, and the average is taken over the student's own draws. That is the “reverse” in the name. It matters, as the device below will show.

Differentiating each term

We want the gradient of J with respect to the generator weights θ. Weights change xτ through the generator, so the chain rule gives a factor ∂xτ/∂θ = ατ ∂Gθ/∂θ.

The target term (slide 33). The teacher distribution does not depend on θ. Changing θ only moves the sample. The score sT tells how log density changes when the sample moves, so ∇θ[−E log pT,τ(xτ)] = −E[(∂xτ/∂θ)T sT(xτ, τ)].

The student term (slide 34). Here both the sample and its density change with θ. The chain rule gives two pieces. One is the sample moving: (∂xτ/∂θ)T sq. The other is the density changing at a fixed input: ∂θ log qθ,τ(y) evaluated at y = xτ. The second piece vanishes on average. Take the expectation under q: ∫ q ∂θ log q dy = ∫ ∂θq dy = ∂θ ∫ q dy = ∂θ 1 = 0. The total probability is always 1, so its slope is 0. Only the student-score piece survives.

Add the two terms and the gradient has a clean shape (slide 35):

sq − sT
The gap between the student's score and the teacher's score at the same noisy point. Gradient descent reverses the sign, so the generator moves along sT − sq: toward where the target is denser than the student.
wτ
A fixed weight, at least zero, for each noise level. Both scores read the same noisy sample xτ.

Making the update with ordinary tools

Deep-learning libraries need a scalar to differentiate. Slide 36 builds one. Evaluate both scores and freeze them: d = sg[wτατ(sφ − sT)]. Define the surrogate loss L = dT Gθ(z, C). Its gradient is exactly (∂G/∂θ)Td, the desired one. Its value is not the KL value. We backpropagate through the generator only, never through either score network.

Training the fake score

The student's score sφ is not given. We train it, with the denoising recipe of Chapter 5 (slide 37). Take fresh samples from the current generator, x̄ = sg[Gθ(z, C)], add known noise, xτ = ατx̄ + στε, and train a denoiser to predict that ε. The loss is Lfake(φ) = E‖ε̂φ(xτ, τ, C) − ε‖2, and the score is sφ = −ε̂φ/στ. Only φ is updated.

The two updates alternate (slide 38). Update the generator with both score models fixed. Then update the fake score with the generator and teacher fixed. After training, keep Gθ only. The two score models only supplied training signals.

Run the push

The student is one bell curve with a mean and a spread. The target is the two bumps. Each arrow is the push on one student sample. Pick a start, then run. Compare where each start ends.

Toy, ours. The student is a bell curve G(z) = mean + spread × z. The fake score is the exact score of the student’s noisy crowd, in place of a trained network. Noise levels are drawn between 0.05 and 0.65 each step, with learning rate 0.05 and 128 samples. The divergence is the reverse KL on clean outputs, computed on a grid. One bump matching one bump perfectly would score ln 2 = 0.69.

Start near a bump and the student locks on: the mean goes to about 1.58, the spread to 0.26, and the divergence settles at 0.70. That is almost exactly ln 2 = 0.69, the best a single bump can do against two. Start wide in the middle and it stays there, at a divergence near 5.96. In this toy, reverse KL has more than one resting place, and the wide one is a poor one. The slides do not show this toy. They do note that the original method adds paired regression to stabilise training, which fits the picture: a pull toward the teacher's own outputs would keep the student out of the wide basin.

DMD2 and the limits

Slide 39 compares the two versions. The original DMD adds paired teacher-output regression to stabilise training. DMD2 removes that regression and instead trains the fake score fast enough to track the generator. It also adds a GAN discriminator that compares generated outputs with real images. The GAN piece belongs to that recipe. The gradient identity itself does not need it.

Slide 40 closes with a caution about few-step generation. Sampling runs only the distilled generator. But evaluation should check sample quality and diversity as well as latency. The same inference budget can come from different training constraints, and the pictures in the original DMD2 figure show a mechanism, not a current model ranking.

In DMD, during the generator update, which parts receive gradients?

Chapter 7

Drifting: Scores From a Batch

Replace the fake-score network with two batches of samples and a kernel, and see the drift as a score difference

Two piles of marbles sit on a table: a pile of real ones and a pile you made. You want your marbles to look like the real ones. For each of your marbles you do two things. You find the real marbles near it and note where their centre is. Then you find your own marbles near it and note where their centre is. You move the marble toward the real centre and away from your own centre. When the two centres agree, you stop.

That is Drifting (Deng et al., 2026). It trains a fast generator with the same goal as DMD, but it replaces the fake-score network with two batches of samples and a similarity rule.

Two batches, no extra network

Slide 41 sets it up. The generator makes x = Gθ(z) from noise. The target is a crowd p we can sample: a batch of real reference samples y1+, …, yN+ ~ p. The generator's own crowd gives a batch of generated reference samples y1−, …, yM− ~ qθ. Those two batches give the training direction. No auxiliary denoising model has to learn the student score.

A local average

For the current output x, give each real sample a weight that grows with its similarity to x. A kernel k(x, y) > 0 is the similarity rule: large when two points are close, small when they are far. Slide 42 normalises the weights to add up to 1, then takes the weighted average:

wj+
How much real sample j counts for this x. The weights sum to 1, so near samples count more and far ones count less.
μp(x)
The weighted local mean of the real examples: the centre of the real marbles near x.
Vp+(x)
An arrow from the current output to that local mean.

Do the same with the generated batch (slide 43): wj−(x) from the kernel, μq(x) the local mean, and Vq−(x) = μq(x) − x. This arrow points toward where the current generated samples concentrate near x. It is a pull we want to reverse. Subtract it. If the real and generated crowds already agree, the correction should stop.

The net movement, on slide 44, is V(x) = Vp+ − Vq− = μp(x) − μq(x). The two copies of x cancel, so the drift compares the local real centre with the local generated centre. Equal crowds give equal local means and zero drift. With finite batches there is estimation noise on top.

Let the generated crowd drift

Blue dots are 64 real samples. Warm dots are 64 generated ones, free to move. The black line marks a query point with its drift arrows. Press Run, then try a narrow kernel width and run again.

0.80
0.40

Toy, ours: the generated samples are free positions, not a network, and each step moves every sample by half of its drift. The crowd distance is the average gap between the sorted real and generated samples. Under the Gaussian kernel the read-out also checks Vp+ / h2 against a finite-difference slope of the log of the smoothed real density.

With h = 0.80 the generated crowd starts off to the right and wide, and in 60 steps the crowd distance drops from 0.98 to about 0.2. The two bumps fill in. With h = 0.30 it gets stuck at 0.84: a sample far from every real sample sees almost no weight on any of them, so its local mean says very little. The slide's warning is exact: kernel width, batch size and representation affect the estimate.

The drift as a frozen target

Now train a network. Slide 45: let x = Gθ(z) and set a target xtarget = sg[x + V(x)]. The target is the output shifted along the drift, frozen with stop-gradient, reference samples included. The loss is L = ½E‖Gθ(z) − xtarget‖2. Its gradient is −E[(∂G/∂θ)TV(x)], because the residual equals −V. Gradient descent therefore trains the generator to follow the drift.

The paper's recipe (slide 46) differs from our toy in two ways. It uses the kernel exp(−‖x − y‖/h), with an unsquared distance, plus batch and drift normalisation. And it applies the loss in the feature space of a frozen encoder Φ, so Lfeat = ½E‖Φ(x) − sg[Φ(x) + V(Φ(x))]‖2, and gradients flow through the predicted features to the generator. At sampling time, only the generator runs. The batches and the encoder disappear.

Why this is a score difference

The slides then show that the drift is secretly the DMD gradient in disguise. Choose a Gaussian kernel of width h: Kh(x | y) = N(x; y, h2I). Average the kernels over the real batch and you get a smoothed density ph(x), a kernel density estimate: a bump on every real sample, added up. Its score is (slide 47):

Vp+ / h2
The kernel weights are exactly the posterior weights of the bumps, so the arrow to the local mean, divided by h squared, is the score of the smoothed real crowd.

The generated batch gives qh and its score the same way (slide 48). Subtract, and the drift becomes V(x) = h2[∇ log ph(x) − ∇ log qh(x)], a score difference (slide 49). DMD gets its two scores from two denoisers. Gaussian Drifting gets the same kind of difference from kernel-weighted batches. Switch the device to the Gaussian kernel and read the check line: the two numbers agree.

One caution from slide 49: this proves the link between the two fields. Matching the full DMD parameter gradient also needs the same evaluation point. Slide 50 states the case. Use population Gaussian smoothing, exact population scores, and evaluate the drift at the same noisy student sample u = Gθ(z) + hε that DMD uses. Then Laligned = (1/2h2)E‖u − sg[u + V(u)]‖2 has gradient E[(∂G/∂θ)T(sqh − sph)], which equals ∇θ KL(qh ‖ ph). The original clean-query recipe differs.

In Drifting, what does the arrow V(x) = μp(x) − μq(x) become when the real and generated crowds are the same?

Chapter 8

FD-Loss and the Choice of Objective

Match the mean and spread of features, then compare trajectory objectives with distribution objectives

You have two bags of coloured beads. You cannot compare them bead by bead, because the beads are in no order. So you describe each bag with two things: the average colour, and how much the colours vary and move together. If the two descriptions match, you call the bags alike.

This is FD-Loss, short for Representation Fréchet loss (Yang et al., 2026). It matches the two descriptions of real and generated pictures, and it needs no score model and no kernel.

Mean and covariance

A frozen encoder Φ turns each picture, real or generated, into a feature vector: a list of numbers that describes it. Run it over a crowd of real pictures and you get a cloud of points. Two numbers summarise a cloud. The mean μ is its centre. The covariance Σ is a table that says how far the cloud spreads in each direction and how the directions move together. A tall thin tilted cloud has a different covariance from a round one.

Slide 51 compares the real summary (μp, Σp) with the generated summary (μq, Σq):

‖μp − μq‖2
How far apart the two cloud centres are, squared.
tr[…]
The trace adds up the diagonal of a table. This term is zero exactly when the two spreads are the same shape and size. The matrix square roots turn it into a distance.

This is the Gaussian Fréchet distance in the chosen representation: the exact distance between two bell-shaped clouds with these means and spreads. The loss gives generator gradients by differentiating through the generated-image features and their statistics. No extra score model is needed.

Match the centre and the spread

The blue cloud is real features in two dimensions. The warm cloud is generated. Shift it, stretch it and tilt it, and watch the two parts of the loss. Then swap the generated cloud for a ring.

1.20
1.50
−0.40

Toy, ours: two feature dimensions instead of thousands. The real cloud has mean 0 and covariance [[1, 0.5], [0.5, 1]]. The generated cloud is that shape scaled, tilted and shifted by your knobs. The distance is the exact two-dimensional formula; the dots are 150 seeded points for the eye.

Set shift 0, scale 1 and tilt 0.50, and the loss is 0. Move only the centre by 1.2 and the loss is 1.44, all of it from the mean term. Now pick the ring. Both clouds have the same two summaries, so the loss reads 0, yet the shapes plainly differ. The slide says it plainly: matching two moments does not identify every image distribution.

A big population and a small batch

There is a practical catch (slide 52). A covariance of thousands of numbers cannot be estimated from one training batch of a few dozen images. The estimate is noisy, and the noise biases the loss. The slide's fix has three parts. Keep a stored population: a queue of recent generated features, or running first and second moments. Generate a current batch of fresh images and compute live features through the frozen encoder. For the generator update, compute FD with the combined statistics, and backpropagate only through the current batch features. The statistics use a broad sample history. The gradient graph covers only the current batch.

Count the samples behind the statistics

Real and generated crowds here are exactly the same. The true distance is zero, but the estimate from a finite sample is not. Set a batch size and a queue length. The warm marker shows the estimate.

32

Toy, ours: both crowds are the same two-dimensional bell curve, and each point is the average of 60 trials of the exact formula on sample means and covariances. Real FD-Loss uses thousands of features, where the gap is far larger. A queue adds stale samples, which this toy does not model.

With a batch of 32 and no queue, the estimate for two identical crowds is 0.21 instead of 0. With a queue of 16 batches it uses 512 samples and drops to 0.01. That is the reason for the stored population. The price is staleness: older features came from older generators, a concern the slide names. FD-Loss can post-train a fast generator or repurpose a multi-step model, and representation-specific optimisation remains a concern.

Trajectory or distribution?

Slides 53 and 54 put the two halves of the lecture side by side. A trajectory-based objective such as Fθ(z) ≈ FT(z) preserves the teacher's noise-to-output pairing. Consistency and MeanFlow also constrain local or finite-time relations, and need not use an explicit paired endpoint loss. A distribution objective, qθ ≈ pT, lets different pairings satisfy the same goal.

Trajectory-based methodsDistribution matching
Training signalA target destination or a local flow relationA signal comparing two populations
Main advantageStructured supervision for a chosen transformationFreedom to change the noise-to-output correspondence
Main difficultyAccumulated target error or an incompatible teacher mapEstimating the population mismatch reliably
Typical costTeacher trajectories, local evaluations, or JVPsScore tracking, adversarial training, or sample interactions

The slide ends with a promise about the next chapters. Initialisation and post-training can use different objectives. Causal video generation will make that distinction concrete.

FD-Loss keeps a queue of recent generated features but backpropagates only through the current batch. Why?

Chapter 9

Video One Chunk at a Time: Self Forcing

Roll a fast generator forward chunk by chunk, train it on its own history, and keep the memory cost bounded

An animator draws a flipbook one page at a time, and can only look at the pages already drawn. Page 12 has a tiny smudge on the character's hand. Page 13 copies the hand, smudge and all, and adds a smudge of its own. By page 40 the hand is a blob. The animator never practised on smudged pages, because every training flipbook was clean.

This is the central problem of autoregressive video: a video made one piece after another, each piece predicted from the pieces before it. It is also the road to an interactive world model, because a model that writes the next piece can take your action first. This chapter follows Self Forcing (Huang et al., 2025), which trains that loop on its own pages.

Two loops

A chunk is a short group of frames drawn together. Slide 55 separates two loops that are easy to confuse. The outer loop runs in video time k: generate the next chunk, append it to the history, repeat. It is written Ŷk ~ qθ(Yk | Ŷ<k, C). The inner loop runs in the generation coordinate τ, inside one chunk: turn noise xk,0 ~ N(0, I) into the clean prediction xk,1 = Ŷk. Both loops cost network calls. Fast sampling from Chapters 1 to 8 shrinks the inner loop.

Slide 56 makes the fast generator explicit: Ŷk = Gθ(zk, Ŷ<k, C). Fresh noise zk picks one possible continuation. The generated prefix supplies the history. The same few-step generator runs again for the next chunk. And the slide's warning: errors in one generated chunk become part of the next input.

What history does training show?

Slide 57 lists three ways to train the history input. Teacher Forcing feeds clean frames from a real training video. Diffusion Forcing feeds real frames with independently sampled noise levels. Self Forcing feeds earlier outputs produced by the current generator. Noise corruption can cover many noise levels without reproducing the model's own content errors. Self-generated history changes the distribution of training inputs, and it is the only one of the three that matches what the model will see at test time.

Watch a smudge travel

The line is how far the generated video has drifted from the true one, chunk by chunk. Every chunk adds a fresh small error. The training regime decides how much of the earlier error is copied forward.

0.20
30

Illustrative toy, not a measurement: the drift follows ek = r × ek−1 + a fresh seeded error, where r is the share of the earlier error that the model carries forward. We chose r = 1.05, 0.95 and 0.60 for the three regimes to show the shape of the problem. The slides give no such numbers.

With the default settings, a Teacher-Forcing-style model carries 105% of its error forward and the drift grows chunk after chunk. A model that carries 60% forward settles at a level set by the fresh error alone. The lesson of the toy is the shape, not the numbers. The carry-forward share decides whether errors die out or pile up. Training on one's own mistakes is how a model learns to shrink them.

Judging the whole clip

Training needs a judge. The judge is DMD from Chapter 6, now applied to a whole video. Slide 58 splits the roles. The online student generates each chunk using only the prefix it has, as it will at test time. After the rollout, the offline supervision evaluates the complete clip V̂ = (Ŷ1, …, ŶK), noised as Vτ = ατV̂ + στE, with a bidirectional teacher: one that looks at all chunks at once, including later ones. Both the teacher score sT(Vτ, τ, C) and the fake score sφ(Vτ, τ, C) now describe distributions over complete clips. The teacher's training-time view does not give the deployed student access to future chunks.

The rollout itself (slide 59) is short. Ŷ1 = Gθ(z1, C), then Ŷ2 = Gθ(z2, Ŷ1, C), and so on. The generated prefix is cached as the rollout advances, and the finished clip is evaluated. The probability of a clip factorises chunk by chunk (slide 60): qθ(V | C) = ∏k qθ(Yk | Y<k, C). The objective is the same reverse KL, on noisy complete clips: Jvideo = Eτ[wτ KL(qθ,τ(V | C) ‖ pT,τ(V | C))], with the score correction sφ − sT as before. Self Forcing specifies the rollout procedure. DMD is one choice of whole-clip training objective.

Training within a memory budget

Backpropagating through every chunk and every sampling step of a whole video would not fit in memory. Slide 61 lists four tricks. Run the early denoising steps of each chunk with no gradient. Pick a random denoising exit and backpropagate only through that final call. Condition on earlier generated chunks but detach their cached keys and values, so no gradient flows back through history. Then evaluate the finished video with the whole-clip objective to supervise the paths that were kept. Random exits give different denoising steps a chance to receive supervision. The practical update does not backpropagate through all video history and all sampling steps.

A rolling cache for memory at test time

At test time the model needs the earlier chunks. Recomputing them for every new chunk would cost more and more. Instead it stores their keys and values, the pieces of attention that later chunks look up (the KV cache). Slide 62 adds a rolling rule: keep the keys and values for recent generated chunks, and drop the oldest when the window fills.

Roll the window

Each box is a chunk. The warm box is the one being written. Purple boxes are in the cache. Grey boxes have rolled out. The blue box holds an object that appears at chunk 3.

14
5

Toy, ours: one unit of attention work for each cached chunk a new chunk reads. The object marker shows what a finite window cannot hold, as the slide cautions. The slides give no window size.

With a window of 5 and chunk 14 being written, the new chunk reads 5 earlier chunks instead of 13, so it does about 38% of the full-history work. The price shows on the marked chunk: the object from chunk 3 has rolled out, and nothing in the cache says it ever existed. A finite cache reduces computation. It does not guarantee persistent geometry or unlimited reliable memory.

Why does Self Forcing train with the student's own generated chunks as history, instead of clean frames from real videos?

Chapter 10

Causal Forcing, Self-Forcing++ and What Is Open

Fix a teacher the student cannot copy, stretch supervision to long rollouts, and name what is still unsolved

A student must copy a teacher's answers, but the teacher writes with the whole answer sheet in view and the student is only allowed to see the questions up to now. For question 5, the teacher's answer sometimes depends on question 9. The student cannot know question 9. What should it write? Whatever it writes, it will often be wrong. The best it can do is the average of what the teacher would have written.

That is the first problem of this chapter. The second is about length: the teacher can only judge short clips, but a world model should run for minutes. Causal Forcing (Zhu et al., ICML 2026) fixes the first. Self-Forcing++ (Cui et al., 2025) fixes the second.

A teacher target the student cannot reproduce

In Self Forcing, the student is causal: it reads earlier chunks only. The teacher in Chapter 9 was bidirectional: it sees all chunks. Slide 63 writes both as full noise-to-video computations F. The teacher's chunk k is YkT = [FT(z1:K, C)]k. It can depend on the future noise z>k. The student's chunk is YkS = [Fθ(z≤k, C)]k, and it cannot read that future noise.

Hold everything the student can see fixed, and change only the hidden future noise. The teacher's target for chunk k may change. A paired loss, a squared error against the teacher's output for the same noise, then asks the student to match two different targets for one input.

What squared error does with a hidden future

Slide 64 does the maths. Let u = z≤k be what the student sees and h = z>k what it cannot. The teacher's target is Tk(u, h). The best function the student can learn is the average over the hidden part, and the loss splits into two pieces:

E[Tk | u]
The teacher's target averaged over every hidden future that fits what the student can see. The student's best answer is this average.
second term
The leftover. It does not depend on f at all, so no student can remove it. It is the part of the target that lives in the hidden future.

Average the hidden future

Each dot is one training pair: the number the student sees (across) and the teacher's target (up). The target also depends on a hidden number. Fit a line. See how much error remains even for the best line.

1.40

Toy, ours: target = 1.0 × visible + c × hidden, with the hidden number a fresh bell-curve draw and c = 0.8 for the bidirectional teacher. 300 seeded pairs. The error figures are measured on those pairs. The slides give no such numbers.

With the bidirectional teacher (c = 0.8), the best line has slope 1.0 and still leaves an error of about 0.64, which is c squared. No amount of training removes it. With a causal teacher, c is zero, the target depends only on what the student sees, and the best line fits the points exactly. Slide 64 draws the conclusion: a causal teacher removes the inaccessible dependence from the paired target, and distribution matching can instead relax the pairing. Slide 63 adds a care: the mismatch is about one particular correspondence, not about whether an autoregressive model can represent the video distribution.

Causal initialisation, then asymmetric DMD

Slide 65 combines both views. Step one: train an autoregressive teacher that learns next-chunk denoising with a causal information interface. Step two: distil its causal map, using compatible paired ODE targets, to initialise the few-step autoregressive student. Step three: match full-video distributions with a strong bidirectional teacher for the DMD post-training stage. Paired map supervision and distribution supervision can use different teacher architectures. This is the distinction Chapter 8 promised: initialisation and post-training can use different objectives.

The supervision horizon

Now the length problem. Slide 66: the video teacher has a short horizon, a segment of K chunks. Self Forcing trains on self-generated clips that fit inside that horizon. But at inference we want a long rollout, L much greater than K. Seeing generated history during training and seeing long generated history are different requirements.

Self-Forcing++ trains on long self-rollouts and asks the short-video teacher to supervise sampled segments of them. Slide 67 gives the recipe. Roll the student out for L chunks: V̂ = (Ŷ1, …, ŶL). Pick a start i uniformly from {1, …, L − K + 1}. Cut the window Wi = Ŷi:i+K−1. Add noise, Wi,τ = ατWi + στE. Apply the DMD direction, sφ(Wi,τ) − sT(Wi,τ), at that window.

Slide a short window along a long rollout

Bars show how often each chunk of the rollout falls inside a sampled teacher window. Grey: Self Forcing, which trains only on clips that fit the teacher. Warm: Self-Forcing++ windows. Change the rollout length and the window length.

40
10

Toy, ours, exact counting rather than sampling: the share of windows that contain chunk j is (the number of window starts that cover j) divided by L − K + 1. The slides give no window length.

With a rollout of 40 and a window of 10, Self Forcing supervises chunks 1 to 10 and nothing after. Windows reach chunk 40, but unevenly: the middle chunks sit in about 32% of windows, and the first and last chunks in only 3%. Slide 68 adds three more pieces. Use a rolling KV cache during training, as at inference. Use backward noise initialisation: re-noise the student's generated latents before the teacher sees them, so the noisy input still carries the content of this rollout. And apply distribution matching at sampled positions, including late ones. The re-noising is the DMD operation of Chapter 6. The extension changes which student outputs receive supervision.

One limit the slide states plainly: matching short windows does not guarantee that an object remains correct after a long occlusion.

Where this leaves interactive world models

Slide 69 lists further reading. Inductive Moment Matching (Zhou et al., ICML 2025) learns generative jumps with distribution-level moment matching and bootstrap targets. Adversarial objectives use a learned discriminator as another population comparison, as in the DMD2 recipe. These objectives can complement map-based initialisation.

Slide 70 is honest about what is left. Long-term consistency: how can supervision over short windows preserve identity and geometry across long gaps? Compatible supervision: which teacher information can an online causal student actually reproduce? Efficient credit assignment: how can late errors improve earlier decisions without keeping a whole rollout graph? Controlled prediction: how do we judge the consequences of new actions, beyond visual plausibility? Fast generation makes an interactive loop possible. Reliable world prediction adds requirements these objectives do not settle. For an action-conditioned interactive world model, see the Genie lesson.

A causal student is trained by paired squared error against a bidirectional teacher whose chunk-k output depends on future noise. What does the student learn?

Chapter 11

The Field Guide

Review the lecture on one page: the numbers and terms, a checklist, the core code, and where to go next

You can now say, from memory, what Lecture 14 argued. A slow sampler follows many small velocity steps from noise to data. A fast sampler needs a new training signal. Flow maps learn the jump itself: BOOT and π-Flow learn it from a teacher's local advice on states the student reaches, consistency models make every point on a path name one endpoint, and MeanFlow learns the average velocity from data with a Jacobian-vector product. Distribution matching drops the pairs and compares crowds: DMD pushes along the gap between a teacher score and a fake score, Drifting gets the same push from two batches and a kernel, and FD-Loss matches feature means and covariances. Autoregressive video then runs a fast generator chunk by chunk. Self Forcing trains it on its own history, Causal Forcing fixes a teacher the student cannot copy, and Self-Forcing++ stretches supervision to long rollouts.

Name the signal

The quickest test of understanding is to read a description of a training signal and name the method. Try eight.

Which method is it?

Each card describes how one method gets its training signal. Pick the method it describes.

The eight descriptions are ours, written from the lecture’s slides 4 to 68. Each answer names the slide it comes from.

The methods on one page

MethodWhat the student outputsTraining signalTeacher?Slides
Flow map with a teacherFθ(xs, s, t), a jumpMatch the integrated teacher endpointYes, full rollouts4 to 7
BOOTA signal yθ(n, t) for any time from one noiseMatch a target built from the student’s nearby earlier guess plus one short teacher correctionYes, local8 to 9
π-FlowA cheap velocity rule πs, then integrateMatch teacher velocity at states the student visitsYes, local10 to 12
ConsistencyThe endpoint f(x, s)Two nearby points on a path give one endpointOne short step, or none13 to 15
MeanFlow, iMFAverage velocity uθ(x, s, t)Identity target with a JVPNone16 to 23
DMD, DMD2A one-call generator Gθ(z, C)Push along sT − sφ; fake score trained by denoisingFrozen score, plus a trained fake score24 to 40
DriftingA one-call generatorDrift μp − μq from two batches and a kernelNo score network41 to 50
FD-LossA fast generatorFréchet distance of encoder feature momentsA frozen encoder51 to 52
Self ForcingA few-step chunk generatorDMD on the full self-generated clipBidirectional, offline55 to 62
Causal ForcingThe same, with a causal startCausal paired initialisation, then asymmetric DMDCausal, then bidirectional63 to 65
Self-Forcing++The same, on long rolloutsDMD on sampled windows of a long self-rolloutShort-video teacher66 to 68

The terms in one line each

TermOne line
Generation time τNoise at 0, data at 1, throughout the lecture.
Flow map Fs,tThe exact jump from time s to time t along one path.
Average velocity uDisplacement over an interval divided by its length.
ScoreThe arrow toward higher density: the gradient of the log density.
Fake scoreA trained estimate of the score of the generator’s own crowd.
Stop gradient (sg)Treat a value as a fixed number during one update.
JVPA Jacobian times a vector, without building the Jacobian.
Rolling KV cacheKeys and values of recent chunks, oldest dropped when full.

A checklist for any fast sampler

The core, as code

This sketch gathers three updates of the lecture. jvp, teacher_eps, fake_eps and softmax stand for whatever your library provides. It is a plain reading of the slides, not code from the papers.

python# 1. MeanFlow, Ch 4: y data, n noise [B, ...]; u(x, s, t) -> [B, ...]
s, t = sample_times()                                   # s <= t
r = (1 - s) * n + s * y;  delta = y - n
u_pred, dudt = jvp(u, (r, s, t), (delta, 1, 0))      # direction (delta, 1, 0)
target = (delta + (t - s) * dudt).detach()                # stop gradient
loss = ((u_pred - target)**2).mean()
x1 = x0 + u(x0, 0, 1)                                      # sampling: one call

# 2. DMD generator update, Ch 6: frozen teacher, trained fake score
x = G(z, c);  eps = randn_like(x);  x_tau = alpha * x + sigma * eps
with no_grad():
    s_T   = -teacher_eps(x_tau, tau, c) / sigma
    s_phi = -fake_eps(x_tau, tau, c) / sigma
d = w_tau * alpha * (s_phi - s_T)                           # frozen direction
loss_G = (d.detach() * x).sum()                           # gradient is (dG/dtheta)^T d
# then the fake score learns from fresh samples of the current G
loss_fake = ((fake_eps(alpha * x.detach() + sigma * eps, tau, c) - eps)**2).mean()

# 3. Drifting, Ch 7: two batches, kernel exp(-distance / h)
def local_mean(x, y, h):                              # x [B, d], y [M, d]
    w = softmax(-cdist(x, y) / h, dim=1)                   # weights sum to 1
    return w @ y
x = G(z)
V = local_mean(x, y_real, h) - local_mean(x, y_gen, h)     # the two x terms cancel
loss = 0.5 * ((x - (x + V).detach())**2).sum(-1).mean()

Where this sits, and what comes next

This lecture is the speed half of interactive world models. Lecture 7 built generators that turn noise into data. Lecture 13 covered video world models. Here those generators become fast enough to run in a loop. The open questions on slide 70 are the next step: long-term consistency, supervision a causal student can reproduce, credit assignment through a rollout, and judging the consequences of new actions. Assignment 3 is released on Friday, October 30.

Keep going

Primary sources the slides cite, with their arXiv pages: Flow maps via self-distillation, BOOT, Progressive Distillation, Consistency Models, MeanFlow, DMD, DMD2, Generative Modeling via Drifting, Self Forcing, Self-Forcing++ and Inductive Moment Matching. The slides also cite π-Flow, Improved MeanFlow, Representation Fréchet Loss, Causal Forcing and a note on Gaussian drift, which we have not linked.

Course credit. This lesson re-teaches Lecture 14 of Penn CIS 6280 World Models (Fall 2026), taught by Jiatao Gu. The slides are linked at the top of this page and in the footer. The devices and the toy models are ours, and each one says so in its fine print.

The takeaway. A fast sampler is a different training problem, not a shorter slow one. Teach the jump, or teach the crowd. Then, for video, train the loop on the history it will really see.
A one-call generator makes sharp samples, but its outputs cover only one of the target's two modes. Which kind of signal could have missed this, and which check would catch it?

Now press Teach and explain, from memory, why one Euler step blurs, how the average velocity gives a one-call jump, what the two scores in DMD compare, and why a causal student cannot copy a bidirectional teacher. Then go back to the hero and move the dial again.

CIS 6280 Lecture 14: Fast Sampling and Interactive World Models
The course site · Lecture slides · Back to Gleams