What is Context Autopilot?
Automated context collection for coding agents. It mines real agent sessions — every instruction repeated, every correction made, every tool call rejected — and distills them into CLAUDE.md / AGENTS.md rules you approve. Runs 100% locally as a CLI and MCP server.
How to use Context Autopilot?
Install via npm install -g context-autopilot or use npx. Run ctxlayer scan to mine signals from local session transcripts (Claude Code and Cursor), ctxlayer distill to convert signals into proposals via your existing Claude CLI, and ctxlayer apply to review and write accepted rules. Also supports a Claude Code plugin and an MCP server for in-chat use.
Key features of Context Autopilot
- Mines session history for repeated instructions, corrections, and rejected tool calls.
- Distills signals into imperative, project-specific rules backed by verbatim evidence.
- Interactive approve/reject flow; never writes context files without your decision.
- Writes managed blocks into both
CLAUDE.md and AGENTS.md.
- Global mode mines all projects for personal working preferences.
- Staleness check (
ctxlayer stale) finds context file references the repo has outgrown.
Use cases of Context Autopilot
- Prevent re‑teaching agents the same conventions every session.
- Enforce project‑specific constraints (e.g., “staff login cannot access admin view”).
- Capture cross‑session patterns that no single live session can observe.
- Maintain a personal, cross‑project set of preferences for how you like to work.
- Add a CI step that flags stale context entries (missing files, removed npm scripts).
Comments