Video World Models · 2026-11-30

ZenAttention: 4-bit Attention Directly on a Quantized KV Cache for Streaming Video Diffusion

Yingwei Song, Tony Zhu, Kelly Peng, Yuan Gao, Huanrui Yang

arXiv:2611.35314PDFCode

AI-assisted summary based on the paper. Consult the linked source for methods and limitations. Benchmark numbers appear after editor verification.

TL;DR

ZenAttention computes streaming video diffusion attention directly on a write-once NVFP4 KV cache. The authors trace quality loss of 4-bit attention on a cache to biased FP4 error that feeds back through the cache and extra sensitivity of the newest cached frame. ZenAttention adds closed-form bias corrections and an 8-bit newest-frame tier, reporting up to 1.89× faster denoising than bf16 and latent detail within 0.7% of bf16 across eight models, with code release.

Why it matters

Streaming video diffusion spends much of denoising time on KV-cache self-attention. The authors target making both cache storage and attention computation low-bit without retraining, aiming to reduce memory/compute while preserving latent detail. They also diagnose why naive 4-bit attention on cached history degrades quality, and propose mechanisms (bias corrections + an 8-bit newest-frame tier) meant to maintain fidelity during autoregressive streaming rollouts.

Method

  • Adds closed-form bias corrections for NVFP4 attention error (one fused multiply-add per score) via a mean/residual split, score rescaling, variance correction, and fixed dithered rounding.
  • Uses an 8-bit tier for the newest cached frame (current chunk + newest cached frame), sharing a single online softmax with the 4-bit tier.
  • Implements attention directly over a write-once NVFP4 KV cache via a compiled Blackwell CUDA kernel (no retraining across evaluated models).

Limitation

The paper states scope of applicability differences: some models use linear attention or have no KV cache, and some setups require partial cache updates (e.g., Context Forcing) or cache reading fewer times, which may affect how directly the approach applies.

Abstract (from arXiv)

In long-video generation, streaming video diffusion models spend up to 58% of denoising time attending to a key-value (KV) cache of past frames at every step. Keeping both the cache and the attention computation in 4-bit precision would save substantial memory and time, yet existing methods achieve only one of the two: FP4 attention requantizes a bf16 cache at every call and loses 4-28% of high-frequency latent detail in streaming rollouts, whereas 4-bit KV caches dequantize back to bf16 before attention. We trace the quality drop of 4-bit attention on a cache to two causes: FP4 attention error is systematically biased and fed back through the cache, amplifying single-chunk loss roughly 3x on Self-Forcing; and the newest cached frame requires more precise attention scores than older history. ZenAttention addresses each cause with one component -- closed-form bias corrections costing one fused multiply-add per score and an 8-bit tier for the newest frame -- and computes attention directly on a write-once NVFP4 KV cache. ZenAttention is fast: 628 effective TOPS on an RTX 5090 (1.45x SageAttention2++), 2.6-3.5x faster self-attention than bf16 (1.23-1.50x SageAttention2++, faster than 8-bit and 4-bit SageAttention), and up to 1.89x faster denoising than bf16 (1.84x over LongLive 2.0's 4-bit release); general: one kernel runs without retraining across eight streaming video and world models (1.3B-5B); small: KV-cache memory drops by two-thirds (33-35% of bf16); and faithful: latent detail stays within 0.7% of bf16 across all eight models (vs. 4-28% lost by SageAttention3), while VBench matches bf16 on Self-Forcing (946 prompts) and LongLive-2.0-5B (VBench-Long). Code: https://github.com/wrencanfly/ZenAttention

Related papers

Publication record

Bibliographic evidence describes where and when a record appeared. It does not validate scientific claims.

First announced by arXiv: 2026-11-30 · Indexed by Pub-AI: 2026-11-30 UTC

preprint

ZenAttention: 4-bit Attention Directly on a Quantized KV Cache for Streaming Video Diffusion

Yingwei Song, Tony Zhu, Kelly Peng, Yuan Gao, Huanrui Yang

First announced by arXiv: 2026-11-30 · Original record ↗

arxiv
2611.35314
Explicit source versions (1)
  • v1 · Date not supplied
  1. Preprint available

    Source date: 2026-11-30 · First detected: 2026-11-30 UTC · Historical baseline

    Source evidence (1)
    • Official evidence ↗ · RSS guid=oai:arXiv.org:2611.35314v1; arxiv:announce_type=new; item pubDate (official metadata)
Abstract · arxiv

In long-video generation, streaming video diffusion models spend up to 58% of denoising time attending to a key-value (KV) cache of past frames at every step. Keeping both the cache and the attention computation in 4-bit precision would save substantial memory and time, yet existing methods achieve only one of the two: FP4 attention requantizes a bf16 cache at every call and loses 4-28% of high-frequency latent detail in streaming rollouts, whereas 4-bit KV caches dequantize back to bf16 before attention. We trace the quality drop of 4-bit attention on a cache to two causes: FP4 attention error is systematically biased and fed back through the cache, amplifying single-chunk loss roughly 3x on Self-Forcing; and the newest cached frame requires more precise attention scores than older history. ZenAttention addresses each cause with one component -- closed-form bias corrections costing one fused multiply-add per score and an 8-bit tier for the newest frame -- and computes attention directly on a write-once NVFP4 KV cache. ZenAttention is fast: 628 effective TOPS on an RTX 5090 (1.45x SageAttention2++), 2.6-3.5x faster self-attention than bf16 (1.23-1.50x SageAttention2++, faster than 8-bit and 4-bit SageAttention), and up to 1.89x faster denoising than bf16 (1.84x over LongLive 2.0's 4-bit release); general: one kernel runs without retraining across eight streaming video and world models (1.3B-5B); small: KV-cache memory drops by two-thirds (33-35% of bf16); and faithful: latent detail stays within 0.7% of bf16 across all eight models (vs. 4-28% lost by SageAttention3), while VBench matches bf16 on Self-Forcing (946 prompts) and LongLive-2.0-5B (VBench-Long). Code: https://github.com/wrencanfly/ZenAttention