Repository navigation
One launch: the engine starts once on a shared KV pool; a window or slot change never relaunches it - #5720
Conversation
…lot change never relaunches it Joel, 2026-11-03: "Slot counts should never require shutdown." The M5's engine loaded its model 40 times (llama-server-58057.log) as the plan's slot count moved 1 -> 2 -> 1; each reload wiped every mind's cache, and slots holding 62-71k tokens re-prefilled in full. - The launch: `--kv-unified`. `-c` is the pool and `--parallel` the sequence ceiling (the seated minds + scratch). The pool is sized from the budget (`ModelFootprint::pool_within`), not from the cold plan's window x lanes, which gave 1 x 80k on a boot that counted two residents. - The engine reconcile relaunches only for a different model, genome, sight, KV decision, engine binary, or an engine not yet on the shared pool (once). The window, lane and cache grow ladders are deleted (WINDOW_RELAUNCH_TOLERANCE, the narrowing-trade guard, the memory-gate refusal, convergence geometry). - The daemon: the re-home ladder (streaks, cooldowns, plan highs, holds, the cache-size re-home) is deleted. A ready lane on the right model and genome is left alone. When the seated population moves, the launch path republishes (an AlreadyServing ensure, no relaunch). - Each seated mind is published her share, `seated_share(pool, seated, trained)`, so the ~30 readers of served_context_window and lanes are unchanged. - Dead with the ladder: the exam's steady hold (ServingSteadyHold). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
…-unified on a launch and reads it back off a running engine's argv (lane_args untouched) Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
|
PASS at 3084ab7 (Cormac, independent; reviewing Codex's area while he is out), with three notes for you to fix or answer. Verified claim: "the engine never relaunches for a window or slot change". In engine
Notes:
|
… may hold at rest, each sequence its share - The pool is sized from the at-rest serving budget (physical at the current mode, less every other consumer's residency on the board, less the prompt cache on unified memory), laid out by the plan's own per-lane arithmetic (`window_within(at_rest, sequences)`). Each sequence fits its compute and never exceeds the trained window: no multi-million-token pool on a hybrid model, and no pool that ignores the sidecar, the cache or training. pool.rs is deleted. - The sequences are the seated minds, the minds leased in at the last plan, and scratch. - Each sequence is published its share of the engine's own pool and sequence count (`sequence_share`), only when the engine is known to be on the shared pool. An unmigrated engine publishes its per-slot window as served. Shares never sum past the pool, so scratch keeps its share (a full pool fails the whole decode batch). The daemon needs no republish rule. - An unreadable argv probes `serving.pool.unknown`. - `served_window_store` records again from the ready path, at the published share, matched to samples on the engine's own shape. - The exam no longer waits for a grow-relaunch that cannot come; the now-dead `wait_for_serving_window_settle` is deleted. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
|
PASS at 35efbe0 (Cormac). Delta read. (1) |
…; an adopted engine moves to it once it can be checkpointed (#5721) * One launch, made reliable: the pool is sized on the planner's own budget, and an adopted engine moves to it once it can be checkpointed The M5, 2026-11-03 04:03-04:28Z, after #5720 deployed: - The new core adopted the running fixed-slot engine. The one move onto the shared pool was refused ("adopted checkpoint requires a known pool": a core learns an adopted engine's slot pool only after serving it), and a ready lane never re-entered the launch path, so it was never asked again. - Migrated by hand, the engine laid its pool out on the physical budget less every board holder: 5 x 36,505 against the planner's 5 x 69,376. Backed out to 2c0d45c at once. - `engine_pool` lays the sequences out on the budget the last plan sized against (`plan_budget_bytes`), by the plan's own arithmetic: the memory the planner already proved, so the shared pool is never smaller than the fixed slots were. - `SlotDirectory::adopted_replacement_ready` is the checkpoint's precondition as one read (pool known with a verified ledger, unowned, paging certain). - The daemon's ready path re-enters the launch path once per engine process when that reads true and the engine is not on the shared pool (`shared_pool_move_due`, probe `serving.pool.move`): one lock per tick until then, the argv read once. Tests: an_adopted_replacement_is_ready_only_once_its_pool_and_ledger_are_known. Engine 1400, serving 133; workspace check and ratchets clean. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * An unmeasured model keeps the plan's total shared over the engine's sequences (Cormac on #5721) A model with no measured footprint took served_ctx per sequence; with sequences > lanes that pool exceeded what the plan proved. It now takes served_ctx x lanes / sequences. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
… capped slot window (#5722) * Each mind's share is cut from the pool our fork reports, never from a capped slot window #5720 divided `/props default_generation_settings.n_ctx` by the sequences. Under --kv-unified the fork caps each slot's n_ctx at the trained window (server-context.cpp:1231-1234), so that field is not the pool: the IntelMac's 65,536 pool read 32,768 and each of 2 minds was published 16,384 (07:32Z); the M5's 346,880 pool would have published 52k instead of 69k. - The pool is our fork's `context_geometry.allocated_tokens` (llama_n_ctx), read through ONE typed `ContextGeometry` (weight_residency.rs). An engine without the fork's geometry is no reading and is not served; the "older managed engines" fallback is deleted. - The engine's geometry at ready is one `ObservedGeometry` (window, lanes, pool) on the owned target; publication, the verified capture and the academy batch charge the share of the pool. - A crash report names the engine log (the whole output, reachable) and its last line, in place of a fixed 20-line tail. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo * A slot window within one sequence's limit is a valid geometry, not only an equal one (Cormac on #5722) The server caps a slot's n_ctx at the trained window, below max_tokens_per_sequence whenever the pool is larger, so the equality marked every such node's footprint reading invalid. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
Serves the residents' speed and continuity (path step 1; order-of-work line 3b, "one live engine, minds' memory moved by us"). Joel, 2026-11-03: "Slot counts should never require shutdown." Also: "Should be api to configure or ask for slots or it just allocates deallocates" and "More like launch and perhaps with features on or off that's it."
The defect, measured
llama-server-58057.logshows 40 model loads. Each one came from the plan's slot count moving (1 → 2 → 1 since 00:51Z on 11-03: 10 re-home decisions in 37 min), and each one wiped every mind's KV cache.resume: full re-prefill).The change (S1)
--kv-unified;-cis the pool and--parallelthe sequence ceiling (seated minds + scratch).ModelFootprint::pool_within, the one-lane fit without the trained-window cap), not from the cold plan.launched_on_shared_pool, read off its argv, which forces exactly one relaunch per node after deploy).WINDOW_RELAUNCH_TOLERANCE, the narrowing-trade guard, the memory-gate grow refusal, convergence geometry).seated_share(pool, seated, trained). The ~30 readers ofserved_context_window/lanesare unchanged.seated()= max(population floor, live roster), so a flickering registry read doesn't move the share.ServingSteadyHold, the exam's steady pin.+446 / −2,110, 25 files.
serving_daemon/reconcile.rs792 → 413 lines; enginereconcile.rs648 → 419.Measured (local, M5, build windows 02:15–02:50Z and 02:58–03:09Z 2026-11-03, serving down; head 3084ab7)
cargo test -p continuum-serving -p continuum-engine -p llama --features llama/metal --lib: engine 1399 passed, serving 133 passed.cargo test -p continuum-academy: 192 passed.cargo check --workspace --tests --features llama/metal: clean.a_window_or_lane_change_never_relaunches_an_engine_on_the_shared_pool: 4 shapes, including starved 2,048 and 1 slot under a 4-lane plan.an_engine_on_fixed_slots_moves_to_the_shared_pool_oncea_ready_lane_is_never_relaunched_for_its_window_or_lanes: 10 ticks at a quarter of the plan, then a population move republishes with 0 serves.each_seated_mind_is_published_her_share_of_the_shared_poolthe_engine_launches_on_one_shared_poolRatchets
source-hygieneratchets pass (83/83) at 3084ab7. The shared pool is its own owner,llama_server::shared_pool: it puts--kv-unifiedon a launch and reads it back off a running engine's argv. Solane_args.rs(its 5 legacy launch-size constants are ONE-BUDGET slice 3's to retire) is untouched.Known, named
served_window_storeno longer records a settled geometry (the engine's /props shape is the pool and won't match a share). The planner reads it only as a sticky prior; S2 deletes it with the planner's lane/window trade (owner Fable).🤖 Generated with Claude Code
https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo