Aleph Alpha
Green gradient with a lighter band across the middle and faint outlined squares
Research

Pit NeitemeierFabien BenureauAlessio SerraEric SchreiberVolker StampaSascha WirgesSteffen Hirschmann

YASA: How Sparse Attention Made Kolibri 1.1 up to 14× More Efficient

TL;DR

Overview

Sparse Attention Step by Step

On a phone, we recommend reading this post in landscape mode: the interactive figures are made for a wide screen.

Rotate your phone for a better viewing experience.

Pepperclimbedatreethismorning.Mialookedinthegarden,butthecatstillsitsthere.WhereisPepper?Peppercurrent tokenDense attentioncostattention scoreThree steps: coarse selection, fine selection, attentionPepperclimbedatreeclimbingthismorning.Miatodaylookedinthegardensearching,butthecatpetstillsitsthere.sittingWhereisPepper?Peppercurrent tokenalways selectedSparse attentioncostattention scoreselection score
Pepperclimbedatreethismorning.Mialookedinthegarden,butthecatstillsitsthere.WhereisPepper?Peppercurrent tokenDense attentioncostattention scoreThree steps: coarse selection, fine selection, attentionPepperclimbedatreeclimbingthismorning.Miatodaylookedinthegardensearching,butthecatpetstillsitsthere.sittingWhereisPepper?Peppercurrent tokenalways selectedSparse attentioncostattention scoreselection score

Dense attention

The current token computes an attention score with every earlier token (a thicker arc is a higher score) and combines all tokens, weighted by their scores, into its output. Only a few tokens get a high score, but every score costs the same.

Serving Performance

  • Kolibri 1
  • Kolibri 1.1

Prefill latency (lower is better)

seconds to first token

0 20 40 60 80 100 16k 64k 256k 1M Context length (tokens) Kolibri 1, 16k: 0.242 seconds to first token Kolibri 1, 64k: 1.04 seconds to first token Kolibri 1, 256k: 6.97 seconds to first token Kolibri 1, 1M: 76 seconds to first token Kolibri 1.1, 16k: 0.239 seconds to first token Kolibri 1.1, 64k: 0.972 seconds to first token Kolibri 1.1, 256k: 4.01 seconds to first token Kolibri 1.1, 1M: 17.3 seconds to first token 1.0× 1.1× 1.7× 4.4× 0 20 40 60 80 100 16k 64k 256k 1M Context length (tokens) Kolibri 1, 16k: 0.242 seconds to first token Kolibri 1, 64k: 1.04 seconds to first token Kolibri 1, 256k: 6.97 seconds to first token Kolibri 1, 1M: 76 seconds to first token Kolibri 1.1, 16k: 0.239 seconds to first token Kolibri 1.1, 64k: 0.972 seconds to first token Kolibri 1.1, 256k: 4.01 seconds to first token Kolibri 1.1, 1M: 17.3 seconds to first token 1.0× 1.1× 1.7× 4.4× 0 20 40 60 80 100 16k 64k 256k 1M Context length (tokens) Kolibri 1, 16k: 0.242 seconds to first token Kolibri 1, 64k: 1.04 seconds to first token Kolibri 1, 256k: 6.97 seconds to first token Kolibri 1, 1M: 76 seconds to first token Kolibri 1.1, 16k: 0.239 seconds to first token Kolibri 1.1, 64k: 0.972 seconds to first token Kolibri 1.1, 256k: 4.01 seconds to first token Kolibri 1.1, 1M: 17.3 seconds to first token 1.0× 1.1× 1.7× 4.4×

Decode throughput (higher is better)

tokens/s per GPU

0 10k 20k 30k 40k 16k 64k 256k 1M Context length (tokens) Kolibri 1, 16k: 20,905 tokens/s per GPU Kolibri 1, 64k: 6,854 tokens/s per GPU Kolibri 1, 256k: 1,734 tokens/s per GPU Kolibri 1, 1M: 483 tokens/s per GPU Kolibri 1.1, 16k: 32,846 tokens/s per GPU Kolibri 1.1, 64k: 27,613 tokens/s per GPU Kolibri 1.1, 256k: 17,563 tokens/s per GPU Kolibri 1.1, 1M: 6,777 tokens/s per GPU 1.6× 4.0× 10.1× 14.0× 0 10k 20k 30k 40k 16k 64k 256k 1M Context length (tokens) Kolibri 1, 16k: 20,905 tokens/s per GPU Kolibri 1, 64k: 6,854 tokens/s per GPU Kolibri 1, 256k: 1,734 tokens/s per GPU Kolibri 1, 1M: 483 tokens/s per GPU Kolibri 1.1, 16k: 32,846 tokens/s per GPU Kolibri 1.1, 64k: 27,613 tokens/s per GPU Kolibri 1.1, 256k: 17,563 tokens/s per GPU Kolibri 1.1, 1M: 6,777 tokens/s per GPU 1.6× 4.0× 10.1× 14.0× 0 10k 20k 30k 40k 16k 64k 256k 1M Context length (tokens) Kolibri 1, 16k: 20,905 tokens/s per GPU Kolibri 1, 64k: 6,854 tokens/s per GPU Kolibri 1, 256k: 1,734 tokens/s per GPU Kolibri 1, 1M: 483 tokens/s per GPU Kolibri 1.1, 16k: 32,846 tokens/s per GPU Kolibri 1.1, 64k: 27,613 tokens/s per GPU Kolibri 1.1, 256k: 17,563 tokens/s per GPU Kolibri 1.1, 1M: 6,777 tokens/s per GPU 1.6× 4.0× 10.1× 14.0×

Model Quality

  • Kolibri 1
  • Kolibri 1.1

Base models

overall average (%) over knowledge, math and code benchmarks

0 20 40 60 80 100 English Kolibri 1: 81.2 81.2 Kolibri 1.1: 79.7 79.7 German Kolibri 1: 81.5 81.5 Kolibri 1.1: 79.8 79.8 0 20 40 60 80 100 English Kolibri 1: 81.2 81.2 Kolibri 1.1: 79.7 79.7 German Kolibri 1: 81.5 81.5 Kolibri 1.1: 79.8 79.8 0 20 40 60 80 100 English Kolibri 1: 81.2 81.2 Kolibri 1.1: 79.7 79.7 German Kolibri 1: 81.5 81.5 Kolibri 1.1: 79.8 79.8

Post-trained models

overall average (%) over model card benchmarks

0 20 40 60 80 100 English Kolibri 1: 64.0 64.0 Kolibri 1.1: 72.2 72.2 German Kolibri 1: 69.2 69.2 Kolibri 1.1: 74.2 74.2 0 20 40 60 80 100 English Kolibri 1: 64.0 64.0 Kolibri 1.1: 72.2 72.2 German Kolibri 1: 69.2 69.2 Kolibri 1.1: 74.2 74.2 0 20 40 60 80 100 English Kolibri 1: 64.0 64.0 Kolibri 1.1: 72.2 72.2 German Kolibri 1: 69.2 69.2 Kolibri 1.1: 74.2 74.2
  • Kolibri 1
  • Kolibri 1.1

RULER

score (%)

