alphaFeedback

WorksComputer Science

Nash-MOPD: Optimizing Task Trade-offs in Multi-Teacher On-Policy Distillation

AI contributions
Not recorded for this paper
View details

Abstract

Multi-teacher on-policy distillation (MOPD) aggregates the capabilities of multiple domain-expert teachers into a single student model. However, all domains in MOPD share the student's finite budget of optimization steps and rollouts. Fixed uses constant domain sampling ratios based on corpus sizes; by contrast, D3^3-MOPD adjusts the ratios using the teacher-student reverse-KL divergence and its recent decrease. However, favoring large recent decreases can direct more training toward domains that already improve quickly, while domains that improve more slowly may receive too few examples. To address inflexible allocation and the risk of giving insufficient training to domains that improve more slowly, we propose Nash-MOPD, an adaptive domain scheduler based on a local minimax game using existing reverse-KL statistics. The equilibrium maximizes the smallest predicted proportional reduction under the local model and gives more prompts to domains that need more examples for comparable improvement. Consequently, Nash-MOPD responds to changing learning progress and supports domains that improve more slowly without extra teacher queries or rollouts. At step 100, Nash-MOPD exceeds both baselines' final mathematics and code checkpoint scores on DeepSeek-R1-Distill-Qwen-1.5B and reaches Fixed's on Qwen3-8B-Base. Furthermore, it leads eight of nine reported metrics and is best or tied best on all six mathematics and code accuracy metrics, respectively.

Introduction

Multi-teacher on-policy distillation (MOPD) aggregates the capabilities of multiple domain-expert teachers into a single student model, which is widely used in frontier model post-training [15, 18] (Zeng et al. 2026; DeepSeek-AI et al. 2026). During training, the student generates rollouts from prompts sampled across domains. The corresponding teacher then provides token-level supervision at student-visited states, and the student is updated to minimize the reverse KL divergence from its next-token distribution to the teacher’s [19, 20]. However, all domains in MOPD share the student’s finite budget of optimization steps and rollouts. As a result, increasing one domain’s sampling ratio leaves fewer training examples for the others. MOPD therefore entails a multi-task trade-off, since the domain mixture must balance competing learning demands to develop diverse capabilities together. This allocation consequently shapes both convergence speed and the final accuracy achievable within the training budget.

Effective use of this shared budget requires accounting for differences in how the student learns across domains. As training proceeds, the student may learn some domains quickly while requiring more examples to learn others. Fixed uses constant domain sampling ratios based on corpus sizes, so it cannot adjust the allocation to these differences or their changes over time. By contrast, D3D^{3}-MOPD adjusts the ratios using the teacher–student reverse-KL divergence and its recent decrease (Sun et al., 2026). However, favoring large recent decreases can direct more training toward domains that already improve quickly, while domains that improve more slowly may receive too few examples. We therefore need an adaptive scheduler that responds to changes in the student’s learning progress and provides sufficient training for domains that improve more slowly, so as to improve both convergence speed and final accuracy under the same training budget.

To address inflexible allocation and the risk of giving insufficient training to domains that improve more slowly, we propose NASH-MOPD, an adaptive domain scheduler based on a local minimax game. At each allocation update, NASH-MOPD uses existing reverse-KL statistics to estimate how much of the remaining teacher–student difference each domain reduces per sampled prompt. It then solves a local minimax game in which the sampler chooses domain sampling ratios and the adversary selects the domain with the smallest predicted proportional reduction. The equilibrium maximizes this minimum progress under the local model and gives more prompts to domains that need more examples for comparable improvement. Sampling bounds preserve domain coverage, while smoothing keeps successive allocations stable. Consequently, NASH-MOPD responds to changing learning progress and supports domains that improve more slowly without extra teacher queries or rollouts. Moreover, this allocation has a clear interpretation, since each domain’s sampling ratio reflects its estimated remaining training demand under the local model.

Multi-teacher on-policy distillation and Nash-MOPD domain scheduling

Figure 1. Optimizing the multi-task trade-off with NASH-MOPD. Frozen domain-expert teachers supervise student rollouts; exposure-normalized progress estimates guide prompt allocation across domains.

To evaluate the effectiveness of NASH-MOPD, we conduct experiments with DeepSeek-R1-Distill-Qwen-1.5B across mathematics, code, and instruction following, and with Qwen3-8B-Base across mathematics and code. All methods use the same training pipeline and budget. On the DeepSeek-R1-Distill-Qwen-1.5B student, NASH-MOPD exceeds both baselines’ final mathematics and code checkpoint scores at step 100. On the Qwen3-8B-Base student, it reaches Fixed’s final mathematics and code performance at step 100, using 60 and 80 fewer optimization steps than Fixed and the original D3^{3}-MOPD baseline described in § 5, respectively. Furthermore, NASH-MOPD leads eight of nine reported metrics on the DeepSeek-R1-Distill-Qwen-1.5B student and is best or tied best on all six mathematics and code accuracy metrics on the Qwen3-8B-Base student. These results demonstrate that NASH-MOPD outperforms both baselines in convergence speed and overall final accuracy across domains.

Related Work

On-policy distillation and capability integration. Reverse-KL and generalized knowledge distillation supervise students on their own responses ([8, 1]). MOPD extends this to multiple teachers, routing rollouts to the corresponding domain teacher ([19]). We preserve its token-level supervision and adapt the probability of choosing each prompt domain.

Adaptive mixtures and multitask optimization. GradNorm and related approaches adapt task weights from gradient magnitude, loss evolution, or validation behavior ([4, 10] (Sundararaman et al. 2021)). DoReMi optimizes domain weights using a proxy-model objective ((Xie et al., 2023)). D3^{3}-MOPD is the closest setting: it repurposes per-domain reverse-KL to adjust the domain mixture ((Sun et al., 2026)). Its composite signal combines remaining gap and descent velocity; our inverse-rate rule estimates exposure needed for completion. Our original D3^{3}-MOPD baseline follows the published domain scheduling rule for allocating prompts across domains.

Games, fairness, and online feedback. Pareto multitask methods and Nash bargaining combine task gradients ((Sener and Koltun, 2018; Navon et al., 2022)). Nash learning from human feedback uses a zero-sum preference game ((Munos et al., 2024)). Here the adversary selects a domain bottleneck and the learner controls domain sampling ratios, so the players and payoff differ. GiGPO uses repeated states across existing trajectories to obtain finer credit signals for agent training ([6]); our controller similarly consumes observations already produced by training, but acts at the domain-mixture level. Neither gradient bargaining nor trajectory credit assignment directly supplies the exposure-based completion objective considered here.

Preliminaries

MOPD Framework

For each of KK domains, let Dk\mathcal{D}_k be its prompt distribution, πTk\pi_{T_k} its frozen domain-expert teacher, and πθ\pi_\theta the shared student. Domain sampling ratios p∈ΔKp \in\Delta_K satisfy pk≥0p_k \ge0 and ∑kpk=1\sum_k p_k = 1. A batch of BB prompts assigns approximately BpkBp_k examples to domain kk; ek(t)e_k(t) counts cumulative prompt presentations, including repeated sampling.

MOPD extends on-policy distillation to multiple teachers ([19]). It samples k∼pk \sim p, x∼Dkx \sim\mathcal{D}_k, and a student response y∼πθ(⋅∣x)y \sim\pi_\theta(\cdot\mid x). At each student-visited state st=(x,y<t)s_t = (x, y_{<t}), the corresponding teacher supervises the student’s next-token distribution through reverse-KL ([8, 1]):

dk,t(θ)=DKL(πθ(⋅∣st)∥πTk(⋅∣st)).d_{k,t}(\theta) = D_{\mathrm{KL}}\left(\pi_\theta(\cdot\mid s_t)\mathbin{\|}\pi_{T_k}(\cdot\mid s_t)\right).

For domain labels kik_i and non-padding response lengths NiN_i, the batch objective is

LOPD(θ)=∑i=1B∑t=1Nidki,t(θ)∑i=1BNi.(1)\mathcal{L}_{\mathrm{OPD}}(\theta) = \frac{\sum_{i=1}^{B}\sum_{t=1}^{N_i} d_{k_i,t}(\theta)}{\sum_{i=1}^{B} N_i}. \tag*{(1)}

Each divergence is evaluated on prompt ii’s rollout, which is held fixed during the update. Eq. (1) averages tokens; prompt shares need not equal token-loss shares. Scheduling changes the prompt mixture, not teacher routing or loss weights.

Domain Allocation Variants

With nkn_k usable training rows, Fixed retains

pkFixed=nk∑jnj.(2)p_k^{\mathrm{Fixed}} = \frac{n_k}{\sum_j n_j}. \tag*{(2)}

These corpus-based ratios cannot respond to changing learning progress.

D3D^3-MOPD adjusts ratios using normalized remaining reverse-KL Lˉk\bar{L}_k and nonnegative descent velocity vkv_k, the recent relative KL decrease ((Sun et al., 2026)). With temperature T>0T > 0, the original method proposes

ck=Lˉkvk,zk=ck/max⁡jcj,c_k = \bar{L}_k v_k,\qquad z_k = c_k / \max_j c_j,
p~kD3=exp⁡(zk/T)∑jexp⁡(zj/T).(3)\widetilde{p}_k^{D^3} = \frac{\exp(z_k/T)}{\sum_j \exp(z_j/T)}. \tag*{(3)}

If all ck=0c_k = 0, the proposal is uniform; floors and caps preserve coverage. This adapts to progress, but favoring large recent decreases may undersample slowly improving domains. We use the original D3D^3-MOPD method; Appendix § 8.§ 2 gives implementation details for its domain scheduling.

Method

To address inflexible allocation and insufficient training for domains that improve more slowly, Nash-MOPD solves a local minimax game using existing reverse-KL statistics. The equilibrium gives more prompts to domains that need more examples for comparable improvement. The controller maximizes the smallest predicted proportional reduction to support bottleneck domains. Online updates adapt to changing progress, while sampling ratios reflect each domain’s remaining training demand under the local model. Bounds and smoothing preserve domain coverage and stable allocations without extra teacher queries or rollouts. Algorithm 1 gives the complete training loop.

Exposure-Normalized Progress Signals

For each domain, the observed signal is mean per-token reverse-KL over non-padding student response tokens. We clip negative empirical estimates to zero and maintain an exponential moving average Lk(t)L_k(t) with coefficient 0.20.2, initialized from the first valid observation. The reference scale Lk(0)L_k^{(0)} is the mean of the first five raw nonnegative observations, floored at 10−810^{-8}. With target ratio ρ=0.10\rho= 0.10, the normalized remaining gap is

