mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #4576] [Engine] Turn ends whenever the model tries to write "Nerazim" #2069
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#2069
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 @cmedinasoriano1 on GitHub (Oct 29, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/4576
Problem:
The Strata dsv41 engine (DeepSeek-V4.1-Flash) hard-stops the turn mid-generation, writing only "Neraz" when asked to use the name "Nerazim" in a sentence. Any string matching
/\b\w+zim\b/itriggers the same stop. The same shards do not break in llama.cpp.Environment:
Reproduce:
/\b\w+zim\b/itriggers it).Expected:
The turn completes with the word written in full — the same shards serve it normally in llama.cpp.
Actual:
The turn ends after writing only "Neraz" (the word truncated mid-generation); hard stop, no further tokens, no error in the response.
Evidence:
Client-side capture of the failed response: the turn ends after writing only "Neraz".

Engine log (aggregate only — it records token counts, never prompt/response text): the request read 3961 prompt tokens and generated only 12 before stopping: prompt 3961 tokens = 0 reused + 3961 read in 52275 ms (75.8 tok/s), 12 generated in 4458 ms (2.69 tok/s).
Reproduction status: Reproduced locally
@Niko1221 commented on GitHub (Oct 29, 2026):
Thanks, this one is on our side and the word does not matter.
The server ended the reply on the token
im. Strata's server stops a reply on the ids of Qwen's<|im_end|>and<|endoftext|>unless the config says it is serving DeepSeek ("arch": "deepseek41"). DeepSeek's tokenizer has no such tokens and writes them as pieces, so<,|,>,end,of,textandimall counted as "stop here". "Nerazim" isNerazim; the model wrote theim, we treated it as the end and dropped it, which is why you got "Neraz". "Kazim" does the same, and so does any reply that runs into a|or>. The engine's 12 generated tokens include that droppedim. It is not the model or the quant, and it is why llama.cpp is fine.I reproduced it on 2 x A6000 with the IQ2_XS pack: with
"arch": "deepseek41"in the config every Nerazim and Kazim case comes out whole, without it they stop at "Neraz" and "Kaz".Until the fix is out: add
"arch": "deepseek41"to your config (a config started withstrata launchalready has it). The fix, for the next build, serves DeepSeek as DeepSeek when the config names no family and the tokenizer is DeepSeek's, and a stop id is now only ever a marker that is one token, so pieces of<|im_end|>can never end a reply.Could you paste the top of your config (without keys)? If it had no
archthat confirms it, and if it did, we have something else to look for.@cmedinasoriano1 commented on GitHub (Oct 29, 2026):
Yeah, I was experimenting more in the morning and it happens when token "im" (328) is used.
Your arch suggestion fixes it! Thanks for your quick response!
@Niko1221 commented on GitHub (Oct 29, 2026):
This one was on our side, and the word did not matter. The server stopped a reply on the ids of Qwen's
<|im_end|>and<|endoftext|>unless the config said DeepSeek, so pieces such asim,|and>ended it ("Neraz" for "Nerazim"). Fixed in 0.2.8: a config with no arch but DeepSeek's tokenizer is served as DeepSeek, and a stop id is now only a marker that is a single token. Runstrata update. Closing; reopen if a word still gets cut.