Error Certificates for KV-Cache Eviction via Randomized Design
AuthorsPeng Xie
Resources
Randomly sampling what an AI forgets lets its serving system tell whether a bad answer came from cache compression or from the model itself.
Key results
Coverage of realized attention-output error in Qwen2.5-1.5B offline replay at the 12.5% eviction budget.
Spearman correlation between the certificate and true attention-output error at the 12.5% budget.
Mean certificate–failure AUC across 16 of 16 model–task cells using four models and four RULER-style tasks.
Pooled certificate AUC for predicting its own task failures at 6k-token contexts.
AUC for distinguishing eviction-induced failures from inherent failures among LongBench failures.
What the paper found
Peng Xie of the Technical University of Munich argues that deterministic KV-cache eviction, including top-k strategies such as H2O and SnapKV, cannot reliably estimate the attention error caused by deleting tokens: unseen evicted values can change arbitrarily while every retained statistic remains identical. The proposed remedy is certainty-plus-Poisson tail sampling with known inclusion probabilities, a Hájek correction implemented as the logit offset log(1/πi), and a retained-set Sen–Yates–Grundy variance estimator converted into an empirical-Bernstein error certificate; it requires no training or new matrices and supports an e-process extension for trajectory-wide monitoring. In offline replays of Qwen2.5-1.5B, certificate coverage reached 96.9% at the 12.5% budget, while certificate-to-attention-error Spearman correlation reached 0.943. Across four models—Qwen2.5-1.5B and 7B, Llama-3.1-8B, and Mistral-7B-v0.3—on four RULER-style tasks, certificate–failure AUC was positive in 16 of 16 cells, with mean 0.836. The real-world LongBench study is more restrained: failure prediction AUC was only 0.555 at 6k contexts and 0.572 at 16k, losing to mean output log-probability. The certificate’s practical advantage is attribution rather than prediction: among failures, it separated cache-induced from inherent errors with AUC 0.749 at 6k and 0.727 at 16k, outperforming confidence signals and improving recomputation scheduling. Randomization therefore makes compression damage identifiable, but it does not reveal whether the model will fail overall.
Original abstract
Deterministic KV-cache eviction keeps the top-$k$ tokens under an importance score and deletes the rest. We prove that this design cannot know what it destroyed: evicted values can be altered so that everything the serving system retains is unchanged while the true attention-output error grows arbitrarily, so no serving-time estimator of that error is consistent. Randomized eviction restores identifiability. With a Poisson-sampled tail at known inclusion probabilities, one logit offset performs the Hájek correction inside the softmax, and a survey-sampling variance estimator over the retained set becomes a per-step error certificate with 0.97 empirical coverage at no accuracy cost. On real workloads we pre-registered seven claims and lost three: question-aware eviction at 25--50\% budgets is nearly free; output log-probability predicts failure better than the certificate; certificate-gated budget escalation adds nothing. What survives is attribution: the certificate separates cache-induced from inherent failures (AUC 0.73--0.75, against 0.47--0.54 for output confidence) and schedules recomputation better than random or confidence gating. Randomization buys attribution, not prediction.
Read the original paperMore in Efficient AI
Browse all 79 papers →Latent Feedback Is a Compute and Data Amplifier
Benhao Huang, Chaitanya Dwivedi, Xuezhe Ma, Alexander Moreno, Hector Liu
Latent feedback may let language models get more value from each training token and FLOP than simply repeating the data.
MACaQ: Fast, Model Agnostic Calibrated Quantization for Low-Precision Weights and Activations
Lorenz K. Muller, Philippe Bich, Chiara Boretti, Hyun-Min Chang, Jiawei Zhuang, Lukas Cavigelli
MACaQ aims to make large neural networks cheaper to run by quantizing their weights and activations quickly, with little added inference overhead.
Mobile AI Factory: Building Specialized Language Models for Your Mobile Device
Evan Li, Krishna Deshpande, Wen Cheng, Shyamnath Gollakota
Mobile AI Factory automatically builds and tunes a small language model for a specific task and phone, aiming to deliver strong performance with less compute.