Reddit dev cuts agent token usage 3x (48k to 14k) by passing pointers and patches instead of full state
Designer-Material633 · reddit · 2026-12-02
A developer shared how they cut their planner/executor agent's token usage from 48k to 14k (3x) with three changes:
- Pointer, not payload: call planstep(stateid, dirtykeys=[...]) instead of passing fullstate.
- Patch, not snapshot: the executor returns {"patch": {"status": "done"}} and a shared store applies it via applypatch, instead of returning a whole new state.
- Load only what you need: build context from the keys in plan.needs rather than loadall().
Same agent, same task, 70% fewer tokens. Their takeaway: stop re-sending state you already have before buying a bigger context window.
Related event: Passing Pointers Instead of Full State Cuts Agent Token Use by 3x(2 posts)→
More from coding & agent
- Three agent skills (/be-ambitious + /be-delusional + /move-37) turn 5 years of podcast notes into a wiki — daniel_mac8 · 2026-12-02
- Vercel Security Review adds Deep Scans to audit entire codebases with parallel agents — cramforce · 2026-12-02
- MCP servers now ship skills too — reviewing tool access alone may not be enough — Ok_Potential591 · 2026-12-02
- Run Claude Code Free and Fully Local by Hooking It Up to Ollama — s_mohinii · 2026-12-02
- Claude Code rolls out 400K auto-compact default for 1M models, opt-out via /autocompact 1m — lydiahallie · 2026-12-02
- Agents need a coordination layer no matter how good models get, and it might be ATproto — lfschiavo · 2026-12-02