In modern LLM applications like RAG and Agents, the model is constantly fed new context. For example, in RAG, we retrieve relevant documents and stuff them into the prompt.
The issue is that this dynamically retrieved context doesn’t always appear at the beginning of the input sequence. Traditional KV caching only reuses a “common prefix,” so if the new information isn’t at the very start, the cache hit rate plummets, and your GPU ends up recomputing the same things over and over.
CacheBlend changes the game by allowing for the reuse of pre-computed KV caches regardless of their position in the input sequence.
This makes it possible to achieve a 100% KV Cache hit rate in applications like RAG. The performance gains are significant:
CacheBlend works by intelligently handling the two main challenges of reusing non-prefix caches:
An interactive CacheBlend demo is available at: https://github.com/LMCache/LMCache-Examples/tree/main/demo-rag-blending
This is the official technology community of Lemmy.ml for all news related to creation and use of technology, and to facilitate civil, meaningful discussion around it.
Ask in DM before posting product reviews or ads. All such posts otherwise are subject to removal.
Rules:
1: All Lemmy rules apply
2: Do not post low effort posts
3: NEVER post naziped*gore stuff
4: Always post article URLs or their archived version URLs as sources, NOT screenshots. Help the blind users.
5: personal rants of Big Tech CEOs like Elon Musk are unwelcome (does not include posts about their companies affecting wide range of people)
6: no advertisement posts unless verified as legitimate and non-exploitative/non-consumerist
7: crypto related posts, unless essential, are disallowed