Repository navigation
A request that names no view end keeps the mind's view end inside the reused prefix (the M5's ~100k-token re-prefills) - #123
Conversation
…side the reused prefix (~100k-token re-prefills on the M5) Measured on the live M5 (engine b5534b5, llama-server-58057.log, 2026-11-16): of ~8.3M tokens prefilled, 6.4M came after a successful checkpoint restore that resumed far behind the matched prefix (e.g. lcp 109,197, resumed at the head checkpoint 9,655, 99.5k tokens re-prefilled). Cause: a short side request (one token, resending the mind's prompt, no view_messages) overwrote slot.prompt.view_end with -1, so the page saved next kept only the head and the prompt's last checkpoint, and the mind's next prompt diverged just before that one. 83 of the 95 pages saved without a view end followed a <=8-token request. carried_view_end (server-view-end.h): a request's own view end wins; one that names none keeps the previous view end while it lies inside the prefix this request reused; otherwise -1. Receipts (qwen35-0.8b, M5): test-server-view-end ok. End to end (a view_messages request, a 1-token side request without one, then a page save): pre-fix "view end = -1", fixed "view end = 993", same build, only this line differing. 0 build warnings. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
|
Codex independent source review of 4ac41f7: no blocking findings. The carry is bounded by the slot's actual retained token count, not the request's full token count or an unverified match estimate. A named boundary still wins; a boundary beyond retained state is discarded. I checked the surrounding prompt-batch/checkpoint code and the exact-boundary/divergence assertions. All eight applicable checks are green (one skipped). The reported real-model before/after page-save evidence supports this narrow metadata repair; I have not independently reproduced that model run on BigMama. Live reuse and act-time proof remains required under Fable's deployment ownership. This does not claim the full saved-page restore path or sampler change is validated. |
…he live reconfigure (S2) Conflicts resolved: - server-test-faults.h: both hooks kept (this line's step_delay_ms, #118's page_io_gate); any() and the startup log name both. - server-context.cpp: slots are created by bind_slots() (a reconfigure re-binds them), so the integration's inline slot setup goes; its page-io pool is created beside bind_slots; the trace/debug/test-fault reads stay where this line moved them (load()). SLOT_SAVE takes #118's page_save / page_restore / page_io_done (off the task loop); those resolve slots through get_slot_by_id, which this line made exact (a parked id is never another mind's slot). Receipt (qwen35-0.8b, M5, 2026-11-16, this merge): 0 build warnings; 20 live reconfigures cycling (16384,4) (4096,1) (12288,3) (8192,2) for (n_ctx, n_seq): a temperature-0 reply identical before and after, the weights loaded once (one load in the log), RSS 1,098 MB before and 1,167 MB after (+69 MB; not claimed flat). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
The largest speed loss on the M5 right now, measured from the live engine log.
Measured (live M5, engine b5534b5, llama-server-58057.log, 2026-11-16)
slot.prompt.view_endwith -1. It resends the mind's whole prompt, generates one token, and carries noview_messages. The next page save then kept only the head checkpoint and the prompt's last one, and the next prompt diverged just before that last one.Change
carried_view_end(server-view-end.h), with three cases:Proof (qwen35-0.8b, M5)
test-server-view-end: ok.view_messages, then a 1-token side request without them, then a page save. Pre-fix the page recordsview end = -1; with the fix,view end = 993. Same build, only this line differs.Measured after deploy
Owner: Fable, in the same serving-down window as #122. On the live M5: prefix reuse in the health line (68% now), the full-vs-restored prefill split from the engine log, and median act time. The card stays open until posted.
Separately, the core should say why a one-token request resends a mind's whole prompt on her slot. I'm tracing it next.
🤖 Generated with Claude Code
https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo