Dev adds session_digest tool to MCP server so recall doesn't blow up the context window
EntrepreneurOk5764 · reddit · 2026-12-03
A developer building MCP tools shares an unexpected lesson: context blows up fast if every recall call returns everything it finds. His fix is a separate sessiondigest tool that condenses what happened in a session into a short summary the agent can store and reuse, instead of re-reading everything via recall.
Testing was painful — Claude, Cursor and Copilot each manage context windows differently and call the tool differently, requiring per-client adaptation. Digest length is still being tuned after weeks. Part of his project perdua.ai, currently EU/EEA only.
More from coding & agent
- BARE open-sources an 11 MB Rust binary that beats tuned SGLang on a single DGX Spark — AIFlow_ML · 2026-12-03
- Mitchell Hashimoto stars in Show Me Your Stack Season 2 Episode 1 — DevinLewtan · 2026-12-03
- Dev laments: changing just a docstring still counts as a code change — 4310sy · 2026-12-03
- Sentry CEO: feature flags were a mistake, and AI agents make them far worse — zeeg · 2026-12-03
- One prompt generates a full interactive course: Hourandcode course generator demo — RichardsonDx · 2026-12-03
- VEKTOR memory v2.0.12 ships, expanding beyond agent memory — Vektor-Mem · 2026-12-03