Two Heads Are Better than One: Simulating Large Transformers with Small Ones
Not on the map. Why?
Abstract (arXiv)
The quadratic complexity of self-attention prevents transformers from scaling effectively to long input sequences. On the other hand, modern GPUs and other specialized hardware accelerators are well-optimized for processing small input sequences in transformers during both training and inference. A natural question arises: can we take advantage of the efficiency of small transformers to deal with long input sequences? In this paper, we show that transformers with long input sequences (large transformers) can be efficiently simulated by transformers that can only take short input sequences (small transformers). Specifically, we prove that any transformer with input length N can be efficiently simulated by only O((N/M)2) transformers with input length M ll N, and that this cannot be improved in the worst case. However, we then prove that in various natural scenarios including average-case inputs, sliding window masking and attention sinks, the optimal number O(N/M) of small transformers suffice.
Key facts. Cited by 2 papers in the map (data through 14 Oct 2026). Builds on 35 of its 45 references that are in the map. First posted on arXiv 13 Jun 2025.
Builds on
35 of 45 references.
References · 35
- 2017Attention Is All You Needcited by 60,361
- 2020Language Models are Few-Shot Learnerscited by 32,419
- 2020An Image is Worth 16x16 Words: Transformers for Image Recognition at Scalecited by 30,186
- 2020End-to-End Object Detection with Transformerscited by 7,414
- 2023Mamba: Linear-Time Sequence Modeling with Selective State Spacescited by 4,718
- 2022FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awarenesscited by 3,673
- 2020Longformer: The Long-Document Transformercited by 3,413
- 2023Efficient Streaming Language Models with Attention Sinkscited by 2,186
- 2020Rethinking Attention with Performerscited by 1,601
- 2021Scaling Language Models: Methods, Analysis & Insights from Training Gophercited by 1,202
- 2020Efficient Transformers: A Surveycited by 790
- 2019Are Transformers universal approximators of sequence-to-sequence functions?cited by 406
23 more
- 2019Theoretical Limitations of Self-Attention in Neural Sequence Modelscited by 288
- 2022Transformers Learn Shortcuts to Automatacited by 268
- 2024Repeat After Me: Transformers are Better than State Space Models at Copyingcited by 216
- 2023Zoology: Measuring and Improving Recall in Efficient Language Modelscited by 204
- 2022The Parallelism Tradeoff: Limitations of Log-Precision Transformerscited by 193
- 2021Saturated Transformers are Constant-Depth Threshold Circuitscited by 139
- 2023Representational Strengths and Limitations of Transformerscited by 133
- 2019Hierarchical Transformers for Multi-Document Summarizationcited by 132
- 2023What Formal Languages Can Transformers Express? A Surveycited by 124
- 2019Hierarchical Transformers for Long Document Classificationcited by 104
- 2023Fast Attention Requires Bounded Entriescited by 102
- 2023HyperAttention: Long-context Attention in Near-Linear Timecited by 85
- 2020O(n) Connections are Expressive Enough: Universal Approximability of Sparse Transformerscited by 83
- 2024Transformers, parallel computation, and logarithmic depthcited by 79
- 2024RNNs are not Transformers (Yet): The Key Bottleneck on In-context Retrievalcited by 64
- 2024On Statistical Rates and Provably Efficient Criteria of Latent Diffusion Transformers (DiTs)cited by 40
- 2022An Exploration of Hierarchical Attention Transformers for Efficient Long Document Classificationcited by 38
- 2023PolySketchFormer: Fast Transformers via Sketching Polynomial Kernelscited by 36
- 2024Computational Limits of Low-Rank Adaptation (LoRA) Fine-Tuning for Transformer Modelscited by 31
- 2024Separations in the Representational Capabilities of Transformers and Recurrent Architecturescited by 29
- 2021LightSeq2: Accelerated Training for Transformer-based Models on GPUscited by 19
- 2023State Spaces Aren't Enough: Machine Translation Needs Attentioncited by 9
- 2024Fundamental Limitations on Subquadratic Alternatives to Transformerscited by 9
Built on by
Citing papers per year: 2026: 2.
2 papers.