60 70 80 90 100 4k 16k 64k 256k 1M Context length (tokens) Kolibri 1, 4k: 95.8 score (%) Kolibri 1, 8k: 94.7 score (%) Kolibri 1, 16k: 93.3 score (%) Kolibri 1, 32k: 91.4 score (%) Kolibri 1, 64k: 85.7 score (%) Kolibri 1, 128k: 79.8 score (%) Kolibri 1, 256k: 79.7 score (%) Kolibri 1, 512k: 77 score (%) Kolibri 1, 1M: 72.6 score (%) Kolibri 1.1, 4k: 95 score (%) Kolibri 1.1, 8k: 93.7 score (%) Kolibri 1.1, 16k: 92.8 score (%) Kolibri 1.1, 32k: 88.9 score (%) Kolibri 1.1, 64k: 84.5 score (%) Kolibri 1.1, 128k: 80.1 score (%) Kolibri 1.1, 256k: 76.7 score (%) Kolibri 1.1, 512k: 74.2 score (%) Kolibri 1.1, 1M: 70.5 score (%) 60 70 80 90 100 4k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Kolibri 1, 4k: 95.8 score (%) Kolibri 1, 8k: 94.7 score (%) Kolibri 1, 16k: 93.3 score (%) Kolibri 1, 32k: 91.4 score (%) Kolibri 1, 64k: 85.7 score (%) Kolibri 1, 128k: 79.8 score (%) Kolibri 1, 256k: 79.7 score (%) Kolibri 1, 512k: 77 score (%) Kolibri 1, 1M: 72.6 score (%) Kolibri 1.1, 4k: 95 score (%) Kolibri 1.1, 8k: 93.7 score (%) Kolibri 1.1, 16k: 92.8 score (%) Kolibri 1.1, 32k: 88.9 score (%) Kolibri 1.1, 64k: 84.5 score (%) Kolibri 1.1, 128k: 80.1 score (%) Kolibri 1.1, 256k: 76.7 score (%) Kolibri 1.1, 512k: 74.2 score (%) Kolibri 1.1, 1M: 70.5 score (%) 60 70 80 90 100 4k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Kolibri 1, 4k: 95.8 score (%) Kolibri 1, 8k: 94.7 score (%) Kolibri 1, 16k: 93.3 score (%) Kolibri 1, 32k: 91.4 score (%) Kolibri 1, 64k: 85.7 score (%) Kolibri 1, 128k: 79.8 score (%) Kolibri 1, 256k: 79.7 score (%) Kolibri 1, 512k: 77 score (%) Kolibri 1, 1M: 72.6 score (%) Kolibri 1.1, 4k: 95 score (%) Kolibri 1.1, 8k: 93.7 score (%) Kolibri 1.1, 16k: 92.8 score (%) Kolibri 1.1, 32k: 88.9 score (%) Kolibri 1.1, 64k: 84.5 score (%) Kolibri 1.1, 128k: 80.1 score (%) Kolibri 1.1, 256k: 76.7 score (%) Kolibri 1.1, 512k: 74.2 score (%) Kolibri 1.1, 1M: 70.5 score (%)

Attention Bottlenecks

Sparse Attention Architecture

  • Kolibri 1.1
  • DeepSeek V4.1-Flash
  • Qwen3.8-Flash-Next
  • Qwen3-Next 80B-A3B
  • Kolibri 1

Attention FLOPs per token

forward FLOPs of the QK and AV products

100M 1G 10G 100G 1T 4k 16k 64k 256k 1M Context length (tokens) Kolibri 1, 4k: 975M forward FLOPs of the QK and AV products Kolibri 1, 8k: 1.49G forward FLOPs of the QK and AV products Kolibri 1, 16k: 2.51G forward FLOPs of the QK and AV products Kolibri 1, 32k: 4.53G forward FLOPs of the QK and AV products Kolibri 1, 64k: 8.55G forward FLOPs of the QK and AV products Kolibri 1, 128k: 16.6G forward FLOPs of the QK and AV products Kolibri 1, 256k: 32.7G forward FLOPs of the QK and AV products Kolibri 1, 512k: 64.9G forward FLOPs of the QK and AV products Kolibri 1, 1M: 129G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 4k: 535M forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 8k: 938M forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 16k: 1.74G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 32k: 3.35G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 64k: 6.57G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 128k: 13G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 256k: 25.9G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 512k: 51.7G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 1M: 103G forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 4k: 658M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 8k: 739M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 16k: 790M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 32k: 834M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 64k: 893M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 128k: 999M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 256k: 1.2G forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 512k: 1.61G forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 1M: 2.41G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 4k: 3.09G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 8k: 3.32G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 16k: 3.6G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 32k: 3.93G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 64k: 4.35G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 128k: 5.06G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 256k: 6.42G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 512k: 9.12G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 1M: 14.5G forward FLOPs of the QK and AV products Kolibri 1.1, 4k: 930M forward FLOPs of the QK and AV products Kolibri 1.1, 8k: 1.08G forward FLOPs of the QK and AV products Kolibri 1.1, 16k: 1.25G forward FLOPs of the QK and AV products Kolibri 1.1, 32k: 1.41G forward FLOPs of the QK and AV products Kolibri 1.1, 64k: 1.49G forward FLOPs of the QK and AV products Kolibri 1.1, 128k: 1.56G forward FLOPs of the QK and AV products Kolibri 1.1, 256k: 1.63G forward FLOPs of the QK and AV products Kolibri 1.1, 512k: 1.74G forward FLOPs of the QK and AV products Kolibri 1.1, 1M: 1.94G forward FLOPs of the QK and AV products 100M 1G 10G 100G 1T 4k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Kolibri 1, 4k: 975M forward FLOPs of the QK and AV products Kolibri 1, 8k: 1.49G forward FLOPs of the QK and AV products Kolibri 1, 16k: 2.51G forward FLOPs of the QK and AV products Kolibri 1, 32k: 4.53G forward FLOPs of the QK and AV products Kolibri 1, 64k: 8.55G forward FLOPs of the QK and AV products Kolibri 1, 128k: 16.6G forward FLOPs of the QK and AV products Kolibri 1, 256k: 32.7G forward FLOPs of the QK and AV products Kolibri 1, 512k: 64.9G forward FLOPs of the QK and AV products Kolibri 1, 1M: 129G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 4k: 535M forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 8k: 938M forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 16k: 1.74G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 32k: 3.35G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 64k: 6.57G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 128k: 13G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 256k: 25.9G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 512k: 51.7G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 1M: 103G forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 4k: 658M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 8k: 739M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 16k: 790M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 32k: 834M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 64k: 893M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 128k: 999M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 256k: 1.2G forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 512k: 1.61G forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 1M: 2.41G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 4k: 3.09G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 8k: 3.32G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 16k: 3.6G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 32k: 3.93G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 64k: 4.35G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 128k: 5.06G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 256k: 6.42G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 512k: 9.12G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 1M: 14.5G forward FLOPs of the QK and AV products Kolibri 1.1, 4k: 930M forward FLOPs of the QK and AV products Kolibri 1.1, 8k: 1.08G forward FLOPs of the QK and AV products Kolibri 1.1, 16k: 1.25G forward FLOPs of the QK and AV products Kolibri 1.1, 32k: 1.41G forward FLOPs of the QK and AV products Kolibri 1.1, 64k: 1.49G forward FLOPs of the QK and AV products Kolibri 1.1, 128k: 1.56G forward FLOPs of the QK and AV products Kolibri 1.1, 256k: 1.63G forward FLOPs of the QK and AV products Kolibri 1.1, 512k: 1.74G forward FLOPs of the QK and AV products Kolibri 1.1, 1M: 1.94G forward FLOPs of the QK and AV products 100M 1G 10G 100G 1T 4k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Kolibri 1, 4k: 975M forward FLOPs of the QK and AV products Kolibri 1, 8k: 1.49G forward FLOPs of the QK and AV products Kolibri 1, 16k: 2.51G forward FLOPs of the QK and AV products Kolibri 1, 32k: 4.53G forward FLOPs of the QK and AV products Kolibri 1, 64k: 8.55G forward FLOPs of the QK and AV products Kolibri 1, 128k: 16.6G forward FLOPs of the QK and AV products Kolibri 1, 256k: 32.7G forward FLOPs of the QK and AV products Kolibri 1, 512k: 64.9G forward FLOPs of the QK and AV products Kolibri 1, 1M: 129G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 4k: 535M forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 8k: 938M forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 16k: 1.74G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 32k: 3.35G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 64k: 6.57G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 128k: 13G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 256k: 25.9G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 512k: 51.7G forward FLOPs of the QK and AV products Qwen3-Next 80B-A3B, 1M: 103G forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 4k: 658M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 8k: 739M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 16k: 790M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 32k: 834M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 64k: 893M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 128k: 999M forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 256k: 1.2G forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 512k: 1.61G forward FLOPs of the QK and AV products Qwen3.8-Flash-Next, 1M: 2.41G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 4k: 3.09G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 8k: 3.32G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 16k: 3.6G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 32k: 3.93G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 64k: 4.35G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 128k: 5.06G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 256k: 6.42G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 512k: 9.12G forward FLOPs of the QK and AV products DeepSeek V4.1-Flash, 1M: 14.5G forward FLOPs of the QK and AV products Kolibri 1.1, 4k: 930M forward FLOPs of the QK and AV products Kolibri 1.1, 8k: 1.08G forward FLOPs of the QK and AV products Kolibri 1.1, 16k: 1.25G forward FLOPs of the QK and AV products Kolibri 1.1, 32k: 1.41G forward FLOPs of the QK and AV products Kolibri 1.1, 64k: 1.49G forward FLOPs of the QK and AV products Kolibri 1.1, 128k: 1.56G forward FLOPs of the QK and AV products Kolibri 1.1, 256k: 1.63G forward FLOPs of the QK and AV products Kolibri 1.1, 512k: 1.74G forward FLOPs of the QK and AV products Kolibri 1.1, 1M: 1.94G forward FLOPs of the QK and AV products

