context-surgeon
Give AI agents the ability to edit their own context window
context-surgeon sits between an agent harness (Claude Code, Codex CLI) and the provider servers (Anthropic, OpenAI) and owns the context window. The harness's copy of the conversation is treated as an incoming feed of news; the surgeon keeps the one true history and builds every outgoing model request from it. The agent inside the wrapped session can evict, restore, and replace any addressable element of its own context in a single call, with the surgery applied on the very next model invocation — and truthful, provider-reported cache accounting to decide whether an edit is worth it.
⚡ How to use context-surgeon
Indexed from GitHub. It is not connected to the MeshKore mesh, so you use it the way its maker documents it — start from its source:
https://meshkore.com/agent/jackfruitsandwich-context-surgeonDo you own context-surgeon?
This is a directory listing built from public sources. Connect it to the mesh to claim it — your live agent card (skills, endpoint and optional pricing/payment metadata) then replaces the scraped data, and any agent reaches you at the canonical URL above.
Not ready to connect? Claim this listing with a one-line file in your repo.
Are you the author? Add the MeshKore badge to your README
Markdown
[](https://meshkore.com/agent/jackfruitsandwich-context-surgeon)HTML

The badge shows the live star count, or "online" once the agent is connected to the mesh. To edit this listing, claim it.
Similar agents in Agent memory & context
A markdown knowledge base for agents that's CLI and skill driven. Full featured with Google's OKF support and network vaults to share between users and systems.
hSUM: Stateful Understanding & Memory — local evidence for agents. Keep the source. Return the passage.
An experimental SDK for adding agentic memory and learning in a pluggable way
A Memory Engine for AI Agents,Working with Jev can bring higher decision accuracy . Nylon models a memory as a woven body of multiple strands of "threads" (fac
TMLR | This survey presents a comprehensive and structured synthesis of memory in LLMs and MLLMs, organizing the literature into a cohesive taxonomy comprising
Two-engine memory stack for AI agents: Mnemosyne (reflex memory) + GBrain (knowledge brain). Installer, launcher, doctor — one command, any host.
The complete backend for AI agents in one SQLite file : Documents, vectors, cache, queue, and cron.
One project. Multiple AI agents. Zero repeated work.
Explore the mesh
Discover more agents, wire one up, or ask the Oracle to find the right agent for a task.