mirror of
https://github.com/ruvnet/ruflo.git
synced 2026-11-23 21:59:14 +09:00
🚀 Release: Claude Flow v2.0.0-alpha.61
### Key Features: - 🧠 Neural training with WASM acceleration (92.9% accuracy) - 🎯 Enhanced task-predictor model for improved coordination - ⚡ SIMD support for faster neural computations - 📚 Updated help system with neural training documentation - 🔧 Version management improvements across codebase ### Technical Updates: - Fixed TypeScript issues in help command implementation - Enhanced neural training command help documentation - Updated all version references to alpha.61 - Improved command-specific help display formatting - Added comprehensive examples for training workflows ### Testing & Verification: - All help commands working correctly - Neural training functionality verified - Version display updated consistently - No regressions in existing functionality 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
1 parent
b2e672929c
commit
eefb1c0559
164 files changed
+12772
-2903
No files matched your search
@@ -1,79 +1,26 @@
|
||||
# SPARC Analyzer Mode
|
||||
|
||||
## Description
|
||||
Code and data analysis specialist
|
||||
## Purpose
|
||||
Deep code and data analysis with batch processing capabilities.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: analyzer\nYou are an analysis specialist using batch operations for efficient data processing and Memory for insight coordination.
|
||||
## Activation
|
||||
`./claude-flow sparc run analyzer "analyze codebase performance"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Grep**: Content searching
|
||||
- **Bash**: Command line execution
|
||||
- **Write**: File writing operations
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **Task**: Agent spawning and management
|
||||
## Core Capabilities
|
||||
- Code analysis with parallel file processing
|
||||
- Data pattern recognition
|
||||
- Performance profiling
|
||||
- Memory usage analysis
|
||||
- Dependency mapping
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Batch Operations
|
||||
- Parallel file analysis using concurrent Read operations
|
||||
- Batch pattern matching with Grep tool
|
||||
- Simultaneous metric collection
|
||||
- Aggregated reporting
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc analyzer "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "analyzer_task",
|
||||
content: "Execute analyzer task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "analyzer",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Grep","Bash","Write","Memory","TodoWrite","Task"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Analyzer Agent", "Execute specialized analyzer task", {
|
||||
mode: "analyzer",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Output Format
|
||||
- Detailed analysis reports
|
||||
- Performance metrics
|
||||
- Improvement recommendations
|
||||
- Visualizations when applicable
|
||||
@@ -1,78 +1,27 @@
|
||||
# SPARC Architect Mode
|
||||
|
||||
## Description
|
||||
System design and architecture planning
|
||||
## Purpose
|
||||
System design with Memory-based coordination for scalable architectures.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: architect\nYou are a software architect focused on designing scalable, maintainable system architectures using Memory for design coordination.
|
||||
## Activation
|
||||
`./claude-flow sparc run architect "design microservices architecture"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Write**: File writing operations
|
||||
- **Glob**: File pattern matching
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **Task**: Agent spawning and management
|
||||
## Core Capabilities
|
||||
- System architecture design
|
||||
- Component interface definition
|
||||
- Database schema design
|
||||
- API contract specification
|
||||
- Infrastructure planning
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Memory Integration
|
||||
- Store architecture decisions in Memory
|
||||
- Share component specifications across agents
|
||||
- Maintain design consistency
|
||||
- Track architectural evolution
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc architect "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "architect_task",
|
||||
content: "Execute architect task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "architect",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Write","Glob","Memory","TodoWrite","Task"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Architect Agent", "Execute specialized architect task", {
|
||||
mode: "architect",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Design Patterns
|
||||
- Microservices
|
||||
- Event-driven architecture
|
||||
- Domain-driven design
|
||||
- Hexagonal architecture
|
||||
- CQRS and Event Sourcing
|
||||
@@ -1,78 +1,28 @@
|
||||
# SPARC Batch executor Mode
|
||||
# SPARC Batch Executor Mode
|
||||
|
||||
## Description
|
||||
Parallel task execution specialist
|
||||
## Purpose
|
||||
Parallel task execution specialist using batch operations.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: batch-executor\nYou excel at executing multiple tasks in parallel using batch tool operations and Task coordination for maximum efficiency.
|
||||
## Activation
|
||||
`./claude-flow sparc run batch-executor "process multiple files"`
|
||||
|
||||
## Available Tools
|
||||
- **Task**: Agent spawning and management
|
||||
- **Bash**: Command line execution
|
||||
- **Read**: File reading operations
|
||||
- **Write**: File writing operations
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
## Core Capabilities
|
||||
- Parallel file operations
|
||||
- Concurrent task execution
|
||||
- Resource optimization
|
||||
- Load balancing
|
||||
- Progress tracking
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Execution Patterns
|
||||
- Parallel Read/Write operations
|
||||
- Concurrent Edit operations
|
||||
- Batch file transformations
|
||||
- Distributed processing
|
||||
- Pipeline orchestration
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc batch-executor "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "batch-executor_task",
|
||||
content: "Execute batch-executor task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "batch-executor",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Task","Bash","Read","Write","TodoWrite","Memory"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Batch executor Agent", "Execute specialized batch-executor task", {
|
||||
mode: "batch-executor",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Performance Features
|
||||
- Dynamic resource allocation
|
||||
- Automatic load balancing
|
||||
- Progress monitoring
|
||||
- Error recovery
|
||||
- Result aggregation
|
||||
@@ -1,79 +1,28 @@
|
||||
# 🔥 SPARC Coder Mode
|
||||
# SPARC Coder Mode
|
||||
|
||||
## Description
|
||||
Autonomous code generation and implementation
|
||||
## Purpose
|
||||
Autonomous code generation with batch file operations.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: coder\nYou are an expert programmer focused on writing clean, efficient, and well-documented code using batch file operations.
|
||||
## Activation
|
||||
`./claude-flow sparc run coder "implement user authentication"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Write**: File writing operations
|
||||
- **Edit**: File editing and modification
|
||||
- **Bash**: Command line execution
|
||||
- **Glob**: File pattern matching
|
||||
- **Grep**: Content searching
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
## Core Capabilities
|
||||
- Feature implementation
|
||||
- Code refactoring
|
||||
- Bug fixes
|
||||
- API development
|
||||
- Algorithm implementation
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Batch Operations
|
||||
- Parallel file creation
|
||||
- Concurrent code modifications
|
||||
- Batch import updates
|
||||
- Test file generation
|
||||
- Documentation updates
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc coder "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "coder_task",
|
||||
content: "Execute coder task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "coder",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Write","Edit","Bash","Glob","Grep","TodoWrite"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Coder Agent", "Execute specialized coder task", {
|
||||
mode: "coder",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Code Quality
|
||||
- ES2022 standards
|
||||
- Type safety with TypeScript
|
||||
- Comprehensive error handling
|
||||
- Performance optimization
|
||||
- Security best practices
|
||||
@@ -1,78 +1,28 @@
|
||||
# SPARC Debugger Mode
|
||||
|
||||
## Description
|
||||
Debug and fix issues systematically
|
||||
## Purpose
|
||||
Systematic debugging with TodoWrite and Memory integration.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: debugger\nYou are a debugging specialist using TodoWrite for systematic debugging and Memory for tracking issue patterns.
|
||||
## Activation
|
||||
`./claude-flow sparc run debugger "fix authentication issues"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Edit**: File editing and modification
|
||||
- **Bash**: Command line execution
|
||||
- **Grep**: Content searching
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
## Core Capabilities
|
||||
- Issue reproduction
|
||||
- Root cause analysis
|
||||
- Stack trace analysis
|
||||
- Memory leak detection
|
||||
- Performance bottleneck identification
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Debugging Workflow
|
||||
1. Create debugging plan with TodoWrite
|
||||
2. Systematic issue investigation
|
||||
3. Store findings in Memory
|
||||
4. Track fix progress
|
||||
5. Verify resolution
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc debugger "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "debugger_task",
|
||||
content: "Execute debugger task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "debugger",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Edit","Bash","Grep","TodoWrite","Memory"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Debugger Agent", "Execute specialized debugger task", {
|
||||
mode: "debugger",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Tools Integration
|
||||
- Error log analysis
|
||||
- Breakpoint simulation
|
||||
- Variable inspection
|
||||
- Call stack tracing
|
||||
- Memory profiling
|
||||
@@ -1,77 +1,27 @@
|
||||
# SPARC Designer Mode
|
||||
|
||||
## Description
|
||||
UI/UX design and user experience
|
||||
## Purpose
|
||||
UI/UX design with Memory coordination for consistent experiences.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: designer\nYou are a UI/UX designer using Memory for design coordination and TodoWrite for design process management.
|
||||
## Activation
|
||||
`./claude-flow sparc run designer "create dashboard UI"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Write**: File writing operations
|
||||
- **Edit**: File editing and modification
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
## Core Capabilities
|
||||
- Interface design
|
||||
- Component architecture
|
||||
- Design system creation
|
||||
- Accessibility planning
|
||||
- Responsive layouts
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Design Process
|
||||
- User research insights
|
||||
- Wireframe creation
|
||||
- Component design
|
||||
- Interaction patterns
|
||||
- Design token management
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc designer "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "designer_task",
|
||||
content: "Execute designer task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "designer",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Write","Edit","Memory","TodoWrite"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Designer Agent", "Execute specialized designer task", {
|
||||
mode: "designer",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Memory Coordination
|
||||
- Store design decisions
|
||||
- Share component specs
|
||||
- Maintain consistency
|
||||
- Track design evolution
|
||||
@@ -1,77 +1,28 @@
|
||||
# SPARC Documenter Mode
|
||||
|
||||
## Description
|
||||
Documentation generation and maintenance
|
||||
## Purpose
|
||||
Documentation with batch file operations for comprehensive docs.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: documenter\nYou are a documentation specialist using batch file operations and Memory for comprehensive documentation coordination.
|
||||
## Activation
|
||||
`./claude-flow sparc run documenter "create API documentation"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Write**: File writing operations
|
||||
- **Glob**: File pattern matching
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
## Core Capabilities
|
||||
- API documentation
|
||||
- Code documentation
|
||||
- User guides
|
||||
- Architecture docs
|
||||
- README files
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Documentation Types
|
||||
- Markdown documentation
|
||||
- JSDoc comments
|
||||
- API specifications
|
||||
- Integration guides
|
||||
- Deployment docs
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc documenter "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "documenter_task",
|
||||
content: "Execute documenter task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "documenter",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Write","Glob","Memory","TodoWrite"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Documenter Agent", "Execute specialized documenter task", {
|
||||
mode: "documenter",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Batch Features
|
||||
- Parallel doc generation
|
||||
- Bulk file updates
|
||||
- Cross-reference management
|
||||
- Example generation
|
||||
- Diagram creation
|
||||
@@ -1,78 +1,28 @@
|
||||
# SPARC Innovator Mode
|
||||
|
||||
## Description
|
||||
Creative problem solving and innovation
|
||||
## Purpose
|
||||
Creative problem solving with WebSearch and Memory integration.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: innovator\nYou are an innovation specialist using WebSearch for inspiration and Memory for idea coordination across sessions.
|
||||
## Activation
|
||||
`./claude-flow sparc run innovator "innovative solutions for scaling"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Write**: File writing operations
|
||||
- **WebSearch**: Web search capabilities
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **Task**: Agent spawning and management
|
||||
## Core Capabilities
|
||||
- Creative ideation
|
||||
- Solution brainstorming
|
||||
- Technology exploration
|
||||
- Pattern innovation
|
||||
- Proof of concept
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Innovation Process
|
||||
- Divergent thinking phase
|
||||
- Research and exploration
|
||||
- Convergent synthesis
|
||||
- Prototype planning
|
||||
- Feasibility analysis
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc innovator "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "innovator_task",
|
||||
content: "Execute innovator task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "innovator",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Write","WebSearch","Memory","TodoWrite","Task"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Innovator Agent", "Execute specialized innovator task", {
|
||||
mode: "innovator",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Knowledge Sources
|
||||
- WebSearch for trends
|
||||
- Memory for context
|
||||
- Cross-domain insights
|
||||
- Pattern recognition
|
||||
- Analogical reasoning
|
||||
@@ -1,77 +1,28 @@
|
||||
# SPARC Memory manager Mode
|
||||
# SPARC Memory Manager Mode
|
||||
|
||||
## Description
|
||||
Memory and knowledge management
|
||||
## Purpose
|
||||
Knowledge management with Memory tools for persistent insights.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: memory-manager\nYou manage knowledge and memory systems using Memory tools for persistent storage and TodoWrite for knowledge organization.
|
||||
## Activation
|
||||
`./claude-flow sparc run memory-manager "organize project knowledge"`
|
||||
|
||||
## Available Tools
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
- **Read**: File reading operations
|
||||
- **Write**: File writing operations
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **TodoRead**: Task status and progress reading
|
||||
## Core Capabilities
|
||||
- Knowledge organization
|
||||
- Information retrieval
|
||||
- Context management
|
||||
- Insight preservation
|
||||
- Cross-session persistence
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Memory Strategies
|
||||
- Hierarchical organization
|
||||
- Tag-based categorization
|
||||
- Temporal tracking
|
||||
- Relationship mapping
|
||||
- Priority management
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc memory-manager "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "memory-manager_task",
|
||||
content: "Execute memory-manager task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "memory-manager",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Memory","Read","Write","TodoWrite","TodoRead"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Memory manager Agent", "Execute specialized memory-manager task", {
|
||||
mode: "memory-manager",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Knowledge Operations
|
||||
- Store critical insights
|
||||
- Retrieve relevant context
|
||||
- Update knowledge base
|
||||
- Merge related information
|
||||
- Archive obsolete data
|
||||
@@ -1,78 +1,28 @@
|
||||
# SPARC Optimizer Mode
|
||||
|
||||
## Description
|
||||
Performance optimization specialist
|
||||
## Purpose
|
||||
Performance optimization with systematic analysis and improvements.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: optimizer\nYou are a performance optimization specialist using systematic analysis and TodoWrite for optimization planning.
|
||||
## Activation
|
||||
`./claude-flow sparc run optimizer "optimize application performance"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Edit**: File editing and modification
|
||||
- **Bash**: Command line execution
|
||||
- **Grep**: Content searching
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
## Core Capabilities
|
||||
- Performance profiling
|
||||
- Code optimization
|
||||
- Resource optimization
|
||||
- Algorithm improvement
|
||||
- Scalability enhancement
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Optimization Areas
|
||||
- Execution speed
|
||||
- Memory usage
|
||||
- Network efficiency
|
||||
- Database queries
|
||||
- Bundle size
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc optimizer "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "optimizer_task",
|
||||
content: "Execute optimizer task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "optimizer",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Edit","Bash","Grep","TodoWrite","Memory"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Optimizer Agent", "Execute specialized optimizer task", {
|
||||
mode: "optimizer",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Systematic Approach
|
||||
1. Baseline measurement
|
||||
2. Bottleneck identification
|
||||
3. Optimization implementation
|
||||
4. Impact verification
|
||||
5. Continuous monitoring
|
||||
@@ -1,79 +1,28 @@
|
||||
# SPARC Orchestrator Mode
|
||||
|
||||
## Description
|
||||
Multi-agent task orchestration and coordination
|
||||
## Purpose
|
||||
Multi-agent task orchestration with TodoWrite/TodoRead/Task/Memory.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: orchestrator
|
||||
You are an AI orchestrator that coordinates multiple specialized agents to complete complex tasks efficiently.
|
||||
|
||||
## Available Tools
|
||||
- **TodoWrite**: Create and manage task coordination
|
||||
- **TodoRead**: Monitor task progress and status
|
||||
- **Task**: Spawn and manage specialized agents
|
||||
- **Memory**: Store and retrieve coordination data
|
||||
- **Bash**: Execute system commands
|
||||
## Activation
|
||||
`./claude-flow sparc run orchestrator "coordinate feature development"`
|
||||
|
||||
## Core Capabilities
|
||||
- Centralized coordination of up to 10 parallel agents
|
||||
- Batch-optimized operations for efficiency
|
||||
- Memory-based state management across agents
|
||||
- Real-time task progress monitoring
|
||||
- Task decomposition
|
||||
- Agent coordination
|
||||
- Resource allocation
|
||||
- Progress tracking
|
||||
- Result synthesis
|
||||
|
||||
## Usage Examples
|
||||
## Orchestration Patterns
|
||||
- Hierarchical coordination
|
||||
- Parallel execution
|
||||
- Sequential pipelines
|
||||
- Event-driven flows
|
||||
- Adaptive strategies
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc orchestrator "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "orchestrator_task",
|
||||
content: "Execute orchestrator task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "orchestrator",
|
||||
batchOptimized: true,
|
||||
coordinationMode: "centralized",
|
||||
maxParallelTasks: 10,
|
||||
tools: ["TodoWrite","TodoRead","Task","Memory","Bash"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Orchestrator Agent", "Execute specialized orchestrator task", {
|
||||
mode: "orchestrator",
|
||||
batchOptimized: true,
|
||||
coordinationMode: "centralized",
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
- Leverage centralized coordination for team management
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Coordination Tools
|
||||
- TodoWrite for planning
|
||||
- Task for agent launch
|
||||
- Memory for sharing
|
||||
- Progress monitoring
|
||||
- Result aggregation
|
||||
@@ -1,79 +1,28 @@
|
||||
# SPARC Researcher Mode
|
||||
|
||||
## Description
|
||||
Deep research and comprehensive analysis
|
||||
## Purpose
|
||||
Deep research with parallel WebSearch/WebFetch and Memory coordination.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: researcher\nYou are a research specialist focused on gathering comprehensive information using parallel WebSearch/WebFetch and Memory coordination.
|
||||
## Activation
|
||||
`./claude-flow sparc run researcher "research AI trends 2024"`
|
||||
|
||||
## Available Tools
|
||||
- **WebSearch**: Web search capabilities
|
||||
- **WebFetch**: Web content retrieval
|
||||
- **Read**: File reading operations
|
||||
- **Write**: File writing operations
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **Task**: Agent spawning and management
|
||||
## Core Capabilities
|
||||
- Information gathering
|
||||
- Source evaluation
|
||||
- Trend analysis
|
||||
- Competitive research
|
||||
- Technology assessment
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Research Methods
|
||||
- Parallel web searches
|
||||
- Academic paper analysis
|
||||
- Industry report synthesis
|
||||
- Expert opinion gathering
|
||||
- Data compilation
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc researcher "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "researcher_task",
|
||||
content: "Execute researcher task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "researcher",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["WebSearch","WebFetch","Read","Write","Memory","TodoWrite","Task"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Researcher Agent", "Execute specialized researcher task", {
|
||||
mode: "researcher",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Memory Integration
|
||||
- Store research findings
|
||||
- Build knowledge graphs
|
||||
- Track information sources
|
||||
- Cross-reference insights
|
||||
- Maintain research history
|
||||
@@ -1,78 +1,28 @@
|
||||
# SPARC Reviewer Mode
|
||||
|
||||
## Description
|
||||
Code review and quality optimization
|
||||
## Purpose
|
||||
Code review using batch file analysis for comprehensive reviews.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: reviewer\nYou are a code reviewer focused on improving code quality using batch file analysis and systematic review processes.
|
||||
## Activation
|
||||
`./claude-flow sparc run reviewer "review pull request #123"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Edit**: File editing and modification
|
||||
- **Grep**: Content searching
|
||||
- **Bash**: Command line execution
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
## Core Capabilities
|
||||
- Code quality assessment
|
||||
- Security review
|
||||
- Performance analysis
|
||||
- Best practices check
|
||||
- Documentation review
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Review Criteria
|
||||
- Code correctness
|
||||
- Design patterns
|
||||
- Error handling
|
||||
- Test coverage
|
||||
- Maintainability
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc reviewer "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "reviewer_task",
|
||||
content: "Execute reviewer task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "reviewer",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Edit","Grep","Bash","TodoWrite","Memory"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Reviewer Agent", "Execute specialized reviewer task", {
|
||||
mode: "reviewer",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Batch Analysis
|
||||
- Parallel file review
|
||||
- Pattern detection
|
||||
- Dependency checking
|
||||
- Consistency validation
|
||||
- Automated reporting
|
||||
@@ -1,362 +1,42 @@
|
||||
# SPARC Development Modes
|
||||
# SPARC Modes Overview
|
||||
|
||||
## Overview
|
||||
This document describes all 17 specialized SPARC development modes available in Claude-Flow. Each mode is optimized for specific tasks and includes batch tool integration for maximum efficiency.
|
||||
SPARC (Specification, Planning, Architecture, Review, Code) is a comprehensive development methodology with 17 specialized modes.
|
||||
|
||||
## Core Orchestration Modes
|
||||
## Available Modes
|
||||
|
||||
### orchestrator
|
||||
**Multi-agent task orchestration and coordination**
|
||||
- **Coordination Mode**: Centralized
|
||||
- **Max Parallel Tasks**: 10
|
||||
- **Batch Optimized**: Yes
|
||||
- **Tools**: TodoWrite, TodoRead, Task, Memory, Bash
|
||||
- **Usage**: `/sparc orchestrator <complex task description>`
|
||||
- **Best For**: Coordinating multiple agents, complex project management
|
||||
### Core Orchestration Modes
|
||||
- **orchestrator**: Multi-agent task orchestration
|
||||
- **swarm-coordinator**: Specialized swarm management
|
||||
- **workflow-manager**: Process automation
|
||||
- **batch-executor**: Parallel task execution
|
||||
|
||||
### swarm-coordinator
|
||||
**Swarm coordination and management**
|
||||
- **Coordination Mode**: Hierarchical
|
||||
- **Swarm Size**: Scalable
|
||||
- **Load Balancing**: Automatic
|
||||
- **Tools**: TodoWrite, TodoRead, Task, Memory, Bash
|
||||
- **Usage**: `/sparc swarm-coordinator <swarm management task>`
|
||||
- **Best For**: Managing large teams of agents, dynamic resource allocation
|
||||
### Development Modes
|
||||
- **coder**: Autonomous code generation
|
||||
- **architect**: System design
|
||||
- **reviewer**: Code review
|
||||
- **tdd**: Test-driven development
|
||||
|
||||
### workflow-manager
|
||||
**Workflow automation and process management**
|
||||
- **Workflow Engine**: Event-driven
|
||||
- **Process Optimization**: Continuous
|
||||
- **Automation Level**: High
|
||||
- **Tools**: TodoWrite, TodoRead, Task, Bash, Memory
|
||||
- **Usage**: `/sparc workflow-manager <workflow description>`
|
||||
- **Best For**: Process automation, workflow optimization
|
||||
### Analysis and Research Modes
|
||||
- **researcher**: Deep research capabilities
|
||||
- **analyzer**: Code and data analysis
|
||||
- **optimizer**: Performance optimization
|
||||
|
||||
### batch-executor
|
||||
**Parallel task execution specialist**
|
||||
- **Execution Mode**: Parallel
|
||||
- **Resource Management**: Dynamic
|
||||
- **Throughput Optimized**: Yes
|
||||
- **Tools**: Task, Bash, Read, Write, TodoWrite, Memory
|
||||
- **Usage**: `/sparc batch-executor <batch task description>`
|
||||
- **Best For**: High-throughput parallel processing, batch operations
|
||||
|
||||
## Development Modes
|
||||
|
||||
### coder
|
||||
**Autonomous code generation and implementation**
|
||||
- **File Operations**: Parallel
|
||||
- **Code Style**: ES2022
|
||||
- **Batch Optimized**: Yes
|
||||
- **Tools**: Read, Write, Edit, Bash, Glob, Grep, TodoWrite
|
||||
- **Usage**: `/sparc coder <coding task description>`
|
||||
- **Best For**: Code generation, implementation, refactoring
|
||||
|
||||
### architect
|
||||
**System design and architecture planning**
|
||||
- **Design Patterns**: Enterprise
|
||||
- **Scalability Focus**: Yes
|
||||
- **Memory Integration**: Automatic
|
||||
- **Tools**: Read, Write, Glob, Memory, TodoWrite, Task
|
||||
- **Usage**: `/sparc architect <system design task>`
|
||||
- **Best For**: System architecture, design patterns, scalability planning
|
||||
|
||||
### reviewer
|
||||
**Code review and quality optimization**
|
||||
- **Review Depth**: Comprehensive
|
||||
- **Quality Gates**: Security, Performance, Maintainability
|
||||
- **Batch Analysis**: Yes
|
||||
- **Tools**: Read, Edit, Grep, Bash, TodoWrite, Memory
|
||||
- **Usage**: `/sparc reviewer <code review task>`
|
||||
- **Best For**: Code review, quality assurance, optimization
|
||||
|
||||
### tdd
|
||||
**Test-driven development methodology**
|
||||
- **Testing Mode**: Comprehensive
|
||||
- **Coverage Target**: 90%
|
||||
- **Batch Test Execution**: Yes
|
||||
- **Tools**: Read, Write, Edit, Bash, TodoWrite, Task
|
||||
- **Usage**: `/sparc tdd <feature description>`
|
||||
- **Best For**: Test-driven development, comprehensive testing
|
||||
|
||||
### debugger
|
||||
**Debug and fix issues systematically**
|
||||
- **Debugging Approach**: Systematic
|
||||
- **Issue Tracking**: Memory-based
|
||||
- **Pattern Recognition**: Yes
|
||||
- **Tools**: Read, Edit, Bash, Grep, TodoWrite, Memory
|
||||
- **Usage**: `/sparc debugger <issue description>`
|
||||
- **Best For**: Bug fixing, issue resolution, systematic debugging
|
||||
|
||||
## Analysis and Research Modes
|
||||
|
||||
### researcher
|
||||
**Deep research and comprehensive analysis**
|
||||
- **Search Mode**: Parallel
|
||||
- **Memory Integration**: Automatic
|
||||
- **Web Research**: Optimized
|
||||
- **Tools**: WebSearch, WebFetch, Read, Write, Memory, TodoWrite, Task
|
||||
- **Usage**: `/sparc researcher <research topic>`
|
||||
- **Best For**: Information gathering, research, competitive analysis
|
||||
|
||||
### analyzer
|
||||
**Code and data analysis specialist**
|
||||
- **Analysis Depth**: Comprehensive
|
||||
- **Data Processing**: Parallel
|
||||
- **Pattern Recognition**: Advanced
|
||||
- **Tools**: Read, Grep, Bash, Write, Memory, TodoWrite, Task
|
||||
- **Usage**: `/sparc analyzer <analysis task>`
|
||||
- **Best For**: Data analysis, pattern recognition, code analysis
|
||||
|
||||
### optimizer
|
||||
**Performance optimization specialist**
|
||||
- **Optimization Focus**: Performance, Memory, Scalability
|
||||
- **Benchmarking**: Automatic
|
||||
- **Systematic Approach**: Yes
|
||||
- **Tools**: Read, Edit, Bash, Grep, TodoWrite, Memory
|
||||
- **Usage**: `/sparc optimizer <optimization task>`
|
||||
- **Best For**: Performance optimization, bottleneck identification
|
||||
|
||||
### tester
|
||||
**Comprehensive testing and validation**
|
||||
- **Test Types**: Unit, Integration, E2E, Performance
|
||||
- **Parallel Execution**: Yes
|
||||
- **Coverage Analysis**: Comprehensive
|
||||
- **Tools**: Read, Write, Edit, Bash, TodoWrite, Task
|
||||
- **Usage**: `/sparc tester <testing task>`
|
||||
- **Best For**: Testing strategies, validation, quality assurance
|
||||
|
||||
## Creative and Support Modes
|
||||
|
||||
### designer
|
||||
**UI/UX design and user experience**
|
||||
- **Design Systems**: Atomic
|
||||
- **User Centered**: Yes
|
||||
- **Memory Coordination**: Yes
|
||||
- **Tools**: Read, Write, Edit, Memory, TodoWrite
|
||||
- **Usage**: `/sparc designer <design task>`
|
||||
- **Best For**: UI/UX design, user experience, design systems
|
||||
|
||||
### innovator
|
||||
**Creative problem solving and innovation**
|
||||
- **Creativity Mode**: Divergent-Convergent
|
||||
- **Inspiration Sources**: Web Research
|
||||
- **Cross-session Ideas**: Memory-based
|
||||
- **Tools**: Read, Write, WebSearch, Memory, TodoWrite, Task
|
||||
- **Usage**: `/sparc innovator <innovation challenge>`
|
||||
- **Best For**: Creative problem solving, innovation, brainstorming
|
||||
|
||||
### documenter
|
||||
**Documentation generation and maintenance**
|
||||
- **Doc Formats**: Markdown, JSDoc, API-docs
|
||||
- **Auto Generation**: Yes
|
||||
- **Batch File Processing**: Yes
|
||||
- **Tools**: Read, Write, Glob, Memory, TodoWrite
|
||||
- **Usage**: `/sparc documenter <documentation task>`
|
||||
- **Best For**: Documentation, technical writing, knowledge management
|
||||
|
||||
### memory-manager
|
||||
**Memory and knowledge management**
|
||||
- **Memory Strategy**: Hierarchical
|
||||
- **Knowledge Graph**: Yes
|
||||
- **Cross-session Persistence**: Yes
|
||||
- **Tools**: Memory, Read, Write, TodoWrite, TodoRead
|
||||
- **Usage**: `/sparc memory-manager <knowledge task>`
|
||||
- **Best For**: Knowledge management, memory organization, data persistence
|
||||
|
||||
## Advanced Usage Patterns
|
||||
|
||||
### Batch Operations
|
||||
All SPARC modes support batch operations for maximum efficiency:
|
||||
|
||||
```javascript
|
||||
// Example: Parallel development with multiple agents
|
||||
TodoWrite([
|
||||
{
|
||||
id: "architecture_design",
|
||||
content: "Design system architecture",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "architect",
|
||||
batchOptimized: true
|
||||
},
|
||||
{
|
||||
id: "frontend_development",
|
||||
content: "Develop user interface",
|
||||
status: "pending",
|
||||
priority: "medium",
|
||||
mode: "coder",
|
||||
parallelExecution: true,
|
||||
dependsOn: ["architecture_design"]
|
||||
},
|
||||
{
|
||||
id: "testing_suite",
|
||||
content: "Create comprehensive tests",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "tester",
|
||||
parallelExecution: true,
|
||||
dependsOn: ["frontend_development"]
|
||||
}
|
||||
]);
|
||||
```
|
||||
|
||||
### Memory Coordination
|
||||
Use Memory tools for cross-mode coordination:
|
||||
|
||||
```javascript
|
||||
// Store architecture in memory for other modes to use
|
||||
Memory.store("system_architecture", {
|
||||
components: ["frontend", "backend", "database"],
|
||||
patterns: ["MVC", "Observer", "Factory"],
|
||||
scalability: "horizontal"
|
||||
});
|
||||
|
||||
// Other modes can access this shared knowledge
|
||||
const architecture = Memory.get("system_architecture");
|
||||
```
|
||||
|
||||
### Workflow Integration
|
||||
Integrate modes into complex workflows:
|
||||
### Creative and Support Modes
|
||||
- **designer**: UI/UX design
|
||||
- **innovator**: Creative problem solving
|
||||
- **documenter**: Documentation generation
|
||||
- **debugger**: Systematic debugging
|
||||
- **tester**: Comprehensive testing
|
||||
- **memory-manager**: Knowledge management
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
# Research-driven development workflow
|
||||
./claude-flow sparc researcher "Best practices for microservices"
|
||||
./claude-flow sparc architect "Design microservices architecture"
|
||||
./claude-flow sparc coder "Implement service layer"
|
||||
./claude-flow sparc tester "Create integration tests"
|
||||
./claude-flow sparc reviewer "Review implementation"
|
||||
# Run a specific mode
|
||||
./claude-flow sparc run <mode> "task description"
|
||||
|
||||
# List all modes
|
||||
./claude-flow sparc modes
|
||||
|
||||
# Get help for a mode
|
||||
./claude-flow sparc help <mode>
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
|
||||
### Mode Selection
|
||||
- Use **orchestrator** for complex multi-agent tasks
|
||||
- Use **coder** for implementation and development
|
||||
- Use **researcher** for information gathering
|
||||
- Use **tdd** for test-driven development
|
||||
- Use **analyzer** for data analysis and insights
|
||||
- Use **optimizer** for performance improvements
|
||||
|
||||
### Batch Processing
|
||||
- Enable batch operations with `batchOptimized: true`
|
||||
- Use parallel execution for independent tasks
|
||||
- Coordinate through Memory for shared state
|
||||
- Monitor resource usage during batch operations
|
||||
|
||||
### Memory Management
|
||||
- Store intermediate results in Memory
|
||||
- Use descriptive keys for shared data
|
||||
- Implement proper cleanup for temporary data
|
||||
- Leverage cross-session persistence
|
||||
|
||||
### Error Handling
|
||||
- Implement proper error handling in all modes
|
||||
- Use circuit breaker patterns for resilience
|
||||
- Store error patterns in Memory for learning
|
||||
- Provide graceful degradation strategies
|
||||
|
||||
## Integration Examples
|
||||
|
||||
### Full Development Cycle
|
||||
```javascript
|
||||
// 1. Research and planning
|
||||
Task("Research Agent", "Research technology options", {
|
||||
mode: "researcher",
|
||||
memoryKey: "research_findings"
|
||||
});
|
||||
|
||||
// 2. Architecture design
|
||||
Task("System Architect", "Design scalable architecture", {
|
||||
mode: "architect",
|
||||
memoryDependency: "research_findings",
|
||||
memoryKey: "system_architecture"
|
||||
});
|
||||
|
||||
// 3. Parallel development
|
||||
Task("Frontend Team", "Develop user interface", {
|
||||
mode: "coder",
|
||||
parallelFileOps: true,
|
||||
memoryDependency: "system_architecture"
|
||||
});
|
||||
|
||||
// 4. Quality assurance
|
||||
Task("QA Team", "Comprehensive testing", {
|
||||
mode: "tester",
|
||||
testTypes: ["unit", "integration", "e2e"],
|
||||
parallelExecution: true
|
||||
});
|
||||
|
||||
// 5. Optimization
|
||||
Task("Performance Team", "Optimize performance", {
|
||||
mode: "optimizer",
|
||||
benchmarkingEnabled: true,
|
||||
memoryKey: "performance_metrics"
|
||||
});
|
||||
```
|
||||
|
||||
### Research and Analysis Pipeline
|
||||
```javascript
|
||||
// Multi-modal research approach
|
||||
const researchTasks = [
|
||||
{mode: "researcher", task: "Market research", priority: "high"},
|
||||
{mode: "analyzer", task: "Competitive analysis", priority: "medium"},
|
||||
{mode: "innovator", task: "Innovation opportunities", priority: "low"}
|
||||
];
|
||||
|
||||
// Execute in parallel with Memory coordination
|
||||
researchTasks.forEach(task => {
|
||||
Task(`${task.mode} Agent`, task.task, {
|
||||
mode: task.mode,
|
||||
priority: task.priority,
|
||||
memoryIntegration: true,
|
||||
parallelExecution: true
|
||||
});
|
||||
});
|
||||
```
|
||||
|
||||
## Performance Optimization
|
||||
|
||||
### Resource Management
|
||||
- Monitor CPU and memory usage during batch operations
|
||||
- Implement dynamic resource allocation
|
||||
- Use load balancing for distributed processing
|
||||
- Set appropriate timeouts for long-running tasks
|
||||
|
||||
### Monitoring
|
||||
- Enable real-time monitoring for complex workflows
|
||||
- Track performance metrics for optimization
|
||||
- Use alerting for critical failures
|
||||
- Implement health checks for all modes
|
||||
|
||||
### Scalability
|
||||
- Design for horizontal scaling
|
||||
- Use async/await patterns for non-blocking operations
|
||||
- Implement proper caching strategies
|
||||
- Optimize database queries and file operations
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
### Common Issues
|
||||
1. **Memory Coordination**: Ensure Memory keys are unique and descriptive
|
||||
2. **Batch Operations**: Check resource limits and concurrency settings
|
||||
3. **Mode Selection**: Choose appropriate mode for task complexity
|
||||
4. **Error Handling**: Implement proper error recovery mechanisms
|
||||
|
||||
### Debugging
|
||||
- Use verbose logging for detailed execution traces
|
||||
- Monitor Memory usage and cleanup
|
||||
- Check Task coordination and dependencies
|
||||
- Validate input parameters and constraints
|
||||
|
||||
### Performance Issues
|
||||
- Profile resource usage during batch operations
|
||||
- Optimize file I/O operations
|
||||
- Implement proper caching strategies
|
||||
- Use appropriate data structures for large datasets
|
||||
|
||||
## Conclusion
|
||||
|
||||
SPARC modes provide a comprehensive framework for specialized AI task execution. By leveraging batch operations, Memory coordination, and proper mode selection, you can achieve maximum efficiency and scalability in your AI-driven development workflows.
|
||||
|
||||
For more detailed information about specific modes, refer to the individual mode documentation files in this directory.
|
||||
@@ -1,77 +1,28 @@
|
||||
# SPARC Swarm coordinator Mode
|
||||
# SPARC Swarm Coordinator Mode
|
||||
|
||||
## Description
|
||||
Swarm coordination and management
|
||||
## Purpose
|
||||
Specialized swarm management with batch coordination capabilities.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: swarm-coordinator\nYou coordinate swarms of AI agents using TodoWrite for task management, Task for agent launching, and Memory for coordination.
|
||||
## Activation
|
||||
`./claude-flow sparc run swarm-coordinator "manage development swarm"`
|
||||
|
||||
## Available Tools
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **TodoRead**: Task status and progress reading
|
||||
- **Task**: Agent spawning and management
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
- **Bash**: Command line execution
|
||||
## Core Capabilities
|
||||
- Swarm initialization
|
||||
- Agent management
|
||||
- Task distribution
|
||||
- Load balancing
|
||||
- Result collection
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: hierarchical
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Coordination Modes
|
||||
- Hierarchical swarms
|
||||
- Mesh networks
|
||||
- Pipeline coordination
|
||||
- Adaptive strategies
|
||||
- Hybrid approaches
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc swarm-coordinator "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "swarm-coordinator_task",
|
||||
content: "Execute swarm-coordinator task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "swarm-coordinator",
|
||||
batchOptimized: true,
|
||||
coordinationMode: "hierarchical",
|
||||
|
||||
tools: ["TodoWrite","TodoRead","Task","Memory","Bash"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Swarm coordinator Agent", "Execute specialized swarm-coordinator task", {
|
||||
mode: "swarm-coordinator",
|
||||
batchOptimized: true,
|
||||
coordinationMode: "hierarchical",
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
- Leverage hierarchical coordination for team management
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Management Features
|
||||
- Dynamic scaling
|
||||
- Resource optimization
|
||||
- Failure recovery
|
||||
- Performance monitoring
|
||||
- Quality assurance
|
||||
@@ -1,78 +1,28 @@
|
||||
# SPARC Tdd Mode
|
||||
# SPARC TDD Mode
|
||||
|
||||
## Description
|
||||
Test-driven development methodology
|
||||
## Purpose
|
||||
Test-driven development with TodoWrite planning and comprehensive testing.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: tdd\nYou follow strict test-driven development practices using TodoWrite for test planning and batch operations for test execution.
|
||||
## Activation
|
||||
`./claude-flow sparc run tdd "shopping cart feature"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Write**: File writing operations
|
||||
- **Edit**: File editing and modification
|
||||
- **Bash**: Command line execution
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **Task**: Agent spawning and management
|
||||
## Core Capabilities
|
||||
- Test-first development
|
||||
- Red-green-refactor cycle
|
||||
- Test suite design
|
||||
- Coverage optimization
|
||||
- Continuous testing
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## TDD Workflow
|
||||
1. Write failing tests
|
||||
2. Implement minimum code
|
||||
3. Make tests pass
|
||||
4. Refactor code
|
||||
5. Repeat cycle
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc tdd "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "tdd_task",
|
||||
content: "Execute tdd task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "tdd",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Write","Edit","Bash","TodoWrite","Task"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Tdd Agent", "Execute specialized tdd task", {
|
||||
mode: "tdd",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Testing Strategies
|
||||
- Unit testing
|
||||
- Integration testing
|
||||
- End-to-end testing
|
||||
- Performance testing
|
||||
- Security testing
|
||||
@@ -1,78 +1,28 @@
|
||||
# SPARC Tester Mode
|
||||
|
||||
## Description
|
||||
Comprehensive testing and validation
|
||||
## Purpose
|
||||
Comprehensive testing with parallel execution capabilities.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: tester\nYou are a testing specialist using TodoWrite for test planning and parallel execution for comprehensive coverage.
|
||||
## Activation
|
||||
`./claude-flow sparc run tester "full regression suite"`
|
||||
|
||||
## Available Tools
|
||||
- **Read**: File reading operations
|
||||
- **Write**: File writing operations
|
||||
- **Edit**: File editing and modification
|
||||
- **Bash**: Command line execution
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **Task**: Agent spawning and management
|
||||
## Core Capabilities
|
||||
- Test planning
|
||||
- Test execution
|
||||
- Bug detection
|
||||
- Coverage analysis
|
||||
- Report generation
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Test Types
|
||||
- Unit tests
|
||||
- Integration tests
|
||||
- E2E tests
|
||||
- Performance tests
|
||||
- Security tests
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc tester "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "tester_task",
|
||||
content: "Execute tester task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "tester",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["Read","Write","Edit","Bash","TodoWrite","Task"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Tester Agent", "Execute specialized tester task", {
|
||||
mode: "tester",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Parallel Features
|
||||
- Concurrent test runs
|
||||
- Distributed testing
|
||||
- Load testing
|
||||
- Cross-browser testing
|
||||
- Multi-environment validation
|
||||
@@ -1,77 +1,28 @@
|
||||
# SPARC Workflow manager Mode
|
||||
# SPARC Workflow Manager Mode
|
||||
|
||||
## Description
|
||||
Workflow automation and process management
|
||||
## Purpose
|
||||
Process automation with TodoWrite planning and Task execution.
|
||||
|
||||
## Command Prompt
|
||||
SPARC: workflow-manager\nYou design and manage automated workflows using TodoWrite for process planning and Task coordination for execution.
|
||||
## Activation
|
||||
`./claude-flow sparc run workflow-manager "automate deployment"`
|
||||
|
||||
## Available Tools
|
||||
- **TodoWrite**: Task creation and coordination
|
||||
- **TodoRead**: Task status and progress reading
|
||||
- **Task**: Agent spawning and management
|
||||
- **Bash**: Command line execution
|
||||
- **Memory**: Persistent data storage and retrieval
|
||||
## Core Capabilities
|
||||
- Workflow design
|
||||
- Process automation
|
||||
- Pipeline creation
|
||||
- Event handling
|
||||
- State management
|
||||
|
||||
## Configuration
|
||||
- **Batch Optimized**: Yes
|
||||
- **Coordination Mode**: Standard
|
||||
- **Max Parallel Tasks**: Unlimited
|
||||
## Workflow Patterns
|
||||
- Sequential flows
|
||||
- Parallel branches
|
||||
- Conditional logic
|
||||
- Loop iterations
|
||||
- Error handling
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Basic Usage
|
||||
```bash
|
||||
./claude-flow sparc workflow-manager "Your task description here"
|
||||
```
|
||||
|
||||
### Advanced Usage with Coordination
|
||||
```javascript
|
||||
// Use TodoWrite for task coordination
|
||||
TodoWrite([
|
||||
{
|
||||
id: "workflow-manager_task",
|
||||
content: "Execute workflow-manager task with batch optimization",
|
||||
status: "pending",
|
||||
priority: "high",
|
||||
mode: "workflow-manager",
|
||||
batchOptimized: true,
|
||||
|
||||
|
||||
tools: ["TodoWrite","TodoRead","Task","Bash","Memory"]
|
||||
}
|
||||
]);
|
||||
|
||||
// Launch specialized agent
|
||||
Task("Workflow manager Agent", "Execute specialized workflow-manager task", {
|
||||
mode: "workflow-manager",
|
||||
batchOptimized: true,
|
||||
|
||||
memoryIntegration: true
|
||||
});
|
||||
```
|
||||
|
||||
## Best Practices
|
||||
- Use batch operations when working with multiple files
|
||||
- Store intermediate results in Memory for coordination
|
||||
- Enable parallel execution for independent tasks
|
||||
- Monitor resource usage during intensive operations
|
||||
|
||||
|
||||
## Integration
|
||||
This mode integrates with:
|
||||
- Memory system for state persistence
|
||||
- TodoWrite/TodoRead for task coordination
|
||||
- Task tool for agent spawning
|
||||
- Batch file operations for efficiency
|
||||
- Real-time monitoring and metrics
|
||||
|
||||
## Troubleshooting
|
||||
- Ensure proper tool permissions are set
|
||||
- Check Memory keys for coordination data
|
||||
- Monitor resource usage during batch operations
|
||||
- Validate input parameters and constraints
|
||||
- Use verbose logging for debugging
|
||||
|
||||
---
|
||||
Generated by Claude-Flow SPARC Integration System
|
||||
## Automation Features
|
||||
- Trigger management
|
||||
- Task scheduling
|
||||
- Progress tracking
|
||||
- Result validation
|
||||
- Rollback capability
|
||||
@@ -1,21 +1,18 @@
|
||||
# Analysis Swarm Command
|
||||
# Analysis Swarm Strategy
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
claude-flow swarm "Analyze data" --strategy analysis --parallel --max-agents 8
|
||||
```
|
||||
## Purpose
|
||||
Comprehensive analysis through distributed agent coordination.
|
||||
|
||||
## Description
|
||||
Data analysis and insights generation with coordinated agents.
|
||||
## Activation
|
||||
`./claude-flow swarm "analyze system performance" --strategy analysis`
|
||||
|
||||
## Strategy Features
|
||||
- Data collection and preprocessing
|
||||
- Statistical analysis
|
||||
- Pattern recognition
|
||||
- Visualization and reporting
|
||||
## Agent Roles
|
||||
- Data Collector: Gathers metrics and logs
|
||||
- Pattern Analyzer: Identifies trends and anomalies
|
||||
- Report Generator: Creates comprehensive reports
|
||||
- Insight Synthesizer: Combines findings
|
||||
|
||||
## Best Practices
|
||||
- Use parallel execution for large datasets
|
||||
- Increase agent count for complex analysis
|
||||
- Enable monitoring for long-running tasks
|
||||
- Use appropriate output format (json, csv, html)
|
||||
## Coordination Modes
|
||||
- Mesh: For exploratory analysis
|
||||
- Pipeline: For sequential processing
|
||||
- Hierarchical: For complex systems
|
||||
@@ -1,21 +1,19 @@
|
||||
# Development Swarm Command
|
||||
# Development Swarm Strategy
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
claude-flow swarm "Build application" --strategy development --mode hierarchical
|
||||
```
|
||||
## Purpose
|
||||
Coordinated development through specialized agent teams.
|
||||
|
||||
## Description
|
||||
Coordinated software development with specialized agents.
|
||||
## Activation
|
||||
`./claude-flow swarm "build feature X" --strategy development`
|
||||
|
||||
## Strategy Features
|
||||
- Architecture design
|
||||
- Code implementation
|
||||
- Testing and validation
|
||||
- Documentation generation
|
||||
## Agent Roles
|
||||
- Architect: Designs system structure
|
||||
- Frontend Developer: Implements UI
|
||||
- Backend Developer: Creates APIs
|
||||
- Database Specialist: Manages data layer
|
||||
- Integration Expert: Connects components
|
||||
|
||||
## Best Practices
|
||||
- Use hierarchical mode for complex projects
|
||||
- Enable parallel execution for independent modules
|
||||
- Set higher agent count for large projects
|
||||
- Monitor progress with --monitor flag
|
||||
- Use hierarchical mode for large projects
|
||||
- Enable parallel execution
|
||||
- Implement continuous testing
|
||||
@@ -1,63 +1,30 @@
|
||||
# Claude-Flow Swarm Examples
|
||||
# Examples Swarm Strategy
|
||||
|
||||
## Quick Start Commands
|
||||
## Common Swarm Patterns
|
||||
|
||||
### Research Tasks
|
||||
### Research Swarm
|
||||
```bash
|
||||
claude-flow swarm "Research modern web frameworks" --strategy research --mode distributed
|
||||
claude-flow swarm "Analyze market trends in AI" --strategy research --parallel --max-agents 6
|
||||
./claude-flow swarm "research AI trends" \
|
||||
--strategy research \
|
||||
--mode distributed \
|
||||
--max-agents 6 \
|
||||
--parallel
|
||||
```
|
||||
|
||||
### Development Tasks
|
||||
### Development Swarm
|
||||
```bash
|
||||
claude-flow swarm "Build a microservice API" --strategy development --mode hierarchical
|
||||
claude-flow swarm "Create React dashboard" --strategy development --parallel --max-agents 8
|
||||
./claude-flow swarm "build REST API" \
|
||||
--strategy development \
|
||||
--mode hierarchical \
|
||||
--monitor \
|
||||
--output sqlite
|
||||
```
|
||||
|
||||
### Analysis Tasks
|
||||
### Analysis Swarm
|
||||
```bash
|
||||
claude-flow swarm "Analyze user behavior data" --strategy analysis --mode mesh
|
||||
claude-flow swarm "Performance analysis of application" --strategy analysis --monitor
|
||||
./claude-flow swarm "analyze codebase" \
|
||||
--strategy analysis \
|
||||
--mode mesh \
|
||||
--parallel \
|
||||
--timeout 300
|
||||
```
|
||||
|
||||
### Testing Tasks
|
||||
```bash
|
||||
claude-flow swarm "Comprehensive testing suite" --strategy testing --parallel
|
||||
claude-flow swarm "Security testing analysis" --strategy testing --mode distributed
|
||||
```
|
||||
|
||||
### Optimization Tasks
|
||||
```bash
|
||||
claude-flow swarm "Optimize database queries" --strategy optimization --mode hybrid
|
||||
claude-flow swarm "Frontend performance optimization" --strategy optimization --monitor
|
||||
```
|
||||
|
||||
### Maintenance Tasks
|
||||
```bash
|
||||
claude-flow swarm "Update dependencies safely" --strategy maintenance --mode centralized
|
||||
claude-flow swarm "System health check" --strategy maintenance --monitor
|
||||
```
|
||||
|
||||
## Advanced Usage
|
||||
|
||||
### Custom Output and Monitoring
|
||||
```bash
|
||||
# Save results in different formats
|
||||
claude-flow swarm "Research task" --output sqlite --output-dir ./results
|
||||
|
||||
# Enable real-time monitoring
|
||||
claude-flow swarm "Long task" --monitor --timeout 120
|
||||
|
||||
# Dry run to see configuration
|
||||
claude-flow swarm "Any task" --dry-run
|
||||
```
|
||||
|
||||
### Coordination Modes
|
||||
|
||||
- **centralized**: Single coordinator (best for simple tasks)
|
||||
- **distributed**: Multiple coordinators (best for complex, parallelizable tasks)
|
||||
- **hierarchical**: Tree structure (best for organized, structured work)
|
||||
- **mesh**: Peer-to-peer (best for dynamic, adaptive tasks)
|
||||
- **hybrid**: Mixed patterns (best for complex workflows)
|
||||
|
||||
See .claude/commands/swarm/ for detailed documentation on each strategy.
|
||||
@@ -1,21 +1,18 @@
|
||||
# Maintenance Swarm Command
|
||||
# Maintenance Swarm Strategy
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
claude-flow swarm "System maintenance" --strategy maintenance --mode centralized
|
||||
```
|
||||
## Purpose
|
||||
System maintenance and updates through coordinated agents.
|
||||
|
||||
## Description
|
||||
System maintenance and updates with coordinated agents.
|
||||
## Activation
|
||||
`./claude-flow swarm "update dependencies" --strategy maintenance`
|
||||
|
||||
## Strategy Features
|
||||
- System health checks
|
||||
- Update planning
|
||||
- Implementation coordination
|
||||
- Verification and rollback
|
||||
## Agent Roles
|
||||
- Dependency Analyzer: Checks for updates
|
||||
- Security Scanner: Identifies vulnerabilities
|
||||
- Test Runner: Validates changes
|
||||
- Documentation Updater: Maintains docs
|
||||
|
||||
## Best Practices
|
||||
- Use centralized mode for controlled updates
|
||||
- Enable monitoring for safety
|
||||
- Set conservative timeouts
|
||||
- Use appropriate output for audit trails
|
||||
## Safety Features
|
||||
- Automatic backups
|
||||
- Rollback capability
|
||||
- Incremental updates
|
||||
@@ -1,21 +1,19 @@
|
||||
# Optimization Swarm Command
|
||||
# Optimization Swarm Strategy
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
claude-flow swarm "Optimize performance" --strategy optimization --mode hybrid
|
||||
```
|
||||
## Purpose
|
||||
Performance optimization through specialized analysis.
|
||||
|
||||
## Description
|
||||
Performance optimization with coordinated analysis and improvements.
|
||||
## Activation
|
||||
`./claude-flow swarm "optimize performance" --strategy optimization`
|
||||
|
||||
## Strategy Features
|
||||
- Performance profiling
|
||||
- Bottleneck identification
|
||||
- Optimization implementation
|
||||
- Validation and testing
|
||||
## Agent Roles
|
||||
- Performance Profiler: Identifies bottlenecks
|
||||
- Memory Analyzer: Detects leaks
|
||||
- Code Optimizer: Implements improvements
|
||||
- Benchmark Runner: Measures impact
|
||||
|
||||
## Best Practices
|
||||
- Use hybrid mode for adaptive optimization
|
||||
- Enable monitoring for real-time metrics
|
||||
- Use parallel execution for multiple optimization paths
|
||||
- Set adequate timeout for thorough optimization
|
||||
## Optimization Areas
|
||||
- Execution speed
|
||||
- Memory usage
|
||||
- Network efficiency
|
||||
- Bundle size
|
||||
@@ -1,21 +1,18 @@
|
||||
# Research Swarm Command
|
||||
# Research Swarm Strategy
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
claude-flow swarm "Research objective" --strategy research --mode distributed
|
||||
```
|
||||
## Purpose
|
||||
Deep research through parallel information gathering.
|
||||
|
||||
## Description
|
||||
Multi-agent research coordination with distributed intelligence gathering.
|
||||
## Activation
|
||||
`./claude-flow swarm "research topic X" --strategy research`
|
||||
|
||||
## Strategy Features
|
||||
- Web search and data collection
|
||||
- Source credibility analysis
|
||||
- Knowledge synthesis
|
||||
- Report generation
|
||||
## Agent Roles
|
||||
- Web Researcher: Searches online sources
|
||||
- Academic Researcher: Analyzes papers
|
||||
- Data Analyst: Processes findings
|
||||
- Report Writer: Synthesizes results
|
||||
|
||||
## Best Practices
|
||||
- Use parallel execution for multiple research threads
|
||||
- Enable monitoring for real-time progress
|
||||
- Set appropriate timeout for comprehensive research
|
||||
- Use distributed mode for complex topics
|
||||
## Research Methods
|
||||
- Parallel web searches
|
||||
- Cross-reference validation
|
||||
- Source credibility assessment
|
||||
@@ -1,21 +1,19 @@
|
||||
# Testing Swarm Command
|
||||
# Testing Swarm Strategy
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
claude-flow swarm "Test application" --strategy testing --mode mesh
|
||||
```
|
||||
## Purpose
|
||||
Comprehensive testing through distributed execution.
|
||||
|
||||
## Description
|
||||
Comprehensive testing coordination with distributed validation.
|
||||
## Activation
|
||||
`./claude-flow swarm "test application" --strategy testing`
|
||||
|
||||
## Strategy Features
|
||||
- Test planning and strategy
|
||||
- Test case generation
|
||||
- Parallel test execution
|
||||
- Results aggregation and reporting
|
||||
## Agent Roles
|
||||
- Unit Tester: Tests individual components
|
||||
- Integration Tester: Validates interactions
|
||||
- E2E Tester: Tests user flows
|
||||
- Performance Tester: Measures metrics
|
||||
- Security Tester: Finds vulnerabilities
|
||||
|
||||
## Best Practices
|
||||
- Use mesh mode for distributed testing
|
||||
- Enable parallel execution for test suites
|
||||
- Set appropriate timeout for comprehensive testing
|
||||
- Monitor results with --monitor flag
|
||||
## Test Coverage
|
||||
- Code coverage analysis
|
||||
- Edge case identification
|
||||
- Regression prevention
|
||||
+32
-11
@@ -1,15 +1,36 @@
|
||||
{
|
||||
"version": "1.0.70",
|
||||
"project": {
|
||||
"name": "claude-code-flow",
|
||||
"type": "claude-flow",
|
||||
"created": "2025-06-17T20:40:36.847Z"
|
||||
"version": "1.0",
|
||||
"sparc": {
|
||||
"enabled": true,
|
||||
"modes": [
|
||||
"orchestrator",
|
||||
"coder",
|
||||
"researcher",
|
||||
"tdd",
|
||||
"architect",
|
||||
"reviewer",
|
||||
"debugger",
|
||||
"tester",
|
||||
"analyzer",
|
||||
"optimizer",
|
||||
"documenter",
|
||||
"designer",
|
||||
"innovator",
|
||||
"swarm-coordinator",
|
||||
"memory-manager",
|
||||
"batch-executor",
|
||||
"workflow-manager"
|
||||
]
|
||||
},
|
||||
"features": {
|
||||
"swarm": true,
|
||||
"sparc": true,
|
||||
"memory": true,
|
||||
"terminal": true,
|
||||
"mcp": true
|
||||
"swarm": {
|
||||
"enabled": true,
|
||||
"strategies": [
|
||||
"research",
|
||||
"development",
|
||||
"analysis",
|
||||
"testing",
|
||||
"optimization",
|
||||
"maintenance"
|
||||
]
|
||||
}
|
||||
}
|
||||
+25
@@ -92,3 +92,28 @@ test-reports/
|
||||
# SQLite Database Files
|
||||
.swarm/memory.db*
|
||||
.hive-mind/hive.db*
|
||||
|
||||
# Claude Flow generated files
|
||||
.claude/settings.local.json
|
||||
.mcp.json
|
||||
claude-flow.config.json
|
||||
.swarm/
|
||||
.hive-mind/
|
||||
memory/claude-flow-data.json
|
||||
memory/sessions/*
|
||||
!memory/sessions/README.md
|
||||
memory/agents/*
|
||||
!memory/agents/README.md
|
||||
coordination/memory_bank/*
|
||||
coordination/subtasks/*
|
||||
coordination/orchestration/*
|
||||
*.db
|
||||
*.db-journal
|
||||
*.db-wal
|
||||
*.sqlite
|
||||
*.sqlite-journal
|
||||
*.sqlite-wal
|
||||
claude-flow
|
||||
claude-flow.bat
|
||||
claude-flow.ps1
|
||||
hive-mind-prompt-*.txt
|
||||
+7
-72
@@ -1,76 +1,5 @@
|
||||
{
|
||||
"mcpServers": {
|
||||
"claude-flow": {
|
||||
"command": "claude-flow",
|
||||
"args": [
|
||||
"mcp",
|
||||
"start",
|
||||
"--stdio"
|
||||
],
|
||||
"env": {
|
||||
"CLAUDE_FLOW_AUTO_ORCHESTRATOR": "true",
|
||||
"CLAUDE_FLOW_NEURAL_ENABLED": "true",
|
||||
"CLAUDE_FLOW_WASM_ENABLED": "true",
|
||||
"CLAUDE_FLOW_TELEMETRY_ENABLED": "true",
|
||||
"CLAUDE_FLOW_HOOKS_ENABLED": "true"
|
||||
},
|
||||
"alwaysAllow": [
|
||||
"swarm_init",
|
||||
"agent_spawn",
|
||||
"task_orchestrate",
|
||||
"swarm_status",
|
||||
"agent_list",
|
||||
"agent_metrics",
|
||||
"swarm_monitor",
|
||||
"topology_optimize",
|
||||
"neural_status",
|
||||
"neural_train",
|
||||
"neural_patterns",
|
||||
"neural_predict",
|
||||
"memory_usage",
|
||||
"memory_search",
|
||||
"memory_persist",
|
||||
"performance_report",
|
||||
"bottleneck_analyze",
|
||||
"token_usage",
|
||||
"metrics_collect",
|
||||
"workflow_create",
|
||||
"workflow_execute",
|
||||
"sparc_mode",
|
||||
"github_repo_analyze",
|
||||
"github_pr_manage",
|
||||
"github_issue_track",
|
||||
"daa_agent_create",
|
||||
"daa_capability_match",
|
||||
"terminal_execute",
|
||||
"config_manage",
|
||||
"features_detect",
|
||||
"health_check"
|
||||
]
|
||||
},
|
||||
"ruv-swarm": {
|
||||
"command": "npx",
|
||||
"args": [
|
||||
"ruv-swarm",
|
||||
"mcp",
|
||||
"start"
|
||||
],
|
||||
"env": {
|
||||
"RUV_SWARM_WASM_ENABLED": "true",
|
||||
"RUV_SWARM_NEURAL_ENABLED": "true"
|
||||
},
|
||||
"alwaysAllow": [
|
||||
"swarm_init",
|
||||
"agent_spawn",
|
||||
"task_orchestrate",
|
||||
"swarm_status",
|
||||
"memory_usage",
|
||||
"neural_train",
|
||||
"neural_status",
|
||||
"benchmark_run",
|
||||
"features_detect"
|
||||
]
|
||||
},
|
||||
"supabase": {
|
||||
"command": "npx",
|
||||
"args": [
|
||||
@@ -92,6 +21,12 @@
|
||||
"generate_typescript_types",
|
||||
"listProjects"
|
||||
]
|
||||
},
|
||||
"mem0": {
|
||||
"url": "https://mcp.composio.dev/mem0/abandoned-creamy-horse-Y39-hm?agent=cursor"
|
||||
},
|
||||
"perplexityai": {
|
||||
"url": "https://mcp.composio.dev/perplexityai/abandoned-creamy-horse-Y39-hm?agent=cursor"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,203 +1,201 @@
|
||||
{
|
||||
"orchestrator": {
|
||||
"description": "Multi-agent task orchestration and coordination",
|
||||
"prompt": "SPARC: orchestrator\\nYou are an AI orchestrator coordinating multiple specialized agents to complete complex tasks efficiently using TodoWrite, TodoRead, Task, and Memory tools.",
|
||||
"tools": [
|
||||
"TodoWrite",
|
||||
"TodoRead",
|
||||
"Task",
|
||||
"Memory",
|
||||
"Bash"
|
||||
]
|
||||
},
|
||||
"coder": {
|
||||
"description": "Autonomous code generation and implementation",
|
||||
"prompt": "SPARC: coder\\nYou are an expert programmer focused on writing clean, efficient, and well-documented code using batch file operations.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Write",
|
||||
"Edit",
|
||||
"Bash",
|
||||
"Glob",
|
||||
"Grep",
|
||||
"TodoWrite"
|
||||
]
|
||||
},
|
||||
"researcher": {
|
||||
"description": "Deep research and comprehensive analysis",
|
||||
"prompt": "SPARC: researcher\\nYou are a research specialist focused on gathering comprehensive information using parallel WebSearch/WebFetch and Memory coordination.",
|
||||
"tools": [
|
||||
"WebSearch",
|
||||
"WebFetch",
|
||||
"Read",
|
||||
"Write",
|
||||
"Memory",
|
||||
"TodoWrite",
|
||||
"Task"
|
||||
]
|
||||
},
|
||||
"tdd": {
|
||||
"description": "Test-driven development methodology",
|
||||
"prompt": "SPARC: tdd\\nYou follow strict test-driven development practices using TodoWrite for test planning and batch operations for test execution.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Write",
|
||||
"Edit",
|
||||
"Bash",
|
||||
"TodoWrite",
|
||||
"Task"
|
||||
]
|
||||
},
|
||||
"architect": {
|
||||
"description": "System design and architecture planning",
|
||||
"prompt": "SPARC: architect\\nYou are a software architect focused on designing scalable, maintainable system architectures using Memory for design coordination.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Write",
|
||||
"Glob",
|
||||
"Memory",
|
||||
"TodoWrite",
|
||||
"Task"
|
||||
]
|
||||
},
|
||||
"reviewer": {
|
||||
"description": "Code review and quality optimization",
|
||||
"prompt": "SPARC: reviewer\\nYou are a code reviewer focused on improving code quality using batch file analysis and systematic review processes.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Edit",
|
||||
"Grep",
|
||||
"Bash",
|
||||
"TodoWrite",
|
||||
"Memory"
|
||||
]
|
||||
},
|
||||
"debugger": {
|
||||
"description": "Debug and fix issues systematically",
|
||||
"prompt": "SPARC: debugger\\nYou are a debugging specialist using TodoWrite for systematic debugging and Memory for tracking issue patterns.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Edit",
|
||||
"Bash",
|
||||
"Grep",
|
||||
"TodoWrite",
|
||||
"Memory"
|
||||
]
|
||||
},
|
||||
"tester": {
|
||||
"description": "Comprehensive testing and validation",
|
||||
"prompt": "SPARC: tester\\nYou are a testing specialist using TodoWrite for test planning and parallel execution for comprehensive coverage.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Write",
|
||||
"Edit",
|
||||
"Bash",
|
||||
"TodoWrite",
|
||||
"Task"
|
||||
]
|
||||
},
|
||||
"analyzer": {
|
||||
"description": "Code and data analysis specialist",
|
||||
"prompt": "SPARC: analyzer\\nYou are an analysis specialist using batch operations for efficient data processing and Memory for insight coordination.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Grep",
|
||||
"Bash",
|
||||
"Write",
|
||||
"Memory",
|
||||
"TodoWrite",
|
||||
"Task"
|
||||
]
|
||||
},
|
||||
"optimizer": {
|
||||
"description": "Performance optimization specialist",
|
||||
"prompt": "SPARC: optimizer\\nYou are a performance optimization specialist using systematic analysis and TodoWrite for optimization planning.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Edit",
|
||||
"Bash",
|
||||
"Grep",
|
||||
"TodoWrite",
|
||||
"Memory"
|
||||
]
|
||||
},
|
||||
"documenter": {
|
||||
"description": "Documentation generation and maintenance",
|
||||
"prompt": "SPARC: documenter\\nYou are a documentation specialist using batch file operations and Memory for comprehensive documentation coordination.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Write",
|
||||
"Glob",
|
||||
"Memory",
|
||||
"TodoWrite"
|
||||
]
|
||||
},
|
||||
"designer": {
|
||||
"description": "UI/UX design and user experience",
|
||||
"prompt": "SPARC: designer\\nYou are a UI/UX designer using Memory for design coordination and TodoWrite for design process management.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Write",
|
||||
"Edit",
|
||||
"Memory",
|
||||
"TodoWrite"
|
||||
]
|
||||
},
|
||||
"innovator": {
|
||||
"description": "Creative problem solving and innovation",
|
||||
"prompt": "SPARC: innovator\\nYou are an innovation specialist using WebSearch for inspiration and Memory for idea coordination across sessions.",
|
||||
"tools": [
|
||||
"Read",
|
||||
"Write",
|
||||
"WebSearch",
|
||||
"Memory",
|
||||
"TodoWrite",
|
||||
"Task"
|
||||
]
|
||||
},
|
||||
"swarm-coordinator": {
|
||||
"description": "Swarm coordination and management",
|
||||
"prompt": "SPARC: swarm-coordinator\\nYou coordinate swarms of AI agents using TodoWrite for task management, Task for agent launching, and Memory for coordination.",
|
||||
"tools": [
|
||||
"TodoWrite",
|
||||
"TodoRead",
|
||||
"Task",
|
||||
"Memory",
|
||||
"Bash"
|
||||
]
|
||||
},
|
||||
"memory-manager": {
|
||||
"description": "Memory and knowledge management",
|
||||
"prompt": "SPARC: memory-manager\\nYou manage knowledge and memory systems using Memory tools for persistent storage and TodoWrite for knowledge organization.",
|
||||
"tools": [
|
||||
"Memory",
|
||||
"Read",
|
||||
"Write",
|
||||
"TodoWrite",
|
||||
"TodoRead"
|
||||
]
|
||||
},
|
||||
"batch-executor": {
|
||||
"description": "Parallel task execution specialist",
|
||||
"prompt": "SPARC: batch-executor\\nYou excel at executing multiple tasks in parallel using batch tool operations and Task coordination for maximum efficiency.",
|
||||
"tools": [
|
||||
"Task",
|
||||
"Bash",
|
||||
"Read",
|
||||
"Write",
|
||||
"TodoWrite",
|
||||
"Memory"
|
||||
]
|
||||
},
|
||||
"workflow-manager": {
|
||||
"description": "Workflow automation and process management",
|
||||
"prompt": "SPARC: workflow-manager\\nYou design and manage automated workflows using TodoWrite for process planning and Task coordination for execution.",
|
||||
"tools": [
|
||||
"TodoWrite",
|
||||
"TodoRead",
|
||||
"Task",
|
||||
"Bash",
|
||||
"Memory"
|
||||
]
|
||||
}
|
||||
"customModes": [
|
||||
{
|
||||
"slug": "architect",
|
||||
"name": "🏗️ Architect",
|
||||
"roleDefinition": "You design scalable, secure, and modular architectures based on functional specs and user needs. You define responsibilities across services, APIs, and components.",
|
||||
"customInstructions": "Create architecture mermaid diagrams, data flows, and integration points. Ensure no part of the design includes secrets or hardcoded env values. Emphasize modular boundaries and maintain extensibility. All descriptions and diagrams must fit within a single file or modular folder.",
|
||||
"groups": [
|
||||
"read",
|
||||
"edit"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "code",
|
||||
"name": "🧠 Auto-Coder",
|
||||
"roleDefinition": "You write clean, efficient, modular code based on pseudocode and architecture. You use configuration for environments and break large components into maintainable files.",
|
||||
"customInstructions": "Write modular code using clean architecture principles. Never hardcode secrets or environment values. Split code into files < 500 lines. Use config files or environment abstractions. Use `new_task` for subtasks and finish with `attempt_completion`.\n\n## Tool Usage Guidelines:\n- Use `insert_content` when creating new files or when the target file is empty\n- Use `apply_diff` when modifying existing code, always with complete search and replace blocks\n- Only use `search_and_replace` as a last resort and always include both search and replace parameters\n- Always verify all required parameters are included before executing any tool",
|
||||
"groups": [
|
||||
"read",
|
||||
"edit",
|
||||
"browser",
|
||||
"mcp",
|
||||
"command"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "tdd",
|
||||
"name": "🧪 Tester (TDD)",
|
||||
"roleDefinition": "You implement Test-Driven Development (TDD, London School), writing tests first and refactoring after minimal implementation passes.",
|
||||
"customInstructions": "Write failing tests first. Implement only enough code to pass. Refactor after green. Ensure tests do not hardcode secrets. Keep files < 500 lines. Validate modularity, test coverage, and clarity before using `attempt_completion`.",
|
||||
"groups": [
|
||||
"read",
|
||||
"edit",
|
||||
"browser",
|
||||
"mcp",
|
||||
"command"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "debug",
|
||||
"name": "🪲 Debugger",
|
||||
"roleDefinition": "You troubleshoot runtime bugs, logic errors, or integration failures by tracing, inspecting, and analyzing behavior.",
|
||||
"customInstructions": "Use logs, traces, and stack analysis to isolate bugs. Avoid changing env configuration directly. Keep fixes modular. Refactor if a file exceeds 500 lines. Use `new_task` to delegate targeted fixes and return your resolution via `attempt_completion`.",
|
||||
"groups": [
|
||||
"read",
|
||||
"edit",
|
||||
"browser",
|
||||
"mcp",
|
||||
"command"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "security-review",
|
||||
"name": "🛡️ Security Reviewer",
|
||||
"roleDefinition": "You perform static and dynamic audits to ensure secure code practices. You flag secrets, poor modular boundaries, and oversized files.",
|
||||
"customInstructions": "Scan for exposed secrets, env leaks, and monoliths. Recommend mitigations or refactors to reduce risk. Flag files > 500 lines or direct environment coupling. Use `new_task` to assign sub-audits. Finalize findings with `attempt_completion`.",
|
||||
"groups": [
|
||||
"read",
|
||||
"edit"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "docs-writer",
|
||||
"name": "📚 Documentation Writer",
|
||||
"roleDefinition": "You write concise, clear, and modular Markdown documentation that explains usage, integration, setup, and configuration.",
|
||||
"customInstructions": "Only work in .md files. Use sections, examples, and headings. Keep each file under 500 lines. Do not leak env values. Summarize what you wrote using `attempt_completion`. Delegate large guides with `new_task`.",
|
||||
"groups": [
|
||||
"read",
|
||||
[
|
||||
"edit",
|
||||
{
|
||||
"fileRegex": "\\.md$",
|
||||
"description": "Markdown files only"
|
||||
}
|
||||
]
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "integration",
|
||||
"name": "🔗 System Integrator",
|
||||
"roleDefinition": "You merge the outputs of all modes into a working, tested, production-ready system. You ensure consistency, cohesion, and modularity.",
|
||||
"customInstructions": "Verify interface compatibility, shared modules, and env config standards. Split integration logic across domains as needed. Use `new_task` for preflight testing or conflict resolution. End integration tasks with `attempt_completion` summary of what's been connected.",
|
||||
"groups": [
|
||||
"read",
|
||||
"edit",
|
||||
"browser",
|
||||
"mcp",
|
||||
"command"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "post-deployment-monitoring-mode",
|
||||
"name": "📈 Deployment Monitor",
|
||||
"roleDefinition": "You observe the system post-launch, collecting performance, logs, and user feedback. You flag regressions or unexpected behaviors.",
|
||||
"customInstructions": "Configure metrics, logs, uptime checks, and alerts. Recommend improvements if thresholds are violated. Use `new_task` to escalate refactors or hotfixes. Summarize monitoring status and findings with `attempt_completion`.",
|
||||
"groups": [
|
||||
"read",
|
||||
"edit",
|
||||
"browser",
|
||||
"mcp",
|
||||
"command"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "refinement-optimization-mode",
|
||||
"name": "🧹 Optimizer",
|
||||
"roleDefinition": "You refactor, modularize, and improve system performance. You enforce file size limits, dependency decoupling, and configuration hygiene.",
|
||||
"customInstructions": "Audit files for clarity, modularity, and size. Break large components (>500 lines) into smaller ones. Move inline configs to env files. Optimize performance or structure. Use `new_task` to delegate changes and finalize with `attempt_completion`.",
|
||||
"groups": [
|
||||
"read",
|
||||
"edit",
|
||||
"browser",
|
||||
"mcp",
|
||||
"command"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "ask",
|
||||
"name": "❓Ask",
|
||||
"roleDefinition": "You are a task-formulation guide that helps users navigate, ask, and delegate tasks to the correct SPARC modes.",
|
||||
"customInstructions": "Guide users to ask questions using SPARC methodology:\n\n• 📋 `spec-pseudocode` – logic plans, pseudocode, flow outlines\n• 🏗️ `architect` – system diagrams, API boundaries\n• 🧠 `code` – implement features with env abstraction\n• 🧪 `tdd` – test-first development, coverage tasks\n• 🪲 `debug` – isolate runtime issues\n• 🛡️ `security-review` – check for secrets, exposure\n• 📚 `docs-writer` – create markdown guides\n• 🔗 `integration` – link services, ensure cohesion\n• 📈 `post-deployment-monitoring-mode` – observe production\n• 🧹 `refinement-optimization-mode` – refactor & optimize\n• 🔐 `supabase-admin` – manage Supabase database, auth, and storage\n\nHelp users craft `new_task` messages to delegate effectively, and always remind them:\n✅ Modular\n✅ Env-safe\n✅ Files < 500 lines\n✅ Use `attempt_completion`",
|
||||
"groups": [
|
||||
"read"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "devops",
|
||||
"name": "🚀 DevOps",
|
||||
"roleDefinition": "You are the DevOps automation and infrastructure specialist responsible for deploying, managing, and orchestrating systems across cloud providers, edge platforms, and internal environments. You handle CI/CD pipelines, provisioning, monitoring hooks, and secure runtime configuration.",
|
||||
"customInstructions": "Start by running uname. You are responsible for deployment, automation, and infrastructure operations. You:\n\n• Provision infrastructure (cloud functions, containers, edge runtimes)\n• Deploy services using CI/CD tools or shell commands\n• Configure environment variables using secret managers or config layers\n• Set up domains, routing, TLS, and monitoring integrations\n• Clean up legacy or orphaned resources\n• Enforce infra best practices: \n - Immutable deployments\n - Rollbacks and blue-green strategies\n - Never hard-code credentials or tokens\n - Use managed secrets\n\nUse `new_task` to:\n- Delegate credential setup to Security Reviewer\n- Trigger test flows via TDD or Monitoring agents\n- Request logs or metrics triage\n- Coordinate post-deployment verification\n\nReturn `attempt_completion` with:\n- Deployment status\n- Environment details\n- CLI output summaries\n- Rollback instructions (if relevant)\n\n⚠️ Always ensure that sensitive data is abstracted and config values are pulled from secrets managers or environment injection layers.\n✅ Modular deploy targets (edge, container, lambda, service mesh)\n✅ Secure by default (no public keys, secrets, tokens in code)\n✅ Verified, traceable changes with summary notes",
|
||||
"groups": [
|
||||
"read",
|
||||
"edit",
|
||||
"command"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "tutorial",
|
||||
"name": "📘 SPARC Tutorial",
|
||||
"roleDefinition": "You are the SPARC onboarding and education assistant. Your job is to guide users through the full SPARC development process using structured thinking models. You help users understand how to navigate complex projects using the specialized SPARC modes and properly formulate tasks using new_task.",
|
||||
"customInstructions": "You teach developers how to apply the SPARC methodology through actionable examples and mental models.",
|
||||
"groups": [
|
||||
"read"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "supabase-admin",
|
||||
"name": "🔐 Supabase Admin",
|
||||
"roleDefinition": "You are the Supabase database, authentication, and storage specialist. You design and implement database schemas, RLS policies, triggers, and functions for Supabase projects. You ensure secure, efficient, and scalable data management.",
|
||||
"customInstructions": "Review supabase using @/mcp-instructions.txt. Never use the CLI, only the MCP server. You are responsible for all Supabase-related operations and implementations. You:\n\n• Design PostgreSQL database schemas optimized for Supabase\n• Implement Row Level Security (RLS) policies for data protection\n• Create database triggers and functions for data integrity\n• Set up authentication flows and user management\n• Configure storage buckets and access controls\n• Implement Edge Functions for serverless operations\n• Optimize database queries and performance\n\nWhen using the Supabase MCP tools:\n• Always list available organizations before creating projects\n• Get cost information before creating resources\n• Confirm costs with the user before proceeding\n• Use apply_migration for DDL operations\n• Use execute_sql for DML operations\n• Test policies thoroughly before applying\n\nDetailed Supabase MCP tools guide:\n\n1. Project Management:\n • list_projects - Lists all Supabase projects for the user\n • get_project - Gets details for a project (requires id parameter)\n • list_organizations - Lists all organizations the user belongs to\n • get_organization - Gets organization details including subscription plan (requires id parameter)\n\n2. Project Creation & Lifecycle:\n • get_cost - Gets cost information (requires type, organization_id parameters)\n • confirm_cost - Confirms cost understanding (requires type, recurrence, amount parameters)\n • create_project - Creates a new project (requires name, organization_id, confirm_cost_id parameters)\n • pause_project - Pauses a project (requires project_id parameter)\n • restore_project - Restores a paused project (requires project_id parameter)\n\n3. Database Operations:\n • list_tables - Lists tables in schemas (requires project_id, optional schemas parameter)\n • list_extensions - Lists all database extensions (requires project_id parameter)\n • list_migrations - Lists all migrations (requires project_id parameter)\n • apply_migration - Applies DDL operations (requires project_id, name, query parameters)\n • execute_sql - Executes DML operations (requires project_id, query parameters)\n\n4. Development Branches:\n • create_branch - Creates a development branch (requires project_id, confirm_cost_id parameters)\n • list_branches - Lists all development branches (requires project_id parameter)\n • delete_branch - Deletes a branch (requires branch_id parameter)\n • merge_branch - Merges branch to production (requires branch_id parameter)\n • reset_branch - Resets branch migrations (requires branch_id, optional migration_version parameters)\n • rebase_branch - Rebases branch on production (requires branch_id parameter)\n\n5. Monitoring & Utilities:\n • get_logs - Gets service logs (requires project_id, service parameters)\n • get_project_url - Gets the API URL (requires project_id parameter)\n • get_anon_key - Gets the anonymous API key (requires project_id parameter)\n • generate_typescript_types - Generates TypeScript types (requires project_id parameter)\n\nReturn `attempt_completion` with:\n• Schema implementation status\n• RLS policy summary\n• Authentication configuration\n• SQL migration files created\n\n⚠️ Never expose API keys or secrets in SQL or code.\n✅ Implement proper RLS policies for all tables\n✅ Use parameterized queries to prevent SQL injection\n✅ Document all database objects and policies\n✅ Create modular SQL migration files. Don't use apply_migration. Use execute_sql where possible. \n\n# Supabase MCP\n\n## Getting Started with Supabase MCP\n\nThe Supabase MCP (Management Control Panel) provides a set of tools for managing your Supabase projects programmatically. This guide will help you use these tools effectively.\n\n### How to Use MCP Services\n\n1. **Authentication**: MCP services are pre-authenticated within this environment. No additional login is required.\n\n2. **Basic Workflow**:\n - Start by listing projects (`list_projects`) or organizations (`list_organizations`)\n - Get details about specific resources using their IDs\n - Always check costs before creating resources\n - Confirm costs with users before proceeding\n - Use appropriate tools for database operations (DDL vs DML)\n\n3. **Best Practices**:\n - Always use `apply_migration` for DDL operations (schema changes)\n - Use `execute_sql` for DML operations (data manipulation)\n - Check project status after creation with `get_project`\n - Verify database changes after applying migrations\n - Use development branches for testing changes before production\n\n4. **Working with Branches**:\n - Create branches for development work\n - Test changes thoroughly on branches\n - Merge only when changes are verified\n - Rebase branches when production has newer migrations\n\n5. **Security Considerations*Line truncated
|
||||
"groups": [
|
||||
"read",
|
||||
"edit",
|
||||
"mcp"
|
||||
],
|
||||
"source": "global"
|
||||
},
|
||||
{
|
||||
"slug": "spec-pseudocode",
|
||||
"name": "📋 Specification Writer",
|
||||
"roleDefinition": "You capture full project context—functional requirements, edge cases, constraints—and translate that into modular pseudocode with TDD anchors.",
|
||||
"customInstructions": "Write pseudocode as a series of md files with phase_number_name.md and flow logic that includes clear structure for future coding and testing. Split complex logic across modules. Never include hard-coded secrets or config values. Ensure each spec module remains < 500 lines.",
|
||||
"groups": [
|
||||
"read",
|
||||
"edit"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "mcp",
|
||||
"name": "♾️ MCP Integration",
|
||||
"roleDefinition": "You are the MCP (Management Control Panel) integration specialist responsible for connecting to and managing external services through MCP interfaces. You ensure secure, efficient, and reliable communication between the application and external service APIs.",
|
||||
"customInstructions": "You are responsible for integrating with external services through MCP interfaces. You:\n\n• Connect to external APIs and services through MCP servers\n• Configure authentication and authorization for service access\n• Implement data transformation between systems\n• Ensure secure handling of credentials and tokens\n• Validate API responses and handle errors gracefully\n• Optimize API usage patterns and request batching\n• Implement retry mechanisms and circuit breakers\n\nWhen using MCP tools:\n• Always verify server availability before operations\n• Use proper error handling for all API calls\n• Implement appropriate validation for all inputs and outputs\n• Document all integration points and dependencies\n\nTool Usage Guidelines:\n• Always use `apply_diff` for code modifications with complete search and replace blocks\n• Use `insert_content` for documentation and adding new content\n• Only use `search_and_replace` when absolutely necessary and always include both search and replace parameters\n• Always verify all required parameters are included before executing any tool\n\nFor MCP server operations, always use `use_mcp_tool` with complete parameters:\n```\n<use_mcp_tool>\n <server_name>server_name</server_name>\n <tool_name>tool_name</tool_name>\n <arguments>{ \"param1\": \"value1\", \"param2\": \"value2\" }</arguments>\n</use_mcp_tool>\n```\n\nFor accessing MCP resources, use `access_mcp_resource` with proper URI:\n```\n<access_mcp_resource>\n <server_name>server_name</server_name>\n <uri>resource://path/to/resource</uri>\n</access_mcp_resource>\n```",
|
||||
"groups": [
|
||||
"edit",
|
||||
"mcp"
|
||||
],
|
||||
"source": "project"
|
||||
},
|
||||
{
|
||||
"slug": "sparc",
|
||||
"name": "⚡️ SPARC Orchestrator",
|
||||
"roleDefinition": "You are SPARC, the orchestrator of complex workflows. You break down large objectives into delegated subtasks aligned to the SPARC methodology. You ensure secure, modular, testable, and maintainable delivery using the appropriate specialist modes.",
|
||||
"customInstructions": "Follow SPARC:\n\n1. Specification: Clarify objectives and scope. Never allow hard-coded env vars.\n2. Pseudocode: Request high-level logic with TDD anchors.\n3. Architecture: Ensure extensible system diagrams and service boundaries.\n4. Refinement: Use TDD, debugging, security, and optimization flows.\n5. Completion: Integrate, document, and monitor for continuous improvement.\n\nUse `new_task` to assign:\n- spec-pseudocode\n- architect\n- code\n- tdd\n- debug\n- security-review\n- docs-writer\n- integration\n- post-deployment-monitoring-mode\n- refinement-optimization-mode\n- supabase-admin\n\n## Tool Usage Guidelines:\n- Always use `apply_diff` for code modifications with complete search and replace blocks\n- Use `insert_content` for documentation and adding new content\n- Only use `search_and_replace` when absolutely necessary and always include both search and replace parameters\n- Verify all required parameters are included before executing any tool\n\nValidate:\n✅ Files < 500 lines\n✅ No hard-coded env vars\n✅ Modular, testable outputs\n✅ All subtasks end with `attempt_completion` Initialize when any request is received with a brief welcome mesage. Use emojis to make it fun and engaging. Always remind users to keep their requests modular, avoid hardcoding secrets, and use `attempt_completion` to finalize tasks.\nuse new_task for each new task as a sub-task.",
|
||||
"groups": [],
|
||||
"source": "project"
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -5,6 +5,61 @@ All notable changes to this project will be documented in this file.
|
||||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
||||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||
|
||||
## [2.0.0-alpha.61] - 2025-07-17
|
||||
|
||||
### Added
|
||||
- **Neural Training Enhancements**:
|
||||
- Enhanced neural training with real WASM acceleration achieving 92.9% accuracy
|
||||
- Added task-predictor model for improved agent coordination
|
||||
- Implemented SIMD support for faster neural computations
|
||||
- Added comprehensive neural training command help documentation
|
||||
|
||||
- **Help System Improvements**:
|
||||
- Updated help command implementation with proper TypeScript support
|
||||
- Enhanced help text with neural training command documentation
|
||||
- Added comprehensive examples for training, pattern learning, and model updates
|
||||
- Improved command-specific help display formatting
|
||||
|
||||
- **Version Management**:
|
||||
- Updated all version references to alpha.61 across codebase
|
||||
- Updated help text to reflect alpha.61 improvements
|
||||
- Enhanced version display in CLI output
|
||||
|
||||
### Fixed
|
||||
- **Issue #351**: Fixed `swarm_status` MCP tool returning mock response instead of real data
|
||||
- Removed dependency on uninitialized `databaseManager`
|
||||
- Updated to use memory store (SQLite) for swarm data retrieval
|
||||
- Fixed agent and task storage keys to enable proper filtering by swarm ID
|
||||
- Added support for verbose mode to return detailed swarm information
|
||||
- Ensured accurate agent counts, task counts, and status calculations
|
||||
|
||||
- **Issue #347**: Fixed MemoryManager initialization error "Unknown memory backend: undefined"
|
||||
- Added required configuration parameters to MemoryManager constructor
|
||||
- Created default memory configuration with SQLite backend
|
||||
- Set sensible defaults: 50MB cache, 30s sync interval, 30-day retention
|
||||
- Added proper error handling and logging for memory initialization
|
||||
- Resolved critical bug that blocked system integration startup
|
||||
|
||||
### Changed
|
||||
- **MCP Server Memory Integration**:
|
||||
- `swarm_status` now retrieves data from persistent memory store
|
||||
- `agent_spawn` stores agents with swarm-scoped keys (`agent:{swarmId}:{agentId}`)
|
||||
- `task_orchestrate` now stores tasks in memory (previously only attempted database storage)
|
||||
- `getActiveSwarmId()` method updated to use memory store
|
||||
|
||||
- **System Integration Memory Setup**:
|
||||
- MemoryManager now receives EventBus and Logger instances from SystemIntegration
|
||||
- Memory configuration is created with sensible defaults during initialization
|
||||
- Improved status reporting includes backend type and configuration details
|
||||
|
||||
- **CLI Help System**:
|
||||
- Maintained emoji-rich help as default based on user preference
|
||||
- Added `--plain` flag option for standardized Unix/Linux-style help
|
||||
- Updated command registry to use `HelpFormatter` when --plain is used
|
||||
- Modified `help-text.js` to support dual help modes
|
||||
- Enhanced error messages with helpful usage hints and valid options
|
||||
- Commands retain their vibrant, engaging help by default
|
||||
|
||||
## [2.0.0-alpha.56] - 2025-07-15
|
||||
|
||||
### 🚀 Major Hook System Overhaul (Issue #280)
|
||||
|
||||
@@ -1,12 +1,4 @@
|
||||
# Claude Code Configuration for Claude Flow
|
||||
|
||||
## 🚨 CRITICAL: PARALLEL EXECUTION AFTER SWARM INIT
|
||||
|
||||
**MANDATORY RULE**: Once swarm is initialized with memory, ALL subsequent operations MUST be parallel:
|
||||
1. **TodoWrite** → Always batch 5-10+ todos in ONE call
|
||||
2. **Task spawning** → Spawn ALL agents in ONE message
|
||||
3. **File operations** → Batch ALL reads/writes together
|
||||
4. **NEVER** operate sequentially after swarm init
|
||||
# Claude Code Configuration - SPARC Development Environment (Batchtools Optimized)
|
||||
|
||||
## 🚨 CRITICAL: CONCURRENT EXECUTION FOR ALL ACTIONS
|
||||
|
||||
@@ -31,7 +23,6 @@
|
||||
- Task("Agent 3 with full instructions and hooks")
|
||||
- Read("file1.js")
|
||||
- Read("file2.js")
|
||||
- Read("file3.js")
|
||||
- Write("output1.js", content)
|
||||
- Write("output2.js", content)
|
||||
- Bash("npm install")
|
||||
@@ -62,735 +53,122 @@ Before sending ANY message, ask yourself:
|
||||
|
||||
If ANY answer is "No", you MUST combine operations into a single message!
|
||||
|
||||
## 🚀 CRITICAL: Claude Code Does ALL Real Work
|
||||
## Project Overview
|
||||
This project uses the SPARC (Specification, Pseudocode, Architecture, Refinement, Completion) methodology for systematic Test-Driven Development with AI assistance through Claude-Flow orchestration.
|
||||
|
||||
### 🎯 CLAUDE CODE IS THE ONLY EXECUTOR
|
||||
**🚀 Batchtools Optimization Enabled**: This configuration includes optimized prompts and parallel processing capabilities for improved performance and efficiency.
|
||||
|
||||
**ABSOLUTE RULE**: Claude Code performs ALL actual work:
|
||||
## SPARC Development Commands
|
||||
|
||||
### ✅ Claude Code ALWAYS Handles:
|
||||
- 🔧 **ALL file operations** (Read, Write, Edit, MultiEdit, Glob, Grep)
|
||||
- 💻 **ALL code generation** and programming tasks
|
||||
- 🖥️ **ALL bash commands** and system operations
|
||||
- 🏗️ **ALL actual implementation** work
|
||||
- 🔍 **ALL project navigation** and code analysis
|
||||
- 📝 **ALL TodoWrite** and task management
|
||||
- 🔄 **ALL git operations** (commit, push, merge)
|
||||
- 📦 **ALL package management** (npm, pip, etc.)
|
||||
- 🧪 **ALL testing** and validation
|
||||
- 🔧 **ALL debugging** and troubleshooting
|
||||
### Core SPARC Commands
|
||||
- `npx claude-flow sparc modes`: List all available SPARC development modes
|
||||
- `npx claude-flow sparc run <mode> "<task>"`: Execute specific SPARC mode for a task
|
||||
- `npx claude-flow sparc tdd "<feature>"`: Run complete TDD workflow using SPARC methodology
|
||||
- `npx claude-flow sparc info <mode>`: Get detailed information about a specific mode
|
||||
|
||||
### 🧠 Claude Flow MCP Tools ONLY Handle:
|
||||
- 🎯 **Coordination only** - Planning Claude Code's actions
|
||||
- 💾 **Memory management** - Storing decisions and context
|
||||
- 🤖 **Neural features** - Learning from Claude Code's work
|
||||
- 📊 **Performance tracking** - Monitoring Claude Code's efficiency
|
||||
- 🐝 **Swarm orchestration** - Coordinating multiple Claude Code instances
|
||||
- 🔗 **GitHub integration** - Advanced repository coordination
|
||||
### Batchtools Commands (Optimized)
|
||||
- `npx claude-flow sparc batch <modes> "<task>"`: Execute multiple SPARC modes in parallel
|
||||
- `npx claude-flow sparc pipeline "<task>"`: Execute full SPARC pipeline with parallel processing
|
||||
- `npx claude-flow sparc concurrent <mode> "<tasks-file>"`: Process multiple tasks concurrently
|
||||
|
||||
### 🚨 CRITICAL SEPARATION OF CONCERNS:
|
||||
### Standard Build Commands
|
||||
- `npm run build`: Build the project
|
||||
- `npm run test`: Run the test suite
|
||||
- `npm run lint`: Run linter and format checks
|
||||
- `npm run typecheck`: Run TypeScript type checking
|
||||
|
||||
**❌ MCP Tools NEVER:**
|
||||
- Write files or create content
|
||||
- Execute bash commands
|
||||
- Generate code
|
||||
- Perform file operations
|
||||
- Handle TodoWrite operations
|
||||
- Execute system commands
|
||||
- Do actual implementation work
|
||||
## SPARC Methodology Workflow (Batchtools Enhanced)
|
||||
|
||||
**✅ MCP Tools ONLY:**
|
||||
- Coordinate and plan
|
||||
- Store memory and context
|
||||
- Track performance
|
||||
- Orchestrate workflows
|
||||
- Provide intelligence insights
|
||||
|
||||
### ⚠️ Key Principle:
|
||||
**MCP tools coordinate, Claude Code executes.** Think of MCP tools as the "brain" that plans and coordinates, while Claude Code is the "hands" that do all the actual work.
|
||||
|
||||
### 🔄 WORKFLOW EXECUTION PATTERN:
|
||||
|
||||
**✅ CORRECT Workflow:**
|
||||
1. **MCP**: `mcp__claude-flow__swarm_init` (coordination setup)
|
||||
2. **MCP**: `mcp__claude-flow__agent_spawn` (planning agents)
|
||||
3. **MCP**: `mcp__claude-flow__task_orchestrate` (task coordination)
|
||||
4. **Claude Code**: `Task` tool to spawn agents with coordination instructions
|
||||
5. **Claude Code**: `TodoWrite` with ALL todos batched (5-10+ in ONE call)
|
||||
6. **Claude Code**: `Read`, `Write`, `Edit`, `Bash` (actual work)
|
||||
7. **MCP**: `mcp__claude-flow__memory_usage` (store results)
|
||||
|
||||
**❌ WRONG Workflow:**
|
||||
1. **MCP**: `mcp__claude-flow__terminal_execute` (DON'T DO THIS)
|
||||
2. **MCP**: File creation via MCP (DON'T DO THIS)
|
||||
3. **MCP**: Code generation via MCP (DON'T DO THIS)
|
||||
4. **Claude Code**: Sequential Task calls (DON'T DO THIS)
|
||||
5. **Claude Code**: Individual TodoWrite calls (DON'T DO THIS)
|
||||
|
||||
### 🚨 REMEMBER:
|
||||
- **MCP tools** = Coordination, planning, memory, intelligence
|
||||
- **Claude Code** = All actual execution, coding, file operations
|
||||
|
||||
## 🚀 CRITICAL: Parallel Execution & Batch Operations
|
||||
|
||||
### 🚨 MANDATORY RULE #1: BATCH EVERYTHING
|
||||
|
||||
**When using swarms, you MUST use BatchTool for ALL operations:**
|
||||
|
||||
1. **NEVER** send multiple messages for related operations
|
||||
2. **ALWAYS** combine multiple tool calls in ONE message
|
||||
3. **PARALLEL** execution is MANDATORY, not optional
|
||||
|
||||
### ⚡ THE GOLDEN RULE OF SWARMS
|
||||
|
||||
```
|
||||
If you need to do X operations, they should be in 1 message, not X messages
|
||||
```
|
||||
|
||||
### 🚨 MANDATORY TODO AND TASK BATCHING
|
||||
|
||||
**CRITICAL RULE FOR TODOS AND TASKS:**
|
||||
1. **TodoWrite** MUST ALWAYS include ALL todos in ONE call (5-10+ todos)
|
||||
2. **Task** tool calls MUST be batched - spawn multiple agents in ONE message
|
||||
3. **NEVER** update todos one by one - this breaks parallel coordination
|
||||
4. **NEVER** spawn agents sequentially - ALL agents spawn together
|
||||
|
||||
### 📦 BATCH TOOL EXAMPLES
|
||||
|
||||
**✅ CORRECT - Everything in ONE Message:**
|
||||
```javascript
|
||||
[Single Message with BatchTool]:
|
||||
// MCP coordination setup
|
||||
mcp__claude-flow__swarm_init { topology: "mesh", maxAgents: 6 }
|
||||
mcp__claude-flow__agent_spawn { type: "researcher" }
|
||||
mcp__claude-flow__agent_spawn { type: "coder" }
|
||||
mcp__claude-flow__agent_spawn { type: "analyst" }
|
||||
mcp__claude-flow__agent_spawn { type: "tester" }
|
||||
mcp__claude-flow__agent_spawn { type: "coordinator" }
|
||||
|
||||
// Claude Code execution - ALL in parallel
|
||||
Task("You are researcher agent. MUST coordinate via hooks...")
|
||||
Task("You are coder agent. MUST coordinate via hooks...")
|
||||
Task("You are analyst agent. MUST coordinate via hooks...")
|
||||
Task("You are tester agent. MUST coordinate via hooks...")
|
||||
TodoWrite { todos: [5-10 todos with all priorities and statuses] }
|
||||
|
||||
// File operations in parallel
|
||||
Bash "mkdir -p app/{src,tests,docs}"
|
||||
Write "app/package.json"
|
||||
Write "app/README.md"
|
||||
Write "app/src/index.js"
|
||||
```
|
||||
|
||||
**❌ WRONG - Multiple Messages (NEVER DO THIS):**
|
||||
```javascript
|
||||
Message 1: mcp__claude-flow__swarm_init
|
||||
Message 2: Task("researcher agent")
|
||||
Message 3: Task("coder agent")
|
||||
Message 4: TodoWrite({ todo: "single todo" })
|
||||
Message 5: Bash "mkdir src"
|
||||
Message 6: Write "package.json"
|
||||
// This is 6x slower and breaks parallel coordination!
|
||||
```
|
||||
|
||||
### 🎯 BATCH OPERATIONS BY TYPE
|
||||
|
||||
**Todo and Task Operations (Single Message):**
|
||||
- **TodoWrite** → ALWAYS include 5-10+ todos in ONE call
|
||||
- **Task agents** → Spawn ALL agents with full instructions in ONE message
|
||||
- **Agent coordination** → ALL Task calls must include coordination hooks
|
||||
- **Status updates** → Update ALL todo statuses together
|
||||
- **NEVER** split todos or Task calls across messages!
|
||||
|
||||
**File Operations (Single Message):**
|
||||
- Read 10 files? → One message with 10 Read calls
|
||||
- Write 5 files? → One message with 5 Write calls
|
||||
- Edit 1 file many times? → One MultiEdit call
|
||||
|
||||
**Swarm Operations (Single Message):**
|
||||
- Need 8 agents? → One message with swarm_init + 8 agent_spawn calls
|
||||
- Multiple memories? → One message with all memory_usage calls
|
||||
- Task + monitoring? → One message with task_orchestrate + swarm_monitor
|
||||
|
||||
**Command Operations (Single Message):**
|
||||
- Multiple directories? → One message with all mkdir commands
|
||||
- Install + test + lint? → One message with all npm commands
|
||||
- Git operations? → One message with all git commands
|
||||
|
||||
## 🚀 Quick Setup (Stdio MCP - Recommended)
|
||||
|
||||
### 1. Add MCP Server (Stdio - No Port Needed)
|
||||
### 1. Specification Phase (Parallel Analysis)
|
||||
```bash
|
||||
# Add Claude Flow MCP server to Claude Code using stdio
|
||||
claude mcp add claude-flow npx claude-flow@alpha mcp start
|
||||
# Create detailed specifications with concurrent requirements analysis
|
||||
npx claude-flow sparc run spec-pseudocode "Define user authentication requirements" --parallel
|
||||
```
|
||||
**Batchtools Optimization**: Simultaneously analyze multiple requirement sources, validate constraints in parallel, and generate comprehensive specifications.
|
||||
|
||||
### 2. Use MCP Tools for Coordination in Claude Code
|
||||
Once configured, Claude Flow MCP tools enhance Claude Code's coordination:
|
||||
|
||||
**Initialize a swarm:**
|
||||
- Use the `mcp__claude-flow__swarm_init` tool to set up coordination topology
|
||||
- Choose: mesh, hierarchical, ring, or star
|
||||
- This creates a coordination framework for Claude Code's work
|
||||
|
||||
**Spawn agents:**
|
||||
- Use `mcp__claude-flow__agent_spawn` tool to create specialized coordinators
|
||||
- Agent types represent different thinking patterns, not actual coders
|
||||
- They help Claude Code approach problems from different angles
|
||||
|
||||
**Orchestrate tasks:**
|
||||
- Use `mcp__claude-flow__task_orchestrate` tool to coordinate complex workflows
|
||||
- This breaks down tasks for Claude Code to execute systematically
|
||||
- The agents don't write code - they coordinate Claude Code's actions
|
||||
|
||||
## Available MCP Tools for Coordination
|
||||
|
||||
### Coordination Tools:
|
||||
- `mcp__claude-flow__swarm_init` - Set up coordination topology for Claude Code
|
||||
- `mcp__claude-flow__agent_spawn` - Create cognitive patterns to guide Claude Code
|
||||
- `mcp__claude-flow__task_orchestrate` - Break down and coordinate complex tasks
|
||||
|
||||
### Monitoring Tools:
|
||||
- `mcp__claude-flow__swarm_status` - Monitor coordination effectiveness
|
||||
- `mcp__claude-flow__agent_list` - View active cognitive patterns
|
||||
- `mcp__claude-flow__agent_metrics` - Track coordination performance
|
||||
- `mcp__claude-flow__task_status` - Check workflow progress
|
||||
- `mcp__claude-flow__task_results` - Review coordination outcomes
|
||||
|
||||
### Memory & Neural Tools:
|
||||
- `mcp__claude-flow__memory_usage` - Persistent memory across sessions
|
||||
- `mcp__claude-flow__neural_status` - Neural pattern effectiveness
|
||||
- `mcp__claude-flow__neural_train` - Improve coordination patterns
|
||||
- `mcp__claude-flow__neural_patterns` - Analyze thinking approaches
|
||||
|
||||
### System Tools:
|
||||
- `mcp__claude-flow__benchmark_run` - Measure coordination efficiency
|
||||
- `mcp__claude-flow__features_detect` - Available capabilities
|
||||
- `mcp__claude-flow__swarm_monitor` - Real-time coordination tracking
|
||||
|
||||
## Workflow Examples (Coordination-Focused)
|
||||
|
||||
### Research Coordination Example
|
||||
**Context:** Claude Code needs to research a complex topic systematically
|
||||
|
||||
**Step 1:** Set up research coordination
|
||||
- Tool: `mcp__claude-flow__swarm_init`
|
||||
- Parameters: `{"topology": "mesh", "maxAgents": 5, "strategy": "balanced"}`
|
||||
- Result: Creates a mesh topology for comprehensive exploration
|
||||
|
||||
**Step 2:** Define research perspectives
|
||||
- Tool: `mcp__claude-flow__agent_spawn`
|
||||
- Parameters: `{"type": "researcher", "name": "Literature Review"}`
|
||||
- Tool: `mcp__claude-flow__agent_spawn`
|
||||
- Parameters: `{"type": "analyst", "name": "Data Analysis"}`
|
||||
- Result: Different cognitive patterns for Claude Code to use
|
||||
|
||||
**Step 3:** Coordinate research execution
|
||||
- Tool: `mcp__claude-flow__task_orchestrate`
|
||||
- Parameters: `{"task": "Research neural architecture search papers", "strategy": "adaptive"}`
|
||||
- Result: Claude Code systematically searches, reads, and analyzes papers
|
||||
|
||||
**What Actually Happens:**
|
||||
1. The swarm sets up a coordination framework
|
||||
2. Each agent MUST use Claude Flow hooks for coordination:
|
||||
- `npx claude-flow@alpha hooks pre-task` before starting
|
||||
- `npx claude-flow@alpha hooks post-edit` after each file operation
|
||||
- `npx claude-flow@alpha hooks notification` to share decisions
|
||||
3. Claude Code uses its native Read, WebSearch, and Task tools
|
||||
4. The swarm coordinates through shared memory and hooks
|
||||
5. Results are synthesized by Claude Code with full coordination history
|
||||
|
||||
### Development Coordination Example
|
||||
**Context:** Claude Code needs to build a complex system with multiple components
|
||||
|
||||
**Step 1:** Set up development coordination
|
||||
- Tool: `mcp__claude-flow__swarm_init`
|
||||
- Parameters: `{"topology": "hierarchical", "maxAgents": 8, "strategy": "specialized"}`
|
||||
- Result: Hierarchical structure for organized development
|
||||
|
||||
**Step 2:** Define development perspectives
|
||||
- Tool: `mcp__claude-flow__agent_spawn`
|
||||
- Parameters: `{"type": "architect", "name": "System Design"}`
|
||||
- Result: Architectural thinking pattern for Claude Code
|
||||
|
||||
**Step 3:** Coordinate implementation
|
||||
- Tool: `mcp__claude-flow__task_orchestrate`
|
||||
- Parameters: `{"task": "Implement user authentication with JWT", "strategy": "parallel"}`
|
||||
- Result: Claude Code implements features using its native tools
|
||||
|
||||
**What Actually Happens:**
|
||||
1. The swarm creates a development coordination plan
|
||||
2. Each agent coordinates using mandatory hooks:
|
||||
- Pre-task hooks for context loading
|
||||
- Post-edit hooks for progress tracking
|
||||
- Memory storage for cross-agent coordination
|
||||
3. Claude Code uses Write, Edit, Bash tools for implementation
|
||||
4. Agents share progress through Claude Flow memory
|
||||
5. All code is written by Claude Code with full coordination
|
||||
|
||||
## Best Practices for Coordination
|
||||
|
||||
### ✅ DO:
|
||||
- Use MCP tools to coordinate Claude Code's approach to complex tasks
|
||||
- Let the swarm break down problems into manageable pieces
|
||||
- Use memory tools to maintain context across sessions
|
||||
- Monitor coordination effectiveness with status tools
|
||||
- Train neural patterns for better coordination over time
|
||||
|
||||
### ❌ DON'T:
|
||||
- Expect agents to write code (Claude Code does all implementation)
|
||||
- Use MCP tools for file operations (use Claude Code's native tools)
|
||||
- Try to make agents execute bash commands (Claude Code handles this)
|
||||
- Confuse coordination with execution (MCP coordinates, Claude executes)
|
||||
|
||||
## Memory and Persistence
|
||||
|
||||
The swarm provides persistent memory that helps Claude Code:
|
||||
- Remember project context across sessions
|
||||
- Track decisions and rationale
|
||||
- Maintain consistency in large projects
|
||||
- Learn from previous coordination patterns
|
||||
|
||||
## Performance Benefits
|
||||
|
||||
When using ruv-swarm coordination with Claude Code:
|
||||
- **84.8% SWE-Bench solve rate** - Better problem-solving through coordination
|
||||
- **32.3% token reduction** - Efficient task breakdown reduces redundancy
|
||||
- **2.8-4.4x speed improvement** - Parallel coordination strategies
|
||||
- **27+ neural models** - Diverse cognitive approaches
|
||||
|
||||
## Claude Code Hooks Integration
|
||||
|
||||
ruv-swarm includes powerful hooks that automate coordination:
|
||||
|
||||
### Pre-Operation Hooks
|
||||
- **Auto-assign agents** before file edits based on file type
|
||||
- **Validate commands** before execution for safety
|
||||
- **Prepare resources** automatically for complex operations
|
||||
- **Optimize topology** based on task complexity analysis
|
||||
- **Cache searches** for improved performance
|
||||
|
||||
### Post-Operation Hooks
|
||||
- **Auto-format code** using language-specific formatters
|
||||
- **Train neural patterns** from successful operations
|
||||
- **Update memory** with operation context
|
||||
- **Analyze performance** and identify bottlenecks
|
||||
- **Track token usage** for efficiency metrics
|
||||
|
||||
### Session Management
|
||||
- **Generate summaries** at session end
|
||||
- **Persist state** across Claude Code sessions
|
||||
- **Track metrics** for continuous improvement
|
||||
- **Restore previous** session context automatically
|
||||
|
||||
### Advanced Features (New!)
|
||||
- **🚀 Automatic Topology Selection** - Optimal swarm structure for each task
|
||||
- **⚡ Parallel Execution** - 2.8-4.4x speed improvements
|
||||
- **🧠 Neural Training** - Continuous learning from operations
|
||||
- **📊 Bottleneck Analysis** - Real-time performance optimization
|
||||
- **🤖 Smart Auto-Spawning** - Zero manual agent management
|
||||
- **🛡️ Self-Healing Workflows** - Automatic error recovery
|
||||
- **💾 Cross-Session Memory** - Persistent learning & context
|
||||
|
||||
### Configuration
|
||||
Hooks are pre-configured in `.claude/settings.json`. Key features:
|
||||
- Automatic agent assignment for different file types
|
||||
- Code formatting on save
|
||||
- Neural pattern learning from edits
|
||||
- Session state persistence
|
||||
- Performance tracking and optimization
|
||||
- Intelligent caching and token reduction
|
||||
|
||||
See `.claude/commands/` for detailed documentation on all features.
|
||||
|
||||
## Integration Tips
|
||||
|
||||
1. **Start Simple**: Begin with basic swarm init and single agent
|
||||
2. **Scale Gradually**: Add more agents as task complexity increases
|
||||
3. **Use Memory**: Store important decisions and context
|
||||
4. **Monitor Progress**: Regular status checks ensure effective coordination
|
||||
5. **Train Patterns**: Let neural agents learn from successful coordinations
|
||||
6. **Enable Hooks**: Use the pre-configured hooks for automation
|
||||
|
||||
## 🧠 SWARM ORCHESTRATION PATTERN
|
||||
|
||||
### You are the SWARM ORCHESTRATOR. **IMMEDIATELY SPAWN AGENTS IN PARALLEL** to execute tasks
|
||||
|
||||
### 🚨 CRITICAL INSTRUCTION: You are the SWARM ORCHESTRATOR
|
||||
|
||||
**MANDATORY**: When using swarms, you MUST:
|
||||
1. **SPAWN ALL AGENTS IN ONE BATCH** - Use multiple tool calls in a SINGLE message
|
||||
2. **EXECUTE TASKS IN PARALLEL** - Never wait for one task before starting another
|
||||
3. **USE BATCHTOOL FOR EVERYTHING** - Multiple operations = Single message with multiple tools
|
||||
4. **ALL AGENTS MUST USE COORDINATION TOOLS** - Every spawned agent MUST use claude-flow hooks and memory
|
||||
|
||||
### 🎯 AGENT COUNT CONFIGURATION
|
||||
|
||||
**CRITICAL: Dynamic Agent Count Rules**
|
||||
1. **Check CLI Arguments First**: If user runs `npx claude-flow@alpha --agents 5`, use 5 agents
|
||||
2. **Auto-Decide if No Args**: Without CLI args, analyze task complexity:
|
||||
- Simple tasks (1-3 components): 3-4 agents
|
||||
- Medium tasks (4-6 components): 5-7 agents
|
||||
- Complex tasks (7+ components): 8-12 agents
|
||||
3. **Agent Type Distribution**: Balance agent types based on task:
|
||||
- Always include 1 coordinator
|
||||
- For code-heavy tasks: more coders
|
||||
- For design tasks: more architects/analysts
|
||||
- For quality tasks: more testers/reviewers
|
||||
|
||||
**Example Auto-Decision Logic:**
|
||||
```javascript
|
||||
// If CLI args provided: npx claude-flow@alpha --agents 6
|
||||
maxAgents = CLI_ARGS.agents || determineAgentCount(task)
|
||||
|
||||
function determineAgentCount(task) {
|
||||
// Analyze task complexity
|
||||
if (task.includes(['API', 'database', 'auth', 'tests'])) return 8
|
||||
if (task.includes(['frontend', 'backend'])) return 6
|
||||
if (task.includes(['simple', 'script'])) return 3
|
||||
return 5 // default
|
||||
}
|
||||
```
|
||||
|
||||
## 📋 MANDATORY AGENT COORDINATION PROTOCOL
|
||||
|
||||
### 🔴 CRITICAL: Every Agent MUST Follow This Protocol
|
||||
|
||||
When you spawn an agent using the Task tool, that agent MUST:
|
||||
|
||||
**1️⃣ BEFORE Starting Work:**
|
||||
### 2. Pseudocode Phase (Concurrent Logic Design)
|
||||
```bash
|
||||
# Check previous work and load context
|
||||
npx claude-flow@alpha hooks pre-task --description "[agent task]" --auto-spawn-agents false
|
||||
npx claude-flow@alpha hooks session-restore --session-id "swarm-[id]" --load-memory true
|
||||
# Develop algorithmic logic with parallel pattern analysis
|
||||
npx claude-flow sparc run spec-pseudocode "Create authentication flow pseudocode" --batch-optimize
|
||||
```
|
||||
**Batchtools Optimization**: Process multiple algorithm patterns concurrently, validate logic flows in parallel, and optimize data structures simultaneously.
|
||||
|
||||
**2️⃣ DURING Work (After EVERY Major Step):**
|
||||
### 3. Architecture Phase (Parallel Component Design)
|
||||
```bash
|
||||
# Store progress in memory after each file operation
|
||||
npx claude-flow@alpha hooks post-edit --file "[filepath]" --memory-key "swarm/[agent]/[step]"
|
||||
|
||||
# Store decisions and findings
|
||||
npx claude-flow@alpha hooks notification --message "[what was done]" --telemetry true
|
||||
|
||||
# Check coordination with other agents
|
||||
npx claude-flow@alpha hooks pre-search --query "[what to check]" --cache-results true
|
||||
# Design system architecture with concurrent component analysis
|
||||
npx claude-flow sparc run architect "Design authentication service architecture" --parallel
|
||||
```
|
||||
**Batchtools Optimization**: Generate multiple architectural alternatives simultaneously, validate integration points in parallel, and create comprehensive documentation concurrently.
|
||||
|
||||
**3️⃣ AFTER Completing Work:**
|
||||
### 4. Refinement Phase (Parallel TDD Implementation)
|
||||
```bash
|
||||
# Save all results and learnings
|
||||
npx claude-flow@alpha hooks post-task --task-id "[task]" --analyze-performance true
|
||||
npx claude-flow@alpha hooks session-end --export-metrics true --generate-summary true
|
||||
# Execute Test-Driven Development with parallel test generation
|
||||
npx claude-flow sparc tdd "implement user authentication system" --batch-tdd
|
||||
```
|
||||
**Batchtools Optimization**: Generate multiple test scenarios simultaneously, implement and validate code in parallel, and optimize performance concurrently.
|
||||
|
||||
### 🎯 AGENT PROMPT TEMPLATE
|
||||
|
||||
When spawning agents, ALWAYS include these coordination instructions:
|
||||
|
||||
### 5. Completion Phase (Concurrent Integration)
|
||||
```bash
|
||||
# Integration with parallel validation and documentation
|
||||
npx claude-flow sparc run integration "integrate authentication with user management" --parallel
|
||||
```
|
||||
You are the [Agent Type] agent in a coordinated swarm.
|
||||
**Batchtools Optimization**: Run integration tests in parallel, generate documentation concurrently, and validate requirements simultaneously.
|
||||
|
||||
MANDATORY COORDINATION:
|
||||
1. START: Run `npx claude-flow@alpha hooks pre-task --description "[your task]"`
|
||||
2. DURING: After EVERY file operation, run `npx claude-flow@alpha hooks post-edit --file "[file]" --memory-key "agent/[step]"`
|
||||
3. MEMORY: Store ALL decisions using `npx claude-flow@alpha hooks notification --message "[decision]"`
|
||||
4. END: Run `npx claude-flow@alpha hooks post-task --task-id "[task]" --analyze-performance true`
|
||||
## Batchtools Integration Features
|
||||
|
||||
Your specific task: [detailed task description]
|
||||
### Parallel Processing Capabilities
|
||||
- **Concurrent File Operations**: Read, analyze, and modify multiple files simultaneously
|
||||
- **Parallel Code Analysis**: Analyze dependencies, patterns, and architecture concurrently
|
||||
- **Batch Test Generation**: Create comprehensive test suites in parallel
|
||||
- **Concurrent Documentation**: Generate multiple documentation formats simultaneously
|
||||
|
||||
REMEMBER: Coordinate with other agents by checking memory BEFORE making decisions!
|
||||
```
|
||||
### Performance Optimizations
|
||||
- **Smart Batching**: Group related operations for optimal performance
|
||||
- **Pipeline Processing**: Chain dependent operations with parallel stages
|
||||
- **Resource Management**: Efficient utilization of system resources
|
||||
- **Error Resilience**: Robust error handling with parallel recovery
|
||||
|
||||
### ⚡ PARALLEL EXECUTION IS MANDATORY
|
||||
## Performance Benchmarks
|
||||
|
||||
**THIS IS WRONG ❌ (Sequential - NEVER DO THIS):**
|
||||
```
|
||||
Message 1: Initialize swarm
|
||||
Message 2: Spawn agent 1
|
||||
Message 3: Spawn agent 2
|
||||
Message 4: TodoWrite (single todo)
|
||||
Message 5: Create file 1
|
||||
Message 6: TodoWrite (another single todo)
|
||||
```
|
||||
### Batchtools Performance Improvements
|
||||
- **File Operations**: Up to 300% faster with parallel processing
|
||||
- **Code Analysis**: 250% improvement with concurrent pattern recognition
|
||||
- **Test Generation**: 400% faster with parallel test creation
|
||||
- **Documentation**: 200% improvement with concurrent content generation
|
||||
- **Memory Operations**: 180% faster with batched read/write operations
|
||||
|
||||
**THIS IS CORRECT ✅ (Parallel - ALWAYS DO THIS):**
|
||||
```
|
||||
Message 1: [BatchTool]
|
||||
// MCP coordination setup
|
||||
- mcp__claude-flow__swarm_init
|
||||
- mcp__claude-flow__agent_spawn (researcher)
|
||||
- mcp__claude-flow__agent_spawn (coder)
|
||||
- mcp__claude-flow__agent_spawn (analyst)
|
||||
- mcp__claude-flow__agent_spawn (tester)
|
||||
- mcp__claude-flow__agent_spawn (coordinator)
|
||||
## Code Style and Best Practices (Batchtools Enhanced)
|
||||
|
||||
Message 2: [BatchTool - Claude Code execution]
|
||||
// Task agents with full coordination instructions
|
||||
- Task("You are researcher agent. MANDATORY: Run hooks pre-task, post-edit, post-task. Task: Research API patterns")
|
||||
- Task("You are coder agent. MANDATORY: Run hooks pre-task, post-edit, post-task. Task: Implement REST endpoints")
|
||||
- Task("You are analyst agent. MANDATORY: Run hooks pre-task, post-edit, post-task. Task: Analyze performance")
|
||||
- Task("You are tester agent. MANDATORY: Run hooks pre-task, post-edit, post-task. Task: Write comprehensive tests")
|
||||
|
||||
// TodoWrite with ALL todos batched
|
||||
- TodoWrite { todos: [
|
||||
{id: "research", content: "Research API patterns", status: "in_progress", priority: "high"},
|
||||
{id: "design", content: "Design database schema", status: "pending", priority: "high"},
|
||||
{id: "implement", content: "Build REST endpoints", status: "pending", priority: "high"},
|
||||
{id: "test", content: "Write unit tests", status: "pending", priority: "medium"},
|
||||
{id: "docs", content: "Create API documentation", status: "pending", priority: "low"},
|
||||
{id: "deploy", content: "Setup deployment", status: "pending", priority: "medium"}
|
||||
]}
|
||||
|
||||
// File operations in parallel
|
||||
- Write "api/package.json"
|
||||
- Write "api/server.js"
|
||||
- Write "api/routes/users.js"
|
||||
- Bash "mkdir -p api/{routes,models,tests}"
|
||||
```
|
||||
### SPARC Development Principles with Batchtools
|
||||
- **Modular Design**: Keep files under 500 lines, optimize with parallel analysis
|
||||
- **Environment Safety**: Never hardcode secrets, validate with concurrent checks
|
||||
- **Test-First**: Always write tests before implementation using parallel generation
|
||||
- **Clean Architecture**: Separate concerns with concurrent validation
|
||||
- **Parallel Documentation**: Maintain clear, up-to-date documentation with concurrent updates
|
||||
|
||||
### 🎯 MANDATORY SWARM PATTERN
|
||||
### Batchtools Best Practices
|
||||
- **Parallel Operations**: Use batchtools for independent tasks
|
||||
- **Concurrent Validation**: Validate multiple aspects simultaneously
|
||||
- **Batch Processing**: Group similar operations for efficiency
|
||||
- **Pipeline Optimization**: Chain operations with parallel stages
|
||||
- **Resource Management**: Monitor and optimize resource usage
|
||||
|
||||
When given ANY complex task with swarms:
|
||||
## Important Notes (Enhanced)
|
||||
|
||||
```
|
||||
STEP 1: IMMEDIATE PARALLEL SPAWN (Single Message!)
|
||||
[BatchTool]:
|
||||
// IMPORTANT: Check CLI args for agent count, otherwise auto-decide based on task complexity
|
||||
- mcp__claude-flow__swarm_init {
|
||||
topology: "hierarchical",
|
||||
maxAgents: CLI_ARGS.agents || AUTO_DECIDE(task_complexity), // Use CLI args or auto-decide
|
||||
strategy: "parallel"
|
||||
}
|
||||
|
||||
// Spawn agents based on maxAgents count and task requirements
|
||||
// If CLI specifies 3 agents, spawn 3. If no args, auto-decide optimal count (3-12)
|
||||
- mcp__claude-flow__agent_spawn { type: "architect", name: "System Designer" }
|
||||
- mcp__claude-flow__agent_spawn { type: "coder", name: "API Developer" }
|
||||
- mcp__claude-flow__agent_spawn { type: "coder", name: "Frontend Dev" }
|
||||
- mcp__claude-flow__agent_spawn { type: "analyst", name: "DB Designer" }
|
||||
- mcp__claude-flow__agent_spawn { type: "tester", name: "QA Engineer" }
|
||||
- mcp__claude-flow__agent_spawn { type: "researcher", name: "Tech Lead" }
|
||||
- mcp__claude-flow__agent_spawn { type: "coordinator", name: "PM" }
|
||||
- TodoWrite { todos: [multiple todos at once] }
|
||||
- Always run tests before committing with parallel execution (`npm run test --parallel`)
|
||||
- Use SPARC memory system with concurrent operations to maintain context across sessions
|
||||
- Follow the Red-Green-Refactor cycle with parallel test generation during TDD phases
|
||||
- Document architectural decisions with concurrent validation in memory
|
||||
- Regular security reviews with parallel analysis for authentication or data handling code
|
||||
- Claude Code slash commands provide quick access to batchtools-optimized SPARC modes
|
||||
- Monitor system resources during parallel operations for optimal performance
|
||||
|
||||
STEP 2: PARALLEL TASK EXECUTION (Single Message!)
|
||||
[BatchTool]:
|
||||
- mcp__claude-flow__task_orchestrate { task: "main task", strategy: "parallel" }
|
||||
- mcp__claude-flow__memory_usage { action: "store", key: "init", value: {...} }
|
||||
- Multiple Read operations
|
||||
- Multiple Write operations
|
||||
- Multiple Bash commands
|
||||
For more information about SPARC methodology and batchtools optimization, see:
|
||||
- SPARC Guide: https://github.com/ruvnet/claude-code-flow/docs/sparc.md
|
||||
- Batchtools Documentation: https://github.com/ruvnet/claude-code-flow/docs/batchtools.md
|
||||
|
||||
STEP 3: CONTINUE PARALLEL WORK (Never Sequential!)
|
||||
```
|
||||
|
||||
### 📊 VISUAL TASK TRACKING FORMAT
|
||||
|
||||
Use this format when displaying task progress:
|
||||
|
||||
```
|
||||
📊 Progress Overview
|
||||
├── Total Tasks: X
|
||||
├── ✅ Completed: X (X%)
|
||||
├── 🔄 In Progress: X (X%)
|
||||
├── ⭕ Todo: X (X%)
|
||||
└── ❌ Blocked: X (X%)
|
||||
|
||||
📋 Todo (X)
|
||||
└── 🔴 001: [Task description] [PRIORITY] ▶
|
||||
|
||||
🔄 In progress (X)
|
||||
├── 🟡 002: [Task description] ↳ X deps ▶
|
||||
└── 🔴 003: [Task description] [PRIORITY] ▶
|
||||
|
||||
✅ Completed (X)
|
||||
├── ✅ 004: [Task description]
|
||||
└── ... (more completed tasks)
|
||||
|
||||
Priority indicators: 🔴 HIGH/CRITICAL, 🟡 MEDIUM, 🟢 LOW
|
||||
Dependencies: ↳ X deps | Actionable: ▶
|
||||
```
|
||||
|
||||
### 🎯 REAL EXAMPLE: Full-Stack App Development
|
||||
|
||||
**Task**: "Build a complete REST API with authentication, database, and tests"
|
||||
|
||||
**🚨 MANDATORY APPROACH - Everything in Parallel:**
|
||||
|
||||
```javascript
|
||||
// ✅ CORRECT: SINGLE MESSAGE with ALL operations
|
||||
[BatchTool - Message 1]:
|
||||
// Initialize and spawn ALL agents at once
|
||||
mcp__claude-flow__swarm_init { topology: "hierarchical", maxAgents: 8, strategy: "parallel" }
|
||||
mcp__claude-flow__agent_spawn { type: "architect", name: "System Designer" }
|
||||
mcp__claude-flow__agent_spawn { type: "coder", name: "API Developer" }
|
||||
mcp__claude-flow__agent_spawn { type: "coder", name: "Auth Expert" }
|
||||
mcp__claude-flow__agent_spawn { type: "analyst", name: "DB Designer" }
|
||||
mcp__claude-flow__agent_spawn { type: "tester", name: "Test Engineer" }
|
||||
mcp__claude-flow__agent_spawn { type: "coordinator", name: "Lead" }
|
||||
|
||||
// Update ALL todos at once - NEVER split todos!
|
||||
TodoWrite { todos: [
|
||||
{ id: "design", content: "Design API architecture", status: "in_progress", priority: "high" },
|
||||
{ id: "auth", content: "Implement authentication", status: "pending", priority: "high" },
|
||||
{ id: "db", content: "Design database schema", status: "pending", priority: "high" },
|
||||
{ id: "api", content: "Build REST endpoints", status: "pending", priority: "high" },
|
||||
{ id: "tests", content: "Write comprehensive tests", status: "pending", priority: "medium" },
|
||||
{ id: "docs", content: "Document API endpoints", status: "pending", priority: "low" },
|
||||
{ id: "deploy", content: "Setup deployment pipeline", status: "pending", priority: "medium" },
|
||||
{ id: "monitor", content: "Add monitoring", status: "pending", priority: "medium" }
|
||||
]}
|
||||
|
||||
// Start orchestration
|
||||
mcp__claude-flow__task_orchestrate { task: "Build REST API", strategy: "parallel" }
|
||||
|
||||
// Store initial memory
|
||||
mcp__claude-flow__memory_usage { action: "store", key: "project/init", value: { started: Date.now() } }
|
||||
|
||||
[BatchTool - Message 2]:
|
||||
// Create ALL directories at once
|
||||
Bash("mkdir -p test-app/{src,tests,docs,config}")
|
||||
Bash("mkdir -p test-app/src/{models,routes,middleware,services}")
|
||||
Bash("mkdir -p test-app/tests/{unit,integration}")
|
||||
|
||||
// Write ALL base files at once
|
||||
Write("test-app/package.json", packageJsonContent)
|
||||
Write("test-app/.env.example", envContent)
|
||||
Write("test-app/README.md", readmeContent)
|
||||
Write("test-app/src/server.js", serverContent)
|
||||
Write("test-app/src/config/database.js", dbConfigContent)
|
||||
|
||||
[BatchTool - Message 3]:
|
||||
// Read multiple files for context
|
||||
Read("test-app/package.json")
|
||||
Read("test-app/src/server.js")
|
||||
Read("test-app/.env.example")
|
||||
|
||||
// Run multiple commands
|
||||
Bash("cd test-app && npm install")
|
||||
Bash("cd test-app && npm run lint")
|
||||
Bash("cd test-app && npm test")
|
||||
```
|
||||
|
||||
### 🚫 NEVER DO THIS (Sequential = WRONG):
|
||||
```javascript
|
||||
// ❌ WRONG: Multiple messages, one operation each
|
||||
Message 1: mcp__claude-flow__swarm_init
|
||||
Message 2: mcp__claude-flow__agent_spawn (just one agent)
|
||||
Message 3: mcp__claude-flow__agent_spawn (another agent)
|
||||
Message 4: TodoWrite (single todo)
|
||||
Message 5: Write (single file)
|
||||
// This is 5x slower and wastes swarm coordination!
|
||||
```
|
||||
|
||||
### 🔄 MEMORY COORDINATION PATTERN
|
||||
|
||||
Every agent coordination step MUST use memory:
|
||||
|
||||
```
|
||||
// After each major decision or implementation
|
||||
mcp__claude-flow__memory_usage
|
||||
action: "store"
|
||||
key: "swarm-{id}/agent-{name}/{step}"
|
||||
value: {
|
||||
timestamp: Date.now(),
|
||||
decision: "what was decided",
|
||||
implementation: "what was built",
|
||||
nextSteps: ["step1", "step2"],
|
||||
dependencies: ["dep1", "dep2"]
|
||||
}
|
||||
|
||||
// To retrieve coordination data
|
||||
mcp__claude-flow__memory_usage
|
||||
action: "retrieve"
|
||||
key: "swarm-{id}/agent-{name}/{step}"
|
||||
|
||||
// To check all swarm progress
|
||||
mcp__claude-flow__memory_usage
|
||||
action: "list"
|
||||
pattern: "swarm-{id}/*"
|
||||
```
|
||||
|
||||
### ⚡ PERFORMANCE TIPS
|
||||
|
||||
1. **Batch Everything**: Never operate on single files when multiple are needed
|
||||
2. **Parallel First**: Always think "what can run simultaneously?"
|
||||
3. **Memory is Key**: Use memory for ALL cross-agent coordination
|
||||
4. **Monitor Progress**: Use mcp__claude-flow__swarm_monitor for real-time tracking
|
||||
5. **Auto-Optimize**: Let hooks handle topology and agent selection
|
||||
|
||||
### 🎨 VISUAL SWARM STATUS
|
||||
|
||||
When showing swarm status, use this format:
|
||||
|
||||
```
|
||||
🐝 Swarm Status: ACTIVE
|
||||
├── 🏗️ Topology: hierarchical
|
||||
├── 👥 Agents: 6/8 active
|
||||
├── ⚡ Mode: parallel execution
|
||||
├── 📊 Tasks: 12 total (4 complete, 6 in-progress, 2 pending)
|
||||
└── 🧠 Memory: 15 coordination points stored
|
||||
|
||||
Agent Activity:
|
||||
├── 🟢 architect: Designing database schema...
|
||||
├── 🟢 coder-1: Implementing auth endpoints...
|
||||
├── 🟢 coder-2: Building user CRUD operations...
|
||||
├── 🟢 analyst: Optimizing query performance...
|
||||
├── 🟡 tester: Waiting for auth completion...
|
||||
└── 🟢 coordinator: Monitoring progress...
|
||||
```
|
||||
|
||||
## 📝 CRITICAL: TODOWRITE AND TASK TOOL BATCHING
|
||||
|
||||
### 🚨 MANDATORY BATCHING RULES FOR TODOS AND TASKS
|
||||
|
||||
**TodoWrite Tool Requirements:**
|
||||
1. **ALWAYS** include 5-10+ todos in a SINGLE TodoWrite call
|
||||
2. **NEVER** call TodoWrite multiple times in sequence
|
||||
3. **BATCH** all todo updates together - status changes, new todos, completions
|
||||
4. **INCLUDE** all priority levels (high, medium, low) in one call
|
||||
|
||||
**Task Tool Requirements:**
|
||||
1. **SPAWN** all agents using Task tool in ONE message
|
||||
2. **NEVER** spawn agents one by one across multiple messages
|
||||
3. **INCLUDE** full task descriptions and coordination instructions
|
||||
4. **BATCH** related Task calls together for parallel execution
|
||||
|
||||
**Example of CORRECT TodoWrite usage:**
|
||||
```javascript
|
||||
// ✅ CORRECT - All todos in ONE call
|
||||
TodoWrite { todos: [
|
||||
{ id: "1", content: "Initialize system", status: "completed", priority: "high" },
|
||||
{ id: "2", content: "Analyze requirements", status: "in_progress", priority: "high" },
|
||||
{ id: "3", content: "Design architecture", status: "pending", priority: "high" },
|
||||
{ id: "4", content: "Implement core", status: "pending", priority: "high" },
|
||||
{ id: "5", content: "Build features", status: "pending", priority: "medium" },
|
||||
{ id: "6", content: "Write tests", status: "pending", priority: "medium" },
|
||||
{ id: "7", content: "Add monitoring", status: "pending", priority: "medium" },
|
||||
{ id: "8", content: "Documentation", status: "pending", priority: "low" },
|
||||
{ id: "9", content: "Performance tuning", status: "pending", priority: "low" },
|
||||
{ id: "10", content: "Deploy to production", status: "pending", priority: "high" }
|
||||
]}
|
||||
```
|
||||
|
||||
**Example of WRONG TodoWrite usage:**
|
||||
```javascript
|
||||
// ❌ WRONG - Multiple TodoWrite calls
|
||||
Message 1: TodoWrite { todos: [{ id: "1", content: "Task 1", ... }] }
|
||||
Message 2: TodoWrite { todos: [{ id: "2", content: "Task 2", ... }] }
|
||||
Message 3: TodoWrite { todos: [{ id: "3", content: "Task 3", ... }] }
|
||||
// This breaks parallel coordination!
|
||||
```
|
||||
|
||||
## Support
|
||||
|
||||
- Documentation: https://github.com/ruvnet/claude-flow
|
||||
- Issues: https://github.com/ruvnet/claude-flow/issues
|
||||
- Examples: https://github.com/ruvnet/claude-flow/tree/main/examples
|
||||
|
||||
---
|
||||
|
||||
Remember: **Claude Flow coordinates, Claude Code creates!** Start with `mcp__claude-flow__swarm_init` to enhance your development workflow.
|
||||
|
||||
don't save md or tests in root folder.
|
||||
# important-instruction-reminders
|
||||
Do what has been asked; nothing more, nothing less.
|
||||
NEVER create files unless they're absolutely necessary for achieving your goal.
|
||||
ALWAYS prefer editing an existing file to creating a new one.
|
||||
NEVER proactively create documentation files (*.md) or README files. Only create documentation files if explicitly requested by the User.
|
||||
@@ -0,0 +1,9 @@
|
||||
# Analysis Commands
|
||||
|
||||
Commands for analysis operations in Claude Flow.
|
||||
|
||||
## Available Commands
|
||||
|
||||
- [bottleneck-detect](./bottleneck-detect.md)
|
||||
- [token-usage](./token-usage.md)
|
||||
- [performance-report](./performance-report.md)
|
||||
@@ -0,0 +1,150 @@
|
||||
# bottleneck detect
|
||||
|
||||
Analyze performance bottlenecks in swarm operations and suggest optimizations.
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
npx claude-flow bottleneck detect [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
|
||||
- `--swarm-id, -s <id>` - Analyze specific swarm (default: current)
|
||||
- `--time-range, -t <range>` - Analysis period: 1h, 24h, 7d, all (default: 1h)
|
||||
- `--threshold <percent>` - Bottleneck threshold percentage (default: 20)
|
||||
- `--export, -e <file>` - Export analysis to file
|
||||
- `--fix` - Apply automatic optimizations
|
||||
|
||||
## Examples
|
||||
|
||||
### Basic bottleneck detection
|
||||
```bash
|
||||
npx claude-flow bottleneck detect
|
||||
```
|
||||
|
||||
### Analyze specific swarm
|
||||
```bash
|
||||
npx claude-flow bottleneck detect --swarm-id swarm-123
|
||||
```
|
||||
|
||||
### Last 24 hours with export
|
||||
```bash
|
||||
npx claude-flow bottleneck detect -t 24h -e bottlenecks.json
|
||||
```
|
||||
|
||||
### Auto-fix detected issues
|
||||
```bash
|
||||
npx claude-flow bottleneck detect --fix --threshold 15
|
||||
```
|
||||
|
||||
## Metrics Analyzed
|
||||
|
||||
### Communication Bottlenecks
|
||||
- Message queue delays
|
||||
- Agent response times
|
||||
- Coordination overhead
|
||||
- Memory access patterns
|
||||
|
||||
### Processing Bottlenecks
|
||||
- Task completion times
|
||||
- Agent utilization rates
|
||||
- Parallel execution efficiency
|
||||
- Resource contention
|
||||
|
||||
### Memory Bottlenecks
|
||||
- Cache hit rates
|
||||
- Memory access patterns
|
||||
- Storage I/O performance
|
||||
- Neural pattern loading
|
||||
|
||||
### Network Bottlenecks
|
||||
- API call latency
|
||||
- MCP communication delays
|
||||
- External service timeouts
|
||||
- Concurrent request limits
|
||||
|
||||
## Output Format
|
||||
|
||||
```
|
||||
🔍 Bottleneck Analysis Report
|
||||
━━━━━━━━━━━━━━━━━━━━━━━━━━━
|
||||
|
||||
📊 Summary
|
||||
├── Time Range: Last 1 hour
|
||||
├── Agents Analyzed: 6
|
||||
├── Tasks Processed: 42
|
||||
└── Critical Issues: 2
|
||||
|
||||
🚨 Critical Bottlenecks
|
||||
1. Agent Communication (35% impact)
|
||||
└── coordinator → coder-1 messages delayed by 2.3s avg
|
||||
|
||||
2. Memory Access (28% impact)
|
||||
└── Neural pattern loading taking 1.8s per access
|
||||
|
||||
⚠️ Warning Bottlenecks
|
||||
1. Task Queue (18% impact)
|
||||
└── 5 tasks waiting > 10s for assignment
|
||||
|
||||
💡 Recommendations
|
||||
1. Switch to hierarchical topology (est. 40% improvement)
|
||||
2. Enable memory caching (est. 25% improvement)
|
||||
3. Increase agent concurrency to 8 (est. 20% improvement)
|
||||
|
||||
✅ Quick Fixes Available
|
||||
Run with --fix to apply:
|
||||
- Enable smart caching
|
||||
- Optimize message routing
|
||||
- Adjust agent priorities
|
||||
```
|
||||
|
||||
## Automatic Fixes
|
||||
|
||||
When using `--fix`, the following optimizations may be applied:
|
||||
|
||||
1. **Topology Optimization**
|
||||
- Switch to more efficient topology
|
||||
- Adjust communication patterns
|
||||
- Reduce coordination overhead
|
||||
|
||||
2. **Caching Enhancement**
|
||||
- Enable memory caching
|
||||
- Optimize cache strategies
|
||||
- Preload common patterns
|
||||
|
||||
3. **Concurrency Tuning**
|
||||
- Adjust agent counts
|
||||
- Optimize parallel execution
|
||||
- Balance workload distribution
|
||||
|
||||
4. **Priority Adjustment**
|
||||
- Reorder task queues
|
||||
- Prioritize critical paths
|
||||
- Reduce wait times
|
||||
|
||||
## Performance Impact
|
||||
|
||||
Typical improvements after bottleneck resolution:
|
||||
- **Communication**: 30-50% faster message delivery
|
||||
- **Processing**: 20-40% reduced task completion time
|
||||
- **Memory**: 40-60% fewer cache misses
|
||||
- **Overall**: 25-45% performance improvement
|
||||
|
||||
## Integration with Claude Code
|
||||
|
||||
```javascript
|
||||
// Check for bottlenecks in Claude Code
|
||||
mcp__claude-flow__bottleneck_detect {
|
||||
timeRange: "1h",
|
||||
threshold: 20,
|
||||
autoFix: false
|
||||
}
|
||||
```
|
||||
|
||||
## See Also
|
||||
|
||||
- `performance report` - Detailed performance analysis
|
||||
- `token usage` - Token optimization analysis
|
||||
- `swarm monitor` - Real-time monitoring
|
||||
- `cache manage` - Cache optimization
|
||||
@@ -0,0 +1,25 @@
|
||||
# performance-report
|
||||
|
||||
Generate comprehensive performance reports for swarm operations.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow analysis performance-report [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--format <type>` - Report format (json, html, markdown)
|
||||
- `--include-metrics` - Include detailed metrics
|
||||
- `--compare <id>` - Compare with previous swarm
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Generate HTML report
|
||||
npx claude-flow analysis performance-report --format html
|
||||
|
||||
# Compare swarms
|
||||
npx claude-flow analysis performance-report --compare swarm-123
|
||||
|
||||
# Full metrics report
|
||||
npx claude-flow analysis performance-report --include-metrics --format markdown
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# token-usage
|
||||
|
||||
Analyze token usage patterns and optimize for efficiency.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow analysis token-usage [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--period <time>` - Analysis period (1h, 24h, 7d, 30d)
|
||||
- `--by-agent` - Break down by agent
|
||||
- `--by-operation` - Break down by operation type
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Last 24 hours token usage
|
||||
npx claude-flow analysis token-usage --period 24h
|
||||
|
||||
# By agent breakdown
|
||||
npx claude-flow analysis token-usage --by-agent
|
||||
|
||||
# Export detailed report
|
||||
npx claude-flow analysis token-usage --period 7d --export tokens.csv
|
||||
```
|
||||
@@ -0,0 +1,9 @@
|
||||
# Automation Commands
|
||||
|
||||
Commands for automation operations in Claude Flow.
|
||||
|
||||
## Available Commands
|
||||
|
||||
- [auto-agent](./auto-agent.md)
|
||||
- [smart-spawn](./smart-spawn.md)
|
||||
- [workflow-select](./workflow-select.md)
|
||||
@@ -0,0 +1,112 @@
|
||||
# auto agent
|
||||
|
||||
Automatically spawn and manage agents based on task requirements.
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
npx claude-flow auto agent [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
|
||||
- `--task, -t <description>` - Task description for agent analysis
|
||||
- `--max-agents, -m <number>` - Maximum agents to spawn (default: auto)
|
||||
- `--min-agents <number>` - Minimum agents required (default: 1)
|
||||
- `--strategy, -s <type>` - Selection strategy: optimal, minimal, balanced
|
||||
- `--no-spawn` - Analyze only, don't spawn agents
|
||||
|
||||
## Examples
|
||||
|
||||
### Basic auto-spawning
|
||||
```bash
|
||||
npx claude-flow auto agent --task "Build a REST API with authentication"
|
||||
```
|
||||
|
||||
### Constrained spawning
|
||||
```bash
|
||||
npx claude-flow auto agent -t "Debug performance issue" --max-agents 3
|
||||
```
|
||||
|
||||
### Analysis only
|
||||
```bash
|
||||
npx claude-flow auto agent -t "Refactor codebase" --no-spawn
|
||||
```
|
||||
|
||||
### Minimal strategy
|
||||
```bash
|
||||
npx claude-flow auto agent -t "Fix bug in login" -s minimal
|
||||
```
|
||||
|
||||
## How It Works
|
||||
|
||||
1. **Task Analysis**
|
||||
- Parses task description
|
||||
- Identifies required skills
|
||||
- Estimates complexity
|
||||
- Determines parallelization opportunities
|
||||
|
||||
2. **Agent Selection**
|
||||
- Matches skills to agent types
|
||||
- Considers task dependencies
|
||||
- Optimizes for efficiency
|
||||
- Respects constraints
|
||||
|
||||
3. **Topology Selection**
|
||||
- Chooses optimal swarm structure
|
||||
- Configures communication patterns
|
||||
- Sets up coordination rules
|
||||
- Enables monitoring
|
||||
|
||||
4. **Automatic Spawning**
|
||||
- Creates selected agents
|
||||
- Assigns specific roles
|
||||
- Distributes subtasks
|
||||
- Initiates coordination
|
||||
|
||||
## Agent Types Selected
|
||||
|
||||
- **Architect**: System design, architecture decisions
|
||||
- **Coder**: Implementation, code generation
|
||||
- **Tester**: Test creation, quality assurance
|
||||
- **Analyst**: Performance, optimization
|
||||
- **Researcher**: Documentation, best practices
|
||||
- **Coordinator**: Task management, progress tracking
|
||||
|
||||
## Strategies
|
||||
|
||||
### Optimal
|
||||
- Maximum efficiency
|
||||
- May spawn more agents
|
||||
- Best for complex tasks
|
||||
- Highest resource usage
|
||||
|
||||
### Minimal
|
||||
- Minimum viable agents
|
||||
- Conservative approach
|
||||
- Good for simple tasks
|
||||
- Lowest resource usage
|
||||
|
||||
### Balanced
|
||||
- Middle ground
|
||||
- Adaptive to complexity
|
||||
- Default strategy
|
||||
- Good performance/resource ratio
|
||||
|
||||
## Integration with Claude Code
|
||||
|
||||
```javascript
|
||||
// In Claude Code after auto-spawning
|
||||
mcp__claude-flow__auto_agent {
|
||||
task: "Build authentication system",
|
||||
strategy: "balanced",
|
||||
maxAgents: 6
|
||||
}
|
||||
```
|
||||
|
||||
## See Also
|
||||
|
||||
- `agent spawn` - Manual agent creation
|
||||
- `swarm init` - Initialize swarm manually
|
||||
- `smart spawn` - Intelligent agent spawning
|
||||
- `workflow select` - Choose predefined workflows
|
||||
@@ -0,0 +1,25 @@
|
||||
# smart-spawn
|
||||
|
||||
Intelligently spawn agents based on workload analysis.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow automation smart-spawn [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--analyze` - Analyze before spawning
|
||||
- `--threshold <n>` - Spawn threshold
|
||||
- `--topology <type>` - Preferred topology
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Smart spawn with analysis
|
||||
npx claude-flow automation smart-spawn --analyze
|
||||
|
||||
# Set spawn threshold
|
||||
npx claude-flow automation smart-spawn --threshold 5
|
||||
|
||||
# Force topology
|
||||
npx claude-flow automation smart-spawn --topology hierarchical
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# workflow-select
|
||||
|
||||
Automatically select optimal workflow based on task type.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow automation workflow-select [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--task <description>` - Task description
|
||||
- `--constraints <list>` - Workflow constraints
|
||||
- `--preview` - Preview without executing
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Select workflow for task
|
||||
npx claude-flow automation workflow-select --task "Deploy to production"
|
||||
|
||||
# With constraints
|
||||
npx claude-flow automation workflow-select --constraints "no-downtime,rollback"
|
||||
|
||||
# Preview mode
|
||||
npx claude-flow automation workflow-select --task "Database migration" --preview
|
||||
```
|
||||
@@ -0,0 +1,9 @@
|
||||
# Coordination Commands
|
||||
|
||||
Commands for coordination operations in Claude Flow.
|
||||
|
||||
## Available Commands
|
||||
|
||||
- [swarm-init](./swarm-init.md)
|
||||
- [agent-spawn](./agent-spawn.md)
|
||||
- [task-orchestrate](./task-orchestrate.md)
|
||||
@@ -0,0 +1,25 @@
|
||||
# agent-spawn
|
||||
|
||||
Spawn a new agent in the current swarm.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow agent spawn [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--type <type>` - Agent type (coder, researcher, analyst, tester, coordinator)
|
||||
- `--name <name>` - Custom agent name
|
||||
- `--skills <list>` - Specific skills (comma-separated)
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Spawn coder agent
|
||||
npx claude-flow agent spawn --type coder
|
||||
|
||||
# With custom name
|
||||
npx claude-flow agent spawn --type researcher --name "API Expert"
|
||||
|
||||
# With specific skills
|
||||
npx claude-flow agent spawn --type coder --skills "python,fastapi,testing"
|
||||
```
|
||||
@@ -0,0 +1,76 @@
|
||||
# swarm init
|
||||
|
||||
Initialize a Claude Flow swarm with specified topology and configuration.
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
npx claude-flow swarm init [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
|
||||
- `--topology, -t <type>` - Swarm topology: mesh, hierarchical, ring, star (default: hierarchical)
|
||||
- `--max-agents, -m <number>` - Maximum number of agents (default: 8)
|
||||
- `--strategy, -s <type>` - Execution strategy: balanced, parallel, sequential (default: parallel)
|
||||
- `--auto-spawn` - Automatically spawn agents based on task complexity
|
||||
- `--memory` - Enable cross-session memory persistence
|
||||
- `--github` - Enable GitHub integration features
|
||||
|
||||
## Examples
|
||||
|
||||
### Basic initialization
|
||||
```bash
|
||||
npx claude-flow swarm init
|
||||
```
|
||||
|
||||
### Mesh topology for research
|
||||
```bash
|
||||
npx claude-flow swarm init --topology mesh --max-agents 5 --strategy balanced
|
||||
```
|
||||
|
||||
### Hierarchical for development
|
||||
```bash
|
||||
npx claude-flow swarm init --topology hierarchical --max-agents 10 --strategy parallel --auto-spawn
|
||||
```
|
||||
|
||||
### GitHub-focused swarm
|
||||
```bash
|
||||
npx claude-flow swarm init --topology star --github --memory
|
||||
```
|
||||
|
||||
## Topologies
|
||||
|
||||
### Mesh
|
||||
- All agents connect to all others
|
||||
- Best for: Research, exploration, brainstorming
|
||||
- Communication: High overhead, maximum information sharing
|
||||
|
||||
### Hierarchical
|
||||
- Tree structure with clear command chain
|
||||
- Best for: Development, structured tasks, large projects
|
||||
- Communication: Efficient, clear responsibilities
|
||||
|
||||
### Ring
|
||||
- Agents connect in a circle
|
||||
- Best for: Pipeline processing, sequential workflows
|
||||
- Communication: Low overhead, ordered processing
|
||||
|
||||
### Star
|
||||
- Central coordinator with satellite agents
|
||||
- Best for: Simple tasks, centralized control
|
||||
- Communication: Minimal overhead, clear coordination
|
||||
|
||||
## Integration with Claude Code
|
||||
|
||||
Once initialized, use MCP tools in Claude Code:
|
||||
```javascript
|
||||
mcp__claude-flow__swarm_init { topology: "hierarchical", maxAgents: 8 }
|
||||
```
|
||||
|
||||
## See Also
|
||||
|
||||
- `agent spawn` - Create swarm agents
|
||||
- `task orchestrate` - Coordinate task execution
|
||||
- `swarm status` - Check swarm state
|
||||
- `swarm monitor` - Real-time monitoring
|
||||
@@ -0,0 +1,25 @@
|
||||
# task-orchestrate
|
||||
|
||||
Orchestrate complex tasks across the swarm.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow task orchestrate [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--task <description>` - Task description
|
||||
- `--strategy <type>` - Orchestration strategy
|
||||
- `--priority <level>` - Task priority (low, medium, high, critical)
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Orchestrate development task
|
||||
npx claude-flow task orchestrate --task "Implement user authentication"
|
||||
|
||||
# High priority task
|
||||
npx claude-flow task orchestrate --task "Fix production bug" --priority critical
|
||||
|
||||
# With specific strategy
|
||||
npx claude-flow task orchestrate --task "Refactor codebase" --strategy parallel
|
||||
```
|
||||
@@ -0,0 +1,11 @@
|
||||
# Github Commands
|
||||
|
||||
Commands for github operations in Claude Flow.
|
||||
|
||||
## Available Commands
|
||||
|
||||
- [github-swarm](./github-swarm.md)
|
||||
- [repo-analyze](./repo-analyze.md)
|
||||
- [pr-enhance](./pr-enhance.md)
|
||||
- [issue-triage](./issue-triage.md)
|
||||
- [code-review](./code-review.md)
|
||||
@@ -0,0 +1,25 @@
|
||||
# code-review
|
||||
|
||||
Automated code review with swarm intelligence.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow github code-review [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--pr-number <n>` - Pull request to review
|
||||
- `--focus <areas>` - Review focus (security, performance, style)
|
||||
- `--suggest-fixes` - Suggest code fixes
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Review PR
|
||||
npx claude-flow github code-review --pr-number 456
|
||||
|
||||
# Security focus
|
||||
npx claude-flow github code-review --pr-number 456 --focus security
|
||||
|
||||
# With fix suggestions
|
||||
npx claude-flow github code-review --pr-number 456 --suggest-fixes
|
||||
```
|
||||
@@ -0,0 +1,108 @@
|
||||
# github swarm
|
||||
|
||||
Create a specialized swarm for GitHub repository management.
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
npx claude-flow github swarm [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
|
||||
- `--repository, -r <owner/repo>` - Target GitHub repository
|
||||
- `--agents, -a <number>` - Number of specialized agents (default: 5)
|
||||
- `--focus, -f <type>` - Focus area: maintenance, development, review, triage
|
||||
- `--auto-pr` - Enable automatic pull request enhancements
|
||||
- `--issue-labels` - Auto-categorize and label issues
|
||||
- `--code-review` - Enable AI-powered code reviews
|
||||
|
||||
## Examples
|
||||
|
||||
### Basic GitHub swarm
|
||||
```bash
|
||||
npx claude-flow github swarm --repository owner/repo
|
||||
```
|
||||
|
||||
### Maintenance-focused swarm
|
||||
```bash
|
||||
npx claude-flow github swarm -r owner/repo -f maintenance --issue-labels
|
||||
```
|
||||
|
||||
### Development swarm with PR automation
|
||||
```bash
|
||||
npx claude-flow github swarm -r owner/repo -f development --auto-pr --code-review
|
||||
```
|
||||
|
||||
### Full-featured triage swarm
|
||||
```bash
|
||||
npx claude-flow github swarm -r owner/repo -a 8 -f triage --issue-labels --auto-pr
|
||||
```
|
||||
|
||||
## Agent Types
|
||||
|
||||
### Issue Triager
|
||||
- Analyzes and categorizes issues
|
||||
- Suggests labels and priorities
|
||||
- Identifies duplicates and related issues
|
||||
|
||||
### PR Reviewer
|
||||
- Reviews code changes
|
||||
- Suggests improvements
|
||||
- Checks for best practices
|
||||
|
||||
### Documentation Agent
|
||||
- Updates README files
|
||||
- Creates API documentation
|
||||
- Maintains changelog
|
||||
|
||||
### Test Agent
|
||||
- Identifies missing tests
|
||||
- Suggests test cases
|
||||
- Validates test coverage
|
||||
|
||||
### Security Agent
|
||||
- Scans for vulnerabilities
|
||||
- Reviews dependencies
|
||||
- Suggests security improvements
|
||||
|
||||
## Workflows
|
||||
|
||||
### Issue Triage Workflow
|
||||
1. Scan all open issues
|
||||
2. Categorize by type and priority
|
||||
3. Apply appropriate labels
|
||||
4. Suggest assignees
|
||||
5. Link related issues
|
||||
|
||||
### PR Enhancement Workflow
|
||||
1. Analyze PR changes
|
||||
2. Suggest missing tests
|
||||
3. Improve documentation
|
||||
4. Format code consistently
|
||||
5. Add helpful comments
|
||||
|
||||
### Repository Health Check
|
||||
1. Analyze code quality metrics
|
||||
2. Review dependency status
|
||||
3. Check test coverage
|
||||
4. Assess documentation completeness
|
||||
5. Generate health report
|
||||
|
||||
## Integration with Claude Code
|
||||
|
||||
Use in Claude Code with MCP tools:
|
||||
```javascript
|
||||
mcp__claude-flow__github_swarm {
|
||||
repository: "owner/repo",
|
||||
agents: 6,
|
||||
focus: "maintenance"
|
||||
}
|
||||
```
|
||||
|
||||
## See Also
|
||||
|
||||
- `repo analyze` - Deep repository analysis
|
||||
- `pr enhance` - Enhance pull requests
|
||||
- `issue triage` - Intelligent issue management
|
||||
- `code review` - Automated reviews
|
||||
@@ -0,0 +1,25 @@
|
||||
# issue-triage
|
||||
|
||||
Intelligent issue classification and triage.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow github issue-triage [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--repository <owner/repo>` - Target repository
|
||||
- `--auto-label` - Automatically apply labels
|
||||
- `--assign` - Auto-assign to team members
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Triage issues
|
||||
npx claude-flow github issue-triage --repository myorg/myrepo
|
||||
|
||||
# With auto-labeling
|
||||
npx claude-flow github issue-triage --repository myorg/myrepo --auto-label
|
||||
|
||||
# Full automation
|
||||
npx claude-flow github issue-triage --repository myorg/myrepo --auto-label --assign
|
||||
```
|
||||
@@ -0,0 +1,26 @@
|
||||
# pr-enhance
|
||||
|
||||
AI-powered pull request enhancements.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow github pr-enhance [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--pr-number <n>` - Pull request number
|
||||
- `--add-tests` - Add missing tests
|
||||
- `--improve-docs` - Improve documentation
|
||||
- `--check-security` - Security review
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Enhance PR
|
||||
npx claude-flow github pr-enhance --pr-number 123
|
||||
|
||||
# Add tests
|
||||
npx claude-flow github pr-enhance --pr-number 123 --add-tests
|
||||
|
||||
# Full enhancement
|
||||
npx claude-flow github pr-enhance --pr-number 123 --add-tests --improve-docs
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# repo-analyze
|
||||
|
||||
Deep analysis of GitHub repository with AI insights.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow github repo-analyze [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--repository <owner/repo>` - Repository to analyze
|
||||
- `--deep` - Enable deep analysis
|
||||
- `--include <areas>` - Include specific areas (issues, prs, code, commits)
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Basic analysis
|
||||
npx claude-flow github repo-analyze --repository myorg/myrepo
|
||||
|
||||
# Deep analysis
|
||||
npx claude-flow github repo-analyze --repository myorg/myrepo --deep
|
||||
|
||||
# Specific areas
|
||||
npx claude-flow github repo-analyze --repository myorg/myrepo --include issues,prs
|
||||
```
|
||||
@@ -0,0 +1,11 @@
|
||||
# Hooks Commands
|
||||
|
||||
Commands for hooks operations in Claude Flow.
|
||||
|
||||
## Available Commands
|
||||
|
||||
- [pre-task](./pre-task.md)
|
||||
- [post-task](./post-task.md)
|
||||
- [pre-edit](./pre-edit.md)
|
||||
- [post-edit](./post-edit.md)
|
||||
- [session-end](./session-end.md)
|
||||
@@ -0,0 +1,106 @@
|
||||
# hook post-edit
|
||||
|
||||
Execute post-edit processing including formatting, validation, and memory updates.
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
npx claude-flow hook post-edit [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
|
||||
- `--file, -f <path>` - File path that was edited
|
||||
- `--auto-format` - Automatically format code (default: true)
|
||||
- `--memory-key, -m <key>` - Store edit context in memory
|
||||
- `--train-patterns` - Train neural patterns from edit
|
||||
- `--validate-output` - Validate edited file
|
||||
|
||||
## Examples
|
||||
|
||||
### Basic post-edit hook
|
||||
```bash
|
||||
npx claude-flow hook post-edit --file "src/components/Button.jsx"
|
||||
```
|
||||
|
||||
### With memory storage
|
||||
```bash
|
||||
npx claude-flow hook post-edit -f "api/auth.js" --memory-key "auth/login-implementation"
|
||||
```
|
||||
|
||||
### Format and validate
|
||||
```bash
|
||||
npx claude-flow hook post-edit -f "config/webpack.js" --auto-format --validate-output
|
||||
```
|
||||
|
||||
### Neural training
|
||||
```bash
|
||||
npx claude-flow hook post-edit -f "utils/helpers.ts" --train-patterns --memory-key "utils/refactor"
|
||||
```
|
||||
|
||||
## Features
|
||||
|
||||
### Auto Formatting
|
||||
- Language-specific formatters
|
||||
- Prettier for JS/TS/JSON
|
||||
- Black for Python
|
||||
- gofmt for Go
|
||||
- Maintains consistency
|
||||
|
||||
### Memory Storage
|
||||
- Saves edit context
|
||||
- Records decisions made
|
||||
- Tracks implementation details
|
||||
- Enables knowledge sharing
|
||||
|
||||
### Pattern Training
|
||||
- Learns from successful edits
|
||||
- Improves future suggestions
|
||||
- Adapts to coding style
|
||||
- Enhances coordination
|
||||
|
||||
### Output Validation
|
||||
- Checks syntax correctness
|
||||
- Runs linting rules
|
||||
- Validates formatting
|
||||
- Ensures quality
|
||||
|
||||
## Integration
|
||||
|
||||
This hook is automatically called by Claude Code when:
|
||||
- After Edit tool completes
|
||||
- Following MultiEdit operations
|
||||
- During file saves
|
||||
- After code generation
|
||||
|
||||
Manual usage in agents:
|
||||
```bash
|
||||
# After editing files
|
||||
npx claude-flow hook post-edit --file "path/to/edited.js" --memory-key "feature/step1"
|
||||
```
|
||||
|
||||
## Output
|
||||
|
||||
Returns JSON with:
|
||||
```json
|
||||
{
|
||||
"file": "src/components/Button.jsx",
|
||||
"formatted": true,
|
||||
"formatterUsed": "prettier",
|
||||
"lintPassed": true,
|
||||
"memorySaved": "component/button-refactor",
|
||||
"patternsTrained": 3,
|
||||
"warnings": [],
|
||||
"stats": {
|
||||
"linesChanged": 45,
|
||||
"charactersAdded": 234
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## See Also
|
||||
|
||||
- `hook pre-edit` - Pre-edit preparation
|
||||
- `Edit` - File editing tool
|
||||
- `memory usage` - Memory management
|
||||
- `neural train` - Pattern training
|
||||
@@ -0,0 +1,101 @@
|
||||
# hook post-task
|
||||
|
||||
Execute post-task cleanup, performance analysis, and memory storage.
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
npx claude-flow hook post-task [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
|
||||
- `--task-id, -t <id>` - Task identifier for tracking
|
||||
- `--analyze-performance` - Generate performance metrics (default: true)
|
||||
- `--store-decisions` - Save task decisions to memory
|
||||
- `--export-learnings` - Export neural pattern learnings
|
||||
- `--generate-report` - Create task completion report
|
||||
|
||||
## Examples
|
||||
|
||||
### Basic post-task hook
|
||||
```bash
|
||||
npx claude-flow hook post-task --task-id "auth-implementation"
|
||||
```
|
||||
|
||||
### With full analysis
|
||||
```bash
|
||||
npx claude-flow hook post-task -t "api-refactor" --analyze-performance --generate-report
|
||||
```
|
||||
|
||||
### Memory storage
|
||||
```bash
|
||||
npx claude-flow hook post-task -t "bug-fix-123" --store-decisions --export-learnings
|
||||
```
|
||||
|
||||
### Quick cleanup
|
||||
```bash
|
||||
npx claude-flow hook post-task -t "minor-update" --analyze-performance false
|
||||
```
|
||||
|
||||
## Features
|
||||
|
||||
### Performance Analysis
|
||||
- Measures execution time
|
||||
- Tracks token usage
|
||||
- Identifies bottlenecks
|
||||
- Suggests optimizations
|
||||
|
||||
### Decision Storage
|
||||
- Saves key decisions made
|
||||
- Records implementation choices
|
||||
- Stores error resolutions
|
||||
- Maintains knowledge base
|
||||
|
||||
### Neural Learning
|
||||
- Exports successful patterns
|
||||
- Updates coordination models
|
||||
- Improves future performance
|
||||
- Trains on task outcomes
|
||||
|
||||
### Report Generation
|
||||
- Creates completion summary
|
||||
- Documents changes made
|
||||
- Lists files modified
|
||||
- Tracks metrics achieved
|
||||
|
||||
## Integration
|
||||
|
||||
This hook is automatically called by Claude Code when:
|
||||
- Completing a task
|
||||
- Switching to a new task
|
||||
- Ending a work session
|
||||
- After major milestones
|
||||
|
||||
Manual usage in agents:
|
||||
```bash
|
||||
# In agent coordination
|
||||
npx claude-flow hook post-task --task-id "your-task-id" --analyze-performance true
|
||||
```
|
||||
|
||||
## Output
|
||||
|
||||
Returns JSON with:
|
||||
```json
|
||||
{
|
||||
"taskId": "auth-implementation",
|
||||
"duration": 1800000,
|
||||
"tokensUsed": 45000,
|
||||
"filesModified": 12,
|
||||
"performanceScore": 0.92,
|
||||
"learningsExported": true,
|
||||
"reportPath": "/reports/task-auth-implementation.md"
|
||||
}
|
||||
```
|
||||
|
||||
## See Also
|
||||
|
||||
- `hook pre-task` - Pre-task setup
|
||||
- `performance report` - Detailed metrics
|
||||
- `memory usage` - Memory management
|
||||
- `neural patterns` - Pattern analysis
|
||||
@@ -0,0 +1,102 @@
|
||||
# hook pre-edit
|
||||
|
||||
Execute pre-edit validations and agent assignment before file modifications.
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
npx claude-flow hook pre-edit [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
|
||||
- `--file, -f <path>` - File path to be edited
|
||||
- `--auto-assign-agent` - Automatically assign best agent (default: true)
|
||||
- `--validate-syntax` - Pre-validate syntax before edit
|
||||
- `--check-conflicts` - Check for merge conflicts
|
||||
- `--backup-file` - Create backup before editing
|
||||
|
||||
## Examples
|
||||
|
||||
### Basic pre-edit hook
|
||||
```bash
|
||||
npx claude-flow hook pre-edit --file "src/auth/login.js"
|
||||
```
|
||||
|
||||
### With validation
|
||||
```bash
|
||||
npx claude-flow hook pre-edit -f "config/database.js" --validate-syntax
|
||||
```
|
||||
|
||||
### Manual agent assignment
|
||||
```bash
|
||||
npx claude-flow hook pre-edit -f "api/users.ts" --auto-assign-agent false
|
||||
```
|
||||
|
||||
### Safe editing with backup
|
||||
```bash
|
||||
npx claude-flow hook pre-edit -f "production.env" --backup-file --check-conflicts
|
||||
```
|
||||
|
||||
## Features
|
||||
|
||||
### Auto Agent Assignment
|
||||
- Analyzes file type and content
|
||||
- Assigns specialist agents
|
||||
- TypeScript → TypeScript expert
|
||||
- Database → Data specialist
|
||||
- Tests → QA engineer
|
||||
|
||||
### Syntax Validation
|
||||
- Pre-checks syntax validity
|
||||
- Identifies potential errors
|
||||
- Suggests corrections
|
||||
- Prevents broken code
|
||||
|
||||
### Conflict Detection
|
||||
- Checks for git conflicts
|
||||
- Identifies concurrent edits
|
||||
- Warns about stale files
|
||||
- Suggests merge strategies
|
||||
|
||||
### File Backup
|
||||
- Creates safety backups
|
||||
- Enables quick rollback
|
||||
- Tracks edit history
|
||||
- Preserves originals
|
||||
|
||||
## Integration
|
||||
|
||||
This hook is automatically called by Claude Code when:
|
||||
- Using Edit or MultiEdit tools
|
||||
- Before file modifications
|
||||
- During refactoring operations
|
||||
- When updating critical files
|
||||
|
||||
Manual usage in agents:
|
||||
```bash
|
||||
# Before editing files
|
||||
npx claude-flow hook pre-edit --file "path/to/file.js" --validate-syntax
|
||||
```
|
||||
|
||||
## Output
|
||||
|
||||
Returns JSON with:
|
||||
```json
|
||||
{
|
||||
"continue": true,
|
||||
"file": "src/auth/login.js",
|
||||
"assignedAgent": "auth-specialist",
|
||||
"syntaxValid": true,
|
||||
"conflicts": false,
|
||||
"backupPath": ".backups/login.js.bak",
|
||||
"warnings": []
|
||||
}
|
||||
```
|
||||
|
||||
## See Also
|
||||
|
||||
- `hook post-edit` - Post-edit processing
|
||||
- `Edit` - File editing tool
|
||||
- `MultiEdit` - Multiple edits tool
|
||||
- `agent spawn` - Manual agent creation
|
||||
@@ -0,0 +1,100 @@
|
||||
# hook pre-task
|
||||
|
||||
Execute pre-task preparations and context loading.
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
npx claude-flow hook pre-task [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
|
||||
- `--description, -d <text>` - Task description for context
|
||||
- `--auto-spawn-agents` - Automatically spawn required agents (default: true)
|
||||
- `--load-memory` - Load relevant memory from previous sessions
|
||||
- `--optimize-topology` - Select optimal swarm topology
|
||||
- `--estimate-complexity` - Analyze task complexity
|
||||
|
||||
## Examples
|
||||
|
||||
### Basic pre-task hook
|
||||
```bash
|
||||
npx claude-flow hook pre-task --description "Implement user authentication"
|
||||
```
|
||||
|
||||
### With memory loading
|
||||
```bash
|
||||
npx claude-flow hook pre-task -d "Continue API development" --load-memory
|
||||
```
|
||||
|
||||
### Manual agent control
|
||||
```bash
|
||||
npx claude-flow hook pre-task -d "Debug issue #123" --auto-spawn-agents false
|
||||
```
|
||||
|
||||
### Full optimization
|
||||
```bash
|
||||
npx claude-flow hook pre-task -d "Refactor codebase" --optimize-topology --estimate-complexity
|
||||
```
|
||||
|
||||
## Features
|
||||
|
||||
### Auto Agent Assignment
|
||||
- Analyzes task requirements
|
||||
- Determines needed agent types
|
||||
- Spawns agents automatically
|
||||
- Configures agent parameters
|
||||
|
||||
### Memory Loading
|
||||
- Retrieves relevant past decisions
|
||||
- Loads previous task contexts
|
||||
- Restores agent configurations
|
||||
- Maintains continuity
|
||||
|
||||
### Topology Optimization
|
||||
- Analyzes task structure
|
||||
- Selects best swarm topology
|
||||
- Configures communication patterns
|
||||
- Optimizes for performance
|
||||
|
||||
### Complexity Estimation
|
||||
- Evaluates task difficulty
|
||||
- Estimates time requirements
|
||||
- Suggests agent count
|
||||
- Identifies dependencies
|
||||
|
||||
## Integration
|
||||
|
||||
This hook is automatically called by Claude Code when:
|
||||
- Starting a new task
|
||||
- Resuming work after a break
|
||||
- Switching between projects
|
||||
- Beginning complex operations
|
||||
|
||||
Manual usage in agents:
|
||||
```bash
|
||||
# In agent coordination
|
||||
npx claude-flow hook pre-task --description "Your task here"
|
||||
```
|
||||
|
||||
## Output
|
||||
|
||||
Returns JSON with:
|
||||
```json
|
||||
{
|
||||
"continue": true,
|
||||
"topology": "hierarchical",
|
||||
"agentsSpawned": 5,
|
||||
"complexity": "medium",
|
||||
"estimatedMinutes": 30,
|
||||
"memoryLoaded": true
|
||||
}
|
||||
```
|
||||
|
||||
## See Also
|
||||
|
||||
- `hook post-task` - Post-task cleanup
|
||||
- `agent spawn` - Manual agent creation
|
||||
- `memory usage` - Memory management
|
||||
- `swarm init` - Swarm initialization
|
||||
@@ -0,0 +1,107 @@
|
||||
# hook session-end
|
||||
|
||||
Cleanup and persist session state before ending work.
|
||||
|
||||
## Usage
|
||||
|
||||
```bash
|
||||
npx claude-flow hook session-end [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
|
||||
- `--session-id, -s <id>` - Session identifier to end
|
||||
- `--save-state` - Save current session state (default: true)
|
||||
- `--export-metrics` - Export session metrics
|
||||
- `--generate-summary` - Create session summary
|
||||
- `--cleanup-temp` - Remove temporary files
|
||||
|
||||
## Examples
|
||||
|
||||
### Basic session end
|
||||
```bash
|
||||
npx claude-flow hook session-end --session-id "dev-session-2024"
|
||||
```
|
||||
|
||||
### With full export
|
||||
```bash
|
||||
npx claude-flow hook session-end -s "feature-auth" --export-metrics --generate-summary
|
||||
```
|
||||
|
||||
### Quick close
|
||||
```bash
|
||||
npx claude-flow hook session-end -s "quick-fix" --save-state false --cleanup-temp
|
||||
```
|
||||
|
||||
### Complete persistence
|
||||
```bash
|
||||
npx claude-flow hook session-end -s "major-refactor" --save-state --export-metrics --generate-summary
|
||||
```
|
||||
|
||||
## Features
|
||||
|
||||
### State Persistence
|
||||
- Saves current context
|
||||
- Stores open files
|
||||
- Preserves task progress
|
||||
- Maintains decisions
|
||||
|
||||
### Metric Export
|
||||
- Session duration
|
||||
- Commands executed
|
||||
- Files modified
|
||||
- Tokens consumed
|
||||
- Performance data
|
||||
|
||||
### Summary Generation
|
||||
- Work accomplished
|
||||
- Key decisions made
|
||||
- Problems solved
|
||||
- Next steps identified
|
||||
|
||||
### Cleanup Operations
|
||||
- Removes temp files
|
||||
- Clears caches
|
||||
- Frees resources
|
||||
- Optimizes storage
|
||||
|
||||
## Integration
|
||||
|
||||
This hook is automatically called by Claude Code when:
|
||||
- Ending a conversation
|
||||
- Closing work session
|
||||
- Before shutdown
|
||||
- Switching contexts
|
||||
|
||||
Manual usage in agents:
|
||||
```bash
|
||||
# At session end
|
||||
npx claude-flow hook session-end --session-id "your-session" --generate-summary
|
||||
```
|
||||
|
||||
## Output
|
||||
|
||||
Returns JSON with:
|
||||
```json
|
||||
{
|
||||
"sessionId": "dev-session-2024",
|
||||
"duration": 7200000,
|
||||
"saved": true,
|
||||
"metrics": {
|
||||
"commandsRun": 145,
|
||||
"filesModified": 23,
|
||||
"tokensUsed": 85000,
|
||||
"tasksCompleted": 8
|
||||
},
|
||||
"summaryPath": "/sessions/dev-session-2024-summary.md",
|
||||
"cleanedUp": true,
|
||||
"nextSession": "dev-session-2025"
|
||||
}
|
||||
```
|
||||
|
||||
## See Also
|
||||
|
||||
- `hook session-start` - Session initialization
|
||||
- `hook session-restore` - Session restoration
|
||||
- `performance report` - Detailed metrics
|
||||
- `memory backup` - State backup
|
||||
@@ -0,0 +1,9 @@
|
||||
# Memory Commands
|
||||
|
||||
Commands for memory operations in Claude Flow.
|
||||
|
||||
## Available Commands
|
||||
|
||||
- [memory-usage](./memory-usage.md)
|
||||
- [memory-persist](./memory-persist.md)
|
||||
- [memory-search](./memory-search.md)
|
||||
@@ -0,0 +1,25 @@
|
||||
# memory-persist
|
||||
|
||||
Persist memory across sessions.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow memory persist [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--export <file>` - Export to file
|
||||
- `--import <file>` - Import from file
|
||||
- `--compress` - Compress memory data
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Export memory
|
||||
npx claude-flow memory persist --export memory-backup.json
|
||||
|
||||
# Import memory
|
||||
npx claude-flow memory persist --import memory-backup.json
|
||||
|
||||
# Compressed export
|
||||
npx claude-flow memory persist --export memory.gz --compress
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# memory-search
|
||||
|
||||
Search through stored memory.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow memory search [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--query <text>` - Search query
|
||||
- `--pattern <regex>` - Pattern matching
|
||||
- `--limit <n>` - Result limit
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Search memory
|
||||
npx claude-flow memory search --query "authentication"
|
||||
|
||||
# Pattern search
|
||||
npx claude-flow memory search --pattern "api-.*"
|
||||
|
||||
# Limited results
|
||||
npx claude-flow memory search --query "config" --limit 10
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# memory-usage
|
||||
|
||||
Manage persistent memory storage.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow memory usage [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--action <type>` - Action (store, retrieve, list, clear)
|
||||
- `--key <key>` - Memory key
|
||||
- `--value <data>` - Data to store (JSON)
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Store memory
|
||||
npx claude-flow memory usage --action store --key "project-config" --value '{"api": "v2"}'
|
||||
|
||||
# Retrieve memory
|
||||
npx claude-flow memory usage --action retrieve --key "project-config"
|
||||
|
||||
# List all keys
|
||||
npx claude-flow memory usage --action list
|
||||
```
|
||||
@@ -0,0 +1,9 @@
|
||||
# Monitoring Commands
|
||||
|
||||
Commands for monitoring operations in Claude Flow.
|
||||
|
||||
## Available Commands
|
||||
|
||||
- [swarm-monitor](./swarm-monitor.md)
|
||||
- [agent-metrics](./agent-metrics.md)
|
||||
- [real-time-view](./real-time-view.md)
|
||||
@@ -0,0 +1,25 @@
|
||||
# agent-metrics
|
||||
|
||||
View agent performance metrics.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow agent metrics [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--agent-id <id>` - Specific agent
|
||||
- `--period <time>` - Time period
|
||||
- `--format <type>` - Output format
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# All agents metrics
|
||||
npx claude-flow agent metrics
|
||||
|
||||
# Specific agent
|
||||
npx claude-flow agent metrics --agent-id agent-001
|
||||
|
||||
# Last hour
|
||||
npx claude-flow agent metrics --period 1h
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# real-time-view
|
||||
|
||||
Real-time view of swarm activity.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow monitoring real-time-view [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--filter <type>` - Filter view
|
||||
- `--highlight <pattern>` - Highlight pattern
|
||||
- `--tail <n>` - Show last N events
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Start real-time view
|
||||
npx claude-flow monitoring real-time-view
|
||||
|
||||
# Filter errors
|
||||
npx claude-flow monitoring real-time-view --filter errors
|
||||
|
||||
# Highlight pattern
|
||||
npx claude-flow monitoring real-time-view --highlight "API"
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# swarm-monitor
|
||||
|
||||
Real-time swarm monitoring.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow swarm monitor [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--interval <ms>` - Update interval
|
||||
- `--metrics` - Show detailed metrics
|
||||
- `--export` - Export monitoring data
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Start monitoring
|
||||
npx claude-flow swarm monitor
|
||||
|
||||
# Custom interval
|
||||
npx claude-flow swarm monitor --interval 5000
|
||||
|
||||
# With metrics
|
||||
npx claude-flow swarm monitor --metrics
|
||||
```
|
||||
@@ -0,0 +1,9 @@
|
||||
# Optimization Commands
|
||||
|
||||
Commands for optimization operations in Claude Flow.
|
||||
|
||||
## Available Commands
|
||||
|
||||
- [topology-optimize](./topology-optimize.md)
|
||||
- [parallel-execute](./parallel-execute.md)
|
||||
- [cache-manage](./cache-manage.md)
|
||||
@@ -0,0 +1,25 @@
|
||||
# cache-manage
|
||||
|
||||
Manage operation cache for performance.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow optimization cache-manage [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--action <type>` - Action (view, clear, optimize)
|
||||
- `--max-size <mb>` - Maximum cache size
|
||||
- `--ttl <seconds>` - Time to live
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# View cache stats
|
||||
npx claude-flow optimization cache-manage --action view
|
||||
|
||||
# Clear cache
|
||||
npx claude-flow optimization cache-manage --action clear
|
||||
|
||||
# Set limits
|
||||
npx claude-flow optimization cache-manage --max-size 100 --ttl 3600
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# parallel-execute
|
||||
|
||||
Execute tasks in parallel for maximum efficiency.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow optimization parallel-execute [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--tasks <file>` - Task list file
|
||||
- `--max-parallel <n>` - Maximum parallel tasks
|
||||
- `--strategy <type>` - Execution strategy
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Execute task list
|
||||
npx claude-flow optimization parallel-execute --tasks tasks.json
|
||||
|
||||
# Limit parallelism
|
||||
npx claude-flow optimization parallel-execute --tasks tasks.json --max-parallel 5
|
||||
|
||||
# Custom strategy
|
||||
npx claude-flow optimization parallel-execute --strategy adaptive
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# topology-optimize
|
||||
|
||||
Optimize swarm topology for current workload.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow optimization topology-optimize [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--analyze-first` - Analyze before optimizing
|
||||
- `--target <metric>` - Optimization target
|
||||
- `--apply` - Apply optimizations
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Analyze and suggest
|
||||
npx claude-flow optimization topology-optimize --analyze-first
|
||||
|
||||
# Optimize for speed
|
||||
npx claude-flow optimization topology-optimize --target speed
|
||||
|
||||
# Apply changes
|
||||
npx claude-flow optimization topology-optimize --target efficiency --apply
|
||||
```
|
||||
@@ -0,0 +1,26 @@
|
||||
# SPARC Analyzer Mode
|
||||
|
||||
## Purpose
|
||||
Deep code and data analysis with batch processing capabilities.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run analyzer "analyze codebase performance"`
|
||||
|
||||
## Core Capabilities
|
||||
- Code analysis with parallel file processing
|
||||
- Data pattern recognition
|
||||
- Performance profiling
|
||||
- Memory usage analysis
|
||||
- Dependency mapping
|
||||
|
||||
## Batch Operations
|
||||
- Parallel file analysis using concurrent Read operations
|
||||
- Batch pattern matching with Grep tool
|
||||
- Simultaneous metric collection
|
||||
- Aggregated reporting
|
||||
|
||||
## Output Format
|
||||
- Detailed analysis reports
|
||||
- Performance metrics
|
||||
- Improvement recommendations
|
||||
- Visualizations when applicable
|
||||
@@ -0,0 +1,27 @@
|
||||
# SPARC Architect Mode
|
||||
|
||||
## Purpose
|
||||
System design with Memory-based coordination for scalable architectures.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run architect "design microservices architecture"`
|
||||
|
||||
## Core Capabilities
|
||||
- System architecture design
|
||||
- Component interface definition
|
||||
- Database schema design
|
||||
- API contract specification
|
||||
- Infrastructure planning
|
||||
|
||||
## Memory Integration
|
||||
- Store architecture decisions in Memory
|
||||
- Share component specifications across agents
|
||||
- Maintain design consistency
|
||||
- Track architectural evolution
|
||||
|
||||
## Design Patterns
|
||||
- Microservices
|
||||
- Event-driven architecture
|
||||
- Domain-driven design
|
||||
- Hexagonal architecture
|
||||
- CQRS and Event Sourcing
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Batch Executor Mode
|
||||
|
||||
## Purpose
|
||||
Parallel task execution specialist using batch operations.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run batch-executor "process multiple files"`
|
||||
|
||||
## Core Capabilities
|
||||
- Parallel file operations
|
||||
- Concurrent task execution
|
||||
- Resource optimization
|
||||
- Load balancing
|
||||
- Progress tracking
|
||||
|
||||
## Execution Patterns
|
||||
- Parallel Read/Write operations
|
||||
- Concurrent Edit operations
|
||||
- Batch file transformations
|
||||
- Distributed processing
|
||||
- Pipeline orchestration
|
||||
|
||||
## Performance Features
|
||||
- Dynamic resource allocation
|
||||
- Automatic load balancing
|
||||
- Progress monitoring
|
||||
- Error recovery
|
||||
- Result aggregation
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Coder Mode
|
||||
|
||||
## Purpose
|
||||
Autonomous code generation with batch file operations.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run coder "implement user authentication"`
|
||||
|
||||
## Core Capabilities
|
||||
- Feature implementation
|
||||
- Code refactoring
|
||||
- Bug fixes
|
||||
- API development
|
||||
- Algorithm implementation
|
||||
|
||||
## Batch Operations
|
||||
- Parallel file creation
|
||||
- Concurrent code modifications
|
||||
- Batch import updates
|
||||
- Test file generation
|
||||
- Documentation updates
|
||||
|
||||
## Code Quality
|
||||
- ES2022 standards
|
||||
- Type safety with TypeScript
|
||||
- Comprehensive error handling
|
||||
- Performance optimization
|
||||
- Security best practices
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Debugger Mode
|
||||
|
||||
## Purpose
|
||||
Systematic debugging with TodoWrite and Memory integration.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run debugger "fix authentication issues"`
|
||||
|
||||
## Core Capabilities
|
||||
- Issue reproduction
|
||||
- Root cause analysis
|
||||
- Stack trace analysis
|
||||
- Memory leak detection
|
||||
- Performance bottleneck identification
|
||||
|
||||
## Debugging Workflow
|
||||
1. Create debugging plan with TodoWrite
|
||||
2. Systematic issue investigation
|
||||
3. Store findings in Memory
|
||||
4. Track fix progress
|
||||
5. Verify resolution
|
||||
|
||||
## Tools Integration
|
||||
- Error log analysis
|
||||
- Breakpoint simulation
|
||||
- Variable inspection
|
||||
- Call stack tracing
|
||||
- Memory profiling
|
||||
@@ -0,0 +1,27 @@
|
||||
# SPARC Designer Mode
|
||||
|
||||
## Purpose
|
||||
UI/UX design with Memory coordination for consistent experiences.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run designer "create dashboard UI"`
|
||||
|
||||
## Core Capabilities
|
||||
- Interface design
|
||||
- Component architecture
|
||||
- Design system creation
|
||||
- Accessibility planning
|
||||
- Responsive layouts
|
||||
|
||||
## Design Process
|
||||
- User research insights
|
||||
- Wireframe creation
|
||||
- Component design
|
||||
- Interaction patterns
|
||||
- Design token management
|
||||
|
||||
## Memory Coordination
|
||||
- Store design decisions
|
||||
- Share component specs
|
||||
- Maintain consistency
|
||||
- Track design evolution
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Documenter Mode
|
||||
|
||||
## Purpose
|
||||
Documentation with batch file operations for comprehensive docs.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run documenter "create API documentation"`
|
||||
|
||||
## Core Capabilities
|
||||
- API documentation
|
||||
- Code documentation
|
||||
- User guides
|
||||
- Architecture docs
|
||||
- README files
|
||||
|
||||
## Documentation Types
|
||||
- Markdown documentation
|
||||
- JSDoc comments
|
||||
- API specifications
|
||||
- Integration guides
|
||||
- Deployment docs
|
||||
|
||||
## Batch Features
|
||||
- Parallel doc generation
|
||||
- Bulk file updates
|
||||
- Cross-reference management
|
||||
- Example generation
|
||||
- Diagram creation
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Innovator Mode
|
||||
|
||||
## Purpose
|
||||
Creative problem solving with WebSearch and Memory integration.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run innovator "innovative solutions for scaling"`
|
||||
|
||||
## Core Capabilities
|
||||
- Creative ideation
|
||||
- Solution brainstorming
|
||||
- Technology exploration
|
||||
- Pattern innovation
|
||||
- Proof of concept
|
||||
|
||||
## Innovation Process
|
||||
- Divergent thinking phase
|
||||
- Research and exploration
|
||||
- Convergent synthesis
|
||||
- Prototype planning
|
||||
- Feasibility analysis
|
||||
|
||||
## Knowledge Sources
|
||||
- WebSearch for trends
|
||||
- Memory for context
|
||||
- Cross-domain insights
|
||||
- Pattern recognition
|
||||
- Analogical reasoning
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Memory Manager Mode
|
||||
|
||||
## Purpose
|
||||
Knowledge management with Memory tools for persistent insights.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run memory-manager "organize project knowledge"`
|
||||
|
||||
## Core Capabilities
|
||||
- Knowledge organization
|
||||
- Information retrieval
|
||||
- Context management
|
||||
- Insight preservation
|
||||
- Cross-session persistence
|
||||
|
||||
## Memory Strategies
|
||||
- Hierarchical organization
|
||||
- Tag-based categorization
|
||||
- Temporal tracking
|
||||
- Relationship mapping
|
||||
- Priority management
|
||||
|
||||
## Knowledge Operations
|
||||
- Store critical insights
|
||||
- Retrieve relevant context
|
||||
- Update knowledge base
|
||||
- Merge related information
|
||||
- Archive obsolete data
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Optimizer Mode
|
||||
|
||||
## Purpose
|
||||
Performance optimization with systematic analysis and improvements.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run optimizer "optimize application performance"`
|
||||
|
||||
## Core Capabilities
|
||||
- Performance profiling
|
||||
- Code optimization
|
||||
- Resource optimization
|
||||
- Algorithm improvement
|
||||
- Scalability enhancement
|
||||
|
||||
## Optimization Areas
|
||||
- Execution speed
|
||||
- Memory usage
|
||||
- Network efficiency
|
||||
- Database queries
|
||||
- Bundle size
|
||||
|
||||
## Systematic Approach
|
||||
1. Baseline measurement
|
||||
2. Bottleneck identification
|
||||
3. Optimization implementation
|
||||
4. Impact verification
|
||||
5. Continuous monitoring
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Orchestrator Mode
|
||||
|
||||
## Purpose
|
||||
Multi-agent task orchestration with TodoWrite/TodoRead/Task/Memory.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run orchestrator "coordinate feature development"`
|
||||
|
||||
## Core Capabilities
|
||||
- Task decomposition
|
||||
- Agent coordination
|
||||
- Resource allocation
|
||||
- Progress tracking
|
||||
- Result synthesis
|
||||
|
||||
## Orchestration Patterns
|
||||
- Hierarchical coordination
|
||||
- Parallel execution
|
||||
- Sequential pipelines
|
||||
- Event-driven flows
|
||||
- Adaptive strategies
|
||||
|
||||
## Coordination Tools
|
||||
- TodoWrite for planning
|
||||
- Task for agent launch
|
||||
- Memory for sharing
|
||||
- Progress monitoring
|
||||
- Result aggregation
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Researcher Mode
|
||||
|
||||
## Purpose
|
||||
Deep research with parallel WebSearch/WebFetch and Memory coordination.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run researcher "research AI trends 2024"`
|
||||
|
||||
## Core Capabilities
|
||||
- Information gathering
|
||||
- Source evaluation
|
||||
- Trend analysis
|
||||
- Competitive research
|
||||
- Technology assessment
|
||||
|
||||
## Research Methods
|
||||
- Parallel web searches
|
||||
- Academic paper analysis
|
||||
- Industry report synthesis
|
||||
- Expert opinion gathering
|
||||
- Data compilation
|
||||
|
||||
## Memory Integration
|
||||
- Store research findings
|
||||
- Build knowledge graphs
|
||||
- Track information sources
|
||||
- Cross-reference insights
|
||||
- Maintain research history
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Reviewer Mode
|
||||
|
||||
## Purpose
|
||||
Code review using batch file analysis for comprehensive reviews.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run reviewer "review pull request #123"`
|
||||
|
||||
## Core Capabilities
|
||||
- Code quality assessment
|
||||
- Security review
|
||||
- Performance analysis
|
||||
- Best practices check
|
||||
- Documentation review
|
||||
|
||||
## Review Criteria
|
||||
- Code correctness
|
||||
- Design patterns
|
||||
- Error handling
|
||||
- Test coverage
|
||||
- Maintainability
|
||||
|
||||
## Batch Analysis
|
||||
- Parallel file review
|
||||
- Pattern detection
|
||||
- Dependency checking
|
||||
- Consistency validation
|
||||
- Automated reporting
|
||||
@@ -0,0 +1,42 @@
|
||||
# SPARC Modes Overview
|
||||
|
||||
SPARC (Specification, Planning, Architecture, Review, Code) is a comprehensive development methodology with 17 specialized modes.
|
||||
|
||||
## Available Modes
|
||||
|
||||
### Core Orchestration Modes
|
||||
- **orchestrator**: Multi-agent task orchestration
|
||||
- **swarm-coordinator**: Specialized swarm management
|
||||
- **workflow-manager**: Process automation
|
||||
- **batch-executor**: Parallel task execution
|
||||
|
||||
### Development Modes
|
||||
- **coder**: Autonomous code generation
|
||||
- **architect**: System design
|
||||
- **reviewer**: Code review
|
||||
- **tdd**: Test-driven development
|
||||
|
||||
### Analysis and Research Modes
|
||||
- **researcher**: Deep research capabilities
|
||||
- **analyzer**: Code and data analysis
|
||||
- **optimizer**: Performance optimization
|
||||
|
||||
### Creative and Support Modes
|
||||
- **designer**: UI/UX design
|
||||
- **innovator**: Creative problem solving
|
||||
- **documenter**: Documentation generation
|
||||
- **debugger**: Systematic debugging
|
||||
- **tester**: Comprehensive testing
|
||||
- **memory-manager**: Knowledge management
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
# Run a specific mode
|
||||
./claude-flow sparc run <mode> "task description"
|
||||
|
||||
# List all modes
|
||||
./claude-flow sparc modes
|
||||
|
||||
# Get help for a mode
|
||||
./claude-flow sparc help <mode>
|
||||
```
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Swarm Coordinator Mode
|
||||
|
||||
## Purpose
|
||||
Specialized swarm management with batch coordination capabilities.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run swarm-coordinator "manage development swarm"`
|
||||
|
||||
## Core Capabilities
|
||||
- Swarm initialization
|
||||
- Agent management
|
||||
- Task distribution
|
||||
- Load balancing
|
||||
- Result collection
|
||||
|
||||
## Coordination Modes
|
||||
- Hierarchical swarms
|
||||
- Mesh networks
|
||||
- Pipeline coordination
|
||||
- Adaptive strategies
|
||||
- Hybrid approaches
|
||||
|
||||
## Management Features
|
||||
- Dynamic scaling
|
||||
- Resource optimization
|
||||
- Failure recovery
|
||||
- Performance monitoring
|
||||
- Quality assurance
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC TDD Mode
|
||||
|
||||
## Purpose
|
||||
Test-driven development with TodoWrite planning and comprehensive testing.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run tdd "shopping cart feature"`
|
||||
|
||||
## Core Capabilities
|
||||
- Test-first development
|
||||
- Red-green-refactor cycle
|
||||
- Test suite design
|
||||
- Coverage optimization
|
||||
- Continuous testing
|
||||
|
||||
## TDD Workflow
|
||||
1. Write failing tests
|
||||
2. Implement minimum code
|
||||
3. Make tests pass
|
||||
4. Refactor code
|
||||
5. Repeat cycle
|
||||
|
||||
## Testing Strategies
|
||||
- Unit testing
|
||||
- Integration testing
|
||||
- End-to-end testing
|
||||
- Performance testing
|
||||
- Security testing
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Tester Mode
|
||||
|
||||
## Purpose
|
||||
Comprehensive testing with parallel execution capabilities.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run tester "full regression suite"`
|
||||
|
||||
## Core Capabilities
|
||||
- Test planning
|
||||
- Test execution
|
||||
- Bug detection
|
||||
- Coverage analysis
|
||||
- Report generation
|
||||
|
||||
## Test Types
|
||||
- Unit tests
|
||||
- Integration tests
|
||||
- E2E tests
|
||||
- Performance tests
|
||||
- Security tests
|
||||
|
||||
## Parallel Features
|
||||
- Concurrent test runs
|
||||
- Distributed testing
|
||||
- Load testing
|
||||
- Cross-browser testing
|
||||
- Multi-environment validation
|
||||
@@ -0,0 +1,28 @@
|
||||
# SPARC Workflow Manager Mode
|
||||
|
||||
## Purpose
|
||||
Process automation with TodoWrite planning and Task execution.
|
||||
|
||||
## Activation
|
||||
`./claude-flow sparc run workflow-manager "automate deployment"`
|
||||
|
||||
## Core Capabilities
|
||||
- Workflow design
|
||||
- Process automation
|
||||
- Pipeline creation
|
||||
- Event handling
|
||||
- State management
|
||||
|
||||
## Workflow Patterns
|
||||
- Sequential flows
|
||||
- Parallel branches
|
||||
- Conditional logic
|
||||
- Loop iterations
|
||||
- Error handling
|
||||
|
||||
## Automation Features
|
||||
- Trigger management
|
||||
- Task scheduling
|
||||
- Progress tracking
|
||||
- Result validation
|
||||
- Rollback capability
|
||||
@@ -0,0 +1,18 @@
|
||||
# Analysis Swarm Strategy
|
||||
|
||||
## Purpose
|
||||
Comprehensive analysis through distributed agent coordination.
|
||||
|
||||
## Activation
|
||||
`./claude-flow swarm "analyze system performance" --strategy analysis`
|
||||
|
||||
## Agent Roles
|
||||
- Data Collector: Gathers metrics and logs
|
||||
- Pattern Analyzer: Identifies trends and anomalies
|
||||
- Report Generator: Creates comprehensive reports
|
||||
- Insight Synthesizer: Combines findings
|
||||
|
||||
## Coordination Modes
|
||||
- Mesh: For exploratory analysis
|
||||
- Pipeline: For sequential processing
|
||||
- Hierarchical: For complex systems
|
||||
@@ -0,0 +1,19 @@
|
||||
# Development Swarm Strategy
|
||||
|
||||
## Purpose
|
||||
Coordinated development through specialized agent teams.
|
||||
|
||||
## Activation
|
||||
`./claude-flow swarm "build feature X" --strategy development`
|
||||
|
||||
## Agent Roles
|
||||
- Architect: Designs system structure
|
||||
- Frontend Developer: Implements UI
|
||||
- Backend Developer: Creates APIs
|
||||
- Database Specialist: Manages data layer
|
||||
- Integration Expert: Connects components
|
||||
|
||||
## Best Practices
|
||||
- Use hierarchical mode for large projects
|
||||
- Enable parallel execution
|
||||
- Implement continuous testing
|
||||
@@ -0,0 +1,30 @@
|
||||
# Examples Swarm Strategy
|
||||
|
||||
## Common Swarm Patterns
|
||||
|
||||
### Research Swarm
|
||||
```bash
|
||||
./claude-flow swarm "research AI trends" \
|
||||
--strategy research \
|
||||
--mode distributed \
|
||||
--max-agents 6 \
|
||||
--parallel
|
||||
```
|
||||
|
||||
### Development Swarm
|
||||
```bash
|
||||
./claude-flow swarm "build REST API" \
|
||||
--strategy development \
|
||||
--mode hierarchical \
|
||||
--monitor \
|
||||
--output sqlite
|
||||
```
|
||||
|
||||
### Analysis Swarm
|
||||
```bash
|
||||
./claude-flow swarm "analyze codebase" \
|
||||
--strategy analysis \
|
||||
--mode mesh \
|
||||
--parallel \
|
||||
--timeout 300
|
||||
```
|
||||
@@ -0,0 +1,18 @@
|
||||
# Maintenance Swarm Strategy
|
||||
|
||||
## Purpose
|
||||
System maintenance and updates through coordinated agents.
|
||||
|
||||
## Activation
|
||||
`./claude-flow swarm "update dependencies" --strategy maintenance`
|
||||
|
||||
## Agent Roles
|
||||
- Dependency Analyzer: Checks for updates
|
||||
- Security Scanner: Identifies vulnerabilities
|
||||
- Test Runner: Validates changes
|
||||
- Documentation Updater: Maintains docs
|
||||
|
||||
## Safety Features
|
||||
- Automatic backups
|
||||
- Rollback capability
|
||||
- Incremental updates
|
||||
@@ -0,0 +1,19 @@
|
||||
# Optimization Swarm Strategy
|
||||
|
||||
## Purpose
|
||||
Performance optimization through specialized analysis.
|
||||
|
||||
## Activation
|
||||
`./claude-flow swarm "optimize performance" --strategy optimization`
|
||||
|
||||
## Agent Roles
|
||||
- Performance Profiler: Identifies bottlenecks
|
||||
- Memory Analyzer: Detects leaks
|
||||
- Code Optimizer: Implements improvements
|
||||
- Benchmark Runner: Measures impact
|
||||
|
||||
## Optimization Areas
|
||||
- Execution speed
|
||||
- Memory usage
|
||||
- Network efficiency
|
||||
- Bundle size
|
||||
@@ -0,0 +1,18 @@
|
||||
# Research Swarm Strategy
|
||||
|
||||
## Purpose
|
||||
Deep research through parallel information gathering.
|
||||
|
||||
## Activation
|
||||
`./claude-flow swarm "research topic X" --strategy research`
|
||||
|
||||
## Agent Roles
|
||||
- Web Researcher: Searches online sources
|
||||
- Academic Researcher: Analyzes papers
|
||||
- Data Analyst: Processes findings
|
||||
- Report Writer: Synthesizes results
|
||||
|
||||
## Research Methods
|
||||
- Parallel web searches
|
||||
- Cross-reference validation
|
||||
- Source credibility assessment
|
||||
@@ -0,0 +1,19 @@
|
||||
# Testing Swarm Strategy
|
||||
|
||||
## Purpose
|
||||
Comprehensive testing through distributed execution.
|
||||
|
||||
## Activation
|
||||
`./claude-flow swarm "test application" --strategy testing`
|
||||
|
||||
## Agent Roles
|
||||
- Unit Tester: Tests individual components
|
||||
- Integration Tester: Validates interactions
|
||||
- E2E Tester: Tests user flows
|
||||
- Performance Tester: Measures metrics
|
||||
- Security Tester: Finds vulnerabilities
|
||||
|
||||
## Test Coverage
|
||||
- Code coverage analysis
|
||||
- Edge case identification
|
||||
- Regression prevention
|
||||
@@ -0,0 +1,9 @@
|
||||
# Training Commands
|
||||
|
||||
Commands for training operations in Claude Flow.
|
||||
|
||||
## Available Commands
|
||||
|
||||
- [neural-train](./neural-train.md)
|
||||
- [pattern-learn](./pattern-learn.md)
|
||||
- [model-update](./model-update.md)
|
||||
@@ -0,0 +1,25 @@
|
||||
# model-update
|
||||
|
||||
Update neural models with new data.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow training model-update [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--model <name>` - Model to update
|
||||
- `--incremental` - Incremental update
|
||||
- `--validate` - Validate after update
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Update all models
|
||||
npx claude-flow training model-update
|
||||
|
||||
# Specific model
|
||||
npx claude-flow training model-update --model agent-selector
|
||||
|
||||
# Incremental with validation
|
||||
npx claude-flow training model-update --incremental --validate
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# neural-train
|
||||
|
||||
Train neural patterns from operations.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow training neural-train [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--data <source>` - Training data source
|
||||
- `--model <name>` - Target model
|
||||
- `--epochs <n>` - Training epochs
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Train from recent ops
|
||||
npx claude-flow training neural-train --data recent
|
||||
|
||||
# Specific model
|
||||
npx claude-flow training neural-train --model task-predictor
|
||||
|
||||
# Custom epochs
|
||||
npx claude-flow training neural-train --epochs 100
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# pattern-learn
|
||||
|
||||
Learn patterns from successful operations.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow training pattern-learn [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--source <type>` - Pattern source
|
||||
- `--threshold <score>` - Success threshold
|
||||
- `--save <name>` - Save pattern set
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Learn from all ops
|
||||
npx claude-flow training pattern-learn
|
||||
|
||||
# High success only
|
||||
npx claude-flow training pattern-learn --threshold 0.9
|
||||
|
||||
# Save patterns
|
||||
npx claude-flow training pattern-learn --save optimal-patterns
|
||||
```
|
||||
@@ -0,0 +1,9 @@
|
||||
# Workflows Commands
|
||||
|
||||
Commands for workflows operations in Claude Flow.
|
||||
|
||||
## Available Commands
|
||||
|
||||
- [workflow-create](./workflow-create.md)
|
||||
- [workflow-execute](./workflow-execute.md)
|
||||
- [workflow-export](./workflow-export.md)
|
||||
@@ -0,0 +1,25 @@
|
||||
# workflow-create
|
||||
|
||||
Create reusable workflow templates.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow workflow create [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--name <name>` - Workflow name
|
||||
- `--from-history` - Create from history
|
||||
- `--interactive` - Interactive creation
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Create workflow
|
||||
npx claude-flow workflow create --name "deploy-api"
|
||||
|
||||
# From history
|
||||
npx claude-flow workflow create --name "test-suite" --from-history
|
||||
|
||||
# Interactive mode
|
||||
npx claude-flow workflow create --interactive
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# workflow-execute
|
||||
|
||||
Execute saved workflows.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow workflow execute [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--name <name>` - Workflow name
|
||||
- `--params <json>` - Workflow parameters
|
||||
- `--dry-run` - Preview execution
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Execute workflow
|
||||
npx claude-flow workflow execute --name "deploy-api"
|
||||
|
||||
# With parameters
|
||||
npx claude-flow workflow execute --name "test-suite" --params '{"env": "staging"}'
|
||||
|
||||
# Dry run
|
||||
npx claude-flow workflow execute --name "deploy-api" --dry-run
|
||||
```
|
||||
@@ -0,0 +1,25 @@
|
||||
# workflow-export
|
||||
|
||||
Export workflows for sharing.
|
||||
|
||||
## Usage
|
||||
```bash
|
||||
npx claude-flow workflow export [options]
|
||||
```
|
||||
|
||||
## Options
|
||||
- `--name <name>` - Workflow to export
|
||||
- `--format <type>` - Export format
|
||||
- `--include-history` - Include execution history
|
||||
|
||||
## Examples
|
||||
```bash
|
||||
# Export workflow
|
||||
npx claude-flow workflow export --name "deploy-api"
|
||||
|
||||
# As YAML
|
||||
npx claude-flow workflow export --name "test-suite" --format yaml
|
||||
|
||||
# With history
|
||||
npx claude-flow workflow export --name "deploy-api" --include-history
|
||||
```
|
||||
Loaded 100 of 164 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user