Skip to publication

18 min read

ReOPD — offline multi-turn distillation without environment rollouts

Online on-policy distillation forces LLM agents to execute live environment rollouts and query teacher models at every step, making multi-turn training prohibitively expensive. ReOPD replaces live environment interactions with replayed teacher prefixes while preserving on-policy student actions at the evaluated step. This eliminates tool calls during student training and speeds up rollout throughput by at least 4×4\times without degrading reasoning accuracy.

By the end you should be able to trace a student action along a replayed prefix, compute the geometric bridge weight between student and teacher occupancies, and derive the step-decay schedule κt\kappa^t that resolves the two-sided prefix trap.

Contents

Why online multi-turn distillation scales poorly

Why does standard multi-turn on-policy distillation become computationally intractable in tool-use environments?

Why does standard on-policy distillation in multi-turn tool environments become computationally intractable as agent training scales? In a multi-turn mathematical reasoning task with Python code execution, evaluating a student policy πθ\pi_\theta against an expert teacher policy πT\pi_T requires generating fresh candidate actions AtA_t and obtaining live environment observations OtO_t across TT interaction steps. Because each policy update alters the student's trajectories, the training loop is forced to execute fresh environment rollouts and query teacher target distributions across newly visited interaction histories HtH_t at every step .

The naive attempt to perform on-policy distillation executes this interactive loop live inside the training pipeline. In a standard setup, the student policy generates actions, sends code snippets to a live Python execution server, waits for output messages, and appends the new observation Ot+1O_{t+1} to build history Ht+1H_{t+1}. Because policy optimization modifies the student parameters at every gradient step, the student history distribution student history occupancy dθoldtd_{\theta_{\mathrm{old}}}^t constantly changes. Consequently, the training loop cannot reuse past rollouts and must re-run the live Python environment for every updated batch. When scaling this process to complex agentic workloads that combine code interpreters, web retrieval tools, and databases, hosting and managing all execution environments concurrently introduces severe deployment complexity and hardware contention .

This fully online requirement creates a severe computational bottleneck. Generating fresh environment observations OtO_t and querying teacher conditionals πT(Ht)\pi_T(\cdot \mid H_t) at every update step causes training throughput to collapse. Live execution latency dominates wall-clock time, tool execution servers require massive process concurrency, and hosting large teacher models alongside active environment containers consumes prohibitive memory resources.

A compelling alternative is off-environment prefix replay: replacing live execution with pre-collected teacher trajectories, where observations OtO_t are drawn from recorded execution traces. Reusing teacher prefixes removes live environment interactions entirely, allowing offline trajectory pools to be shared across diverse tasks. However, this shift creates a new unresolved tension: while replaying static teacher prefixes eliminates environment overhead, it introduces sequence drift between teacher-generated prefixes and on-policy student actions.

The two-sided distribution shift

How does substituting teacher prefixes for student roll-ins create a trade-off between relevance and reliability?

Suppose our LLM agent is attempting a multi-turn mathematical reasoning problem using a Python code interpreter. At step 33, the student policy student policy generates flawed code, producing an execution error and a traceback history that the expert teacher policy never encountered during its own training. If we evaluate the student strictly on its own rollout history from student history occupancy, the training state is perfectly relevant to the student's operational distribution. However, when we query the teacher for a target distribution on this uncalibrated history, its predictions become erratic because the state lies outside the teacher's reliable domain.

Conversely, if we replace the student's rollout with a pre-collected trace from teacher history occupancy, every code block and environment output is pristine. The teacher delivers sharp, low-entropy target distributions, but the student never learns how to handle its own buggy code. This tension exposes the two-sided distribution shift : prioritizing student relevance by sampling from student history occupancy corrupts teacher supervision, whereas prioritizing teacher reliability by sampling from teacher history occupancy leaves the student fragile to its own mistakes .

