Skip to content
Skill

Create formal verification skill

Builds a project-local skill that formally verifies the riskiest code paths

Create formal verification skill is an open-source agent skill for developer tools. It is available on Claude Code.

Scripts
None
Platforms
Claude Code
GitHub stars
5.1K
Last commit
License
MIT
Listing updated

Similar skills

About Create formal verification skill

This skill guides an agent to find the part of a repository where a bug would cost the most and ordinary tests reach least, then verify one property of that code. It favors a model checker over a small model of the design when the question is about event ordering, and a verifier that runs on the code itself when the question is about behavior for every input. Where no verifier supports the language, it falls back to generated inputs run against the real code rather than a hand-written model.

The output is a new project-local skill that a later agent can use to check whether a change touches the verified code, run the check, tell a genuine bug from a modeling error, and update the verification when a change is intended. The generated skill records which files and functions each check covers and the commit at which the verification was last confirmed to match the code. The workflow also requires testing the generated skill against a deliberately broken variant of the code to confirm it catches the break, and it treats real counterexamples as findings to report rather than reasons to weaken the property.

When your agent uses it

Generate a project-local skill that formally verifies the code where a bug costs the most and tests reach the least, in any language, with whichever verification tool fits. Use for /create-formal-verification-skill, "model-check this race", "prove this invariant", or when concurrency, retries, state machines, parsers, or unsafe code need more than tests.

From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.

What it can access

From a static check of its 1 file (6 KB) on GitHub on 1 December 2026. Nothing was run. Read the files before you install a skill: it can tell your agent to run anything its tools allow.

Check another skill before you install it.

Install

This skill ships in the pstack plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

/plugin marketplace add michael-denyer/pstack-claude
/plugin install pstack@pstack-claude

Or copy only this skill to ~/.claude/skills/create-formal-verification-skill:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/michael-denyer/pstack-claude.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/create-formal-verification-skill &&
cp -R "$tmp/plugins/pstack/skills/create-formal-verification-skill" ~/.claude/skills/create-formal-verification-skill &&
rm -rf "$tmp"

For one project only, put the folder in .claude/skills/create-formal-verification-skill inside it instead.

Claude Code docs on skills

Copy the skill folder to ~/.agents/skills/create-formal-verification-skill to use it in every repository:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/michael-denyer/pstack-claude.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/create-formal-verification-skill &&
cp -R "$tmp/plugins/pstack/skills/create-formal-verification-skill" ~/.agents/skills/create-formal-verification-skill &&
rm -rf "$tmp"

For one repository only, put the folder in .agents/skills/create-formal-verification-skill inside it instead.

Codex docs on skills

Copy the skill folder to ~/.cursor/skills/create-formal-verification-skill to use it in every project:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/michael-denyer/pstack-claude.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/create-formal-verification-skill &&
cp -R "$tmp/plugins/pstack/skills/create-formal-verification-skill" ~/.cursor/skills/create-formal-verification-skill &&
rm -rf "$tmp"

For one project only, put the folder in .cursor/skills/create-formal-verification-skill inside it instead.

Cursor docs on skills

Run in a terminal (add --scope workspace to install it for the current workspace only):

gemini skills install https://github.com/michael-denyer/pstack-claude.git --path plugins/pstack/skills/create-formal-verification-skill

Or copy the folder to ~/.gemini/skills/create-formal-verification-skill yourself.

Gemini CLI docs on skills

For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/create-formal-verification-skill:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/michael-denyer/pstack-claude.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/create-formal-verification-skill &&
cp -R "$tmp/plugins/pstack/skills/create-formal-verification-skill" ~/.copilot/skills/create-formal-verification-skill &&
rm -rf "$tmp"

For one project only, put the folder in .github/skills/create-formal-verification-skill inside it instead.

VS Code docs on skills

Get the folder:

git clone --depth 1 https://github.com/michael-denyer/pstack-claude.git

Then copy pstack-claude/plugins/pstack/skills/create-formal-verification-skill into your agent's skills folder as create-formal-verification-skill. Agents that support SKILL.md read one folder per skill.

The SKILL.md format

What it does

Target selection from code
Identifies the strongest promise the codebase makes where failures harm users and tests rarely reach.
Tool choice by question
Matches the property to a model checker, a code verifier, or a proof tool, and explains the choice.
Generated verification skill
Writes a project-local skill with frontmatter, coverage records and a sync commit for future agents.
Broken-variant testing
Requires each property to fail on a deliberately broken version of the guarded code before handoff.
Scope and assumption notes
States what the verification covers, under which bounds, and what it leaves out.
Counterexample reporting
Reports real violations in the code's own terms without weakening the property or changing product code.

Good for

  • Model-check a race condition in a concurrent module
  • Prove an invariant holds for a data structure
  • Verify retry logic or a state machine against its intended behavior
  • Check a parser or unsafe code path more rigorously than unit tests allow

Create formal verification skill FAQ

What does Create formal verification skill need to run?

It is a Claude Code plugin skill. Its generated output depends on the target language and the verification tool chosen for the repository, and it asks the user only for facts it cannot observe in the codebase.

When does Create formal verification skill trigger?

It triggers on the command /create-formal-verification-skill, on requests such as model-check this race or prove this invariant, and when concurrency, retries, state machines, parsers or unsafe code need more than tests.

Does Create formal verification skill change product code?

No. The skill states that product code is not changed unless the user asks for it. Counterexamples found in the current code are reported as findings.

Which follow-up skill maintains the output?

After changes that were not rechecked, the skill points users to /maintain-formal-verification-skill to bring the verification back in line with the code.

How do I install Create formal verification skill in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/create-formal-verification-skill to use it in all your projects, or to .claude/skills/create-formal-verification-skill in one project. Or install the pstack plugin, which includes it: /plugin marketplace add michael-denyer/pstack-claude, then /plugin install pstack@pstack-claude.

Does Create formal verification skill run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

Which AI agents can use Create formal verification skill?

Claude Code. It reads skills in the SKILL.md format; the install steps on this page show where to put the folder.

What are the best alternatives to Create formal verification skill?

The closest alternatives to Create formal verification skill are Maintain formal verification skill, Create verification skill, Maintain verification skill, Principle prove it works and Principle build the lever.

Where this comes from

  • Description: from the skill's own SKILL.md.

More from michael-denyer/pstack-claude

  1. Makes the agent read pstack's poteto-mode skill first and follow its routing

    • Open source
    • 5.1K GitHub stars
    • Developer tools
  2. Has the agent restate your goals and the problem you're solving in its own words

    • Open source
    • 5.1K GitHub stars
    • Productivity
  3. Sketches types, signatures and module layout before the agent writes code

    • Open source
    • 5.1K GitHub stars
    • Developer tools
  4. Runs parallel candidate attempts at a task, then merges the best parts into one artifact

    • Open source
    • 5.1K GitHub stars
    • Developer tools
  5. Drafts a personal working-style skill from your past agent conversations

    • Open source
    • 5.1K GitHub stars
    • Developer tools