---
title: V13-4p2-ds4.1-flash
canonical_url: "https://www.modelscope.cn/models/mate1510/V13-4p2-ds4.1-flash"
md_url: "https://www.modelscope.cn/models/mate1510/V13-4p2-ds4.1-flash.md"
repository: mate1510/V13-4p2-ds4.1-flash
last_updated: 2026-12-01
license: mit
parameters: 1068.9B
tensor_type:
  - F8_E4M3
  - F8_E8M0
  - U8
  - BF16
  - I8
  - F32
library_name:
  - safetensors
downloads: 242
stars: 0
tags:
  - deepseek-v4.1-flash
  - prefill-decode-disaggregation
  - vllm
  - dgx-spark
---

# V13-4p2-ds4.1-flash

> V13-4p2-ds4.1-flash - mate1510 在 ModelScope 开源的模型。V13: DeepSeek-V4.1-Flash 4+2 PD deployment (dealign weights)

mate1510/V13-4p2-ds4.1-flash 是 ModelScope 魔搭社区上的 1068.9B 参数机器学习模型，采用 mit 许可。

- **Repository**: mate1510/V13-4p2-ds4.1-flash
- **License**: mit
- **Parameters**: 1068.9B
- **Tags**: deepseek-v4.1-flash, prefill-decode-disaggregation, vllm, dgx-spark
- **Downloads**: 242
- **Stars**: 0
- **Last updated**: 2026-12-01

Source: https://www.modelscope.cn/models/mate1510/V13-4p2-ds4.1-flash

---

# V13: DeepSeek-V4.1-Flash 4+2 PD deployment (dealign weights)

A complete, self-contained deployment of DeepSeek-V4.1-Flash-1017 (dealign variant) split into
prefill on one x86 node with 2 GPUs (P node) and TP4 decode on 4 DGX Spark nodes (D nodes).
Everything needed is in this repository: weights, decode container image, prefill binary and core,
engram tables, proxy image, scripts and systemd units. No file contains real addresses or keys;
you supply them in `xy-v13.env`.

## Layout

| Path | Size | Needed on |
|---|---|---|
| `weights/` | 476 GB | D0-D3 |
| `d/spark-ds41f-1126.tar` | 27.5 GB | D0-D3 (docker image `spark-ds41f:1126`) |
| `d/engram-packed/rank<N>/` | 52 GB each | D node of rank N only |
| `d/xyconn`, `d/yee44`, `d/yee44-state`, `d/xy-v13-d-ctl`, `d/xy-extra.env` | small | D0-D3 |
| `engram-rows/shards/l{1,14}-s<N>of5.safetensors` | 40 GB per shard pair | D rank N (D2 also holds s4) |
| `engram-rows/*.py`, `libxyrow.so`, `xy_rowread.c` | small | D0-D3 |
| `p/flare`, `p/core/` | 358 GB | P |
| `p/*.in`, `p/xy-v13-*`, `p/*.py`, `p/xy-v13-nvidia.conf` | small | P |
| `proxy/vllm-dsv41-x86-overlay6.rootfs.tar` | 13.5 GB | P (pico proxy runtime) |
| `proxy/xy_pico_proxy.py` | small | P |
| `deploy.sh`, `xy-v13.env.example`, `SHA256SUMS` | small | all |

## Requirements

- P node: x86_64 Linux, 2 NVIDIA GPUs with P2P (driver 595.99.02 or newer; flare links libcuda 595.99.02),
  docker, python3, about 400 GB free disk.
- D nodes: 4 x DGX Spark (GB10) with docker + NVIDIA container toolkit, RoCE links between them
  (direct topology), python3, about 650 GB free disk each (weights + image + own engram files).
- All 5 nodes reachable from each other on one IP network. Ports used: D 8000 (API on D0), 9999 (TP
  master on D0), 9621-9624 (engram rows); P 8000 (pico), 8001 (public API), 8100, 18960 (local), 18961.

## Download

Install the client once: `pip install -U modelscope`. Download into the same directory on each node
(for example `/opt/xy-v13`), only what that node needs:

```bash
R=mate1510/V13-4p2-ds4.1-flash; T=/opt/xy-v13; N=0   # N = this D node's rank 0..3
# D node of rank N (for N=2 add: --include 'engram-rows/shards/*-s4of5.safetensors')
modelscope download --model $R --local_dir $T --include 'weights/*' 'd/spark-ds41f-1126.tar' \
  "d/engram-packed/rank$N/*" 'd/xyconn/*' 'd/yee44/*' 'd/yee44-state/*' 'd/xy-*' \
  "engram-rows/shards/*-s${N}of5.safetensors" 'engram-rows/*.py' 'engram-rows/*.so' 'engram-rows/*.c' \
  deploy.sh xy-v13.env.example SHA256SUMS
# P node
modelscope download --model $R --local_dir $T --include 'p/*' 'proxy/*' deploy.sh xy-v13.env.example SHA256SUMS
```

Or download everything: `modelscope download --model $R --local_dir $T` (about 1.3 TB).
Web page: https://www.modelscope.cn/models/mate1510/V13-4p2-ds4.1-flash

## One-click deploy

```bash
cd /opt/xy-v13
cp xy-v13.env.example xy-v13.env && vi xy-v13.env   # same values on all 5 nodes
sudo bash deploy.sh verify                         # checks sha256 of the files you downloaded
sudo bash deploy.sh d                              # on D0, D1, D2, D3 (any order)
sudo bash deploy.sh p                              # on the P node, after the D nodes
sudo bash deploy.sh status                         # any node
```

`deploy.sh d` finds the node's rank by matching its local IPs against `D0_IP..D3_IP`, starts the engram row
servers as systemd units `xy-v13-engram-962x`, loads the image and starts container `xy-d41`
(`xy-v13-d-ctl start|stop|status|logs`). Model load takes 10-20 minutes; D0 answers
`curl http://D0_IP:8000/health` when ready.

`deploy.sh p` installs the NVIDIA module options (first run: reboot the P node, then services start on
boot), the flare supervisor `xy-v13-flare.service` (`xy-v13-ctl status`), relay `xy-v13-flare-relay`
(P_IP:18961, used by the D nodes to fetch prefill KV), timing proxy `xy-v13-timing-proxy` and the pico
proxy container `xy-v13-pico`.

Clients use the OpenAI API at `http://P_IP:8001/v1`, model `deepseek-v4.1-flash`.

## Notes

- `APPROVE_KEY` is the value for flare's `--dangerously-approve-key`. It is not included; obtain your own.
- The decode image contains a built-in default master address. It is always overridden by
  `--master-addr $D0_IP`, set by `xy-v13-d-ctl`; you do not need to edit the image.
- `DSFRONT_KEY` is optional. When set, the pico proxy replaces client keys with it when calling D0.
- The pico proxy image is a `docker export` rootfs; `deploy.sh` imports it with `docker import` and
  restores PATH, LD_LIBRARY_PATH and WORKDIR.
- To stop: D nodes `sudo xy-v13-d-ctl stop`; P node `sudo systemctl stop xy-v13-flare xy-v13-timing-proxy
  xy-v13-flare-relay && docker stop xy-v13-pico`.

## License and disclaimer

Code and scripts in this repository are released under the MIT License. The model weights are a dealign
derivative of DeepSeek-V4.1-Flash and remain subject to the upstream DeepSeek model license. The
dealign variant has had refusal behaviour reduced and may produce harmful, inaccurate or offensive
output; you are responsible for how you deploy and use it and for complying with applicable laws.
Provided as is, without warranty of any kind.
