ClaudeMap

Vigil

Claude Code plugin that stretches your usage limit automatically: replays your real sessions daily, finds the cheapest auto-compact window per project, and sets it for you — one install, zero settings

Plugins & Agentsplugincostcontextautomation

Vigil studies how you actually work and tunes the one setting that decides what a long Claude Code session costs: autoCompactWindow. Claude Code shrinks long conversations into a summary, but by default it waits until about 400k tokens, and it uses that same number for everyone, in every project — by then most of the spend has already gone to re-reading. Vigil replays your real sessions under seven different settings and keeps the value that would have cost least; once a project has about 300 requests and three long sessions of history it gets its own window, and everything is recalculated every day as your tools and habits change. The rails are explicit: any setting that would leave you under 60k of working room is refused, a value you set yourself is never touched, and if anything in Vigil fails it stays silent so Claude Code runs as normal. When a session is shrunk, Vigil tells Claude what to hold on to — the goal, the decisions and why, the files, the checks you ran, what is left — and it spots dead weight: agents loaded on every turn but never used. Optional commands: /vigil:auto (current values and reasoning), /vigil:audit (unused agents and skills) and /vigil:kept (a weekly report); undo with /vigil:auto off, remove with claude plugin uninstall vigil@vigil-mcp. No commands to remember, no dashboard, no account; it reads usage numbers and which folder a session ran in — never your prompts, code or files — with no network calls or telemetry. Claude Code plugin (v0.6.0), needs Node 22.18+. MIT; bundled TypeScript under Apache 2.0.

What it does

  • Replays your real sessions under seven settings and keeps the cheapest — for the author, 150k beat both the roughly-400k default and the "obvious" 100k
  • Per-project windows once a project has enough history (about 300 requests and three long sessions), recalculated daily as tools and habits change
  • Hard rails: settings that would leave under 60k of working room are refused, your hand-set value is never touched, and failures stay silent so Claude Code runs as normal
  • On shrink, hands Claude a keep-list (goal, decisions and why, files, checks run, what is left) and reports dead-weight agents loaded every turn but never used
  • Three optional commands (/vigil:auto, /vigil:audit, /vigil:kept) and a one-line undo via /vigil:auto off

When to use it

Best for Claude Code users on metered subscriptions or API spend who want compaction to happen at the moment each project actually saves money, without reading docs or touching settings — and for anyone whose long sessions quietly re-read themselves into their limit.

Getting started

npx github:ssamuels8/vigil-mcp

Prefer to type the install yourself?
claude plugin marketplace add ssamuels8/vigil-mcp
claude plugin install vigil@vigil-mcp

Things to know

The README's savings numbers carry their own tags and are its measurements, not guarantees: 21–73% less (cost of the rest of a task after shrinking at about 100k) and 7–36% less (whole task) come from three live runs, one project, one person, tests passed; the 21%-less-use figure is modelled on the author's 138 sessions against the default, and the effect on a real subscription limit has not been measured yet. Needs Node 22.18+; tested on macOS and Linux, not yet on Windows. A summary is shorter than the conversation it replaces, so some detail can be lost — run /vigil:auto off for sessions that need every earlier detail. Vigil changes only autoCompactWindow (once in your Claude Code settings; per-project values go in that project's personal settings file, which git ignores). MIT; bundled TypeScript under Apache 2.0.

Repository

ssamuels8/vigil-mcp

Charted

Related on the map

  • clawd-conduit

    Plugin / Agent

    Wire all 15 Claude Code hook events into the Clawd on Desk desktop pet — and turn permission requests into a blocking desktop card.

    • hooks
    • desktop
    • notifications
    • claude-code
  • CometixCode

    Plugin / Agent

    An unofficial Rust 1:1 reimplementation of the Claude Code terminal UI, ported file-for-file onto an iocraft TUI framework.

    • terminal-ui
    • rust
    • reimplementation
    • unofficial
  • Abide

    Plugin / Agent

    Hook-level enforcement for the natural-language rules in AGENTS.md and CLAUDE.md — every edit is judged and violations are repaired in the same turn.

    • hooks
    • code-review
    • rules
    • agents-md
  • fast-jev-compaction

    Plugin / Agent

    A Claude Code plugin that replaces the lossy compaction summary with Jev-scored pruning: stale tool calls are dropped, and everything kept stays verbatim.

    • plugin
    • context-management
    • compaction
    • function-hooks
  • Anthropic's official Claude Cowork plugin for financial advisors — eight ready-to-run compliance-aware workflows over the firm's own connectors.

    • official
    • plugin
    • finance
    • cowork
  • Claude ADHD

    Plugin / Agent

    A Claude Code plugin for ADHD brains that remembers what you said but never finished — two-layer capture, session digests, gentle nudges and a focus mode. Yours, not the model's.

    • plugin
    • adhd
    • memory
    • reminders