Skip to main content
QUICK REVIEW

[论文解读] Scaling Laws for Neural Machine Translation

Behrooz Ghorbani, Orhan Fırat|arXiv (Cornell University)|Sep 16, 2021
Natural Language Processing Techniques参考文献 33被引用 19
一句话总结

本文提出了用于编码器-解码器Transformer模型的双变量缩放定律,应用于神经机器翻译任务,表明交叉熵损失取决于编码器和解码器的参数量,而不仅仅是总参数量。研究发现,当测试集为源语言原始(翻译后)或目标语言原始(自然)时,缩放收益存在显著差异:在源语言原始数据上,尽管损失持续降低,BLEU分数却趋于饱和。

ABSTRACT

We present an empirical study of scaling properties of encoder-decoder Transformer models used in neural machine translation (NMT). We show that cross-entropy loss as a function of model size follows a certain scaling law. Specifically (i) We propose a formula which describes the scaling behavior of cross-entropy loss as a bivariate function of encoder and decoder size, and show that it gives accurate predictions under a variety of scaling approaches and languages; we show that the total number of parameters alone is not sufficient for such purposes. (ii) We observe different power law exponents when scaling the decoder vs scaling the encoder, and provide recommendations for optimal allocation of encoder/decoder capacity based on this observation. (iii) We also report that the scaling behavior of the model is acutely influenced by composition bias of the train/test sets, which we define as any deviation from naturally generated text (either via machine generated or human translated text). We observe that natural text on the target side enjoys scaling, which manifests as successful reduction of the cross-entropy loss. (iv) Finally, we investigate the relationship between the cross-entropy loss and the quality of the generated translations. We find two different behaviors, depending on the nature of the test data. For test sets which were originally translated from target language to source language, both loss and BLEU score improve as model size increases. In contrast, for test sets originally translated from source language to target language, the loss improves, but the BLEU score stops improving after a certain threshold. We release generated text from all models used in this study.

研究动机与目标

  • 探究编码器-解码器NMT模型是否遵循与仅解码器语言模型相同的单变量缩放规律。
  • 理解训练和评估数据构成(特别是源语言原始与目标语言原始文本)对模型缩放行为的影响。
  • 检查交叉熵损失的改进是否一致地转化为BLEU和BLEURT等生成质量指标的提升。
  • 在缩放条件下,确定编码器与解码器之间最优的容量分配以实现最大性能。
  • 评估合成数据(如后向翻译)对缩放饱和点和模型质量的影响。

提出的方法

  • 在两个语料对上,通过调整编码器和解码器大小,实证训练大量编码器-解码器Transformer模型。
  • 将交叉熵损失建模为编码器和解码器参数量的双变量函数,拟合幂律缩放公式。
  • 在源语言原始(翻译后)和目标语言原始(自然)测试集上评估模型,以分析数据构成的影响。
  • 使用BLEU和BLEURT分数衡量生成质量,比较不同缩放策略下的趋势。
  • 在评估过程中使用固定超参数的束搜索,以确保所有模型的一致解码。
  • 分析交叉熵损失与生成指标之间的关系,识别不同数据环境下指标的分歧点。

实验结果

研究问题

  • RQ1编码器-解码器NMT模型的交叉熵损失是否遵循基于总参数量的单变量缩放规律,还是需要采用双变量公式?
  • RQ2训练和评估集中源端与目标端文本的自然性如何影响模型缩放行为和损失降低?
  • RQ3交叉熵损失的改进是否在不同数据构成下始终对应BLEU或BLEURT分数的提升?
  • RQ4在缩放条件下,为最大化翻译质量,编码器与解码器之间最优的容量分配是什么?
  • RQ5在合成的后向翻译数据上进行训练,如何影响模型性能的饱和点?

主要发现

  • 基于总参数量的单变量缩放规律无法准确描述NMT损失;采用编码器与解码器参数量的双变量函数可显著提升预测能力。
  • 解码器缩放的幂律指数与编码器不同,表明二者对损失降低的贡献具有非对称性。
  • 在目标语言原始评估集上,交叉熵损失随模型规模持续降低,BLEURT分数也相应提升。
  • 在源语言原始评估集上,交叉熵损失随规模改善,但BLEU分数在达到一定模型容量后趋于饱和,表明相关性出现断裂。
  • 源语言原始数据的不可约误差区域在模型规模适中时即已达到,表明在此类数据上进一步缩放的收益有限。
  • 在后向翻译(目标语言原始)数据上训练可实现随规模持续的性能提升,而在源语言原始数据上训练则导致性能早期饱和,可能源于翻译语体中多样性有限。

更好的研究,从现在开始

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

无需绑定信用卡

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