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

面向语言建模的学习跳过机制

Learning to Skip for Language Modeling

Google Research(谷歌研究院);Google Brain(谷歌大脑)

Dewen Zeng, Nan Du, Tao Wang, Yuanzhong Xu, Tao Lei, Zhifeng Chen, Claire Cui

AI总结:

针对语言模型对每个token分配相同计算量的问题,提出利用二元路由器动态跳过层或模块执行的通用方法,在24个NLP任务中以适度额外推理成本显著提升1-shot性能。

摘要:

过参数化的大规模语言模型在上下文少样本学习中展现出令人印象深刻的泛化性能。然而,大多数语言模型为每个token分配相同数量的参数或计算量,忽视了输入数据的复杂性或重要性。我们认为,在语言模型预训练中,应为不同的token分配可变的计算量,这可以通过简单的路由机制高效实现。与token只能在早期层提前退出的传统早停技术不同,我们提出了一种更通用的方法,利用二元路由器动态跳过任意输入token的某一层(或模块)的执行。在涵盖24个NLP任务的广泛评估中,我们证明所提方法仅需适度的额外推理成本,即可显著提升1-shot性能,优于其他竞争性基线。

英文摘要:

Overparameterized large-scale language models have impressive generalization performance of in-context few-shot learning. However, most language models allocate the same amount of parameters or computation to each token, disregarding the complexity or importance of the input data. We argue that in language model pretraining, a variable amount of computation should be assigned to different tokens, and this can be efficiently achieved via a simple routing mechanism. Different from conventional early stopping techniques where tokens can early exit at only early layers, we propose a more general method that dynamically skips the execution of a layer (or module) for any input token with a binary router. In our extensive evaluation across 24 NLP tasks, we demonstrate that the proposed method can significantly improve the 1-shot performance compared to other competitive baselines only at mild extra cost for inference.

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

↑