一舉兩得:更聰明且更便宜——位元組精確的KV快取嫁接將凍結的小型模型轉化為驗證知識飛輪
Smarter and Cheaper at Once: Byte-Exact KV-Cache Grafting Turns a Frozen Small Model into a Verified-Knowledge Flywheel
July 15, 2026
作者: Sietse Schelpe
cs.AI
摘要
我們報告一種能同時讓凍結的小型語言模型更具能力且大幅降低成本的方法,且無需改變任何權重。經驗證的知識以位元組精確的鍵值狀態工件形式一次性儲存,隨後透過嫁接方式恢復到新的推論上下文中。此恢復是位元精確的:在固定的確定性配置下,嫁接後的logits與全新計算在位元組上完全一致(SHA-256雜湊相等),零Kullback-Leibler散度,並在五十個樣本上100%的argmax一致。我們證明,在具有浮點旋轉編碼的模型中,自身位置嫁接是唯一的數值精確操作點,並在兩個模型規模(12B、31B)和兩個GPU目標上驗證了位元組精確性,其中一個目標通過預註冊的重放進行驗證。在AIME 2025上,凍結的Gemma-4-12B在嫁接經驗證的解決方案庫後,從80.0%提升至93.3%,高於其自身的77.5%及其31B同款的89.2%已發布基準。在重複案例中,基礎模型在401,026個token預算內從未解決的八個問題,通過緩存的經驗證解決方案在總共61個解碼token內得到回答,token數量減少了6,574倍,能耗降低約8,700倍;能力主張的恰當依據在於保留的遷移測試(31B上7/7全數通過)。相同的位元組精確儲存將可用上下文從32,768個token擴展到2,854,766個token,且不增加加速器記憶體,並在相同架構的機器之間實現位元組級別的遷移。我們從行為層面描述此系統;引擎為專有技術,每個報告的數字都有已提交的輸入和輸出雜湊支援,因此無需引擎即可重新檢查評分。
English
We report a way to make a frozen small language model both more capable and dramatically cheaper at once, without changing any weights. Verified knowledge is deposited once as a byte-exact key-value (KV) state artifact and later restored, by graft, into a fresh inference context. The restore is bit-exact: under a pinned deterministic configuration, the grafted logits are byte-for-byte identical to a fresh computation (SHA-256 equality), with zero KL divergence and 100% argmax agreement over fifty samples. We show that own-position graft is the unique numerically exact operating point on a model with floating-point rotary encoding, and we verify byte-exactness on two model scales (12B, 31B) and two GPU targets, one through a pre-registered replay. On AIME 2025, a frozen Gemma-4-12B moves from 80.0% to 93.3% once a verified solution library is grafted, above its own 77.5% and its 31B sibling's 89.2% published anchors. On the recurring case, eight problems the base model never solves within a 401,026-token budget are answered from cached verified solutions in 61 total decode tokens, a factor of 6,574 fewer tokens and about 8,700x less energy; the capability claim proper rests on held-out transfer (7 of 7 at 31B). The same byte-exact store widens usable context from 32,768 to 2,854,766 tokens at zero extra accelerator memory, and moves byte-identical between machines of the same architecture. We describe the system at the behavior level; the engine is proprietary, and every reported number is backed by committed input and output hashes so the scoring can be re-checked without it.