KV cache per sequence

GB at the served precision

0.001 0.01 0.1 1 10 100 4k 16k 64k 256k 1M Context length (tokens) Kolibri 1, 4k: 0.0839 GB at the served precision Kolibri 1, 8k: 0.126 GB at the served precision Kolibri 1, 16k: 0.21 GB at the served precision Kolibri 1, 32k: 0.377 GB at the served precision Kolibri 1, 64k: 0.713 GB at the served precision Kolibri 1, 128k: 1.38 GB at the served precision Kolibri 1, 256k: 2.73 GB at the served precision Kolibri 1, 512k: 5.41 GB at the served precision Kolibri 1, 1M: 10.8 GB at the served precision Qwen3-Next 80B-A3B, 4k: 0.0898 GB at the served precision Qwen3-Next 80B-A3B, 8k: 0.14 GB at the served precision Qwen3-Next 80B-A3B, 16k: 0.241 GB at the served precision Qwen3-Next 80B-A3B, 32k: 0.442 GB at the served precision Qwen3-Next 80B-A3B, 64k: 0.845 GB at the served precision Qwen3-Next 80B-A3B, 128k: 1.65 GB at the served precision Qwen3-Next 80B-A3B, 256k: 3.26 GB at the served precision Qwen3-Next 80B-A3B, 512k: 6.48 GB at the served precision Qwen3-Next 80B-A3B, 1M: 12.9 GB at the served precision Qwen3.8-Flash-Next, 4k: 0.116 GB at the served precision Qwen3.8-Flash-Next, 8k: 0.172 GB at the served precision Qwen3.8-Flash-Next, 16k: 0.286 GB at the served precision Qwen3.8-Flash-Next, 32k: 0.512 GB at the served precision Qwen3.8-Flash-Next, 64k: 0.965 GB at the served precision Qwen3.8-Flash-Next, 128k: 1.87 GB at the served precision Qwen3.8-Flash-Next, 256k: 3.68 GB at the served precision Qwen3.8-Flash-Next, 512k: 7.31 GB at the served precision Qwen3.8-Flash-Next, 1M: 14.6 GB at the served precision DeepSeek V4.1-Flash, 4k: 0.00636 GB at the served precision DeepSeek V4.1-Flash, 8k: 0.01 GB at the served precision DeepSeek V4.1-Flash, 16k: 0.0173 GB at the served precision DeepSeek V4.1-Flash, 32k: 0.0319 GB at the served precision DeepSeek V4.1-Flash, 64k: 0.061 GB at the served precision DeepSeek V4.1-Flash, 128k: 0.119 GB at the served precision DeepSeek V4.1-Flash, 256k: 0.236 GB at the served precision DeepSeek V4.1-Flash, 512k: 0.469 GB at the served precision DeepSeek V4.1-Flash, 1M: 0.936 GB at the served precision Kolibri 1.1, 4k: 0.0526 GB at the served precision Kolibri 1.1, 8k: 0.0633 GB at the served precision Kolibri 1.1, 16k: 0.0846 GB at the served precision Kolibri 1.1, 32k: 0.127 GB at the served precision Kolibri 1.1, 64k: 0.213 GB at the served precision Kolibri 1.1, 128k: 0.383 GB at the served precision Kolibri 1.1, 256k: 0.725 GB at the served precision Kolibri 1.1, 512k: 1.41 GB at the served precision Kolibri 1.1, 1M: 2.77 GB at the served precision 0.001 0.01 0.1 1 10 100 4k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Kolibri 1, 4k: 0.0839 GB at the served precision Kolibri 1, 8k: 0.126 GB at the served precision Kolibri 1, 16k: 0.21 GB at the served precision Kolibri 1, 32k: 0.377 GB at the served precision Kolibri 1, 64k: 0.713 GB at the served precision Kolibri 1, 128k: 1.38 GB at the served precision Kolibri 1, 256k: 2.73 GB at the served precision Kolibri 1, 512k: 5.41 GB at the served precision Kolibri 1, 1M: 10.8 GB at the served precision Qwen3-Next 80B-A3B, 4k: 0.0898 GB at the served precision Qwen3-Next 80B-A3B, 8k: 0.14 GB at the served precision Qwen3-Next 80B-A3B, 16k: 0.241 GB at the served precision Qwen3-Next 80B-A3B, 32k: 0.442 GB at the served precision Qwen3-Next 80B-A3B, 64k: 0.845 GB at the served precision Qwen3-Next 80B-A3B, 128k: 1.65 GB at the served precision Qwen3-Next 80B-A3B, 256k: 3.26 GB at the served precision Qwen3-Next 80B-A3B, 512k: 6.48 GB at the served precision Qwen3-Next 80B-A3B, 1M: 12.9 GB at the served precision Qwen3.8-Flash-Next, 4k: 0.116 GB at the served precision Qwen3.8-Flash-Next, 8k: 0.172 GB at the served precision Qwen3.8-Flash-Next, 16k: 0.286 GB at the served precision Qwen3.8-Flash-Next, 32k: 0.512 GB at the served precision Qwen3.8-Flash-Next, 64k: 0.965 GB at the served precision Qwen3.8-Flash-Next, 128k: 1.87 GB at the served precision Qwen3.8-Flash-Next, 256k: 3.68 GB at the served precision Qwen3.8-Flash-Next, 512k: 7.31 GB at the served precision Qwen3.8-Flash-Next, 1M: 14.6 GB at the served precision DeepSeek V4.1-Flash, 4k: 0.00636 GB at the served precision DeepSeek V4.1-Flash, 8k: 0.01 GB at the served precision DeepSeek V4.1-Flash, 16k: 0.0173 GB at the served precision DeepSeek V4.1-Flash, 32k: 0.0319 GB at the served precision DeepSeek V4.1-Flash, 64k: 0.061 GB at the served precision DeepSeek V4.1-Flash, 128k: 0.119 GB at the served precision DeepSeek V4.1-Flash, 256k: 0.236 GB at the served precision DeepSeek V4.1-Flash, 512k: 0.469 GB at the served precision DeepSeek V4.1-Flash, 1M: 0.936 GB at the served precision Kolibri 1.1, 4k: 0.0526 GB at the served precision Kolibri 1.1, 8k: 0.0633 GB at the served precision Kolibri 1.1, 16k: 0.0846 GB at the served precision Kolibri 1.1, 32k: 0.127 GB at the served precision Kolibri 1.1, 64k: 0.213 GB at the served precision Kolibri 1.1, 128k: 0.383 GB at the served precision Kolibri 1.1, 256k: 0.725 GB at the served precision Kolibri 1.1, 512k: 1.41 GB at the served precision Kolibri 1.1, 1M: 2.77 GB at the served precision 0.001 0.01 0.1 1 10 100 4k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Kolibri 1, 4k: 0.0839 GB at the served precision Kolibri 1, 8k: 0.126 GB at the served precision Kolibri 1, 16k: 0.21 GB at the served precision Kolibri 1, 32k: 0.377 GB at the served precision Kolibri 1, 64k: 0.713 GB at the served precision Kolibri 1, 128k: 1.38 GB at the served precision Kolibri 1, 256k: 2.73 GB at the served precision Kolibri 1, 512k: 5.41 GB at the served precision Kolibri 1, 1M: 10.8 GB at the served precision Qwen3-Next 80B-A3B, 4k: 0.0898 GB at the served precision Qwen3-Next 80B-A3B, 8k: 0.14 GB at the served precision Qwen3-Next 80B-A3B, 16k: 0.241 GB at the served precision Qwen3-Next 80B-A3B, 32k: 0.442 GB at the served precision Qwen3-Next 80B-A3B, 64k: 0.845 GB at the served precision Qwen3-Next 80B-A3B, 128k: 1.65 GB at the served precision Qwen3-Next 80B-A3B, 256k: 3.26 GB at the served precision Qwen3-Next 80B-A3B, 512k: 6.48 GB at the served precision Qwen3-Next 80B-A3B, 1M: 12.9 GB at the served precision Qwen3.8-Flash-Next, 4k: 0.116 GB at the served precision Qwen3.8-Flash-Next, 8k: 0.172 GB at the served precision Qwen3.8-Flash-Next, 16k: 0.286 GB at the served precision Qwen3.8-Flash-Next, 32k: 0.512 GB at the served precision Qwen3.8-Flash-Next, 64k: 0.965 GB at the served precision Qwen3.8-Flash-Next, 128k: 1.87 GB at the served precision Qwen3.8-Flash-Next, 256k: 3.68 GB at the served precision Qwen3.8-Flash-Next, 512k: 7.31 GB at the served precision Qwen3.8-Flash-Next, 1M: 14.6 GB at the served precision DeepSeek V4.1-Flash, 4k: 0.00636 GB at the served precision DeepSeek V4.1-Flash, 8k: 0.01 GB at the served precision DeepSeek V4.1-Flash, 16k: 0.0173 GB at the served precision DeepSeek V4.1-Flash, 32k: 0.0319 GB at the served precision DeepSeek V4.1-Flash, 64k: 0.061 GB at the served precision DeepSeek V4.1-Flash, 128k: 0.119 GB at the served precision DeepSeek V4.1-Flash, 256k: 0.236 GB at the served precision DeepSeek V4.1-Flash, 512k: 0.469 GB at the served precision DeepSeek V4.1-Flash, 1M: 0.936 GB at the served precision Kolibri 1.1, 4k: 0.0526 GB at the served precision Kolibri 1.1, 8k: 0.0633 GB at the served precision Kolibri 1.1, 16k: 0.0846 GB at the served precision Kolibri 1.1, 32k: 0.127 GB at the served precision Kolibri 1.1, 64k: 0.213 GB at the served precision Kolibri 1.1, 128k: 0.383 GB at the served precision Kolibri 1.1, 256k: 0.725 GB at the served precision Kolibri 1.1, 512k: 1.41 GB at the served precision Kolibri 1.1, 1M: 2.77 GB at the served precision

