arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2409.12512cs.CL
收藏

探索与增强自回归语言模型知识蒸馏中的分布迁移

Exploring and Enhancing the Transfer of Distribution in Knowledge Distillation for Autoregressive Language Models

Harbin Institute of Technology(哈尔滨工业大学);University of Sydney(悉尼大学);Nanyang Technological University(南洋理工大学)

Jun Rao, Xuebo Liu, Zepeng Lin, Liang Ding, Jing Li, Dacheng Tao, Min Zhang

AI总结:

本文提出在线知识蒸馏(OKD)方法,通过在教师网络中集成小型在线模块与学生模型同步训练,动态适应学生分布,解决了传统Reverse KL和SGO在自回归语言模型中的局限性,并在多种架构和规模下提升性能且大幅减少训练时间。

摘要:

知识蒸馏(KD)是一种通过训练较小的学生模型来模仿大教师模型从而压缩它们的技术。KD在自回归语言模型中的成功主要依赖于Reverse KL进行模式寻找以及学生生成输出(SGO)来对抗曝光偏差。我们的理论分析和实验验证表明,尽管Reverse KL能有效地模仿教师分布的某些特征,但它未能捕获其大部分行为。相反,SGO带来了更高的计算成本,并在优化方面带来挑战,特别是当学生模型显著小于教师模型时。这些限制主要归因于教师模型不可变的分布,它无法自适应地调整以适应不同大小的模型。我们引入了在线知识蒸馏(OKD),其中教师网络集成小型在线模块以与学生模型同时训练。这一策略消除了对on-policy采样的需求,在训练过程中仅需对教师在线模块的参数进行最小化更新,从而允许动态适应学生的分布以实现更好的蒸馏。在多个生成数据集上的广泛结果表明,OKD在各种模型架构和规模下达到或超越了领先方法的性能,将训练时间减少了多达四倍。

英文摘要:

Knowledge distillation (KD) is a technique that compresses large teacher models by training smaller student models to mimic them. The success of KD in auto-regressive language models mainly relies on Reverse KL for mode-seeking and student-generated output (SGO) to combat exposure bias. Our theoretical analyses and experimental validation reveal that while Reverse KL effectively mimics certain features of the teacher distribution, it fails to capture most of its behaviors. Conversely, SGO incurs higher computational costs and presents challenges in optimization, particularly when the student model is significantly smaller than the teacher model. These constraints are primarily due to the immutable distribution of the teacher model, which fails to adjust adaptively to models of varying sizes. We introduce Online Knowledge Distillation (OKD), where the teacher network integrates small online modules to concurrently train with the student model. This strategy abolishes the necessity for on-policy sampling and merely requires minimal updates to the parameters of the teacher's online module during training, thereby allowing dynamic adaptation to the student's distribution to make distillation better. Extensive results across multiple generation datasets show that OKD achieves or exceeds the performance of leading methods in various model architectures and sizes, reducing training time by up to fourfold.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