How much do contextualized representations encode long-range context?
Not on the map. Why?
Abstract (arXiv)
We analyze contextual representations in neural autoregressive language models, emphasizing long-range contexts that span several thousand tokens. Our methodology employs a perturbation setup and the metric Anisotropy-Calibrated Cosine Similarity, to capture the degree of contextualization of long-range patterns from the perspective of representation geometry. We begin the analysis with a case study on standard decoder-only Transformers, demonstrating that similar perplexity can exhibit markedly different downstream task performance, which can be explained by the difference in contextualization of long-range content. Next, we extend the analysis to other models, covering recent novel architectural designs and various training configurations. The representation-level results illustrate a reduced capacity for high-complexity (i.e., less compressible) sequences across architectures, and that fully recurrent models rely heavily on local context, whereas hybrid models more effectively encode the entire sequence structure. Finally, preliminary analysis of model size and training configurations on the encoding of long-range context suggest potential directions for improving existing language models.
Key facts. No citing papers in the map yet (data through 14 Oct 2026). Builds on 46 of its 71 references that are in the map. First posted on arXiv 16 Oct 2024.
Builds on
46 of 71 references.
References · 46
- 2017Attention Is All You Needcited by 60,361
- 2015Deep Residual Learning for Image Recognitioncited by 52,096
- 2024The Llama 3 Herd of Modelscited by 14,715
- 2023Mamba: Linear-Time Sequence Modeling with Selective State Spacescited by 4,718
- 2021RoFormer: Enhanced Transformer with Rotary Position Embeddingcited by 4,703
- 2014Neural Machine Translation by Jointly Learning to Align and Translatecited by 4,548
- 2021SimCSE: Simple Contrastive Learning of Sentence Embeddingscited by 2,173
- 2024RULER: What's the Real Context Size of Your Long-Context Language Models?cited by 1,346
- 2024Transformers are SSMs: Generalized Models and Efficient Algorithms Through Structured State Space Dualitycited by 1,336
- 2021Train Short, Test Long: Attention with Linear Biases Enables Input Length Extrapolationcited by 1,103
- 2023RWKV: Reinventing RNNs for the Transformer Eracited by 827
- 2019How Contextual are Contextualized Word Representations? Comparing the Geometry of BERT, ELMo, and GPT-2 Embeddingscited by 784
34 more
- 2023Extending Context Window of Large Language Models via Positional Interpolationcited by 740
- 2019Compressive Transformers for Long-Range Sequence Modellingcited by 726
- 2024Parallelizing Linear Transformers with the Delta Rule over Sequence Lengthcited by 396
- 2023Hyena Hierarchy: Towards Larger Convolutional Language Modelscited by 393
- 2019Linguistic Knowledge and Transferability of Contextual Representationscited by 383
- 2024Learning to (Learn at Test Time): RNNs with Expressive Hidden Statescited by 355
- 2023Effective Long-Context Scaling of Foundation Modelscited by 303
- 2019Representation Degeneration Problem in Training Natural Language Generation Modelscited by 255
- 2024Griffin: Mixing Gated Linear Recurrences with Local Attention for Efficient Language Modelscited by 242
- 2019NeMo: a toolkit for building AI applications using Neural Modulescited by 235
- 2018Adaptive Input Representations for Neural Language Modelingcited by 226
- 2022A Contrastive Framework for Neural Text Generationcited by 225
- 2022Neural Networks and the Chomsky Hierarchycited by 217
- 2023What Algorithms can Transformers Learn? A Study in Length Generalizationcited by 199
- 2023Large Language Models as General Pattern Machinescited by 197
- 2023Text Embeddings Reveal (Almost) As Much As Textcited by 192
- 2024Samba: Simple Hybrid State Space Models for Efficient Unlimited Context Language Modelingcited by 174
- 2016Exploring the Limits of Language Modelingcited by 173
- 2024How to Train Long-Context Language Models (Effectively)cited by 146
- 2020Contextualized Perturbation for Textual Adversarial Attackcited by 136
- 2023Scaling Laws of RoPE-based Extrapolationcited by 125
- 2018Sharp Nearby, Fuzzy Far Away: How Neural Language Models Use Contextcited by 113
- 2021Do Long-Range Language Models Actually Use Long-Range Context?cited by 92
- 2024Is Cosine-Similarity of Embeddings Really About Similarity?cited by 89
- 2021Do Transformer Modifications Transfer Across Implementations and Applications?cited by 87
- 2024Anisotropy Is Inherent to Self-Attention in Transformerscited by 63
- 2022Contrastive Search Is What You Need For Neural Text Generationcited by 59
- 2022Outliers Dimensions that Disrupt Transformers Are Driven by Frequencycited by 55
- 2024Jamba-1.5: Hybrid Transformer-Mamba Models at Scalecited by 50
- 2024Megalodon: Efficient LLM Pretraining and Inference with Unlimited Context Lengthcited by 46
- 2024A Controlled Study on Long Context Extension and Generalization in LLMscited by 26
- 2021Frequency-based Distortions in Contextualized Word Embeddingscited by 20
- 2024Towards Optimal Learning of Language Modelscited by 7
- 2021How Do Neural Sequence Models Generalize? Local and Global Context Cues for Out-of-Distribution Predictioncited by 2
Built on by
Not cited yet.