/formal-verification:specify [create [<promise>]|check [<dir> ...]|refresh [<dir> ...] [--convert <dir>]] [--unattended]from formal-verification
Proposes, creates, checks, and refreshes formal verification skills for code properties. Use when you need model checking, invariant proving, or race condition verification beyond what tests cover.
Ships in formal-verification. 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.
Arguments. [create [<promise>]|check [<dir> ...]|refresh [<dir> ...] [--convert <dir>]] [--unattended].
Each <dir> is a skill folder; --unattended applies to create and refresh. Quote a promise of
more than one word.
e.g. /formal-verification:specify, /formal-verification:specify create "a claimed item has one
holder", /formal-verification:specify check, /formal-verification:specify refresh
A test checks the cases that someone thought to write. Formal verification checks every case in a
stated scope: every order of steps in a model, every input up to a bound, or every input. This skill
finds the part of the repo where that matters most, verifies one property of it, and leaves a
formal-<area> skill that lets the next agent check a change against that property. That skill
follows the formal-area contract
(${CLAUDE_PLUGIN_ROOT}/reference/formal-skill.md); read it before any form below.
The reference files write this plugin's folder as <plugin-root>, which is ${CLAUDE_PLUGIN_ROOT};
when the plugin is not installed and runs from a checkout of its source, it is the folder that holds
its .claude-plugin/plugin.json. "$PWD" in a command is the repository root: pass its absolute
path where the shell's working directory does not carry between calls.
This skill names no verification tool. The question and the repository choose it, by
reference/choose-a-tool.md, and the choice is recorded only in the
area's formal-<area> skill, under ## Tool and why.
| Form | Writes | What it does |
|---|---|---|
| bare | nothing | Proposes the target. |
create "<promise>" | the formal-<area> folder, after the yeses below | Builds and proves one check. |
create with no promise | nothing until a yes | Shows the bare form's proposal and waits for a yes. |
create --unattended | nothing | A dry run: the plan, and the open questions a person must answer. |
check [SKILL_DIR...] | nothing | Runs the contract gate over each formal-<area> skill. |
refresh [SKILL_DIR...] | the formal-<area> folder, in a commit of its own | Brings each check back in line with the code. |
refresh --convert SKILL_DIR | that skill, as a formal-<area> folder | Converts a verification skill outside the contract, attended only. |
A run with no person present (a lane, CI, a model that invoked this skill with nobody to answer) is unattended, whatever its arguments.
Follow reference/create.md "Choose the target from the code" and "Let the
question choose the tool", and stop before anything is written. Give the strongest candidate first,
then up to two more, each as:
formal-<area> folder create would write, under the skills_dir setting.Say once whether the repository's project instructions opt in to formal verification
(reference/create.md "Before anything" step 2). Then name the command that
takes it: /formal-verification:specify create "<promise>".
createFollow reference/create.md from the top. It checks the enforcement
ladder's opt-in first: without it, it goes on only on an attended yes for this run, and an
unattended run reports blocked: formal verification not opted in. It reads every existing
formal-* skill first, asks before it records a tool, makes its seeded break in a throwaway git
worktree, and hands off only after the check caught that break.
checkRun the contract check. It reads each formal-<area> skill and its sync.yaml, and edits nothing:
node "${CLAUDE_PLUGIN_ROOT}/scripts/check.mjs" --project-dir "$PWD" [--default-ref <ref>] [SKILL_DIR...]
With no folder named it checks every formal-* folder under the skills_dir setting. Pass
--default-ref with the default branch's tip, read from its remote, as any ref or SHA git resolves
to a commit (a remote-tracking branch or the fetched SHA), so a sync commit that only the working
branch holds fails now rather than after the merge. It prints one
FAIL or WARN line per finding and a summary, and exits 0 with no failure, 1 with one, 2 when it
cannot run. The findings it reports are listed in the contract's "The contract check". Report the
lines as printed. A stale-coverage warning means the check needs another look, not that it fails:
say which check and which files.
refreshFollow reference/refresh.md from the top. It finds each check, runs it
unchanged, reads every change to its covered code since the sync commit, updates the verification
from the code in a throwaway git worktree, reruns it with a seeded break, and ends each check
in sync, updated, bug or blocked. A property changes only on a person's yes. On a ticket
branch it commits there; otherwise on its own upkeep branch, through one pull request. Unattended,
it writes only for a check that ends in sync or updated with its seeded break caught.
/formal-verification:setup installs only
what this plugin declares, and only on a typed request.formal-<area> folder, the paths its sync.yaml lists under
outside_model, and a skill refresh --convert names. Product code changes only in the throwaway
worktree, which is discarded.formal-<area> skill written and its seeded break caught: /verification:confirm.check reads git history: in a shallow clone the sync commit is not there, and it fails as not
an ancestor of HEAD.## Run that words the command differently from its sync.yaml entry, or puts more on that
line, fails check: give the command exactly, on a line of its own.What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub melodic-software/claude-code-plugins --plugin formal-verification3 skills in this plugin
/chartChart: TLA+ with TLCModel-check a TLA+ spec with TLC and draw it as a Mermaid statechart of how a system moves between states, such as a product flow, a protocol or a service; the report gives the shortest path to each state that breaks a rule, for a person to judge. Use when a formal-area skill's Run names it, or to show a bug as a path through states. TLA+ with TLC only./setupPurposeSet up the formal-verification toolchain: check reports the script runtime, Java, the TLC jar and the renderer; apply install-model-checker or install-renderer downloads the pinned file into the plugin data directory, kept only on a checksum match. Use when: 'set up formal verification', 'install TLC', or /formal-verification:chart reported blocked: toolchain missing. Never installs Java.Other plugins' skills for the same job