pub fn pack_store_into_slot(
lw: &mut LoraWeights,
slot: usize,
name: &str,
store: &WeightStore,
peft: &PeftAdapterConfig,
cfg: &ModelConfig,
gpu: &dyn GpuBackend,
) -> Result<Vec<Option<LoraLayerWeights>>>Expand description
2026-09-25: Disk swap: audit store and pack it into existing pool slot
of lw in place, with the same audit_adapter and pack_slot as the
startup load. The slot region is zeroed first, since it still holds the
previous adapter. Then the slot’s name, config and pairs are replaced, its
pointer and scale table entries refreshed, and its generation bumped.
Returns the new pairs so the caller can re-install them when the slot is
active.
Refused, before anything is written: slot >= max_loras, a slot with
in-flight sequences, and adapters with router, expert or token-overlay
tensors.