{"id":"60130167-e8a5-421d-8957-140cd5cd713e","slug":"fable-bench","kind":"skill","name":"fable-bench","summary":"On-demand /consult skill — a Claude Fable 5 plan-consult plus an automatic warm diff-review on any task. Opus drives; Fable consults.","owner":"casualsav","repoUrl":"https://github.com/casualsav/fable-bench","license":"MIT","licenseTier":"permissive","trust":"community","stars":5,"match":null,"fewStars":false,"format":"skill","createdAt":"2026-07-03T19:24:17.000Z","addedAt":"2026-10-21T23:24:00.307Z","logoUrl":"https://avatars.githubusercontent.com/u/283022617?v=4","linkOnly":false,"collection":null,"skillPath":null,"categories":["productivity"],"tags":[],"runtime":"binary","local":true,"cloudCapable":false,"cloudCapability":"unknown","cloudReadyOnPlatform":false,"needsApiKey":false,"reviewed":false,"syncedAt":"2026-10-26T04:52:12.545Z","sample":false,"url":"https://conduits.dev/tools/fable-bench","language":"TypeScript","transports":["stdio"],"install":{},"requirements":{"env":[],"upstreamMayCharge":false},"tools":null,"readme":"# fable-bench\n\n**Fable is the planner.** `/fable` on any nontrivial task: you (a below-Fable\ndriver — Sonnet or Opus) gather the evidence, Claude Fable 5 writes the plan\n— unanchored by any draft of yours — you execute it, and the *same* Fable\nagent is resumed at the end for a warm diff-review. Nothing fires unless you\ntype it (this is the LITE variant — no auto layer).\n\nAn optional **lead mode** covers sessions where Fable itself is the driving\nmodel: plan engagements are suppressed as redundant — Fable specs, reviews,\nand ships; the worker agents write the code. It's a ~6-line CLAUDE.md block\n(pointing at `skills/fable/LEAD.md`), NOT installed by default, and inert in\nbelow-Fable sessions.\n\nThe philosophy: **the driver holds full session context and does the work;\nFable holds the judgment.** Fable 5 has stronger judgment but zero session\ncontext, so the driver's job is to compress that context into a terse\nevidence brief — constraints, acceptance criteria, file map, load-bearing\ncode — and Fable's job is the plan. Two touches per `/fable` — the plan\nengagement before you build, the warm review of the diff after — plus at most\none exception-triggered mid-consult if a checkpoint or assumption Fable\nflagged fails mid-task.\n\n## What it does\n\nRun `/fable` on a nontrivial task and it drives this flow:\n\n1. **Ground** — map the relevant code with `explorer` workers (scaled to the task), capture the test command and baseline.\n2. **Preflight** — confirm your harness can resume a subagent (the hard dependency below).\n3. **Brief** — compress the evidence into a terse plan brief (≤3.5k tokens): intent, task verbatim, constraints, `DONE-MEANS`, file map, pasted load-bearing code. Zero approach content — no draft, no leading questions.\n4. **Plan** — Fable returns the numbered plan (terse, coded) with risks, checkpoints, assumptions.\n5. **Execute** — you build it, logging deviations; if a Fable checkpoint or assumption fails, one warm mid-consult is allowed.\n6. **Warm review** — the *same* Fable agent is resumed to review the diff (`SHIP / FIX-THEN-SHIP / RECONSULT`).\n7. **Apply MUST-FIX, self-verify, ship** — no third engagement.\n\n(An opt-in **critique mode** — you draft, Fable attacks it with\n`ENDORSE / AMEND / REPLACE` — survives for when the user explicitly asks for a\ncritique of the driver's own plan.)\n\nThree additions from the execution-layer marriage:\n\n- **Orchestrated parallel execution (S5-alt):** for a batch of independent items, the driver\n  fans out to `coder` / `engineer` / `test-writer` workers in parallel,\n  gates every result through `reviewer`, and sends the merged diff to the one warm\n  review. Speed comes from parallelism; quality holds because of the gates. Dependent chains\n  stay inline.\n- **Batch mode:** ≤3 small, vetted, non-interacting items share one plan engagement and one\n  warm review — thinking overhead bills per engagement, so batching amortizes it.\n- **Review-only mode:** pre-approved mechanical items skip the plan engagement; a cold\n  `REVIEW-ONLY` Fable engagement (or, for trivial diffs, the Sonnet `reviewer` at zero\n  Fable) judges the result. Tiered so no diff is double-reviewed by default.\n\n## Install\n\n**Recommended — bare `/fable` (user-level skill):**\n\n```\ngit clone https://github.com/casualsav/fable-bench\n./fable-bench/install.sh\n```\n\nThis copies the skills and agents into your Claude config dir\n(`~/.claude`, or `$CLAUDE_CONFIG_DIR`). Your `CLAUDE.md` is untouched by\ndefault (stale blocks from earlier installs are stripped). The installer asks\nthree questions (env vars skip them for non-interactive installs):\n\n1. **Fable plan effort** (`FABLE_EFFORT`, recommended **high**).\n2. **Fable review effort** (`FABLE_REVIEW_EFFORT`, recommended **medium**) —\n   applied as the per-invocation override on the warm review, mid-consults, and\n   cold REVIEW-ONLY engagements.\n3. **Lead mode** (`FABLE_LEAD`, default **no**) — only worth `yes` if you run\n   sessions with Fable as the driving model; it merges a ~6-line block into\n   `CLAUDE.md` behind sentinels that points Fable-led sessions at\n   `skills/fable/LEAD.md`. Below-Fable sessions ignore it.\n\nWorker efforts are pinned in frontmatter (they cost speed, not Fable):\nverification + explore `low` · coder + smoke-tester `medium` · test-writer `high` ·\nengineer + reviewer `high`.\n\nUser skills aren't namespaced, so the command is exactly `/fable`. Restart / reload your session after\ninstalling.\n\n**Alternative — as a plugin (namespaced `/fable-bench:fable`):**\n\n```\n/plugin marketplace add casualsav/fable-bench\n/plugin install fable-bench\n```\n\nYou get `/plugin`-managed updates, but Claude Code namespaces every plugin\ncommand, so it invokes as `/fable-bench:fable` — not bare `/fable` — and the\nworkers are namespaced too (see the plugin note below). Pick this only if you\nwant the managed-update path over the clean name.\n\n## Uninstall\n\nIf you used the script:\n\n```\n./fable-bench/uninstall.sh\n```\n\nIf you installed the plugin:\n\n```\n/plugin uninstall fable-bench\n/plugin marketplace remove casualsav/fable-bench\n```\n\n`uninstall.sh` also removes the subagent guard's entry from\n`~/.claude/settings.json`, leaving every other hook and setting in place.\n\nEither way, `/fable` writes nothing persistent beyond those files — its only\nruntime state is an in-session task checkpoint that lives and dies with the\nsession — so nothing is left behind.\n\n## Subagent guard\n\nAn `Agent` call whose `subagent_type` pins no model inherits the **parent\nsession's** model. That is how one Fable-led session turned five unnamed\nsubagents into ~1,000 web fetches at Fable rates on 2026-09-20. `install.sh`\nregisters a `PreToolUse` hook on the `Agent` tool in `~/.claude/settings.json`\nto close it — a hook rather than a setting, because the rule is for Fable-led\nsessions only and a settings default would be box-wide.\n\nThe hook decides from the tool input, the installed agent files and the session\ntranscript — no model call, no network:\n\n- **Under a Fable-led parent**, a spawn that would inherit — `general-purpose`,\n  `fork`, `Explore`, `Plan`, an agent file with no `model:`, a call with no\n  `subagent_type` — is **rewritten** to `model: opus` (one step down from Fable\n  rather than two) via `hookSpecificOutput.updatedInput`, and carries a\n  one-line notice that a defined worker is preferred. The call is not blocked.\n- **Under a Sonnet- or Opus-led parent**, nothing happens at all: no rewrite,\n  no notice. Their subagents inherit exactly as they did before.\n- **Always allowed untouched:** a `subagent_type` whose agent file pins a\n  non-Fable `model:` — it cannot inherit — and any call passing an explicit\n  non-Fable `model`.\n- **Always denied:** a spawn whose `model` names Fable or Mythos. No subagent\n  runs on Fable.\n- **`fable-planner` is denied under a Fable-led parent**: its frontmatter pins\n  Fable, a frontmatter pin beats the tool input, and a Fable lead is already\n  the planner. Below-Fable parents spawn it as usual — that is what `/fable` is.\n\nThe parent's model is not handed to the hook (measured 2026-09-20 against\nClaude Code 2.1.278: the hook input carries `agent_id`, `agent_type`, `effort`\nand the tool input but no model, and the hook's environment exposes\n`CLAUDE_EFFORT` and no model variable), so the hook reads the last assistant\nentry in `transcript_path`. Measured limit: assistant entries are flushed a turn\nbehind, so inside a session's **first** assistant turn there is nothing to read\nyet. That reads unknown and **fails closed** — the spawn is pinned to Opus\nrather than left to inherit — except for `fable-planner`, which only a *proven*\nFable parent blocks, so `/fable` typed as a session's first action still works.\n\nBoth mechanisms were proved live on 2.1.278 with throwaway Sonnet sessions: a\nhook's `updatedInput` really does change the model the subagent runs on (a\n`general-purpose` spawn came back as `claude-haiku-4-5-20251001` after a probe\nhook pinned it), and `additionalContext` on an allowed call reaches the model as\na system-reminder without blocking it.\n\n## Requirements\n\n- **Claude Fable 5** access (the planner agent is pinned to `model: claude-fable-5`; `install.sh` prompts\n  for effort, recommended `high` — see below).\n- **`bun`** — for the subagent guard and the `verifier`'s delta runner. Without it `install.sh`\n  installs everything else and says plainly that the guard is not active.\n- **A harness that supports warm subagent-resume** (`SendMessage` to a spawned agent). The\n  warm review resumes the plan agent; there is **no cold fallback**. If resume isn't available,\n  `/fable` detects it at preflight and stops rather than half-running.\n\n## Tuning Fable's effort\n\nFable's reasoning depth is set by the `effort:` frontmatter in the installed\n`fable-planner` agent. `install.sh` **prompts** for it and writes your choice in —\n**recommended: high** — Anthropic's own default for nontrivial work, and `/fable` only fires\non nontrivial work; Fable at medium buys little margin over the Opus driver (Fable-low is\ncomparable to Opus-xhigh). Raise to `xhigh` for a rare, capability-critical plan. One honest caveat: thinking\ntokens bill at Fable's output rate ($50/MTok), so effort — not the visible reply caps — is\nthe biggest cost dial in the system; `medium` is the legitimate lever if usage limits bite:\n\n```\n./fable-bench/install.sh                      # prompts: low | medium | high | xhigh | max\nFABLE_EFFORT=high ./fable-bench/install.sh     # or set it to skip the prompt / for CI\n```\n\nRe-run with a new value to change it. (**Two efforts now govern the two engagements** —\nverified: changing effort mid-conversation does NOT invalidate the message cache. The\nfrontmatter effort applies to the plan engagement; the warm review and any exception mid-consult\nare resumed with a per-invocation override to `medium`, since they're bounded judgment\nagainst an already-vetted plan. This makes `xhigh` plans affordable: the deep\nthinking is spent once, not twice. If you install via `/plugin` instead of `install.sh`, the\nshipped default is `high`; edit the agent's `effort:` frontmatter to change it.)\n\n## What's inside\n\n| File | Role |\n|---|---|\n| `skills/fable/SKILL.md` | The `/fable` flow + all the engagement discipline (brief format, coded-output decoding, bindingness). |\n| `skills/fable/LEAD.md` | The Fable-lead playbook, loaded by the optional lead-mode CLAUDE.md block (Fable-driven sessions only). |\n| `skills/fable-method/SKILL.md` | Fable’s working method distilled for the below-Fable driver — decomposition, self-verification, next-action selection. Load at the start of any nontrivial task. |\n| `agents/fable-planner.md` | The Fable 5 planner — writes the plan from the evidence brief; warm diff-review when resumed; opt-in critique mode. |\n| `agents/explorer.md` | Sonnet discovery worker (grounds the brief; also spawned by the planner for its own search). |\n| `agents/researcher.md` | Sonnet web/docs research worker: searches and fetches, returns a sourced, dated summary; never writes to the repo. |\n| `agents/verifier.md` | Haiku test/lint/build runner (returns distilled pass/fail for self-verify). |\n| `agents/coder.md` | Sonnet worker: small, precisely-specced fixes. Gated by `reviewer`. |\n| `agents/engineer.md` | Opus 5 worker (pinned `claude-opus-5`): behavior-preserving structural refactors, tests-first on uncovered code. |\n| `agents/test-writer.md` | Sonnet worker: characterization/regression tests; orchestrator escalates gnarly cases with a spawn-time model/effort override. |\n| `agents/reviewer.md` | Sonnet read-only gate: reviews worker diffs under a below-Fable driver (a Fable lead reads diffs itself); also the zero-Fable review tier and the degraded fallback when a warm-review handle is lost. |\n| `agents/smoke-tester.md` | Sonnet live prober: drives the real running app end-to-end post-deploy — green unit tests are not the finish line. |\n| `scripts/subagent-guard.ts` | The `PreToolUse` hook on the `Agent` tool: allows only the workers above, denies anything that would inherit the session's model. |\n| `scripts/install-subagent-guard.ts` | Merges (and removes) that hook in `~/.claude/settings.json`, touching no other key. |\n| `subagent-guard.test.ts` | `bun test` over the guard's decision rule and the settings merge. |\n| `install.sh` / `uninstall.sh` | User-level install of the skill + agents into `~/.claude` (`$CLAUDE_CONFIG_DIR`), giving bare `/fable`. |\n| `.claude-plugin/` | Manifests for the alternative `/plugin` install (namespaced `/fable-bench:fable`). |\n\n## Plugin note (only if you chose the plugin path)\n\nThe script install puts the agents at user level, where they resolve by bare name\n(`explorer`, `fable-planner`, `verifier`) — exactly what `SKILL.md` and\n`fable-planner.md` reference — so there's nothing to check.\n\nThe **plugin** path is different: Claude Code namespaces plugin subagents (e.g.\n`fable-bench:explore`). After a plugin install, run one `/fable` on a throwaway\ntask and confirm the discovery and verification workers resolve; if bare names\ndon't, qualify them in `agents/fable-planner.md` (its nested `explorer` spawn) and\nin `SKILL.md`. This mismatch is the main reason the script install is recommended.\n\n## License\n\nMIT\n"}