Book Review: Reinforcement Learning for Large Language Models

I was offered to read Reinforcement Learning for Large Language Models: Making the hard math easy by Arun Shankar and Mikhail Chertushkin in exchange for an honest review. The book explains how reinforcement learning is used to train LLMs, from classical RLHF to the GRPO-based recipes behind reasoning models. Every idea is explained “three times: as plain-language intuition, as a worked example with real numbers, and only then as mathematics”.
The overall structure

The nineteen chapters are split into four parts:
- Foundations (Chapters 1-4): the math toolkit, why next-token prediction doesn’t produce a helpful assistant, RL fundamentals, and a free training environment on Colab.
- Core methods (Chapters 5-10): SFT with a reasoning cold start, RLHF with PPO, DPO and Online DPO, reward modeling, and newer algorithms such as GRPO, RLOO, and KTO.
- Advanced techniques (Chapters 11-16): verifiers and process reward models, the DeepSeek recipe, test-time compute, self-play and Constitutional AI, multi-objective rewards for agents, and rewards for code, math, tools, and dialogue.
- Production (Chapters 17-19): recipes for a chatbot, a reasoner, and an agent, followed by debugging, scaling, and deployment.
Most chapters have a companion notebook that runs on a free Colab T4 GPU with small Qwen2.5 models.
What I liked
Most ideas include calculation examples you can follow by hand. For example, Chapter 6 has a cautionary tale about the KL penalty. A policy trained on reward alone drifts into writing “PERFECT PERFECT EXCELLENT EXCELLENT AMAZING AMAZING…”, and the reward model scores this higher than a genuine answer. Adding a KL penalty with β = 0.02 doesn’t help, as the nonsense still has the highest objective. Only a larger β = 0.1 puts the genuine answer on top, because the KL of a degenerating policy grows much faster than its reward. I liked that the book shows the first fix failing instead of jumping straight to the correct answer.
Chapter 9 starts with a statement I fully agree with: “Getting the reward right matters more than getting the algorithm right”. Its taxonomy of reward hacking covers length gaming, sycophancy, style over substance, and filler phrases like “Great question! Let me break this down for you”. In the book’s words, most forms exploit “a mild bias that annotators really do have, which the reward model then learns, and the policy then exaggerates”. The companion notebook trains a reward model on hand-written pairs in which the preferred answer is always the longer one. It then scores a padded answer, a list of ML keywords, and a circular non-answer higher than short correct answers.

I saw a similar pattern with coding agents in the ROGII competition. Claude kept hardcoding solutions for the three visible test wells, and when I asked it to summarize our approach, it claimed that the public leaderboard consisted only of these three wells. In effect, it optimized for the data it could see instead of the actual task.
Chapter 10 compares REINFORCE, PPO, GRPO, and RLOO by the baseline each one subtracts from the reward. PPO learns a value function for it, GRPO uses the average reward of a group of answers to the same prompt, and RLOO uses the average of the other answers in the group. Seeing them side by side makes it clear how the newer methods simplify PPO. Chapter 12 then explains why the DeepSeek-R1 recipe works with a binary reward: “GRPO does not need rich reward signals; it needs variance within each group”. If every answer in a group is wrong, all advantages are zero, and the model learns nothing from that prompt.

Chapter 13 covers test-time compute: best-of-N, self-consistency, self-correction, beam search, and MCTS. It frames all of them as one trade-off: “Training-time compute is a one-time investment that improves every future query. Test-time compute is a per-query cost that improves only the current response”. The chapter ends with the question of how to split a fixed budget between training and inference, and suggests routing queries by difficulty so that only the hard ones get the expensive search.
This matched my experience in the IHES Picture Cube competition from the CayleyPy series on Kaggle, where a small learned heuristic guided a beam search through puzzle states. Widening the beam from 8K to 65K states shortened the solutions by about 2000 moves in total, while training larger models sometimes made the results worse.
The book is also open about the limits of its small models. When the fine-tuned 0.5B model in Chapter 5 sometimes repeats its references block, the authors call it “the honest limit of a tiny model on a free GPU”. Chapter 14 warns that a 0.5B model “is a weak self-critic that rubber-stamps everything ‘OK’”, so its notebook needs a few examples before the critique step works.
What could have been better
A few small things I would have liked to see differently:
- Chapter 11 calls verifiers “free, perfect, and immune to reward hacking”, but models can learn to game unit tests too.
- Table 12.4 lists DeepSeek-R1’s training as “Pure RL with GRPO (no SFT)”, which contradicts the chapter’s own description of R1.
- I would have liked a short section on newer GRPO variants such as DAPO, Dr. GRPO, and GSPO.
But these are small nitpicks that are completely overshadowed by the good sides of the book.
Conclusion
This book is a good fit for ML engineers, applied researchers, and software engineers who build with LLMs and want to understand the reinforcement learning behind post-training. It assumes Python and basic machine learning, but no RL background, as the math starts from scratch in Chapter 1. Compared to A Practical Guide to Reinforcement Learning from Human Feedback that I reviewed in April, this book spends less time on classical RL and more on GRPO, verifiers, and reasoning models.
The main ideas of the book are: SFT teaches the format and RL teaches behavior from outcomes, the reward matters more than the algorithm, the reward signal should match the task, and evaluation should be planned before training.
bookreview books rl rlhf llm reasoning