To quantify this trade-off, we compare the objective against an ideal target ideal improvement target, which evaluates the student on its own environment occupancy student history occupancy against the true optimal step action. When we substitute the ideal target with the teacher teacher policy on an arbitrary effective prefix distribution, the discrepancy between the ideal interactive objective R(θ;θold)\mathcal{R}^\star(\theta;\theta_{\mathrm{old}}) and the replayed distillation loss Lρ(θ;θold)\mathcal{L}_\rho(\theta;\theta_{\mathrm{old}}) is upper-bounded by two distinct mismatch terms .

R(θ;θold)Lρ(θ;θold)ExD[t=1Tαt{2BTV(dθoldt(x),ρt(x))+EHtρt(x)[ϵT,tθ(x,Ht)]}]\left| \mathcal R^\star(\theta;\theta_{\mathrm{old}}) - \mathcal L_\rho(\theta;\theta_{\mathrm{old}}) \right| \le \mathbb E_{x\sim\mathcal D} \left[ \sum_{t=1}^{T} \alpha_t \left\{ 2B\, \mathrm{TV}\left(d_{\theta_{\mathrm{old}}}^{t}(\cdot\mid x), \rho_t(\cdot\mid x)\right) + \mathbb E_{H_t\sim \rho_t(\cdot\mid x)}\left[\epsilon_{T,t}^{\theta}(x,H_t)\right] \right\} \right]
The error between the ideal objective R\mathcal{R}^\star and the replayed loss Lρ\mathcal{L}_\rho is bounded by 2B2B times the total variation distance between student occupancy dθoldtd_{\theta_{\mathrm{old}}}^t and effective prefix distribution ρt\rho_t, plus the expected teacher reliability error ϵT,tθ\epsilon_{T,t}^\theta under ρt\rho_t.

The first term in the bound measures student occupancy mismatch via total variation distance TV(dθoldt,ρt)\mathrm{TV}(d_{\theta_{\mathrm{old}}}^t, \rho_t), scaled by the uniform loss bound bounded loss constant . This mismatch shrinks to zero only when the effective prefix distribution effective prefix distribution matches the student's live environment occupancy student history occupancy. The second term measures expected teacher unreliability Eρt[ϵT,tθ]\mathbb{E}_{\rho_t}[\epsilon_{T,t}^\theta], which remains small only when ρt\rho_t draws histories where the teacher's target distribution stays close to the ideal target qtq_t^\star .

Evaluating either extreme reveals why simple distribution choices fail . Selecting ρt=dθoldt\rho_t = d_{\theta_{\mathrm{old}}}^t zeroes out the occupancy mismatch, but as tt increases, student errors compound and drive Edθoldt[ϵT,tθ]\mathbb{E}_{d_{\theta_{\mathrm{old}}}^t}[\epsilon_{T,t}^\theta] upward as the teacher is queried on unfamiliar code tracebacks. Conversely, selecting ρt=dTt\rho_t = d_T^t minimizes teacher unreliability but maximizes occupancy mismatch 2BTV(dθoldt,dTt)2B \mathrm{TV}(d_{\theta_{\mathrm{old}}}^t, d_T^t). Because neither purely student-on-policy nor purely teacher-forced history distributions minimize both error terms simultaneously across all interaction steps, effective distillation requires a mechanism that explicitly balances relevance against reliability.

The geometric occupancy bridge

How can an effective history distribution ρt\rho_t^\star balance student relevance against teacher reliability?

When an LLM agent solves a multi-turn math problem using a Python interpreter, training prefixes set both where the student learns and where the teacher is asked to supervise. If we sample prefixes strictly from the student's history occupancy student history occupancy, the student encounters states produced by its own past interpreter errors. However, as the student drifts off-track into malformed code contexts, the teacher policy teacher policy is queried on uncalibrated histories where its target conditionals become unreliable . Conversely, sampling prefixes solely from teacher occupancy teacher history occupancy provides reliable target distributions, but leaves the student untrained on recovery paths. A naive linear mixture 12dθoldt+12dTt\frac{1}{2} d_{\theta_{\mathrm{old}}}^t + \frac{1}{2} d_T^t fails because it assigns mass to low-probability regions of either distribution without preserving the joint likelihood structure of valid multi-turn interaction traces.

