{"slug": "agentbelt-0-3-0-token-optimization-for-local-ai-agents-with-honest-numbers", "title": "agentbelt 0.3.0: token optimization for local AI agents, with honest numbers", "summary": "The developer behind agentbelt released version 0.3.0, adding a Goose adapter and demo GIF to the MCP-based tool that gives AI coding apps like Claude Code, Codex, Cursor, Copilot, DeepSeek and LM Studio shared, audited dev tools. Benchmarking context compaction on a local gpt-oss 20B model with a 16k window, the developer found compaction cut average input tokens on a repeated failing-test-log task from 42,267 to 18,448 while leaving accuracy unchanged at 1/3, but slightly increased tokens on a five-file read task (46,916 to 50,410). The stated takeaway is that avoiding repeated logs is the biggest win for local agents, while shrinking file contents can backfire.", "body_md": "[agentbelt](https://github.com/LovaRK/agentbelt) gives every AI coding app (Claude Code, Codex, Cursor, Copilot, DeepSeek, LM Studio) the same safe, audited dev tools over MCP. Version 0.2.0 added **context compaction** for agents running on local models with small context windows (gpt-oss 20B, 16k context, on a MacBook Air). 0.3.0 adds a Goose adapter and a demo GIF.\n\nI ran the same tasks with compaction off and on, 3 runs each. Token counts are what Ollama itself reported.\n\n| Task | Compaction | Correct | Avg input tokens | Largest prompt | \n|---|---|---|---|---|\n| read 5 files | off | 3/3 | 46,916 | 13,317 | \n| read 5 files | on | 3/3 | 50,410 | 10,269 | \n| failing test log, twice | off | 1/3 | 42,267 | 6,182 | \n| failing test log, twice | on | 1/3 | 18,448 | 3,338 | \n\n**Takeaway:** for local agents, the biggest win is not repeating the same logs. Shrinking file contents can backfire.\n\nFull method and raw results: [docs/token-optimization.md](https://github.com/LovaRK/agentbelt/blob/main/docs/token-optimization.md)\n\n```\nnpx agentbelt setup\n```\n\nThen ask your AI app: \"Use agentbelt's agent_run with compact: true to …\"\n\n⭐ If this is useful, a star on [GitHub](https://github.com/LovaRK/agentbelt) helps other developers find it. And if you run agents on local models, I'd love to hear what you've measured.", "url": "https://wpnews.pro/news/agentbelt-0-3-0-token-optimization-for-local-ai-agents-with-honest-numbers", "canonical_source": "https://dev.to/plova_rama_5254efcc1133ae/agentbelt-030-token-optimization-for-local-ai-agents-with-honest-numbers-3kfa", "published_at": "2026-11-14 08:08:07+00:00", "updated_at": "2026-11-14 08:20:29.387090+00:00", "lang": "en", "topics": ["ai-agents", "ai-tools", "agent-protocols", "developer-tools", "large-language-models"], "entities": ["agentbelt", "Claude Code", "Codex", "Cursor", "Copilot", "DeepSeek", "LM Studio", "Goose"], "also_reported_by": [], "alternates": {"html": "https://wpnews.pro/news/agentbelt-0-3-0-token-optimization-for-local-ai-agents-with-honest-numbers", "markdown": "https://wpnews.pro/news/agentbelt-0-3-0-token-optimization-for-local-ai-agents-with-honest-numbers.md", "text": "https://wpnews.pro/news/agentbelt-0-3-0-token-optimization-for-local-ai-agents-with-honest-numbers.txt", "jsonld": "https://wpnews.pro/news/agentbelt-0-3-0-token-optimization-for-local-ai-agents-with-honest-numbers.jsonld"}}