LearnQuestion bank

Several 2025–2026 open models mix linear-attention layers (for example Gated DeltaNet or Kimi Delta Attention) with a minority of full-attention layers. Explain the design, its training and serving trade-offs, and how you would choose the ratio.

ResearchTechnicalHard

Answer it yourself first, out loud or on paper, then compare.

Answer

Model answer, written in a candidate's voice

In short

  • Linear layers keep a fixed-size state updated per token; delta-rule writes with gating decide what to overwrite and forget, giving linear compute and constant memory in sequence length
  • A minority of full softmax-attention layers restores exact retrieval and in-context copying that pure recurrent models do poorly
  • Serving gains: much smaller KV cache and faster long-context decoding (Kimi Linear reports up to 75% less KV cache and up to 6x decoding throughput at 1M context)
  • Costs: specialised kernels, chunked parallel training algorithms, harder prefix caching and speculative decoding because the recurrent state cannot be sliced, and immature engine support
  • Choose the ratio by sweeping at small scale on long-context retrieval (needle, multi-key), in-context learning, and throughput, then confirm the trend at larger scale

In full

The core idea is to spend most layers on cheap linear-attention recurrence and keep a small minority of exact softmax attention. In the linear layers, each token updates a fixed-size state via a delta-rule-style write with gating that decides what to overwrite and forget, so compute grows linearly and memory stays constant in sequence length; the full-attention layers restore exact retrieval and in-context copying that pure recurrent models handle poorly. In serving this shrinks the KV cache and speeds long-context decoding—Kimi Linear reports up to 75% less KV cache and up to 6x decoding throughput at 1M context—but it is not free: you need specialised kernels and chunked parallel training, and prefix caching and speculative decoding get harder because the recurrent state cannot be sliced, with engine support still immature. I would not pick the ratio by intuition; I would sweep it at small scale on long-context retrieval (needle and multi-key), in-context learning, and throughput, then confirm the trend at larger scale before committing. A 3:1 linear-to-full ratio like Qwen3-Next is a reasonable starting point, not a universal answer.

Corrected by an independent AI reviewer.

What a strong answer covers

  • Linear-attention layers keep a fixed-size state updated per token (delta-rule updates with gating decide what to overwrite and forget), so compute is linear and memory is constant in sequence length
  • A minority of full softmax-attention layers (e.g. 3:1 linear to full in Qwen3-Next) restores exact retrieval and in-context copying that pure recurrent models do poorly
  • Serving benefits: much smaller KV cache and faster long-context decoding (Kimi Linear reports up to 75% less KV cache and up to 6× decoding throughput at 1M context)
  • Costs: specialised kernels, chunked parallel training algorithms, harder prefix caching and speculative decoding because the recurrent state cannot be sliced, and immature engine support
  • Choosing the ratio: sweep at small scale on long-context retrieval (needle, multi-key), in-context learning and throughput, then confirm the trend at larger scale

Common mistakes

  • Claiming hybrids have no KV cache at all
  • Judging the design only on short-context benchmarks

Follow-ups

  • Why does the delta rule improve on plain linear attention’s additive state update?