To minimize both KL divergences to student occupancy student history occupancy and teacher occupancy teacher history occupancy, we need a formal interpolation between student and teacher history occupancies . We define the optimal effective distribution optimal effective history distribution ρt\rho_t^\star as the minimizer of a trade-off objective between student relevance and teacher reliability :

ρt=argminρt{λstu,tDKL(ρt(x)dθoldt(x))+λtea,tDKL(ρt(x)dTt(x))}\rho_t^\star = \arg\min_{\rho_t} \left\{ \lambda_{\mathrm{stu},t} D_{\mathrm{KL}}\left(\rho_t(\cdot \mid x) \parallel d_{\theta_{\mathrm{old}}}^t(\cdot \mid x)\right) + \lambda_{\mathrm{tea},t} D_{\mathrm{KL}}\left(\rho_t(\cdot \mid x) \parallel d_T^t(\cdot \mid x)\right) \right\}
The optimal distribution ρt\rho_t^\star balances the KL divergence to the student's occupancy against the KL divergence to the teacher's occupancy using scalar trade-off weights λstu,t\lambda_{\mathrm{stu},t} and λtea,t\lambda_{\mathrm{tea},t}.

Solving this constrained optimization problem yields the geometric occupancy bridge :

ρt(htx)[dθoldt(htx)]γt[dTt(htx)]1γt\rho_t^\star(h_t \mid x) \propto \left[ d_{\theta_{\mathrm{old}}}^t(h_t \mid x) \right]^{\gamma_t} \left[ d_T^t(h_t \mid x) \right]^{1 - \gamma_t}
The geometric bridge ρt(htx)\rho_t^\star(h_t \mid x) takes the exponential weighted product of the student and teacher occupancies at history hth_t, normalized by the bridge parameter γt=λstu,tλstu,t+λtea,t[0,1]\gamma_t = \frac{\lambda_{\mathrm{stu},t}}{\lambda_{\mathrm{stu},t} + \lambda_{\mathrm{tea},t}} \in [0, 1].

The parameter γt=λstu,tλstu,t+λtea,t\gamma_t = \frac{\lambda_{\mathrm{stu},t}}{\lambda_{\mathrm{stu},t} + \lambda_{\mathrm{tea},t}} operates as a continuous trade-off weight bridge interpolation weight . Setting γt=1\gamma_t = 1 recovers pure student-on-policy roll-in, maximizing relevance at the expense of teacher reliability. Setting γt=0\gamma_t = 0 collapses the bridge to teacher-forced roll-in, guaranteeing reliable targets while ignoring student drift. Intermediate values γt(0,1)\gamma_t \in (0, 1) select prefixes hth_t that are both reachable by the student's current interpreter actions and anchored within the teacher's reliable domain. Crucially, the optimal balance shifts across trajectory steps tt: at early steps, student and teacher occupancies heavily overlap (γt1\gamma_t \to 1), whereas deep in a multi-turn reasoning trajectory, compounding errors degrade teacher reliability, pulling the optimal weight toward teacher support (γt0\gamma_t \to 0) .

Geometric bridge density as a function of occupancy ratio

Increasing γt\gamma_t shifts training density toward student-favored histories, while decreasing γt\gamma_t anchors density in teacher-supported regions.

Geometric bridge density as a function of occupancy ratio: live curves controlled by Bridge weight gamma t-3.48-1.7401.743.48-3-1.501.53
Relative log-density log(ρt/dTt)\log(\rho_t^\star / d_T^t)Log-occupancy ratio log(dstu/dtea)\log(d_{\mathrm{stu}} / d_{\mathrm{tea}})
Relative log-density log(ρt/dTt)\log(\rho_t^\star / d_T^t)

This model isolates the geometric interpolation logρt(ht)logdTt(ht)=γt(logdθoldt(ht)logdTt(ht))\log \rho_t^\star(h_t) - \log d_T^t(h_t) = \gamma_t \left(\log d_{\theta_{\mathrm{old}}}^t(h_t) - \log d_T^t(h_t)\right) at step tt holding all other history variables fixed.

