Stately.ai Skills
Stately Skills are Claude skills for keeping your code, docs, and diagrams in sync as a living source of truth, readable by humans and AI agents alike.
Available skills
- readme - Keep README files in sync with the codebase using symbolic HTML comments.
- stately - Find implicit state machines in application code, model and check their behavior, and inspect or improve them in Stately. Use for /stately, hidden-state discovery, statechart or protocol analysis, safety/liveness/deadlock checks, app documentation, and visual behavior proposals in any framework.
- xstate-v5 - Design, implement, review, and migrate XState v5 statecharts in TypeScript using modern v5 patterns.
- xstate-v6 - Write, review, and migrate XState v6 machines by reading the docs that ship with the installed package.
Install
Claude Code
This repository is a Claude Code plugin marketplace. Install the stately plugin:
/plugin marketplace add statelyai/skills
/plugin install stately@stately
Then run /mcp and sign in to the stately server to save and open models in Stately. Invoke the skill with /stately:stately.
The plugin loads the stately, xstate-v5 and xstate-v6 skills, the hosted Stately MCP server (https://mcp.stately.ai/mcp), and the opt-in stately-channel Apply channel.
Claude Code does not update third-party marketplaces automatically unless you turn on auto-update for the stately marketplace in /plugin. To update by hand:
/plugin marketplace update stately
/plugin update stately@stately
Codex
Add this repository as a Codex plugin marketplace, install the stately plugin, and sign in to the hosted Stately MCP server:
codex plugin marketplace add statelyai/skills
codex plugin add stately@stately
codex mcp login stately
Invoke the skill with $stately. The plugin loads the skills in skills/ and the hosted Stately MCP server. Checking runs locally without signing in; saving and opening models in Stately requires it.
To update:
codex plugin marketplace upgrade stately
codex plugin add stately@stately
Other agents
Install the skills with skills. This installs the skills only. To save and open models in Stately, add the MCP server https://mcp.stately.ai/mcp to your agent and sign in.
npx skills add statelyai/skills
To install one skill, name it:
npx skills add statelyai/skills --skill xstate-v6
Or copy the skill directory manually:
mkdir -p "$HOME/.agents/skills"
cp -R skills/stately "$HOME/.agents/skills/stately"
Copy the whole directory: skills/stately/scripts/ holds the bundled checker.
Contributing
The stately plugin and skill (.claude-plugin/plugin.json, .mcp.json, plugin.json, mcp.json, assets/, and skills/stately/) are synced from statelyai/viz by pnpm skills:sync. Make changes to those paths in statelyai/viz; edits made here are overwritten by the next sync. Issues are welcome here.
The Stately Agent skills in plugins/stately-agent/ moved here from statelyai/agent and are edited here. They are unlisted: the marketplace does not offer the stately-agent plugin, and each skill sets metadata.internal: true. Keep their API names in step with the @statelyai/agent next branch.