Cache read per decode step

GB at the served precision

0.01 0.1 1 10 100 4k 16k 64k 256k 1M Context length (tokens) Kolibri 1, 4k: 0.0839 GB at the served precision Kolibri 1, 8k: 0.126 GB at the served precision Kolibri 1, 16k: 0.21 GB at the served precision Kolibri 1, 32k: 0.377 GB at the served precision Kolibri 1, 64k: 0.713 GB at the served precision Kolibri 1, 128k: 1.38 GB at the served precision Kolibri 1, 256k: 2.73 GB at the served precision Kolibri 1, 512k: 5.41 GB at the served precision Kolibri 1, 1M: 10.8 GB at the served precision Qwen3-Next 80B-A3B, 4k: 0.0898 GB at the served precision Qwen3-Next 80B-A3B, 8k: 0.14 GB at the served precision Qwen3-Next 80B-A3B, 16k: 0.241 GB at the served precision Qwen3-Next 80B-A3B, 32k: 0.442 GB at the served precision Qwen3-Next 80B-A3B, 64k: 0.845 GB at the served precision Qwen3-Next 80B-A3B, 128k: 1.65 GB at the served precision Qwen3-Next 80B-A3B, 256k: 3.26 GB at the served precision Qwen3-Next 80B-A3B, 512k: 6.48 GB at the served precision Qwen3-Next 80B-A3B, 1M: 12.9 GB at the served precision Qwen3.8-Flash-Next, 4k: 0.0905 GB at the served precision Qwen3.8-Flash-Next, 8k: 0.0968 GB at the served precision Qwen3.8-Flash-Next, 16k: 0.109 GB at the served precision Qwen3.8-Flash-Next, 32k: 0.135 GB at the served precision Qwen3.8-Flash-Next, 64k: 0.185 GB at the served precision Qwen3.8-Flash-Next, 128k: 0.286 GB at the served precision Qwen3.8-Flash-Next, 256k: 0.487 GB at the served precision Qwen3.8-Flash-Next, 512k: 0.889 GB at the served precision Qwen3.8-Flash-Next, 1M: 1.69 GB at the served precision DeepSeek V4.1-Flash, 4k: 0.0101 GB at the served precision DeepSeek V4.1-Flash, 8k: 0.0119 GB at the served precision DeepSeek V4.1-Flash, 16k: 0.0156 GB at the served precision DeepSeek V4.1-Flash, 32k: 0.0183 GB at the served precision DeepSeek V4.1-Flash, 64k: 0.0239 GB at the served precision DeepSeek V4.1-Flash, 128k: 0.0351 GB at the served precision DeepSeek V4.1-Flash, 256k: 0.0573 GB at the served precision DeepSeek V4.1-Flash, 512k: 0.102 GB at the served precision DeepSeek V4.1-Flash, 1M: 0.191 GB at the served precision Kolibri 1.1, 4k: 0.0575 GB at the served precision Kolibri 1.1, 8k: 0.0606 GB at the served precision Kolibri 1.1, 16k: 0.0666 GB at the served precision Kolibri 1.1, 32k: 0.0669 GB at the served precision Kolibri 1.1, 64k: 0.0675 GB at the served precision Kolibri 1.1, 128k: 0.0687 GB at the served precision Kolibri 1.1, 256k: 0.071 GB at the served precision Kolibri 1.1, 512k: 0.0758 GB at the served precision Kolibri 1.1, 1M: 0.0852 GB at the served precision 0.01 0.1 1 10 100 4k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Kolibri 1, 4k: 0.0839 GB at the served precision Kolibri 1, 8k: 0.126 GB at the served precision Kolibri 1, 16k: 0.21 GB at the served precision Kolibri 1, 32k: 0.377 GB at the served precision Kolibri 1, 64k: 0.713 GB at the served precision Kolibri 1, 128k: 1.38 GB at the served precision Kolibri 1, 256k: 2.73 GB at the served precision Kolibri 1, 512k: 5.41 GB at the served precision Kolibri 1, 1M: 10.8 GB at the served precision Qwen3-Next 80B-A3B, 4k: 0.0898 GB at the served precision Qwen3-Next 80B-A3B, 8k: 0.14 GB at the served precision Qwen3-Next 80B-A3B, 16k: 0.241 GB at the served precision Qwen3-Next 80B-A3B, 32k: 0.442 GB at the served precision Qwen3-Next 80B-A3B, 64k: 0.845 GB at the served precision Qwen3-Next 80B-A3B, 128k: 1.65 GB at the served precision Qwen3-Next 80B-A3B, 256k: 3.26 GB at the served precision Qwen3-Next 80B-A3B, 512k: 6.48 GB at the served precision Qwen3-Next 80B-A3B, 1M: 12.9 GB at the served precision Qwen3.8-Flash-Next, 4k: 0.0905 GB at the served precision Qwen3.8-Flash-Next, 8k: 0.0968 GB at the served precision Qwen3.8-Flash-Next, 16k: 0.109 GB at the served precision Qwen3.8-Flash-Next, 32k: 0.135 GB at the served precision Qwen3.8-Flash-Next, 64k: 0.185 GB at the served precision Qwen3.8-Flash-Next, 128k: 0.286 GB at the served precision Qwen3.8-Flash-Next, 256k: 0.487 GB at the served precision Qwen3.8-Flash-Next, 512k: 0.889 GB at the served precision Qwen3.8-Flash-Next, 1M: 1.69 GB at the served precision DeepSeek V4.1-Flash, 4k: 0.0101 GB at the served precision DeepSeek V4.1-Flash, 8k: 0.0119 GB at the served precision DeepSeek V4.1-Flash, 16k: 0.0156 GB at the served precision DeepSeek V4.1-Flash, 32k: 0.0183 GB at the served precision DeepSeek V4.1-Flash, 64k: 0.0239 GB at the served precision DeepSeek V4.1-Flash, 128k: 0.0351 GB at the served precision DeepSeek V4.1-Flash, 256k: 0.0573 GB at the served precision DeepSeek V4.1-Flash, 512k: 0.102 GB at the served precision DeepSeek V4.1-Flash, 1M: 0.191 GB at the served precision Kolibri 1.1, 4k: 0.0575 GB at the served precision Kolibri 1.1, 8k: 0.0606 GB at the served precision Kolibri 1.1, 16k: 0.0666 GB at the served precision Kolibri 1.1, 32k: 0.0669 GB at the served precision Kolibri 1.1, 64k: 0.0675 GB at the served precision Kolibri 1.1, 128k: 0.0687 GB at the served precision Kolibri 1.1, 256k: 0.071 GB at the served precision Kolibri 1.1, 512k: 0.0758 GB at the served precision Kolibri 1.1, 1M: 0.0852 GB at the served precision 0.01 0.1 1 10 100 4k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Kolibri 1, 4k: 0.0839 GB at the served precision Kolibri 1, 8k: 0.126 GB at the served precision Kolibri 1, 16k: 0.21 GB at the served precision Kolibri 1, 32k: 0.377 GB at the served precision Kolibri 1, 64k: 0.713 GB at the served precision Kolibri 1, 128k: 1.38 GB at the served precision Kolibri 1, 256k: 2.73 GB at the served precision Kolibri 1, 512k: 5.41 GB at the served precision Kolibri 1, 1M: 10.8 GB at the served precision Qwen3-Next 80B-A3B, 4k: 0.0898 GB at the served precision Qwen3-Next 80B-A3B, 8k: 0.14 GB at the served precision Qwen3-Next 80B-A3B, 16k: 0.241 GB at the served precision Qwen3-Next 80B-A3B, 32k: 0.442 GB at the served precision Qwen3-Next 80B-A3B, 64k: 0.845 GB at the served precision Qwen3-Next 80B-A3B, 128k: 1.65 GB at the served precision Qwen3-Next 80B-A3B, 256k: 3.26 GB at the served precision Qwen3-Next 80B-A3B, 512k: 6.48 GB at the served precision Qwen3-Next 80B-A3B, 1M: 12.9 GB at the served precision Qwen3.8-Flash-Next, 4k: 0.0905 GB at the served precision Qwen3.8-Flash-Next, 8k: 0.0968 GB at the served precision Qwen3.8-Flash-Next, 16k: 0.109 GB at the served precision Qwen3.8-Flash-Next, 32k: 0.135 GB at the served precision Qwen3.8-Flash-Next, 64k: 0.185 GB at the served precision Qwen3.8-Flash-Next, 128k: 0.286 GB at the served precision Qwen3.8-Flash-Next, 256k: 0.487 GB at the served precision Qwen3.8-Flash-Next, 512k: 0.889 GB at the served precision Qwen3.8-Flash-Next, 1M: 1.69 GB at the served precision DeepSeek V4.1-Flash, 4k: 0.0101 GB at the served precision DeepSeek V4.1-Flash, 8k: 0.0119 GB at the served precision DeepSeek V4.1-Flash, 16k: 0.0156 GB at the served precision DeepSeek V4.1-Flash, 32k: 0.0183 GB at the served precision DeepSeek V4.1-Flash, 64k: 0.0239 GB at the served precision DeepSeek V4.1-Flash, 128k: 0.0351 GB at the served precision DeepSeek V4.1-Flash, 256k: 0.0573 GB at the served precision DeepSeek V4.1-Flash, 512k: 0.102 GB at the served precision DeepSeek V4.1-Flash, 1M: 0.191 GB at the served precision Kolibri 1.1, 4k: 0.0575 GB at the served precision Kolibri 1.1, 8k: 0.0606 GB at the served precision Kolibri 1.1, 16k: 0.0666 GB at the served precision Kolibri 1.1, 32k: 0.0669 GB at the served precision Kolibri 1.1, 64k: 0.0675 GB at the served precision Kolibri 1.1, 128k: 0.0687 GB at the served precision Kolibri 1.1, 256k: 0.071 GB at the served precision Kolibri 1.1, 512k: 0.0758 GB at the served precision Kolibri 1.1, 1M: 0.0852 GB at the served precision