Instantiating this optimal geometric bridge directly requires evaluating density ratios between student and teacher occupancies across multi-turn trajectories . However, exact density ratios across long sequences incur high variance, making direct sample reweighting unstable over extended horizons.

Step-decay sampling schedule

How does a position-dependent step decay κt\kappa^t approximate the exact geometric bridge weight?

When an LLM agent executes Python code across multiple interaction turns to solve a math problem, estimating the exact geometric bridge weight at step tt requires knowing how likely the student would have reached that specific execution history. Evaluating the exact density ratio between student and teacher history occupancies requires computing the cumulative likelihood ratio along the replayed teacher prefix. Because both policies evaluate on the identical teacher-recorded prefix ht=(O1,A1,,Ot)h_t = (O_1, A_1, \dots, O_t), environment observation probabilities cancel out completely, leaving the per-history prefix likelihood ratio :

r^t(x,ht)=s<tπθold(asx,hs)πT(asx,hs)\widehat{r}_t(x,h_t) = \prod_{s<t} \frac{\pi_{\theta_{\mathrm{old}}}(a_s \mid x, h_s)}{\pi_T(a_s \mid x, h_s)}
The exact per-history likelihood ratio is the product of student-to-teacher action probabilities along the replayed teacher prefix.

Evaluating this ratio reveals a severe practical flaw. Because every historical action asa_s was chosen by the teacher, the student policy πθold\pi_{\theta_{\mathrm{old}}} assigns it a lower probability than the teacher πT\pi_T does, causing r^t(x,ht)\widehat{r}_t(x,h_t) to decay exponentially toward zero as execution traces extend . Estimating the exact normalized bridge weight wt(x,ht)r^t(x,ht)γtw_t(x,h_t) \propto \widehat{r}_t(x,h_t)^{\gamma_t} creates extreme variance across individual trajectories, making loss gradients unstable .

However, empirical measurements show that the step index tt accounts for almost all variation in r^t\widehat{r}_t, so approximating the log-ratio by the average per-step KL divergence gives logr^t(t1)cˉ\log \widehat{r}_t \approx -(t-1)\bar{c}, where cˉ=EasπT[log(πT/πθold)]0\bar{c} = \mathbb{E}_{a_s \sim \pi_T}[\log(\pi_T / \pi_{\theta_{\mathrm{old}}})] \ge 0 . Exponentiating this approximation connects the bridge parameter γt\gamma_t directly to the step-decay base :

This mapping replaces noisy per-history density ratios with a clean position-dependent schedule ω(t;κ)=κt\omega(t; \kappa) = \kappa^t, whose normalization across the trajectory horizon yields step sampling probabilities ptκtp_t \propto \kappa^t. Instead of evaluating every position and multiplying losses by volatile weights, the training pipeline simply draws interaction step tt with probability ptp_t from the offline trajectory pool and applies unweighted distillation on the student's generated action. Early code execution steps—where student prefix drift is minimal—are sampled frequently, whereas late high-shift steps are sampled exponentially less. This concentrates supervision on low-shift prefixes where teacher conditionals are reliable while eliminating per-history likelihood ratio variance .

We must verify whether training off-environment with prefix decay preserves distillation accuracy without executing tool calls.

This mapping replaces noisy per-history density ratios with a clean position-dependent schedule ω(t;κ)=κt\omega(t; \kappa) = \kappa^t . Normalizing ω(t;κ)\omega(t; \kappa) across the trajectory horizon yields a step sampling probability ptκtp_t \propto \kappa^t . Instead of evaluating every position and multiplying losses by volatile weights, the training pipeline simply draws interaction step tt with probability ptp_t from the offline trajectory pool and applies unweighted distillation on the student's generated action . Early code execution steps—where the student's prefix drift is minimal—are sampled frequently, whereas late steps—where replayed prefixes become high-shift surrogates—are sampled exponentially less . This concentrates supervision on low-shift prefixes where teacher conditionals are reliable, while eliminating per-history likelihood ratio variance .

We must verify whether training off-environment with prefix decay preserves distillation accuracy without executing tool calls.

Off-environment prefix replay

How does ReOPD execute student step generation and teacher supervision without live tool execution?

