Instructions to use BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B") model = AutoModelForCausalLM.from_pretrained("BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B
- SGLang
How to use BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B with Docker Model Runner:
docker model run hf.co/BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B
# Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B")
model = AutoModelForCausalLM.from_pretrained("BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B", device_map="auto")DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B
Expert-pruned variant of BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8, a mixed-precision quantization of deepseek-ai/DeepSeek-V4-Flash-0731.
What changed: routed experts pruned uniformly from 256 → 192 per layer across all 43 MoE layers. Quantization formats, dense layers, and KV cache are unchanged from the source — see its card for quantization and calibration details.
How K=192 was selected: per-expert REAP saliency computed during INT4 calibration,
0.7 × num_captured × (1 − rel_l2_error) + 0.3 × gate_l2_norm
keeping the top-192 experts in every layer. The per-layer mask is stored in reap_saliency.json; surviving experts are compacted to contiguous indices 0..191.
Parameters (INT4 experts unpacked ×8):
| Component | Params |
|---|---|
| Routed experts (192 × 43 × 25.17 M) | 207.8 B |
| Dense (attention, shared experts, indexer, norms, embeddings) | 7.8 B |
| Total weights (≈ 216 B) | 215.6 B |
| Active per token (6 routed + shared + dense) | ≈ 12 B |
Quantization scales and index tables add ≈ 6.6 B of storage tensors (not counted as model parameters). Before pruning (K=256) the model is ≈ 285 B.
Usage:
vllm serve BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B \
--trust-remote-code --kv-cache-dtype fp8
License: MIT — same as deepseek-ai/DeepSeek-V4-Flash-0731.
Cite:
@misc{deepseekai2026deepseekv4,
title={DeepSeek-V4: Towards Highly Efficient Million-Token Context Intelligence},
author={DeepSeek-AI},
year={2026},
}
- Downloads last month
- 84
Model tree for BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B
Base model
deepseek-ai/DeepSeek-V4-Flash-0731
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="BlivionIaG/DeepSeek-V4-Flash-0731-Int4-FP8-REAP-216B")