Long-horizon agents share one workload trait: input dwarfs output. A codebase, a stack of documents, dozens of tool-call transcripts crammed into context — prefill compute, KV cache in HBM, SSD capacity and transfer bandwidth all strain at once. DeepSeek's V4.1-Flash technical report, released September 17 (arXiv:2609.19969), is essentially one accounting exercise: how does a 552B model push per-token KV cache overhead down to 890 bytes?
Layer 1: CED asymmetric activation — 8B to read, 16B to answer
V4.1-Flash adopts a Causal Encoder-Decoder (CED) architecture: a 40-layer Transformer organized as a 20-layer causal encoder followed by a 20-layer decoder. The key move: the decoder's global KV cache is projected from the final encoder hidden states rather than derived from each decoder layer's own hidden states. The payoff is immediate — only 8B parameters activate per token during prefill, 16B during decode. For input-heavy, output-light agentic workloads, the savings land exactly on the most expensive segment. The "8B to read, 16B to answer" framing from the September 10 API announcement now has its full architectural justification.
Layer 2: CSA2's three modes plus FP4 — global cache cut to 1/4 of the previous generation
Compressed Sparse Attention 2 (CSA2) assigns each attention layer one of three static modes — Full, Reindex, or Reuse — letting layers share main KV and indexer K while reusing Top-K sparse-attention indices. A Hierarchical Sparse Indexer in the decoder further restricts later indexing layers to a candidate pool built by the first Full-mode layer, bounding deeper indexer cost independently of context length. Layered on top, FP4 main KV caching (E2M1 format, one E4M3 scale per 16 channels) brings the global KV cache footprint to 890 bytes per token — roughly 1/4 of DeepSeek-V4-Flash and 1/437 of V1.
Layer 3: SWA Bounded Replay — persistent cache cut to 1/8
Persistent KV residing on SSD or in host memory is a separate cost. SWA Bounded Replay skips persisting sliding-window-attention KV states entirely; when needed, it reconstructs missing states by replaying only the most recent n_win tokens. The persistent cache footprint drops to roughly 1/8 of V4-Flash.
Components beyond the cache stack
The report also details several notable components: Engram conditional memory (196B parameters, sparsely accessed via token-based lookup); DSpark speculative decoding (semi-autoregressive draft generation with confidence-scheduled verification); and an MoE design of 1 shared expert plus 384 routed experts per layer, activating 6 routed experts per token. Pretraining ran from scratch on a 45T-token multimodal corpus, with sparse attention trained at 64K sequence length and context extended to 1M tokens at the 34T mark. Post-training follows the standard SFT → RL → on-policy distillation (OPD) recipe with no algorithmic changes — the substantive work moved to the data pipeline: large-scale automated synthesis of agent tasks and environments. Inference supports a continuously controllable reasoning-effort setting, an integer scale of 1 to 100.
Officially reported benchmarks: leading on agents, still behind on hard reasoning
Per the model card's benchmarks (evaluated in DeepSeek's internal framework, vendor-reported), at maximum reasoning effort: Terminal-Bench 2.1 at 90.6 (above Opus-5.0's 89.1), DeepSWE v1.1 at 74.2 (above Opus's 74.0), CyberGym 88.1, Agent's Last Exam 31.8, AutomationBench 54.8 — all best in the comparison table; the Codeforces rating of 3471 is also the table's highest. But the gaps are right there in the same table: Terminal-Bench 3.0/4.0 at 30.0/31.2 trail Opus's 43.3/51.8 by a wide margin; HLE 36.8 versus Opus's 56.3; GPQA 90.9 below GPT-5.6 Sol's 94.1. Cheap is not omniscient — a table that publishes its own weak spots alongside the wins carries more information than any single first-place finish.
Artifacts included: even the Rust libraries shipped
The HF repository (MIT license) ships weights plus a prompt-encoding reference implementation, inference code, DeepSWE reproduction steps, and deepseek-recipe — a set of Rust libraries with Python bindings that uniformly handles prompt encoding and decoding for V4 and V4.1. The community has already followed with 73 quantized variants and 14 fine-tunes. Notably, no Jinja chat template is provided this time; the encoding toolchain is self-maintained instead — a hint that the new architecture's prompt-format complexity may have outgrown generic templating.
The three-layer cache design doesn't shrink the model; it redesigns how context is stored. As agents treat million-token contexts as routine configuration, the HBM-and-SSD ledger will land on every inference team's desk sooner or later. The reference frame this report offers: asymmetric activation at the architecture layer, cross-layer sharing at the attention layer, and lossy reconstruction at the deployment layer — three moves that stack, and that are open to verify.