RocketKV: Accelerating Long-Context LLM Inference via Two-Stage KV Cache Compression
Paper · 2025 · Payman Behnam, Yaosheng Fu, Ritchie Zhao et al.
Summary
A long prompt can slow down every token of the answer. In a Transformer, attention uses stored vectors called keys and values to draw on earlier tokens. Keeping those vectors in a key-value cache saves the work of generating them again. As the context grows, however, reading the cache repeatedly can become a large part of the cost of producing an answer. RocketKV asks whether a system can keep a much smaller working set of previously seen tokens while still finding the ones that matter to each new step of generation.
RocketKV makes that decision in stages. At the end of the prompt, it uses an existing technique called SnapKV to score prompt tokens using attention from the closing part of the prompt. It retains a broad selection and discards the rest. During generation, a method the authors call hybrid sparse attention makes a fresh, narrower selection for each query. It estimates where the strongest attention scores are likely to occur by examining summaries of groups of nearby keys and reading only the features that matter most to the current query. It then uses the original key and value vectors at the selected positions. The procedure operates at inference time with the existing weights.
The accuracy and efficiency experiments answer different parts of the question. On LongBench, RocketKV with Llama3.1-8B-Ins lost 1.1% in average accuracy at a token budget of 256 and showed almost no loss at 512 and above. On Needle-in-a-Haystack, the same system achieved 100% accuracy at a budget of 256, corresponding to over 400× compression in the paper’s traffic accounting at the maximum sequence length of 109K tokens. In separate decoding tests against full-cache attention, the maximum end-to-end speedup was 3.7× on an NVIDIA A100 and 3.3× on an H100. Peak memory use during decoding fell by up to 32.6%. The compression ratio describes the traffic allowed for cache selection and attention, while peak memory includes other allocations such as the weights.
A conversation introduces a different problem. A passage that seems irrelevant to the current question can become central to the next one. RocketKV-MT keeps the full cache across turns and reapplies the prompt filter when a new turn begins. Each answer can still be generated from a smaller working set, with the full history available when the next filter is applied. On multi-turn SCBench, this change brought accuracy close to a reference that selects the highest-scoring keys exactly at each decoding step. Preserving that ability to revisit the history gives up the main variant’s savings in cache storage.
Deep dive: RocketKV: Accelerating Long-Context LLM Inference via Two-Stage KV Cache Compression
RocketKV speeds up long-context decoding by filtering the key-value cache before generation and selecting a smaller set of entries for each new token. · about 34 minutes to read
The problem and its context
Why caching leaves work to do
Generation proceeds token by token. At each step, attention uses a query associated with the current position to determine how strongly to draw on earlier positions. A key is the vector against which the query is compared. A value is the vector whose contribution is weighted by that comparison. The cache holds the keys and values that have already been computed. When the system advances to another position, it can consult those entries and add new ones as it goes.
Processing the prompt is called prefill. Producing the continuation is called decoding. The distinction matters because decoding repeatedly returns to the history accumulated during prefill and generation. A cached key may have been computed only when its token was processed, yet it remains available to a succession of queries. Under full attention, a larger history gives every subsequent query more stored material to read. The cache thus trades repeated computation for memory use, both the space occupied by the stored vectors and the traffic involved in fetching them.
Memory capacity determines whether the cache and other data fit in the available memory. Memory bandwidth concerns how quickly the data can be delivered to the computations that use it. A method can help with either cost. Keeping the full history but fetching only promising entries reduces traffic while retaining the original storage requirement. Removing entries can also free space, provided that the method has enough evidence to decide what can be discarded. RocketKV concerns both costs and reports them separately.
The burden also grows with batch size. Each sequence in a batch needs its own attention history. The paper illustrates the scale with Llama3.1-70B-Instruct at FP16 precision. In that example, the key-value cache alone needs about 320 GB when the batch size is 32 and the context length is 32K. The illustration concerns the motivation for cache compression. It is a different setup from the paper’s timed decoding tests.
The opportunity comes from the distribution of attention. Earlier work surveyed by the authors found that a small set of positions can carry much of the useful attention at a decoding step. If a method can find those positions cheaply, it can calculate attention using a fraction of the cache. This turns attention efficiency into a selection problem. The method has to save more work in the final attention operation than it spends deciding which entries that operation should use.
What earlier methods chose to share, keep, or read
Some of the earlier research described in the paper changes how attention itself is organized. Cross-layer approaches share cache entries across layers, while other designs remove attention from selected layers or use a mixture of global and local attention. Global attention can address the available history, while local attention restricts which positions a layer considers. These approaches change which parts of the architecture need their own access to a long history.
Other designs reduce duplication across attention heads. A head is a component of an attention layer with its own query. Ordinary multi-head attention can maintain separate keys and values for different heads. Under Grouped-Query Attention, or GQA, several query heads share keys and values as a group. The paper discusses Multi-Query Attention and Multi-head Latent Attention alongside GQA as architectural approaches to using fewer stored key-value representations. RocketKV works with the sharing already present in GQA, so the distinction between a head and a group affects both the method and its budget.
The authors also describe methods designed to work with existing weights. StreamingLLM keeps an initial portion of the sequence and a recent window. As the sequence grows, the window advances while the initial entries remain available. DuoAttention and RazorAttention distinguish retrieval heads, which receive global access, from heads that can use the restricted streaming pattern. The allocation of broad access across heads is itself a way to control traffic and storage.
Other techniques target prefill. MInference searches the attention matrix for patterns that specialized computation can take advantage of. SeerAttention uses a learned gate to choose blocks. XAttention estimates the importance of attention blocks through antidiagonal sums. RocketKV begins with regular prompt attention. The selection it introduces concerns the entries handed to decoding and the attention operations used during decoding.
Eviction and dynamic selection
Permanent eviction decides which entries remain available at later steps. H2O keeps recent positions and positions that account for a large share of attention, which the authors describe as heavy hitters. SnapKV determines which parts of the prompt are useful by examining attention from a window at the prompt’s end. Ada-KV considers how to allocate a limited cache budget across heads. These methods use evidence already available when they make their selection. If a later query needs an entry that was previously evicted, that entry is outside the cache used by the decoder.
Dynamic selection makes a new decision for each query. Quest groups consecutive positions into pages and creates compact summaries of their keys. A query can score those summaries to decide where to look. SparQ and Loki reduce work along the feature axis of a key, the axis that runs through the coordinates of a vector for a head. The resulting estimates guide a more expensive attention operation over the selected entries. This preserves the ability to change the selection from step to step, with the original vectors and any search metadata still occupying storage.
The paper also describes systems that move some of that storage to the CPU. InfiniGen holds the full cache there and transfers selected entries to the GPU when needed. MagicPIG combines a sampling approach with locality-sensitive hashing and CPU offloading. These examples show that the question of which entries to read can be addressed separately from the question of where to store them. RocketKV’s main design reduces the resident prompt cache before applying dynamic selection and is designed to work without CPU offloading.
What an exact selector can establish
The authors use Exact-TopK to ask how much accuracy sparse attention could preserve if it knew which keys to read. The “top-k” entries are the positions with the highest attention scores, with the count governed by the budget. Exact-TopK identifies those entries using exact scores and is treated as if identifying them cost nothing. Its role is to isolate the effect of limiting final attention to a selected set. A deployable method has the additional job of finding that set with limited traffic.
A low score for a practical selector can therefore have different causes. The final set may be too small for the task, or the method may spend that set on the wrong entries. Comparing it with Exact-TopK helps distinguish these possibilities. If exact selection retains task accuracy under a tight budget, the result shows that a small final set can suffice in that setting. It leaves open how to identify the same positions efficiently.
There is also a distinction between the positions needed at one decoding step and all positions needed across an answer. The query changes during generation, so the useful set can change with it. A permanent filter has to preserve enough candidates to support those future selections. A dynamic selector can use a narrower allowance because it makes a separate choice at each step. The design question for RocketKV is how to allocate the available compression across those decisions.
The method, step by step
From an observation to a design
The design begins with a diagnostic on qasper, a task in LongBench. The authors first compare practical cache methods with Exact-TopK using Mistral-7B-Instruct-v0.2. All the practical methods in this comparison lose substantial accuracy once the budget drops below 1024, whereas Exact-TopK shows negligible loss with a budget of 256. For this task and system, the gap motivates looking at the identities of the selected entries. The same small allowance can have a different effect depending on how positions are chosen.
The authors then examine 200 qasper questions at layer 31, head 0. They take the exact selection with k set to 256 at each generation step, collect the distinct indices selected over the course of the answer, and compare the count with the maximum sequence length. The distributions answer different questions. The sequence length describes how much history might be available. The distinct-index count describes how many positions the exact selector actually uses at any point in that run.
In this diagnostic, the sequence length reaches 25,000, while the number of distinct selected indices reaches 1200. For the choices observed there, a filter that could anticipate all the useful entries would have a much smaller pool to preserve than the full length suggests. Finding such a pool in advance is the challenge. The diagnostic knows which positions were used because it has the decoding trace. RocketKV uses measurements available from the prompt to make a practical estimate before that trace exists.
This motivates a broad filter followed by a narrow search. The broad filter excludes prompt entries that appear unlikely to matter across the answer. The narrower decision can then be made anew for each query, with fewer candidates to examine. The framework distinguishes those roles from their implementations. The paper mentions Ada-KV as another candidate for the broad filter and Quest or SparQ as possible selectors for the dynamic stage. The evaluated RocketKV uses SnapKV and the authors’ hybrid sparse attention.
How RocketKV selects cache entries during decoding
The steps in order.
Filtering the prompt with SnapKV
SnapKV treats the final stretch of the prompt as an observation window. The attention scores from that window provide evidence about which earlier positions are likely to be useful. Intuitively, if the closing part of a prompt draws strongly on a passage earlier in the context, that passage is a candidate to keep for generating the answer. The score is computed from actual prompt attention. Its predictive value comes from the relationship between what the end of the prompt attends to and what queries during the answer will need.
RocketKV pools the scores along the sequence, allowing neighboring positions to benefit from a strong score nearby. A relevant passage can contain an identifying term at one position and qualifying information at adjacent positions. Selecting only isolated peaks risks keeping isolated pieces of the passage. Pooling makes the filter favor stretches that contain strong evidence, which matches the first stage’s job of keeping a broad set of useful material.
For standalone SnapKV, the paper uses a pooling kernel size of 7. For SnapKV inside RocketKV, it uses 63 throughout the experiments. The kernel size specifies the span involved in the pooling operation, while the observation window specifies the portion of the prompt whose attention is used to score earlier positions. The authors set the observation window to 32 for single-turn benchmarks and 128 for multi-turn SCBench. A large pooling neighborhood is compatible with the later dynamic stage, which can still make a selective decision inside the retained set.
The original SnapKV chooses positions separately for each attention head. Under GQA, separate choices can cause shared keys and values to be stored redundantly when the same positions are retained by several heads. Following a group-level approach from Ada-KV, RocketKV aggregates the attention scores of the heads that share a cache and uses them to select a common set. The selection therefore respects the unit of sharing already present in the attention architecture.
In the main RocketKV variant, the entries outside the prompt selection are evicted. The retained key and value vectors are kept in their original form. The compression here comes from holding fewer positions. The dynamic stage then has access to the survivors and the entries generated as decoding proceeds. A prompt entry discarded at this point is outside the scope of the subsequent search, so the initial filter must keep enough context to cover changing queries within the answer.
Building a compact search over keys
Hybrid sparse attention, abbreviated HSA, reduces the cost of the dynamic search in two directions. Along the sequence, it groups consecutive keys into pages. Along the feature dimension, it reads a subset of the coordinates in the summaries of those pages. Each direction reduces a different part of the search. A page stands in for several positions, while the coordinate selection limits how much data the search reads about each page.
For every page, HSA stores a vector of coordinate-wise maxima and a vector of coordinate-wise minima. Each coordinate of a summary describes the range of that feature among the keys on the page. A single key need never attain all those extremes together. The summaries give the query a way to ask whether a page might contain a high-scoring key even though finding the actual score would require inspecting individual vectors.
The authors store the summary tensors with a layout aligned to the head dimension, so the implementation can gather particular features efficiently. This detail connects the two reductions. Once the current query identifies which coordinates it wants, the summary representation should make those coordinates cheap to read. The summaries are updated when a new key is produced, giving later queries a search representation that includes the growing continuation.
At each decoding step, HSA selects the query coordinates with the largest absolute values. The reasoning comes from the query–key comparison. A query coordinate of large magnitude has the potential to contribute strongly to a dot product. The sign then decides which end of a key coordinate’s range gives the larger product. A positive query coordinate favors the largest stored key coordinate, and a negative one favors the smallest. HSA reads the appropriate extreme for each selected coordinate.
max(q × Kₘₐₓ, q × Kₘᵢₙ)
Here q denotes the query, and Kₘₐₓ and Kₘᵢₙ denote the tensors of page maxima and page minima. The multiplication sign indicates coordinate-wise multiplication in this expression. max takes the larger of the two products at each coordinate. In HSA, the operation is restricted to the k₁ coordinates chosen by the magnitudes in the query, where k₁ is the feature allowance for the estimate.
The selected coordinate contributions are used to estimate attention scores along the sequence. There are two reasons to treat the estimate as a guide to where to look. The most favorable coordinates in a page may come from different keys. Also, omitted query coordinates can contribute to the full dot product. The page calculation is consequently an estimate of potential relevance. A high page score can direct the search to useful entries even when it differs from the exact score of every individual key in the page.
HSA selects the largest estimated candidates along the sequence. The paper denotes the number of selected indices for the final operation by k₂. The decoder retrieves the original key and value vectors corresponding to the chosen indices and performs sparse attention over them. Approximation controls admission to that operation. The actual attention computation on the admitted entries has the full vectors available.
This distinction also explains what an estimation error can do. A strong candidate that is ranked too low receives no weight in the final sparse attention step. A weak candidate that is ranked high consumes part of the allowance, though the exact attention computation can still give it a small weight. Better estimation matters because the exact computation can refine scores only within the selected set.
Sharing the search within an attention group
In GQA, the same key and value vectors serve several query heads. Preparing a separate selection for every query head would diminish the benefit of sharing those vectors. RocketKV therefore applies key selection to the attention group and gives its heads a common set of indices. Each head still uses its query in the final attention operation.
For the estimation decisions, the HSA description uses sums across the heads in a group. It sums query magnitudes when it needs to identify important feature coordinates and uses signed query sums where sign matters for choosing a page extreme. Magnitudes combine evidence that a coordinate is active even when heads give it different signs. Signed sums preserve the direction needed to decide which side of the key range to read. These operations support a shared search, while individual heads still determine their attention over the retrieved vectors.
Group-level selection is also important when interpreting the token budget. The group shares the data being fetched, so the budget applies to that shared unit. For a per-head method that stores separate selections inside a group, the same traffic allowance must account for the separate sets. This is why the baseline configuration for standalone SnapKV allocates the allowance differently from RocketKV’s first stage.
Expressing traffic as a token budget
The paper uses a token budget to put search traffic and final attention traffic on the same scale. A budget of 512 represents the amount of data in 512 complete key–value pairs. For a dynamic method, the traffic spent finding candidates is included in the equivalent budget. The budget can therefore describe a combination of page summaries, selected features, and full vectors. It does not directly specify how many original prompt entries are stored after the first stage.
The experiments divide the traffic allowance evenly between the estimation step and the final sparse attention step for HSA and the other dynamic selectors. If a method needs large amounts of metadata to decide where to look, that expense then uses part of the same budget that governs the full-vector fetch. The exact oracle is a special case. The cost of its selection is assumed away so that it can answer the separate question of what a perfectly selected sparse set can achieve.
c = S / t
Here c is the overall compression ratio in the traffic accounting, S is the sequence length represented by full-cache attention, and t is the equivalent token budget. The slash denotes division. The same budget can imply stronger compression at a longer sequence length, since full-cache attention would have more positions available to read at that length.
Dividing compression across the stages
RocketKV chooses an intermediate size for the retained prompt cache by assigning a share of the compression to each stage. The assignment is multiplicative. The first stage cuts the candidate pool, and the second reduces the traffic needed to use that pool for a query.
cʳ × c⁽¹⁻ʳ⁾ = c
Here c is the total compression ratio, and r is the split factor, which can range from 0 to 1 in the decomposition. The first term, c raised to r, is the factor assigned to prompt filtering. The second term, c raised to 1 − r, is the factor assigned to dynamic selection. The multiplication sign combines the two factors. The 1 in the second exponent gives that stage the portion of the exponent left after assigning the first stage its share.
r = min(0.2 + 0.06 × log₂(c), 0.8)
Here r and c retain their meanings. log₂ is the logarithm to base 2. The constant 0.2 sets the starting share in the compression regime, 0.06 controls how that share grows with the logarithm of compression, and 0.8 caps it. The min operation takes the smaller of the expression that grows with c and the cap. The paper describes the chosen rule as keeping the factor between 0.2 and 0.8.
At mild compression, the rule puts a smaller share on permanent filtering. Retaining more candidates protects against mistakes made before the answer begins. At stronger compression, too much pressure on HSA can leave it with too little detail to distinguish promising candidates. The rule then shifts more of the reduction to SnapKV, which uses exact attention from the prompt window to decide what to keep. Exact attention in the window gives a stronger basis for its scores, while their usefulness for future queries remains an empirical property.
Within HSA, the authors initially split the stage’s compression evenly on a multiplicative scale across the sequence and the head dimensions. A page must contain a whole number of positions. The sequence-side factor is therefore rounded up, and the feature-side factor is adjusted to match.
p = ⌈c⁽¹⁻ʳ⁾⁄²⌉
Here p names the page size, c is the overall compression ratio, and r is the first-stage share of its exponent. Dividing the remaining exponent 1 − r by 2 gives the equal split across the two dimensions before rounding. The ceiling brackets round the resulting sequence-side factor up to a whole number of positions.
c⁽¹⁻ʳ⁾ / p
This expression gives the head-dimension compression after the page size has been rounded. Its numerator is the full factor allocated to HSA by c and r. Its denominator p is the rounded factor already accounted for by grouping positions. The slash divides the former by the latter.
The paper illustrates the rule with an overall compression ratio of 64×. The split factor is 0.56, assigning 10.3× compression to the first stage and 6.2× to HSA. Within HSA, the page size of 3 gives 3× compression along the sequence dimension. The head-dimension factor is 2.1×. These are the authors’ stated values for the allocation. The example shows how a demanding overall target can be distributed across operations that each make a less severe reduction.
The method is training-free. It uses attention observed in the current prompt and features of the current query. Its adaptive allocation depends on the requested ratio through a fixed formula. The authors choose settings such as the pooling kernel empirically. That configuration work is distinct from learning new weights or fitting a predictor for which keys will matter.
Accounting for storage and traffic
After prompt eviction, the main RocketKV variant holds a fraction of the original cache. HSA needs additional storage for its page summaries. In its comparison with full-cache attention, the paper expresses the auxiliary cost using the equal dimension split before rounding the page size.
(1 / cʳ) × (1 / c⁽¹⁻ʳ⁾⁄²) × 2 = 2 / c⁽¹⁺ʳ⁾⁄²
Here c is the overall traffic compression ratio and r sets the split. The first fraction gives the retained share of the original cache after the prompt filter. The second expresses the reduction in the number of positions represented by the page summaries, ignoring the ceiling on page size. The factor 2 accounts for the maximum and minimum summaries. The expression on the right is the resulting auxiliary storage normalized to the full-cache baseline in the authors’ accounting.
1 / cʳ + 2 / c⁽¹⁺ʳ⁾⁄²
This is RocketKV’s normalized cache storage, including the auxiliary summaries. The term 1 / cʳ covers the retained cache and the second term covers HSA’s metadata. The + sign adds these storage costs. As before, c is the overall compression ratio and r is the share assigned to the first stage.
1 / c
This is the normalized cache traffic under the paper’s budget convention. Here 1 represents full-cache traffic and c describes how far the budget reduces it. This expression concerns the data read for cache selection and attention. End-to-end decoding also includes other operations, and total memory use includes allocations outside the cache.
Under a fixed traffic target, practical selectors can have the same allowance and different storage costs. The paper’s comparison credits RocketKV, DuoAttention, and SnapKV with reducing cache storage. Quest and SparQ still need the cache and auxiliary representations. RocketKV-MT retains the cache for a different reason: a subsequent turn may want to search a part of the history the current turn sets aside.
Preserving the history across turns
RocketKV-MT changes the effect of the initial filter. The filter still defines the working set for the current answer. Everything in the original history remains stored, so the next turn can construct its working set from all the available entries.
The authors describe this with M input entries and a selection of N entries. M is the number of input key–value pairs available at the start of the turn. N is the number of input pairs admitted to the dynamic selector by SnapKV. During the answer, HSA can select from those N entries and the newly generated entries. When the next turn arrives, the full prior input of M entries and the entries generated in the answer are available along with the new input. The new prompt window can then give a high score to a position that was outside the working set before.
1 + 2 / c⁽¹⁺ʳ⁾⁄²
This is the normalized storage in RocketKV-MT under the same analysis. The leading 1 represents the complete original cache. The remaining term is the auxiliary storage for HSA over the filtered set, with c and r serving the same roles as in RocketKV. The variant can keep the decoding traffic allowance of RocketKV because decoding uses the filtered set. Its persistent storage also has to cover the entries set aside for future turns.
The paper discusses a serving arrangement in which separate GPUs handle prefill and decoding. Ordinary RocketKV can transfer the filtered cache to the decoding GPU and reduce storage on both sides. With RocketKV-MT, the prefill side can preserve the full history and send only the current working set to the decoding side. The argument concerns which vectors need to move for each answer and where the omitted entries can reside between turns.
The authors identify other compatibility properties. Full prompt attention leaves room for FlashAttention during prefill. Selection can follow the distribution of heads or groups in tensor parallelism because the method applies the same kind of operation to each unit. The released implementation is called RocketKV.
Experiments and results
Systems, benchmarks, and comparison rules
The accuracy evaluation uses Llama3.1-8B-Instruct, Mistral-7B-Instruct-v0.2, and LongChat-7B-v1.5-32k. The paper shortens their names to Llama3.1-8B-Ins, Mistral-7B-Ins-v0.2, and LongChat-7B-v1.5. Llama and Mistral use GQA. LongChat uses multi-head attention. The setup thus includes systems with a shared cache within each group and a system with cache selection at the head level.
Llama3.1-8B-Ins supports sequences up to 128K in the authors’ setup. Mistral and LongChat support up to 32K. The authors apply compression in all attention layers for Llama and Mistral. For LongChat, they leave the first two layers uncompressed to maintain accuracy. The comparison therefore includes architecture-specific choices about where applying the method is practical.
The benchmarks probe different aspects of long-context use. LongBench supplies a collection of tasks for assessing long-context understanding. Needle-in-a-Haystack, or NIAH, tests whether specific information can be located inside a long input, with position and length varied. RULER tests accuracy across controlled sequence lengths. The multi-turn setting of SCBench gives later queries an opportunity to require history that earlier turns did not use. A high score on one benchmark addresses its own kind of access to context. The suite gives a broader view of how the same cache decisions behave across tasks.
For LongBench, the prompt cap is 127,500 tokens for Llama3.1-8B-Ins and 31,500 for Mistral and LongChat. For longer prompts, the experiment preserves material from the beginning and the end while removing the middle. This happens before the decoding cache policy comes into play. Both full attention and the compression methods are consequently evaluated on the same bounded inputs.
For NIAH on Llama, the authors use 10 input lengths, evenly spaced from 2048 to 81,920 words, and 10 insertion depths at each length. The largest word count becomes approximately 109K tokens under Llama’s tokenization. For Mistral and LongChat, the range is 512 to 20,480 words. The maximum becomes about 30K tokens for Mistral and 31K for LongChat. Word counts specify how the benchmark inputs are varied, while the token counts describe how much sequence the attention systems process.
The RULER evaluation uses 50 examples per task in place of the original benchmark’s 500. The reported length settings for Llama are 16K, 32K, 64K, and 96K. The corresponding settings for Mistral and LongChat are 8K, 16K, 24K, and 32K. SCBench uses Llama3.1-8B-Ins in multi-turn mode with a prompt cap of 127,500 tokens.
Full-KV is the dense reference. It makes the whole cache available to each decoding attention operation. Exact-TopK is the sparse reference with cost-free identification of the exact top entries. Its budget maps directly onto the number of positions used in sparse attention. The practical dynamic methods must spend some of the allowance to estimate which positions to fetch, so their final selection can be smaller at the same stated budget.
DuoAttention divides responsibility between retrieval heads and streaming heads. In this evaluation, when the budget exceeds 640, the streaming heads keep 128 initial tokens and 512 recent tokens, and the ratio of retrieval heads is varied to match the average budget. Below 640, the setup uses streaming heads throughout. The initial allocation is 128 when the budget in that regime is above 256, and 20% of the budget otherwise. The rest goes to recent positions. These settings give DuoAttention a defined way to operate under tight limits on retrieval access.
Standalone SnapKV uses an observation window of 32 for the single-turn tasks and 128 for SCBench, with a pooling kernel of 7. Under GQA, it uses separate head-level selections, so the group allowance is divided across the heads. Quest is adapted to select using scores accumulated within each GQA group. Quest and SparQ both divide their allowance evenly between estimating the top positions and fetching the entries for sparse attention. RocketKV uses the same division for HSA. The authors keep prefill attention dense for the compared methods, including DuoAttention, to focus the experiment on decoding.
The single-turn accuracy tests span token budgets from 256 to 4096. Multi-turn SCBench uses budgets from 1024 to 16,384. The main curves compare benchmark average scores across individual tasks. Full-KV supplies the unrestricted reference across the budget settings. RocketKV-MT is evaluated separately on multi-turn SCBench, where preserving the history can affect the result. Its working-set policy for a single answer is the same as RocketKV’s.
LongBench and targeted retrieval
On LongBench, the authors report that RocketKV leads the practical alternatives across the tested systems, with a more visible advantage at tight budgets. For Llama3.1-8B-Ins, accuracy is nearly unchanged from Full-KV at 512 and above. At 256, the paper reports a 1.1% average accuracy drop. These numbers describe performance across LongBench tasks at the stated budget, rather than the accuracy of the selector against the oracle’s chosen indices.
The reported accuracy losses for Mistral and LongChat are somewhat larger. The authors suggest that Llama may be more robust to sparse attention because of differences in training. They note that Exact-TopK shows a similar pattern across the systems. The oracle observation supports the narrower point that responses to sparse attention vary across systems even with exact selection. Differences in training remain the authors’ proposed explanation.
SparQ performs well on Llama and LongChat at budgets of 1024 and above, while it scores below the alternatives on Mistral in the reported LongBench comparison. Standalone SnapKV remains relatively competitive at small budgets, although its gap to RocketKV grows as the allowance falls. Taken together, these comparisons show why the results are organized across both budget and system. A selector that works well for a particular combination can be more sensitive under another.
NIAH gives a direct test of whether a small cache allowance still permits finding a piece of information buried far from the query. RocketKV scores close to Full-KV across the tested systems even at a budget of 256. With Llama3.1-8B-Ins, it reaches 100% accuracy at that budget. The longest input in this setup is 109K tokens, and the paper describes the corresponding traffic compression as over 400×.
Standalone SnapKV is comparable to RocketKV on the Llama NIAH case. On Mistral and LongChat, its accuracy is more than 20% below Full-KV even at a budget of 1024. The difference across systems matters to the interpretation. On the Llama retrieval task, the broad prompt-based approach can already preserve the required information quite effectively. The results on Mistral and LongChat show a larger benefit from RocketKV’s overall retention and selection policy.
The appendix also breaks NIAH out by position. The visualizations put document length along one axis and the relative depth of the target sentence along the other. The authors report that RocketKV can achieve accuracy close to Full-KV throughout the document, across the tested systems at budgets as low as 256. This comparison checks a property that a single average could hide. A method might retrieve reliably from favored positions and struggle elsewhere, even when its aggregate score is strong.
Length effects on RULER and turn effects on SCBench
On RULER, RocketKV remains ahead of the practical comparison methods across the reported combination of sequence lengths and budgets. Its accuracy loss is small at shorter lengths and becomes more visible as the sequence grows. The authors also report widening gaps between RocketKV and the alternatives at longer lengths. Those trends can hold together. A method can become less accurate in absolute terms as a task grows harder and still preserve more performance than competing methods.
The authors relate the length trend to the effective sequence length discussed by RULER. A system can accept an input of a given nominal length while having more difficulty using the distant context at that length. Introducing sparse attention can increase that difficulty. The paper offers this as an interpretation of the curves, with the controlled comparisons showing the observed dependence on length rather than directly establishing its cause.
SCBench changes what a useful cache policy has to preserve. In the multi-turn tests on Llama3.1-8B-Ins, standard RocketKV performs well against the practical methods when the token allowance is small. SparQ moves ahead of it at budgets of 8192 and beyond. There is also a visible gap between standard RocketKV and Exact-TopK throughout the budget range. A larger allowance for the current decoding operation can leave the problem of earlier eviction intact. The positions most useful to a new turn depend on the new query.
RocketKV-MT improves the benchmark score and reaches accuracy comparable to Exact-TopK across the tested SCBench budgets. The result fits the distinction between the persistent cache and the working set. At each turn the working set can remain small enough for efficient selection, while the prompt window for a later turn can reconsider all history. The comparison puts particular weight on preserving candidate availability between turns.
Measured decoding speed and peak memory
The efficiency experiment uses Llama3.1-8B-Ins at FP16, with a batch size of 1, on NVIDIA A100 and H100 GPUs. The implementation runs in gpt-fast. The authors vary the token budget during decoding and normalize the measurements to Full-KV. The speedup covers the end-to-end decoding phase in this setup, including work beyond the cache selection and attention operation.
Maximum RocketKV decoding speedup by GPU against Full-KV on Llama3.1-8B-Ins
RocketKV records its larger maximum decoding speedup on the A100.
The numbers
| System or setting | × speedup |
|---|---|
| RocketKV on H100 | 3.3 |
| RocketKV on A100 (this paper) | 3.7 |
RocketKV reaches up to 3.7× end-to-end decoding speedup on the A100 and up to 3.3× on the H100. The paper reports that the A100 maximum is 12% higher and attributes the difference to the A100’s lower ratio of memory bandwidth to compute. In that interpretation, cache traffic is a larger constraint on the A100, so reducing it has more leverage over total decoding time.
The maximum peak memory saving during decoding is 32.6% relative to Full-KV. The measurement counts the weights, activations, cache, and other metadata. The authors report the same peak memory usage on the two tested GPUs for the setup. That scope matters because RocketKV’s compression factors refer to cache traffic, and its storage expressions refer to the cache and summaries. Only some of the allocations counted in peak memory respond to those reductions.
The efficiency results and the benchmark scores give complementary evidence. The accuracy tests show what can be retained under different equivalent token budgets. The timing and memory tests show what one implementation achieves on specified hardware. The peak speedup, the peak memory saving, and the retrieval result at over 400× compression are maxima reported for their respective measurements. The paper does not identify them as observations of a single common operating point.
What the ablations show
Isolating the dynamic selector
The main comparisons bundle every design choice in RocketKV. A lead over Quest or SparQ could come from making the pool smaller first, from using HSA to search it, or from both. The standalone HSA ablation tests the selection mechanism by itself against the other dynamic selectors on Llama3.1-8B-Ins. It compares methods that must devote part of the decoding budget to finding promising entries.
HSA leads Quest and SparQ in the reported comparison across the benchmarks shown, especially when the token budget is low. Quest compresses the search along the sequence through page summaries. SparQ emphasizes selecting key coordinates. HSA uses a combination so that the search can work with fewer page representatives and fewer coordinates in each representative. The observed advantage for standalone HSA supports the contribution of the dynamic stage independently of the earlier SnapKV filter.
The result is evidence about the whole HSA selector under those test conditions. The comparison uses complete implementations with different ways of estimating scores. It allows a reader to judge whether the combined selector works better than the tested alternatives. It does not quantify a separate gain from the summary layout, the sign-dependent choice of extrema, or a particular feature allowance. Those details contribute to the implemented method whose overall accuracy is compared.
The small-budget trend also connects to the original qasper diagnostic. Under abundant traffic, an approximation can afford to consult more evidence before making a choice. Under a strict allowance, a method that relies on a single dimension of reduction may need to make that reduction more severe. The reported standalone result is consistent with the design argument that spreading the work across dimensions can preserve more useful evidence for deciding where to look.
Adapting the stage split
The authors compare the adaptive rule with fixed split factors ranging from 0.3 to 0.7 on Llama3.1-8B-Ins. A factor of 0.5 divides the compression evenly between the first and second stages on the multiplicative scale used in the method. Changing the split varies the size of the retained pool and the compression expected of HSA while preserving the target for overall traffic.
Different sequence lengths and budgets favor different fixed factors. A fixed factor can perform well at a particular operating point because it gives the appropriate balance between preserving candidates and limiting search work. When length or budget changes, the same balance can become less effective. The adaptive rule generally yields accuracy comparable to the best fixed factor in the reported settings.
The point of comparison is a collection of fixed settings tried over multiple conditions. The adaptive factor is computed from the ratio of length to budget. It can therefore respond to both kinds of change through the same rule. The study supports using a variable allocation across the conditions tested. It leaves open how a different formula, or one using more information about the current prompt, would compare.
What turn handling and retrieval position reveal
The comparison of RocketKV with RocketKV-MT on SCBench tests a different design issue. Both variants use a filtered set for the current answer, but the multi-turn variant can rebuild that set from the full stored history when another query arrives. The improvement towards Exact-TopK when the full history is preserved indicates that availability across turns matters to the observed gap. It also helps explain why raising the standard variant’s decoding budget alone can leave a gap to Exact-TopK.
The NIAH position visualizations offer another form of analysis. They test whether retrieval degrades in particular regions of the input and how that pattern changes with length and token budget. The authors describe retrieval close to Full-KV across the document with RocketKV, even under tight budgets. This finding concerns the benchmark’s targeted sentence and chosen insertion depths. It shows that the observed retrieval success is distributed across positions rather than attributable solely to a favorable placement.
Finally, the qasper trace gives a reason why a broad initial filter can be useful at all. The set of exact selections accumulated across an answer is larger than the per-step selection and still much smaller than the longest sequence observed in the diagnostic. The evidence illustrates the opportunity for a compact candidate pool. The standalone HSA study and the split-factor comparison then address how to search such a pool and how much of the reduction to expect from it.
Limitations
Limits the authors state
The authors report increasing accuracy loss at longer RULER lengths. RocketKV’s advantage over the practical alternatives persists in those comparisons, but its own results vary with sequence length. Its strongest NIAH result therefore has a specific interpretation: retrieval of the target information can survive a very tight traffic budget in that setup. The long RULER results show that preserving accuracy is harder across a broader range of demands.
The authors identify permanent eviction as a drawback in multi-turn generation. An earlier answer provides a weak basis for deciding what every later answer will need. RocketKV-MT addresses that drawback by keeping the complete history. Its costs include full persistent cache storage plus auxiliary summaries for the active set. The traffic savings are tied to work done for each answer, while memory capacity must still accommodate the history somewhere in the serving arrangement.
LongChat needs special treatment in the evaluation. The authors leave its first two layers uncompressed, whereas the reported Llama and Mistral settings apply compression in all attention layers. This is part of the evaluated recipe. It also shows that a cache policy may need to respect different sensitivity across architectures or layers.
The paper identifies room to improve the gpt-fast implementation through customized CUDA kernels or a more advanced runtime such as FlashInfer. Its suggestion that RTX 4090/5090 GPUs might see larger speedups is an expectation based on the role of bandwidth. The reported measurements concern the A100 and H100. Likewise, the discussion of compatibility with disaggregated serving describes how the cache could be placed and transferred. The measured speedups come from the stated decoding setup.
Limits of the experimental evidence
The oracle is a diagnostic for sparse attention, with exact selection assumed to have zero cost. Its accuracy does not establish that a practical system can obtain those indices under the same traffic and latency constraints. A realistic comparison must include what the selector reads during estimation, and the budget rules do so for the practical dynamic methods. The oracle answers the simpler question of how well a small final set can serve attention when the choice has already been made.
The motivating count of distinct exact selections comes from a particular head in Mistral and from qasper questions. The result makes the idea of a much smaller candidate pool concrete. It provides no measured bound for the distinct selections of every head, architecture, or task. It is also retrospective. The exact indices are gathered after observing the generation steps, while a permanent filter has to predict what will be useful before those steps occur.
RocketKV’s initial filter and standalone SnapKV differ in several ways. The filter in RocketKV uses a wider pooling kernel, selects at the GQA group level where applicable, and retains an intermediate set for another selection stage. The full-system comparison therefore measures the result of those choices together. The standalone HSA and adaptive split studies isolate parts of the design, but the reported comparisons do not assign an independent numerical benefit to every change in the prompt filter.
The traffic budget is normalized to an equivalent amount of key-value data. That convention is useful for comparing estimated fetch volume across unlike methods. Actual speed can also depend on how the implementation gathers entries, updates page summaries, and executes the rest of decoding. The measured speedup includes those effects for the tested implementation. Applying the same budget on a different system leaves actual performance to be measured there.
Benchmark averages should be understood alongside the construction of the inputs. LongBench inputs above the cap are truncated in the middle. NIAH checks access to a specific target with controlled placement. RULER uses a reduced sample count per task. Multi-turn SCBench is reported for Llama3.1-8B-Ins. Together these settings establish a range of observed behaviors, with different levels of evidence for individual tasks, architectures, and conversation patterns.
Finally, the efficiency experiment uses FP16 with a batch size of 1 on Llama3.1-8B-Ins. The motivation includes the high storage demand of larger batches, but the reported timing and peak memory figures do not measure how that larger-batch regime behaves. The procedure leaves prefill attention dense, so the speedup is scoped to decoding. A workload with substantial prompt processing has both costs to account for when judging its overall latency.
What came after
No later citing work is documented here, so there is no follow-up result to report. SCBench, FlashInfer, and the disaggregated serving systems discussed by the authors inform RocketKV’s evaluation or its possible deployment. The paper describes those connections from RocketKV’s side and provides no evidence that they subsequently adopted its cache filter or hybrid sparse attention.
Cite
Cite as Payman Behnam, Yaosheng Fu, Ritchie Zhao, Po-An Tsai, Zhiding Yu and Alexey Tumanov. 2025. RocketKV: Accelerating Long-Context LLM Inference via Two-Stage KV Cache Compression. arXiv:2502.14051.
@misc{behnam2025rocketkv,
title = {{RocketKV: Accelerating Long-Context LLM Inference via Two-Stage KV Cache Compression}},
author = {Payman Behnam, Yaosheng Fu, Ritchie Zhao, Po-An Tsai, Zhiding Yu and Alexey Tumanov},
year = {2025},
doi = {10.48550/arxiv.2502.14051},
eprint = {2502.14051},
archivePrefix = {arXiv},
url = {https://doi.org/10.48550/arxiv.2502.14051}
}This page in Markdown https://md.research.elamur.ai/free/en/papers/behnam-2025-rocketkv-accelerating-long-context-llm/
References
- AI@Meta. Llama 3 Model Card. 2024. OpenAlex ↗ · Scholar ↗
- Ainslie, J., Lee-Thorp, J., de Jong, M., Zemlyanskiy, Y., Lebrón, F., and Sanghai, S. GQA: Training generalized multi-query transformer models from multi-head checkpoints. Conference on Empirical Methods in Natural Language Processing (EMNLP), 2023. our card
- AMD. Instinct™ MI300X Accelerators. https://www.amd.com/en/products/accelerators/instinct/mi300/mi300x.html, 2024. Accessed: 2025-01-07. OpenAlex ↗ · Scholar ↗
- Bai, Y., Lv, X., Zhang, J., Lyu, H., Tang, J., Huang, Z., Du, Z., Liu, X., Zeng, A., Hou, L., et al. LongBench: A bilingual, multitask benchmark for long context understanding. Annual Meeting of the Association for Computational Linguistics (ACL), 2024. our card
- Brandon, W., Mishra, M., Nrusimha, A., Panda, R., and Ragan Kelly, J. Reducing transformer key-value cache size with cross-layer attention. Conference on Neural Information Processing Systems (Neurips), 2024. our card
- Chen, Z., Sadhukhan, R., Ye, Z., Zhou, Y., Zhang, J., Nolte, N., Tian, Y., Douze, M., Bottou, L., Jia, Z., and Chen, B. MagicPIG: LSH Sampling for Efficient LLM Generation. International Conference on Learning Representations (ICLR), 2025. our card
- Dao, T., Fu, D., Ermon, S., Rudra, A., and Ré, C. Flashattention: Fast and memory-efficient exact attention with io-awareness. Conference on Neural Information Processing Systems (Neurips), 35:0 16344–16359, 2022. OpenAlex ↗ · Scholar ↗
- Feng, Y., Lv, J., Cao, Y., Xie, X., and Zhou, S. K. Ada-kv: Optimizing kv cache eviction by adaptive budget allocation for efficient llm inference. arXiv preprint arXiv:2407.11550, 2024. OpenAlex ↗ · Scholar ↗
- Gao, Y., Zeng, Z., Du, D., Cao, S., So, H. K.-H., Cao, T., Yang, F., and Yang, M. SeerAttention: Learning Intrinsic Sparse Attention in Your LLMs. arXiv preprint arXiv:2410.13276, 2024. URL https://arxiv.org/abs/2410.13276. OpenAlex ↗ · Scholar ↗
- Ge, S., Zhang, Y., Liu, L., Zhang, M., Han, J., and Gao, J. Model tells you what to discard: Adaptive kv cache compression for llms. International Conference on Learning Representations (ICLR), 2024. our card
- Ho, N., Bae, S., Kim, T., Jo, H., Kim, Y., Schuster, T., Fisch, A., Thorne, J., and Yun, S.-Y. Block Transformer: Global-to-Local Language Modeling for Fast Inference. Conference on Neural Information Processing Systems (Neurips), 2024. OpenAlex ↗ · Scholar ↗
- Hsieh, C.-P., Sun, S., Kriman, S., Acharya, S., Rekesh, D., Jia, F., and Ginsburg, B. RULER: What’s the real context size of your long-context language models? Conference on Language Modeling (COLM), 2024. our card
- Jiang, A. Q., Sablayrolles, A., Mensch, A., Bamford, C., Chaplot, D. S., Casas, D. d. l., Bressand, F., Lengyel, G., Lample, G., Saulnier, L., et al. Mistral 7b. arXiv preprint arXiv:2310.06825, 2023. OpenAlex ↗ · Scholar ↗
- Jiang, H., Li, Y., Zhang, C., Wu, Q., Luo, X., Ahn, S., Han, Z., Abdi, A. H., Li, D., Lin, C.-Y., et al. MInference 1.0: Accelerating pre-filling for long-context llms via dynamic sparse attention. Conference on Neural Information Processing Systems (Neurips), 2024. our card
- Jouppi, N., Kurian, G., Li, S., Ma, P., Nagarajan, R., Nai, L., Patil, N., Subramanian, S., Swing, A., Towles, B., et al. TPUv4 : An optically reconfigurable supercomputer for machine learning with hardware support for embeddings. In Annual International Symposium on Computer Architecture (ISCA), pp. 1–14, 2023. OpenAlex ↗ · Scholar ↗
- Kamradt, G. LLMTest_Needle In A Haystack. https://github.com/gkamradt/LLMTest_NeedleInAHaystack, 2023. Accessed: 2024-12-14. OpenAlex ↗ · Scholar ↗
- Lee, W., Lee, J., Seo, J., and Sim, J. InfiniGen: Efficient generative inference of large language models with dynamic KV cache management. In 18th USENIX Symposium on Operating Systems Design and Implementation (OSDI), pp. 155–172, 2024. OpenAlex ↗ · Scholar ↗
- Li, D., Shao, R., Xie, A., Sheng, Y., Zheng, L., Gonzalez, J., Stoica, I., Ma, X., and Zhang, H. How Long Can Context Length of Open-Source LLMs truly Promise? In NeurIPS 2023 Workshop on Instruction Tuning and Instruction Following, 2023. OpenAlex ↗ · Scholar ↗
- Li, Y., Huang, Y., Yang, B., Venkitesh, B., Locatelli, A., Ye, H., Cai, T., Lewis, P., and Chen, D. SnapKV: LLM knows what you are looking for before generation. Conference on Neural Information Processing Systems (Neurips), 2024. our card
- Li, Y., Jiang, H., Wu, Q., Luo, X., Ahn, S., Zhang, C., Abdi, A. H., Li, D., Gao, J., Yang, Y., et al. Scbench: A kv cache-centric analysis of long-context methods. International Conference on Learning Representations (ICLR), 2025. OpenAlex ↗ · Scholar ↗
- Ling, G., Wang, Z., Yan, Y., and Liu, Q. SlimGPT: Layer-wise Structured Pruning for Large Language Models. Conference on Neural Information Processing Systems (Neurips), 2024. OpenAlex ↗ · Scholar ↗
- Liu, A., Feng, B., Wang, B., Wang, B., Liu, B., Zhao, C., Dengr, C., Ruan, C., Dai, D., Guo, D., et al. Deepseek-v2: A strong, economical, and efficient mixture-of-experts language model. arXiv preprint arXiv:2405.04434, 2024a. our card
- Liu, A., Feng, B., Xue, B., Wang, B., Wu, B., Lu, C., Zhao, C., Deng, C., Zhang, C., Ruan, C., et al. Deepseek-v3 technical report. arXiv preprint arXiv:2412.19437, 2024b. OpenAlex ↗ · Scholar ↗
- NVIDIA. H100 Tensor Core GPU. https://www.nvidia.com/en-us/data-center/h100/, 2024. Accessed: 2025-01-06. OpenAlex ↗ · Scholar ↗
- NVIDIA. Dynamo: A datacenter scale distributed inference serving framework. https://github.com/ai-dynamo/dynamo, 2025. URL https://github.com/ai-dynamo/dynamo. Version 0.1.1. OpenAlex ↗ · Scholar ↗
- Pawar, S., Tonmoy, S., Zaman, S., Jain, V., Chadha, A., and Das, A. The What, Why, and How of Context Length Extension Techniques in Large Language Models–A Detailed Survey. arXiv preprint arXiv:2401.07872, 2024. OpenAlex ↗ · Scholar ↗
- PyTorchLabs. gpt-fast: Simple and efficient PyTorch-native transformer text generation. https://github.com/pytorch-labs/gpt-fast, 2023. Accessed: 2024-12-12. OpenAlex ↗ · Scholar ↗
- Qin, R., Li, Z., He, W., Zhang, M., Wu, Y., Zheng, W., and Xu, X. Mooncake: A kvcache-centric disaggregated architecture for llm serving. USENIX Conference on File and Storage Technologies (FAST 25), 2025. our card
- Ribar, L., Chelombiev, I., Hudlass-Galley, L., Blake, C., Luschi, C., and Orr, D. SparQ Attention: Bandwidth-Efficient LLM Inference. In International Conference on Machine Learning (ICML), 2024. OpenAlex ↗ · Scholar ↗
- Shazeer, N. Fast transformer decoding: One write-head is all you need. arXiv preprint arXiv:1911.02150, 2019. OpenAlex ↗ · Scholar ↗
- Shoeybi, M., Patwary, M., Puri, R., LeGresley, P., Casper, J., and Catanzaro, B. Megatron-LM: Training multi-billion parameter language models using model parallelism. arXiv preprint arXiv:1909.08053, 2019. our card
- Singhania, P., Singh, S., He, S., Feizi, S., and Bhatele, A. Loki: Low-Rank Keys for Efficient Sparse Attention. Conference on Neural Information Processing Systems (Neurips), 2024. OpenAlex ↗ · Scholar ↗
- Sun, Y., Dong, L., Zhu, Y., Huang, S., Wang, W., Ma, S., Zhang, Q., Wang, J., and Wei, F. You only cache once: Decoder-decoder architectures for language models. Conference on Neural Information Processing Systems (Neurips), 2024. OpenAlex ↗ · Scholar ↗
- Tang, H., Lin, Y., Lin, J., Han, Q., Hong, S., Yao, Y., and Wang, G. RazorAttention: Efficient kv cache compression through retrieval heads. International Conference on Learning Representations (ICLR), 2025. OpenAlex ↗ · Scholar ↗
- Tang, J., Zhao, Y., Zhu, K., Xiao, G., Kasikci, B., and Han, S. Quest: Query-Aware Sparsity for Efficient Long-Context LLM Inference. In International Conference on Machine Learning (ICML), 2024. our card
- Team, G., Mesnard, T., Hardin, C., Dadashi, R., Bhupatiraju, S., Pathak, S., Sifre, L., Rivière, M., Kale, M. S., Love, J., et al. Gemma: Open models based on gemini research and technology. arXiv preprint arXiv:2403.08295, 2024. our card
- Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, L., and Polosukhin, I. Attention Is All You Need. Conference on Neural Information Processing Systems (Neurips), 2017. our card
- Xiao, G., Tang, J., Zuo, J., Guo, J., Yang, S., Tang, H., Fu, Y., and Han, S. DuoAttention: Efficient Long-Context LLM Inference with Retrieval and Streaming Heads. International Conference on Learning Representations (ICLR), 2025. our card
- Xu, R., Xiao, G., Huang, H., Guo, J., and Han, S. Xattention: Block sparse attention with antidiagonal scoring. arXiv preprint arXiv:2503.16428, 2025. our card
- Ye, Z., Chen, L., Lai, R., Lin, W., Zhang, Y., Wang, S., Chen, T., Kasikci, B., Grover, V., Krishnamurthy, A., and Ceze, L. FlashInfer: Efficient and Customizable Attention Engine for LLM Inference Serving. Conference on Machine Learning and Systems (MLSys), 2025. URL https://arxiv.org/abs/2501.01005. our card
- Yuan, J., Liu, H., Zhong, S., Chuang, Y.-N., Li, S., Wang, G., Le, D., Jin, H., Chaudhary, V., Xu, Z., Zirui, L., and Hu, X. KV Cache Compression, But What Must We Give in Return? A Comprehensive Benchmark of Long Context Capable Approaches. Conference on Empirical Methods in Natural Language Processing (EMNLP), 2024. OpenAlex ↗ · Scholar ↗
- Zhang, Z., Sheng, Y., Zhou, T., Chen, T., Zheng, L., Cai, R., Song, Z., Tian, Y., Ré, C., Barrett, C., et al. H2O: Heavy-hitter oracle for efficient generative inference of large language models. Conference on Neural Information Processing Systems (Neurips), 36:0 34661–34710, 2023. OpenAlex ↗ · Scholar ↗