You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Delta load: swap compiled variants on a running engine keeping weights on the NPU (ATOM and RNGD) #17
Switching a serving engine to another compiled variant of the same model (batch size, sequence bucket) reloads the whole model onto the NPU. onggi delivers only the changed bytes to the node, and a CSI pod gets a new variant in 4–12 s. The first token still waits for a full model load: 10–13 s on both chips, and 18.9–28.4 s from pod creation (onggi #55). On the NPU, 98.6–99.8 % of the bytes are identical between variants (onggi #38, #54).
Evidence
onggi docs/evaluation.md: ATOM B2 → B8 changes only the first 70 KB and the last 218 MB of 15.2 GB; RNGD pfbatch → preset is 99.77 % same offset.
npu-graph-swap / aicomp #118:
ATOM shares one weight copy between graphs compiled in one session and switches at no cost; a separately compiled graph cannot attach to resident weights.
RNGD can pass resident device tensors (weights) as graph inputs (toy model).
Full reload: ATOM 26–33 s warm; RNGD 7–8 s warm local.
Scope
Delta load in rngd-pd's own engine (no vendor or Optimus Prime changes): a running engine switches variant keeping what is already on the NPU.
RNGD:
Weights stay resident as device tensors; switching loads only the variant's graph.
When weights differ in part, only the changed tensors are uploaded. The byte ranges come from onggi diff --ranges, mapped to tensors through the safetensors header, an open format.
ATOM:
Variants compiled in one session share the weights, and switching selects a graph.
A variant outside the session is prepared in the background (warm pool) while the current one serves, if device memory allows.
A public rebel API that binds external weights is used if one exists.
API:swap(variant) on the engine, plus a load-driven selector hook. Greedy tokens after a swap must equal a fresh load of that variant.
Done when
Swap time (request → first token on the new variant) on each chip is measured against a full reload, with tokens identical.
RNGD: swap ≤ 2 s for a bucket or batch change.
ATOM: swap within a session ≤ 1 s. Outside a session, the background-prepared swap and its memory cost are reported.
The results and how to use it are in the README; CI is green.
RNGD milestone, merged in #21 (CI for the repo added in #20 / #19).
One device copy of the weights is shared by every decode variant (group 8), and swap() loads only the variant's EDF. Measured on one RNGD card, two runs, greedy tokens compared per stream:
Variant
Full reload, launch → first token (s)
Swap, request → first token (ms)
Swap back (ms)
Tokens = full reload
B4, S512
21.8 / 22.3
(initial)
113 / 145
yes
B8, S512
22.0 / 22.2
728 / 941
148 / 275
yes
B16, S512
22.7 / 22.5
867 / 1197
353 / 539
yes
B4, S256
21.4 / 22.3
547 / 732
56 / 63
yes
Device memory: each extra variant costs under 0.25 GiB (33.5 GiB free after the weights, 33.25 GiB with 4 variants loaded).
Partial update: 3 changed tensors (151 MB of 16 GB), planned from onggi diff --ranges through the safetensors header and refined to the rows that really differ. They were uploaded in 0.24 s, with 0.84 s to the first token. Tokens equal a full load of the new checkpoint (22.1 s).
Activity
CI: run the NPU-free tests on every PR (#20)
Delta load on RNGD: one resident weight copy shared by every decode v…
gspark-etri commentedon Oct 22, 2026
RNGD milestone, merged in #21 (CI for the repo added in #20 / #19).
One device copy of the weights is shared by every decode variant (group 8), and
swap()loads only the variant's EDF. Measured on one RNGD card, two runs, greedy tokens compared per stream:onggi diff --rangesthrough the safetensors header and refined to the rows that really differ. They were uploaded in 0.24 s, with 0.84 s to the first token. Tokens equal a full load of the new checkpoint (22.1 s).ATOM is in progress on
feat/delta-load-atom.