mirror of
https://github.com/Niko1221/Strata.git
synced 2026-12-03 19:03:30 +07:00
[GH-ISSUE #27] Generation stops after few hundred tokens in v0.1.8 #14
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#14
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 @ast321 on GitHub (Sep 27, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/27
Generation stops unexpectedly. This happens via OpenAI endpoint and web chat.
ast@localllm:~/Strata$ ./run-iq3_xxs.sh
loading the model (the first start takes a minute or two) ...
ready: http://127.0.0.1:8080/v1 (OpenAI: /v1/chat/completions, Anthropic: /v1/messages, context 65536 tokens)
open http://127.0.0.1:8080/ in a browser to chat; close this window to stop the model
[strata] reading the prompt: 59 tokens, 1 s so far
[strata] thinking: 14 of max 65469 tokens, 20.0 tok/s, 2 s
[strata] thinking: 37 of max 65469 tokens, 20.9 tok/s, 4 s
[strata] thinking: 66 of max 65469 tokens, 23.1 tok/s, 5 s
[strata] thinking: 91 of max 65469 tokens, 23.3 tok/s, 6 s
[strata] thinking: 110 of max 65469 tokens, 22.4 tok/s, 7 s
[strata] thinking: 130 of max 65469 tokens, 21.6 tok/s, 8 s
[strata] thinking: 151 of max 65469 tokens, 21.5 tok/s, 9 s
[strata] thinking: 177 of max 65469 tokens, 22.0 tok/s, 10 s
[strata] thinking: 200 of max 65469 tokens, 22.0 tok/s, 11 s
[strata] thinking: 231 of max 65469 tokens, 22.9 tok/s, 12 s
[strata] thinking: 255 of max 65469 tokens, 22.8 tok/s, 13 s
[strata] thinking: 288 of max 65469 tokens, 23.7 tok/s, 14 s
[strata] thinking: 301 of max 65469 tokens, 22.9 tok/s, 15 s
[strata] thinking: 326 of max 65469 tokens, 23.0 tok/s, 16 s
[strata] thinking: 346 of max 65469 tokens, 22.7 tok/s, 17 s
[strata] thinking: 370 of max 65469 tokens, 22.8 tok/s, 18 s
[strata] thinking: 395 of max 65469 tokens, 22.8 tok/s, 19 s
[strata] thinking: 429 of max 65469 tokens, 23.3 tok/s, 20 s
[strata] done: 440 tokens in 20 s (23.6 tok/s) (length, cancel=False)
Prompt here was "Tell me 300 jokes" and it it stopped in the middle of thinking. Status in monitor shows "Max tokens". After this there is exception and the engine crashes when trying to request something else.
It did work previously up to the old 1024 token limit and by patching that to a higher number it worked fine up to that number.
@Niko1221 commented on GitHub (Sep 27, 2026):
Thanks for the detailed report and screenshots, they made this findable.
What happened: the engine process died mid-answer. The giveaway is your Monitor after the stop: System RAM 1.9 / 47 GB. While the engine runs, its experts alone take ~43 GB of RAM with IQ3_XXS, so at that moment it was already gone. On Linux, when RAM runs out, the kernel's out-of-memory killer ends the biggest process. IQ3_XXS needs about 60 GB of RAM in total (setup asks for that now), so 47 GB leaves almost nothing for the system. How long an answer survives depends on what else grows in memory, which is why it sometimes got further before.
You can confirm it with:
What was wrong on our side: the server recorded the reply as "Max tokens", cut the stream, and every request after that failed on the dead engine. v0.1.10 fixes that:
For your PC (47 GB): Q2_0 is the size that fits (its experts take ~34 GB); IQ2_XS is borderline. Run
./setup.sh --setupand pick Q2_0, or add RAM for IQ3_XXS.Closing. If
dmesgshows no out-of-memory kill and it still happens on v0.1.10, reopen it withstrata-iq3_xxs.logfrom the Strata folder.@ast321 commented on GitHub (Sep 27, 2026):
Interesting that with yesterdays version it ran for hours without any issues in the same computer never using any swap. Max RAM usage was below 43 GB.
@ast321 commented on GitHub (Sep 27, 2026):
No out of memory errors in dmesg and the main process stays alive but the others are killed. However it seems to run out of VRAM according to the log:
I added --vram-reserve-mib 1024 and now it seems to run fine again, 37000 tokens generated so far without issues.
ast@localllm:~/Strata$ cat strata-iq3_xxs.log
strata generate: this CPU has no AVX-512: the expert kernels run on AVX2
strata generate: native pack: /home/ast/Strata/packs/iq3_xxs experts (largest blob 2.33 MB), token embedding type 21 in mapped host memory (260 MiB)
strata generate: 1466 MiB of weights loaded from /home/ast/Strata/packs/iq3_xxs (302 canonical tensors skipped: served natively)
strata generate: 300 native projection matrices, 1781.11 MiB of weights
strata generate: PLE on, table 320001536 rows of /home/ast/Strata/models/IQ3_XXS/Qwen3.8-Flash-Next-GSQ-RCO-IQ3_XXS-00002-of-00002.gguf
strata generate: expert arena: cudaHostRegister PORTABLE ok; MAP_HUGETLB unavailable (no hugetlb pool configured?); using 4 KB pages
strata generate: loaded 39.97 GiB at 1.08 GiB/s
strata mtp: draft layer loaded, 876 MiB of VRAM (experts 675, dense 111)
strata generate: profile /home/ast/Strata/data/expert-profile.bin: 8000 ranked pairs, built for 8000 slots
strata generate: expert cache auto: 10.08 GiB free, 700 MiB reserved -> 4329 slots
strata generate: expert cache 5800 slots, 9.39 GiB of VRAM; policy is
strata generate: the GPU computes the experts in the cache; it rounds differently from the CPU,
so a reply can differ slightly from a run without the cache (same quality:
bench/results/2026-09-27-cache-parity).
PROFILE, ranked by routing frequency, no eviction.
strata generate: pre-filled 5800 of 5800 slots from the profile; slot 0 verified
strata generate: R4 hit path ON - resident experts are computed on the GPU
strata generate: 11 expert-pool workers + the host thread
strata generate: session is up; locating the head
strata generate: experimental native Q5_K head, 437043200 bytes
strata generate: token graph hit path: 5800 resident experts, decided on the device
strata serve: the prompt path borrows 948 cache slots (1.52 GiB)
strata verify: window up to 6 tokens, 69.2 MiB of device buffers
strata mtp: draft head over 40525 tokens (68.0 MiB)
strata serve: 66 MiB of VRAM free with everything loaded - LOW: requests may stall; lower --max-context or raise --vram-reserve-mib
strata verify: captured the 4-token window (upload no error, sync no error)
strata verify: captured the 1-token window (upload no error, sync no error)
strata verify: captured the 2-token window (upload no error, sync no error)
strata verify: captured the 3-token window (upload no error, sync no error)
strata verify: captured the 5-token window (upload no error, sync no error)