How Do You Run Multiple Claude Agents in Parallel with Ruflo?
Problem
I was stuck in a sequential AI workflow. Every time I needed to build a feature, I’d ask Claude to do one thing, wait for it to finish, then ask for the next thing. My development process looked like this:
Time →
Task 1 (API) ████████████░░░░░░░░░░░░░░░░░░░░Task 2 (Tests) ░░░░░░░░░░░░░░████████████░░░░░░░░Task 3 (Docs) ░░░░░░░░░░░░░░░░░░░░░░░░░████████
Total: ~30 minutes of waitingI’d spend 30 minutes just waiting for tasks to complete one after another. The bottleneck wasn’t Claude’s capability - it was my workflow. I was using Claude like a single assistant when I needed a team.
What happened?
I found a Reddit thread about Ruflo that mentioned the “delegate like a manager” workflow. One comment stood out:
"Ruflo runs swarms of Claude agents on your project in parallel.This is the closest I've found to the 'delegate like a manager'workflow actually working."I realized I’d been thinking about AI wrong. Instead of treating Claude as one assistant, I should treat it as multiple specialists I can delegate to simultaneously.
The difference is fundamental:
ASSISTANT MINDSET:"I need help with X" → Claude does X → "Now help with Y" → Claude does Y
MANAGER MINDSET:"I need X, Y, and Z done" → Delegate to Agent 1 (X), Agent 2 (Y), Agent 3 (Z)→ Review all results togetherWhat is Ruflo?
Ruflo is a Claude Code plugin that spawns multiple Claude instances to work on your project simultaneously. Instead of one Claude doing one task at a time, you get multiple agents working in parallel.
I installed it and tried my first parallel workflow:
# Install Ruflopip install ruflo
# Run multiple agents on a taskruflo run --agents 3 "Build user authentication with tests and docs"The output showed three agents working:
Agent 1 [API]: Creating /auth/login endpoint...Agent 2 [Tests]: Writing test cases for auth module...Agent 3 [Docs]: Generating API documentation...
All agents completed in 12 minutesWhat would have taken 30+ minutes sequentially took 12 minutes with parallel execution.
How Parallel Execution Works
The key insight is that many development tasks are independent. When I’m building a feature, the backend API, frontend components, tests, and documentation don’t necessarily depend on each other during the initial creation phase.
Here’s how I now structure parallel workflows:
┌─────────────────┐ │ Developer │ │ (Single Task) │ └────────┬────────┘ │ ┌──────────────┼──────────────┐ │ │ │ ▼ ▼ ▼ ┌─────────┐ ┌─────────┐ ┌─────────┐ │ Agent 1 │ │ Agent 2 │ │ Agent 3 │ │ API │ │ Tests │ │ Docs │ └────┬────┘ └────┬────┘ └────┬────┘ │ │ │ └──────────────┼──────────────┘ │ ▼ ┌─────────────────┐ │ Integration │ │ Review │ └─────────────────┘The wall-clock time becomes max(task times) + integration overhead instead of sum(all task times).
Use Cases I Tested
I tried several parallel execution patterns:
1. Feature Development
Agent 1: Backend API endpointsAgent 2: Frontend componentsAgent 3: Test suiteAgent 4: DocumentationI ran this for a user profile feature. Each agent worked independently on its part. The only coordination needed was agreeing on the API contract upfront.
2. Code Review
Agent 1: Security reviewAgent 2: Performance analysisAgent 3: Code style consistencyThis pattern replaced my usual “one comprehensive review” with specialized perspectives. I caught a security issue and a performance problem that a single agent might have missed.
3. Research Tasks
Agent 1: Technology A evaluationAgent 2: Technology B evaluationAgent 3: Technology C evaluationI used this to compare three database options. Each agent researched one option deeply, then I synthesized the results.
The “Delegate Like a Manager” Workflow
This is the core pattern that changed how I work with Claude.
Traditional Sequential Workflow:
Iteration 1: Me: "Write API endpoint" Claude: [writes API] Me: [reviews]
Iteration 2: Me: "Write tests" Claude: [writes tests] Me: [reviews]
Iteration 3: Me: "Write docs" Claude: [writes docs] Me: [reviews]
Total: 3 × (task time + review time)Parallel Manager Workflow:
Single Iteration: Me: "Build user API with tests and docs"
Ruflo orchestrates: API Agent + Tests Agent + Docs Agent (simultaneous)
Me: [reviews integrated result]
Total: 1 × (max task time + review time)The mental shift is significant. Instead of micromanaging each step, I define the outcome and let the agents coordinate.
Common Pitfalls I Hit
I made several mistakes when starting with parallel agents.
Pitfall 1: Over-Parallelization
I tried running 10 agents at once for a complex feature. The result was chaos:
Agent 1: Created User modelAgent 2: Created UserProfile model (conflicting with Agent 1)Agent 3: Wrote tests for non-existent endpointsAgent 4: Created docs for wrong API version...Integration: 45 minutes of fixing conflictsI learned that 3-4 agents is the sweet spot. Beyond that, coordination overhead outweighs speed gains.
Pitfall 2: Ignoring Dependencies
I tried parallel execution for a feature where the frontend depended on the backend API:
Agent 1 [Backend]: Created /api/users endpointAgent 2 [Frontend]: Failed - endpoint doesn't exist yet
Result: Frontend agent wasted time waitingNow I identify dependencies upfront. If Task B depends on Task A, they run sequentially. Independent tasks run in parallel.
Pitfall 3: Context Fragmentation
Each agent only sees part of the project context. I had this issue:
Agent 1 [API]: Used PostgreSQL-specific syntaxAgent 2 [Tests]: Wrote tests assuming MySQL
Result: Tests failed on CI which uses MySQLI now include project-wide context in each agent’s instructions:
Project uses:- PostgreSQL in development- MySQL in production- All SQL must be database-agnosticPitfall 4: Rate Limit Exhaustion
Running 5 agents in parallel means 5x API calls. I hit rate limits:
Error: Rate limit exceeded (429)Current usage: 95,000 tokens/minuteLimit: 100,000 tokens/minuteI reduced parallel agents to 3 and added retry logic. I also spread work across different time windows when possible.
Pitfall 5: Integration Chaos
Merging outputs from 4 agents into one codebase created conflicts:
CONFLICT: Both Agent 1 and Agent 3 modified routes/index.jsCONFLICT: Agent 2 and Agent 4 both created tests/setup.jsI learned to assign agents to distinct files or modules. No two agents should modify the same file.
Sequential vs Parallel: When to Use Each
After testing both approaches, I made a decision guide:
| Task Type | Best Approach | Reason |
|---|---|---|
| Independent features | Parallel | No dependencies between agents |
| Bug fixes (single file) | Sequential | One agent, one file |
| Large refactors | Sequential | Changes are highly coupled |
| Documentation | Parallel | Different docs can be written simultaneously |
| Testing | Parallel | Tests for different features are independent |
| Research | Parallel | Multiple perspectives simultaneously |
| Code review | Parallel | Different review aspects are independent |
The key question I ask: “Can these tasks be done without knowing each other’s results?”
If yes, parallel. If no, sequential.
My Current Workflow
I now use this decision tree:
Start │ ▼Is the task complex (3+ subtasks)? │ ├─ No → Sequential (single agent) │ └─ Yes → Are subtasks independent? │ ├─ No → Sequential (dependencies) │ └─ Yes → Can I define clear boundaries? │ ├─ No → Sequential (risk of conflicts) │ └─ Yes → Parallel with Ruflo │ ▼ Limit to 3-4 agents Assign distinct files/modules Include shared contextThis flow prevents most of the pitfalls I encountered.
Summary
In this post, I showed how to run multiple Claude agents in parallel using Ruflo. The key point is the “delegate like a manager” workflow: instead of giving Claude one task at a time, you orchestrate multiple agents working simultaneously on independent tasks.
The main takeaways:
- Parallel execution reduces total time from
sum(task times)tomax(task time) + overhead - 3-4 agents is optimal; more creates coordination chaos
- Identify dependencies upfront; independent tasks only for parallel execution
- Each agent needs project-wide context to avoid conflicts
- Assign agents to distinct files/modules to prevent merge conflicts
Ruflo transformed my AI workflow from “waiting for an assistant” to “managing a team.” The bottleneck shifted from execution time to my ability to define clear, independent tasks.
Final Words + More Resources
My intention with this article was to help others share my knowledge and experience. If you want to contact me, you can contact by email: Email me
Here are also the most important links from this article along with some further resources that will help you in this scope:
Oh, and if you found these resources useful, don’t forget to support me by starring the repo on GitHub!
Comments