workflow

workflow is a command for Claude Code from yorrick/agent-skills. It costs 18 tokens per session (6,819 once invoked), scanned A, original, MIT.

A command that turns a plain-language task into a workflow script and runs it with the StateGraph engine, a system for connecting steps and decisions. It also includes the project’s documented quality checks in the workflow.

In plain words
What is it for?
Use it to plan and run ad-hoc workflows, connect dependent steps, run independent checks in parallel, and validate the result.
Why use it?
It organizes multi-step coding work and makes required checks part of the process instead of relying on memory.

Command for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: mentions CLAUDE.md; mentions AGENTS.md; mentions Codex.

Runs only inside its plugin — its command needs a path that Claude Code sets for a plugin’s own hooks and for nothing else. Install the plugin, not this.

Part of the dev-loop plugin — 3 commands shipped together

Good fit Use it to plan and run ad-hoc workflows, connect dependent steps, run independent checks in parallel, and validate the result.

Compare 6 commands from other repositories ↓
Install

Getting it into your agent

This one installs as part of its plugin. Adding the marketplace and installing the plugin brings it with everything else the plugin ships.

Claude Code
/plugin marketplace add yorrick/agent-skills
Claude Code
/plugin install dev-loop

Made for: Claude Code.

Or install dev-loop, the plugin that ships this one along with the rest of its 3 commands.

Wrote 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.

agentmods badge for workflow

README.md
[![agentmods](https://agentmods.dev/badge/commands/yorrick/agent-skills/workflow/github.svg)](https://agentmods.dev/commands/yorrick/agent-skills/workflow)
Your own site
<a href="https://agentmods.dev/commands/yorrick/agent-skills/workflow"><img src="https://agentmods.dev/badge/commands/yorrick/agent-skills/workflow/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.

agentmods 80×15 button for workflow

Your own site · 80×15
<a href="https://agentmods.dev/commands/yorrick/agent-skills/workflow"><img src="https://agentmods.dev/badge/commands/yorrick/agent-skills/workflow.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 18 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 6,819 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00018 $0.06819
Opus 5.5 $0.00007 $0.02728
Sonnet 5.5 $0.00004 $0.01364
Haiku 4.5 $0.00002 $0.00682

Measured 1mo ago against content hash 033be14ad543, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

workflow scanned grade A with 1 finding 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.

Runs shell commandslowCapability

Expected in a hook, worth knowing in a rule or an instructions file.

result = subprocess.run(
dev-loop/commands/workflow.md · 593 lines

How it starts

The opening of the file, as written. The whole thing — 593 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Workflow Generator

You generate and execute ad-hoc workflow scripts using the StateGraph engine.

The user's request is: $ARGUMENTS

Engine location

The workflow engine is at: ${CLAUDE_PLUGIN_ROOT}/scripts/engine.py

What to do

  1. Read CLAUDE.md and list quality gates. Before anything else, read CLAUDE.md (or AGENTS.md, GEMINI.md) in the repo root. If it exists, extract every quality gate command it mentions (e.g., uv run ruff check ., uv run pyright, npx playwright test, npm run build). Write them down — you will need to add a workflow node for each one.
  2. Understand the request. Read relevant source files to understand the codebase context.
  3. Design the workflow. Decide which nodes, edges, and routers are needed. Pick the right node type for each step. For every quality gate from step 1, add a dedicated shell_node (or include the command in an LLM node prompt). If CLAUDE.md says "run ruff check", there must be a node that runs ruff. If it says "run pyright", there must be a node for pyright. No exceptions. Look for parallelization opportunities — independent quality gates can run in parallel via add_parallel_edges.
  4. Write the script. Create a Python script at /tmp/workflow_NNNN.py (use a random 4-digit suffix). Always include --diagram flag handling (see template).
  5. Show the diagram first. Run with uv run /tmp/workflow_NNNN.py --diagram and show the user the rendered ASCII diagram so they can see the workflow graph before execution. The script template already uses graph.to_ascii() for this — do NOT change it to to_mermaid(). The ASCII version renders a visual box-and-arrow diagram directly in the terminal.
  6. Run it. Execute with uv run /tmp/workflow_NNNN.py.
  7. Report the result. Show the user what happened.

Script template

Every generated script follows this structure:

#!/usr/bin/env -S uv run --script
# /// script
# requires-python = ">=3.12"
# dependencies = ["mermaid-ascii"]
# ///
import os
import sys
sys.path.insert(0, "${CLAUDE_PLUGIN_ROOT}/scripts")

import asyncio
from engine import (
    StateGraph, claude_node, codex_node, gemini_node,
    shell_node, python_node, template_node,
    detect_available_models, END,
)


def build_graph(models: dict[str, bool] | None = None) -> StateGraph:
    """Build the workflow graph. Accepts optional models dict for testing."""
    if models is None:
        models = detect_available_models()
    HAS_CODEX = models["codex"]
    HAS_GEMINI = models["gemini"]

    graph = StateGraph(max_iterations=5)

    # ... define nodes and edges ...
    # Use codex_node/gemini_node when available and appropriate,
    # fall back to claude_node otherwise. See model selection guide below.

    return graph


if __name__ == "__main__":
    graph = build_graph()
    if "--diagram" in sys.argv:
        print(graph.to_ascii())
        sys.exit(0)
    initial_state = {"work_dir": os.getcwd()}
    asyncio.run(graph.run(initial_state))

Read the full file on GitHub · 593 lines

Changes

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.

  1. 1mo ago First seen · 593 lines · 18 tokens per session scan A 033be14ad543

Subscribe to this mod's changes

workflow is a command published in the GitHub repository yorrick/agent-skills (11 stars, last pushed 11d ago), licensed MIT. It adds 18 tokens to every session and 6,819 once invoked, about $0.0001 per session on Opus 5.5. A static security scan graded it A with 1 finding (runs shell commands). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.