TL;DR
Structured pruning efficiently compresses Large Language Models (LLMs) but often causes their free-form generation capabilities to collapse into repetitive loops. To fix this, the authors introduce ShortOPD, an on-policy distillation framework featuring a dynamic "short-to-long" rollout budget. By automatically shrinking the generation horizon when the model gets stuck in repetitive loops and expanding it as the model recovers, ShortOPD restores generation quality to 9× its unrecovered value while slashing training time by 76% compared to fixed-horizon baselines.
What Problem Does This Paper Address?
While structured pruning (deleting entire layers or channels) is highly hardware-friendly, it suffers from a frustrating evaluation gap. Pruned models often retain high accuracy on multiple-choice benchmarks like MMLU, yet completely collapse when asked to generate free-form text, code, or math solutions.
The authors diagnose this generation collapse with two key observations:
- Knowledge is demoted, not erased: Under greedy decoding ($pass@1$), performance drops to near zero. However, under repeated sampling ($pass@k$), correct answers still appear frequently. The model still "knows" the answers; its token rankings are just slightly misaligned.
- Compounding errors lead to loops: This misalignment causes errors to compound along the generation path, quickly trapping the pruned model in infinite suffix repetition loops (e.g., repeating the same phrase or tokens indefinitely).
Standard recovery methods like Supervised Fine-Tuning (SFT) or off-policy Knowledge Distillation (KD) fail to fix these specific on-policy generation errors. Meanwhile, standard On-Policy Distillation (OPD)—where the pruned model learns by generating text and comparing its token distributions to its unpruned self—wastes massive amounts of compute generating long, low-information repetitive suffixes early in training.
Methods
ShortOPD builds on top of On-Policy Distillation by introducing a closed-loop controller that dynamically adjusts the generation token budget ($H$) during training.
The framework operates via two main mechanisms:
- Terminal Periodic-Loop Detector: A lightweight probe monitors the final tokens of each student rollout to detect severe periodic repetitions. It calculates the "effective length" of the generation before the loop began.
- Repetition-Gated Horizon Control:
- If the repetition rate is high, the controller opens a "shrink gate," reducing the rollout budget ($H$) to match the average effective length. This cuts off the useless repetitive tails.
- If the repetition rate is low and generations are being cleanly truncated by the current budget, the controller opens a "growth gate," gradually increasing $H$ to allow the model to practice longer generations.
The student model is optimized using a generalized Jensen-Shannon Divergence (JSD) loss, matching the dense, token-level next-token probabilities of the original, unpruned model (acting as a frozen teacher).
Datasets
The authors utilized a mixed research corpus for recovery training and evaluation:
- Training/Recovery Corpus: A joint dataset of 29,585 prompts spanning math (GSM8K, MATH), code (OpenCodeInstruct, MBPP), and general instructions.
- Evaluation Benchmarks: Free-form generation was tested across Math (GSM8K, MATH-500), Code (HumanEval, MBPP), and Open-Ended generation (Alpaca, QA, Summarization, MT-Bench). Held-out multiple-choice benchmarks (ARC-C, HellaSwag, MMLU, WinoGrande) were also used for sanity checks.
Key Insights and Ideas
- Repetitive loops carry no learning signal: The authors discovered that the teacher-student divergence on repeated suffixes is roughly 35× lower than on ordinary tokens. Wasting compute on these loops yields virtually zero gradient information, creating a massive training bottleneck.
- Sparse rewards fail heavily compressed models: On-policy reinforcement learning methods like PPO or GRPO fail to recover pruned models because the model's greedy generation is so broken that it rarely samples a correct answer to receive a reward signal. Dense, token-level teacher guidance is mandatory.
- The recovery corpus dictates capability: "Leave-one-domain-out" ablations revealed that on-policy distillation only repairs the states the student actually visits. Removing math or code prompts from the training mix completely crippled recovery in those respective domains.
Key Results
ShortOPD was evaluated on 25%-pruned Qwen3-4B-Instruct and Qwen3-8B models.
- Generation Recovery: ShortOPD raised the compressed model's overall generation score to roughly 9× its unrecovered value, achieving 1.6–4.4× the performance of standard recovery recipes like SFT, KD, and SeqKD.
- Compute Efficiency: Compared to a fixed long horizon of 8,192 tokens, ShortOPD matched its performance within 2 points while using 71% fewer rollout tokens and reducing total training time from 35.9 hours down to just 8.5 hours.
- Versatility: The approach successfully generalized across different pruning structures, showing strong recovery gains for depth-pruned, width-pruned, and hybrid width-depth pruned models.
Limitations and Future Work
The authors note a few boundaries to their current work:
- Model Scope: The evaluation was restricted to the Qwen3 model family at 4B and 8B scales. Testing on broader model architectures is required to confirm universal generality.
- Compression Limits: The study primarily focused on a 25% parameter reduction. Exploring higher compression ratios is necessary to find the breaking point where lightweight on-policy recovery is no longer viable.
Summary updated