Introduction
Large Language Models (LLMs) are powerful but computationally expensive to deploy. Knowledge Distillation (KD) aims to transfer the capabilities of a large teacher model into a smaller, more efficient student model. However, current KD methods face significant hurdles, including error accumulation in student-generated sequences and distribution noise in the teacher's high-dimensional output. This paper proposes a Multi-Granularity Semantic Revision framework to address these issues by intervening at the sequence, token, and span levels.
Methodology
1. Sequence Level: Sequence Correction and Re-generation (SCRG)
Most modern KD relies on "on-policy" data—sequences generated by the student. If the student makes an error early in a sentence, the rest of the sequence often becomes incoherent, leading the student to learn from its own hallucinations. The SCRG strategy acts as a proactive tutor by monitoring the "semantic cognitive difference" between the teacher and student at every token. When a significant error is detected, the framework replaces the student's token with the teacher's correct one, allowing the student to continue generating from a corrected state. This prevents error accumulation and increases data diversity.
2. Token Level: Distribution Adaptive Clipping KL (DAC-KL)
Not all parts of a teacher's probability distribution are equally informative. Standard loss functions like KL Divergence often struggle with the noise of low-probability tokens. The authors introduced Distribution Adaptive Clipping KL (DAC-KL), which uses a small, learnable sub-network to adaptively clip the teacher's output distribution. This focuses the student's attention on "semantically dense" areas—the most likely tokens—while filtering out redundant information that acts as noise.
3. Span Level: Correlation Consistency
Language is composed of phrases (spans) rather than independent tokens. To capture this structural information, the framework uses a "chunker" to identify noun and verb phrases. It then enforces Span-level Correlation Consistency, ensuring that the relationship between adjacent tokens within a phrase (calculated via Hadamard products and L2 distance) remains consistent between the teacher and the student. This helps the model learn the "connective tissue" of language, leading to more coherent outputs.
Experimental Evaluation
The researchers evaluated their method across four model families—LLaMA2, OpenLLAMA2, OPT, and GPT2—with parameters ranging from 0.1B to 13B. Testing was conducted on five prominent instruction-following datasets: Dolly, Self-Instruct, Vicuna, Super-Natural Instruction, and Unnatural Instruction.
Key Results
- Superior Performance: The proposed method outperformed state-of-the-art baselines such as MiniLLM, GKD, and DistiLLM across nearly every task.
- Significant Gains in OPT: On the OPT series (6.7B teacher to 1.3B student), the method showed an average score improvement of over 12% compared to the next best method.
- Robustness: Even the smallest models, such as GPT2-0.1B, saw significant gains, proving the method's effectiveness regardless of parameter count.
Conclusion
Multi-Granularity Semantic Revision offers a smarter way to distill LLMs by bridging the gap between rigid teacher-forcing and error-prone free-run generation. By focusing on high-density semantic regions and maintaining structural awareness through span priors, the framework significantly enhances the performance of small language models. Future work will explore the effectiveness of these revisions in specialized domains and multi-modal tasks.
Summary updated