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

用于相对位置的函数式插值改进长上下文 Transformer

Functional Interpolation for Relative Positions Improves Long Context Transformers

Carnegie Mellon University(卡内基梅隆大学);Google Research(谷歌研究院);Google DeepMind(谷歌DeepMind)

Shanda Li, Chong You, Guru Guruganesh, Joshua Ainslie, Santiago Ontanon, Manzil Zaheer, Sumit Sanghai, Yiming Yang, Sanjiv Kumar, Srinadh Bhojanapalli

AI总结:

针对长上下文外推中的位置编码瓶颈,提出带渐进式插值的函数式相对位置编码 FIRE,理论上可表示 T5 RPE、Alibi 和 Kerple,并在零样本语言建模与长文本基准上取得更优泛化。

摘要:

防止 Transformer 在处理比训练所用输入更长的输入时出现性能衰减,一直是扩展这些模型上下文长度的一项重要挑战。尽管 Transformer 架构在其能够处理的输入序列长度上基本没有限制,但训练期间所采用的位置编码选择,可能会限制这些模型在更长输入上的性能。我们提出一种新颖的带有渐进式插值的函数式相对位置编码 FIRE,以提升 Transformer 对更长上下文的泛化能力。我们从理论上证明,该方法能够表示一些流行的相对位置编码,例如 T5 的 RPE、Alibi 和 Kerple。随后,我们通过实验表明,FIRE 模型在零样本语言建模和长文本基准测试上都对更长上下文具有更好的泛化能力。

英文摘要:

Preventing the performance decay of Transformers on inputs longer than those used for training has been an important challenge in extending the context length of these models. Though the Transformer architecture has fundamentally no limits on the input sequence lengths it can process, the choice of position encoding used during training can limit the performance of these models on longer inputs. We propose a novel functional relative position encoding with progressive interpolation, FIRE, to improve Transformer generalization to longer contexts. We theoretically prove that this can represent some of the popular relative position encodings, such as T5's RPE, Alibi, and Kerple. We next empirically show that FIRE models have better generalization to longer contexts on both zero-shot language modeling and long text benchmarks.

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

↑