// Use when user provides workflow syntax with arrows (-> || ~>), says "run workflow", "execute workflow", "run this", mentions step1 -> step2 patterns. Executes orchestration workflows with real-time visualization, steering, and error recovery.
| name | orchestration:executing-workflows |
| description | Use when user provides workflow syntax with arrows (-> || ~>), says "run workflow", "execute workflow", "run this", mentions step1 -> step2 patterns. Executes orchestration workflows with real-time visualization, steering, and error recovery. |
I execute workflows with real-time visualization, progress tracking, and interactive steering at checkpoints.
I automatically activate when you:
Just provide workflow syntax and I'll handle the rest:
Explore:"Analyze codebase":analysis ->
implement:"Add feature based on {analysis}":code ->
general-purpose:"Run tests":results
I automatically:
I analyze your workflow:
I show you the execution plan using ASCII art:
Execution Graph:
โโโโโโโโโโโโโโโโโโโ
โ Explore โ
โ (Analyze code) โ
โโโโโโโโโโฌโโโโโโโโโ
โ
v
โโโโโโโโโโโโโโโโโโโ
โ implement โ
โ (Add feature) โ
โโโโโโโโโโฌโโโโโโโโโ
โ
v
โโโโโโโโโโโโโโโโโโโ
โ general-purpose โ
โ (Run tests) โ
โโโโโโโโโโโโโโโโโโโ
I run agents sequentially or in parallel:
Sequential (->):
Running: Explore... [In Progress]
Result: โ Analysis complete
Running: implement... [In Progress]
Result: โ Feature added
Parallel (||):
Running: task1... [In Progress]
Running: task2... [In Progress]
Running: task3... [In Progress]
All complete! Merging results...
At checkpoints (@review), you control flow:
@review-point reached
Options:
[C]ontinue - Proceed with workflow
[R]etry - Re-run previous step
[M]odify - Adjust and continue
[A]bort - Stop workflow
Your choice?
If agent fails, I offer options:
โ Agent 'implement' failed: Tests not passing
Options:
- Retry with same instruction
- Modify instruction and retry
- Skip this step (continue workflow)
- Abort workflow
What would you like to do?
CRITICAL: After EVERY workflow execution, you MUST clean up temporary files!
Cleanup steps:
Delete temp-scripts - Remove all Python, JavaScript, shell scripts created during workflow
${CLAUDE_PLUGIN_ROOT}/temp-scripts/Delete temp-agents - Remove temporary agent definitions (if not promoted)
${CLAUDE_PLUGIN_ROOT}/temp-agents/Delete temporary JSON - Remove workflow state files
${CLAUDE_PLUGIN_ROOT}/examples/Report cleanup - Tell user what was cleaned:
๐งน Cleaned up 5 temporary files:
- temp-scripts/fetch_reddit.py
- temp-scripts/process_data.js
- temp-agents/scanner.md
- examples/workflow-state.json
Verify cleanup - Check that temp directories are empty
NEVER skip cleanup! This prevents disk clutter and keeps plugin workspace clean.
See syntax-reference.md for complete syntax documentation.
Quick reference:
| Syntax | Meaning | Example |
|---|---|---|
-> | Sequential | a -> b |
| ` | ` | |
~> | Conditional | (if passed)~> next |
@ | Checkpoint | @review |
:var | Output capture | task:output |
{var} | Variable interpolation | "Use {output}" |
$agent | Temp agent | $scanner:"Scan" |
Built-in Claude Code agents (no prefix):
Explore - Fast codebase exploration and searchPlan - Planning and breaking down tasksgeneral-purpose - Versatile agent for complex multi-step tasksPlugin agents (orchestration: prefix):
orchestration:workflow-socratic-designer - Workflow creation via Socratic methodorchestration:workflow-syntax-designer - Custom syntax designExternal agents (registered via /orchestration:init):
~/.claude/agents/ can be registered and used directlyexpert-code-implementer, code-optimizer (if registered)Temp agents ($name):
See variables.md for advanced variable usage.
Capture output:
Explore:"Find routes":routes ->
analyze:"Check {routes}":findings
Conditional on variables:
test:"Run tests":results ->
(if results.passed)~> deploy ->
(if results.failed)~> debug
Common error patterns:
Retry on failure:
@attempt ->
operation:"Try task" ->
(if failed)~> wait:"Wait 5s" -> @attempt ~>
(if passed)~> continue
Fallback path:
primary:"Try primary" ->
(if failed)~> backup:"Use backup" ~>
(if passed)~> process
Stop on critical error:
security-scan:"Scan" ->
(if critical-issues)~> @emergency-stop -> abort ~>
(if clean)~> deploy
See checkpoints.md for checkpoint details.
Basic checkpoint:
implement -> @review -> deploy
Labeled checkpoint:
@quality-gate:"Review code quality. Approve?"
Conditional checkpoint:
(if security-critical)~> @security-review
See parallel.md for parallel execution patterns.
Basic parallel:
[task1 || task2 || task3] -> merge
Parallel with individual variables:
[
task1:"First":result1 ||
task2:"Second":result2 ||
task3:"Third":result3
] ->
general-purpose:"Process {result1}, {result2}, {result3}"
Conditional parallel:
(if needs-full-scan)~> [security || performance || style] ~>
(if needs-quick-check)~> basic-lint
See examples/ for categorized workflow examples:
Normal mode (default):
Dry-run mode:
Auto mode:
During execution, I show:
Workflow: TDD Implementation
Progress: [โโโโโโโโโโ] 80%
Phase 1: โ Requirements analyzed
Phase 2: โ Tests written
Phase 3: โ Tests verified failing
Phase 4: โธ Checkpoint: review-test-coverage
Phase 5: โณ In Progress: Implementing code...
Phase 6: โธ Pending
Phase 7: โธ Pending
Track execution metadata:
Workflow: debug-and-fix.flow
Started: 2025-01-08 14:32:10
Duration: 5m 23s
Agents used: 8
Checkpoints: 2
Status: โ Complete
Agents executed:
- Explore (ร1)
- general-purpose (ร5)
- expert-code-implementer (ร2)
Resources:
- Files read: 12
- Files modified: 3
- Tests run: 1
Agent not found:
Variable not found:
:varname{varname}Checkpoint skipped:
@checkpoint-nameParallel execution failed:
[a || b]/orchestration:run - Execute workflow from file or inline/orchestration:template - Execute saved template/orchestration:explain - Explain workflow execution planReady to execute? Provide your workflow syntax or template name!