gk(t)=[Lk(t)−ρLk(0)(1−ρ)Lk(0)]+.(4)g_k(t) = \left[\frac{L_k(t) - \rho L_k^{(0)}}{(1-\rho)L_k^{(0)}}\right]_+. \tag*{(4)}

This normalization accounts for differences in initial reverse-KL scales. Gaps may exceed one when

Algorithm 1 NASH-MOPD: online domain scheduling
Require: Domain pools $\{D_k\}$, frozen teachers $\{\pi_{T_k}\}$, student $\pi_\theta$; batch size $B$; $S$ updates
Require: Sampling bounds $(\ell, u)$; warm-up $w$; scheduling interval $h$; smoothing $\alpha$; jitter $\gamma$
1: Initialize $p$ from usable-row proportions and $s_{\mathrm{last}} \gets 0$
2: Initialize pool permutations/cursors, prompt exposures, reference KL scales, and EMA/gap histories
3: for $s = 1, \ldots, S$ do
4: Draw $\eta_k \sim U[-\gamma,\gamma]$; set $\tilde{p}_k \gets p_k(1+\eta_k)/\sum_j p_j(1+\eta_j)$
5: $b \gets \operatorname{LARGESTREMAINDER}(B\tilde{p})$; draw $b_k$ prompts per domain, reshuffling exhausted pools
6: Shuffle the batch; generate student rollouts and query $\pi_{T_k}$ at each domain-$k$ prefix
7: Compute the token-mean reverse-KL loss $\mathcal{L}_{\mathrm{OPD}}$; update exposures and KL statistics
8: Estimate remaining gaps $g_k$ and absorption rates $\hat{r}_k$ using {xref}`Eqs. (4)–(5)`
9: if statistics are ready, $s \ge w$, and $s-s_{\mathrm{last}} \ge h$ then
10: $\mathcal{A} \gets \{k : g_k > 10^{-3}, \hat{r}_k > 10^{-8}, \hat{r}_k\text{ is finite}\}$
11: Solve {xref}`Eq. (9)` for $p^*$ with the coverage fallbacks in {xref}`Section 4.3`
12: $p \gets \Pi_{\mathcal{P}}((1-\alpha)p+\alpha p^*)$; $s_{\mathrm{last}} \gets s$
13: end if
14: Update $\theta$ using $\mathcal{L}_{\mathrm{OPD}}$; save controller, sampler, and random states for recovery
15: end for
16: return Student checkpoints and domain-scheduling traces

divergence increases; zero indicates the KL target, not benchmark success. After the fifth observation, the gap history starts at one. We retain up to 11 exposure–gap pairs and use the oldest and newest records [t0,t1][t_0,t_1], spanning up to ten observed updates, to estimate

a^k(t)=[gk(t0)−gk(t1)]+max⁡(ek(t1)−ek(t0),1)(5)\widehat{a}_k(t)=\frac{[g_k(t_0)-g_k(t_1)]_+}{\max(e_k(t_1)-e_k(t_0),1)} \tag*{(5)}
r^k(t)=a^k(t)max⁡(gk(t1),10−3).\widehat{r}_k(t)=\frac{\widehat{a}_k(t)}{\max(g_k(t_1),10^{-3})}.

Here a^k\widehat{a}_k measures gap reduction per prompt, and r^k\widehat{r}_k is the exposure-normalized absorption rate, or proportional reduction per prompt. Dividing by exposure separates progress due to receiving more prompts from progress per prompt; a zero estimate means no positive decrease was measured in the window. These statistics are collected from observations already available during ordinary distillation, without extra teacher queries or rollouts.

Local Minimax Allocation

At one allocation update, fix positive gaps gkg_k and finite positive per-prompt reductions aka_k; let rk=ak/gkr_k=a_k/g_k. The separable local model predicts gk+≈gk−Bpkakg_k^+ \approx g_k-Bp_ka_k, with proportional reduction BpkrkBp_kr_k. If these rates remained fixed, the predicted number of updates needed to close every gap would be

Tloc(p)=max⁡kgkBpkak=1Bmin⁡kpkrk.(6)T_{\mathrm{loc}}(p)=\max_k\frac{g_k}{Bp_ka_k}=\frac{1}{B\min_k p_kr_k}. \tag*{(6)}

Minimizing Eq. (6) is thus equivalent to maximizing the smallest predicted proportional reduction. The sampler chooses pp, while an adversary q∈ΔKq\in\Delta_K selects a bottleneck domain:

u(p,q)=∑kqkpkrk,max⁡p∈ΔKmin⁡q∈ΔKu(p,q).(7)u(p,q)=\sum_k q_kp_kr_k,\qquad\max_{p\in\Delta_K}\min_{q\in\Delta_K}u(p,q). \tag*{(7)}

In Eq. (7), minimizing over qq for fixed pp gives min⁡kpkrk\min_k p_kr_k. With no binding sampling bounds, the unique maximizing allocation is

pk∗=rk−1∑jrj−1=gk/ak∑jgj/aj.(8)p_k^*=\frac{r_k^{-1}}{\sum_j r_j^{-1}}=\frac{g_k/a_k}{\sum_j g_j/a_j}. \tag*{(8)}

To see why, an allocation with minimum payoff mm must satisfy pk≥m/rkp_k\ge m/r_k. Summing yields m≤(∑krk−1)−1m\le\left(\sum_k r_k^{-1}\right)^{-1}; Eq. (8) attains equality for every domain. The equilibrium therefore assigns prompts in proportion to estimated remaining training demand gk/akg_k/a_k. A smaller positive rate requires more exposure to achieve comparable proportional improvement. This result concerns a frozen-rate local model, not guaranteed convergence of the nonlinear training trajectory. We re-estimate the rates online; Appendix A gives the saddle-point proof and bounded-allocation analysis.

The adversary serves to identify the current bottleneck, rather than introducing a trainable model. The controller computes the maximizing allocation directly from domain statistics. Scheduling therefore fits within the existing training loop, without alternating optimization between players.

Bounds, Smoothing, and Execution

Very small positive rates can produce extreme inverse-rate weights. We constrain base sampling ratios to P={p:∑kpk=1, ℓ≤pk≤u}\mathcal{P} = \{p : \sum_k p_k = 1,\ \ell\le p_k \le u\}, with ℓ=0.10\ell= 0.10 and u=0.70u = 0.70. Feasibility requires Kℓ≤1≤KuK\ell\le1 \le Ku. Let A\mathcal{A} contain domains with gk>10−3g_k > 10^{-3} and finite r^k>10−8\hat{r}_k > 10^{-8}. Inactive domains initially receive the floor ℓ\ell. On the active set, bisection selects a scalar vv such that

pk∗=clip⁡(v/r^k,ℓ,u),p_k^* = \operatorname{clip}(v/\hat{r}_k,\ell,u),
∑k∈Apk∗=1−∣Ac∣ℓ.(9)\sum_{k \in\mathcal{A}} p_k^* = 1 - |\mathcal{A}^{c}|\ell. \tag*{(9)}

This maximizes the smallest active-domain payoff under the bounds; it does not assign a positive modeled progress guarantee to zero-rate domains. If active caps leave probability unallocated, active shares are set to uu and the remainder goes to inactive domains. If none is active, the target is uniform. Training starts with Fixed’s row-proportional ratios (Eq. (2)). Observations accumulate during a 20-update warm-up; scheduling starts only when all domains have reference scales and at least two history records. Every ten updates, we smooth the target with α=0.25\alpha= 0.25 and project onto P\mathcal{P}:

pt=ΠP((1−α)pt−1+αpt∗).(10)p_t = \Pi_{\mathcal{P}}\left((1-\alpha)p_{t-1}+\alpha p_t^*\right). \tag*{(10)}

The base mixture preserves domain coverage, while smoothing tempers abrupt reallocations. Each batch applies multiplicative jitter in [0.7,1.3][0.7, 1.3], renormalizes, and uses largest-remainder rounding for BB prompt quotas. All schedules share the permutation sampler. Bounds apply to post-warm-up base ratios; jitter and rounding can change realized fractions. KL observations precede the optimizer update, and revised ratios control subsequent batches. Appendix B.1 gives sampler and checkpoint recovery details for resuming training.

Measuring joint convergence. Controller feedback uses reverse-KL; joint target attainment uses held-out domain scores Sk,tS_{k,t} and thresholds τk\tau_k. For the measured checkpoint set C\mathcal{C}, the first checkpoint meeting all domain targets is

tfirst=min⁡{t∈C:Sk,t≥τk for all k}.t_{\mathrm{first}} = \min\{t \in\mathcal{C} : S_{k,t} \ge\tau_k\ \text{for all } k\}.

The first sustained crossing additionally requires every later measured checkpoint through the endpoint to satisfy all thresholds. We report both alongside endpoint accuracy.

Experiments

Experimental Setup

Models and training data. DeepSeek-R1-Distill-Qwen-1.5B Guo et al., [9] trains on DAPO mathematics Yu et al., 2025, TACO code Li et al., [16], and Multi-IF conversations He et al., [12]. Its teachers are JustRL-DeepSeek-1.5B He et al., [11], DeepCoder-1.5B-Preview, and UltraData-IF-1.5B Fu et al., [7], respectively. The Multi-IF training split excludes 256 held-out conversations. Qwen3-8B-Base Yang et al., 2025 uses the same math and code corpora. Its teachers are two Qwen3-8B-Base versions trained via reinforcement learning on math and code, respectively. This tests allocation across scales and domain counts.

Baselines and training steps. We compare Fixed, the original D3^3-MOPD baseline, and NASH-MOPD through step 200, evaluating checkpoints every 20 optimizer updates. Final benchmark scores use the step-200 checkpoint. Fixed retains row-proportional base ratios throughout training. D3^3-MOPD combines normalized reverse-KL with descent velocity. Its original scheduling procedure is specified in Appendix B.2. NASH-MOPD uses the controller in § 4. The baselines differ in allocation, not in the distillation objective. Their common training configuration is listed in Appendix B.3. The shared budget isolates allocation effects.

Benchmarks and metrics. Endpoint accuracy is avg@4 on MATH-500 Hendrycks et al., [13], LiveCodeBench v6, or LCB, Jain et al., [14], HumanEval+, and MBPP+ Liu et al., [17], and avg@16 on AIME25 and AMC23. avg@kk averages correctness over kk candidates per question, whereas pass@kk measures the fraction of questions solved by at least one of those candidates. We report both. Instruction following uses Multi-IF’s three-turn score and IFBench’s loose and strict prompt accuracy Pyatkin et al., 2025. Checkpoint curves use MATH-500 and LCB pass@1, with Multi-IF additionally included in the three-domain experiment. This separates average accuracy from candidate coverage.

