Agent skill

Fable Discipline

by assafkip in assafkip/kipi-system

Teaches staged, verifiable coding habits for multi-file tasks and ships a hook that blocks tests from touching live data.

MITAuto-check passedAgent Workflows

Install Fable Discipline

skills CLI
$ npx skills add assafkip/kipi-system --skill fable-discipline -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install assafkip/kipi-system fable-discipline --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/assafkip/kipi-system.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/prd-os/skills/fable-discipline .claude/skills/fable-discipline && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
fable-discipline
GitHub stars
112
Token cost
~2.9k tokens
SKILL.md length
1,678 words
Files
5 (incl. scripts, references)
Skills in repo
14
Repo updated
First seen
Licence
MIT

At a glance

Teaches staged, verifiable coding habits for multi-file tasks and ships a hook that blocks tests from touching live data.

  • Works in 5 steps: Stage before you act. Write the stage… → Verify each stage with a check that can… → Say, then batch. State the one-line… → …
  • Building a feature or fixing a bug that spans several files or sessions
  • SKILL.md covers Position: the…, When NOT to use this, Layer 1: running the task and Layer 2: writing the code, plus 4 more sections
  • Runs Python scripts from its folder; calls python3

What it does

The skill has two layers. The first covers how to run a task: write a stage plan that numbers the stages and names one checkable artifact for each, verify every stage with a check that can fail, such as a test, a file in the right shape or an output diffed against the spec, and state a one-line intent before the batch of actions that carries it out. A stage with no failable check is marked unverified so the gap stays visible. The second layer covers how to write code: recon before editing, verifying against a copy with a negative self-test, single-writer chokepoints and why-comments anchored to past failures.

One habit is enforced by code rather than judgment. A paired hook deterministically blocks a test from touching live data, on the reasoning that a rule a model can talk itself out of is only a suggestion. The folder also holds EXAMPLE.md, a checklist reference and a Python lint script with its own tests.

It is meant for work bigger than a one-line change and adds to what the model already does well. One-line fixes, typo fixes and tasks with one obvious approach should skip it, since staging them buries the answer. Inside the prd-os plugin it loads through /issue-start before the first edit of an issue and through the quick-plan path for other coding tasks.

When your agent uses it

  • Building a feature or fixing a bug that spans several files or sessions
  • Hardening a data path so tests cannot touch live data
  • Breaking complex work into stages that each produce something checkable

Example prompts

  • “Fix the duplicate-invoice bug across the billing and export modules, with a check per stage.”
  • “Add tests for the import job and make sure none of them can touch live data.”
  • “Plan this migration in stages and name what each stage will prove.”

Requirements

  • Python 3 for the lint script

Workflow steps

5 steps, taken from the first numbered list in SKILL.md.

  1. Stage before you act. Write the stage plan first. Number the stages, name
  2. Verify each stage with a check that can fail. A test that runs, a file that
  3. Say, then batch. State the one-line intent, then fire the burst of actions
  4. Done is written, not felt. Define done-criteria up front. On a task that
  5. Ground before you diagnose. Confirm a perceived error actually reproduces

What it can do on your machine

Read from SKILL.md and the folder at commit 16d4724. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 2 files in scripts/ (Python), which the agent can run.

    Shell commands in SKILL.md call:

    • python3

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Fable Discipline loads about 2.9k tokens when it runs, and up to ~4.3k if it reads all its reference files. Until then it costs about 155 tokens; SKILL.md has 1,678 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~155
When it runs · the whole SKILL.md, loaded when a task matches
~2.9k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~4.3k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from assafkip/kipi-system at commit 16d4724, republished under its MIT licence (© assafkip). 1,678 words, ~2,890 tokens.

