mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #5136] [Engine] Route tail skip is on by default and changes answers; the switch is not in the Advanced table #2405
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#2405
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 @HelloItMeMort on GitHub (Nov 3, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/5136
Area: Engine. The last section is a Terminal finding (
strata_cli,strata_control) and can be split into a[TUI]issue if one-problem-per-thread is preferred.Summary
STRATA_ROUTE_TAIL_SKIPis enabled at rank 7 by default on CUDA builds and on HIP gfx1200/gfx1201. An expert that is not resident and that every token of a verify window routes at rank 7 or lower is neither copied nor computed: its row is zeroed and the survivors keep the router's weights, without renormalisation (src/core/expert_source.cpp:4941-4944, 5163-5166). The text the server returns is therefore not the text the same engine returns with the switch off, on the same weights, with the same seed.Answer changes are answer changes. A default that changes what the model says is not a tuning choice to be debated on speed: a serving default must not alter output unless the user asks for it.
AGENTS.mdstates that standard — "A new feature is opt-in, and the default path stays byte-identical to the last release" — andCONTRIBUTING.mdrepeats it. The off switch exists (=0), so the behaviour is understood to be separable; it is still what every user gets without asking for it.The finding is about the code, not about one machine: it is a source-level property of the serve start-up, and it holds across the configurations listed below.
Why it is wrong
expert_source.cpp:4958readsd.host_res[...] >= 0and does not skip a resident expert), and residency is the GPU expert cache, which the adaptive swaps move during the run (generate.cpp:12216-12217,--adapt-every/--adapt-swaps). The same prompt with the same seed can therefore differ at two points in one server's lifetime, and differs between machines with different VRAM or cache size.setup.py:4107-4108writesSTRATA_ROUTE_TAIL_SKIP=0into the run config for Unsloth packs outside the RAM-budget mode and writes nothing for any other family.generate.cpp:12171-12172). That is treated as a correctness problem in--batchand as a default everywhere else.=0as the behaviour of record.tools/quant_quality.py:40pins it off inFIXED_ENV, so the quality yardstick will not measure with the default on;bench/results/2026-10-20-0.2.1-idle-gpu/README.md:45andbench/results/2026-10-12-p40-sm61-kernels/README.md:154require off before two builds' answers can be compared; setup itself opts the largest installed group of CUDA configs out. #2482 and #2523 are both runs of=7against=0, i.e. the community already treats the rank as the user's choice.STRATA_KVAandSTRATA_ROUTE_PRIORalso change answers, and both ship off with a plain-words warning — "Off by default: answers about long documents can miss or mix up details" (strata_control/speed_switches.py:38-43). Route tail skip ships on, unnamed and undescribed. Nothing technical separates them.STRATA_ROUTE_TAIL_SKIP=7 turns it on(generate.cpp:12203-12204,docs/NVFP4.md:68-69). This asks for the same treatment where it was never examined.Additionally, no papers have been authored on the potential effects of skipping tails. This feature should have never been implemented without proper neural network architecture experience.
How the default is applied
Read from commit
ffa80d73133ea5c548aefe57889a16e8085a938f(2026-11-02), Strata 0.2.10, engine 0.1.56.generate.cpp:12168-12215resolves the default at serve start-up and callsset_tail_skip_rank(7)at:12209. The engine's own convention is unset-means-off (expert_source.cpp:4848-4863, unset gives 0); the serve start-up is the single place that overrides it.The default 7 applies when all of the following hold (
generate.cpp:12198-12201):STRATA_ROUTE_TAIL_SKIPis unsetgenerate.cpp:12174generate.cpp:12166-12167STRATA_TAIL_SKIP_MAX_CACHEDgenerate.cpp:12179-12190--batchis 0generate.cpp:12198decode_defaults_arch_ok())generate.cpp:2400-2409generate.cpp:12199generate.cpp:12193-12201docs/DETAILS.md:1049files the switch under "On by default", and its own row ends with "Answers differ slightly from a run without it."The switch cannot be reached from the product
It is an environment key, so it is not in the engine's
--help, and the Terminal's Advanced table builds its rows from exactly three sources (strata_cli/launch/params.py:171-201): parsed--help(parse_help,:99-120, which accepts only lines beginning with--), the tuner's arms (env_params,:122-133, fromtune_knobs.ARMS) and the speed switches (switch_params,:136-142, fromspeed_switches.SWITCHES). The key is in none of them:So the value the server is actually running has no row, and the only route is "+ Add a setting by name…", labelled "for flags of newer engine versions" (
strata_cli/launch/screens.py:1318). What that returns:The one screen meant to show what a launch does tells the user the setting is off and that the correct name is a typo.
check_name(params.py:203-210) returns early unless the name begins with--, so environment keys get no "did you mean" help at all while mistyped flags do.Expected vs actual
Expected:
strata launchwith nothing set computes every expert the router selected, and its answer is the answer the same engine gives withSTRATA_ROUTE_TAIL_SKIP=0. Answers do not depend on cache occupancy or on the installed family. The Advanced table lists the setting, its real default and what it does to answers.Actual: the server runs the skip at rank 7 unless the user finds an environment variable the product never showed them, and the answers differ from the same build with the switch off. The setting is absent from the Advanced table; typed correctly, it is labelled a newer flag or a typing mistake and its default column reads
off.Reproduce
The interface half, in a source checkout, with no GPU:
The engine half is the start-up strings at
generate.cpp:12203-12214and the counter atgenerate.cpp:19062-19064; a server on a covered card that never set the variable printsWhat must change
tail_default_okis false when the environment does not name the switch, sostrata launchserves the weights as given. The opt-in is untouched —=7(1-9) still turns it on and prints the existing line. Nobody loses speed for not asking.STRATA_ROUTE_TAIL_SKIPtospeed_switches.SWITCHESortune_knobs.ARMS, and judge a name unknown only when it begins with--, so environment keys the engine honours are not reported as typos.docs/DETAILS.md:1049moves out of "On by default", anddocs/QUANTS.md:158says the setting is opt-in.Per-launch opt-in through a serve flag is an acceptable shape. A silent default is not.
Reproduction status
speed_switches.env_names()andtune_knobs.ARMS, plus the two switch sentences quoted fromstrata_control/speed_switches.py.generate.cpp:12168-12215) and the skip path (expert_source.cpp:4941-4944, 5163-5166), read from source atffa80d73. The two log lines above confirm them on hardware; no engine was run for this report.Limits and related work
This concerns the default only.
=7stays available and unchanged for anyone who wants the speed; the question is who decides — the user, or the launch. SYCL and Metal are out of scope: neither tree contains the switch.Same class, already open here: #4402 (
STRATA_ROUTE_PRIORdefault-on for ≤13 GiB cards, repetition loops) and #5000 (asks for the routing choice to be logged at start-up and for a per-VRAM default). #1884 is the V100 report that produced the current 90% carve-out. #2482 and #2523 measured=7against=0as a user choice. SearchingROUTE_TAIL_SKIPand "tail skip" in the tracker found no open issue asking about the default itself, which is why this is a new thread rather than a comment on those.@HelloItMeMort commented on GitHub (Nov 3, 2026):
This, among many other "features" that sacrifice quality for speed, is why I'm using Infernix. But not everyone has a Blackwell/50-series card, so it's unfortunate that the most popular alternative has many silent defaults that affect quality without informing the user.