Endpoint Accuracy

Tables 1 and 2 report endpoint accuracy. NASH-MOPD leads eight of nine individual benchmark metrics on the DeepSeek-R1-Distill-Qwen-1.5B student and is best or tied best on all six on the

MethodMATH avg@4AIME avg@16AMC avg@16MeanLCB avg@4HE+ avg@4MB+ avg@4MeanMulti-IF scoreIF-L scoreIF-S scoreMean
Initial student76.8518.9665.7853.8616.5761.1351.5243.0729.5915.0010.3318.31
Fixed83.0526.0479.6962.9321.5768.1456.6848.8040.2516.6712.3323.08
D³-MOPD83.2526.0479.0662.7819.2966.3157.0147.5441.5418.0013.6724.40
NASH-MOPD85.9527.5078.9164.1223.2968.7557.4749.8443.0120.0014.6725.89

Table 1. Benchmark scores in %. D³-MOPD denotes the original method described in the experimental setup. MATH, AIME, AMC, and LCB denote MATH-500, AIME25, AMC23, and LiveCodeBench v6. HE+ and MB+ denote HumanEval+ and MBPP+. IF-L and IF-S denote IFBench loose and strict scores. Mean is the unweighted mean of the three displayed metrics within each domain. Bold marks the best method, including ties.

MethodMATH avg@4AIME avg@16AMC avg@16MeanLCB avg@4HE+ avg@4MB+ avg@4Mean
Initial student64.259.3855.0042.8816.5769.8243.3943.26
Fixed86.7022.7178.2862.5626.8683.0860.1956.71
D³-MOPD87.4021.6779.8462.9727.4382.6261.9757.34
NASH-MOPD87.4023.1380.1663.5628.5783.2362.3758.06

Table 2. Benchmark scores in %. MATH, AIME, AMC, and LCB denote MATH-500, AIME25, AMC23, and LiveCodeBench v6. HE+ and MB+ denote HumanEval+ and MBPP+. Mean is the unweighted mean of the three displayed metrics within each domain. Bold marks the best method, including ties.

Qwen3-8B-Base student. Domain means are reported separately from these counts.

Three-domain experiment. On the DeepSeek-R1-Distill-Qwen-1.5B student, NASH-MOPD scores 85.95% on MATH-500 avg@4, 23.29% on LCB avg@4, and 43.01% on Multi-IF. These exceed Fixed by 2.90, 1.72, and 2.76 percentage points, and D³-MOPD by 2.70, 4.00, and 1.47 points, respectively. Fixed has the highest AMC23 avg@16 score at 79.69%, compared with 78.91% for NASH-MOPD. Relative to the initial student’s 76.85% and the math teacher’s 86.10% MATH-500 avg@4 scores, NASH-MOPD achieves a gap recovery ratio of 98.4% Fu et al., [7], relative to the 9.25-point initial teacher–student performance gap, compared with 67.0% for Fixed. The remaining math gap is only 0.15 points, versus 3.05 points for Fixed at the final checkpoint.

Two-domain experiment. On the Qwen3-8B-Base student, NASH-MOPD scores 87.40% on MATH-500 avg@4 and 28.57% on LCB avg@4, exceeding Fixed by 0.70 and 1.71 points. It ties D³-MOPD on MATH-500 and exceeds its LCB score by 1.14 points. Mathematics and code means reach 63.56% and 58.06%, exceeding Fixed by 1.00 and 1.35 points, respectively. Both means also exceed D³-MOPD’s by 0.59 and 0.72 points, so the larger code improvement is accompanied by a gain in mathematics on the larger base student.

Convergence Speed

We measure convergence speed by the optimizer updates needed to match baseline endpoint mathematics and code performance. Figure 2 and Figure 3 report domain-score totals and checkpoint curves at 20-step intervals. Math and code use pass @1, whereas the endpoint tables use multi-candidate average accuracy.

Held-out domain-score totals for DeepSeek-R1-Distill-Qwen-1.5B and Qwen3-8B-Base

Figure 2. Held-out domain-score totals for DeepSeek-R1-Distill-Qwen-1.5B (left: math, code, and Multi-IF) and Qwen3-8B-Base (right: math and code). Math/code use pass@1. Totals are compared within each student.

Checkpoint scores for DeepSeek-R1-Distill-Qwen-1.5B and Qwen3-8B-Base

Figure 3. Checkpoint scores for DeepSeek-R1-Distill-Qwen-1.5B (top) and Qwen3-8B-Base (bottom). Dashed lines mark teacher-referenced targets (top) and Fixed’s final math/code scores (bottom).

Three-domain experiment. On the DeepSeek-R1-Distill-Qwen-1.5B student, NASH-MOPD’s step-100 math/code scores of 84.80/22.29% already exceed Fixed’s step-200 scores of 83.40/21.71% and D³-MOPD’s 83.40/18.86%. It therefore surpasses both baselines’ final mathematics and code performance with half the training updates. It also reaches all three teacher-referenced targets of 84.3/19.3/39.1% on math/code/Multi-IF @page 6/22 starts_mid=0 ends_mid=1

MethodMATH avg@4AIME avg@16AMC avg@16MeanLCB avg@4HE+ avg@4MB+ avg@4MeanMulti-IF scoreIF-L scoreIF-S scoreMean
Initial student76.8518.9665.7853.8616.5761.1351.5243.0729.5915.0010.3318.31
Fixed83.0526.0479.6962.9321.5768.1456.6848.8040.2516.6712.3323.08
D³-MOPD83.2526.0479.0662.7819.2966.3157.0147.5441.5418.0013.6724.40
NASH-MOPD85.9527.5078.9164.1223.2968.7557.4749.8443.0120.0014.6725.89

Table 1 (PDF p. 6). Benchmark scores in %. D³-MOPD denotes the original method described in the experimental setup. MATH, AIME, AMC, and LCB denote MATH-500, AIME25, AMC23, and LiveCodeBench v6. HE+ and MB+ denote HumanEval+ and MBPP+. IF-L and IF-S denote IFBench loose and strict scores. Mean is the unweighted mean of the three displayed metrics within each domain. Bold marks the best method, including ties.

MethodMATH avg@4AIME avg@16AMC avg@16MeanLCB avg@4HE+ avg@4MB+ avg@4Mean
Initial student64.259.3855.0042.8816.5769.8243.3943.26
Fixed86.7022.7178.2862.5626.8683.0860.1956.71
D³-MOPD87.4021.6779.8462.9727.4382.6261.9757.34
NASH-MOPD87.4023.1380.1663.5628.5783.2362.3758.06

Table 2 (PDF p. 6). Benchmark scores in %. MATH, AIME, AMC, and LCB denote MATH-500, AIME25, AMC23, and LiveCodeBench v6. HE+ and MB+ denote HumanEval+ and MBPP+. Mean is the unweighted mean of the three displayed metrics within each domain. Bold marks the best method, including ties.

Qwen3-8B-Base student. Domain means are reported separately from these counts.

Three-domain experiment. On the DeepSeek-R1-Distill-Qwen-1.5B student, NASH-MOPD scores 85.95% on MATH-500 avg@4, 23.29% on LCB avg@4, and 43.01% on Multi-IF. These exceed Fixed by 2.90, 1.72, and 2.76 percentage points, and D³-MOPD by 2.70, 4.00, and 1.47 points, respectively. Fixed has the highest AMC23 avg@16 score at 79.69%, compared with 78.91% for NASH-MOPD. Relative to the initial student’s 76.85% and the math teacher’s 86.10% MATH-500 avg@4 scores, NASH-MOPD achieves a gap recovery ratio of 98.4% Fu et al., [7], relative to the 9.25-point initial teacher–student performance gap, compared with 67.0% for Fixed. The remaining math gap is only 0.15 points, versus 3.05 points for Fixed at the final checkpoint.

Two-domain experiment. On the Qwen3-8B-Base student, NASH-MOPD scores 87.40% on MATH-500 avg@4 and 28.57% on LCB avg@4, exceeding Fixed by 0.70 and 1.71 points. It ties D³-MOPD on MATH-500 and exceeds its LCB score by 1.14 points. Mathematics and code means reach 63.56% and 58.06%, exceeding Fixed by 1.00 and 1.35 points, respectively. Both means also exceed D³-MOPD’s by 0.59 and 0.72 points, so the larger code improvement is accompanied by a gain in mathematics on the larger base student.

Convergence Speed

We measure convergence speed by the optimizer updates needed to match baseline endpoint mathematics and code performance. Figure 2 and Figure 3 report domain-score totals and checkpoint curves at 20-step intervals. Math and code use pass @1, whereas the endpoint tables use multi-candidate average accuracy.

Three-domain experiment. On the DeepSeek-R1-Distill-Qwen-1.5B student, NASH-MOPD’s step-100 math/code scores of 84.80/22.29% already exceed Fixed’s step-200 scores of 83.40/21.71% and D³-MOPD’s 83.40/18.86%. It therefore surpasses both baselines’ final mathematics and code performance with half the training updates. It also reaches all three teacher-referenced targets of 84.3/19.3/39.1% on math/code/Multi-IF at step 120, only 20 updates after exceeding the baseline math/code endpoints, and sustains them at later measured checkpoints. Neither baseline reaches all three targets within 200 optimization updates.

Two-domain experiment. On the Qwen3-8B-Base student, NASH-MOPD reaches Fixed’s final math/code scores of 86.40/26.86% at step 100, scoring 88.20/28.57%, with margins of 1.80 and 1.71 points above these thresholds. Fixed and D³-MOPD first reach the same reference level at steps 160 and 180, respectively. NASH-MOPD thus uses 60 and 80 fewer updates, reductions of 37.5% and 44.4%, and remains above both thresholds through step 200. Figure 2 also shows that NASH-MOPD has the highest domain-score totals from step 100 onward for both students.

Training cost. Figure 4 reports full 200-step training time. Fixed, D³-MOPD, and NASH-MOPD take 6.63/6.49/6.81 hours on the DeepSeek-R1-Distill-Qwen-1.5B student and

200-step training time for DeepSeek-R1-Distill-Qwen-1.5B and Qwen3-8B-Base

Figure 4. 200-step training time without held-out evaluation: DeepSeek-R1-Distill-Qwen-1.5B (solid) and Qwen3-8B-Base (hatched).

12.97/12.97/13.21 hours on the Qwen3-8B-Base student, respectively. These totals exceed Fixed’s by 0.18 and 0.24 hours or 2.7% and 1.9%, respectively. We measure convergence speed in optimizer updates. Wall-clock time to the earlier performance crossings was not measured.

Additional Benchmarks and Candidate Coverage

