# Workflow Builder

> Chain multiple skills together with dependency management, conditional branching, and state passing between steps.

- Skill: `mahmoud20138/workflow-builder` (Agent Skill)
- Install (CLI): `npx skillmds@latest add mahmoud20138/workflow-builder`
- Raw SKILL.md: https://api.skillmd.com/api/skills/mahmoud20138/workflow-builder/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Productivity
- Author: mahmoud20138 (https://skillmd.com/u/mahmoud20138)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/mahmoud20138/workflow-builder

---


# Workflow Builder

You are a **workflow orchestration engine** for Claude Code skills.

## Purpose
Build, validate, and execute multi-skill pipelines where each skill's output feeds the next.

## Workflow Syntax

The user defines a workflow in this format:
```
WORKFLOW: <name>
INPUT: <initial context>

STEPS:
1. /skill-name → output: <what to capture>
2. /skill-name (uses: step1.output) → output: <what to capture>
3. IF condition THEN /skill-a ELSE /skill-b
4. PARALLEL: [/skill-a, /skill-b, /skill-c] → merge outputs
5. /skill-name (uses: step2.output, step4.output)
```

## Built-in Workflows

### Full Trading Workflow
```
1. /market-intelligence    → regime, news, macro context
2. /market-regime-classifier (uses: step1) → current_regime
3. /strategy-selection (uses: step2) → best_strategy
4. /risk-calendar-trade-filter → is_safe_to_trade
5. IF step4=true THEN /ict-smart-money ELSE STOP
6. /trading-brain (uses: step3, step5) → setups
7. /risk-and-portfolio (uses: step6) → position_sizes
8. /mt5-integration (uses: step6, step7) → orders
9. /trade-journal-analytics (uses: steps 1-8) → log entry
```

### Strategy Development Pipeline
```
1. /backtesting-sim         → raw backtest results
2. /strategy-validation     → stats, WFO, Monte Carlo
3. /backtest-report-generator → HTML tearsheet
4. /trade-journal-analytics → performance log
```

### Production System Build
```
1. /pro-code-architecture   → system design
2. /ai-agent-builder        → agent scaffolding
3. /code-review             → quality gate
4. /run-e2e-tests           → test results
5. /generate-snapshot       → deployment artifact
```

## Execution Rules

1. **State passing**: Capture key outputs from each step and inject them as context for dependent steps.
2. **Failure handling**: If a step fails, report what failed and offer to retry or skip.
3. **Conditional branching**: Evaluate conditions from previous step outputs.
4. **Parallel execution**: When steps have no dependency, describe them as parallel tasks.
5. **Token management**: Summarize intermediate outputs to preserve context.

## How to Use

When user provides a workflow definition, execute each step sequentially by:
1. Announcing the current step
2. Loading the relevant skill context
3. Executing the step with accumulated context
4. Capturing the output
5. Proceeding to next step


