A student model is a smaller language model trained to reproduce outputs from a larger teacher model. For reasoning tasks, those outputs include both intermediate reasoning traces and final answers, transferring useful behavior into a cheaper model. section 8.0 section 8.1
The workflow generates teacher traces, prepares a training dataset, trains the student with supervised learning, and evaluates checkpoints. Hard distillation uses teacher-generated tokens as targets; soft distillation matches the teacher’s vocabulary probability distribution with KL divergence. section 8.1 section 8.11
A practical student-model training run typically:
- Combines a rendered prompt with the teacher reasoning trace and final answer, optionally using <think>...</think> tags. section 8.11
- Tokenizes examples once, filters them by sequence length, and reuses the processed dataset across epochs. section 8.11
- Trains with answer-only cross-entropy, then shuffles data, backpropagates, updates weights, and monitors validation loss. section 8.11
Concrete setup
DeepSeek-R1 serves as the teacher and Qwen3 0.6B as the student. A dataset built from 12,000 MATH training problems supports the distillation run, which takes about three hours on a DGX Spark and uses roughly 15 GB of RAM. section 8.1 section 8.11
Figure 8.3 This chapter covers distillation in four main steps: (1) distillation introduction and overview; (2) dataset preparation (steps 2a-2c); (3) training via distillation (steps 3a-3c); and (4) evaluation.
Use the workflow overview to connect dataset preparation, distillation training, and evaluation. section 8.1