AIME25 and AMC23 use sixteen candidates per question. HumanEval+ and MBPP+ [3, 2, 17] use four. IFBench Pyatkin et al. (2025) reports loose and strict accuracy from one response per prompt.

Additional benchmark accuracy. For the DeepSeek-R1-Distill-Qwen-1.5B student, NASH-MOPD has the highest AIME25 avg@16 at 27.50%, HumanEval+ avg@4 at 68.75%, and MBPP+ avg@4 at 57.47%. Its IFBench loose and strict scores are 20.00% and 14.67%, exceeding Fixed by 3.33 and 2.34 points, roughly 20% relative gains under both scoring criteria. For the Qwen3-8B-Base student, NASH-MOPD leads AIME25 avg@16 at 23.13%, AMC23 avg@16 at 80.16%, HumanEval+ avg@4 at 83.23%, and MBPP+ avg@4 at 62.37%.

Coverage under multiple candidates. Table 3 reports pass@4 for MATH-500, LiveCodeBench v6, HumanEval+, and MBPP+, and pass@16 for AIME25 and AMC23. NASH-MOPD is best or tied best on all six coverage metrics for the DeepSeek-R1-Distill-Qwen-1.5B student and five of six for the Qwen3-8B-Base student. On the DeepSeek-R1-Distill-Qwen-1.5B student, NASH-MOPD’s AIME25 coverage reaches 53.33%, compared with 36.67% for Fixed, a gain of about 16.7 points. MATH-500 and LCB coverage rise to 93.60% and 25.14%. On the Qwen3-8B-Base student, NASH-MOPD leads AIME25 at 46.67%, AMC23 at 97.50%, LCB at 32.00%, and MBPP+ at 80.95%, and ties the best MATH-500 coverage at 94.00%. On HumanEval+ for the Qwen3-8B-Base student, D3D^{3}-MOPD has higher pass@4 coverage than NASH-MOPD at 92.07% versus 91.46%, despite lower avg@4 accuracy at 82.62% versus 83.23%. Here, NASH-MOPD’s 0.61-point average-accuracy gain coexists with a 0.61-point coverage shortfall, illustrating that the two metrics can rank methods differently.

MethodMathCode
MATH pass@4AIME pass@16AMC pass@16MeanLCB pass@4HE+ pass@4MB+ pass@4Mean
DeepSeek-R1-Distill-Qwen-1.5B
Initial student88.0043.3392.5074.6119.4378.6667.2055.10
Fixed92.8036.6795.0074.8224.0081.1067.7257.61
D³-MOPD91.4050.0095.0078.8021.7180.4970.1157.44
NASH-MOPD93.6053.3395.0080.6425.1482.3270.3759.28
Qwen3-8B-Base
Initial student86.6033.3387.5069.1419.4387.2075.4060.68
Fixed93.8043.3392.5076.5429.7190.2480.6966.88
D³-MOPD94.0036.6795.0075.2230.8692.0779.3767.43
NASH-MOPD94.0046.6797.5079.3932.0091.4680.9568.14

Table 3. pass@kk coverage in %. Benchmark abbreviations follow Tables 1 and 2. Mean averages the three benchmarks within each domain. Bold marks the best method within each student, including ties.

Conclusion

NASH-MOPD allocates prompts by maximizing the smallest predicted absorption rate of the remaining teacher–student reverse-KL gaps. Under a separable, frozen-rate progress model, the unconstrained equilibrium follows an inverse-rate rule. Online rate estimates, bounded shares, and smoothing implement this allocation during training. The DeepSeek-R1-Distill-Qwen-1.5B student reaches and sustains all three teacher-referenced targets from step 120, while the baselines remain short of the joint target through step 200. The Qwen3-8B-Base student reaches Fixed’s final math/code performance at step 100, requiring 37.5% and 44.4% fewer updates than Fixed and D3D^{3}-MOPD for first attainment. At the endpoint, NASH-MOPD leads eight of nine metrics on the DeepSeek-R1-Distill-Qwen-1.5B student and is best or tied best on all six metrics on the Qwen3-8B-Base student, with no extra teacher queries or rollouts.

Limitations

NASH-MOPD relies on local, separable progress estimates. Future work could model cross-domain transfer and forgetting, quantify rate uncertainty, and handle delayed feedback. Incorporating token counts and training time could improve resource allocation. Learning sampling bounds, update intervals, and smoothing could reduce manual tuning. More domains, model sizes, and training budgets would test these extensions.

Theory of the Allocation Game

Local surrogate and the zero-sum game

At one scheduler update, fix normalized gaps gk>0g_k > 0 and estimated per-prompt reductions ak>0a_k > 0 for the active domains. A batch of BB prompts with allocation p∈ΔKp \in\Delta_K predicts gap reduction BpkakBp_k a_k and fractional progress BpkrkBp_k r_k, where rk=ak/gkr_k = a_k/g_k. Ignoring truncation at the target, define the local time surrogate

Tloc(p)=max⁡k∈[K]1Bpkrk=1Bmin⁡kpkrk.(11)T_{\mathrm{loc}}(p) = \max_{k \in[K]} \frac{1}{Bp_k r_k} = \frac{1}{B \min_k p_k r_k}. \tag*{(11)}

This is a local planning quantity, not a guarantee for nonlinear training: student parameters, responses, losses, and rates can change after each update.

The sampler is the maximizing player and the adversary is a distribution q∈ΔKq \in\Delta_K over domains. Their zero-sum payoff is

u(p,q)=∑k=1Kqkpkrk.(12)u(p,q) = \sum_{k=1}^{K} q_k p_k r_k. \tag*{(12)}

For fixed pp, the adversary places all mass on an index attaining min⁡kpkrk\min_k p_k r_k, so min⁡q∈ΔKu(p,q)=min⁡kpkrk\min_{q \in\Delta_K} u(p,q) = \min_k p_k r_k. The sampler’s problem is the linear maximin program

ν∗=max⁡p∈ΔKmin⁡k∈[K]pkrk.(13)\nu^* = \max_{p \in\Delta_K} \min_{k \in[K]} p_k r_k. \tag*{(13)}

Theorem A.1 (Interior maximin solution). For a fixed active set and finite rates rk>0r_k > 0, with no active lower or upper share constraints, the unique maximizing allocation in Eq. (13) is

pk∗=rk−1∑j=1Krj−1,ν∗=(∑j=1Krj−1)−1.p_k^* = \frac{r_k^{-1}}{\sum_{j=1}^{K} r_j^{-1}}, \qquad\nu^* = \left(\sum_{j=1}^{K} r_j^{-1}\right)^{-1}.

The associated worst-domain local time is Tloc(p∗)=B−1∑jrj−1T_{\mathrm{loc}}(p^*) = B^{-1} \sum_j r_j^{-1}. The pair (p∗,q∗)(p^*,q^*), where qk∗=pk∗q_k^* = p_k^*, is a saddle point of Eq. (12).

Proof. Let pp be any feasible allocation and write m(p)=min⁡kpkrkm(p) = \min_k p_k r_k. Then pk≥m(p)/rkp_k \ge m(p)/r_k for every kk, so

1=∑kpk≥m(p)∑krk−1,1 = \sum_k p_k \ge m(p) \sum_k r_k^{-1},
m(p)≤(∑krk−1)−1.(14)m(p) \le\left(\sum_k r_k^{-1}\right)^{-1}. \tag*{(14)}

The proposed allocation sums to one and satisfies pk∗rk=(∑jrj−1)−1p_k^*r_k = \left(\sum_j r_j^{-1}\right)^{-1} for every domain, attaining this upper bound. Equality in Eq. (14) requires pk=m(p)/rkp_k = m(p)/r_k for every kk, which proves uniqueness. Substituting ν∗\nu^* into Eq. (11) gives the stated local time. For the saddle-point claim, pk∗rk=ν∗p_k^*r_k = \nu^* makes u(p∗,q)=ν∗u(p^*,q) = \nu^* for every qq. Also, since qk∗rk=ν∗q_k^*r_k = \nu^*, u(p,q∗)=ν∗u(p,q^*) = \nu^* for every pp. Thus neither player can improve its payoff by a unilateral change.

The minimum payoff requires fractional progress in every domain. Theorem A.1 therefore also minimizes worst-domain local time under frozen rates; the online controller re-estimates these rates after subsequent updates.

Bounded shares and water-filling

The implementation imposes a floor ℓ\ell and cap uu on domain sampling ratios. We assume Kℓ≤1≤KuK\ell\le1 \le Ku. Let A\mathcal{A} contain domains with a gap above the target threshold and a positive finite estimated rate; let I\mathcal{I} be the other domains. The code fixes pi=ℓp_i = \ell for i∈Ii \in\mathcal{I} and maximizes the worst rate over A\mathcal{A} using the remaining mass b=1−∣I∣ℓb = 1 - |\mathcal{I}|\ell. This convention is part of the controller: a zero-rate domain is not assigned a modeled positive payoff, so its share is a per-domain floor rather than a maximin guarantee.

For ∣A∣>0|\mathcal{A}| > 0, define

ϕ(v)=∑k∈Aclip⁡(vrk,ℓ,u).(15)\phi(v) = \sum_{k \in\mathcal{A}} \operatorname{clip}\left(\frac{v}{r_k},\ell,u\right). \tag*{(15)}

When b≤∣A∣ub \le|\mathcal{A}|u, the bisection in the implementation finds a level vv for which ϕ(v)=b\phi(v) = b (up to numerical tolerance), and sets the positive-rate shares to the clipped values in Eq. (15). If b>∣A∣ub > |\mathcal{A}|u, all positive-rate domains receive uu and the forced remainder is shared among inactive domains. The following result states what this construction does and, just as importantly, what its scalar vv does not mean when a cap binds.

Theorem A.2 (Optimality of the bounded allocation). Suppose ∣A∣>0|\mathcal{A}| > 0, rk>0r_k > 0 for all k∈Ak \in\mathcal{A}, and the floor/cap constraints are feasible. If b≤∣A∣ub \le|\mathcal{A}|u, any vector pk=clip⁡(v/rk,ℓ,u)p_k = \operatorname{clip}(v/r_k,\ell,u) satisfying ∑k∈Apk=b\sum_{k \in\mathcal{A}} p_k = b maximizes min⁡k∈Apkrk\min_{k \in\mathcal{A}} p_k r_k over ℓ≤pk≤u\ell\le p_k \le u with total mass bb. If b>∣A∣ub > |\mathcal{A}|u, setting pk=up_k = u for all k∈Ak \in\mathcal{A} maximizes the same objective; any feasible distribution of the remaining probability over I\mathcal{I} leaves that active-domain optimum unchanged. The maximizing allocation need not be unique.

