Subquadratic Attention with a Hierarchical Tree-Structured Indexer
Not on the map. Why?
Abstract (arXiv)
The quadratic scaling of attention is a fundamental bottleneck limiting the long-context capabilities of large language models (LLMs). A variety of approaches have attempted to circumvent this, but they either fail to match attention's expressiveness (e.g., sliding-window or linear attention variants with fixed-size state) or only achieve constant-factor speedups (e.g., sparse attention methods whose indexers themselves scale quadratically). In this paper, we derive an asymptotically subquadratic sparse attention method based on a hierarchical, tree-structured indexer, which we call Zyphra Hierarchical Attention (ZHA). ZHA constructs a tree of recursively compressed key summaries over the KV cache, which future queries traverse from the top down to retrieve a sparse subset of keys. Crucially, by iteratively growing the tree's depth, the total cost including routing and final attention grows sublinearly in sequence length, resulting in overall subquadratic (but superlinear) scaling for attention. We demonstrate that ZHA can be cheaply applied to existing pretrained models with only a short KL distillation training stage of a billion tokens, and maintains performance on long-context retrieval and challenging reasoning, mathematical, and agentic coding evaluation tasks. Moreover, we show that our method is highly robust to tree geometry including very deep trees of up to 6 levels. Finally, we develop a detailed performance model and show that our approach scales subquadratically, dramatically outperforms competing methods beyond 1 million tokens of context, and ultimately has the potential to extend effective context windows to the hundreds of millions or billions of tokens.
Key facts. No citing papers in the map yet (data through 24 Nov 2026). Builds on 40 of its 44 references that are in the map. Submitted 30 Oct 2026.
Builds on
40 of 44 references.
References · 40
- 2017Attention Is All You Needcited by 62,125
- 2021RoFormer: Enhanced Transformer with Rotary Position Embeddingcited by 5,132
- 2023Mamba: Linear-Time Sequence Modeling with Selective State Spacescited by 5,111
- 2022FlashAttention: Fast and Memory-Efficient Exact Attention with IO-Awarenesscited by 3,893
- 2023SWE-bench: Can Language Models Resolve Real-World GitHub Issues?cited by 3,871
- 2023GPQA: A Graduate-Level Google-Proof Q&A Benchmarkcited by 3,191
- 2024MMLU-Pro: A More Robust and Challenging Multi-Task Language Understanding Benchmarkcited by 2,076
- 2024RULER: What's the Real Context Size of Your Long-Context Language Models?cited by 1,559
- 2024Transformers are SSMs: Generalized Models and Efficient Algorithms Through Structured State Space Dualitycited by 1,479
- 2023GQA: Training Generalized Multi-Query Transformer Models from Multi-Head Checkpointscited by 1,467
- 2026DeepSeek-V4: Towards Highly Efficient Million-Token Context Intelligencecited by 1,363
- 2024DeepSeek-V2: A Strong, Economical, and Efficient Mixture-of-Experts Language Modelcited by 1,241
28 more
- 2025DeepSeek-V3.2: Pushing the Frontier of Open Large Language Modelscited by 940
- 2023H2O: Heavy-Hitter Oracle for Efficient Generative Inference of Large Language Modelscited by 892
- 2024MiniCPM: Unveiling the Potential of Small Language Models with Scalable Training Strategiescited by 788
- 2024PyramidKV: Dynamic KV Cache Compression based on Pyramidal Information Funnelingcited by 479
- 2023Scissorhands: Exploiting the Persistence of Importance Hypothesis for LLM KV Cache Compression at Test Timecited by 471
- 2025Native Sparse Attention: Hardware-Aligned and Natively Trainable Sparse Attentioncited by 469
- 2024LongBench v2: Towards Deeper Understanding and Reasoning on Realistic Long-context Multitaskscited by 447
- 2024Jamba: A Hybrid Transformer-Mamba Language Modelcited by 438
- 2025Gated Attention for Large Language Models: Non-linearity, Sparsity, and Attention-Sink-Freecited by 323
- 2024Ada-KV: Optimizing KV Cache Eviction by Adaptive Budget Allocation for Efficient LLM Inferencecited by 264
- 2025Kimi Linear: An Expressive, Efficient Attention Architecturecited by 249
- 2024Repeat After Me: Transformers are Better than State Space Models at Copyingcited by 245
- 2024Zamba: A Compact 7B SSM Hybrid Modelcited by 138
- 2026Mamba-3: Improved Sequence Modeling using State Space Principlescited by 113
- 2025Dynamic Chunking for End-to-End Hierarchical Sequence Modelingcited by 86
- 2026MiniMax Sparse Attentioncited by 61
- 2024Softmax is not Enough (for Sharp Size Generalisation)cited by 60
- 2025Twilight: Adaptive Attention Sparsity with Hierarchical Top-p Pruningcited by 60
- 2026IndexCache: Accelerating Sparse Attention via Cross-Layer Index Reusecited by 46
- 2024The Zamba2 Suite: Technical Reportcited by 27
- 2025Sliding Window Attention Training for Efficient Large Language Modelscited by 27
- 2026Fast KVzip: Efficient and Accurate LLM Inference with Gated KV Evictioncited by 22
- 2026Hierarchical Sparse Attention Done Right: Toward Infinite Context Modelingcited by 19
- 2026LongCat Sparse Attention: Taming the Lightning via Streaming-aware Hierarchical Cross-Layer Indexingcited by 11
- 2026DashAttention: Differentiable and Adaptive Sparse Hierarchical Attentioncited by 7
- 2025Compressed Convolutional Attention: Efficient Attention in a Compressed Latent Spacecited by 6
- 2026ZAYA1-8B Technical Reportcited by 5
- 2026Block Sparse Attention with Log-Linear Complexitycited by 3
Built on by
Not cited yet.
Similar, not cited
Close in wording, no citation either way
- 2026Latent Sparse Attention: Towards Subquadratic Ultra-Long Context Attention
- 2024A Training-free Sub-quadratic Cost Transformer Model Serving Framework With Hierarchically Pruned Attention
- 2023SEA: Sparse Linear Attention with Estimated Attention Mask
- 2026Stratified Sparse Attention: Reducing the Sparse-to-Dense Gap at Extreme Sparsity
- 2026Recursive Sparse Attention: Million-Token Length Extrapolation at Logarithmic Cost
- 2026Simplified Sparse Attention via Gist Tokens
- 2026COBS: Cumulant Order Block Sparse Attention
- 2025SALE : Low-bit Estimation for Efficient Sparse Attention in Long-context LLM Prefilling