LLM RL V: Reasoning, Agents and Scalable Training

The final module extends the trajectory from one completion to reasoning and tool interaction, then studies the actor, verifier and learner system that produces training data. It requires controls that distinguish learned improvement from search, longer traces, reward loopholes, stale policies and extra compute.

Section 12 of 12 · 13 units · about 55 hours

0/13

By the end you can Complete a small reasoning or tool-use RL study with versioned trajectories and a reproducible rollout-update path, then defend a learned-policy claim against search, length, verifier, staleness and compute explanations using independent evaluation and a retained negative result.

Units

Build it

Mini project · about 14 to 20 hours

Reasoning agents, rollout systems and reproduction

Integrate verifiable reasoning, tool use and the rollout system in policylab, then prove the behavior with independent evaluation and a clean reproduction. The system, ledgers and extension close the track into the capstone.

  1. 1Build one verifiable math and code task family in envs/ with an isolated verifier in llm/, gate all-pass against partial credit on fixed outputs, hold out hidden tests, and follow the Stanford CS224R Countdown verifier contract before any training.
  2. 2Contrast outcome and step rewards on fixed traces with discounted-return recomputation, compare greedy against self-consistency and small search at matched token budgets, then distill verified traces with explicit length and invalid-trace rules using the reasoning-model book loop.
  3. 3Implement the multi-turn tool loop in agents/ with action-only masks, run tool calls in a separate process with timeout inside a resettable sandbox, and prove deterministic replay from recorded seeds and tool results with retry deduplication and duplicate-action accounting.
  4. 4Split actor, rollout, verifier and learner roles in systems/ with policy-version stamps and staleness records, compare single-example against batched generation with time and memory records, and attribute backpressure and starvation from queue evidence.
  5. 5Write checkpoint and sampler recovery with resume rules in systems/, deduplicate retries by call identity with every failure retained, then run a versioned prompt curriculum and account rollout and verifier throughput, update utilization and total compute in ledger/.
  6. 6Freeze an independent harness in eval/ with capability, safety and shift slices, attack verifiers and judges with one retained hacked regime and postmortem from the Hands-on Modern RL probe set, then reproduce from a clean checkout and run one prespecified extension keeping the negative regime.
What you hand in
  • The agents/ and systems/ loop with sandbox, roles, recovery and ledgers.
  • Reasoning, search and distillation studies with length and budget evidence.
  • Independent evaluation, hacking postmortem, reproduction and extension report.
How to check it
How it's graded

Reward honesty

Pass: Isolated verifier with hidden tests separates format from accuracy and search gains are budget-matched.

Great: A partial-credit rule flips one update and the hidden set catches the gaming.

System correctness

Pass: Roles, versions, replay, recovery and deduplication pass with failures retained and counted.

Great: A killed run resumes with identical ordering and a retried call counts once.

Throughput honesty

Pass: The curriculum is versioned, utilization is consumed over produced rollouts, and compute includes failed work.

Great: Queue evidence names the bottleneck and a placement change keeps its losing side.

Evaluation judgment

Pass: Independent slices, attacks and clean reproduction support a scoped claim with negatives kept.

Great: The extension states its falsifier and names the broken assumption on failure.

Resources

  • RLHF Book - Reasoning, Synthetic Data, Tools and EvaluationNathan Lambert

    Study Chapter 7 (reasoning and inference-time scaling), Chapter 12 (synthetic data and on-policy distillation), Chapter 13 (tool use), Chapter 14 (over-optimization) and Chapter 16 (evaluation). Build a claim map separating RLVR learning, inference-time search, on-policy distillation, tool trajectories, reward overoptimization and independent evaluation.

  • RLHF Book Course - Lectures 5, 7, 11 and 12Nathan Lambert

    Use Lecture 5 (the rise of reasoning models), Lecture 7 (synthetic data and modern post-training), Lecture 11 (tool use and the road to agents) and Lecture 12 (frontier model evaluation). Tie every mechanism to a distinct data and compute budget.

  • DeepSeek-R1 Technical ReportDeepSeek AI

    Read version 2 of the report (January 2026; the Nature 2025 paper is the peer-reviewed version): the R1-Zero and R1 training pipeline, reward design, observed behaviors and limitations. Reproduce only a reduced verifier-driven question and test whether longer sampling or selection explains the observed gain.

  • Stanford CS224R 2026 LLM RL Default Project - ExtensionStanford University

    Use the specification sections on SFT, IPO, RLOO, evaluation and one extension such as off-policy sampling, test-time inference, exploration, self-play or tool reasoning. Build independent code on a distinct task and respect all course restrictions.

  • LLM Post-Training Laboratory - Final IntegrationRoadmap-Final

    Finish the bounded rollout and verification queue, reasoning or tool extension, independent clean and adversarial evaluation, reward-hacking postmortem, policy-lag and throughput records, clean reproduction and one prespecified negative or positive result.

  • Build a Reasoning Model (From Scratch) - Chapters 3, 6 and 8Sebastian Raschka (Manning)

    Use Chapter 3 (a math verifier: boxed-answer extraction, normalization and equivalence checks), Chapter 6 (RLVR with GRPO on a MATH subset) and Chapter 8 (distillation from filtered rollouts) as the smallest verifier-to-distillation path on Qwen3 0.6B.

  • Tulu 3: Pushing Frontiers in Open Language Model Post-TrainingLambert et al. (Ai2, 2024)

    Read the RLVR section: verifiable rewards for math, instruction following and constraints, and how the RLVR stage sits after SFT and DPO. Compare its recipe with R1-Zero on what is rewarded and what is held out.

  • STaR: Bootstrapping Reasoning With ReasoningZelikman et al. (NeurIPS 2022)

    Read the generate, filter by correctness and fine-tune loop and the rationalization step. Use it as the rejection fine-tuning control that an RL method must beat at matched samples.

  • RAGEN: Understanding Self-Evolution in LLM Agents via Multi-Turn Reinforcement LearningWang et al. (2025)

    Read the multi-turn trajectory formulation and the training instabilities it reports for agent RL (collapse into repetitive reasoning). Use it to design the diagnostics for a small multi-turn environment.

  • Berkeley CS 185/285 Deep Reinforcement Learning (Spring 2026) - LLM RL Default Final ProjectUC Berkeley

    Read the default project for open-ended instruction following: offline DPO, IPO and AOT, online GRPO, Dr. GRPO and GSPO, and judge-based win rates against a frozen base. Use it as a second extension menu; its compute assumes cloud GPUs and a paid judge model.

  • Hands-on Modern RL - Reasoning, Agentic RL and SafetyWalking Labs

    Use the build-an-agentic-training-system page (a from-scratch trainer exercise), one reasoning or search control and the reward-hacking evaluation chapter selectively. Skip the pages that need API keys or several GPUs and the frontier surveys. Pin commit 9231bab of walkinglabs/hands-on-modern-rl; its code/chapterNN folders do not follow the site chapter numbers.

  • veRLByteDance

    Inspect the hybrid-controller architecture, worker roles, supported algorithms and examples at commit 8718ca3 after single-device losses pass. Trace one rollout from generation through reward and update, record policy lag and run only hardware-compatible examples.

  • Reinforcement Learning CheckpointRoadmap-Final

    Take the checkpoint closed-note after the integrated project. Pass the estimator and state reconstruction, unseen failure diagnosis, matched-budget comparison, external evaluation and research-readiness clauses.