When an LLM agent solves a mathematical reasoning problem across multiple interaction turns, executing Python code snippets at each step consumes significant compute and wall-clock time. In standard online on-policy distillation, the student policy student policy must evaluate its own action Atπθold(x,ht)A_t \sim \pi_{\theta_{\mathrm{old}}}(\cdot \mid x, h_t) on-policy at step tt. To obtain the interaction history prefix hth_t, online distillation forces the student to execute live tool calls against the environment for every rollout. This creates a severe throughput bottleneck during student optimization. Can we provide genuinely on-policy training signals at step tt without executing a single live tool call?

A naive attempt to bypass live execution is pure off-policy teacher forcing—training the student solely to predict offline teacher tokens. But this fails to provide on-policy feedback: because the student never evaluates its own generated actions, it suffers from severe exposure bias when it branches off-trajectory during multi-turn inference.

ReOPD eliminates live environment calls while preserving on-policy evaluation by utilizing an offline teacher trajectory pool teacher trajectory pool. For a supervised step tt, the interaction prefix hth_t is replayed verbatim from a recorded teacher trace, including all previous teacher actions A<tA_{<t} and environment observations OtO_{\le t}. The student does not re-run Python code to reach step tt. Instead, it receives hth_t as a static context and autoregressively samples its own multi-token action AtA_t .

(πθ,πT;x,ht,At)=j=1ntDKL(πθ(x,ht,at<j)πT(x,ht,at<j))\ell(\pi_\theta, \pi_T; x, h_t, A_t) = \sum_{j=1}^{n_t} D_{\mathrm{KL}}\Big(\pi_\theta(\cdot \mid x, h_t, a_t^{<j}) \,\Vert\, \pi_T(\cdot \mid x, h_t, a_t^{<j})\Big)
The per-step loss (πθ,πT;x,ht,At)\ell(\pi_\theta, \pi_T; x, h_t, A_t) sums the KL divergence between the student policy πθ\pi_\theta and teacher policy πT\pi_T over each token jj in the student-sampled action AtA_t, conditioned on the student's prefix context at<ja_t^{<j}.

Supervision is computed per generated token along the student's action At=(at1,,atnt)A_t = (a_t^1, \dots, a_t^{n_t}). For each token position jj, the teacher policy teacher policy evaluates its target conditional πT(x,ht,at<j)\pi_T(\cdot \mid x, h_t, a_t^{<j}) using the student's own generated tokens at<ja_t^{<j} as context. Because the evaluated contexts at<ja_t^{<j} are sampled directly by the student, the distillation step is genuinely on-policy . Crucially, because hth_t is replayed verbatim from DT\mathcal{D}_T, no action is executed in the environment and no observation is generated .

This off-environment prefix replay achieves zero tool calls during student training, bypassing process memory constraints and code interpreter deployment bottlenecks. Consequently, ReOPD achieves at least a 4×4\times speedup in rollout throughput relative to standard online distillation .

While off-environment prefix replay removes the operational bottleneck of online tool calls, it relies entirely on replayed teacher traces. It remains to test whether ReOPD maintains reasoning accuracy across diverse environment domains and under varying teacher-student capability gaps.

Regime-aware distillation performance

Under what environment conditions does ReOPD outperform standard online on-policy distillation?

In a multi-turn mathematical reasoning problem with a Python code interpreter, an LLM agent executes code across TT interaction steps. When standard online on-policy distillation rolls out the student policy student policy in a live execution environment, early student mistakes steer interaction into uncalibrated states where the teacher policy teacher policy was never trained. At these drifted histories, teacher supervision fails because the teacher's conditional action distribution is an unreliable proxy for true solution progress. One might assume that executing live student rollouts is essential for effective on-policy learning; however, when the capability gap between teacher and student is wide, forcing student-on-policy roll-ins actively degrades distillation quality. ReOPD resolves this trap by keeping the roll-in anchored to replayed prefixes replayed interaction prefix from the offline teacher trajectory pool teacher trajectory pool, evaluating the student step action student step action on states where teacher targets remain trustworthy .

