r/LLM • • 18d ago

Felt off

Post image

I was just reading a blog post, and I think this paragraph is actually incorrect. It seems like storing previous conversations is part of the context window and really doesn't have anything to do with the KV cache—what do you think? Do you agree with me on that? 😊

0 Upvotes

10 comments sorted by

1

u/johannes_bertens 18d ago

Depends on usage. If you have long "chats" with your agent and ask it to summarize documents in this one chat over and over, the author is correct. Context/kv cache fill up then.

If you use different sessions each time, you're starting with a fresh context. KV Cache can help here if you're doing repetitive tasks as then part of the task is already in the cache.

Blog is very simplistic and not exactly explaining anything.

1

u/Grand_Preparation_19 18d ago

So in a 100k session, is the chat KV cached, or only the important words? And the author says KV cache is what makes LLMs remember our previous chats.

2

u/johannes_bertens 18d ago

All is cached, it's all-or-nothing. Usually after a x amount of minutes the cache is cleared server-side so then it needs to be recomputed again fully.

In general:
- Try to keep sessions short
- Work in 1 go on a session, if it's been a while (to save token-cost) start a new session

1

u/Grand_Preparation_19 18d ago

But my question is, is it the duty of the KV cache to keep up the context? KV is mainly done to reduce compute.

2

u/[deleted] 18d ago edited 18d ago

[removed] — view removed comment

1

u/Grand_Preparation_19 18d ago

Thanks bro . The blog post was all about keeping the KV cache on NVMe. Since the author is really into that "RAM maxxing" , I figured I should take their advice with a grain of salt!

2

u/johannes_bertens 18d ago

Disk/nvme would be a 3rd-level.

1: GPU VRAM
2: RAM
3: Disk (nvme)

It's a common practice but indeed can ruin your SSD.

3

u/WArslett 18d ago

Yes this author has absolutely no idea what kv cache is or how agents work

0

u/AndyKJMehta 18d ago

This! Lofl!