mirror of
https://github.com/mw00/project-maya.git
synced 2026-12-03 21:08:26 +07:00
[PR #639] [CLOSED] DeepSeek: restore points, one-launch --parallel attention, logprobs, faster i-quant kernels and CPU rows, a prompt read in parts, a RAM expert store, pack tools #641
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#641
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/639
Author: @needmorevram
Created: 10/28/2026
Status: ❌ Closed
Base:
main← Head:ds4-engine-features📝 Commits (10+)
2f69607DeepSeek: restore points a request asks for (GEN marks= / shared=)0c39be8serve: MAYA_DS4_RESTORE_POINTS - DeepSeek restore points at the last user turn, the tail and the system prompt's endad38d6bDeepSeek: a prompt's run of chunks read in parts with the plan of one calld9f1752DeepSeek --parallel: running requests decode between a long prompt's chunks; a long read gives way to a short one7bed54aDeepSeek: a GEMV call's int8 inputs rounded in one launch by default, an input several jobs read rounded once6ee87bcDeepSeek: the HC mix and split in one launch where they run on the layer's own stream94028f6DeepSeek: a GGUF head reads 8 rows a pass9482b5bDeepSeek: the drafter's markov head as Q8_0 blocks (opt-in, MAYA_DS4_MARKOV_Q8)34faf4fDeepSeek: the HC mix + split launch opt-in until measured979a23bDeepSeek: a prompt's path by its length (DS4_PROMPT_PICK=length), the prompt GEMMs warmed up at load📊 Changes
55 files changed (+12379 additions, -731 deletions)
View changed files
📝
CMakeLists.txt(+99 -1)➕
cmake/build_id.cmake(+45 -0)📝
docs/RESPONSES.md(+5 -0)📝
docs/SETTINGS.md(+365 -11)📝
include/strata/spec/draft_policy.hpp(+54 -2)📝
maya.py(+2 -1)📝
serve/fake_multi_engine.py(+8 -2)📝
serve/frontend.py(+1 -0)📝
serve/responses.py(+20 -3)📝
serve/server.py(+297 -19)➕
serve/test_ds4_restore_points.py(+198 -0)➕
serve/test_logprobs.py(+330 -0)📝
src/ds4/ds4_cpu_exl3.hpp(+4 -1)📝
src/ds4/ds4_engram_io.hpp(+17 -7)📝
src/ds4/ds4_gguf.cu(+148 -66)📝
src/ds4/ds4_gguf.cuh(+9 -3)📝
src/ds4/ds4_gguf_cpu.hpp(+3 -2)➕
src/ds4/ds4_interleave.hpp(+85 -0)📝
src/ds4/ds4_iq.cu(+401 -197)📝
src/ds4/ds4_iq.cuh(+17 -7)...and 35 more files
📄 Description
What
A set of DeepSeek engine and server improvements on top of v1.1.36 (it builds on #611's
--paralleldrafter). Everything here is exact: the model's math is unchanged, and the defaults that changed were measured first. One request without--paralleldecodes the same tokens as v1.1.36's engine.On by default
MAYA_DS4_RESTORE_POINTS, 4).MAYA_DS4_SLOT_KEEP) save and load the points.0turns them off.--parallelstep's attention in one launch (MAYA_DS4_MULTI_ATTN).MAYA_DS4_IQ_PERSIST=0: the full grids);All of these give the same bits.
DS4_IQ512=0: as before.--mmap-experts autono longer copies every expert into RAM when the GPU shares it.logprobs/top_logprobs(up to 20) on chat completions and the Responses API, streamed or not;Opt-in, documented in docs/SETTINGS.md
MAYA_DS4_PROMPT_SHARE,MAYA_DS4_PROMPT_GAP_MS,MAYA_DS4_PROMPT_YIELD).--ssd-cache,--ssd-policy). It reads whole experts past the page cache, serves demand reads before guesses, and gives RAM back when memory is low.DS4_DRAFT_COST).DS4_PROMPT_PICK=length);DS4_RING_MB=auto);DS4_SETTLE_MS);DS4_COPY_HUGETLB, auto only when a reserved pool holds them all;DS4_COPY_PIN_RO);DS4_UMA_FREE);MAYA_DS4_HC_MIX_SPLIT);MAYA_DS4_MARKOV_Q8; it changes the drafts only, never the verified tokens).Tools
maya-ds4 --pack-info: a pack described without a GPU or its weights. It shows the types, bytes per expert and per token, the tiers by profile, tensors without a kernel, missing files ("DEAD PACK") and suspicious metadata.maya-ds4 --version, and a build line with--verbose.--profile-run/--profile-out: an expert profile from a corpus.--profile-readonly: placement from a profile that is never written back.--spec-evalwithDS4_ROUND_LOG: the drafter's acceptance by position and confidence.--sampler-test: a chi-square check that speculative sampling draws as the model does.--parts-check: a prompt read in parts against one call, bit for bit.tools/ds4/concurrent_check.py: conversations at once must not see each other's state.Measured
One RTX 3090 + eight RTX 5060 Ti (
--tp 8over a layer split), EXL3 3.5 bpw, two thirds of the experts in RAM, unless noted.--parallel 2 --multi-check, expert cache off, gives the same logits bit for bit, 398 of 398 rows. 2 × 200 tokens go 43.9 → 49.3 tok/s in all without drafts and 52.0 → 56.3 with them (measured on v1.1.35). On this branch on top of v1.1.36: 52.7 tok/s together without drafts and 60.4 with them in one pass, every mode the same tokens as alone.MAYA_DS4_PROMPT_SHARE=0.5.DS4_DRAFT_COSTandMAYA_DS4_PROMPT_SHARE: no gain in the two-request server test, so both stay opt-in.Tested
maya-ds4,mayaandmaya-mm3build for sm_86 and sm_120 with no new warnings.--pack-info;serve/test_logprobs.py(19) andserve/test_ds4_restore_points.py(8). The 13test_responses_schemafailures happen on v1.1.36 too.ds4_gguf_test, including--trims,--persistand--deviceson all 9 GPUs: all OK;ds4_multi_attn_test: OK;--multi-check: bit for bit;--parts-check(a 24K-token prompt in 7 parts with another conversation stepped between): bit for bit;--pack-infosays they can load.🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.