Skip to main content

Overview

Parallel execution allows running multiple task attempts simultaneously, dramatically reducing total execution time. Perfect for comparing approaches or working on independent tasks.
Speed boost: Run 3 attempts in parallel = 3x faster than sequential execution!

Why Parallel Execution?

Sequential (Slow)

Parallel (Fast)

Result: 2.4x faster!

Basic Parallel Execution

Via CLI

Via SDK


Advanced Parallel Patterns

Parallel Task Creation

Create and start multiple tasks at once:

Parallel Comparison

Compare multiple agents on the same task:

Resource Management

Concurrency Limits

Don’t run too many at once:

Rate Limiting

Respect API rate limits:

Git Worktree Isolation

Each parallel attempt gets its own worktree:
Benefits:
  • No conflicts between attempts
  • Safe parallel modifications
  • Easy to compare results
Automatic cleanup:

Monitoring Parallel Execution

Real-Time Dashboard

Progress Aggregation


Error Handling

Graceful Degradation

Timeout Handling


Cost Optimization

Smart Parallel Strategy


Batch Operations

Bulk Task Processing

Parallel Template Execution


Real-World Examples

Example 1: A/B/C Testing

Example 2: Multi-Platform Development


Best Practices

Limit Concurrency

Handle Failures

Monitor Resources

Clean Up


Performance Metrics

Track parallel execution performance:

Next Steps

Specialized Agents

Run different agents in parallel

Task Templates

Templates with parallel tasks

Processes API

Monitor parallel executions

Workflows

Complete workflows with parallelism