Attention Alignment and Flexible Positional Embeddings Improve Transformer Length Extrapolation

要約

理想的な長さの外挿可能な Transformer 言語モデルは、長いシーケンスの微調整を行わずに、トレーニング長よりも長いシーケンスを処理できます。
このようなロングコンテキストの利用能力は、柔軟な位置埋め込み設計に大きく依存しています。
既存の大規模な事前トレーニング済み Transformer 言語モデルの柔軟性を調査した結果、位置埋め込みが豊富で柔軟な注意パターンを捕捉するため、T5 ファミリーは詳しく調べる価値があることがわかりました。
ただし、T5 には注意が分散するという問題があります。入力シーケンスが長いほど、注意の分布は平坦になります。
この問題を軽減するために、温度スケーリングによる 2 つの注意調整戦略を提案します。
私たちの発見は、言語モデリング、検索、および複数ドキュメントの質問応答における T5 のロングコンテキストの利用能力を微調整なしで改善し、柔軟な位置埋め込み設計と注意の調整が Transformer の長さの外挿に大いに役立つことを示唆しています。\脚注
{\url{https://github.com/chijames/Attendance-Alignment-Transformer-Length-Extrapolation}}

要約(オリジナル)

An ideal length-extrapolatable Transformer language model can handle sequences longer than the training length without any long sequence fine-tuning. Such long-context utilization capability highly relies on a flexible positional embedding design. Upon investigating the flexibility of existing large pre-trained Transformer language models, we find that the T5 family deserves a closer look, as its positional embeddings capture rich and flexible attention patterns. However, T5 suffers from the dispersed attention issue: the longer the input sequence, the flatter the attention distribution. To alleviate the issue, we propose two attention alignment strategies via temperature scaling. Our findings improve the long-context utilization capability of T5 on language modeling, retrieval, and multi-document question answering without any fine-tuning, suggesting that a flexible positional embedding design and attention alignment go a long way toward Transformer length extrapolation.\footnote{\url{https://github.com/chijames/Attention-Alignment-Transformer-Length-Extrapolation}}

arxiv情報

著者 Ta-Chung Chi,Ting-Han Fan,Alexander I. Rudnicky
発行日 2023-11-01 17:43:35+00:00
arxivサイト arxiv_id(pdf)

提供元, 利用サービス

arxiv.jp, Google

カテゴリー: cs.CL, cs.LG パーマリンク