The Sparse Attention Layer

Rotate your phone for a better viewing experience.

Pick a step, or switch between an indexer and a reindexer layer.

4 groups × 12 query heads group 0 group 1 group 2 group 3 q₁ … q₁₂ 8 sinks (4 drawn) KV cache: tokens open to selection, in blocks of 16 (8 drawn per block) last 128 head 0 head 1 head 2 head 3 1 Coarse indexer layers only Indexer ReLU(q · k‾block) mean over the 12 heads k‾block mean of 16 head-0 keys (8 drawn) score 2 Fine Indexer Reindexer ReLU(q · k) mean over the 12 heads k head-0 keys of the pool tokens (8 drawn per block) score 3 Gather Attention softmax(q kᵀ) v all 48 heads output o head 0 head 1 head 2 head 3 keys and values of all 4 key-value heads 8 sinks + 2,048 tokens + 128 last tokens = 2,184 tokens attended pool top 1,024 blocks selected = 16,384 tokens from the indexer selected top 2,048 tokens selected out of 16,384 q₁ … q₁₂ q₁ … q₁₂ q₁ … q₄₈
4 groups × 12 query heads group 0 group 1 group 2 group 3 q₁ … q₁₂ 8 sinks (4 drawn) KV cache: tokens open to selection, in blocks of 16 (8 drawn per block) last 128 head 0 head 1 head 2 head 3 1 Coarse indexer layers only Indexer ReLU(q · k‾block) mean over the 12 heads k‾block mean of 16 head-0 keys (8 drawn) score 2 Fine Indexer Reindexer ReLU(q · k) mean over the 12 heads k head-0 keys of the pool tokens (8 drawn per block) score 3 Gather Attention softmax(q kᵀ) v all 48 heads output o head 0 head 1 head 2 head 3 keys and values of all 4 key-value heads 8 sinks + 2,048 tokens + 128 last tokens = 2,184 tokens attended pool top 1,024 blocks selected = 16,384 tokens from the indexer selected top 2,048 tokens selected out of 16,384 q₁ … q₁₂ q₁ … q₁₂ q₁ … q₄₈
  • value over key of one key-value head
  • 8 sink tokens
  • 128 most recent tokens
  • selected tokens
  • used by the tied indexer: group-0 queries, head-0 keys
  • token position in the pool or the selection
  • what a step reads

Tied Indexer

sj=1H∑h=1HReLU⁡(qh⋅kj)s_j = \frac{1}{H} \sum_{h=1}^{H} \operatorname{ReLU}\big(q_h \cdot k_j\big)

Hierarchical Selection

  • No compression
  • Keys compressed 8×
  • Keys compressed 16×

Selection time of one indexer layer

µs per decode step at batch 64

0 200 400 600 800 1k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) No compression, 8k: 21.5 µs per decode step at batch 64 No compression, 16k: 27.6 µs per decode step at batch 64 No compression, 32k: 48.9 µs per decode step at batch 64 No compression, 64k: 75 µs per decode step at batch 64 No compression, 128k: 125 µs per decode step at batch 64 No compression, 256k: 226 µs per decode step at batch 64 No compression, 512k: 411 µs per decode step at batch 64 No compression, 1M: 784 µs per decode step at batch 64 Keys compressed 8×, 8k: 32.7 µs per decode step at batch 64 Keys compressed 8×, 16k: 36 µs per decode step at batch 64 Keys compressed 8×, 32k: 49.8 µs per decode step at batch 64 Keys compressed 8×, 64k: 54.9 µs per decode step at batch 64 Keys compressed 8×, 128k: 63.8 µs per decode step at batch 64 Keys compressed 8×, 256k: 82.8 µs per decode step at batch 64 Keys compressed 8×, 512k: 132 µs per decode step at batch 64 Keys compressed 8×, 1M: 428 µs per decode step at batch 64 Keys compressed 16×, 8k: 33.2 µs per decode step at batch 64 Keys compressed 16×, 16k: 35.8 µs per decode step at batch 64 Keys compressed 16×, 32k: 47.9 µs per decode step at batch 64 Keys compressed 16×, 64k: 50.7 µs per decode step at batch 64 Keys compressed 16×, 128k: 55.9 µs per decode step at batch 64 Keys compressed 16×, 256k: 64.4 µs per decode step at batch 64 Keys compressed 16×, 512k: 84.7 µs per decode step at batch 64 Keys compressed 16×, 1M: 128 µs per decode step at batch 64 0.6× 0.8× 1.0× 1.5× 2.2× 3.5× 4.9× 6.1× 0 200 400 600 800 1k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) No compression, 8k: 21.5 µs per decode step at batch 64 No compression, 16k: 27.6 µs per decode step at batch 64 No compression, 32k: 48.9 µs per decode step at batch 64 No compression, 64k: 75 µs per decode step at batch 64 No compression, 128k: 125 µs per decode step at batch 64 No compression, 256k: 226 µs per decode step at batch 64 No compression, 512k: 411 µs per decode step at batch 64 No compression, 1M: 784 µs per decode step at batch 64 Keys compressed 8×, 8k: 32.7 µs per decode step at batch 64 Keys compressed 8×, 16k: 36 µs per decode step at batch 64 Keys compressed 8×, 32k: 49.8 µs per decode step at batch 64 Keys compressed 8×, 64k: 54.9 µs per decode step at batch 64 Keys compressed 8×, 128k: 63.8 µs per decode step at batch 64 Keys compressed 8×, 256k: 82.8 µs per decode step at batch 64 Keys compressed 8×, 512k: 132 µs per decode step at batch 64 Keys compressed 8×, 1M: 428 µs per decode step at batch 64 Keys compressed 16×, 8k: 33.2 µs per decode step at batch 64 Keys compressed 16×, 16k: 35.8 µs per decode step at batch 64 Keys compressed 16×, 32k: 47.9 µs per decode step at batch 64 Keys compressed 16×, 64k: 50.7 µs per decode step at batch 64 Keys compressed 16×, 128k: 55.9 µs per decode step at batch 64 Keys compressed 16×, 256k: 64.4 µs per decode step at batch 64 Keys compressed 16×, 512k: 84.7 µs per decode step at batch 64 Keys compressed 16×, 1M: 128 µs per decode step at batch 64 0.6× 0.8× 1.0× 1.5× 2.2× 3.5× 4.9× 6.1× 0 200 400 600 800 1k 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) No compression, 8k: 21.5 µs per decode step at batch 64 No compression, 16k: 27.6 µs per decode step at batch 64 No compression, 32k: 48.9 µs per decode step at batch 64 No compression, 64k: 75 µs per decode step at batch 64 No compression, 128k: 125 µs per decode step at batch 64 No compression, 256k: 226 µs per decode step at batch 64 No compression, 512k: 411 µs per decode step at batch 64 No compression, 1M: 784 µs per decode step at batch 64 Keys compressed 8×, 8k: 32.7 µs per decode step at batch 64 Keys compressed 8×, 16k: 36 µs per decode step at batch 64 Keys compressed 8×, 32k: 49.8 µs per decode step at batch 64 Keys compressed 8×, 64k: 54.9 µs per decode step at batch 64 Keys compressed 8×, 128k: 63.8 µs per decode step at batch 64 Keys compressed 8×, 256k: 82.8 µs per decode step at batch 64 Keys compressed 8×, 512k: 132 µs per decode step at batch 64 Keys compressed 8×, 1M: 428 µs per decode step at batch 64 Keys compressed 16×, 8k: 33.2 µs per decode step at batch 64 Keys compressed 16×, 16k: 35.8 µs per decode step at batch 64 Keys compressed 16×, 32k: 47.9 µs per decode step at batch 64 Keys compressed 16×, 64k: 50.7 µs per decode step at batch 64 Keys compressed 16×, 128k: 55.9 µs per decode step at batch 64 Keys compressed 16×, 256k: 64.4 µs per decode step at batch 64 Keys compressed 16×, 512k: 84.7 µs per decode step at batch 64 Keys compressed 16×, 1M: 128 µs per decode step at batch 64 0.6× 0.8× 1.0× 1.5× 2.2× 3.5× 4.9× 6.1×

Softmax Attention

Attention time per decode step

ms, summed over all layers

  • Coarse selection
  • Fine selection
  • Softmax attention over selected tokens
  • Sliding-window attention
0 0.5 1 1.5 2 Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.37 ms, Fine selection: 0.30 ms, Coarse selection: 0.00 ms, 1.20 8k Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.00 ms, 1.24 16k Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.07 ms, 1.31 32k Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.08 ms, 1.32 64k Sliding-window attention: 0.54 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.09 ms, 1.34 128k Sliding-window attention: 0.54 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.34 ms, Coarse selection: 0.13 ms, 1.38 256k Sliding-window attention: 0.55 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.34 ms, Coarse selection: 0.21 ms, 1.47 512k Sliding-window attention: 0.56 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.34 ms, Coarse selection: 0.38 ms, 1.66 1M Context length (tokens) 0 0.5 1 1.5 2 Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.37 ms, Fine selection: 0.30 ms, Coarse selection: 0.00 ms, 1.20 8k Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.00 ms, 1.24 16k Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.07 ms, 1.31 32k Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.08 ms, 1.32 64k Sliding-window attention: 0.54 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.09 ms, 1.34 128k Sliding-window attention: 0.54 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.34 ms, Coarse selection: 0.13 ms, 1.38 256k Sliding-window attention: 0.55 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.34 ms, Coarse selection: 0.21 ms, 1.47 512k Sliding-window attention: 0.56 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.34 ms, Coarse selection: 0.38 ms, 1.66 1M Context length (tokens) 0 0.5 1 1.5 2 Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.37 ms, Fine selection: 0.30 ms, Coarse selection: 0.00 ms, 1.20 8k Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.00 ms, 1.24 16k Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.07 ms, 1.31 32k Sliding-window attention: 0.53 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.08 ms, 1.32 64k Sliding-window attention: 0.54 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.33 ms, Coarse selection: 0.09 ms, 1.34 128k Sliding-window attention: 0.54 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.34 ms, Coarse selection: 0.13 ms, 1.38 256k Sliding-window attention: 0.55 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.34 ms, Coarse selection: 0.21 ms, 1.47 512k Sliding-window attention: 0.56 ms, Softmax attention over selected tokens: 0.38 ms, Fine selection: 0.34 ms, Coarse selection: 0.38 ms, 1.66 1M Context length (tokens)

