Ark Routes Tokens Between Softmax and Linear Attention
Not Every Token Deserves Softmax
The notable result is that a per-token routing decision, not a new kernel, delivers the memory savings — meaning existing hybrid designs may leave large efficiency gains on the table. Teams building long-context applications, RAG pipelines, or on-device inference should benchmark Ark's open-source code, since the 3.8x decoding speedup over FlashAttention-4 at 64K directly cuts serving cost. Researchers working on efficient attention architectures will want to compare the router's learned split against their own layer-interleaving heuristics.
Researchers introduce Attention Routing Kernels (Ark), a new attention architecture described in arXiv paper 2612.06276 that assigns each token to one of two memory types instead of forcing all tokens through a single attention kernel. A learned router, applied per token in every layer and KV group, keeps tokens that need precise recall in an exponential-kernel KV cache, while folding the rest into a fixed-size recurrent state used by linear attention. Every query reads from both memories at once.
The routing decision directly controls compute and memory cost. Training combines a linear-time recurrent pass with pairwise attention over only the retained keys, and inference runs with a fixed-size recurrent state plus the small set of KV cache entries that survived routing. Unlike standard softmax or linear attention, where the kernel is fixed and memory grows linearly with sequence length or recall is capped, Ark adapts its memory footprint to the input.
Empirically, models from 400M to 2B parameters match Transformers and hybrids that interleave softmax and linear layers, while storing about 90% less memory than Transformers and 25–53% less than hybrids. The savings translate into faster long-context decoding: at 64K tokens, Ark's 2B model decodes 1.8x faster than a GLA hybrid and 3.8x faster than FlashAttention-4. Code is released on GitHub.
Not Every Token Deserves Softmax
Softmax and linear attention sit at opposite ends of a memory tradeoff because they compare tokens with different kernels. The former uses an exponential kernel and caches every token, growing memory linearly with length; the latter uses a linear kernel, which factorizes so that the past compresses into a fixed-size recurrent state, at the cost of limited recall. In both cases the kernel is fixed, so neither adapts computation or memory to the input. We introduce Attention Routing Kernels (Ark), an architecture that chooses the kernel separately for each token, in every layer and KV group. A learned router sends each token to exactly one of two memories: tokens that need the exponential kernel stay in a KV cache, and the rest are folded into a fixed-size recurrent state. Every query reads both memories. The routing split governs cost: training combines a linear-time recurrent pass with pairwise attention over retained keys, while inference carries a fixed-size recurrent state plus the retained entries in the KV cache. Across 400M--2B parameters, Ark is competitive with Transformers and with hybrids that interleave softmax- and linear-attention layers, while storing about 90% and 25--53% less memory, respectively. Ark's smaller memory thus speeds up long-context decoding: at 64K, the 2B model is $1.8\times$ faster than a GLA hybrid and $3.8\times$ faster than FlashAttention-4. Code is available at https://github.com/goombalab/ark.
This report is categorized under AITOP's "Papers" desk, focusing on US frontier AI labs and Silicon Valley technology leaders. Within our cross-regional analytical framework, it directly maps to AI developer toolchains, coding agents, and engineering workflows and US-China foundation model benchmarks and commercialization comparison. Key entities and technical topics under continuous tracking include Ark, FlashAttention, linear attention, KV cache.
Source attribution: curated from arXiv cs.LG (@Aviv Bick, Arshia Afzal, Roger Waleffe, Aakash Lahoti, Mostofa Patwary, Mohammad Shoeybi, Bryan Catanzaro, Eric P. Xing, Albert Gu). Cross-source corroboration: 2 independent sources have covered this development (including Together AI), confirming industry-wide signal strength.
- Together AI12-03 19:40Source