logoalt Hacker News

__natty__yesterday at 8:05 PM1 replyview on HN

So it makes sense to first send stable prompt, reasoning and files content, tool calls summary and actual tool calls at the very end?


Replies

leemooreyesterday at 11:26 PM

The way you do this (and the way opencode does it) is you do most of your pruning in more recent history. Last I looked at opencode, they start pruning tool call results after 2 full agentic turns. So you probably dont get quite as good hits on cache for the most recent 1-5% of your turns, but after that everything else caches fine and those tool calls that likely aren't relavent to your session anymore are gone.