Save this video free

On-policy distillation

Mohit Iyyer · 1:11:10 · Watch on YouTube

On-policy distillation Watch on YouTube →

Overview

Mohit Iyyer connects supervised fine-tuning to reinforcement learning by defining policies, rollouts, rewards, and the difference between off-policy data and model-generated on-policy data. He explains exposure bias, soft-target distillation with teacher probabilities, and how forward versus reverse KL leads to different training behavior, including mode covering and mode seeking.

Key takeaways

Chapters

0:00 Course Roadmap and SFT Implementation Options
2:36 Teacher-Generated Responses and the Policy Definition
4:39 Rollouts, Rewards, and Sparse Feedback
12:35 Off-Policy Data Versus Model-Generated On-Policy Data
18:23 Exposure Bias from Ground-Truth Prefixes
22:35 On-Policy Feedback and the Cost of Autoregressive Training
27:22 Hinton’s Distillation and Soft Teacher Targets
38:01 Soft-Target Distillation Requires Teacher Probabilities
41:07 KL Divergence Measures Teacher-Student Mismatch
43:35 How Forward KL Weights Teacher Outcomes
49:46 SFT Negative Log-Likelihood as Forward KL
54:40 Expected Reward and Monte Carlo Rollout Sampling
1:00:14 Reverse KL Uses Student Rollouts and Teacher Scoring
1:06:29 Forward KL Mode Covering Versus Reverse KL Mode Seeking

Keep these chapters and the full searchable transcript in your own library.

Transcript excerpt

0:06 All right. Let's get started. So, today we are going to bridge between supervised fine-tuning, which we talked about in the previous couple classes, and reinforcement learning, which we will spend quite a bit of time on. So, today we'll be introducing a bunch of notation, and we will also be focusing a lot of our time on a new class new algorithm for this semester called on-policy distillation, which is very common these days in training frontier models. So, we will start this topic and likely not finish today. We'll have to finish on Monday, and then we will start talking about

0:55 reinforcement learning. But, the two things are related enough that after we cover this variant of distillation, you should be well positioned to understand how reinforcement learning differs from the distillation setup. Also, we'll try on the you know, in the next few weeks to keep unifying all these algorithms together as much as possible so that you understand their pros, cons, implementation, what they're actually optimizing. Okay, so before we start some logistics, your homework is finally released. So, please look into that, especially if you don't have that much experience coding

1:44 in PyTorch. Um, it is going to be a useful homework to understand some of the low-level implementation behind transformers. Once you guys submit that homework, we'll have a follow-up homework that has you kind of doing SFT and possibly even some RL on so so like more of a post training focused homework. Um, and we're just waiting for one person to finish their exam on Friday and we'll post the results and discuss them on Monday. Okay, great. So, um, last time um, we talked about SFT and instruction

2:39 tuning. And now this can either be implemented via full model tuning where we compute the DLD data for all of

This is the start of the transcript. Save this video free for the whole transcript, searchable and time-coded.

Related notes

Summary, takeaways, and chapters were generated by AI from the video's transcript and may contain errors. The video belongs to its creator, Mohit Iyyer.

Want the full transcript?

Save this video in YouTube Collector to get its complete searchable transcript, your own AI summaries, and a library that keeps every video you collect in one place.