mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #5027] [TUI] strata launch --set mmap-experts=off never reaches strata-dsv41: DeepSeek reads the experts in place (about 40% slower decode) #2326
Labels
No labels
needs-format
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
Niko1221/Strata#2326
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?
Originally created by @erikash on GitHub (Nov 2, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/5027
Area
[TUI] (the Terminal: strata launch, connect, monitor)
Desktop app, Terminal or source?
Docker
What happened
With DeepSeek,
strata launch --set mmap-experts=off(in Docker:STRATA_SET="mmap-experts=off ...") never reaches strata-dsv41. The engine starts with no--mmap-expertsat all, so it uses its default and reads the experts in place from the model files instead of copying them into RAM. That costs about 40% of decode on my machine.The launcher treats
--mmap-expertsas a bare switch for every engine, because it is intune_knobs.BOOL_FLAGS, andsettings.as_argv_changesturnsoffinto "remove the flag". That is right for the Qwen engine, where--mmap-expertstakes no value. strata-dsv41 reads it with a word,--mmap-experts on|off|auto(src/dsv41/ds4_main.cpp), and its default is on. It is the same kind of problem #3959 fixed for--dspark.Engine command line from the launch, inside the container (
/proc/<pid>/cmdline):--cpu-threads,--ssd-cache,--dsparkand--expertsfrom the sameSTRATA_SETarrive;--mmap-experts offdoes not.Expected:
--mmap-experts offon the engine line.Same files, same container image, same card, run once each (greedy, thinking off, 400 tokens out; the last row is a 16.9K-token prompt, then 300 tokens out). Decode in tokens per second, two rounds each:
--mmap-experts)--mmap-experts offFor the second row I started
serve/server.pyfrom the image by hand, with the launch's own run config (/data/state/strata/launch/ds.json) plus--mmap-experts offand nothing else changed.From reading the code, not run:
--set mmap-experts=onfor DeepSeek appends a bare--mmap-experts. strata-dsv41 would then take the next argument as its word, or stop with "--mmap-experts needs a value" when the flag is last.Smallest steps or command that reproduce it
Without a GPU:
derive_configon a DeepSeek run config withextra={"--mmap-experts": "off"}returns args without--mmap-experts. I checked this inside the image (its Python, its code) against the run config the launch wrote.Reproduction status
Reproduced locally
Strata version
Strata 0.2.9 · engine 0.1.55 (ghcr.io/niko1221/strata:0.2.9-cuda13; the DeepSeek engine package 0.1.55-linux-x86_64-cuda-cuda13 that the launch downloaded)
Graphics card, memory and system
RTX 3090 24 GB · 157 GiB RAM · AMD EPYC 7702P (64 vCPUs) · Ubuntu 26.04.1 (VM), Docker
Model, size and settings
DeepSeek-V4.1-Flash IST-DAS-2.25bpw · 256K context · pictures on ·
STRATA_SET="mmap-experts=off cpu-threads=48 ssd-cache=0 dspark=on experts=5"Logs
The engine command line above is the relevant part. I have no error to show: the engine starts and runs, just with the experts read in place.
I have a fix with a regression test and will open a PR that links here.
@Niko1221 commented on GitHub (Nov 5, 2026):
Hello erikash,
Thank you for the report and PR #5028. In Strata 0.2.11
--set mmap-experts=on|off|autokeeps its word for DeepSeek (strata-dsv41) and reaches the engine, while for Qwen it stays a bare switch. It also holds through a second launch. We reproduced the dropped value on the old code. We did not measure the decode speed difference you saw on your container. If the experts are still read in place withoffon 0.2.11, please send the engine command line from the launch log.The Strata project
@erikash commented on GitHub (Nov 5, 2026):
Confirmed on 0.2.11, thanks. I used
ghcr.io/niko1221/strata:0.2.11-cuda13(engine 0.1.57) on the RTX 3090 withFAMILY=deepseek41 MODEL=IST-DAS-2.25bpwandSTRATA_SET="mmap-experts=off cpu-threads=48 ssd-cache=0 dspark=on experts=5". The strata-dsv41 command line now has--mmap-experts off, and the engine copied 15,203 of the CPU lane's 15,342 experts into RAM. Withmmap-experts=onit gets--mmap-experts on, so the word comes through in both cases.I ran it twice in the same container with the same prompts, changing only that flag (greedy, thinking off, 400 tokens out, two rounds). Decode in tokens per second:
mmap-experts=on(in place)mmap-experts=offThat's about +58% decode, in line with what I measured in the report. Prompt reading is the same either way.