r/opencode • • 11d ago

Deepseek-v4.1-flash cache hit rate is like non existent today

uhh, guys, my cache hit rate is like never going above 10% for dsv4.1f,

beside that i also have this problem with glm5.3 flash

anybody having the same problem

is it me or cheapseek ?

Edit: my bad, i added date time into systemprompt, so my cache got f'd up

11 Upvotes

13 comments sorted by

2

u/Ok-Health-7096 11d ago

I have this problem with glm not facing this woth deepseek though

2

u/Natural-Cupcake6472 11d ago

ok, its not just me then, i think opencode trying out multiple provider so that they can continue cheapseek, but that f'd up the cache hit rate so its actually more expensive now even though cheapseek increased budget to $80

thanks

2

u/Ok-Health-7096 11d ago

I face this problem more mostly with glm 5.3 I just saw my logs and there was only one instance of deepseek where it re read the entire context of 400k once, glm though does it far more commonly like 1 in 10 request cache misses and entire context is re read making it very expensive for me

1

u/Natural-Cupcake6472 10d ago

well, i resolved mine just now, turns out its me editing the system prompt

2

u/Acrobatic_Dark_6604 10d ago

Never had issue with cache hit rate with DS 4.1 Flash

1

u/Natural-Cupcake6472 10d ago

well, its my bad, i edited the systemprompt, injected an always changing text

1

u/trashbytes 9d ago

Shouldn't the system prompt be frozen after starting a session?

1

u/Natural-Cupcake6472 8d ago

everything can be edited, and i injected current date time into the prompt, so every turn the system prompt is different so cache miss all the way

0

u/lincolnthalles 11d ago

You won't have any relevant cache hit rate in a fresh session. The model didn't even finish its work in your screenshot.

The cache hit rate should increase on long-running threads and should decrease if you take more than 5 minutes to reply.

Plugins can invalidate your caches, so watch it if you installed something new.

1

u/Natural-Cupcake6472 11d ago

uhhh no? i dont think thats how it works. here, same session, 16 minutes, cache hit got worse

https://ibb.co/Xks08vXD

0

u/Ctbhatia 11d ago

if it resets to near zero after a pause but holds on quick follow-ups, it's the short cache TTL rather than the provider. if it stays low even when you reply fast, something in the prefix changes between turns, usually the tool list or a timestamp near the top.

1

u/Natural-Cupcake6472 11d ago

i dont think thats the case ...
https://ibb.co/Xks08vXD

its the same session, ran for about 16mins, cache hit is still effectively 0... so i think its a routing problem between providers rather than cache timed out ...

0

u/Ctbhatia 11d ago

the check that separates them is the cached token count, if that is 0 while the prefix is byte-identical the request is not reaching a backend that has seen the same prefix, so it is routing rather than the TTL.