Research Article

Analysis of different transformer variants

Yisu Li
School of Computing, Wuhan University, Wuhan 430072, China

Abstract

Efficient self-attention models are crucial in applications where long sequences are modeled, such as documents, images, and videos, are often composed of relatively large numbers of pixels or tokens. Therefore, the efficiency of dealing with long sequences is crucial for the broad adoption of Transformers. This paper talks about four transformer variants: Longformer, Transformer-XL, Big Bird, and Star transformer. This paper makes a comparative analysis of the four varieties’ theoretical methods, and obtains the advantages of the four methods and their applicable fields. Longformer has lower complexity and can be used for various document-level tasks. Transformer-XL improves the accuracy by addressing context fragmentation. BigBird replaces the Bert-like whole attention mechanism with Block Sparse Attention, which has achieved the SOTA effect on many tasks with long text sequences, such as long text summaries, long text questions, and answers. Star-Transformer reduces the time complexity to and performs well in the synthetic data set.

Keywords: Transformer; Longformer; Transformer-XL; Big Bird; Star-Transformer.
Published: May 30, 2023
DOI: 10.54254/2755-2721/4/20230432
Volume: ACE Vol.4
pp. 143-151
Download PDF

References

  1. Hou B J and Z H Zhou 2018 Learning with Interpretable Structure from RNN
  2. Sutskever I O Vinyals and Q V Le 2014 Sequence to Sequence Learning with Neural
  3. Networks NIPS MIT Press
  4. Mikolov T et al 2015 Recurrent neural network based language model Interspeech Conference of the International Speech Communication Association Makuhari Chiba Japan September DBLP
  5. Vaswani A et al 2017 Attention Is All You Need arXiv arXiv
  6. Kim Y 2014 Convolutional Neural Networks for Sentence Classification Eprint Arxiv
  7. Zhang P et al 2021 Multi-Scale Vision Longformer: A New Vision Transformer for High-Resolution Image Encoding
  8. Dai Z et al 2019 Transformer-XL: Attentive Language Models beyond a Fixed-Length Context Proceedings of the 57th Annual Meeting of the Association for Computational Linguistics
  9. Zaheer M et al 2020 Big Bird: Transformers for Longer Sequences
  10. Guo Q et al 2019 Star-Transformer Proceedings of the 2019 Conference of the North 2019
  11. Al-Rfou R et al 2018 Character-Level Language Modeling with Deeper Self-Attention.