mirror of
https://github.com/mw00/project-maya.git
synced 2026-12-03 21:08:26 +07:00
[PR #520] [CLOSED] DeepSeek: orcarouter's abliterated Mix-256G GGUF, and ~7x faster prompts for a tensor-parallel GGUF group #576
Labels
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
mw00/project-maya#576
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/mw00/project-maya/pull/520
Author: @needmorevram
Created: 10/26/2026
Status: ❌ Closed
Base:
main← Head:ds4-abliterated📝 Commits (1)
b5eb8caDeepSeek: orcarouter's abliterated Mix-256G GGUF (--ds4-quant abliterated); a tensor-parallel GGUF group's prompt copies by member part, from pinned copies📊 Changes
16 files changed (+827 additions, -87 deletions)
View changed files
📝
README.md(+1 -0)📝
docs/SETTINGS.md(+15 -2)📝
docs/SETUP.md(+11 -1)📝
maya.py(+81 -17)📝
setup.py(+7 -2)📝
src/ds4/ds4_gguf.cu(+26 -20)📝
src/ds4/ds4_gguf.cuh(+2 -2)📝
src/ds4/ds4_iq.cu(+28 -1)📝
src/ds4/ds4_iq.cuh(+5 -4)📝
src/ds4/ds4_model.cu(+412 -27)📝
src/ds4/ds4_q6k.cuh(+16 -0)📝
tests/ds4_gguf_test.cu(+32 -9)📝
tools/ds4/download_gguf.json(+44 -0)📝
tools/ds4/pack_gguf.py(+15 -0)📝
tools/test_ds4_vision_pack.py(+37 -2)📝
tools/test_setup_ds4.py(+95 -0)📄 Description
Adds orcarouter's abliterated DeepSeek-V4.1-Flash-1017 (Mix-256G GGUF, 346 GB) to the setup as
--ds4-quant abliterated. It also makes a tensor-parallel GGUF group's prompts much faster. At--tp 8on 9 GPUs, 16K prompts went from 85-93 to 595-639 tok/s; part of that came from moving the model's Engram shard to an NVMe.The speed work only changes how expert bytes reach the GPUs, not the arithmetic.
MAYA_DS4_TP_CHECK=1compares every new copy with the file's bytes, byte for byte.What changes
Setup (
maya.py,setup.py,tools/ds4/download_gguf.json,tools/ds4/pack_gguf.py)--ds4-quant abliterateddownloads the 7 shards, with sizes and sha256 at revision43fac799, into<models>/DeepSeek-V4.1-Flash-1017-abliterated-GGUF/Mix-256G. The model is served asdeepseek-v4.1-flash-abliterated.HF_TOKEN,HUGGING_FACE_HUB_TOKEN, or the tokenhf auth loginsaved.$HF_TOKEN, not the token itself.pack_gguf.py: this GGUF has nodspark.*keys. If its layer count and compress ratios match DeepSeek-V4.1-Flash's (40 layers plus the drafter's 3), the pack takes the drafter's geometry from the checkpoint'sconfig.json. DeepSeek's DSpark drafter then drafts for it as it does for unsloth's GGUFs. Without this, the engine loaded the drafter but never drafted.Engine: the quant's formats (
ds4_gguf.cu,ds4_iq.cu,ds4_q6k.cuh)mx_role). This covers the token, window and prompt-set paths.ds4_iq), and the Q6_K token embedding is decoded on the host.Engine: prompts of a tensor-parallel GGUF group (
ds4_model.cu)read_mx_member). WithMAYA_DS4_TP_GGUF_UNEVEN=1and off the flow:cudaMemcpy2DAsyncper row. That took about 35 ms an expert.cp_pin). With several GPUs, the CPU lane's experts copied into RAM (two NUMA parts) are pinned at load when prompts run in chunks, all or none.DS4_COPY_PIN=0turns this off. If the pin fails, the load says so and the prompt path stages everything as before.MAYA_DS4_TP_CHECK=1checks the new copies. For each format and rotation, it copies the parts as the prompt path does, from RAM and from the file. It then compares them on the device with the file's bytes, with guard bytes around each copy.Docs: README's model table, SETUP.md, and SETTINGS.md (
DS4_COPY_PIN, the members' prompt copies, the TP check).Tested
--tp 8 --prefill-chunk 4096 --dspark on,MAYA_DS4_TP_GGUF_UNEVEN=1. The 3090 runs layers 0-4 and the drafter by itself; the 5060 Tis are the tp8 group.Checks:
MAYA_DS4_TP_CHECK=1passed: 27 expert formats and rotations, and 432 of the prompt path's copies byte for byte on the devices.ds4_gguf_test: ALL OK (497 checks) on an RTX 5060 Ti (sm_120) and on the RTX 3090 (sm_86). It covers Q6_K against ggml'sdequantize_row_q6_K, and the IQ3_XXS/MXFP4, MXFP4/IQ3_S and IQ2_S/MXFP4 layers: token experts, plus the PCIe lane bit for bit with VRAM.check_hip_compat.pyOK;tools400 tests OK (1 skipped);serve366 tests OK (8 skipped).Speed: the same serve bench and prompts as #495 (two ~16K prompts, then decode at temperature 1.0). Prefill is two prompts; decode is all / median.
Why the Engram step mattered: the Engram tables (shard 00002, 110 GB, read at random in 144-byte rows) were on a USB SSD that manages about 5,000 random reads/s. A 16K prompt reads about 620K rows, which takes about 2 minutes at that rate. On an NVMe (about 115K reads/s) it's no longer the bottleneck. README already says to keep the files on an NVMe.
Load time: pinning takes 50-110 s for 125 GB. From the NVMe, the server is ready in 5-8 minutes.
Known gaps
--tp 8one member takes 512 columns and the others 256, rotating per layer. That's 1.78x the even share; EXL3's split128 is 1.33x.--tp 9would split evenly. Not measured.MAYA_DS4_TP_CHECK=1hung the first prompt once at tp8 (GPU 1 at 100%), before the member-part change. It hasn't happened in any run since.--tp 8), the drafter's three blocks on the lead cap every member's VRAM experts: 1,523 of 15,360 slots, leaving 206 GB to be read from the files.MAYA_DS4_DRAFT_DEV=1,2,3, which already exists, spreads the blocks across members. 161 GB was then copied and pinned.🤖 Generated with Claude Code
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.