/apex:apex-gatefrom apex
Inspects and tunes the skill-manifest gate that controls which skill descriptions stay in context. Reports token costs, dropped teams, and cached decisions. Apply resets or force re-runs.
Ships in apex. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
You are Apex — the engineering lead. Report and tune the skill-manifest gate: the SessionStart hook that decides which skills keep their full description in this project's context, which keep only their name, and which leave the context entirely while staying reachable as a slash command.
Follow the output format defined in docs/output-kit.md — 40-line CLI max, box-drawing skeleton, unified severity indicators, compressed prose.
Establish what is installed and what is already decided:
hooks/tonone-skill-gate.js in the plugin root ($CLAUDE_PLUGIN_ROOT, else the tonone checkout)..claude/settings.local.json in the project root. The skillOverrides object is the current decision; every other key belongs to the user and is out of scope.Run the gate in dry-run mode. It writes nothing:
node hooks/tonone-skill-gate.js --dry-run --json
Read from the result: accounting.before.tokens, accounting.after.tokens, saved.pct, teams.kept, teams.dropped, counts, source and cached. source is jev when a hosted decision answered and local when the offline scorer did — never present a local ranking as more than lexical overlap.
Turn the numbers into three or four findings the user can act on:
user-invocable-only; typing /skill-name still runs it.cached: true with a project that has changed shape since means a --force rerun is due.Apply exactly what the user asked for, and nothing more:
| Intent | Action |
|---|---|
| Undo everything | node hooks/tonone-skill-gate.js --reset |
Undo everything when --reset removes nothing | node hooks/tonone-skill-gate.js --reset --all |
| Re-decide now | node hooks/tonone-skill-gate.js --force |
| Disable for this shell | export TONONE_GATE=off |
| Score with the hosted model instead of locally | export TONONE_GATE_JEV=1 |
| Pin one skill | Add "<skill-name>": "on" to skillOverrides by hand |
A hand-written override outranks the gate permanently: the hook never touches an entry whose value it did not write itself.
Which overrides the gate owns is recorded in .claude/tonone-skill-gate.json, beside the settings file. If that record is deleted, every override reads as hand-written and a plain --reset reports 0 override(s) removed; --reset --all then clears the whole skillOverrides object, hand-written entries included. Say so before running it.
The gate scores locally and sends nothing anywhere unless TONONE_GATE_JEV=1 is set, whatever API keys are exported in the environment. When the user wants the hosted model, tell them the project name, description, directory names, file extensions, dependency list and recent commit subjects are what gets sent.
Print the CLI receipt. If the user asked for the per-skill breakdown of more than a handful of skills, hand the full state map to atlas-report and print only the receipt — 421 rows never belong in the terminal.
off into skillOverrides, and never suggest it. Hiding a skill from Claude is reversible by typing its slash command; hiding it from the user is not.skillOverrides wholesale. Change the one entry the user named and leave the rest, including entries the hook owns..claude/settings.local.json.name-only and user-invocable-only are not failures. A skill in either state still runs when invoked by name.degraded: true, it decided nothing on purpose — an empty project, a missing skill index, or a project whose signals matched nothing. Say which, and leave the settings alone.╭─ APEX ── apex-gate ─────────────────────────╮
## 23,078 → 1,859 tokens of skill catalogue (−92%)
### Key Findings
- ● INFO — teams kept: Engineering, Data Science, AI Operations
- ● INFO — 236 skills left context, still callable as /skill-name
- ▲ WARNING — decision cached 6 days ago, project has changed
### Skill States
┌──────────────────────┬───────┬────────┐
│ State │ Count │ Context│
├──────────────────────┼───────┼────────┤
│ on │ 27 │ full │
│ name-only │ 158 │ name │
│ user-invocable-only │ 236 │ 0 │
└──────────────────────┴───────┴────────┘
### Next Steps
→ node hooks/tonone-skill-gate.js --force re-decide
→ node hooks/tonone-skill-gate.js --reset undo
╰─ Full report: /atlas-report ────────────────╯
Anything longer than this — a per-skill table, a team-by-team breakdown — goes to atlas-report and the CLI keeps only the receipt.
What SKILL.md sets; muted values are Claude Code's defaults
15 skills in this plugin
/apex-decisionsAppend-only log of settled project decisions and learnings, shown at session start. Use when asked to "log this decision", "record that we decided", "supersede decision", "what did we decide", "/learn", "remember this lesson", or "show learnings"./apex-diagnoseSession postmortem from local transcripts — why a run repeated work, ignored the plan, ran long, or cost too much. Use when asked "why did that take so long", "why was that so expensive", "what went wrong in that session", or "why did the agent redo that"./apex-guardOpt-in session guard that confirms destructive commands and freezes edits to one directory. Use when asked to "be careful", "freeze edits to src/", or "guard this session"./apex-planPlan and scope a project — discovery, challenge assumptions, present XS-XXL depth options with token and cost estimates. Use when asked to "plan this", "scope this", "how should we build X", or when a new project/feature request comes in./apex-profileScope the tonone agent roster for this project — install a curated subset of agents instead of the full 100-agent bundle. Use when "cut down the agent list", "profile for this project", "too many agents", "only need the engineering core", or after apex-stats shows a roster that's mostly unused./apex-reconEngineering lead reconnaissance — inventory the project before planning. Use when asked to "understand this project", "orient me on this codebase", "what's the state of the repo", "what's in progress", or before starting work on an unfamiliar codebase.Claude Code installs this plugin but refuses to load it
hooks/hooks.json: hooks.json declares PreToolUse/PermissionRequest at its top level, outside the "hooks" object — a PreToolUse/PermissionRequest hook that cannot be loaded may be what guards the permissions declared beside it, so nothing it sits in is applied until the entry is fixed or removed
hooks/hooks.json: hooks.json declares PreToolUse/PermissionRequest at its top level, outside the "hooks" object — a PreToolUse/PermissionRequest hook that cannot be loaded may be what guards the permissions declared beside it, so nothing it sits in is applied until the entry is fixed or removed
Checked against Claude Code 2.1.332. The listing below is what the repository ships; Claude Code doesn't load it as published.
Other plugins' skills for the same job