arXiv(opens in a new tab)cs.LGOct 2026Cited by 3 papers on PaperVantage

Manuscript Offprint

arXiv:2610.22236

Training-Free On-Policy Distillation

Bangji Yang, Jiajun Fan, Zhaoyu Zhu, Hongbo Ma, Ge Liu

Abstract

On-policy distillation consolidates specialist models into one student at the price of rollouts, teacher passes and gradient steps for every teacher. We show that the consolidation does not need training: with forward passes only, the capabilities of separately tuned specialists can be aggregated into one model that is, on average, more accurate than either specialist alone. When specialists share a base model, distillation has an exact layer-wise solution: each linear layer of the fused model must reproduce every specialist's output on the inputs that specialist receives while reading its own answers, a least-squares problem whose solution needs only the second moments of those inputs. One forward pass over a few hundred rollouts provides them. We call this training-free on-policy distillation (TF-OPD). What the rollouts contain matters more than the solver: answers truncated in repetition loops are few among a mathematics specialist's rollouts but carry a large share of their tokens, and removing them lifts the fused model on AIME25 from task arithmetic's level to the specialist's at matched precision. On Olmo 3 7B, a few GPU-hours of forward computation per specialist yield a generalist that keeps most of each specialist's gain on each of seven mathematics and code benchmarks.

Date: October 16, 2026

Correspondence: geliu@illinois.edu

1 Introduction

Reinforcement learning from verifiable rewards has become the standard way to turn a base language model into a strong reasoner in one domain [1–5]. Because the reward is domain-specific, the result is a family of specialists that share an initialization: from one base checkpoint, one model is trained on competition mathematics, another on programming, a third on instruction following [6]. Each is far ahead on its own domain and far behind on the others, so a user who wants mathematics and programming in the same model has to build that model from the specialists.

The available routes either train or ignore the rollouts (Table 1). One can repeat reinforcement learning on the union of the domains [7, 8], or distill: on-policy distillation lets the student generate, has a teacher supervise those generations, and updates the student on its own distribution [9–11]. It has become a post-training route for consolidating specialists into one student [12], at the price of rollouts, teacher passes and gradient steps for every teacher. The training-free alternative is to merge weights. Arithmetic on parameters [13] does not know which inputs the parameters act on, and on reinforcement-learned specialists it can give up part of what made them specialists: summing the mathematics and coding updates of a 7B model leaves it below the mathematics specialist on AIME25 (Section 4.5). RegMean [14] does use inputs, in a closed-form least-squares solution, but takes them from each task's training corpus, whereas a reasoning model spends almost all of its computation on text it has generated itself.

a Mathematics against code

Figure

○ Base model

b Every benchmark

■ Math specialist

◇ Code specialist

c Mean over seven benchmarks

Figure

TF-OPD

Figure 1 A generalist with the highest mean accuracy, without training (Olmo 3 7B). (a) Mean accuracy on the five mathematics benchmarks against mean accuracy on the two code benchmarks; dashed lines mark what each specialist reaches on its own domain, and TF-OPD, computed from the two with forward passes only, lies next to the corner they define. (b) Every benchmark: the base model and the specialists on the upper line of each row, TF-OPD below, and at the right the score of that domain's specialist and of TF-OPD. (c) Mean accuracy over the seven benchmarks: TF-OPD is more accurate on average than either specialist it was built from.

RouteNo trainingOn-policy inputsMatches teachers
Multi-domain RL✕✓✕
On-policy distillation✕✓✓
Task arithmetic, TIES, DARE✓✕✕
RegMean✓✕✓
TF-OPD (ours)✓✓✓

Table 1 Routes from several specialists to one model. TF-OPD needs no training, gathers its statistics on text the models generate, and is fit to match the specialists' outputs.

We connect the two lines. For a single linear layer, asking the fused weight to reproduce each teacher's output on that teacher's inputs is the distillation objective restricted to the layer, and it is the least-squares problem that RegMean solves: once the second moments of the inputs are known, no optimization is left to run. TF-OPD gathers those moments where on-policy distillation gathers its data, on rollouts. Each specialist answers a few hundred training problems from its domain, the answers are filtered, the specialist reads its kept answers once with teacher forcing while forward hooks accumulate a Gram matrix per layer, and each layer is then solved exactly. Nothing is back-propagated.

On Olmo 3 7B this yields a generalist without a single gradient step: one model that keeps most of what each specialist gained on five mathematics and two code benchmarks and that is, on average, more accurate than either specialist alone (Figure 1). Three findings explain when it works. First, the filter carries the result. A minority of the mathematics specialist's rollouts run to the length limit in a repetition loop: few among the answers, several times more among the tokens. With them the closed form is no better than task arithmetic on AIME25, and removing them alone closes the gap to the specialist scored in the same format. Second, the token-level fit is not what fails: the unfiltered model already follows the specialist almost token for token, so hard problems are decided by which inputs the statistics weigh. Third, rollouts written by the student, the on-policy data of trained distillation, do not improve the closed form. Reinforcement learning also moves weights so little that the 16-bit release format distorts a fused update, which makes the formats of storage and evaluation part of the method.

1 Rollouts 2 Selection 3 Statistics

4 Solve

Figure

Figure 2 Overview of TF-OPD. Two specialists trained from one base model each answer training problems of their own domain (1); answers that end in a repetition loop or fail grading are dropped (2); each specialist reads its kept answers once while hooks record the second moments GdG_{d} of every layer's inputs (3); and each layer of the fused model is obtained by one linear solve (4). Steps 1 to 3 are forward passes and step 4 is linear algebra, so no gradient is computed at any point. Step 2 decides the hard problems (Section 3.4).

Contributions.

  • We show that the capabilities of separately tuned specialists can be aggregated without training. On Olmo 3 7B, a closed-form fusion of a mathematics and a coding specialist keeps most of each specialist's gain on seven benchmarks and is, on average, more accurate than either specialist alone, after a few GPU-hours of forward computation per specialist.

  • The method, TF-OPD, reads layer-wise distillation from several teachers as the closed-form problem of RegMean and feeds it statistics from the specialists' own rollouts, using forward passes only.

  • We show that the composition of those rollouts decides the outcome on hard problems. Truncated answers ending in repetition loops are a small share of answers and a large share of tokens, and removing them separates a fused model that falls short of its mathematics specialist from one that matches it in the same evaluation format.

  • We analyze what matters and what does not: a close token-level fit does not protect hard problems; student rollouts, domain reweighting and mined hard problems do not improve on selection; numerical precision does.

References (43)