通过双向自蒸馏提升扩散语言模型生成质量,效果超越教师模型。
SelFusion: Self-distillation for Diffusion Language Models

- 同一模型两次前向传播,不同掩码率形成难易模式,实现自蒸馏。
- 在指令跟随任务上,性能超越使用外部教师的蒸馏方法。
- 无需外部教师,适合追求高效高质文本生成的研究与应用。
扩散语言模型(DLMs)缓解了自回归大语言模型(LLMs)固有的延迟瓶颈,但其生成质量下降限制了实际应用。尽管知识蒸馏(KD)是提升性能的潜在方向,但我们发现直接应用传统KD仅带来微小提升,甚至降低生成质量。基于此,我们提出一种针对DLMs的新型自蒸馏框架——SelFusion。为在无外部教师模型的情况下实现有效蒸馏,SelFusion进行两次前向传播,采用不同掩码概率:高掩码率对应难模式,低掩码率对应易模式。然而,易模式并非总比难模式更准确,可能对错误词元过度自信。因此,我们引入双向知识蒸馏,根据词元级正确性动态决定蒸馏方向。在指令跟随任务上的实验表明,所提自蒸馏方法显著优于使用外部LLM和DLM教师的其他蒸馏方法。在多数配置中,使用SelFusion训练的学生模型甚至超越了LLM教师的性能,为提升DLM生成质量提供了实用路径。源代码见 https://github.com/scai-research/SelFusion_official。
原文摘要 · Abstract (English)
Diffusion language models (DLMs) alleviate the inherent latency bottleneck of autoregressive (AR) large language models (LLMs), but their degraded generation quality limits practical applicability. Although knowledge distillation (KD) can be a promising direction for improving performance, we empirically find that naively applying conventional KD yields only marginal gains, or even degrades generation quality. Based on these observations, we propose a novel self-distillation framework for DLMs, namely SelFusion. To enable effective KD without an external teacher model, SelFusion performs two forward passes with different masking levels, defining the hard mode with a larger masking probability and the easy mode with a smaller masking probability. However, the easy mode is not always more accurate than the hard mode and can be overconfident on incorrect tokens. Thus, we introduce bidirectional KD between the two modes, which can dynamically determine the distillation direction based on token-level correctness. Experimental results on instruction-following tasks show that the proposed self-distillation substantially outperforms other KD methods with external LLM and DLM teachers. In many configurations, the student trained with SelFusion even surpasses the performance of the LLM teacher, providing a practical path toward improving DLM generation quality. Source code can be found at https://github.com/scai-research/SelFusion_official
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。