This is a terrible compaction strategy that fundamentally doesn't understand how compaction and context management work.
Seems like a lot of people are confused so let's break this down.
1. Compaction isn't a filter
The role of compaction is to clean up history to keep the agent focused, not just deleting noise. It should be used sparingly when context gets too long, not constantly to keep context small.
2. Jev doesn't even know what it's deciding on!
Models use the context of the thread to decide what to keep or not keep in a summary. This implementation goes through on a "line-by-line" (per tool call) basis to decide what should be left or deleted.
Not only does this 32k token context model know very little of what happened before, but (in this implementation) it doesn't even know what the result of the tool call is!
Deleting these things randomly will keep the model from knowing what it's tried and dooms you to end up in "stupid loops" where the model keeps trying the same thing over and over.
3. You're giving up the reasoning entirely
Frontier models from OpenAI, Anthropic, XAI, and Google do not share reasoning traces over the API. They share encrypted payloads, which Jev cannot see (and often will drop).
Anthropic is even stricter with this, requiring you to preserve the entire history in order to get any of the reasoning data. As a result, using this in Claude Code guarantees the model will act way dumber.
4. Models are tuned on their compaction flows
For the last year, Frontier Labs have been including compaction and long runs as part of the training process. These models have learned ways to compact that are more effective than any rudimentary solution.
Fun fact: If you switch models in Codex and compaction is necessary, compaction will run on the model that was previously used in the thread.
5. Cache writes are more expensive than cache reads.
Cache writes are the biggest cost by far for agents. I often see cache write costs go over 60% of my total LLM spend in my personal use of Claude Code and Codex.
Cache writes are insanely expensive when data earlier in the history is changed (because the old cache is invalidated when things change at the top). Every history edit requires a cache rewrite for ANY data past the history edit.
If your history is "1,2,3,4,5,6" and you delete "2", you have to rewrite "3,4,5,6". This is more expensive than leaving "2" in the history.
Good news. Since we're already killing all of the reasoning tokens by doing this stupid compaction strategy, the rewrite cost won't actually be that high because the model is missing so much data! 🙃🙃
6. The implementation is hot garbage.
> "Whatever is not kept is deleted permanently, but the assistant can always re-run a tool or re-read a file."
Good luck with that one.
To be clear: this is a cool experiment and I find it genuinely interesting. That said, if you think this style of bs filtering on a probability threshold is actually a compaction strategy, I highly recommend you just use the defaults in tools like Claude Code and Codex.
You're much less likely to hurt yourself that way.
With the recent wave of vulnerability disclosures, it’s a good time to take a closer look at your own code.
Turn your coding agent into a team of security auditors with the open-source skill that seeded Cloudflare’s vulnerability discovery harness.
The 6 phase approach:
1. Map the codebase
2. Hunt for vulnerabilities
3. Challenge each candidate
4. Record the findings
5. Verify the findings
6. Report what’s confirmed, rejected, or still needs validation
Start your hunt here:
https://t.co/kL5PvcoAYY
@Shiroko_o3o 나쁜 뜻으로 만드신 건 절대 아니시라는 건 알지만....
서비스를 운영하시기 전에 한번 제대로 전자상거래법과 관련된 법률 검토를 해보시는 게 좋으실 거에요..
지금 서비스를 운영중인 운영자측의 리스크가 훨씬 더 많아서 자칫하면 운영자측 책임이 더 많을수도 있어요