This structural distinction divides multi-turn distillation into two clear environment regimes . On complex mathematical reasoning tasks, where the teacher-student model gap is large, teacher reliability shift dominates. Evaluating a Qwen3-4B student under a Qwen3-4B teacher on Python-assisted math benchmarks, ReOPD achieves an average accuracy of 57.257.2, outperforming online OPD's 55.155.1. When scaling to a stronger Qwen3-8B teacher, ReOPD widens its advantage over online OPD (53.753.7 vs 51.051.0 average accuracy), precisely because teacher unreliability on drifted student rollouts becomes the primary performance bottleneck . Conversely, in search and question-answering environments where the teacher remains reliable on student-induced histories, student occupancy shift dominates . Here, ReOPD essentially matches online OPD (40.540.5 vs 40.640.6 average accuracy under a Qwen3-4B teacher) because teacher-anchored prefixes and student-induced histories nearly overlap .

ReOPD also scales seamlessly to multi-environment settings without added operational complexity. Training a single student agent across heterogeneous tool environments normally requires deploying live Python interpreters and search engines concurrently during every gradient update. By decoupling prefix collection from student optimization, ReOPD allows distinct domain teachers to build offline trajectory pools independently, which are then merged into a unified dataset for joint student training. On joint math and search benchmarks, a single student trained via ReOPD achieves 55.355.3 math average and 41.041.0 search average, matching online OPD while eliminating live environment hosting entirely . This resolves our central throughline: LLM agents can learn from dense on-policy distillation off-environment with zero live tool calls during student training, achieving at least a 4imes4 imes speedup per rollout without degrading reasoning accuracy .

Transfer set

Put the pieces together

These questions combine mechanisms from more than one section. Work from the causal chain before opening the answer.

  1. 01

    Suppose an engineer sets the step-decay parameter κ=1\kappa = 1 when training an agent on a T=10T=10 turn Python math reasoning task, resulting in a uniform sampling distribution pt=1/Tp_t = 1/T across steps. Combining the error bound from the two-sided prefix trap with the step-decay derivation, how does this choice affect the balance between student occupancy mismatch 2BTV(dθoldt,ρt)2B \mathrm{TV}(d_{\theta_{\mathrm{old}}}^t, \rho_t) and expected teacher unreliability Eρt[ϵT,tθ]\mathbb{E}_{\rho_t}[\epsilon_{T,t}^\theta] at late interaction steps (tTt \to T), and why does it degrade distillation performance?

    Show answer

    Setting κ=1\kappa = 1 forces a uniform sampling distribution pt=1/Tp_t = 1/T, sampling deep interaction steps (tTt \approx T) with equal probability as step 11. As derived from the per-history likelihood ratio r^t(x,ht)exp((t1)cˉ)\widehat{r}_t(x, h_t) \approx \exp(-(t-1)\bar{c}), the student-to-teacher density ratio decays exponentially with turn index tt. In terms of the geometric occupancy bridge ρt\rho_t^\star, assigning equal sampling weight at large tt corresponds to keeping γt\gamma_t artificially high rather than letting γt0\gamma_t \to 0 to anchor deep prefixes in teacher support dTtd_T^t. On multi-turn code execution trajectories, over-sampling late-step teacher prefixes without position decay forces the student to evaluate actions AtA_t on deep replayed prefixes where cumulative sequence drift is high. This fails to minimize the combined bound of total variation mismatch 2BTV(dθoldt,ρt)2B \mathrm{TV}(d_{\theta_{\mathrm{old}}}^t, \rho_t) and expected teacher unreliability Eρt[ϵT,tθ]\mathbb{E}_{\rho_t}[\epsilon_{T,t}^\theta], degrading distillation accuracy relative to the step-decay schedule ptκtp_t \propto \kappa^t.

  2. 02

    Consider a scenario where the student policy πθ\pi_\theta has already converged close to the teacher policy πT\pi_T such that the average per-step KL divergence cˉ0\bar{c} \to 0, but the multi-turn Python execution environment still suffers from high latency and tool server overhead. Combining the step-decay parameter mapping, off-environment prefix replay, and regime-aware performance mechanisms, what happens to the sampling schedule ptp_t, execution tool calls, and overall distillation throughput?

    Show answer

    When the student-teacher policy gap vanishes (cˉ0\bar{c} \to 0), the step-decay base κ=exp(γtcˉ)\kappa = \exp(-\gamma_t \bar{c}) approaches exp(0)=1\exp(0) = 1, making the step sampling distribution ptκtp_t \propto \kappa^t uniform across interaction turns tt. Because πθoldπT\pi_{\theta_{\mathrm{old}}} \approx \pi_T, student occupancy dθoldtd_{\theta_{\mathrm{old}}}^t matches teacher occupancy dTtd_T^t, dropping total variation occupancy mismatch TV(dθoldt,ρt)\mathrm{TV}(d_{\theta_{\mathrm{old}}}^t, \rho_t) and teacher unreliability ϵT,tθ\epsilon_{T,t}^\theta to near zero across all turns. Under off-environment prefix replay, the student generates step actions Atπθold(x,ht)A_t \sim \pi_{\theta_{\mathrm{old}}}(\cdot \mid x, h_t) directly on replayed teacher prefixes hth_t from the offline trajectory pool DT\mathcal{D}_T. Because all intermediate observations OtO_{\le t} are loaded directly from DT\mathcal{D}_T, the student optimization loop executes exactly zero live tool calls. This resolves our central throughline—how to perform on-policy distillation without live tool execution—by showing that replacing live rollouts with replayed teacher prefixes eliminates environment latency bottlenecks and speeds up rollout throughput by at least 4×4\times while preserving full reasoning performance.

