Skip to main content
QUICK REVIEW

[论文解读] Rethinking embedding coupling in pre-trained language models

Hyung Won Chung, Thibault Févry|arXiv (Cornell University)|Oct 24, 2020
Topic Modeling参考文献 56被引用 11
一句话总结

本文挑战了预训练语言模型中输入与输出嵌入绑定的常规做法,表明解耦其维度——尤其是增大输出嵌入大小——可在不增加微调参数数量的情况下提升模型的泛化能力和迁移能力。通过将节省的参数重新分配至更深的Transformer层,作者在更少的预训练token下实现了多语言基准上的最先进性能,证明更大的输出嵌入可防止过专一化,并增强跨语言与跨任务的迁移能力。

ABSTRACT

We re-evaluate the standard practice of sharing weights between input and output embeddings in state-of-the-art pre-trained language models. We show that decoupled embeddings provide increased modeling flexibility, allowing us to significantly improve the efficiency of parameter allocation in the input embedding of multilingual models. By reallocating the input embedding parameters in the Transformer layers, we achieve dramatically better performance on standard natural language understanding tasks with the same number of parameters during fine-tuning. We also show that allocating additional capacity to the output embedding provides benefits to the model that persist through the fine-tuning stage even though the output embedding is discarded after pre-training. Our analysis shows that larger output embeddings prevent the model's last layers from overspecializing to the pre-training task and encourage Transformer representations to be more general and more transferable to other tasks and languages. Harnessing these findings, we are able to train models that achieve strong performance on the XTREME benchmark without increasing the number of parameters at the fine-tuning stage.

研究动机与目标

  • 重新评估在多语言设置下广泛采用的预训练语言模型中输入与输出嵌入绑定的做法。
  • 探究解耦嵌入维度是否能提升模型的灵活性、参数效率以及下游性能。
  • 确定增大输出嵌入大小是否能增强表示的泛化能力与跨任务和跨语言的迁移能力。
  • 设计并评估一种重新平衡的多语言BERT(RemBERT),其在更少的预训练token下优于XLM-R,且微调参数数量与mBERT和XLM-R相同。

提出的方法

  • 在仅编码器的模型中解耦输入与输出嵌入维度,实现对每一项的独立优化。
  • 在安全减少输入嵌入维度的同时,将节省的参数重新分配至增加Transformer层的宽度与深度。
  • 将输出嵌入大小增加至超过输入维度,即使该部分在预训练后被丢弃,也能提升预训练信号与表示质量。
  • 训练一种重新平衡的多语言mBERT(RemBERT)模型,采用优化的嵌入分配策略,使用与mBERT和XLM-R相同的微调参数数量。
  • 使用探测分析(Tenney et al., 2019)结合混合策略,评估在9项任务(包括POS、SRL和共指)上的通用NLP能力。
  • 通过从英语到德语的最近邻翻译准确率,逐层测量跨语言迁移能力,以评估语言无关表示学习的效果。

实验结果

研究问题

  • RQ1在多语言预训练模型中,解耦输入与输出嵌入维度是否能提升下游性能?
  • RQ2即使在预训练后被丢弃,增大输出嵌入大小是否仍能提升模型的泛化能力与迁移能力?
  • RQ3更大的输出嵌入在多大程度上能防止最后几层Transformer对预训练任务的过专一化?
  • RQ4嵌入解耦在多语言模型中如何影响跨语言对齐与迁移能力?
  • RQ5通过嵌入解耦优化参数分配,是否能让一个预训练token更少的模型在性能上超越更强的基线模型如XLM-R?

主要发现

  • 将输出嵌入大小从128提升至3072个token,在全部9项NLP任务上的探测准确率均得到提升,平均提升0.5分,且未增加微调参数数量。
  • 重新平衡的mBERT(RemBERT)模型在XTREME基准上的表现优于XLM-R,其预训练token数量仅为后者的1/3.5,且微调参数数量与mBERT和XLM-R相同。
  • 更大的输出嵌入使更高层的Transformer层产生更平坦、更具语言无关性的表示,表现为从英语到德语的最近邻翻译准确率提升。
  • 更大的输出嵌入带来的性能增益在微调过程中依然存在,表明预训练质量直接影响下游迁移能力。
  • 解耦嵌入维度允许安全减少输入嵌入而不会造成性能损失,从而释放参数用于更深更宽的Transformer层。
  • 探测结果表明,更大的输出嵌入通过减少对预训练目标的过专一化,提升了模型在高层的通用NLP能力。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。