/phobos:phobosfrom phobos
Enforces token-efficient coding discipline: triages effort, writes minimal correct code, reduces round-trips, and keeps context lean. Activates on efficiency keywords.
Ships in phobos. 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.
Goal: the fewest tokens that still fully answer. Efficient is not careless — you compress the packaging, never the correctness.
Do this before anything else. It is the difference between a greeting costing 20 tokens and 13,000.
| Turn | Do | Don't |
|---|---|---|
| Trivial — greeting, thanks, yes/no, a fact you know, one-line lookup | Answer in one line. | Read files, recall memory, consult routing, or load any reference. |
| Simple — one edit, single-file question, short command | Apply the output contract + code ladder from memory; ≤1 targeted read. | Open references/. |
| Substantive — multi-file, feature, debugging, design | Load the reference files the task needs (below). | Read files the change doesn't touch "to be safe". |
⚠. If a genuine risk is essential to the answer, fold it into a plain sentence — correctness is never dropped, but it's never dressed up as a warning block either.Climb the ladder, stop at the first rung that holds — but only after you understand the problem:
<input type=date>)? Use it.assert-based demo()/__main__ or one small test.The ledger is written automatically by a Stop hook (hooks/stop.sh) — after a turn that edited files, it appends one edited: a, b line to .claude/phobos-activity.log. Do not run a logging command yourself — a per-turn tool call is exactly the round-trip latency phobos exists to cut. Turns that change nothing log nothing.
hooks/session-start.sh tails the last 8 lines after the activation card, so a new session or post-/clear turn re-orients without re-reading history. Mid-session, tail .claude/phobos-activity.log beats re-deriving "what have we been doing".hooks/log-activity.sh still exists for a manual note when the user explicitly asks you to record something — not for routine per-turn logging..claude/phobos-activity.log to .gitignore — ephemeral breadcrumbs, not project memory (contrast references/memory.md).Benchmark history is separate and automatic: the SessionEnd hook records real per-session output/input/cache tokens + wall time to .claude/phobos-benchmark.jsonl. When the user asks "how much have I used / saved / is this getting cheaper", run one of these directly — don't estimate from memory and don't go hunting for the script:
bash ~/.claude/skills/phobos/hooks/benchmark.shbash ~/.claude/skills/phobos/hooks/savings.shBoth need bash + jq. On Windows that means running inside Git Bash (see the repo's install requirements); if the command isn't found, that's the fix — don't retry blindly.
Some phobos rules are enforced by hooks, not left to discipline. When you hit one, cooperate with it:
hooks/guard-reads.sh, PreToolUse): the path was node_modules/lockfile/minified/build-output/git-internals, or an unbounded huge read (by size or line count). Don't retry the identical call and don't route around it with cat. Follow the deny reason — Grep the symbol, Read with offset/limit, or use the suggested CLI. If the read is genuinely required, tell the user to add a regex line to .claude/phobos-guard-allow (or set PHOBOS_GUARD=off).hooks/guard-cmd.sh, PreToolUse): the call would flood the window or waste a turn — an unbounded content Grep (add head_limit), a recursive ls/grep or unbounded git log (bound it or pipe to head), or a command you've already run that failed the same way with nothing edited since. Take the steer in the deny reason; for a repeat-failure, read the actual error and fix the root cause instead of re-running. Disable with PHOBOS_CMD_GUARD=off (or PHOBOS_GUARD=off for all guards).hooks/context-warn.sh, UserPromptSubmit): the window is nearly full and every turn re-sends it. Finish the current step, then suggest /compact (or /clear on a topic change) in one line. See references/context-hygiene.md..claude/phobos-state.md at session start (hooks/state.sh, via Stop/PreCompact): a small current-state handoff — git SHA + dirty count, working set, recent activity — that survives /compact and /clear so you re-orient from it instead of re-reading the transcript. It is stamped with the git state it was generated from; treat everything in it as true as of that SHA and re-verify a named file/line against the live tree before acting.hooks/pre-compact.sh): entries above it predate the summary — re-verify any file/flag named above that line before acting on it.bash ~/.claude/skills/phobos/hooks/doctor.sh — it self-tests the install and prints the fix./compact: references/context-hygiene.mdSibling skills (load when installed):
phobos:max: maximum prose compression — drop articles, pleasantries, hedges; keep full technical accuracy.bash ~/.claude/skills/phobos/hooks/update.sh (fast-forward pull, then restart the session).ACTIVATION.md (opens in a new tab)hooks/benchmark.sh (opens in a new tab)hooks/context-warn.sh (opens in a new tab)hooks/doctor.sh (opens in a new tab)hooks/guard-cmd.sh (opens in a new tab)hooks/guard-reads.sh (opens in a new tab)hooks/log-activity.sh (opens in a new tab)hooks/pre-compact.sh (opens in a new tab)hooks/savings.sh (opens in a new tab)hooks/session-end.sh (opens in a new tab)hooks/session-start.sh (opens in a new tab)hooks/spinner.sh (opens in a new tab)hooks/state.sh (opens in a new tab)hooks/statusline.sh (opens in a new tab)hooks/stop.sh (opens in a new tab)hooks/update.sh (opens in a new tab)references/context-hygiene.md (opens in a new tab)references/memory.md (opens in a new tab)references/routing.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub broisnees/phobos --plugin phobos3 skills in this plugin
/phobos-codeCoding discipline — minimal correct code with zero slop and zero wasted round-trips. Understand fully first, climb the reuse ladder, fix root causes not symptoms, verify before claiming done. Use on any coding task (write, edit, refactor, fix, review) or when the user says "phobos-code", "no slop", "minimal", or "clean"./phobos-planAnalyze the user's request before acting — extract every ask, resolve ambiguity in one batch, order work by dependency and risk, and decide what to do first. Use when a request is multi-part, vague, or large; when asks conflict; or when the user says "phobos-plan", "plan this", "prioritize", or "what first".Other plugins' skills for the same job