Student models learn better from similar teachers than stronger ones

Proximity over Strength in On-Policy Distillation: Evidence from Teacher Swaps in Code and Math

Machine Learning

Summary

When teaching an AI model to solve code and math problems, the authors found it works better if the teacher is a version of the student itself rather than a stronger, unrelated model. They showed that students trained on their future improved self outperformed those taught by higher-scoring but less similar teachers. This means that familiarity or closeness between teacher and student matters more than the teacher’s raw strength in guiding learning.

What this means in practice

  • For ai developers: Design on-policy distillation training where the teacher model closely matches the student's current reasoning to improve learning outcomes.
  • For automated coding platforms: Improve code solution accuracy by training student models with teacher models that reflect their own future learning rather than larger, unrelated models.

Authors

Zhiyuan Ma

Abstract

In on-policy distillation, a teacher scores the reasoning its student writes, including choices the teacher would rarely make itself. We compared two ways to choose that teacher. One uses the teacher's own benchmark score. The other uses the mean log probability it assigns to the starting student's reasoning tokens. In each domain we trained a fresh copy of the same student with each teacher. One teacher was the student's future self, a copy of the starting model that had already improved through reinforcement learning. On 172 competitive programming problems, this teacher assigned the highest probability on average to the student's choices and raised its mean score from 7.10 to 13.55 out of 100. With either of two stronger teacher models, the student's mean score fell below 4. A separate Flash recipe first trained the student on demonstrations. Adding program execution rewards gave no clear gain over its best distillation checkpoint. We identified the ranking retrospectively on code and tested it prospectively on competition math. The future-self student finished 7.0 percentage points ahead of the student taught by a stronger 32B model.