Proof. Write m(p)=min⁡k∈Apkrkm(p) = \min_{k\in\mathcal{A}} p_k r_k. First consider a solution of Eq. (15). If an upper-clipped domain has payoff below vv, choose jj with the smallest payoff urju r_j among such domains. Every feasible allocation then has m(p)≤urjm(p) \le u r_j. The clipped vector assigns pj=up_j = u; every uncapped domain has payoff vv, every floor-clipped domain has payoff at least vv, and every other upper-clipped domain has payoff at least urju r_j. Its minimum therefore equals this upper bound, so no allocation can do better. If no upper-clipped domain has payoff below vv, all domain payoffs under the clipped vector are at least vv. Any allocation with minimum payoff strictly above vv must assign more than v/rkv/r_k to every domain with ℓ≤v/rk<u\ell\le v/r_k < u, including a domain exactly at its floor. Domains with v/rk<ℓv/r_k < \ell can remain at their floor and already have payoff above vv. If some domain has v/rk=uv/r_k = u, strict improvement is impossible for that domain because of its cap. Otherwise, when at least one domain needs a strict increase, the required total exceeds the clipped vector’s mass bb. If all domains have v/rk<ℓv/r_k < \ell, feasibility fixes every share at its floor. Thus no feasible vector has a larger minimum payoff. Finally, when b>∣A∣ub > |\mathcal{A}|u, every active coordinate is already at its maximum, so no feasible allocation can increase any positive-rate domain’s share; the minimum active payoff is therefore maximal. The inactive residual is feasible because Kℓ≤1≤KuK\ell\le1 \le Ku.

The bounded objective has the same domain-adversary interpretation: for fixed shares, minimizing the bilinear payoff over distributions on A\mathcal{A} selects an active bottleneck. The implementation needs only the maximizing allocation from Theorem A.2; it does not compute a dual distribution or alternate between game players.

The level vv equalizes payoffs only for interior coordinates. A capped domain can have payoff urk<vu r_k < v and become the bottleneck; plateaus of ϕ\phi can make vv non-unique. Hence vv should not be interpreted as an empirical Nash value when constraints bind.

For a feasible active budget, the scalar search is well-defined: ϕ\phi is continuous and nondecreasing, with ϕ(0)=∣A∣ℓ\phi(0) = |\mathcal{A}|\ell and ϕ(umax⁡k∈Ark)=∣A∣u\phi(u\max_{k\in\mathcal{A}} r_k) = |\mathcal{A}|u. The implementation uses 80 bisection iterations within this bracket. Share clipping and a final projection handle finite precision; the root level describes the bounded allocation, not a measured convergence rate.

Sensitivity to estimated positive rates

The controller uses window estimates r^k\hat r_k. The following result quantifies how a specified error changes its local planning objective. It compares the same active domain set and feasible share constraints; changes in which domains pass the positive-rate test are addressed separately in Section A.5.

Proposition A.3 (Deterministic rate sensitivity). Let A\mathcal{A} be a fixed nonempty active set and let P⊆ΔK\mathcal{P} \subseteq\Delta_K be a nonempty compact feasible allocation set with the controller’s coverage convention held fixed. Suppose rk,r^k>0r_k,\hat r_k > 0 and max⁡k∈A∣rk−r^k∣≤ϵ\max_{k\in\mathcal{A}} |r_k-\hat r_k| \le\epsilon. If p^\hat p maximizes min⁡k∈Ap^kr^k\min_{k\in\mathcal{A}} \hat p_k\hat r_k on P\mathcal{P}, then

min⁡k∈Ap^krk≥νA(r)−2ϵ,\min_{k\in\mathcal{A}} \hat p_k r_k \ge\nu_{\mathcal{A}}(r)-2\epsilon,
νA(r)=max⁡p∈Pmin⁡k∈Apkrk.\nu_{\mathcal{A}}(r)=\max_{p\in\mathcal{P}}\min_{k\in\mathcal{A}}p_k r_k.

Proof. For every feasible pp, 0≤pk≤10 \le p_k \le1 bounds the change in each active product by ϵ\epsilon. Taking the minimum preserves that bound, so ∣min⁡k∈Apkrk−min⁡k∈Apkr^k∣≤ϵ|\min_{k\in\mathcal{A}}p_k r_k-\min_{k\in\mathcal{A}}p_k\hat r_k| \le\epsilon. Maximizing over the same compact set also gives ∣νA(r)−νA(r^)∣≤ϵ|\nu_{\mathcal{A}}(r)-\nu_{\mathcal{A}}(\hat r)| \le\epsilon. The estimated optimizer therefore satisfies

min⁡k∈Ap^krk≥νA(r^)−ϵ≥νA(r)−2ϵ.\min_{k\in\mathcal{A}}\hat p_k r_k \ge\nu_{\mathcal{A}}(\hat r)-\epsilon\ge\nu_{\mathcal{A}}(r)-2\epsilon.

This result applies to the bounded target before temporal smoothing. It is conditional on a specified perturbation of the local rates. Our moving-window EMA estimator is temporally dependent, and the experiments do not supply a calibrated bound on ϵ\epsilon. Consequently the proposition explains sensitivity of the planning objective without assigning a confidence level or certifying progress for the reported training runs.

Smoothing, batch-level jitter, and finite batches

Let qtq_t be the bounded target, ptp_t the smoothed allocation, and α∈(0,1]\alpha\in(0,1] the smoothing coefficient. Convex combinations of feasible shares remain feasible, so Euclidean projection is a numerical safeguard after entry into the capped simplex. It also enforces bounds at the first dynamic update, since the instruction-following warm-up share is below 0.1. The lemma assumes a feasible initial allocation.

Lemma A.4 (Smoothing contraction and tracking). *For a fixed target qq, the update pt=ΠP((1−α)pt−1+αq)p_t = \Pi_{\mathcal{P}}((1-\alpha)p_{t-1}+\alpha q) satisfies ∥pt−q∥2≤(1−α)∥pt−1−q∥2\lVert p_t-q\rVert_2 \le(1-\alpha)\lVert p_{t-1}-q\rVert_2. If the targets vary with ∥qt−qt−1∥2≤ξ\lVert q_t-q_{t-1}\rVert_2 \le\xi and the update uses qtq_t, then

∥pt−qt∥2≤(1−α)∥pt−1−qt−1∥2+(1−α)ξ.\lVert p_t-q_t\rVert_2 \le(1-\alpha)\lVert p_{t-1}-q_{t-1}\rVert_2+(1-\alpha)\xi.

Consequently lim sup⁡t∥pt−qt∥2\limsup_t \lVert p_t-q_t\rVert_2 is at most (1−α)ξ/α(1-\alpha)\xi/\alpha when the stated variation bound holds.*

Proof. Euclidean projection onto a closed convex set is non-expansive and fixes qq. Therefore

∥pt−q∥2≤∥(1−α)pt−1+αq−q∥2,\lVert p_t-q\rVert_2 \le\lVert(1-\alpha)p_{t-1}+\alpha q-q\rVert_2,

which gives the contraction. For a varying target, compare the projected update with qtq_t and apply the triangle inequality:

∥pt−qt∥2≤(1−α)∥pt−1−qt∥2≤(1−α)∥pt−1−qt−1∥2+(1−α)ξ.\begin{aligned} \lVert p_t-q_t\rVert_2 &\le(1-\alpha)\lVert p_{t-1}-q_t\rVert_2\\ &\le(1-\alpha)\lVert p_{t-1}-q_{t-1}\rVert_2+(1-\alpha)\xi. \end{aligned}

Iterating this scalar recursion gives a geometric transient plus a geometric sum bounded by (1−α)ξ/α(1-\alpha)\xi/\alpha.

The lemma concerns the tracking of target shares. It supplies no contraction of the student’s KL gap or benchmark error. The runs use α=0.25\alpha=0.25; we do not estimate a stationary target-variation bound from their traces.

For one batch, the implementation multiplies each share pkp_k by 1+ηk1+\eta_k, with ∣ηk∣≤γ\lvert\eta_k\rvert\le\gamma, and renormalizes. Let p~\tilde p be this jittered distribution. Since

1−γ≤∑jpj(1+ηj)≤1+γ,1-\gamma\le\sum_j p_j(1+\eta_j)\le1+\gamma,
1−γ1+γpk≤p~k≤1+γ1−γpk.\frac{1-\gamma}{1+\gamma}p_k\le\tilde p_k\le\frac{1+\gamma}{1-\gamma}p_k.

For a batch of BB prompts, largest-remainder apportionment first assigns ⌊Bp~k⌋\lfloor B\tilde p_k\rfloor examples to each domain and then distributes the remaining prompts according to fractional remainders. If nkn_k is the resulting integer quota, then

∑knk=B,∣nkB−p~k∣<1B.\sum_k n_k=B,\qquad\left|\frac{n_k}{B}-\tilde p_k\right|<\frac{1}{B}.

The bound is deterministic and concerns batch composition only. It does not bound gradient noise or model quality. The random perturbations are sampled independently per batch. The sampler is shared by Fixed, D3^3-MOPD, and NASH-MOPD in both the DeepSeek-R1-Distill-Qwen-1.5B and Qwen3-8B-Base experiments.

Zero-rate domains and the scope of the guarantee

The bounded solver marks domain kk as progressing only if gk>10−3g_k>10^{-3}, r^k>10−8\hat r_k>10^{-8}, and its rate is finite. A domain outside this set receives its per-domain floor when a feasible positive-rate allocation can consume the remaining probability. If upper bounds prevent that allocation from consuming all mass, the residual is split equally over the other domains. When no domain passes the progressing-domain test, the target is uniform. These rules make every sampler update defined without dividing by zero.

They also change the scope of the optimization. If an unfinished domain has rk=0r_k=0, then min⁡kpkrk=0\min_k p_k r_k=0 for every feasible pp in the full-domain game, and its modeled completion time is infinite. No allocation can certify positive all-domain progress from those rates. The controller instead optimizes on the positive-rate subset while retaining exposure to the other domains. A zero estimate can represent a noisy window, a plateau, interference, or an inadequate teacher; the observations do not identify which explanation holds. In particular, allocating the minimum share to a zero-rate domain should not be interpreted as the best recovery policy for a stalled domain.

The diagonal local model additionally assumes that a domain’s improvement is attributable to its own prompt exposure. A shared student can improve one domain from another domain’s data or suffer negative transfer. The present analysis does not model those interactions, prove monotone KL descent, or establish a connection from KL descent to a benchmark threshold. The theoretical statements therefore concern allocation under specified local rates, whereas the results test whether that controller is useful in the observed nonlinear training system.

Implementation Details

