/sunstack:formal-verifyfrom sunstack
Check one promise of a piece of work against every case in a stated scope, not a sample: code (every order of steps, every input up to a bound), a project design (every state and event), or writing (every requirement, claim and term). The check must catch a deliberate break before it counts. Modes: check (on the fly, leaves nothing), create (leaves a rerunnable check in the project's sunstack/formal-verify/ folder), maintain (brings a check back in line after changes). Works in any session, with or without a Sunstack team. Use for "sunstack formal-verify", "/sunstack:formal-verify", "formal verify", "prove this can't happen", "model-check this", "check every case", "is every requirement covered", "does the design handle every event", or when tests or a read-through cannot reach the case that breaks.
Ships in sunstack. 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.
Skill only: /sunstack:formal-verify in Claude Code, $sunstack:formal-verify in Codex. It has no command of its own.
A test or a read-through checks the cases someone thought of. This skill checks every case inside a scope you state, and says what lies outside it. It works on code, on a project design, and on writing. The loop is the same for each; the domain reference says what each step means there.
references/code.mdreferences/design.mdreferences/writing.mdreferences/tools.mdPick the mode from the request. When the request names none, look in sunstack/formal-verify/ first: a check for this promise that is out of date means maintain, one that is current means rerun it, none means create (or check, when the user wants nothing left behind).
sunstack/formal-verify/<area>/ in the project, so the next agent can rerun it on a change.sunstack/formal-verify/ and the work changed since it last matched. Bring the check back in line (see Maintain).references/tools.md). Check whether it is installed (command -v). If it is not, tell the user which tool, why it fits better than what is installed, and the exact install command, and ask before installing. If the user declines, use the best installed tool and say in the report what the stronger tool would have covered that this one does not. Say why you chose the tool and what the bound is.git rev-parse HEAD), and record the marker that still holds. For a hand-written checker, record the toolchain version.Project data folder. Sunstack skills keep a project's data in sunstack/ at the top of the project (beside the team files, when there is a team), or in the folder that sunstack.json there names ({"data": "<path inside the project>"}). Paths in this skill that start with sunstack/verify/ or sunstack/formal-verify/ mean that folder. It holds only what is committed, never run output. Before a skill creates it for the first time, settle the place with the user in a short Q&A (AskUserQuestion in Claude Code, a numbered question in Codex), showing what will go in it: sunstack/ (recommended: one folder for skill data and any later team), .sunstack/ (hidden), docs/sunstack/, or create nothing (check only, leave nothing behind); the user may name another folder. For any folder other than sunstack/, write sunstack.json with its path and commit both. When the folder already exists, use it without asking.
All checks of a project live in sunstack/formal-verify/, one subfolder per area (the verify skill keeps its run map beside it, in sunstack/verify/). Nothing else in the project changes. Each area folder holds check.md and the files it needs (a model, a script, a kept copy of checked text):
sunstack/
formal-verify/
lock/
check.md
model.go
go.mod
The folder is data, not a skill: this skill reads and runs it, in Claude Code and Codex alike. A model in the project's own language gets its own module or package file (go.mod, pyproject.toml) so the project's build and tests never pick it up; with a Go model, the go tool's ./... also stops at a folder with its own go.mod. Commit the folder with the work, so other sessions and hosts find it.
Write check.md for an agent who reads it cold, mid-change. Start it with # <area>: <property in one sentence>. From it alone, the next agent must be able to tell whether a change touches the covered work, run the check, tell a real finding from a modeling error, and update the model when a change is intended. Put in the property and its harm, the bound and assumptions, the command (run from the area folder, with the tool version, writing every trace, cache or build output outside the committed data: to sunstack/_local/formal-verify/<area>/ in a team (sunstack/PROTOCOL.md here or above; _local/ is ignored only there), else the session's scratch folder; after a rerun, git status on the area folder shows nothing new), each break it catches and how to apply it, and the coverage record. This skill owns its format; sunstack next only reads it to suggest a maintain pass when the covered files change:
## Coverage
sync: <commit>
covers: internal/core/lock.go internal/core/prefs.go
sync: is the marker from step 6. For work outside git or with uncommitted changes, it is sha256: followed by the output of shasum -a 256 <the covered files, in the covers order> | shasum -a 256 run at the top of the project (the first field only), and the kept copy goes in the area folder. A covered folder stands for every file under it, in the order find <folder> -type f | LC_ALL=C sort lists them (write the folder without its trailing / there), so the whole list is { find src -type f | LC_ALL=C sort; echo other.go; } | tr '\n' '\0' | xargs -0 shasum -a 256 | shasum -a 256. covers: lists the covered files and folders, relative to the top of the project, separated by spaces and written with /, a folder with a trailing / (internal/core/). A folder covers every file under it, so a file added there later also counts as a change. Write no leading ./. A path with a space or a backslash cannot be listed: cover its folder instead. A content hash cannot cover a file whose name has a backslash or a line break: use a commit marker for those. Use the project's real paths, commands and names; leave no placeholders.
Before you hand it over, follow it once as the next agent would, on a scratch break of the real work. It must catch the break. Then drop the break and confirm the check is back where it started. A skill that was never run is a draft.
Find the checks under sunstack/formal-verify/ (or the one the user named). If none exists, offer create mode. Run each check once as it is and record the result: a pass now only says the old description still holds. Read every change to the covered work since the sync marker, including moved or renamed parts and new parts that reach the guarded state. When no marker is recorded, use the last commit that changed the check's files, and say so. When the marker is a hash with no kept copy, the changes cannot be read: map the model against the work again from scratch, and say that the change history is unknown. Update the model from the work, not from the result. Change the property only for a promise that changed on purpose, with the evidence (a commit message, a changelog, the user's words). Keep the bound unless the change makes it wrong, and say so when you reduce it. Rerun, and break the updated model once to show it can still fail. Give each check one outcome:
Move the sync marker only after you confirm the model describes the work at the new marker. Keep model updates in a change of their own, apart from any fix to the work.
None of this needs a team. A team means a sunstack/PROTOCOL.md in this folder or above; a sunstack/ folder that holds only skill data is not one. In a team:
sunstack/formal-verify/ is not the verify skill's run map in sunstack/verify/: it models one promise, it does not drive the app.sunstack next flags each check whose covered files changed since its sync marker. An agent that owns a check runs maintain when a delivery touches the covered work.Tell the user, in plain words: the property and its harm, the tool and why, the bound and assumptions, how many items the bound holds and how many of them the check could decide, the break the check caught, the result (each finding as steps or an item in the work's words, with what the work actually does), how to rerun it, and what it does not cover. Suggest a second target only if you found a close one.
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub lucklyric/sunstack --plugin sunstack21 skills in this plugin
/asTake on a Sunstack agent identity (for example builder.alice) in this project, alone or alongside sessions already working as it, or recover the identity this session already holds. Use for "sunstack as", "/sunstack:as", "take on the builder agent", "which Sunstack agent should I be", "sunstack whoami", "which agent am I", or after compaction or /clear lost the session state. Only in projects with a Sunstack team (sunstack/PROTOCOL.md)./boardShow and align the Sunstack team's objectives and key results across the user and every agent, with dependencies, stale or overdue entries and unfollowed directives. Use for "sunstack board", "/sunstack:board", "the team's OKRs", "the team's dependencies", "align the team". Not the ranked to-do list (next skill)./