Huffing Face

deepseek-ai/DeepSeek-V4.1-Flash-1017

mit 83/83 files local @ 1bae0e108899

HF_ENDPOINT=https://huffingface.co \
  python -c "from huggingface_hub import snapshot_download; snapshot_download('deepseek-ai/DeepSeek-V4.1-Flash-1017')"

Model card

DeepSeek-V4.1-Flash-1017

DeepSeek-V4.1

Homepage Chat
Hugging Face Twitter Follow
License

Technical Report 👁️

Introduction

DeepSeek-V4.1-Flash-1017 is a minor update to DeepSeek-V4.1-Flash, delivering substantial improvements across reasoning, coding, agentic tasks, and visual benchmarks. Alongside these gains, the model reduces task execution time and output length, enabling users to complete tasks faster and at lower cost and advancing the performance–cost Pareto frontier across multiple agent harnesses.

BenchmarkDS-V4.1-Flash-1017DS-V4.1-FlashK3GLM-5.3GPT-5.6 SolOpus 5
HLE w/o tools42.6 (44.0†)36.8 (39.1†)43.542.0†44.556.3
Terminal-Bench 4.042.331.212.637.939.951.8
DeepSWE v1.177.074.267.566.973.074.0
ProgramBench29.120.317.519.023.037.0
NL2Repo-Bench68.265.458.058.056.875.3
Automation-Bench v1.0.660.554.846.748.845.850.3
Agents’ Last Exam35.431.827.628.526.728.6
Apex Bench v1.172.164.647.856.654.365.8
Chartography (w/tools)83.078.968.1—79.984.0
BabyVision (w/tools)92.589.685.7—88.994.1
ZeroBench-main (w/tools)51.049.041.0—53.052.0

† denotes the text-only subset of HLE. We use the Claude Code harness for Terminal-Bench 4.0 and the Mini-SWE-V2 harness for DeepSWE v1.1.

Prompt Encoding

This release does not include a Jinja-format chat template. The encoding folder contains a self-contained Python reference implementation (encoding.py) with test cases for multi-turn conversations, tool calling, thinking mode, numeric reasoning effort, mid-conversation system messages, and interleaved image content.

For production use, we additionally release deepseek-recipe, a set of Rust libraries with Python bindings that provides the same prompt format as a maintained, protocol-aware toolkit. It converts Messages, Chat Completions, and Responses API requests into the Conversation format, encodes them into DeepSeek V4 and V4.1 prompts or token IDs, and parses model output back into complete or streamed responses — covering thinking, tool calls, images, and generation settings. Model inference, tool execution, and HTTP transport are left to the caller.

Minimal Inference

Please refer to the inference folder for instructions on weight conversion and running inference locally.

Recommended sampling parameters:

ParameterValue
temperature1.0
top_p1.0
context_window1M tokens
max_tokens≥ 256K

License

This repository and the model weights are licensed under the MIT License.

Citation

@misc{deepseekai2026deepseekv41flash,
      title={DeepSeek-V4.1-Flash: Pushing the Limits of KV Cache Compression},
      author={DeepSeek-AI},
      year={2026},
}

Contact

If you have any questions, please raise an issue or contact us at service@deepseek.com.

Files