This appendix complements Algorithm 1 with the controller state, comparator settings, and shared training settings.

State, observations, and update order

The controller stores a domain-specific random row permutation, cursor, prompt exposure count, initial KL scale, EMA, and recent histories. Each domain’s raw signal is recovered from the dense token-level distillation reward and aggregated over its non-padding response tokens. Negative raw estimates are clipped to zero before entering the EMA. The first valid observation initializes the EMA; later observations use coefficient 0.2. The initial scale is the mean of the first five raw observations, floored at 10−810^{-8}. At the fifth observation, the gap history is initialized at one; subsequent records use the normalized remaining gap from the main text. NASH-MOPD has no upper clipping of this gap.

A rolling history retains up to 11 exposure–gap pairs. Its oldest and newest entries provide a gap decrement over up to 10 observed updates. The nonnegative decrement divided by the exposure difference yields the estimated exposure-normalized descent velocity, and division by max⁡(gk,10−3)\max(g_k, 10^{-3}) gives the exposure-normalized absorption rate. The exposure denominator is floored at one. Rates and gap observations are updated throughout warm-up, but sampling shares change only once every domain has a scale and at least two history points. Dynamic updates begin at step 20 and occur at 10-step intervals. The logged post-update mixture controls subsequent batches; the current batch has already been sampled. The teacher signal in row ss is measured before optimizer update ss.

The sampler uses one random-number generator for row permutations, batch-level jitter, and within-batch ordering. It consumes each domain’s current row permutation before reshuffling that pool. Thus it permits repeated presentations across training while avoiding independent sampling with replacement at every draw within a cycle. Exposure counts measure prompt presentations, including repeats, rather than distinct training examples. Resume checkpoints retain the sampler’s random-number state, current permutations, cursors, yielded count, histories, EMA, scales, and last update. Resuming a trainer segment continues this state instead of restarting warm-up.

struction following and recomputes row proportions.

Bounded allocation and comparator details

Nash-MOPD solves for a clipped inverse-rate target by 80 bisection iterations over [0,umax⁡kr~k][0, u \max_k \tilde{r}_k], then normalizes its finite-precision result. It blends this target with the previous mixture using α=0.25\alpha= 0.25 and projects the result onto the capped simplex. The projection itself uses 80 bisection iterations. Share floors and caps apply to the controller’s base mixture after dynamic updates; the jittered probabilities and rounded batch fractions can exceed those nominal coordinate bounds. The DeepSeek-R1-Distill-Qwen-1.5B row-proportional warm-up also has an instruction-following base share below 0.1.

Each batch applies independent multiplicative jitter in [0.7,1.3][0.7, 1.3] to the scheduled shares and renormalizes them. Largest-remainder rounding converts the resulting probabilities into integer quotas summing to the global prompt batch size BB. Fixed and dynamic schedules use the same batch construction and random-permutation sampler.

The D3^{3}-MOPD comparator maintains an independent smoothed-KL history of up to 41 observations. Its remaining-gap signal is Lˉk=clip⁡(Lk/Lk(0),0,1.5)\bar{L}_k = \operatorname{clip}(L_k/L_k^{(0)}, 0, 1.5). The EMA and reference scale follow the initialization above. Descent velocity vkv_k averages the available 10-step differences from at most three windows, with previous KL floored at 0.15, and truncates negative descent to zero. Its composite signal multiplies the remaining-gap and descent-velocity signals, divides by their maximum, uses softmax temperature 0.5, adds the probability floor, and applies the same cap. If all signals vanish, it proposes a uniform target. It uses no additional temporal blend. This baseline uses the original D3^{3}-MOPD scheduling method, combining remaining gap and descent velocity to determine the domain sampling probabilities. Eq. (3) describes the proposal before the sampling floor and cap are applied. Both adaptive schedules retain the row-proportional base mixture during the shared warm-up and use the same batch-level jitter and integer-quota sampler; only Nash-MOPD uses the temporal blend in Eq. (10).

Fixed keeps the usable-row proportions throughout training. In the DeepSeek-R1-Distill-Qwen-1.5B experiment these proportions are approximately 38.2% math, 52.7% code, and 9.1% instruction following, computed from 17,917, 24,699, and 4,245 loaded rows. Qwen3-8B-Base removes instruction following and recomputes row proportions.

Shared training and decoding settings

Schedules within each experiment share initialization, teachers, data, AdamW settings, and a global batch of 64 with one student rollout per prompt. Training uses learning rate 10−610^{-6}, weight decay 0.01, up to 4,096 prompt tokens and 7,168 response tokens, on A100-SXM4-80GB GPUs. Held-out decoding uses temperature 0.6 and top-pp 0.95, except for IFBench. Table 4 collects the training and scheduling settings.

SettingValueApplied to
Global prompt batch / responses per prompt64 / 1All training runs
Maximum prompt / response tokens4,096 / 7,168All training runs
Student optimizer / learning rate / weight decayAdamW / 10−610^{-6} / 0.01All training runs
Training rollout / teacher temperature1.0 / 1.0All training runs
Loss aggregation / teacher precisionToken mean / bfloat16All training runs
KL scale observations / EMA coefficient5 / 0.2Domain-sampler controllers
KL target ratio / remaining-gap floor0.10 / 10−310^{-3}NASH-MOPD signals
Positive-rate cutoff10−810^{-8}NASH-MOPD allocation
Per-domain floor / cap0.10 / 0.70Dynamic post-warm-up mixtures
Warm-up / update interval20 / 10 stepsDynamic schedules
Rate-history window10 observationsNASH-MOPD rate estimation
Descent-velocity windows / KL denominator floorUp to 3×103 \times10 / 0.15D3^3-MOPD comparator
Softmax temperature / remaining-gap cap0.5 / 1.5D3^3-MOPD comparator
Mixture smoothing0.25NASH-MOPD only
Batch-level jitterUniform [−0.3-0.3, 0.3]Domain-sampler conditions
Scalar allocation / projection iterations80 / 80Bounded solver
Primary evaluation interval20 optimizer stepsMain scheduler comparisons
Primary evaluation temperature / top-pp0.6 / 0.95Shared held-out domains

Table 4. Training and scheduling settings for the reported studies.

Supplementary Results and Mechanism Analysis

Figure 5 compares training of the student model DeepSeek-R1-Distill-Qwen-1.5B over 200 optimizer steps, each representing one parameter update. The three domains are mathematics, code generation, and instruction following, which respectively involve solving mathematical problems, producing programs, and satisfying prompt requirements. Fixed samples domains in proportion to their training corpus sizes; D3^{3}-MOPD adjusts sampling using remaining teacher–student divergence and its recent decrease; NASH-MOPD balances predicted proportional gap reductions across domains. A domain sampling ratio is the scheduled probability of selecting a prompt from that domain. Reverse Kullback–Leibler divergence, abbreviated KL, measures the discrepancy between the student’s and the domain teacher’s next-token distributions on student-generated responses. The remaining KL gap is the nonnegative difference between the smoothed divergence and 10% of its initial scale, divided by 90% of that scale. Smoothing assigns weight 0.2 to the latest observation and 0.8 to the previous smoothed value; the initial scale is the mean of the first five nonnegative observations. A gap of one represents the initial scale, and zero represents the target divergence.

Domain sampling ratios and remaining KL gaps for mathematics, code generation, and instruction following

Figure 5. Domain sampling ratios and remaining KL gaps for DeepSeek-R1-Distill-Qwen-1.5B through optimizer step 200 under Fixed, D3^{3}-MOPD, and NASH-MOPD. Columns show mathematics, code generation, and instruction following; the upper row shows sampling ratios and the lower row shows remaining gaps. Gray shading marks steps 1–20.

First, the upper row shows how the methods distribute training prompts. Fixed maintains ratios of 38.2%, 52.7%, and 9.1% for mathematics, code generation, and instruction following. In contrast, NASH-MOPD increases the mathematics ratio to 58.3% by step 120 while reducing the code generation ratio to 28.6%. D3^{3}-MOPD makes a larger shift toward instruction following after step 100, assigning it 58.2% at step 160, compared with 18.3% under NASH-MOPD. Thus, NASH-MOPD sustains a larger mathematics allocation, whereas D3^{3}-MOPD concentrates more prompts on instruction following during the middle and later stages.

Correspondingly, the lower row shows distinct patterns of gap reduction. At step 200, the mathematics gap is 0.051 under NASH-MOPD, compared with 0.091 under D3^{3}-MOPD and 0.131 under Fixed. Code generation shows the reverse ordering: Fixed reaches zero, while D3^{3}-MOPD and NASH-MOPD finish at 0.008 and 0.034. Meanwhile, the instruction-following gap fluctuates around one during early training and declines more strongly under D3^{3}-MOPD after its sampling ratio increases. Its final gap is 0.277 under D3^{3}-MOPD, 0.605 under NASH-MOPD, and 1.636 under Fixed. These trajectories show the domain trade-offs directly: NASH-MOPD achieves the smallest mathematics gap, Fixed the smallest code generation gap, and D3^{3}-MOPD the smallest instruction-following gap.

Next, Figure 6 compares predictions of gap reduction over 18 ten-step windows starting at steps 20, 30, …\ldots, 190. For domain kk and starting step ss, let a^k,s\hat{a}_{k,s} be the estimated gap decrease per prompt, computed by dividing the nonnegative gap decrease over up to ten observed updates by the number of prompt presentations during those updates. Let Δek,s\Delta e_{k,s} count prompt presentations over the next ten steps, including repeated presentations. Holding the starting estimate fixed gives the predicted reduction

Bar charts showing task-macro correlation and mean absolute error for Fixed, D³-MOPD, and Nash-MOPD

Figure 6. Gap-reduction prediction metrics for DeepSeek-R1-Distill-Qwen-1.5B under Fixed, D³-MOPD, and NASH-MOPD across 18 ten-step windows from step 20 to step 200. The left panel shows task-macro correlation; the right panel shows mean absolute error.

Δg^k,s=a^k,s Δek,s.\widehat{\Delta g}_{k,s}=\hat{a}_{k,s}\,\Delta e_{k,s}.

The observed reduction Δgk,s\Delta g_{k,s} is the starting gap minus the ending gap, so a negative value indicates an increase. Task-macro correlation is the equal-weight mean of the three domain-specific Spearman rank correlations between predicted and observed reductions over the 18 windows. Spearman correlation measures agreement between their rankings, with larger values indicating closer agreement. Mean absolute error is the mean of ∣Δg^k,s−Δgk,s∣\left|\widehat{\Delta g}_{k,s}-\Delta g_{k,s}\right| over all three domains and 18 windows; smaller values indicate closer predicted magnitudes.

