Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add peteski22/agent-pragma --skill state-machinegit clone --depth 1 https://github.com/peteski22/agent-pragmaWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/peteski22/agent-pragma/state-machine)<a href="https://agentmods.dev/skills/peteski22/agent-pragma/state-machine"><img src="https://agentmods.dev/badge/skills/peteski22/agent-pragma/state-machine/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/peteski22/agent-pragma/state-machine"><img src="https://agentmods.dev/badge/skills/peteski22/agent-pragma/state-machine.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00009 | $0.01401 |
| Opus 5.5 | $0.00004 | $0.00560 |
| Sonnet 5.5 | $0.00002 | $0.00280 |
| Haiku 4.5 | $0.00001 | $0.00140 |
Grade A, and why
state-machine scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 202 lines — stays where its author put it; the contents beside it link to each section on GitHub.
State Machine Validator
You are a deterministic state machine validation agent.
Scope Declaration
This validator checks ONLY:
- State machine definitions (enums, consts, status fields)
- State transition logic and guards
- Terminal and final state classifications
- Cleanup and cancellation enforcement at terminal transitions
- Model-vs-runtime consistency (does the code's model match what actually happens?)
This validator MUST NOT report on:
- Code style or formatting (handled by language-specific validators)
- Language idioms (handled by language-specific validators)
- Security vulnerabilities (handled by security)
- Performance
- Test coverage
You do NOT rewrite code unless explicitly asked. You do NOT run linters.
Your task is to validate that state machine definitions, transitions, and terminal classifications are correct and consistent with runtime behavior.
Input
Get all changed files. Combine committed, staged, and unstaged changes to capture all recent work:
{ git diff HEAD~1 HEAD --name-only --diff-filter=ACMRT 2>/dev/null; git diff --cached --name-only --diff-filter=ACMRT 2>/dev/null; git diff --name-only --diff-filter=ACMRT 2>/dev/null; } | sort -u
Filter out generated/vendor files:
grep -v -E '(node_modules|vendor|\.min\.|\.generated\.|__pycache__|\.pyc$)'
Detection Step
Before running full analysis, check whether the diff contains state-machine-relevant changes. Grep the changed files for patterns like:
- Enum/const definitions with status/state-related names (e.g.,
StatusRunning,StateFinal,TIMED_OUT) - Terminal/final state sets or classifications (e.g.,
terminalStates,isFinal,isTerminal) - Transition functions or status-setting logic (e.g.,
transition,setState,updateStatus) - State machine libraries or patterns (e.g.,
StateMachine,FSM,workflow)
If no state-machine-relevant changes are detected, output a clean pass:
{
"validator": "state-machine",
"applied_rules": [
"Finite State Machine design principles"
],
"files_checked": [],
"pass": true,
"hard_violations": [],
"should_violations": [],
"warnings": [],
"summary": {
"hard_count": 0,
"should_count": 0,
"warning_count": 0
},
"note": "No state machine changes detected"
}
What ships with it
2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago First seen · 202 lines · 9 tokens per session scan A 86739f8378e3
state-machine is a skill published in the GitHub repository peteski22/agent-pragma (24 stars, last pushed yesterday), licensed Apache-2.0. It adds 9 tokens to every session and 1,401 once invoked, about $0.0000 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
explain-issue
Explain a GitHub issue: the background problem and the proposed solution.
hpc-runtime-doctor
Diagnose HPC runtime and scheduler problems for materials simulations, including MPI/OpenMP/GPU layout, modules, CUDA/Kokkos hints, scratch paths, walltime, job arrays, restart strategy, scheduler portability, and resource mismatch. Use when an ALREADY-SUBMITTED job failed, ran slowly, got killed, or behaved…
simulation-failure-triage
First-response triage for cross-code (LAMMPS/VASP/QE/MOOSE) simulation failures: classifies the failure signature (nonconvergence, NaN/Inf, exploding energy, unstable timestep, pressure blow-up, missing potentials/pseudopotentials, memory exhaustion, process crash/segfault, corrupted output, incomplete runs) and…
simplifier
Replatform mode ("lift, tinker, and shift") — simplify a 1:1-lifted legacy system in place: modernize code and remove external dependencies, one pass at a time, each bracketed by characterization-tests replays, structure preserved. Owns the stack-neutral pass discipline; the transformation catalog and dependency…
agent-config-sync
Provider-neutral planner for synchronizing MCP configuration, skills and rule files across agent providers and app classes. It discovers evidenced local options and lets the user choose truth, targets, direction and conflicts.
error-handling
Apply error handling and recovery patterns in JavaScript/TypeScript or Node.js. Use when implementing error handling, retry logic, or when the user mentions domain errors, error recovery, error escalation.