FileSizeStatus
.gitattributes2 kBhuffed
LICENSE1 kBhuffed
README.md5 kBhuffed
config.json3 kBhuffed
encoding/README.md12 kBhuffed
encoding/encoding.py38 kBhuffed
encoding/test_encoding.py22 kBhuffed
encoding/tests/test_input_1.json3 kBhuffed
encoding/tests/test_input_2.json1 kBhuffed
encoding/tests/test_input_3.json3 kBhuffed
encoding/tests/test_input_4.json1 kBhuffed
encoding/tests/test_input_5.json1 kBhuffed
encoding/tests/test_output_1.txt2 kBhuffed
encoding/tests/test_output_2.txt0 kBhuffed
encoding/tests/test_output_3.txt2 kBhuffed
encoding/tests/test_output_4.txt1 kBhuffed
encoding/tests/test_output_5.txt0 kBhuffed
inference/README.md2 kBhuffed
inference/config.json2 kBhuffed
inference/convert.py9 kBhuffed
inference/engram.py8 kBhuffed
inference/examples/example.txt0 kBhuffed
inference/examples/example_harmony.json2 kBhuffed
inference/examples/images/carrots.jpeg212 kBhuffed
inference/examples/images/corn.jpeg56 kBhuffed
inference/generate.py9 kBhuffed
inference/image_processor.py8 kBhuffed
inference/kernel.py24 kBhuffed
inference/model.py62 kBhuffed
inference/requirements.txt0 kBhuffed
inference/run.sh2 kBhuffed
inference/vision.py4 kBhuffed
model-00001-of-00048.safetensors970.5 MBhuffed
model-00002-of-00048.safetensors1.3 GBhuffed
model-00003-of-00048.safetensors7.4 GBhuffed
model-00004-of-00048.safetensors7.4 GBhuffed
model-00005-of-00048.safetensors7.4 GBhuffed
model-00006-of-00048.safetensors7.4 GBhuffed
model-00007-of-00048.safetensors7.4 GBhuffed
model-00008-of-00048.safetensors7.4 GBhuffed
model-00009-of-00048.safetensors7.4 GBhuffed
model-00010-of-00048.safetensors7.4 GBhuffed
model-00011-of-00048.safetensors7.4 GBhuffed
model-00012-of-00048.safetensors7.4 GBhuffed
model-00013-of-00048.safetensors7.4 GBhuffed
model-00014-of-00048.safetensors7.4 GBhuffed
model-00015-of-00048.safetensors7.4 GBhuffed
model-00016-of-00048.safetensors7.4 GBhuffed
model-00017-of-00048.safetensors7.4 GBhuffed
model-00018-of-00048.safetensors7.4 GBhuffed
model-00019-of-00048.safetensors7.4 GBhuffed
model-00020-of-00048.safetensors7.4 GBhuffed
model-00021-of-00048.safetensors7.4 GBhuffed
model-00022-of-00048.safetensors7.4 GBhuffed
model-00023-of-00048.safetensors7.4 GBhuffed
model-00024-of-00048.safetensors7.4 GBhuffed
model-00025-of-00048.safetensors7.4 GBhuffed
model-00026-of-00048.safetensors7.4 GBhuffed
model-00027-of-00048.safetensors7.4 GBhuffed
model-00028-of-00048.safetensors7.4 GBhuffed
model-00029-of-00048.safetensors7.4 GBhuffed
model-00030-of-00048.safetensors7.4 GBhuffed
model-00031-of-00048.safetensors7.4 GBhuffed
model-00032-of-00048.safetensors7.4 GBhuffed
model-00033-of-00048.safetensors7.4 GBhuffed
model-00034-of-00048.safetensors7.4 GBhuffed
model-00035-of-00048.safetensors7.4 GBhuffed
model-00036-of-00048.safetensors7.4 GBhuffed
model-00037-of-00048.safetensors7.4 GBhuffed
model-00038-of-00048.safetensors7.4 GBhuffed
model-00039-of-00048.safetensors7.4 GBhuffed
model-00040-of-00048.safetensors7.4 GBhuffed
model-00041-of-00048.safetensors7.4 GBhuffed
model-00042-of-00048.safetensors7.4 GBhuffed
model-00043-of-00048.safetensors1.3 GBhuffed
model-00044-of-00048.safetensors2.7 GBhuffed
model-00045-of-00048.safetensors2.6 GBhuffed
model-00046-of-00048.safetensors2.7 GBhuffed
model-00047-of-00048.safetensors101.5 GBhuffed
model-00048-of-00048.safetensors101.5 GBhuffed
model.safetensors.index.json7.5 MBhuffed
tokenizer.json6.4 MBhuffed
tokenizer_config.json1 kBhuffed