Finally, both panels place NASH-MOPD ahead of the other methods. NASH-MOPD has the highest task-macro correlation at 0.421, followed by Fixed at 0.400 and D³-MOPD at 0.290. The corresponding correlation advantages are 0.021 and 0.130. NASH-MOPD also has the lowest mean absolute error at 0.0739, compared with 0.1008 for Fixed and 0.0812 for D³-MOPD, reductions of 26.6% and 8.9%, respectively. Together, the panels show that NASH-MOPD’s gap-reduction predictions achieve both closer agreement in ranking and smaller magnitude errors when averaged across the three domains.

Case Studies

DeepSeek-R1-Distill-Qwen-1.5B: Mathematical Reasoning

Question (MATH-500). A steel sphere with a 3-inch radius is made by removing metal from the corners of a cube that has the shortest possible side lengths. How many cubic inches are in the volume of the cube?

Reference answer: 216.

Initial Student (Incorrect)

The response states that an inscribed sphere “touches the corners of the cube,” and equates its diameter to the cube’s space diagonal:

s3=6,s=23.s\sqrt{3}=6,\qquad s=2\sqrt{3}.

[. . . intermediate reasoning omitted . . .]

It cubes this edge length:

(23)3=243.(2\sqrt{3})^3=24\sqrt{3}.

Model answer: 24324\sqrt{3}.

Check. The sphere must fit inside the cube. Its diameter equals the shortest cube’s edge, rather than its space diagonal. The proposed edge 23<62\sqrt{3}<6 cannot contain the sphere.

Fixed (Incorrect)

The response models the removal of corners using a truncation plane x+y+z=33x+y+z=3\sqrt{3}. It then sets a corner-to-plane distance equal to the sphere’s radius:

∣3s/2−33∣3=3.\frac{\left|3s/2-3\sqrt{3}\right|}{\sqrt{3}}=3.

[. . . intermediate reasoning omitted . . .]

It selects s=43s=4\sqrt{3} and computes

(43)3=1923.(4\sqrt{3})^3=192\sqrt{3}.

Model answer: 1923192\sqrt{3}.

Check. The added corner-to-plane constraint does not determine the smallest enclosing cube. The resulting edge is larger than the required diameter 6.

D³-MOPD (Incorrect)

The response assumes a truncation plane x+y+z=ax+y+z=a and uses the distance from the cube’s center (a/2,a/2,a/2)(a/2,a/2,a/2) to that plane:

∣3a/2−a∣3=a23=3⟹a=63.\frac{\left|3a/2-a\right|}{\sqrt{3}}=\frac{a}{2\sqrt{3}}=3\quad\Longrightarrow\quad a=6\sqrt{3}.

[. . . intermediate reasoning omitted . . .]

It evaluates (63)3=6483(6\sqrt{3})^3=648\sqrt{3}.

Model answer: 6483648\sqrt{3}.

Check. This assumed plane imposes an unsupported geometric condition. The shortest enclosing cube is determined by tangency to its six faces, so its edge is 6, not 636\sqrt{3}.

NASH-MOPD (Correct)

The response identifies the relevant tangency: “The sphere is inscribed inside the cube such that it touches the centers of the faces of the cube.” It therefore equates the cube’s edge to the sphere’s diameter:

s=2×3=6.s=2\times3=6.

[. . . intermediate reasoning omitted . . .]

It answers the requested volume, rather than a diagonal or the sphere’s volume: s3=63=216s^3=6^3=216.

Model answer: 216.

Check. The radius-3 sphere fits inside a cube of edge 6 and touches all six faces. Any smaller edge would exclude part of the sphere.

DeepSeek-R1-Distill-Qwen-1.5B: Code Generation

Question (LiveCodeBench v6; condensed). Given an uppercase string SS of length 3–100, count triples $1 \le i < j < k \le |S|$ such that j−i=k−jj-i=k-j and Si=AS_i=A, Sj=BS_j=B, Sk=CS_k=C. Read SS from standard input and print the count. For AABCC, the answer is 2; for AABAAABBAEDCCCD, it is 4.

Reference criterion: pass all 43 saved tests.

Initial Student (Incorrect)

[Reasoning and explanatory prose omitted.]

S = input().strip()
count = 0
n = len(S)
for d in range(1, n - 1):
    for j in range(1, n - d + 1):
        i = j - d
        k = j + d
        if S[i] == 'A' and S[j] == 'B' and S[k] == 'C':
            count += 1
print(count)

Recorded verdict: fail; 38/43 tests pass in the local recheck.

Check. The bounds allow k=nk=n, outside Python’s valid indices. AABAAABBAEDCCCD raises IndexError instead of printing 4.

Fixed (Incorrect)

The response repeatedly revisits the indexing and attempts to count the example AABCC. One pass gives 3 instead of the reference 2. It notices this mismatch: “So perhaps my approach is still wrong.”

[. . . intermediate reasoning omitted . . .]

The saved response ends while reconsidering the loop bounds:

“So for len(S)=5, j runs from 1 to4.

In j=4:

i can”

Recorded verdict: fail; no complete code block.

Check. The saved generation contains no complete delimited Python program. It is an unfinished response, so no runnable solution can be submitted under the benchmark’s extraction rule.

D3-MOPD (Incorrect)

[Reasoning and explanatory prose omitted.]

s = input().strip()
n = len(s)
count = 0
for j in range(n):
    max_d = n - j - 1
    for d in range(1, max_d + 1):
        i = j - d
        k = j + d
        if s[i] == 'A' and s[j] == 'B' and s[k] == 'C':
            count += 1
print(count)

Recorded verdict: fail; 42/43 tests pass in the local recheck.

Check. The upper bound constrains only the right endpoint. For d>jd>j, i=j−di=j-d is negative and Python reads from the end of the string. The saved test AABAAABBAEDCCCD produces 5 rather than 4.

NASH-MOPD (Correct)

[Reasoning and explanatory prose omitted.]

s = input().strip()
count = 0
n = len(s)
for j in range(2, n):
    max_d = min(j - 1, n - j)
    for d in range(1, max_d + 1):
        i = j - d
        k = j + d
        if i < 1 or k > n:
            continue
        if s[i-1] == 'A' and s[j-1] == 'B' and s[k-1] ==
'C':
            count += 1
print(count)

Recorded verdict: pass; 43/43 tests pass in the local recheck.

Check. The response uses one-based mathematical indices consistently and converts them to Python indices at access time. The bound d≤min⁡(j−1,n−j)d \le\min(j-1,n-j) keeps both endpoints inside the string. It prints 4 on the same counterexample.

DeepSeek-R1-Distill-Qwen-1.5B: Instruction Following

Question (IFBench; original English prompt). Generate 4 multiple choice questions with 5 options each about “20th century art history”. Each question should start with the label “Question”. The questions should get progressively longer. Do not provide an explanation.

Reference criterion: the official custom:mcq_count_length check. Length is the character count of question text before its options.

Initial Student (Incorrect)

[Reasoning and the five options per question omitted; all question texts retained.]

Question 1: The Great Depression and World War II had a significant impact on 20th century art. Which of the following best describes this impact?

Question 2: The 1950s and 1960s were a time of digital art and computer use. Which movement emerged during this period?

Question 3: The 1970s and 1980s were a time of experimentation and new art movements. Which movement emerged during this period?

Question 4: The 1990s and 2000s brought about the digital revolution and the rise of digital art. Which of the following best describes this period?

Recorded verdict: strict fail; loose fail.

Check. The question lengths are 134, 107, 116, 136 characters. The second question is shorter than the first, so the required increasing-length sequence fails.

Fixed (Incorrect)

[Reasoning and the five options per question omitted; all question texts retained.]

Question 1: Which of the following best describes the origins of 20th century art?

Question 2: What was a key characteristic of Expressionism in 20th century art?

Question 3: How did the Great Depression and World War II shape 20th century art?

Question 4: What is a major concept in 20th century art history?

Recorded verdict: strict fail; loose fail.

Check. The question lengths are 70, 67, 69, 52 characters. They decrease at the first transition and again at the last transition.

D3D^3-MOPD (Incorrect)

[Reasoning and the five options per question omitted; all question texts retained.]

Question Which artist is best known for creating abstract geometric patterns in the 20th century?

Question Which period in the 20th century saw the most significant contributions to modern art?

Question Which of the following artists is associated with the use of color in their work during the 20th century?

Question Which of the following movements was most influential in shaping 20th century art?

Recorded verdict: strict fail; loose fail.

Check. The question lengths are 88, 86, 105, 82 characters and are not strictly increasing. It also omits question numbers expected by the official parser.

NASH-MOPD (Correct)

[Reasoning and the five options per question omitted; all question texts retained.]

Question 1: What was the first major movement in 20th century art history?

Question 2: Which of the following is a key figure in the Realism movement?

Question 3: What theory emerged in the 20th century that influenced modern art?

Question 4: Which of the following is a significant theory in 20th century art history?

Recorded verdict: strict pass; loose pass.

Check. The question lengths are 62, 63, 67, 75 characters, so all three transitions increase. The original response has four numbered questions, each with five options, and no explanatory prose. This verdict checks the requested format and lengths, rather than the factual quality of the quiz.

Qwen3-8B-Base: Mathematical Reasoning

Question (MATH-500). How many of the same digits are found in the base 7 and base 8 representations of 62910629_{10}? For example, 1213121_{3} and 4135413_{5} would have one digit in common.

Reference answer: 3.

Initial Student (Incorrect)

The response describes repeated division and supplies a conversion function, then claims the following output:

([1, 6, 0, 2], [1, 1, 4, 5], {1}, 1)

[… intermediate reasoning omitted …]

It concludes that the representations are 160271602_{7} and 114581145_{8}, and that only the digit 1 appears in both.

Model answer: 1.

Check. The claimed conversions are incorrect: 16027=6391602_{7} = 639 and 11458=6131145_{8} = 613. The actual representations are 155671556_{7} and 116581165_{8}.

Fixed (Incorrect)

The response correctly obtains 155671556_{7} and 116581165_{8}, but compares every occurrence of a digit in one representation with every occurrence in the other. It lists five matches:

“1 vs 1” (twice), “5 vs 5” (twice), and “6 vs 6”.

[… intermediate reasoning omitted …]

It decides that matches at different positions should count separately.

Model answer: 5.

Check. The question counts distinct shared digits, as its example indicates. Repeated occurrences of 1 and 5 must not increase the count.

D³-MOPD (Incorrect)

The response also correctly converts the number to 155671556_{7} and 116581165_{8}. It aligns their positions and compares 1 with 1, 5 with 1, 5 with 6, and 6 with 5.

[… intermediate reasoning omitted …]

