ワンクリックで
wf-compose
Propose a weft workflow from conversation context. Scans skills, identifies gaps, builds template with loops.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Propose a weft workflow from conversation context. Scans skills, identifies gaps, builds template with loops.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Query the weft event log with filters. Use only when user types /ev-query.
Analyze weft workflow runs for timing and friction. Use only when user types /wf-analyze.
Check weft template currency — drift of working copies vs the bundled canonical, and whether the plugin clone is behind upstream. Use only when user types /wf-doctor.
Resume a weft workflow parked in 'waiting' at a human gate (unattended on_fail=block). Use only when user types /wf-resume.
Execute the current weft step via the Claude Code Workflow tool, then auto-transition on the structured verdict. Use only when user types /wf-run-step, or when advancing a step whose template declares an executor.
Initialize a weft workflow from a template or inline steps. Use only when user types /wf-start.
| name | wf-compose |
| description | Propose a weft workflow from conversation context. Scans skills, identifies gaps, builds template with loops. |
| argument-hint | [description] [--from template-name] |
| allowed-tools | ["Bash","Read","Write","Glob","Grep"] |
Read the conversation context, scan available skills, identify gaps, and propose a v2 workflow template with loops and skill blocks.
$ARGUMENTS
| Usage | Behavior |
|---|---|
/wf-compose "review, fix, iterate until clean" | One-shot: propose from description |
/wf-compose (no args) | Interactive: ask "What are you trying to accomplish?" |
/wf-compose --from feature-workflow | Start from existing template, modify based on context |
Understand what the user is trying to do:
git branch --show-current 2>/dev/null
git diff --stat 2>/dev/null | tail -5
python3 "${CLAUDE_PLUGIN_ROOT}/core/cli.py" status 2>/dev/null
--from <template> was provided, load it as the starting point:
python3 "${CLAUDE_PLUGIN_ROOT}/core/cli.py" preview <template>
Build a map of what skills are available:
cat "${CLAUDE_SKILLS_REGISTRY:-$HOME/.claude/skills-registry.json}" 2>/dev/null
python3 "${CLAUDE_PLUGIN_ROOT}/core/cli.py" start
Compare what the user described against available skills:
Missing skill: /devils-advocate
Options:
1. Create a stub skill (I'll generate a skeleton)
2. Use /staff-review instead (similar purpose)
3. Skip this step
Build a v2 template JSON:
Map each step in the user's described workflow to a template step.
For each step, set:
name: kebab-case identifierskill: the matching skill name (e.g., "/staff-review"), or null if manualon_fail: "retry" for review/test steps, "block" for critical gates, "continue" for optional stepsguards: add logical guards (e.g., no git push before review)description: one-line summary of what the step doesFor iterative segments (user said "until", "repeat", "loop", "iterate"):
loop_back_to on the last step of the loop, pointing to the firstmax_iterations (default 3, or what the user specified)exit_condition from the user's description (natural language)Add schema_version: 2 to the template root.
Show the proposed workflow in two formats:
Draw the workflow as a flow diagram showing loops:
┌────────────┐ ┌───────────────┐ ┌─────────────┐
│ review │────>│ fix-issues │────>│ run-tests │
│ /staff-rev │ │ /fix-polish │ │ │
└────────────┘ └───────────────┘ └──────┬──────┘
^ │
│ ↻ until clean (max 3) │
└─────────────────────────────────────────┘
│ done
v
┌─────────────┐
│ ship │
│ /pr-ready │
└─────────────┘
For linear segments, use a simple arrow chain:
setup ──> plan ──> implement ──> verify
Show the full template JSON, formatted for readability.
Ask the user:
Approve this workflow? (approve / edit / cancel)
- approve: Save template and optionally start it
- edit: Describe what to change
- cancel: Discard
On approve:
echo '<json>' | python3 "${CLAUDE_PLUGIN_ROOT}/core/cli.py" save-template
/wf-start <template-name>On edit:
On cancel:
skill field. This is metadata — Claude reads it from context.md and knows which skill to invoke.loop_back_to on the last step of the repeating segment. The state machine handles the rest.exit_condition is evaluated by Claude (natural language), not by scripts. Keep conditions specific and observable: "no MEDIUM+ issues" not "code is good enough".max_iterations defaults to 3. If the user says "until done" without a cap, set it to 5 and note the cap.git push before review, no deploy before tests.