Skip to content

docs: qualify four-model prefix-cache page geometry controls - #279

Draft
gspark-etri wants to merge 4 commits into
mainfrom
docs/212-cache-history
Draft

gspark-etri wants to merge 4 commits into
mainfrom
docs/212-cache-history

Conversation

@gspark-etri

@gspark-etri gspark-etri commented Oct 24, 2026 •

Copy link
Copy Markdown
Collaborator

Background

Prefix reuse changes greedy outputs in the mixed128/2048/8192 HTTP fixture. A homogeneous512/2048 cache matrix passed but did not exercise the original partial-prefix history.

Changes

Add four-model page64/page256 evidence and current-runtime cache-off controls, with raw artifact hashes, frozen revisions, reproduction commands and limitations. No engine or default-setting changes.

At chunk256, page64 reproduces concurrent output differences for Qwen3-0.6B, Qwen3-4B and KONI. Page256 has12/12 within-run matches for each selected model and3/3 serial reference matches to each model's current page256/cache-off control. Qwen0.6 reverse-order repetitions retain the difference. Gemma's current page64 within-run failure does not reproduce; its archived-reference difference is after EOS.

Verification

  • Experimental runtime a3497e5; evidence branch based on main fd89265.
  • One A10080GB PCIe, driver580.178.04; torch2.13.0+cu130, Transformers5.15.0; BF16,4slots, context9216, chunk256; exact model revisions in summary.json.
  • Fifteen runs complete:10cache-on and5cache-off. All HTTP lifecycle checks pass. Independent saved-array audit counts180concurrent responses, with17mismatches confined to page64 cache-on arms. Cache counters verify reuse and GPU cleanup is empty.
  • KONI current cold controls match across page sizes but differ from old128/2K records; historical drift is kept separate from the cache effect.
  • Diagnostic source copies verified to change only import path and page-size parameter. Staged sensitive-data scan and git diff --check pass.

Additional partial-prefix controls

The same four models also run280/536-token seeds, which share one/two complete256-token pages with later2K prompts. Sixteen current cacheoff/cacheon runs pass HTTP lifecycle checks; independent saved-array audit gives192/192 concurrent matches and24/24 paired serial references equal. Cache hits are positive in every enabled arm, zero in every disabled arm; GPU cleanup is empty. See experiments/cache-history-212/seed-controls.md and seed-summary.json. This adds two prefix lengths, not eviction/host-reload coverage or general deterministic output guarantees.

Device eviction and host reload controls

Four frozen models, one execution slot,36device pages and two distinct8K prompts:12off/device/host arms completed on2026-10-25 and were independently audited on2026-10-30. All72response arrays match within-arm references; all48device/host responses match cacheoff and16/16A/B reference arrays agree. Each host arm records61offloaded/87reloaded blocks and22272host-hit tokens. Device-only revisits recompute; host revisits reuse7936tokens. Actual removal events, allocation returns and zero remaining live references are checked. A verifier negative control rejects missing reload evidence.

Includes portable diagnostic fixture, raw hashes and verifier in experiments/cache-history-212/pressure-controls.md. Published verifier passes all12raw runs and rejects4missing-reload controls; existing-output guard tested before model load. No host-tier eviction, multi-slot transfer, NPU transport or stable performance claim. All12children exited0; no contemporaneous global GPU-idle snapshot is claimed.

Full native GPU condition grid

Adds the 2026-10-30 matched page256/chunk256 cache-off/on grid for all four selected models: input128/512/2048/8192, output32/128, concurrency1/4/16, BF16 and four decode slots. Eight fresh server arms complete192conditions2752responses (64warmups,1344token checks,1344SSE checks) with zero mismatches against each model's fresh cache-off references. Cache-hit counters and reference hashes are independently checked. All children and coordinator exit0; a fresh GPU-idle snapshot is captured before the next experiment.

Runtime8f9f2a05178bcbb859c97dce2e5ee1bbc23eca3e, one A10080GB PCIe, driver580.178.04, torch2.13.0+cu130, Transformers5.15.0. At8K/128/c4, warm-prefix cache-off/on throughput is Qwen0.6 62.42/185.98, Qwen4 40.59/134.29, Gemma59.14/149.25 and KONI40.82/158.97tok/s. These are single ordered repeated-prefix samples, not cold-input or stable speedup claims.

Includes portable fixture, example config, full timing/hash summary, auditor and12selfchecks. Published fixture changes only require an explicit config and reject existing outputs before model load; both guards tested. Original unsupported-metadata preflight failure is documented separately. Prior full weight-hash identity evidence is distinguished from current metadata-hash/file-size rechecks; weights were not rehashed during this grid. Staged sensitive and whitespace checks pass. See experiments/cache-history-212/full-grid-controls.md.

Compatibility and limits

Page256/chunk256 is a scoped configuration mitigation candidate, not a general numerical fix. Coarser pages reduce reuse in this fixture. Single-burst timings do not establish a stable speedup. Other prompt histories, host-capacity eviction, concurrent reload/fault controls, numerical controls and semantic quality remain open; this does not certify RNGD/ATOM paths. The documented runtime is experimental, not current main.

Related Issue

Related to #212 and #201; neither is closed.

Prepared and verified with Codex assistance. Maintainer review/merge required.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant