Save 75% on Claude Code: Open-Source Tool Optimizes Agent Memory
shhdwi · reddit · 2026-08-03
A developer shared an open-source tool called Graft that drastically reduces Claude Code costs by preventing the agent from repeatedly scanning the codebase.
How it works: The tool pre-scans the repository and saves its structure as a linked Markdown file in Git. Claude reads this file before executing tasks, avoiding the need for numerous tool calls to understand the context. It plugs natively into Claude Code's hooks system for fully automated operation.
Benchmark results (over 162 runs):
- 46% fewer tool calls
- Up to 4x fewer tokens consumed
- 60% less time spent
- Significant cost reductions, enabling Sonnet to achieve Opus-level performance.
Related event: Open-Source Tool Optimizes Claude Code to Cut Costs(3 posts)→
More from coding & agent
- Hugging Face's Open-Source Speech-to-Speech Project Crosses 10k GitHub Stars — andimarafioti · 2026-08-03
- Cloudflare Workers RPC Now Supports Cross-Language Calls Between Python and JavaScript — ritakozlov · 2026-08-03
- Cloudflare Launches Billable Usage API for Programmatic Cost Visibility — ritakozlov · 2026-08-03
- Agent Skills Are Run Books, Not Programs: A Warning Against Massive Prompts — psobot · 2026-08-03
- Fixing MCP failure detector: false positives traced to SDK error code overloading — Thirumalaiboobathi · 2026-08-03
- Cloudflare Launches @cloudflare/computer: A Dedicated Runtime Environment for Every Agent — threepointone · 2026-08-03