self-managed-context skill: let agents edit their own context file, 18k stars on GitHub
RulinShao · x · 2026-10-02
The self-managed-context skill from Agent-Skills-for-Context-Engineering (18.1k stars) lets the model—not the harness—manage its own context window: the live context becomes an editable file the agent rewrites with code tools, deciding what to keep, archive, update, or evict. Key invariants: keep system instructions and the original task outside the editable file, write labeled conversation messages to a file, read it back after each edit, and guard self-editing with pinned prefixes, edit gates, receipts, budget readouts, and rollback on overflow. It also covers prefix-cache costs of mid-context edits. Researchers praised it for making CLM context mechanics tangible.
More from coding & agent
- Product idea: cloud Android VMs and home WiFi proxies to make agents look human — Darpinian · 2026-11-29
- Dev builds stealth Chromium browser after agents got bot-blocked on half the web — Darpinian · 2026-11-29
- Clairvoyance dev reveals 'staff model' agent architecture: one PM, named agents, per-agent inboxes — draginol · 2026-11-29
- Claude Opus Configures Karabiner Media Keys End-to-End, No Human Hands — cantrell · 2026-11-29
- Agentic GraphRAG unifies enterprise knowledge and agent memory in one traversable graph — vm324234 · 2026-11-29
- Coding agent blocked from npm rewrote the whole package from memory — and it worked — Panther1537 · 2026-11-29