References

  1. [1]
    Abstractabstract
    Fully online OPD is costly because each update requires fresh student rollouts through the environment and teacher queries at visited histories.
  2. [2]
    With an increasing number of environments, the operational complexity grows for OPD due to the heavy deployment of the environments.
  3. [3]
    Second, even when histories are relevant to the student, the teacher may be unreliable on histories far from its own interaction support.
  4. [4]
    Fully student-on-policy OPD (ρt=dθoldt\rho_t=d_{\theta_{\mathrm{old}}}^{t} for all tt) zeroes the occupancy term but not the reliability one: student-generated actions can steer the environment into histories unlikely under the teacher's own interaction process, especially at later steps where its conditional is a poorly calibrated target.
  5. [5]
    \mathcal R^\star(\theta;\theta_{\mathrm{old}})
  6. [6]
    When the supports overlap, the solution is the geometric bridge
  7. [7]
    \rho_t^\star \in \arg\min_{\rho_t}
  8. [8]
    \rho_t^\star(h_t\mid x) \propto
  9. [9]
    so the exact weight's depth profile is geometric:
  10. [10]
    \label{eq:exact-weight}
  11. [11]
    \label{eq:kappa-map}
  12. [12]
    For each supervised step tt, the prefix ht=(O1,A1,,Ot)h_t=(O_1,A_1,\dots,O_t) is replayed \emph{verbatim} from the teacher trace -- all earlier actions A<tA_{<t} and all observations OtO_{\le t} are the teacher's.
  13. [13]
    No action is ever executed against the environment and no observation is ever generated, so no environment is queried.
  14. [14]
    Unlike OPD, which must execute fresh environment rollouts and tool calls during every student update, ReOPD replays teacher-recorded prefixes and therefore uses zero tool calls during student training. This also translates into faster updates: ReOPD is at least 4×4\times faster per rollout than OPD.
  15. [15]
    the teacher-anchored pool wins when the gap is large and ties student-on-policy OPD when the teacher is already reliable
  16. [16]
    With a Qwen3-4B teacher and Qwen3-4B student, ReOPD improves the average from 55.155.1 to 57.257.2; with a Qwen3-8B teacher, it improves from 51.051.0 to 53.753.7
  17. [17]
    With a Qwen3-4B teacher, OPD and ReOPD obtain 40.640.6 and 40.540.5 average accuracy, respectively;
  18. [18]
    ReOPD remains on par with OPD in both domains while avoiding online environment interaction during student training.