It concludes: “Only the first digit is the same.”

Model answer: 1.

Check. Shared digits need not occur in the same position. Digits 5 and 6 occur in both representations, so positional comparison misses two valid shared digits.

NASH-MOPD (Correct)

The response computes 62910=15567=11658629_{10} = 1556_{7} = 1165_{8}. It initially considers a positional comparison, then revisits the meaning: “Alternatively, perhaps I should consider that the digits are the same regardless of their positions, just looking for any matching digits.”

[… intermediate reasoning omitted …]

It identifies 1, 5, and 6 in both representations, and explicitly counts each digit only once despite repeated occurrences.

Model answer: 3.

Check. The distinct digit sets are both {1,5,6}\{1, 5, 6\}. Their intersection has size 3, matching the question’s example.

Qwen3-8B-Base: Code Generation

Question (LiveCodeBench v6; condensed). Implement Solution.largestInteger(nums, k). An integer is “almost missing” if it appears in exactly one contiguous subarray of size k. Return the largest such integer, or −1 if none exists. Constraints: 1≤∣nums∣≤501 \leq|\mathrm{nums}| \leq50, 0≤nums[i]≤500 \leq\mathrm{nums}[i] \leq50, and 1≤k≤∣nums∣1 \leq k \leq|\mathrm{nums}|.

Reference criterion: pass all 34 saved tests. Repeated occurrences inside one subarray count as one containing subarray.

Initial Student (Incorrect)

Its first code block accumulates each occurrence: [Surrounding code and prose omitted.]

for subarray in subarrays:
    for num in subarray:
        count[num] += 1

The last code block contains only example calls:

solution = Solution()
print(solution.largestInteger([3, 9, 2, 1, 7], 3))  #
    Output: 7
print(solution.largestInteger([3, 9, 7, 2, 1, 7], 4))  #
    Output: 3
print(solution.largestInteger([0, 0], 1))  # Output: -1

Recorded verdict: fail; 0/34 tests pass in the local recheck.

Check. The benchmark extracts the last complete code block, which has no class definition and raises NameError. The earlier implementation also counts repeated elements within one subarray multiple times.

Fixed (Incorrect)

[Imports, signature, comments and prose omitted.]

subarrays = []
for i in range(len(nums) - k + 1):
    subarrays.append(nums[i:i + k])
from collections import defaultdict
count_dict = defaultdict(int)
for subarray in subarrays:
    for num in subarray:
        count_dict[num] += 1
largest_integer = -1
for num in sorted(count_dict.keys(), reverse=True):
    if count_dict[num] == 1:
        largest_integer = num
        break
return largest_integer

Recorded verdict: fail; 30/34 tests pass in the local recheck.

Check. For nums = [0] * 50 and k = 50, there is only one subarray. The correct answer is 0, but the code counts 50 occurrences and returns −1.

D³-MOPD (Incorrect)

[Imports, signature, comments and prose omitted.]

subarrays = []
for i in range(len(nums) - k + 1):
    subarrays.append(nums[i:i + k])
count_dict = {}
for num in nums:
    count_dict[num] = 0
for subarray in subarrays:
    for num in subarray:
        if num in count_dict:
            count_dict[num] += 1
max_num = -1
for num, count in count_dict.items():
    if count == 1 and num > max_num:
        max_num = num
return max_num

Recorded verdict: fail; 30/34 tests pass in the local recheck.

Check. The membership check tests whether a dictionary entry exists; it does not deduplicate elements within a subarray. Thus the same saved counterexample, nums = [0] * 50, k = 50, returns −1 instead of 0.

NASH-MOPD (Correct)

[Imports, signature, comments and prose omitted.]

subarrays = []
for i in range(len(nums) - k + 1):
    subarrays.append(nums[i:i + k])
count_dict = {}
for num in nums:
    count = 0
    for subarray in subarrays:
        if num in subarray:
            count += 1
    count_dict[num] = count
result = -1
for num, count in count_dict.items():
    if count == 1 and num > result:
        result = num
return result

Recorded verdict: pass; 34/34 tests pass in the local recheck.

Check. Each subarray contributes at most one count for a given integer via num in subarray. It follows, for the all-zero counterexample, because 0 belongs to exactly one size-50 subarray. It then selects the largest integer whose containing-subarray count equals one.

References

  1. [1]Rishabh Agarwal, Nino Vieillard, Yongchao Zhou, Piotr Stanczyk, Sabela Ramos Garea, Matthieu Geist, and Olivier Bachem. 2024. On-policy distillation of language models: Learning from self-generated mistakes. In International Conference on Learning Representations.arxiv.org/abs/2306.13649
  2. [2]Jacob Austin, Augustus Odena, Maxwell Nye, Maarten Bosma, Henryk Michalewski, David Dohan, Ellen Jiang, Carrie Cai, Michael Terry, Quoc Le, and Charles Sutton. 2021. Program synthesis with large language models. arXiv preprint arXiv:2108.07732.arxiv.org/abs/2108.07732
  3. [3]Mark Chen, Jerry Tworek, Heewoo Jun, et al. 2021. Evaluating large language models trained on code. arXiv preprint arXiv:2107.03374.arxiv.org/abs/2107.03374
  4. [4]Zhao Chen, Vijay Badrinarayanan, Chen-Yu Lee, and Andrew Rabinovich. 2018. GradNorm: Gradient normalization for adaptive loss balancing in deep multitask networks. In Proceedings of the 35th International Conference on Machine Learning, volume 80 of Proceedings of Machine Learning Research. PMLR.
  5. [6]Lang Feng, Zhenghai Xue, Tingcong Liu, and Bo An. 2025. Group-in-group policy optimization for LLM agent training. In Advances in Neural Information Processing Systems, volume 38.arxiv.org/abs/2505.10978
  6. [7]Zixuan Fu, Bingxiang He, Yuxin Zuo, Haohuan Huang, Jingxian Zhang, Ruhang Xiao, Cheng Qian, Qinyu Luo, Huan-ang Gao, Yudong Wang, Zhiyuan Liu, Ning Ding, and Chaojun Xiao. 2026. Rethinking on-policy distillation of large language models II: One training example. arXiv preprint arXiv:2609.04172.arxiv.org/abs/2609.04172
  7. [8]Yuxian Gu, Li Dong, Furu Wei, and Minlie Huang. 2024. MiniLLM: Knowledge distillation of large language models. In International Conference on Learning Representations.DOI
  8. [9]Daya Guo, Dejian Yang, Haowei Zhang, et al. 2025. DeepSeek-R1 incentivizes reasoning in LLMs through reinforcement learning. Nature, 645(8081):633–638.DOI
  9. [10]Michelle Guo, Albert Haque, De-An Huang, Serena Yeung, and Li Fei-Fei. 2018. Dynamic task prioritization for multitask learning. In Proceedings of the European Conference on Computer Vision.DOI
  10. [11]Bingxiang He, Zekai Qu, Zeyuan Liu, Yinghao Chen, Yuxin Zuo, Cheng Qian, Kaiyan Zhang, Weize Chen, Chaojun Xiao, Ganqu Cui, Ning Ding, and Zhiyuan Liu. 2026. JustRL: Scaling a 1.5b LLM with a simple RL recipe. In ICLR Blogposts 2026.arxiv.org/abs/2512.16649
  11. [12]Yun He, Di Jin, Chaoqi Wang, Chloe Bi, Karishma Mandyam, Hejia Zhang, Chen Zhu, Ning Li, Tengyu Xu, Hongjiang Lv, Shruti Bhosale, Chenguang Zhu, Karthik Abinav Sankararaman, Eryk Helenowski, Melanie Kambadur, Aditya Tayade, Hao Ma, Han Fang, and Sinong Wang. 2024. Multi-IF: Benchmarking LLMs on multi-turn and multilingual instructions following. arXiv preprint arXiv:2410.15553.arxiv.org/abs/2410.15553
  12. [13]Dan Hendrycks, Collin Burns, Saurav Kadavath, Akul Arora, Steven Basart, Eric Tang, Dawn Song, and Jacob Steinhardt. 2021. Measuring mathematical problem solving with the MATH dataset. In Proceedings of the Neural Information Processing Systems Track on Datasets and Benchmarks 1.
  13. [14]Naman Jain, King Han, Alex Gu, Wen-Ding Li, FanJia Yan, Tianjun Zhang, Sida Wang, Armando Solar-Lezama, Koushik Sen, and Ion Stoica. 2025. Live-CodeBench: Holistic and contamination free evaluation of large language models for code. In International Conference on Learning Representations.DOI
  14. [15]Kimi Team. 2026. Kimi K3: Open frontier intelligence. arXiv preprint arXiv:2607.24653.arxiv.org/abs/2607.24653
  15. [16]Rongao Li, Jie Fu, Bo-Wen Zhang, Tao Huang, Zhihong Sun, Chen Lyu, Guang Liu, Zhi Jin, and Ge Li. 2023. TACO: Topics in algorithmic COde generation dataset. arXiv preprint arXiv:2312.14852.arxiv.org/abs/2312.14852
  16. [17]Jiawei Liu, Chunqiu Steven Xia, Yuyao Wang, and Lingming Zhang. 2023. Is your code generated by ChatGPT really correct? rigorous evaluation of large language models for code generation. In Advances in Neural Information Processing Systems.arxiv.org/abs/2305.01210
  17. [18]LLM-Core Xiaomi. 2026. MiMo-V2.6: Scaling reinforcement learning towards self-improvement. Technical report, Xiaomi.arxiv.org/abs/2610.11959
  18. [19]Wenhan Ma, Jianyu Wei, Liang Zhao, Hailin Zhang, Bangjun Xiao, Lei Li, Qibin Yang, Bofei Gao, Yudong Wang, Rang Li, Jinhao Dong, Zhifang Sui, and Fuli Luo. 2026. MOPD: Multi-teacher on-policy distillation for capability integration in LLM post-training. arXiv preprint arXiv:2606.30406.arxiv.org/abs/2606.30406
  19. [20]Linjian Meng, Siyuan Gan, YuHan Li, Xiran Wang, Ziyang Ding, Dituan Gou, Yiming Wu, and Zhen Zhao. 2026. Unbiased top-k estimation for on-policy distillation. arXiv preprint arXiv:2609.34447.arxiv.org/abs/2609.34447

Paper details

vlnc:W_eycyjqq8
v1 · latestHistory (1)

published · Fresh — added to the Hub within the last 30 days

added ·

Usage

views · 0

downloads · 0

A view counts once per browser per day, a download each time the PDF is requested.

CC BY 4.0

Original source

  • Computer Science

Not recorded for this paper · View statement →

Looking for related papers…
Contents