Replacing all MCP tools with one JS-executing tool halved tokens and improved evals
dosco · x · 2026-12-01
Kaspars Dancis reports that replacing all MCP tools with a single "run" tool that lets agents execute JavaScript cut token usage by half, made the agent faster, and improved eval scores. dosco notes this is exactly the RLM setup his ax-agent has used from the start:
- Tools are just functions inside a REPL; the model writes code to call them and prints only the bits it needs
- Tool schemas and tool outputs therefore never pile up in the prompt
- This is why the agent can handle any number of tools and still work on small models like Gemini Flash-Lite
A reusable agent-engineering trick: let the model orchestrate functions via code instead of stuffing dozens of tool schemas into context.
More from coding & agent
- GitHub explains how multiple small AI reviewers beat one big model in Copilot code review — GitHub Blog AI/ML · 2026-12-01
- GPU kernel overfitting is a feature, not a bug, says Anthropic-supported tool author — jmschreiber91 · 2026-12-01
- Confidence scoring loop for agents: requery until the answer is reliable — Puzzleheaded-Can3016 · 2026-12-01
- A weekly x-bookmarks skill turns expert tweets into real app optimizations — DanielLockyer · 2026-12-01
- Google Antigravity adds /swarm and /generative-ui to visualize multi-agent coding teams — rseroter · 2026-12-01
- A PM's GitHub masterclass: 9 AI agents and 9 skills for non-engineers — marilynika · 2026-12-01