Skip to content

DAG-KV

Position-Decoupled Graph KV Cache with Query-Side Adjoint RoPE, LSE-Bounded Submodular Bridge Repair, and Fused Quantized Triton Kernels.

Standard prefix caching (vLLM Automatic Prefix Caching, SGLang RadixAttention) collapses to a 0% cache hit rate whenever documents, RAG passages, or repository source files are reordered. DAG-KV renders physical Key-Value blocks 100% read-only and globally shareable across arbitrary permutations while cutting decode latency, suffix prefill latency, and KV VRAM footprints dramatically.

Key Capabilities (v0.7.0)

  • 100% Order-Invariant KV Reuse & Live 3-Way Engine Head-to-Head: Query-Side Adjoint RoPE applies \(\mathcal{R}(-\Delta_b)\) to queries in SRAM registers without mutating HBM. On NVIDIA H200 NVL (141 GB), DAG-KV beats live vLLM 0.34.0 APC by 4.77× (9.2K) and 4.00× (18.5K) and beats live SGLang 1.0.0 RadixAttention by 4.29× (9.2K) and 3.42× (18.5K) on Qwen2.5-14B (3/3 EM), while matching SGLang within 0.47 ms on 18.5K same-order prefix hits (25.04 ms vs. 24.57 ms).
  • Standardized LongBench (N=111) vs. CacheBlend HKVD 15%: Across real HotpotQA, 2WikiMultihopQA, MuSiQue, and RepoBench-P on Qwen2.5-14B (K8V4), DAG-KV (4% → 1.5%) achieves 40.70 macro avg — outperforming CacheBlend-15% (40.36) at 2.10× lower TTFT (88.3 ms vs. 185.7 ms; up to 3.70× on MuSiQue) and 4.65× faster than Dense Oracle (410.3 ms; up to 10.06×).
  • 32B-Class Native FP8, K8V4 & 64K GQA-SplitKV Triton Kernels: Verified across Turing RTX 2080 Ti (sm_75), Hopper H200 NVL (sm_90), and Blackwell RTX PRO 6000 (sm_120) — scales Qwen2.5-32B-Instruct Native FP8 up to 33.8K at 10.03× (8.4K) / 7.00× (33.8K, 3/3 EM), Qwen2.5-14B to 36.8K at 5.15× (71.6× bypass), and Blackwell 64K GQA-SplitKV K8V4 prefill in 33.27 ms (1.44× faster than FP16).
  • Real DeepSeek-V2-Lite-Chat Absorbed MLA Engine (DeepSeekMLADAGKVEngine): Counter-rotates only the decoupled RoPE slice \(q_R\) while leaving compressed latents \(c_{KV}\) untouched with Latent-Space Query-Guided CoW Bridge Repair — 8.89× KV VRAM compression, 3/3 (100%) EM on permuted 6-doc RAG (vs 1/3 isolated), 8.48× faster prefill at 32.0K, and 107×–152.5× Triton MLA decode speedup.
  • Prompt-Lookup Speculative Decoding, Batched Ragged Prefill & CUDA Graphs: Zero-VRAM lossless speculative decoding reaches 352.1 tok/s (5.04×, 14B) and 242.0 tok/s (6.50×, 32B) on H200; batched ragged prefill (B=8) runs 4.39×–5.66× faster; static CUDA Graph decode runs 1.51×–2.17× faster (0.000000 diff).
  • Live 100GbE RoCE Direct RDMA & Multi-Language AST-Delta Caching: Re-prefills only edited functions/classes (92.7% token reuse), spills lazily to NVMe (SCHEMA_VERSION=1.0), and transfers KV blocks directly GPU-to-GPU from Hopper H200 → Blackwell RTX PRO 6000 over 100GbE RoCE (bnxt_re0) at 10.44 GB/s (83.50 Gbps, 107× faster than HTTP, bit-exact).
  • Ecosystem Native (vLLM v1 Verified on Live H200 GPU): Zero-fork vLLM v0 & v1 (KVConnectorBase_V1 + v1.attention.backend, 0.0 roundtrip max diff on vLLM 0.34.0), Hugging Face, LangChain, LlamaIndex, OpenTelemetry, Apple MLX, and MCP (dag-kv mcp).
pip install dag-kv
dag-kv info