Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Stream-JSON chaining for multi-agent pipelines, data transformation, and sequential workflows
.claude/skills/ruvnet-stream-chain/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-01 | ✗→✓ | ▲ Improved | 198% | 0% |
| case-02 | ✗→✓ | ▲ Improved | 213% | 0% |
| case-03 | ✗→✓ | ▲ Improved | 184% | 0% |
| case-05 | ✗→✓ | ▲ Improved | 184% | 0% |
| case-06 | ✗→✓ | ▲ Improved | 137% | 0% |
Execute sophisticated multi-step workflows where each agent's output flows into the next, enabling complex data transformations and sequential processing pipelines.
Stream-Chain provides two powerful modes for orchestrating multi-agent workflows:
run): Execute custom prompt sequences with full controlpipeline): Use battle-tested workflows for common tasksEach step in a chain receives the complete output from the previous step, enabling sophisticated multi-agent coordination through streaming data flow.
bashclaude-flow stream-chain run \ "Analyze codebase structure" \ "Identify improvement areas" \ "Generate action plan"
bashclaude-flow stream-chain pipeline analysis
run)Execute custom stream chains with your own prompts for maximum flexibility.
bashclaude-flow stream-chain run <prompt1> <prompt2> [...] [options]
Requirements:
| Option | Description | Default | |--------|-------------|---------| | --verbose | Show detailed execution information | false | | --timeout <seconds> | Timeout per step | 30 | | --debug | Enable debug mode with full logging | false |
Each step receives the previous output as context:
Step 1: "Write a sorting function"
Output: [function implementation]
Step 2 receives:
"Previous step output:
[function implementation]
Next task: Add comprehensive tests"
Step 3 receives:
"Previous steps output:
[function + tests]
Next task: Optimize performance"bashclaude-flow stream-chain run \ "Write a user authentication function" \ "Add input validation and error handling" \ "Create unit tests with edge cases"
bashclaude-flow stream-chain run \ "Analyze authentication system for vulnerabilities" \ "Identify and categorize security issues by severity" \ "Propose fixes with implementation priority" \ "Generate security test cases" \ --timeout 45 \ --verbose
bashclaude-flow stream-chain run \ "Identify code smells in src/ directory" \ "Create refactoring plan with specific changes" \ "Apply refactoring to top 3 priority items" \ "Verify refactored code maintains behavior" \ --debug
bashclaude-flow stream-chain run \ "Extract data from API responses" \ "Transform data into normalized format" \ "Validate data against schema" \ "Generate data quality report"
pipeline)Execute battle-tested workflows optimized for common development tasks.
bashclaude-flow stream-chain pipeline <type> [options]
Comprehensive codebase analysis and improvement identification.
bashclaude-flow stream-chain pipeline analysis
Workflow Steps:
Use Cases:
Systematic code refactoring with prioritization.
bashclaude-flow stream-chain pipeline refactor
Workflow Steps:
Use Cases:
Comprehensive test generation with coverage analysis.
bashclaude-flow stream-chain pipeline test
Workflow Steps:
Use Cases:
Performance optimization with profiling and implementation.
bashclaude-flow stream-chain pipeline optimize
Workflow Steps:
Use Cases:
| Option | Description | Default | |--------|-------------|---------| | --verbose | Show detailed execution | false | | --timeout <seconds> | Timeout per step | 30 | | --debug | Enable debug mode | false |
bashclaude-flow stream-chain pipeline analysis
bashclaude-flow stream-chain pipeline refactor --timeout 60 --verbose
bashclaude-flow stream-chain pipeline test --debug
bashclaude-flow stream-chain pipeline optimize --timeout 90 --verbose
Each pipeline execution provides:
Define reusable pipelines in .claude-flow$config.json:
json{ "streamChain": { "pipelines": { "security": { "name": "Security Audit Pipeline", "description": "Comprehensive security analysis", "prompts": [ "Scan codebase for security vulnerabilities", "Categorize issues by severity (critical$high$medium$low)", "Generate fixes with priority and implementation steps", "Create security test suite" ], "timeout": 45 }, "documentation": { "name": "Documentation Generation Pipeline", "prompts": [ "Analyze code structure and identify undocumented areas", "Generate API documentation with examples", "Create usage guides and tutorials", "Build architecture diagrams and flow charts" ] } } } }
bashclaude-flow stream-chain pipeline security claude-flow stream-chain pipeline documentation
Chain different agent types for complex workflows:
bashclaude-flow stream-chain run \ "Research best practices for API design" \ "Design REST API with discovered patterns" \ "Implement API endpoints with validation" \ "Generate OpenAPI specification" \ "Create integration tests" \ "Write deployment documentation"
Process and transform data through multiple stages:
bashclaude-flow stream-chain run \ "Extract user data from CSV files" \ "Normalize and validate data format" \ "Enrich data with external API calls" \ "Generate analytics report" \ "Create visualization code"
Systematic code migration with validation:
bashclaude-flow stream-chain run \ "Analyze legacy codebase dependencies" \ "Create migration plan with risk assessment" \ "Generate modernized code for high-priority modules" \ "Create migration tests" \ "Document migration steps and rollback procedures"
Comprehensive code quality workflow:
bashclaude-flow stream-chain pipeline analysis claude-flow stream-chain pipeline refactor claude-flow stream-chain pipeline test claude-flow stream-chain pipeline optimize
Good:
bash"Analyze authentication.js for SQL injection vulnerabilities"
Avoid:
bash"Check security"
Order prompts to build on previous outputs:
bash1. "Identify the problem" 2. "Analyze root causes" 3. "Design solution" 4. "Implement solution" 5. "Verify implementation"
Include validation in your chains:
bashclaude-flow stream-chain run \ "Implement feature X" \ "Write tests for feature X" \ "Verify tests pass and cover edge cases"
Use chains for iterative improvement:
bashclaude-flow stream-chain run \ "Generate initial implementation" \ "Review and identify issues" \ "Refine based on issues found" \ "Final quality check"
bash# Initialize swarm for coordination claude-flow swarm init --topology mesh # Execute stream chain with swarm agents claude-flow stream-chain run \ "Agent 1: Research task" \ "Agent 2: Implement solution" \ "Agent 3: Test implementation" \ "Agent 4: Review and refine"
Stream chains automatically store context in memory for cross-session persistence:
bash# Execute chain with memory claude-flow stream-chain run \ "Analyze requirements" \ "Design architecture" \ --verbose # Results stored in .claude-flow$memory$stream-chain/
Successful chains train neural patterns for improved performance:
bash# Enable neural training claude-flow stream-chain pipeline optimize --debug # Patterns learned and stored for future optimizations
If steps timeout, increase timeout value:
bashclaude-flow stream-chain run "complex task" --timeout 120
If context not flowing properly, use --debug:
bashclaude-flow stream-chain run "step 1" "step 2" --debug
Verify pipeline name and custom definitions:
bash# Check available pipelines cat .claude-flow$config.json | grep -A 10 "streamChain"
bash# Full feature development chain claude-flow stream-chain run \ "Analyze requirements for user profile feature" \ "Design database schema and API endpoints" \ "Implement backend with validation" \ "Create frontend components" \ "Write comprehensive tests" \ "Generate API documentation" \ --timeout 60 \ --verbose
bash# Automated code review workflow claude-flow stream-chain run \ "Analyze recent git changes" \ "Identify code quality issues" \ "Check for security vulnerabilities" \ "Verify test coverage" \ "Generate code review report with recommendations"
bash# Framework migration helper claude-flow stream-chain run \ "Analyze current Vue 2 codebase" \ "Identify Vue 3 breaking changes" \ "Create migration checklist" \ "Generate migration scripts" \ "Provide updated code examples"
Stream-Chain enables sophisticated multi-step workflows by:
Use run for custom workflows and pipeline for battle-tested solutions.
| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-18 | pass→pass | 6,096 | 1,562 | -74% | 1 | 1 | 0% | 980 | 3,191 | +226% | 0 | 0 | — |
case-01 | fail→pass | 6,441 | 3,543 | -45% | 1 | 1 | 0% | 1,213 | 3,612 | +198% | 0 | 0 | — |
case-02 | fail→pass | 5,286 | 1,931 | -63% | 1 | 1 | 0% | 1,036 | 3,243 | +213% | 0 | 0 | — |
case-03 | fail→pass | 6,792 | 3,578 | -47% | 1 | 1 | 0% | 1,312 | 3,725 | +184% | 0 | 0 | — |
case-04 | pass→pass | 9,345 | 2,931 | -69% | 1 | 1 | 0% | 1,617 | 3,486 | +116% | 0 | 0 | — |
case-05 | fail→pass | 6,035 | 1,430 | -76% | 1 | 1 | 0% | 1,111 | 3,160 | +184% | 0 | 0 | — |
case-06 | fail→pass | 7,713 | 1,926 | -75% | 1 | 1 | 0% | 1,374 | 3,256 | +137% | 0 | 0 | — |
case-07 | fail→pass | 9,768 | 1,978 | -80% | 1 | 1 | 0% | 1,906 | 3,280 | +72% | 0 | 0 | — |
case-08 | fail→pass | 8,667 | 1,943 | -78% | 1 | 1 | 0% | 1,668 | 3,256 | +95% | 0 | 0 | — |
case-09 | pass→pass | 6,513 | 1,487 | -77% | 1 | 1 | 0% | 771 | 3,211 | +316% | 0 | 0 | — |
case-10 | fail→pass | 5,990 | 2,597 | -57% | 1 | 1 | 0% | 1,131 | 3,478 | +208% | 0 | 0 | — |
case-11 | fail→pass | 6,750 | 1,744 | -74% | 1 | 1 | 0% | 1,120 | 3,200 | +186% | 0 | 0 | — |
case-12 | fail→pass | 7,432 | 1,965 | -74% | 1 | 1 | 0% | 1,224 | 3,275 | +168% | 0 | 0 | — |
case-13 | fail→pass | 10,046 | 1,630 | -84% | 1 | 1 | 0% | 1,547 | 3,175 | +105% | 0 | 0 | — |
case-14 | fail→pass | 14,365 | 2,237 | -84% | 1 | 1 | 0% | 1,186 | 3,312 | +179% | 0 | 0 | — |
case-15 | fail→pass | 12,139 | 4,404 | -64% | 1 | 1 | 0% | 1,961 | 3,709 | +89% | 0 | 0 | — |
case-16 | pass→pass | 9,926 | 3,054 | -69% | 1 | 1 | 0% | 1,896 | 3,362 | +77% | 0 | 0 | — |
case-17 | pass→pass | 11,436 | 1,829 | -84% | 1 | 1 | 0% | 1,026 | 3,215 | +213% | 0 | 0 | — |
case-19 | fail→pass | 9,647 | 2,299 | -76% | 1 | 1 | 0% | 1,609 | 3,158 | +96% | 0 | 0 | — |
case-20 | pass→pass | 10,517 | 6,976 | -34% | 1 | 1 | 0% | 1,969 | 4,312 | +119% | 0 | 0 | — |
case-21 | pass→pass | 10,911 | 6,505 | -40% | 1 | 1 | 0% | 2,150 | 4,121 | +92% | 0 | 0 | — |
case-22 | pass→fail | 11,852 | 7,989 | -33% | 1 | 1 | 0% | 2,510 | 4,573 | +82% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted, and 21 counted toward the lift figure. The other 1 produced results that are not comparable between the two arms, so they are excluded from the headline rather than averaged into it. The headline lift of +59 percentage points is the difference between those two pass rates over the 21 comparable cases. 1 case got worse with the skill loaded, and it is included in that figure.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.