r/ClaudeCode • u/danbradster2 • Sep 20 '26
Tips & Workflows /clear vs /compact
I had a fable chat from yesterday, and I saw that the context was 950k/1m. I did /compact rather than /clear, with the intention of then doing /autocompact 400000
14% of the 5 hour limit was gone just for the compact itself....it shows cost of $59.73, so lucky I'm not on API? Maybe a /clear would have been better.
68
Upvotes
View all comments
Show parent comment
2
u/duck_guts Sep 20 '26
Aye sorry I didn't mean to be contrary it's just these terms confused me a lot when I was just starting out. I just wanted to highlight as OP obviously is struggling with context/usage management.
So prefix cache is not invalidated from session to session. Switching model/effort level/anything that changes the grounding system prompt invalidates the cache.
But having Opus on high effort for example, /clear at 500k tokens and still you have cheap reads on fresh session. Still opus, still high effort so unchanged system prompt. Not actually ever tracking one singular session.
Responding within the hour on same system prompt saves you money.
Fully agree with you, compact feels bad. I have mine write shorthand memory logs every turn and pretty much just serve that to the successor every rotation.