Synthesizer: Rethinking Self-Attention for Transformer Models
Yi Tay, Dara Bahri, Donald Metzler, Da-Cheng Juan, Zhe Zhao, Che Zheng
摘要
The dot product self-attention is known to be central and indispensable to state-of-the-art Transformer models. But is it really required? This paper investigates the true importance and contribution of the dot product-based self-attention mechanism on the performance of Transformer models. Via extensive experiments, we find that (1) random alignment matrices surprisingly perform quite competitively and (2) learning attention weights from token-token (query-key) interactions is useful but not that important after all. To this end, we propose SYNTHESIZER, a model that learns synthetic attention weights without token-token interactions. In our experiments, we first show that simple Synthesizers achieve highly competitive performance when compared against vanilla Transformer models across a range of tasks, including machine translation, language modeling, text generation and GLUE/SuperGLUE benchmarks. When composed with dot product attention, we find that Synthesizers consistently outperform Transformers. Moreover, we conduct additional comparisons of Synthesizers against Dynamic Convolutions, showing that simple Random Synthesizer is not only 60% faster but also improves perplexity by a relative 3.5%. Finally, we show that simple factorized Synthesizers can outperform Linformers on encoding only tasks. introduction Transformer models (Vaswani et al., 2017) have demonstrated success across a wide range of tasks. This has resulted in Transformers largely displacing once popular auto-regressive and recurrent models in recent years. At the heart of Transformer models lies the query-key-value dot
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 46 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- MLP-Mixer: An all-MLP Architecture for Vision 引用了 On the Relationship between Self-Attention and Convolutional Layers
- cosFormer: Rethinking Softmax In Attention 引用了 Sparse Sinkhorn Attention
- cosFormer: Rethinking Softmax In Attention 引用了 Reformer: The Efficient Transformer
- Sparse Sinkhorn Attention 引用了 Reformer: The Efficient Transformer
- Fixed Encoder Self-Attention Patterns in Transformer-Based Machine Translation 引用了 Reformer: The Efficient Transformer
- Container: Context Aggregation Networks 引用了 MLP-Mixer: An all-MLP Architecture for Vision
- Container: Context Aggregation Networks 引用了 Reformer: The Efficient Transformer
- Spatio-temporal Relation Modeling for Few-shot Action Recognition 引用了 MLP-Mixer: An all-MLP Architecture for Vision
- Hierarchically Gated Recurrent Neural Network for Sequence Modeling 引用了 cosFormer: Rethinking Softmax In Attention
- Retrieval meets Long Context Large Language Models 引用了 Sparse Sinkhorn Attention
- Retrieval meets Long Context Large Language Models 引用了 Reformer: The Efficient Transformer
引用它的顶会 Paper46
- cosFormer: Rethinking Softmax In AttentionZhen Qin, Weixuan Sun, Hui Deng, Dongxu Li 等ICLR 2022 · 303 次引用
- Hierarchically Gated Recurrent Neural Network for Sequence ModelingZhen Qin, Songlin Yang, Yiran ZhongNeurIPS 2023 · 152 次引用
- Spatio-temporal Relation Modeling for Few-shot Action RecognitionAnirudh Thatipelli, Sanath Narayan, Salman Khan, Rao Muhammad Anwer 等CVPR 2022 · 144 次引用
- Retrieval meets Long Context Large Language ModelsPeng Xu, Wei Ping, Xianchao Wu, Lawrence McAfee 等ICLR 2024 · 131 次引用
- Container: Context Aggregation NetworksPeng Gao, Jiasen Lu, Hongsheng Li, Roozbeh Mottaghi 等NeurIPS 2021 · 86 次引用
它引用的 Paper5
- MLP-Mixer: An all-MLP Architecture for VisionIlya O. Tolstikhin, Neil Houlsby, Alexander Kolesnikov, Lucas Beyer 等NeurIPS 2021 · 3,862 次引用
- Reformer: The Efficient TransformerNikita Kitaev, Lukasz Kaiser, Anselm LevskayaICLR 2020 · 2,878 次引用
- On the Relationship between Self-Attention and Convolutional LayersJean-Baptiste Cordonnier, Andreas Loukas, Martin JaggiICLR 2020 · 629 次引用
- Sparse Sinkhorn AttentionYi Tay, Dara Bahri, Liu Yang, Donald Metzler 等ICML 2020 · 391 次引用
- Fixed Encoder Self-Attention Patterns in Transformer-Based Machine TranslationAlessandro Raganato, Yves Scherrer, Jörg TiedemannEMNLP Findings 2020 · 88 次引用
相关 Paper
- Recurrent Attention for Neural Machine TranslationJiali Zeng, Shuangzhi Wu, Yongjing Yin, Yufan Jiang 等EMNLP 2021
- Is the Attention Matrix Really the Key to Self-Attention in Multivariate Long-Term Time Series Forecasting?Xinyu Li, Kexi Chen, Jiajie Shen, Ying Zheng 等ACL 2026
- Symmetric Dot-Product Attention for Efficient Training of BERT Language ModelsMartin Courtois, Malte Ostendorff, Leonhard Hennig, Georg RehmACL Findings 2024 · 3 次引用
- How Much Does Attention Actually Attend? Questioning the Importance of Attention in Pretrained TransformersMichael Hassid, Hao Peng, Daniel Rotem, Jungo Kasai 等EMNLP Findings 2022 · 16 次引用
- RealFormer: Transformer Likes Residual AttentionRuining He, Anirudh Ravula, Bhargav Kanagal, Joshua AinslieACL Findings 2021 · 104 次引用
