TTT-Sparse: Test-Time Training of Sparse Attention for Long-Context Understanding

Xuehao Wang, Huayu Deng, Linhao Zhong, Yanbin Wei, Hengyu Zhao, Mingyu Liu, Hao Chen, Chunhua Shen


Abstract
Pretrained LLMs excel across diverse tasks, yet standard attention remains a major bottleneck for long-context understanding. Recent test-time training (TTT) methods alleviate this by encoding context into internal model parameters, but they typically require specialized architectures, meta-learned initialization, or continual post-training, preventing plug-and-play use on off-the-shelf LLMs. We propose test-time training sparse attention (TTT-Sparse), a plug-and-play alternative that performs test-time training over external memory while keeping the internal parameters frozen. For each input, TTT-Sparse constructs contextual chunk key states from the KV cache and learns a lightweight query adapter to induce a task-specific sparse attention pattern, which is used during generation to attend only to the most relevant context chunks and suppress interference from irrelevant context. Extensive experiments on long-context benchmarks show that TTT-Sparse improves long-context understanding while reducing generation-time attention cost.
Anthology ID:
2026.emnlp-main.1575
Volume:
Proceedings of the 2026 Conference on Empirical Methods in Natural Language Processing
Month:
October
Year:
2026
Address:
Budapest, Hungary
Editors:
Hung-Yi Lee, Sunipa Dev, Jessy Li, Desmond Elliott
Venue:
EMNLP
SIG:
SIGDAT
Publisher:
Association for Computational Linguistics
Note:
Pages:
35866–35881
Language:
URL:
https://aclanthology.org/2026.emnlp-main.1575/
DOI:
Bibkey:
Cite (ACL):
Xuehao Wang, Huayu Deng, Linhao Zhong, Yanbin Wei, Hengyu Zhao, Mingyu Liu, Hao Chen, and Chunhua Shen. 2026. TTT-Sparse: Test-Time Training of Sparse Attention for Long-Context Understanding. In Proceedings of the 2026 Conference on Empirical Methods in Natural Language Processing, pages 35866–35881, Budapest, Hungary. Association for Computational Linguistics.
Cite (Informal):
TTT-Sparse: Test-Time Training of Sparse Attention for Long-Context Understanding (Wang et al., EMNLP 2026)
Copy Citation:
PDF:
https://aclanthology.org/2026.emnlp-main.1575.pdf