DeepSeek-V4.1-Flash

DeepSeek

Parameters

763.0B total / 16.0B active

MoE: total / active

Architecture

MoE

Released

10.09.2026

License

MIT License

Open Weights Commercial Use Multimodal BF16, F32, F8_E4M3, I8 DeepSeek en zh

Input Modalities

text image

Output Modalities

text

Context (native)

1,000,000 tokens

Context (extended)

1,000,000 tokens

Openness Index Score 100.0/100

About

DeepSeek-V4.1-Flash is DeepSeek's MIT-licensed multimodal Mixture-of-Experts model with 552B backbone parameters (763B total) and a 1M-token context window. Maintained by DeepSeek, it natively processes images and text (DeepSeek-ViT vision encoder plus a two-layer MLP projector) and generates text autoregressively, with English and Chinese as primary languages.

Its defining novelty is extreme KV-cache compression for agentic workloads: the global KV cache shrinks to 890 bytes per token — roughly 1/4 of DeepSeek-V4-Flash and 1/437 of DeepSeek-V1 — while activating only 8B parameters per token during prefill and 16B during decode.

  • Causal Encoder-Decoder (CED): a 40-layer Transformer split into a 20-layer causal encoder and a 20-layer decoder; the decoder's global KV cache is projected from the final encoder hidden states rather than from each decoder layer's own states.
  • Compressed Sparse Attention 2 (CSA2): every attention layer runs in one of three static modes (Full, Reindex, Reuse), sharing main KV and indexer K across layers and reusing Top-K sparse-attention indices; a Hierarchical Sparse Indexer bounds deeper indexer cost independently of context length.
  • FP4 main KV caching (E2M1 format, one E4M3 scale per 16 channels) and SWA Bounded Replay, which reconstructs missing sliding-window-attention KV states by replaying only the most recent n_win tokens — cutting the persistent KV footprint to about 1/8 of DeepSeek-V4-Flash without persisting SWA KV to SSD.
  • Sparse MoE: 1 shared expert plus 384 routed experts per layer with 6 routed experts activated per token; Engram conditional memory (196B parameters, token-based lookup), DSpark speculative decoding (semi-autoregressive drafts with confidence-scheduled verification) and Single-Pass mHC with an efficient Mega-mHC kernel.

Pre-training used a 45T-token multimodal corpus with sparse attention trained at 64K sequence length, extending context to 1M tokens at 34T tokens. Post-training follows the SFT → RL → on-policy distillation (OPD) paradigm, with large-scale automated synthesis of agent tasks and environments; a continuously controllable reasoning_effort setting (integer 1–100) trades inference cost for accuracy.

At maximum reasoning effort the model sets records on DeepSWE v1.1 (74.2) and Terminal-Bench 2.1 (90.6) and leads on CyberGym (88.1), AutomationBench (54.8) and Agent's Last Exam (31.8). Recommended sampling: temperature 1.0, top_p 0.95, context window 1M tokens, max_tokens ≥ 256K.

Training Data Trained from scratch on a 45T-token multimodal corpus; sparse attention trained at 64K sequence length, context extended to 1M tokens at 34T tokens. Post-training: SFT -> RL -> on-policy distillation (OPD) with large-scale automated synthesis of agent tasks and environments.

Benchmark Scores

Benchmark Score Date Standing
Terminal-Bench Science 0.1
coding_agent
35.63%
07.11.2026
#2/5
better than 75%
GDP.pdf
long_context
29.68%
19.10.2026
#7/13
better than 50%
GPQA Diamond
stem_reasoning
93.57%
10.09.2026
#23/80
better than 71%
Humanity's Last Exam
stem_reasoning
65.72%
10.09.2026
#27/71
better than 63%
MathArena Apex 2025
stem_reasoning
51.04%
10.09.2026
#7/8
better than 14%
Terminal Bench 2.1
coding_agent
100.00%
10.09.2026
#1/44
better than 100%
Terminal-Bench 3.0
coding_agent
84.67%
10.09.2026
#3/7
better than 67%
Terminal-Bench 4.0
coding_agent
35.03%
10.09.2026
#8/10
better than 22%
ProgramBench
coding_agent
25.11%
10.09.2026
#11/18
better than 41%
NL2Repo-Bench
coding_agent
78.96%
10.09.2026
#4/23
better than 86%

Hardware Requirements

Estimated VRAM per quantization at 4,096 tokens context — MoE: all experts must fit in VRAM, only 16.0B are active per token

Quantization Weights KV Cache Total VRAM On your hardware
FP16 — 16-bit 1526.0 GB 2.5 GB 1604.8 GB Which GPUs can run it? Calculate on your GPU
INT8 — 8-bit 763.0 GB 1.2 GB 802.4 GB Which GPUs can run it? Calculate on your GPU
INT4 — 4-bit 381.5 GB 0.6 GB 401.2 GB Which GPUs can run it? Calculate on your GPU
FP4 — 4-bit 381.5 GB 0.6 GB 401.2 GB Which GPUs can run it? Calculate on your GPU

Only datacenter GPUs — FP16 needs 1604.8 GB. For consumer hardware, choose the INT4 build with a multi-GPU setup.

Architecture

Decoder Block input Embedding vocab 129K · d 5120 Full Attention Sparse Attn 64:1 · dₕ 512 · win 128 ×40 MoE FFN 384 experts · top-6 · +1 shared · dᴻ 2304 MTP Head ×3 speculative layers Final Norm LM Head vocab 129K output
Attention
Sparse Attention (64:1)
MoE
384 experts · top-6 per token
Layers
40
Hidden size
5120
Context
1M tokens
RoPE θ
10K
Parameters
763000M
Active params
16000M

Source: Hugging Face config.json · DeepseekV41ForCausalLM · model repo

Type: Causal Encoder-Decoder (CED) Transformer
Attention: Compressed Sparse Attention 2 (CSA2) with static Full/Reindex/Reuse modes, Hierarchical Sparse Indexer, and sliding-window attention with Bounded Replay
Decoder: 20-layer autoregressive decoder on top of a 20-layer causal encoder (40 layers total)
MoE: yes (384 experts)
Routing: Top-6 routed experts of 384 per token plus 1 always-on shared expert
Speculative Decoding

DSPark (semi-autoregressive draft generation with confidence-scheduled verification)

Training Pipeline

  1. 1
    pretraining

    Multimodal pre-training from scratch

    45T-token multimodal corpus (text + images); sparse attention trained at a sequence length of 64K.

  2. 2
    cpt

    Context extension to 1M tokens

    Context extended to 1M tokens at the 34T-token mark of pre-training.

  3. 3
    sft

    Supervised fine-tuning

    Standard SFT stage without algorithmic modifications; substantive changes lie in the data pipeline (large-scale automated synthesis of agent tasks and environments).

  4. 4
    rl

    Reinforcement learning

    Standard RL stage of the SFT -> RL -> OPD post-training recipe.

  5. 5
    other

    On-policy distillation (OPD)

    Final consolidation stage; on-policy distillation with progressive scaling of data, tasks and rollouts.

Training & Evaluation Datasets

NameRoleSizeModalitiesCollection
GPQA (Diamond) evaluation — —
Terminal-Bench 2.1 evaluation — —
Deep SWE evaluation — —
Terminal-Bench (3.0 / 4.0) evaluation — —
HLE (Humanity's Last Exam) evaluation — —

Comments (0)

No comments yet

Be the first to share your thoughts!

What now?

You have read the full card for DeepSeek-V4.1-Flash — here is where to go next.