Inference-time scaling
Draft
Draft
This page is a skeleton for review: a short opening, planned headings, diagrams and references. The article is not written yet. It is listed here so the chapter can be checked as a whole. (Quarto’s draft: true would hide the page from the preview, so we mark the draft in this callout instead.)
Spending compute after the model is already trained
One way to get better reasoning is to train a better model. Another is to give the model you already have more time at the question: a longer chain of thought, several attempts and a vote, or a second pass that tries to fix the first. That is inference-time scaling. This page will take the idea in Raschka’s chapters 4 and 5, in plain language, and keep training (RL, distillation) for their own pages.
Chain of thought: one longer attempt
- Ask the model to write the working, then the answer. Often that alone raises accuracy, because the extra tokens give it room to plan.
- Everyday analogy: thinking with a pencil instead of answering from the doorway.
Several attempts, then a vote
- Self-consistency and best-of-N: sample more than one trace, then pick the answer that appears most often, or the one a scorer prefers. You buy accuracy with test-time compute.
- The leftover problem: you pay for every question, and a confident majority can still be wrong.
A second look: self-refinement
- Raschka’s chapter 5 is the natural next step: the model (or a small loop around it) reviews or revises an attempt instead of only voting among first drafts.
- Keep this short and practical: when a second pass helps, and when it just spends tokens.
The bill at test time
- A simple picture of the trade-off: more samples or longer traces versus cost and latency. This is why later work also tries to train the model to use its thinking time well, which belongs on the RL page, and why a smaller distilled student can still be useful.
Planned diagrams
- Own light and dark: one chain-of-thought path beside a bundle of sampled paths that meet in a vote.
- Own light and dark: a small self-refinement loop (attempt → critique or check → revised attempt).
- Optional: a sketch of “more compute, higher accuracy” that stays honest about diminishing returns.
Planned references
- Sebastian Raschka, Build a Reasoning Model (From Scratch), Manning, chapters 4 and 5.
- Jason Wei et al., Chain-of-Thought Prompting Elicits Reasoning in Large Language Models, 2022.
- Xuezhi Wang et al., Self-Consistency Improves Chain of Thought Reasoning in Language Models, 2023.
- OpenAI, Learning to Reason with LLMs (o1), 2024, as the public example of spending more at test time.
See also
- What is a reasoning model? (draft)
- Evaluating reasoning (draft)
- Reinforcement learning for reasoning (draft)
- Language model inference