TRANSMISSION // 2611.32954v1

How LoomKV makes more room for AI memory

Source published

LoomKV uses lossless compression to fit more language-model KV cache in storage tiers and GPU memory. Tests show gains when capacity is a bottleneck, with trade-offs and limits.

AI-generated conceptual illustration for How LoomKV makes more room for AI memory
AI-generated conceptual illustration; not documentary evidence.

Language models can reuse saved computation when a request repeats earlier text, but the numerical cache behind that shortcut takes up memory. LoomKV proposes storing this key/value (KV) cache in fewer bytes without changing its stored values. The authors test whether those savings can improve serving when memory is tight.

For a language model, remembering a long conversation or prompt takes more than keeping the words. During processing, the system builds a key/value (KV) cache: numerical information used by the model’s attention mechanism. Reusing that cache can avoid processing a repeated prefix again, but the cache consumes substantial memory. When GPU memory fills, requests may wait; when external memory tiers run short, cached prefixes may be evicted and have to be recomputed.

A team led by Wentao Zhu calls its proposed solution LoomKV. Its practical question is whether a serving system can store KV data in fewer bytes without changing the data—and turn those savings into useful capacity without adding too much delay.

Compressing patterns in the numbers

LoomKV targets a regularity in BF16, a format used to store model values. It leaves each value’s low byte unchanged and encodes its high byte using a calibrated codebook. The code uses fixed-width 3-bit symbols for common values, with escape codes for less common ones; it is not a variable-length code in which frequent values receive shorter symbols. The authors calibrate model-specific codebooks offline using a 1024-token forward pass.

The system has two modes for different bottlenecks. In tier mode, it compresses KV data stored in host DRAM and SSD, then restores the original values when loading them onto the GPU. In pool mode, it also keeps the GPU’s KV pool compressed; a custom attention kernel decompresses values as it uses them. Extra SSD capacity does not make room for more active requests in GPU memory, and a larger GPU pool does not by itself keep more past prompts in external storage.

The engineering is designed to make the savings usable. Tier mode allocates external records at their actual compressed length and decompresses directly into the GPU’s existing, scattered memory pages. Pool mode packs variable-length records into shared-budget GPU pages and combines decompression with attention. The paper reports an implementation with LMCache and vLLM that does not modify the serving engine itself, although pool mode uses an additional attention backend.

Results depend on where memory runs short

Across nine evaluated models, LoomKV stores BF16 KV data at about 70–71% of its original size. For FP8 KV, the reported ratio is about 85–87%. These are storage ratios, not direct measures of faster responses: the benefit depends on whether the saved bytes relieve a real capacity constraint.

In tests replaying AgentX coding-agent sessions, tier mode’s compressed storage behaved like raw storage with roughly 1.4 times the capacity. Near the tested cache’s eviction cliff—where prefixes can disappear before reuse—the paper reports 2.7–3.6 times raw’s goodput, meaning the rate of requests meeting the study’s latency targets. Across the stated LRU-cliff comparisons, it also reports 1.9–3.1 times lower mean time to first token (TTFT) than raw storage. When raw tiers already held the working set, the advantage largely disappeared; compression cost up to 2.2% of throughput in the reported ample-capacity tests.

When external tiers held the working set but GPU memory limited concurrency, pool mode fit about 1.31–1.34 times as many KV tokens in the same GPU budget. In one setup, it allowed 12 long requests with roughly the queue and goodput of a raw pool admitting eight. On a separate, production-derived AI IDE trace where both levels were constrained, the paper reports goodput gains over the raw configuration of 1.24 times for tier mode and 1.59 times for pool mode.

“Lossless” needs qualification. Tier mode restored KV values and produced outputs bit-for-bit identical to the raw-tier baseline in the tested models. Pool mode also stored KV values losslessly, but its fused attention kernel sums values in a different floating-point order. Its results therefore matched the reference up to rounding differences, rather than being bit-identical to the stock attention backend.

Promising tests, bounded evidence

These results come from a systems evaluation, not a test of every deployment. The main experiments used two H800 GPUs, vLLM and LMCache, and replayed recorded agent sessions; the second workload was an internal AI IDE trace. The authors report three runs per experiment and give medians, while noting greater variation near capacity cliffs. The evaluation focuses on single-node serving over PCIe.

The authors identify pipeline and expert parallelism, multi-engine shared cache servers, multi-head latent attention (MLA), and FP4 KV as untested. Pool mode currently supports BF16 and FP8 KV, 128-dimension heads, grouped-query attention group sizes up to 8, and 128-token blocks. These constraints matter when judging whether the reported results transfer to another system.

LoomKV is described in an arXiv preprint. The reported results are from the authors’ evaluation, and should not be taken as a guarantee of production gains. The conditional takeaway is that LoomKV may provide more effective cache capacity when memory is the bottleneck, at the cost of implementation complexity and some overhead. Whether that trade-off pays off depends on which part of a serving system is full and how closely its workload matches the tests.

Reviewed cross-references

These connections were reviewed by a model, not independently fact-checked by a human. Similarity does not imply agreement; consult the original papers and the evidence below.

  • A runtime memory strategy could help AI agents serve more tasks

    Supporting evidence: Both papers report KV capacity as a serving constraint: LoomKV describes GPU-pool limits on concurrent long requests, while Contexture reports shared KV saturation limiting agent-session throughput. This supports the bounded point that KV capacity can constrain serving in their evaluated workloads; it does not compare the systems or establish that either remedy generalizes beyond those settings.

    Model review: · openai-codex/gpt-6-luna

    Evidence and provenance

    Selected excerpts, not complete papers. PDF extraction can omit figures or damage equations, tables and reading order; sources may be preprints.

    • 2611.32954v1 — Original paper

      Excerpt reference: static/papers/2611.32954v1.md:311-425
      Basis: Paper text
      Source SHA-256: 3e7e6f7a776a62e82f813019ce2bdba4a5c1ad544d4e6527a6e95a85c58f2cef

    • 2611.26980v1 — Original paper

      Excerpt reference: static/papers/2611.26980v1.md:387-458
      Basis: Paper text
      Source SHA-256: 5978c864e59792f081d06231360a3e4b6c75c9f25c53f7fe4f6e468dbb0185af

Automatically matched by shared topic keywords. These links do not imply that the sources agree or establish a consensus.