Repository navigation
ARGUS v0.7.0 — GPU-resident paged attention
ARGUS v0.7.0 — closing the measured gap, exactly
On the one workload measured end to end (Qwen2.5-0.5B-Instruct Q4_K_M, F16 KV, 4K
context, RTX 3050 Ti Laptop), ARGUS prefill went from 2.09x stock llama.cpp's
time to 1.29x with all KV on the GPU, and from 7.4x to 1.36x with the
placement policy managing GPU/pinned/RAM/disk tiers. Decode is now faster than
stock in both modes.
| mode | prefill (median, 5 repeats) | vs stock | decode |
|---|---|---|---|
| stock llama.cpp, host KV | 1.336 s | 1.00x | 37.5 tok/s |
| ARGUS GPU control (diagnostic) | 1.719 s | 1.29x | 55.6 tok/s |
| ARGUS policy on | 1.821 s | 1.36x | 48.2 tok/s |
Exactness. Every ARGUS attention path stays bit-exact with its staged
reference; the output hash is a152ed56 in every mode. Stock llama.cpp uses
tensor-core FlashAttention, which is a different arithmetic contract, so its
output bits differ (007ddc77). The ratios above compare two different
computations. They are one model, one GPU and one context length, not a general
speed claim.
What changed (llama.cpp integration)
- Decode reads GPU pages in place; decode went from 7.5 to 39 tok/s.
- KV appends are written on the GPU, byte-identical to the CPU encoding. In GPU
control they are resolved on the device. - Policy stores write dirty pages back to disk in the background, with verified
double slots. - Attention reads a device page table and returns without waiting, in GPU control
and, when the whole store fits the GPU budget, in policy stores. Page-table
entries change only through stream-ordered publication. - Placement-policy fixes: rewrites keep a page's promotion, and promotion leaves
the attention scratch headroom free. - Models ARGUS cannot serve (MLA, attention sinks, KQ bias, soft-capping, ALiBi,
Grok attention, several KV streams) fall back to llama.cpp's own KV cache at load. - Python runtime fixes: bounded event log with an opt-in trace
(ARGUS_TRACE_PATH);Page.getno longer swallows errors.
Install
pip install torch
pip install --no-build-isolation argus-cache==0.7.0The llama.cpp patches and sources ship in the sdist and the repository; see
README.md → Using ARGUS with llama.cpp.
Full changelog: CHANGELOG.md. Record of every experiment: plans/argus-v0.7.0.md.