Indexer and Reindexer Placement

  • Indexer: coarse and fine selection
  • Reindexer: fine selection only
  • Softmax attention of the same layer, for scale

Selection time of one sparse layer

µs per decode step at batch 64

0 50 100 150 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Indexer: coarse and fine selection, 8k: 35.1 µs per decode step at batch 64 Indexer: coarse and fine selection, 16k: 37.5 µs per decode step at batch 64 Indexer: coarse and fine selection, 32k: 49.3 µs per decode step at batch 64 Indexer: coarse and fine selection, 64k: 51.9 µs per decode step at batch 64 Indexer: coarse and fine selection, 128k: 55.9 µs per decode step at batch 64 Indexer: coarse and fine selection, 256k: 66.1 µs per decode step at batch 64 Indexer: coarse and fine selection, 512k: 86.4 µs per decode step at batch 64 Indexer: coarse and fine selection, 1M: 129 µs per decode step at batch 64 Reindexer: fine selection only, 8k: 30.1 µs per decode step at batch 64 Reindexer: fine selection only, 16k: 32.8 µs per decode step at batch 64 Reindexer: fine selection only, 32k: 32.9 µs per decode step at batch 64 Reindexer: fine selection only, 64k: 33 µs per decode step at batch 64 Reindexer: fine selection only, 128k: 33.3 µs per decode step at batch 64 Reindexer: fine selection only, 256k: 33.8 µs per decode step at batch 64 Reindexer: fine selection only, 512k: 34.1 µs per decode step at batch 64 Reindexer: fine selection only, 1M: 33.9 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 8k: 36.8 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 16k: 37.8 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 32k: 37.9 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 64k: 38 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 128k: 37.7 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 256k: 37.7 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 512k: 37.7 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 1M: 37.9 µs per decode step at batch 64 1.2× 1.1× 1.5× 1.6× 1.7× 2.0× 2.5× 3.8× 0 50 100 150 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Indexer: coarse and fine selection, 8k: 35.1 µs per decode step at batch 64 Indexer: coarse and fine selection, 16k: 37.5 µs per decode step at batch 64 Indexer: coarse and fine selection, 32k: 49.3 µs per decode step at batch 64 Indexer: coarse and fine selection, 64k: 51.9 µs per decode step at batch 64 Indexer: coarse and fine selection, 128k: 55.9 µs per decode step at batch 64 Indexer: coarse and fine selection, 256k: 66.1 µs per decode step at batch 64 Indexer: coarse and fine selection, 512k: 86.4 µs per decode step at batch 64 Indexer: coarse and fine selection, 1M: 129 µs per decode step at batch 64 Reindexer: fine selection only, 8k: 30.1 µs per decode step at batch 64 Reindexer: fine selection only, 16k: 32.8 µs per decode step at batch 64 Reindexer: fine selection only, 32k: 32.9 µs per decode step at batch 64 Reindexer: fine selection only, 64k: 33 µs per decode step at batch 64 Reindexer: fine selection only, 128k: 33.3 µs per decode step at batch 64 Reindexer: fine selection only, 256k: 33.8 µs per decode step at batch 64 Reindexer: fine selection only, 512k: 34.1 µs per decode step at batch 64 Reindexer: fine selection only, 1M: 33.9 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 8k: 36.8 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 16k: 37.8 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 32k: 37.9 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 64k: 38 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 128k: 37.7 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 256k: 37.7 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 512k: 37.7 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 1M: 37.9 µs per decode step at batch 64 1.2× 1.1× 1.5× 1.6× 1.7× 2.0× 2.5× 3.8× 0 50 100 150 8k 16k 32k 64k 128k 256k 512k 1M Context length (tokens) Indexer: coarse and fine selection, 8k: 35.1 µs per decode step at batch 64 Indexer: coarse and fine selection, 16k: 37.5 µs per decode step at batch 64 Indexer: coarse and fine selection, 32k: 49.3 µs per decode step at batch 64 Indexer: coarse and fine selection, 64k: 51.9 µs per decode step at batch 64 Indexer: coarse and fine selection, 128k: 55.9 µs per decode step at batch 64 Indexer: coarse and fine selection, 256k: 66.1 µs per decode step at batch 64 Indexer: coarse and fine selection, 512k: 86.4 µs per decode step at batch 64 Indexer: coarse and fine selection, 1M: 129 µs per decode step at batch 64 Reindexer: fine selection only, 8k: 30.1 µs per decode step at batch 64 Reindexer: fine selection only, 16k: 32.8 µs per decode step at batch 64 Reindexer: fine selection only, 32k: 32.9 µs per decode step at batch 64 Reindexer: fine selection only, 64k: 33 µs per decode step at batch 64 Reindexer: fine selection only, 128k: 33.3 µs per decode step at batch 64 Reindexer: fine selection only, 256k: 33.8 µs per decode step at batch 64 Reindexer: fine selection only, 512k: 34.1 µs per decode step at batch 64 Reindexer: fine selection only, 1M: 33.9 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 8k: 36.8 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 16k: 37.8 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 32k: 37.9 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 64k: 38 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 128k: 37.7 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 256k: 37.7 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 512k: 37.7 µs per decode step at batch 64 Softmax attention of the same layer, for scale, 1M: 37.9 µs per decode step at batch 64 1.2× 1.1× 1.5× 1.6× 1.7× 2.0× 2.5× 3.8×

Rotate your phone for a better viewing experience.

prefill: layers 1–30 build every full-length cache layers 31–50 add no full-length cache Selection: an indexer hands its pool to the reindexers of its group group 1 group 2 group 3 group 4 5 10 15 20 25 30 35 40 45 50 KV cache: producers keep the full context, consumers read a producer’s cache L 513 0 5 10 15 20 25 30 35 40 45 50
  • sliding window (513 tokens, BF16)
  • indexer
  • reindexer
  • pool
  • producer (all tokens, NVFP4)
  • consumer
  • cache read by a consumer

Hover or tap a sparse layer to see its group and its cache source.

KV Cache Size

  • Full-length caches and indexer keys
  • Sliding-window cache

16k tokens

GB per sequence

0 0.05 0.1 0.15 0.2 0.25 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.17 GB 0.21 Kolibri 1 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.11 GB 0.15 + NVFP4 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.04 GB 0.08 + sharing = Kolibri 1.1 0 0.05 0.1 0.15 0.2 0.25 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.17 GB 0.21 Kolibri 1 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.11 GB 0.15 + NVFP4 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.04 GB 0.08 + sharing = Kolibri 1.1 0 0.05 0.1 0.15 0.2 0.25 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.17 GB 0.21 Kolibri 1 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.11 GB 0.15 + NVFP4 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.04 GB 0.08 + sharing = Kolibri 1.1

128k tokens

GB per sequence

0 0.5 1 1.5 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 1.34 GB 1.38 Kolibri 1 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.85 GB 0.89 + NVFP4 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.34 GB 0.38 + sharing = Kolibri 1.1 0 0.5 1 1.5 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 1.34 GB 1.38 Kolibri 1 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.85 GB 0.89 + NVFP4 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.34 GB 0.38 + sharing = Kolibri 1.1 0 0.5 1 1.5 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 1.34 GB 1.38 Kolibri 1 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.85 GB 0.89 + NVFP4 Sliding-window cache: 0.04 GB Full-length caches and indexer keys: 0.34 GB 0.38 + sharing = Kolibri 1.1

1M tokens

GB per sequence