Download SKILL.mdSave it as .claude/skills/fable-discipline/SKILL.md (or your agent's skills folder). This skill also uses 4 other files; get the full folder from GitHub.
name
fable-discipline
description
Engineering discipline distilled from a forensic read of one model's work. Use when building a feature, fixing a bug, writing tests, hardening a data path, or running any task that spans multiple files, sources, or sessions. Two layers: how to RUN the task (stage it, verify each stage with a check that can fail, write done-criteria) and how to WRITE the code (recon before edit, verify against a copy with a negative self-test, single-writer chokepoints, scar-anchored why-comments). Ships a paired hook that deterministically blocks a test from touching live data, the one habit a machine can enforce.

Fable-Discipline

Coding and task discipline, distilled from reading thousands of edits by one capable model and grading them against an independent review. It is additive: it does not replace what your model already does well, it adds the habits that strong engineers have and most code generation skips.

Most of it is judgment the skill teaches. One slice is enforced by a hook, because a rule a model can talk itself out of is a suggestion, not a gate. The skill teaches; the hook makes the one checkable habit non-optional.

<!-- kipi-only:start -->

Position: the execution-discipline layer of prd-os

This skill is not a sibling system to prd-os; it is prd-os's execution-discipline layer (merged 2026-07-04, see the plugin CHANGELOG). Two load paths, one skill:

  • PRD work: /issue-start loads this skill before the first edit of every DSSE issue. The issue's receipts (verified, reviewed, findings_triaged) are the task-level half of the same contract this skill states per-edit.
  • Non-PRD work: the quick-plan fast path and the fable-discipline auto-invoke rule load it for any coding task bigger than a one-line change.

The public standalone export (github.com/assafkip/fable-discipline) mirrors this copy; scripts/export-fable-mirror.sh --check is the drift blocker.

<!-- kipi-only:end -->

When NOT to use this

One-line changes, typo fixes, a task with one obvious approach that fits in a single pass. Staging a trivial task buries the answer under ceremony. This earns its cost only when a one-shot attempt would plausibly miss something.


Layer 1: running the task

How to move through complex work without shipping a confident wrong answer.

  1. Stage before you act. Write the stage plan first. Number the stages, name the one checkable artifact each produces. If a stage produces nothing checkable, merge it into the next. The map is living, not a contract; update it when what you learn invalidates it.

  2. Verify each stage with a check that can fail. A test that runs, a file that provably exists in the right shape, a source actually read, an output diffed against the spec. "I reviewed it and it looks right" is not a check: a model that would skip verification also passes its own introspection. If a stage has no failable check, say so and mark its output unverified so the gap is visible.

  3. Say, then batch. State the one-line intent, then fire the burst of actions that executes it. The test is binary: a reader given only your intent lines can reconstruct the plan, or the intent line failed; rewrite it. It keeps you from drifting mid-burst.

  4. Done is written, not felt. Define done-criteria up front. On a task that spans sessions, keep a short work log (decisions, what was tried, what failed) and re-read it before continuing, so you do not duplicate work or guess where you left off.

  5. Ground before you diagnose. Confirm a perceived error actually reproduces before you act on it. Read where the data comes from before you trust what it represents. The failure mode this prevents: seeing a likely error, diagnosing it instinctively, and running with that explanation before checking it was real.


Layer 2: writing the code

  1. Recon before edit. Read reality, do not assume it. Grep the real schema and call-sites before changing anything. Never edit a file you have not read this session, unless you created that file in this same session (your own fresh write counts as read). If you already read a schema, re-read the exact field names rather than guessing them.

  2. Verify against a copy, with a negative self-test. A passing gate is not trusted until it has been seen to fail. Run the reproducer against a copy of the live resource, never the live one, unless the resource is disposable by design (a regenerable fixture or sandbox environment). Then corrupt a valid input and prove the check FAILS on the violation, so a green result is not a rubber stamp.

    A mutation result is THREE claims, and usually only one gets checked. "The mutant was KILLED" is meaningless until "the mutant was APPLIED" and "the check was GREEN first" are both proven. An unapplied mutant and a well-defended one are identical bytes on the terminal, and so are a killed mutant and a command that was already red. Every mutation run therefore:

    • matches its anchor exactly once before writing, and proves the bytes on disk moved (digest, not length: a length-preserving mutant is legitimate);
    • exits non-zero as a FAILED EXPERIMENT on an anchor miss or an ambiguous anchor, and never falls through to the run. Override: re-derive the anchor from the file as it is now and re-run once it matches exactly one site. Loosening the anchor to make it match is not the hatch, it is the scar;
    • pins PYTHONDONTWRITEBYTECODE=1 AND a bytecode-cache path outside the source tree. The first stops the run LEAVING a cache; only the second stops it READING a stale one, and the stale read is what measures the unmutated module;
    • starts from a green baseline, measured per experiment against the unmutated file rather than trusted once at the top of a table. A mutation run against an already-red check kills every mutant trivially and prints a perfect score;
    • holds the subject one run at a time. Two concurrent runs each read the other's mutant as "the original" and each restore it, so the mutant stays on disk while both report a clean tree.

    Scar 2026-09-20 (rca-injection-boundary, PR #386): five bad instruments across six review rounds by two independent sessions, every one failing in the reassuring direction. A stale __pycache__ made mutants read KILLED; an anchor that no longer matched printed a clean 248 green, which is exactly what a defended site looks like. Both produced a wrong DIAGNOSIS, not a wrong number.

<!-- kipi-only:start -->

In this fleet that protocol is a script, not a habit: python3 plugins/prd-os/scripts/mutate.py --file F --anchor A --replacement R -- <check> (exit 0 KILLED, 1 SURVIVED, 2 FAILED EXPERIMENT; always restores and verifies the restore). Its own decision points are mutation-proven by plugins/prd-os/tests/mutants_of_mutate.py.

<!-- kipi-only:end -->
  1. Single-writer chokepoint, guarded by a CENSUS TAKEN BY CODE. Route every mutation of a shared resource through one helper, and make a gate enumerate the consumers from the source, never from your recollection of them. Migrate existing call-sites one small, independently revertible edit at a time, not one bulk rewrite. For a module that declares an exclusion predicate, that gate is q-system/.q-system/scripts/consumer-parity-check.py, a PostToolUse hook that walks the AST and reports every walker that skips the predicate. Retired 2026-08-03 (ASK-315): this line used to say "write a test that greps the tree", which is prose naming no executable. Under it, a commit whose message read "one predicate for all three consumers" shipped with a fourth, and six instances of that shape landed in one file in one night. A habit is not a census.

  2. Why-comments anchored to a named scar. Comments encode the constraint and the specific past bug that motivates it, not a restatement of the code. These survive refactors because they encode an invariant.

  3. Capture every out-of-scope finding; never just mention it. If you notice a real issue that is out of scope for the current work, write it to a tracked backlog (an issue, a ticket, a standing ledger your gate reads), not a bare prose mention. A mention is a silent drop; a tracked item is one a gate can keep failing until it is resolved. The paired lint blocks deferral language written into code without such a capture. Override: capture first, then ack the captured line with # spillover-skip; there is no skip-first path.

  4. Build against the recurring gap classes. If the change scales or touches sensitive data, walk the gap-class block in references/checklist.md: an in-memory cap is not a disk bound; a UI hide is not access control; a gate fails closed while a filter fails open; redact at the egress edge; a new flag must reach every reader; check-then-mutate needs one lock; single-source the version; a cross-cutting invariant needs a written scope + a self-enumerating guard. Check only the classes the change touches.

  5. Least-code bias. Prefer the smallest change that solves it. Reach for delete-and-reuse before you write new code; the best fix is often a line removed, not a line added. When you catch yourself writing the third near-identical thing, stop and generalize the mechanism instead of adding a third copy.

Show full SKILL.md (292 more words)Show less

Consistency rules

Habits that are easy to do somewhere and forget elsewhere. Make them non-optional:

  • Test isolation. A test uses a temp copy, a tempfile, or :memory:, never a real data path. (This is the slice the paired hook enforces.) Override: an audit test that must NAME a live path may assert on it (assertion lines are exempt); anything else carries # fable-discipline-lint-skip in that file with a one-line reason.
  • Declare and pin every new dependency the moment you import it, and keep a test that proves the manifest covers every third-party import.
  • Specify degenerate cases before implementing: empty, single-element, disconnected, non-converging. Each gets defined behavior, not an implicit crash.
  • Validate persisted external input. Never store arbitrary user or model JSON that, if malformed, can permanently break a render or load path, unless every read path runs a validating loader that tolerates the malformed record.
  • Enumerate all call-sites when scoping a change. Grep for every site the change must reach before declaring it done.

Anti-patterns to drop

  • Guessing a schema or API you already read. Re-read it.
  • Acting on an unconfirmed diagnosis. Confirm the error is real first.
  • Re-attempting the same failing command. Change the approach, do not retry it.
  • Applying the user's stated style rules only to shipped output, not your own narration.

Communication while building

Terse mid-task, then decompress at the seam into a short "ran, not assumed" block listing what you ran and what passed. When a real choice exists, name the options, mark your pick, give the tradeoff, end with one action.

Enforcement

The deterministic slice (test isolation) is enforced by scripts/fable-discipline-lint.py, wired in hooks/hooks.json as a PostToolUse hook. Everything else is judgment and lives here. See EXAMPLE.md for a worked before/after, and references/checklist.md for the copy-paste pre-done gate.

© assafkip, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 4 other files (scripts, references) in plugins/prd-os/skills/fable-discipline of assafkip/kipi-system.

  • SKILL.md
  • EXAMPLE.md
  • references/checklist.md
  • scripts/fable-discipline-lint.py
  • scripts/test_fable_discipline_lint.py

Open the folder on GitHubat commit 16d4724

Compare with similar skills

Fable Discipline next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Fable Discipline compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Fable Discipline this skillassafkip/kipi-system112—~2.9kAutomated safety check: PassMIT
AI SAFE2 Development MethodCyberStrategyInstitute/ai-safe2-framework146—~833Automated safety check: PassCustom licence
Auditable Playbook Designercursor/plugins10k8 repos~1kAutomated safety check: PassNone
Iterative Development Orchestratorprime-radiant-inc/iterative-development181—~2.7kAutomated safety check: PassApache-2.0
Execute Implementation Planimbue-ai/bouncer400—~425Automated safety check: WarnAGPL-3.0
Spec-Driven DevelopmentLichAmnesia/lich-skills234—~3.5kAutomated safety check: PassMIT

Similar skills

  • AI SAFE2 Development Method

    CyberStrategyInstitute/ai-safe2-framework

    Plans and runs material repository changes with the AI SAFE2 method: classify delivery shape and risk, isolate the work, collect test evidence and finish with a completion receipt.

    146 GitHub stars~833 tokensUpdated today
    DevelopmentAuto-check passed
  • Official

    Designs a step-by-step playbook for large or unfamiliar work, runs it as a loop of hypotheses and measurements, and logs decisions so a human can review them later.

    10k GitHub starsUsed in 8 repos~1k tokens
    Agent WorkflowsAuto-check passed
  • Iterative Development Orchestrator

    prime-radiant-inc/iterative-development

    Runs an autonomous loop that extracts requirements with proof obligations, builds a walking skeleton, then audits sprint by sprint against real behavior evidence.

    181 GitHub stars~2.7k tokensUpdated 4 mo ago
    Agent WorkflowsAuto-check passed
  • Works through the task files of a feature's implementation plan one at a time, with a TODO list and a verification step and commit for each task.

    400 GitHub stars~425 tokensUpdated yesterday
    Agent WorkflowsAuto-check: warnings
  • Spec-Driven Development

    LichAmnesia/lich-skills

    Runs a gated Spec, Plan, Build, Test, Review, Ship workflow so non-trivial changes are specified, verified and reviewed before they ship, with a named artifact per phase.

    234 GitHub stars~3.5k tokensUpdated 4 mo ago
    Agent WorkflowsAuto-check passed
  • Launch Delivery Pipeline

    Yeachan-Heo/oh-my-claudecode

    Delivery pipeline from mission brief to verified change: writes a spec, splits it into tickets, runs them in parallel, verifies and reports a decision log after a repo audit gate.

    40k GitHub stars~7.3k tokensUpdated yesterday
    Agent WorkflowsAuto-check passed

More from assafkip/kipi-system

All 14 skills in this repo
  • Deck AI

    assafkip/kipi-system

    Turns a markdown file into a themed, image-rich slide deck exported as PDF, using Slidev for layouts and Unsplash for photos, all run locally.

    112 GitHub stars~1.5k tokensUpdated yesterday
    Auto-check: notes
  • Unified Design Router

    assafkip/kipi-system

    Routes visual design requests to built-in logo, corporate identity, slide, banner, social photo and icon workflows, backed by style data and AI image generation.

    112 GitHub stars~2.9k tokensUpdated yesterday
    Auto-check passed
  • Improve Idea Critique

    assafkip/kipi-system

    Judges a pasted tip, post or video summary against what the kipi system already has, and returns adopt, skip or already-built with the files that back the verdict.

    112 GitHub stars~729 tokensUpdated yesterday
    Auto-check passed
  • Root-Cause Analysis Writer

    assafkip/kipi-system

    Writes a structured, blameless root-cause analysis for a defect that escaped a test or gate, separating surface from structural causes and linting the result.

    112 GitHub stars~796 tokensUpdated yesterday
    Auto-check passed
  • Architecture Review

    assafkip/kipi-system

    Surfaces architectural friction in real code — shallow modules, tight coupling, untested seams — and proposes deepening refactors using Ousterhout's deep-module principle (small interface hiding a…

    112 GitHub stars~817 tokensUpdated yesterday
    Auto-check passed
  • Audhd Executive Function

    assafkip/kipi-system

    AUDHD executive function accommodations. An agent skill from assafkip/kipi-system.

    112 GitHub stars~3.3k tokensUpdated yesterday
    Auto-check passed

Questions about Fable Discipline

What does Fable Discipline do?

Teaches staged, verifiable coding habits for multi-file tasks and ships a hook that blocks tests from touching live data. The skill has two layers. The first covers how to run a task: write a stage plan that numbers the stages and names one checkable artifact for each, verify every stage with a check that can fail, such as a test, a file in the right shape or an output diffed against the spec, and state a one-line intent before the batch of actions that carries it out.

When should I use Fable Discipline?

Fable Discipline fits situations like: building a feature or fixing a bug that spans several files or sessions; hardening a data path so tests cannot touch live data; breaking complex work into stages that each produce something checkable.

How do I install Fable Discipline in Claude Code?

Run `npx skills add assafkip/kipi-system --skill fable-discipline -a claude-code`. Or copy the skill folder (plugins/prd-os/skills/fable-discipline in assafkip/kipi-system) into .claude/skills/fable-discipline in your project. Claude Code loads it when a task matches its description.

How do I install Fable Discipline in Codex?

Run `npx skills add assafkip/kipi-system --skill fable-discipline -a codex`. Or copy the skill folder (plugins/prd-os/skills/fable-discipline in assafkip/kipi-system) into .agents/skills/fable-discipline in your project. Codex loads it when a task matches its description.

Can I use Fable Discipline in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add assafkip/kipi-system --skill fable-discipline -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/fable-discipline, .gemini/skills/fable-discipline, .github/skills/fable-discipline and .opencode/skills/fable-discipline in your project.

What does Fable Discipline need to run?

Going by SKILL.md and its folder, Fable Discipline needs Python for the scripts in its folder and the command-line tools its instructions call (python3). Our summary lists: Python 3 for the lint script.

Does Fable Discipline access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Fable Discipline safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Fable Discipline use?

Fable Discipline is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Fable Discipline use?

About 2.9k tokens (SKILL.md is roughly 12k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 1.4k tokens, read only when the agent opens those files.

What are the alternatives to Fable Discipline?

Skills that share tags, products or a category with Fable Discipline: AI SAFE2 Development Method (CyberStrategyInstitute/ai-safe2-framework, 146 stars), Auditable Playbook Designer (cursor/plugins, 10k stars), Iterative Development Orchestrator (prime-radiant-inc/iterative-development, 181 stars) and Execute Implementation Plan (imbue-ai/bouncer, 400 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Fable Discipline?

assafkip (a GitHub user) maintains it in assafkip/kipi-system, which has 112 GitHub stars. The repository holds 14 skills in this directory. The repository was last updated on October 7, 2026.

Source: assafkip/kipi-system on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.