KV Cache

The mechanism that lets a LLM avoid recomputing the whole start of a conversation for every new token it generates. It keeps the work already done on the context in memory (the 'keys' and 'values') and only processes what follows. Direct consequence for you: if the start of your prompt stays identical across calls, the model reuses it and it costs far less. It is the engine behind the 'prompt caching' that Anthropic and others bill.

Strengths

Limitations

Best for

Official site

View on Coeurdar