The Rabbit Hole / AI / Model architectures
IBM · Architecture map Granite-SWASH 3B-A600M A small mixture of experts where 20 of 28 layers see only the last 128 tokens, and every attention head has a learnable sink.
Granite-SWASH-3B-a600M (base model), July 2026 · Granite release timeline
Architecture map What to notice Component articles Compare with another model Sources Inside Granite-SWASH 3B-A600M
Parameters 3.02B · 0.6B active
Layers 28
Width 1,280
Mixer Grouped-query Select a component to explore it. Layer colours match the execution-order strip. Inside grouped-query attention · Full-attention layers 1, 4, 8, 12, 16, 20, 24 and 28 5 query heads per group × 4 K/V groups. Earlier context dimmed · current token bright · dashed regions contain cached entries.
Granite-SWASH 3B-A600M: Full-attention layers 1, 4, 8, 12, 16, 20, 24 and 28 · grouped-query attention 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Full layers store keys and values for 4 heads of size 64 per token. Sliding-window layers store only the last 128 tokens. 4 KV groups; the front face shows one representative. 4 KV groups 5 heads / group; the front face shows one representative. 5 heads / group Attention input. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Earlier context is dimmed; outlined columns are current. Current token computation. Attention input 1,280 CL Wq. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Wq 1,280 64 Wk. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Wk 1,280 64 Wv. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Wv 1,280 64 RoPE. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. RoPE RoPE. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. RoPE K cache. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Earlier columns are cached; outlined columns are newly computed. Cached positions from earlier decoding steps. Current token computation. K cache 64 CL V cache. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Earlier columns are cached; outlined columns are newly computed. Cached positions from earlier decoding steps. Current token computation. V cache 64 CL Q context. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Earlier context is dimmed; outlined columns are current. Current token computation. Q context 64 CL Scaled query–key scores, masking and softmax. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Sink CL CL ×. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. × Joined heads. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. 20 Wo. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Wo 1,280 1,280 Attention output. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Earlier context is dimmed; outlined columns are current. Current token computation. Attention output 1,280 CL Inside grouped-query attention · Sliding-window layers (the other 20) 5 query heads per group × 4 K/V groups. Earlier context dimmed · current token bright · dashed regions contain cached entries.
Granite-SWASH 3B-A600M: Sliding-window layers (the other 20) · grouped-query attention 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Full layers store keys and values for 4 heads of size 64 per token. Sliding-window layers store only the last 128 tokens. 4 KV groups; the front face shows one representative. 4 KV groups 5 heads / group; the front face shows one representative. 5 heads / group Attention input. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Earlier context is dimmed; outlined columns are current. Current token computation. Attention input 1,280 CL Wq. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Wq 1,280 64 Wk. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Wk 1,280 64 Wv. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Wv 1,280 64 RoPE. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. RoPE RoPE. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. RoPE K cache. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Earlier columns are cached; outlined columns are newly computed. Cached positions from earlier decoding steps. Current token computation. K cache 64 ≤ 128 V cache. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Earlier columns are cached; outlined columns are newly computed. Cached positions from earlier decoding steps. Current token computation. V cache 64 ≤ 128 Q context. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Earlier context is dimmed; outlined columns are current. Current token computation. Q context 64 CL Scaled query–key scores, masking and softmax. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Window 128 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Sink CL CL ×. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. × Joined heads. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. 20 Wo. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Wo 1,280 1,280 Attention output. 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Earlier context is dimmed; outlined columns are current. Current token computation. Attention output 1,280 CL Model-specific details Full-attention layers 1, 4, 8, 12, 16, 20, 24 and 28 · 8 repetitions Attention over the whole sequence, then 48 routed experts (size 512), 4 chosen per token, plus a shared expert of size 1280. Sliding-window layers (the other 20) · 20 repetitions Attention over the last 128 tokens, then the same expert block. Attention and positions 20 query heads share 4 key/value heads of size 64. 20 layers use sliding-window attention over the last 128 tokens; 8 layers (1, 4, 8, 12, 16, 20, 24 and 28) attend to the whole sequence. Every head in every layer has one learnable sink value. Memory Full layers store keys and values for 4 heads of size 64 per token. Sliding-window layers store only the last 128 tokens. Short windows and small experts
Twenty of 28 layers use a 128-token window; eight are global.
Every head has a learned attention sink, including in local layers.
Each layer selects four of 48 experts of width 512, plus one shared expert of width 1,280.
Input/output embeddings are tied; the context is 8,192 tokens.
This is the July 2026 3B-A600M base checkpoint. The dense 2B SWASH model uses a different feed-forward layout.
Explore the components Sources for this map