DAPE V2: Process Attention Score as Feature Map for Length Extrapolation
Not on the map. Why?
Abstract (arXiv)
The attention mechanism is a fundamental component of the Transformer model, contributing to interactions among distinct tokens, in contrast to earlier feed-forward neural networks. In general, the attention scores are determined simply by the key-query products. However, this work's occasional trial (combining DAPE and NoPE) of including additional MLPs on attention scores without position encoding indicates that the classical key-query multiplication may limit the performance of Transformers. In this work, we conceptualize attention as a feature map and apply the convolution operator (for neighboring attention scores across different heads) to mimic the processing methods in computer vision. Specifically, the main contribution of this paper is identifying and interpreting the Transformer length extrapolation problem as a result of the limited expressiveness of the naive query and key dot product, and we successfully translate the length extrapolation issue into a well-understood feature map processing problem. The novel insight, which can be adapted to various attention-related models, reveals that the current Transformer architecture has the potential for further evolution. Extensive experiments demonstrate that treating attention as a feature map and applying convolution as a processing method significantly enhances Transformer performance.
Key facts. Cited by 10 papers in the map (data through 7 Oct 2026). Builds on 108 of its 128 references that are in the map. First posted on arXiv 7 Oct 2024.
Builds on
108 of 128 references.
References · 108
- 2017Attention Is All You Needcited by 59,932
- 2015Deep Residual Learning for Image Recognitioncited by 51,809
- 2018BERT: Pre-training of Deep Bidirectional Transformers for Language Understandingcited by 40,204
- 2020Language Models are Few-Shot Learnerscited by 32,199
- 2020An Image is Worth 16x16 Words: Transformers for Image Recognition at Scalecited by 29,915
- 2019PyTorch: An Imperative Style, High-Performance Deep Learning Librarycited by 20,160
- 2014Very Deep Convolutional Networks for Large-Scale Image Recognitioncited by 15,267
- 2019Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformercited by 14,491
- 2023LLaMA: Open and Efficient Foundation Language Modelscited by 13,958
- 2021Swin Transformer: Hierarchical Vision Transformer using Shifted Windowscited by 12,082
- 2022Scalable Diffusion Models with Transformerscited by 5,931
- 2022PaLM: Scaling Language Modeling with Pathwayscited by 5,304
38 more
- 2023Mamba: Linear-Time Sequence Modeling with Selective State Spacescited by 4,616
- 2021RoFormer: Enhanced Transformer with Rotary Position Embeddingcited by 4,581
- 2020Training data-efficient image transformers & distillation through attentioncited by 4,560
- 2014Neural Machine Translation by Jointly Learning to Align and Translatecited by 4,530
- 2020Longformer: The Long-Document Transformercited by 3,362
- 2023Efficient Streaming Language Models with Attention Sinkscited by 2,115
- 2022BLOOM: A 176B-Parameter Open-Access Multilingual Language Modelcited by 1,968
- 2019Transformer-XL: Attentive Language Models Beyond a Fixed-Length Contextcited by 1,830
- 2018CommonsenseQA: A Question Answering Challenge Targeting Commonsense Knowledgecited by 1,793
- 2020Rethinking Attention with Performerscited by 1,584
- 2018Self-Attention with Relative Position Representationscited by 1,112
- 2019PEGASUS: Pre-training with Extracted Gap-sentences for Abstractive Summarizationcited by 1,100
- 2021Train Short, Test Long: Attention with Linear Biases Enables Input Length Extrapolationcited by 1,085
- 2023BloombergGPT: A Large Language Model for Financecited by 923
- 2023RWKV: Reinventing RNNs for the Transformer Eracited by 814
- 2022Galactica: A Large Language Model for Sciencecited by 736
- 2023Extending Context Window of Large Language Models via Positional Interpolationcited by 721
- 2023YaRN: Efficient Context Window Extension of Large Language Modelscited by 584
- 2022Hungry Hungry Hippos: Towards Language Modeling with State Space Modelscited by 495
- 2024Jamba: A Hybrid Transformer-Mamba Language Modelcited by 390
- 2024xLSTM: Extended Long Short-Term Memorycited by 320
- 2023The Impact of Positional Encoding on Length Generalization in Transformerscited by 319
- 2024LongRoPE: Extending LLM Context Window Beyond 2 Million Tokenscited by 302
- 2023Effective Long-Context Scaling of Foundation Modelscited by 301
- 2020Sparse Sinkhorn Attentioncited by 250
- 2021LongT5: Efficient Text-To-Text Transformer for Long Sequencescited by 232
- 2024Griffin: Mixing Gated Linear Recurrences with Local Attention for Efficient Language Modelscited by 232
- 2022Neural Networks and the Chomsky Hierarchycited by 214
- 2023What Algorithms can Transformers Learn? A Study in Length Generalizationcited by 198
- 2020Rethinking Positional Encoding in Language Pre-trainingcited by 197
- 2023Zoology: Measuring and Improving Recall in Efficient Language Modelscited by 188
- 2024Data Engineering for Scaling Language Models to 128K Contextcited by 183
- 2023Birth of a Transformer: A Memory Viewpointcited by 154
- 2022Transformer Language Models without Positional Encodings Still Learn Positional Informationcited by 148
- 2024Infini-gram: Scaling Unbounded n-gram Language Models to a Trillion Tokenscited by 148
- 2023Progressive-Hint Prompting Improves Reasoning in Large Language Modelscited by 147
- 2020On Translation Invariance in CNNs: Convolutional Layers can Exploit Absolute Spatial Locationcited by 141
- 2023Focused Transformer: Contrastive Training for Context Scalingcited by 133
50 most cited of 108 All 108 (JSON)
Built on by
Citing papers per year: 2025: 9; 2026: 1.
10 papers.
- 2025PaTH Attention: Position Encoding via Accumulating Householder Transformationscited by 32
- 2025Multi-Token Attentioncited by 10
- 2025SynapseRoute: An Auto-Route Switching Framework on Dual-State Large Language Modelcited by 7
- 2025Self-Adjust Softmaxcited by 3
- 2025SAS: Simulated Attention Scorecited by 3
- 2025Context-aware Biases for Length Extrapolationcited by 2
- 2025Benchmarking the Thinking Mode of Multimodal Large Language Models in Clinical Taskscited by 2
- 2025Beyond Real: Imaginary Extension of Rotary Position Embeddings for Long-Context LLMscited by 2
- 2026RoVE: Rotary Value Embeddings Attention for Relative Position-dependent Value Pathwayscited by 2
- 2025Diagnosing Shoulder Disorders Using Multimodal Large Language Models and Consumer-Grade Camerascited by 1
- 2026RoVE: Rotary Value Embeddings Attention for Relative Position-dependent Value Pathways9 Jun 2026
- 2025Beyond Real: Imaginary Extension of Rotary Position Embeddings for Long-Context LLMs8 Dec 2025
- 2025Benchmarking the Thinking Mode of Multimodal Large Language Models in Clinical Tasks5 Nov 2025
- 2025Diagnosing Shoulder Disorders Using Multimodal Large Language Models and Consumer-Grade Cameras10 Oct 2025
- 2025SAS: Simulated Attention Score10 Jul 2025
- 2025SynapseRoute: An Auto-Route Switching Framework on Dual-State Large Language Model3 Jul 2025
- 2025PaTH Attention: Position Encoding via Accumulating Householder Transformations22 May 2025
- 2025Multi-Token Attention1 Apr 2025
- 2025Context-aware Biases for Length Extrapolation11 Mar 2025
- 2025Self-Adjust Softmax25 Feb 2025