0 5 10 15 Sliding-window cache: 0.0 GB Full-length caches and indexer keys: 10.7 GB 10.8 Kolibri 1 Sliding-window cache: 0.0 GB Full-length caches and indexer keys: 6.8 GB 6.9 + NVFP4 Sliding-window cache: 0.0 GB Full-length caches and indexer keys: 2.7 GB 2.8 + sharing = Kolibri 1.1 0 5 10 15 Sliding-window cache: 0.0 GB Full-length caches and indexer keys: 10.7 GB 10.8 Kolibri 1 Sliding-window cache: 0.0 GB Full-length caches and indexer keys: 6.8 GB 6.9 + NVFP4 Sliding-window cache: 0.0 GB Full-length caches and indexer keys: 2.7 GB 2.8 + sharing = Kolibri 1.1 0 5 10 15 Sliding-window cache: 0.0 GB Full-length caches and indexer keys: 10.7 GB 10.8 Kolibri 1 Sliding-window cache: 0.0 GB Full-length caches and indexer keys: 6.8 GB 6.9 + NVFP4 Sliding-window cache: 0.0 GB Full-length caches and indexer keys: 2.7 GB 2.8 + sharing = Kolibri 1.1

Continued Pre-Training

  • Continued mid-training, phase 1, batch 100.7M tokens, context 64k
  • Continued mid-training, phase 2, batch 100.7M tokens, context 192k
  • Long-context stage, batch 201.3M tokens, context 256k
0.90 0.95 1.00 1.05 1.10 1.15 1.20 0 200B 400B 600B 800B 1000B Tokens Training loss 0.90 0.95 1.00 1.05 1.10 1.15 1.20 0 200B 400B 600B 800B 1000B Tokens Training loss Continued mid-training, phase 1 batch 100.7M tokens context 64k Continued mid-training, phase 2 batch 100.7M tokens context 192k Long-context stage batch 201.3M tokens context 256k 0.90 0.95 1.00 1.05 1.10 1.15 1.20 0 200B 400B 600B 800B 1000B Tokens Training loss Continued mid-training, phase 1 batch 100.7M tokens context 64k Continued mid-training, phase 2 batch 100.7M tokens context 192k Long-context stage batch 201.3M tokens context 256k

Appendix

Initialisation for KV Sharing

ℓj=q⊤kj=xq⊤(Q⊤K) xj,α=softmax⁡(ℓ)\ell_j = q^\top k_j = x_q^\top (Q^\top K)\, x_j, \qquad \alpha = \operatorname{softmax}(\ell)
O∑jαjvj=(OV)∑jαjxjO \sum_j \alpha_j v_j = (O V) \sum_j \alpha_j x_j
Q⊤K=Q⊤R⊤R K=(RQ)⊤(RK)Q^\top K = Q^\top R^\top R\,K = (RQ)^\top (RK)
Rm=arg⁡min⁡R⊤R=I∥RKm−Kˉ∥FR_m = \arg\min_{R^\top R = I} \lVert R K_m - \bar{K} \rVert_F
Kˉ←1∣M∣∑m∈MRmKm\bar{K} \leftarrow \frac{1}{|M|}\sum_{m \in M} R_m K_m
Qm⊤Km=(RmQm)⊤(RmKm)≈(RmQm⏟new Qm)⊤KˉQ_m^\top K_m = (R_m Q_m)^\top (R_m K_m) \approx \big(\underbrace{R_m Q_m}_{\text{new } Q_m}\big)^\top \bar{K}

Rotate your phone for a better viewing experience.

logit in layer m\text{logit in layer } m
=x⊤Qm⊤Km x′{} = x^\top Q_m^\top K_m\,x'
=x⊤(Rm Qm) ⁣⊤(Rm Km) x′{} = x^\top \big(\htmlClass{map}{R_m}\,Q_m\big)^{\!\top} \big(\htmlClass{map}{R_m}\,K_m\big)\,x'
≈x⊤(Rm Qm) ⁣⊤Kˉ x′{} \approx x^\top \big(\htmlClass{map}{R_m}\,Q_m\big)^{\!\top} \bar{K}\,x'
a layer’s own keykey in the shared cachequeryProducercachesharedConsumer 1cacheConsumer 2cache12345q1234512345q1234512345q12345logit of the query for each key, dashed: original
a layer’s own keykey in the shared cachequeryProducercachesharedConsumer 1cacheConsumer 2cache12345q1234512345q1234512345q12345logit of the query for each key, dashed: original

Step 1 of 3: original

Before sharing: the keys of five tokens and one query in the key space of each layer, with the logits of that query below.

OV=O (CV′)=(OC) V′O V = O\,(C V') = (O C)\,V'
P=arg⁡min⁡P2=P=P⊤rank⁡P=n∑m∈M∑h∥Om,h Vm (I−P)∥F2P = \arg\min_{\substack{P^2 = P = P^\top \\ \operatorname{rank} P = n}} \sum_{m \in M} \sum_h \lVert O_{m,h}\, V_m\, (I - P) \rVert_F^2
Cm=arg⁡min⁡C∥Vm−C Vˉ∥F=VmVˉ⊤(VˉVˉ⊤)−1C_m = \arg\min_{C} \lVert V_m - C\,\bar{V} \rVert_F = V_m \bar{V}^\top \big(\bar{V}\bar{V}^\top\big)^{-1}
Om,hVm≈Om,h (CmVˉ)=(Om,hCm⏟new Om,h) VˉO_{m,h} V_m \approx O_{m,h}\,(C_m \bar{V}) = \big(\underbrace{O_{m,h} C_m}_{\text{new } O_{m,h}}\big)\,\bar{V}

Rotate your phone for a better viewing experience.

output of layer m for a token\text{output of layer } m \text{ for a token}
=Om Vm x{} = O_m\,V_m\,x
≈Om (Cm Vˉ) x{} \approx O_m\,\big(\htmlClass{map}{C_m}\,\bar{V}\big)\,x
=(Om Cm) Vˉ x{} = \big(O_m\,\htmlClass{map}{C_m}\big)\,\bar{V}\,x
a layer’s own valuevalue in the shared cacheoriginal valuebasis of the output matrixProducercachesharedConsumer 1cacheConsumer 2cache123451234512345
a layer’s own valuevalue in the shared cacheoriginal valuebasis of the output matrixProducercachesharedConsumer 1cacheConsumer 2cache123451234512345

Step 1 of 3: original

Before sharing: the values of five tokens in the value space of each layer. The grid is the basis in which the layer’s output matrix reads them, and every layer fills a cache of its own.

Oc∑jαjvj=Oc vˉ+Oc∑jαj (vj−vˉ)O_c \sum_j \alpha_j v_j = O_c\,\bar{v} + O_c \sum_j \alpha_j\,(v_j - \bar{v})

Full Benchmark Results

Base Models

Kolibri 1 Kolibri 1.1
Overall (EN) 81.2 79.7
Overall (DE) 81.5 79.8
Average (EN) 81.3 80.9
Average (DE) 82.7 82.8
Average (EN) 85.1 83.9
Average (DE) 77.0 74.6
Average (EN) 77.1 74.4
Average (DE) 84.8 82.1

Post-Trained Models

Kolibri 1 Kolibri 1.1
Overall (EN) 64.0 72.2
Overall (DE) 69.2 74.2
Average (EN) 35.1 38.3
Average (DE) 48.6 52.1
Average (EN) 70.5 77.4
Average (DE) 89.7 94.6
Average (EN) 61.8 61.0
Average (EN) 63.6 69.5
Average (EN) 63.7 84.6
Average (EN) 78.8 82.7
Average (EN) 58.9 69.6
Average (EN) 64.3 71.2
Average (DE) 72.7 78.5
Average (EN) 84.8 81.8
Average (DE) 65.9 71.4
Average (EN) 63.6 67.7
Average (EN) 58.9 91.0

Citation

@misc{neitemeier2026yasa,
  title        = {{YASA}: How Sparse Attention Made {Kolibri} 1.1 up to 14$\times$ More Efficient},
  author       = {Pit Neitemeier and Fabien C. Y. Benureau and Alessio Serra and Eric Schreiber and Volker Stampa and Sascha Wirges and Steffen Hirschmann},
  year         = {2026},
  howpublished = {Aleph Alpha Research Blog},
  url          = {https://aleph-alpha.com/en/blog/sparse-attention-in-kolibri-1-1/}
}

References