Overview

7 Reasoning & Inference-Time Scaling

The chapter explains how reasoning models became a major leap in language model performance by combining long chain-of-thought generation with inference-time scaling, where extra computation at generation time can produce better answers. It frames reinforcement learning as moving from a minor post-training add-on to a central tool for shaping model behavior, especially as models grew capable enough to benefit from extensive reasoning before responding. The result is a new family of “thinking” models that often spend many tokens exploring a problem, then return stronger outputs on tasks like math, code, and science.

A central idea is Reinforcement Learning with Verifiable Rewards, which adapts the RLHF pipeline but replaces subjective reward modeling with simple verification functions that can judge correctness directly. In math, this may mean checking whether an extracted final answer matches the known solution; in code, unit tests can serve as the verifier. Because the reward is usually binary or otherwise objective, the model can be trained by repeatedly sampling multiple answers, reinforcing the successful ones, and revisiting the same data many times to discover behaviors correlated with correctness.

The chapter also surveys the evolution of reasoning training, from earlier work that encouraged chain-of-thought on verifiable tasks to the modern large-scale RL recipes used by models like o1 and DeepSeek R1. It highlights common implementation choices such as difficulty filtering, curriculum scheduling, relaxed clipping, removal of KL penalties, format and language-consistency rewards, and parallel test-time sampling. Looking forward, the field is still moving quickly, but the main lesson is that reinforcement learning now plays a foundational role in frontier model training, and future systems will likely refine rather than abandon these ideas.

RLVR in the form of an RL feedback loop. Instead of a reward model, a verification function is used.
figure

Summary

  • Reasoning models use reinforcement learning with verifiable rewards (RLVR) to dramatically improve performance on math, code, science, and other tasks where the correctness of an answer can be assessed. Unlike RLHF, which requires a learned reward model, RLVR uses verification functions – such as answer matching or unit tests – that return definitive correctness signals.
  • The core training loop applies the policy gradient algorithms from chapter 6 in a remarkably simple way: sample multiple answers to questions, take gradient steps toward the correct ones, and repeat.
  • Inference-time scaling – using more computation during generation to get better responses – is closely linked to reasoning training. RL-trained models learn to produce longer reasoning chains that are strongly correlated with improved performance, a meaningful shift from the superficial length bias seen in early RLHF.
  • Common practices for reasoning training include difficulty filtering (training only on problems the model solves 20-80% of the time), removing or relaxing KL penalties to allow greater exploration, format and language consistency rewards, and progressive length scheduling to combat overthinking.
  • The reasoning model landscape evolved rapidly from OpenAI’s o1 and DeepSeek R1 through dozens of open-weight models – including Qwen 3, Phi-4 Reasoning, Llama-Nemotron, and OLMo 3 Think – with the field converging on recipes that combine instruction tuning, RLHF, and large-scale RLVR in carefully sequenced stages. Substantial changes to these recipes are expected to continue.

FAQ

What is inference-time scaling in reasoning models?Inference-time scaling is the practice of improving model performance by spending more computation during generation, such as producing longer reasoning chains or sampling multiple candidate answers and selecting the best one.
How does RLVR differ from RLHF?RLHF relies on a learned reward model to judge subjective qualities like helpfulness or clarity, while RLVR uses a verification function that gives a definite reward based on correctness, such as whether an answer matches a ground truth or passes tests.
Why are reasoning models considered a major breakthrough for language models?Reasoning models showed that scaling reinforcement learning on verifiable tasks like math, coding, and science can dramatically improve performance, especially when models are trained to think extensively before answering.
What kinds of tasks are best suited for RLVR?RLVR works especially well in domains where correctness can be checked automatically, such as mathematics with exact answers, code generation with unit tests, and precise instruction following with verification rules.
Why is the \boxed{} format useful in RLVR?The \boxed{} notation makes it easy to extract the final answer from a response using a simple regular expression, which helps automated verification determine whether the answer is correct.
Why do reasoning models often generate longer responses?Reasoning models are trained to produce more thinking tokens, and that extra internal computation is often correlated with better downstream performance, although only when it actually helps solve the task rather than wasting compute.
What is the basic training loop used in RLVR?The core loop is: sample multiple answers for multiple questions, apply gradient updates toward the correct answers, and repeat the process many times over the same data.
What are some common implementation choices in reasoning-model training?Common choices include difficulty filtering, curriculum scheduling, removing KL penalties, relaxed clipping, asynchronous or off-policy updates, format rewards, language consistency rewards, length penalties, loss normalization, and parallel test-time compute scaling.
Why do many reasoning models use difficulty filtering?Difficulty filtering focuses training on problems the starting model gets right only part of the time, creating a useful learning signal; if a problem is always solved or never solved, there may be little or no gradient to learn from.
Which early models helped establish best practices for reasoning training?Important early and influential models include OpenAI’s o1 and DeepSeek R1, along with earlier research such as STaR, Quiet-STaR, TRICE, VinePPO, and Tülu 3, which helped shape modern reasoning training recipes.

pro $24.99 per month

  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose one free eBook per month to keep
  • exclusive 50% discount on all purchases
  • renews monthly, pause or cancel renewal anytime

lite $19.99 per month

  • access to all Manning books, including MEAPs!

team

5, 10 or 20 seats+ for your team - learn more


choose your plan

team

monthly
annual
$49.99
$499.99
only $41.67 per month
  • five seats for your team
  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose another free product every time you renew
  • choose twelve free products per year
  • exclusive 50% discount on all purchases
  • renews monthly, pause or cancel renewal anytime
  • renews annually, pause or cancel renewal anytime
  • Reinforcement Learning from Human Feedback ebook for free
choose your plan

team

monthly
annual
$49.99
$499.99
only $41.67 per month
  • five seats for your team
  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose another free product every time you renew
  • choose twelve free products per year
  • exclusive 50% discount on all purchases
  • renews monthly, pause or cancel renewal anytime
  • renews annually, pause or cancel renewal anytime
  • Reinforcement Learning from Human Feedback ebook for free
choose your plan

team

monthly
annual
$49.99
$499.99
only $41.67 per month
  • five seats for your team
  • access to all Manning books, MEAPs, liveVideos, liveProjects, and audiobooks!
  • choose another free product every time you renew
  • choose twelve free products per year
  • exclusive 50% discount on all purchases
  • renews monthly, pause or cancel renewal anytime
  • renews annually, pause or cancel renewal anytime
  • Reinforcement Learning from Human Feedback ebook for free