The House of Mesia’s X
Live0 online now0 members0 guests0 on this page0 page views0 today0 all-time visits
← Teaching ai computing

Lecture 10 How AI Learns to Reason of Deep Reinforcement Learning Course at Stanford

Like & subscribe

Let's move from general language tasks to the specific challenge of solving complex technical problems—like math and coding—where "looking right" isn't enough; the model must actually be right. The Limits of Next-Token Prediction A central theme is the inadequacy of standard supervised learning for reasoning. Traditional models are trained to approximate a ground-truth distribution through next-token prediction. However, high-quality human data for hard reasoning problems is scarce, and researchers estimate we may run out of it by 2028. More importantly, supervised models often become "stochastic parrots" that produce solutions looking sensible to a human expert but containing fundamental logical errors, RL provides a way to fix this by prioritizing the correctness of the final answer over the mere imitation of text. Reasoning as a Markov Decision Process (MDP) The Evolution of Classical Methods: RFT and the "Spurious Step" Problem The lecture evaluates early methods like Rejection Fine-Tuning (RFT), where a model samples many solutions, filters for the correct ones, and fine-tunes on them. While RFT can be 2x more data-efficient than human-led imitation learning, it eventually hits a generalization bottleneck where test error starts to increase. This failure is often caused by spurious steps—irrelevant or logically incorrect calculations that coincidentally still lead to the right answer in a training rollout. If the model mimics these "lucky" but flawed traces, it fails to learn true problem-solving strategies. Credit Assignment: Advantages and Process Reward Models To eliminate spurious steps, RL uses per-step credit assignment. By performing "rollouts" from different points in a solution, researchers can estimate: Q-Values: The expected future success starting from a specific prefix and action. Advantages: The difference in Q-values between steps, which identifies how much a specific step actually contributed to a successful outcome. These advantages are used to filter training data or to train Process Reward Models (PRMs)—also known as verifiers—that score every individual step rather than just the final result. This dense reward signal can provide up to an 8x boost in data efficiency over standard imitation learning. Modern Extensions: "Thinking" Models The lecture concludes with a look at modern "thinking" models like DeepSeek R1 and OpenAI o1. Interestingly, the core RL objectives remain similar to classical methods, but the action space has changed. These base models are now capable of sampling meta-procedures—like backtracking, self-verifying, and long-form thinking—which RL then optimizes to achieve superhuman performance

Lesson 172 · Teaching ai computing

Guided learning · 0 of 5 steps

Make this lesson your own

Watch & notice

Lecture 10 How AI Learns to Reason of Deep Reinforcement Learning Course at Stanford

What is the main idea? Notice one detail you could explain to someone else.

Sign in to save practice

Sign in to record yourself and receive speech feedback.

Sign in to practice