Geometric Analysis of Token Selection in Multi-Head Attention
Not on the map. Why?
Abstract (arXiv)
We present a geometric framework for analysing multi-head attention in large language models (LLMs). Without altering the mechanism, we view standard attention through a top-N selection lens and study its behaviour directly in value-state space. We define geometric metrics - Precision, Recall, and F-score - to quantify separability between selected and non-selected tokens, and derive non-asymptotic bounds with explicit dependence on dimension and margin under empirically motivated assumptions (stable value norms with a compressed sink token, exponential similarity decay, and piecewise attention weight profiles). The theory predicts a small-N operating regime of strongest non-trivial separability and clarifies how sequence length and sink similarity shape the metrics. Empirically, across LLaMA-2-7B, Gemma-7B, and Mistral-7B, measurements closely track the theoretical envelopes: top-N selection sharpens separability, sink similarity correlates with Recall. We also found that in LLaMA-2-7B heads specialize into three regimes - Retriever, Mixer, Reset - with distinct geometric signatures. Overall, attention behaves as a structured geometric classifier with measurable criteria for token selection, offering head level interpretability and informing geometry-aware sparsification and design of attention in LLMs.
Key facts. Cited by 1 paper in the map (data through 7 Oct 2026). Builds on 20 of its 26 references that are in the map. First posted on arXiv 2 Feb 2026.
Builds on
20 of 26 references.
References · 20
- 2023Llama 2: Open Foundation and Fine-Tuned Chat Modelscited by 12,865
- 2021RoFormer: Enhanced Transformer with Rotary Position Embeddingcited by 4,581
- 2014Neural Machine Translation by Jointly Learning to Align and Translatecited by 4,530
- 2023Mistral 7Bcited by 3,065
- 2023Efficient Streaming Language Models with Attention Sinkscited by 2,115
- 2020Transformers are RNNs: Fast Autoregressive Transformers with Linear Attentioncited by 1,979
- 2019Are Transformers universal approximators of sequence-to-sequence functions?cited by 404
- 2016From Softmax to Sparsemax: A Sparse Model of Attention and Multi-Label Classificationcited by 337
- 2024Massive Activations in Large Language Modelscited by 277
- 2024When Attention Sink Emerges in Language Models: An Empirical Viewcited by 200
- 2019Sparse Sequence-to-Sequence Modelscited by 167
- 2018Hyperbolic Entailment Cones for Learning Hierarchical Embeddingscited by 160
8 more
- 2023Quantizable Transformers: Removing Outliers by Helping Attention Heads Do Nothingcited by 147
- 2019On Identifiability in Transformerscited by 115
- 2024Spectral Filters, Dark Signals, and Attention Sinkscited by 54
- 2024Active-Dormant Attention Heads: Mechanistically Demystifying Extreme-Token Phenomena in LLMscited by 54
- 2017A Regularized Framework for Sparse and Structured Neural Attentioncited by 38
- 2026A Unified View of Attention and Residual Sinks: Outlier-Driven Rescaling is Essential for Transformer Trainingcited by 21
- 2025OrthoRank: Token Selection via Sink Token Orthogonality for Efficient LLM inferencecited by 8
- 2025Limitations of Normalization in Attention Mechanismcited by 7
Built on by
Citing papers per year: 2026: 1.
1 paper.
- 2026Retrieval Capacity of Self-Attention Under Competitioncited by 0
- 2026Retrieval Capacity of Self-Attention Under Competition29 Sep 2026