<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Levi</title>
    <description>The latest articles on DEV Community by Levi (@levitc).</description>
    <link>https://dev.to/levitc</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3864354%2F5130f60c-cbd8-46dd-a0ca-58915313f684.png</url>
      <title>DEV Community: Levi</title>
      <link>https://dev.to/levitc</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/levitc"/>
    <language>en</language>
    <item>
      <title>I Let 5 AI Agents Loose on One Repo. It Was a Disaster. So I Built This.</title>
      <dc:creator>Levi</dc:creator>
      <pubDate>Fri, 10 Apr 2026 19:46:48 +0000</pubDate>
      <link>https://dev.to/levitc/i-let-5-ai-agents-loose-on-one-repo-it-was-a-disaster-so-i-built-this-k3</link>
      <guid>https://dev.to/levitc/i-let-5-ai-agents-loose-on-one-repo-it-was-a-disaster-so-i-built-this-k3</guid>
      <description>&lt;p&gt;Last month I tried something ambitious: split a feature across five AI coding agents running in parallel. Claude Code on auth. Aider on the API. Codex on tests. Two more on frontend components.&lt;/p&gt;

&lt;p&gt;Within 90 seconds, three of them had edited &lt;code&gt;src/index.ts&lt;/code&gt;. Two had conflicting changes to the same utility function. One had deleted a file another was importing.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The merge was unfixable.&lt;/strong&gt; I lost an hour untangling it, then threw everything away and did it sequentially. One agent at a time. Like it's 2024.&lt;/p&gt;

&lt;p&gt;That experience broke something in my brain. AI agents are fast enough to work in parallel — but our tooling assumes they work alone. So I built the missing piece.&lt;/p&gt;

&lt;h2&gt;
  
  
  The Problem Nobody Talks About
&lt;/h2&gt;

&lt;p&gt;Every AI coding tool — Claude Code, Cursor, Aider, Codex, Windsurf — operates with a mental model of "one agent, one repo." And that's fine for solo tasks.&lt;/p&gt;

&lt;p&gt;But the moment you want parallelism — the thing that &lt;em&gt;should&lt;/em&gt; make AI 5x faster — you hit the wall:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;No workspace isolation.&lt;/strong&gt; Agents share a checkout. One agent's &lt;code&gt;git stash&lt;/code&gt; nukes another's work.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No file ownership.&lt;/strong&gt; Two agents rewrite the same module with zero awareness of each other.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No merge strategy.&lt;/strong&gt; You're the merge strategy. At 2am. With conflicting diffs you didn't write.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No dependency ordering.&lt;/strong&gt; The frontend agent starts before the API it depends on exists.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Git branches help with history isolation. But branches don't prevent two agents from touching the same files. They just defer the pain to merge time.&lt;/p&gt;

&lt;h2&gt;
  
  
  Ruah Orch: Parallel Agents That Don't Collide
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://github.com/ruah-dev/ruah-orch" rel="noopener noreferrer"&gt;Ruah Orch&lt;/a&gt; is an open-source orchestration engine that coordinates multiple AI agents working on the same repository. Each task gets:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;1. An isolated workspace&lt;/strong&gt; (Git worktree — a real checkout, not a branch)&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ruah task create auth &lt;span class="nt"&gt;--files&lt;/span&gt; &lt;span class="s2"&gt;"src/auth/**"&lt;/span&gt; &lt;span class="nt"&gt;--executor&lt;/span&gt; claude-code
ruah task create api  &lt;span class="nt"&gt;--files&lt;/span&gt; &lt;span class="s2"&gt;"src/api/**"&lt;/span&gt;  &lt;span class="nt"&gt;--executor&lt;/span&gt; aider
ruah task create ui   &lt;span class="nt"&gt;--files&lt;/span&gt; &lt;span class="s2"&gt;"src/ui/**"&lt;/span&gt;   &lt;span class="nt"&gt;--executor&lt;/span&gt; claude-code
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;2. File locks checked &lt;em&gt;before&lt;/em&gt; agents start&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ruah task create utils &lt;span class="nt"&gt;--files&lt;/span&gt; &lt;span class="s2"&gt;"src/utils/**"&lt;/span&gt;
&lt;span class="c"&gt;# ERROR: Lock conflict with task 'auth' on src/utils/helpers.ts&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;No more discovering conflicts after an agent has been running for 10 minutes. Ruah rejects overlapping file claims at creation time.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;3. Smart parallel execution with dependency ordering&lt;/strong&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight markdown"&gt;&lt;code&gt;&lt;span class="gh"&gt;# workflow.md&lt;/span&gt;

backend:
  files: src/api/&lt;span class="ge"&gt;**&lt;/span&gt;
  executor: claude-code
  prompt: "Build REST endpoints for user management"

frontend:
  files: src/ui/&lt;span class="ge"&gt;**&lt;/span&gt;
  executor: claude-code
  parallel: true
  prompt: "Build user profile components"

integration-tests:
  files: tests/&lt;span class="ge"&gt;**&lt;/span&gt;
  depends: [backend, frontend]
  executor: aider
  prompt: "Write integration tests for the user flow"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ruah workflow run workflow.md
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Ruah builds a DAG, validates there are no cycles, checks for file conflicts, then runs &lt;code&gt;backend&lt;/code&gt; and &lt;code&gt;frontend&lt;/code&gt; in parallel. &lt;code&gt;integration-tests&lt;/code&gt; waits until both are done.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;4. Contract enforcement before merge&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Tasks can declare modification contracts:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;owned&lt;/code&gt; — only this task touches these files&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;shared-append&lt;/code&gt; — append only, no deletions&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;read-only&lt;/code&gt; — hands off&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Violations are caught &lt;em&gt;before&lt;/em&gt; merge, not after.&lt;/p&gt;

&lt;h2&gt;
  
  
  It Works With Everything
&lt;/h2&gt;

&lt;p&gt;Ruah isn't tied to one AI tool. It ships with executor adapters for:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Executor&lt;/th&gt;
&lt;th&gt;Tool&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;claude-code&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Claude Code CLI&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;aider&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Aider&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;codex&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;OpenAI Codex CLI&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;code&gt;script&lt;/code&gt;&lt;/td&gt;
&lt;td&gt;Any shell command&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Mix and match. Use Claude Code for complex architecture and Aider for quick edits. Ruah doesn't care — it manages workspaces, not agents.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ruah task create backend &lt;span class="nt"&gt;--executor&lt;/span&gt; claude-code &lt;span class="nt"&gt;--prompt&lt;/span&gt; &lt;span class="s2"&gt;"Design the auth system"&lt;/span&gt;
ruah task create docs    &lt;span class="nt"&gt;--executor&lt;/span&gt; aider        &lt;span class="nt"&gt;--prompt&lt;/span&gt; &lt;span class="s2"&gt;"Write API documentation"&lt;/span&gt;
ruah task create tests   &lt;span class="nt"&gt;--executor&lt;/span&gt; codex        &lt;span class="nt"&gt;--prompt&lt;/span&gt; &lt;span class="s2"&gt;"Add unit test coverage"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  The 5-Minute Version
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# Install&lt;/span&gt;
npm &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="nt"&gt;-g&lt;/span&gt; @ruah-dev/orch

&lt;span class="c"&gt;# Initialize in your repo&lt;/span&gt;
&lt;span class="nb"&gt;cd &lt;/span&gt;your-project
ruah init

&lt;span class="c"&gt;# Create parallel tasks with file isolation&lt;/span&gt;
ruah task create auth    &lt;span class="nt"&gt;--files&lt;/span&gt; &lt;span class="s2"&gt;"src/auth/**"&lt;/span&gt;    &lt;span class="nt"&gt;--executor&lt;/span&gt; claude-code
ruah task create payments &lt;span class="nt"&gt;--files&lt;/span&gt; &lt;span class="s2"&gt;"src/payments/**"&lt;/span&gt; &lt;span class="nt"&gt;--executor&lt;/span&gt; claude-code

&lt;span class="c"&gt;# Start them (each gets its own worktree)&lt;/span&gt;
ruah task start auth
ruah task start payments

&lt;span class="c"&gt;# When done, merge cleanly&lt;/span&gt;
ruah task &lt;span class="k"&gt;done &lt;/span&gt;auth
ruah task merge auth

ruah task &lt;span class="k"&gt;done &lt;/span&gt;payments
ruah task merge payments
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's it. Two agents, working in parallel, zero collisions, clean merges.&lt;/p&gt;

&lt;h2&gt;
  
  
  What Happens Under the Hood
&lt;/h2&gt;

&lt;p&gt;When you run &lt;code&gt;ruah task start auth&lt;/code&gt;:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Worktree created&lt;/strong&gt; — A real Git worktree at &lt;code&gt;.ruah/worktrees/auth/&lt;/code&gt;, branched from your current HEAD&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Locks acquired&lt;/strong&gt; — &lt;code&gt;src/auth/**&lt;/code&gt; is claimed. No other task can touch these files&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Environment injected&lt;/strong&gt; — The agent receives &lt;code&gt;RUAH_TASK&lt;/code&gt;, &lt;code&gt;RUAH_WORKTREE&lt;/code&gt;, &lt;code&gt;RUAH_FILES&lt;/code&gt;, &lt;code&gt;RUAH_ROOT&lt;/code&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Executor launched&lt;/strong&gt; — Claude Code (or Aider, or your script) starts in the isolated worktree&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Artifacts captured&lt;/strong&gt; — Changed files, patches, and commit metadata are persisted to &lt;code&gt;.ruah/state.json&lt;/code&gt;
&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;When you &lt;code&gt;ruah task merge auth&lt;/code&gt;:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Contracts validated&lt;/strong&gt; — Did the agent stay within its file boundaries?&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Governance gates run&lt;/strong&gt; — If you have quality gates (linting, tests, type checking), they run automatically&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Clean merge&lt;/strong&gt; — Changes merge into your base branch. No surprises.&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Subtasks: Agents Spawning Agents
&lt;/h2&gt;

&lt;p&gt;Here's where it gets interesting. A parent task can spawn child tasks:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;ruah task create auth-api &lt;span class="nt"&gt;--parent&lt;/span&gt; auth &lt;span class="nt"&gt;--files&lt;/span&gt; &lt;span class="s2"&gt;"src/auth/api/**"&lt;/span&gt;
ruah task create auth-ui  &lt;span class="nt"&gt;--parent&lt;/span&gt; auth &lt;span class="nt"&gt;--files&lt;/span&gt; &lt;span class="s2"&gt;"src/auth/ui/**"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Children branch from the parent (not main), inherit its context, and merge back into the parent. The parent then merges into main. It's turtles all the way down — but organized turtles.&lt;/p&gt;

&lt;h2&gt;
  
  
  Zero Dependencies. Zero Network. Zero Risk.
&lt;/h2&gt;

&lt;p&gt;Ruah has &lt;strong&gt;zero runtime dependencies&lt;/strong&gt;. The &lt;code&gt;node_modules&lt;/code&gt; after install? Just dev tools. The binary is pure TypeScript compiled to ESM.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;No network calls (unless you explicitly opt into update checks)&lt;/li&gt;
&lt;li&gt;No secrets stored&lt;/li&gt;
&lt;li&gt;No shell injection risk (array-form process spawning)&lt;/li&gt;
&lt;li&gt;MIT licensed&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Your code never leaves your machine. Ruah just manages workspaces and state.&lt;/p&gt;

&lt;h2&gt;
  
  
  Built-in Safety Net
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;&lt;span class="c"&gt;# Health check everything&lt;/span&gt;
ruah doctor

&lt;span class="c"&gt;# See what's running&lt;/span&gt;
ruah status

&lt;span class="c"&gt;# Clean up stale tasks and orphaned worktrees&lt;/span&gt;
ruah clean

&lt;span class="c"&gt;# Preview a workflow without executing&lt;/span&gt;
ruah workflow run plan.md &lt;span class="nt"&gt;--dry-run&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  When Should You Use This?
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Use Ruah when:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You're splitting features across multiple AI agents&lt;/li&gt;
&lt;li&gt;You want parallelism without merge hell&lt;/li&gt;
&lt;li&gt;You use more than one AI coding tool&lt;/li&gt;
&lt;li&gt;Your team has AI agents running on shared repos&lt;/li&gt;
&lt;li&gt;You're building agentic workflows that decompose tasks&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;strong&gt;Don't use Ruah when:&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;You're running a single agent on a single task (just use the agent directly)&lt;/li&gt;
&lt;li&gt;Your changes are all in one file (no isolation needed)&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  What's Next
&lt;/h2&gt;

&lt;p&gt;Ruah Orch is Phase 1. The orchestration layer. Coming next:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Ruah Architect&lt;/strong&gt; — Feed it a PRD or GitHub issue, get a parallelized workflow back&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ruah Guard&lt;/strong&gt; — Policy engine for what agents can and can't do&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ruah Observe&lt;/strong&gt; — Tracing and observability for multi-agent runs&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ruah Studio&lt;/strong&gt; — Visual UI for watching agents work in real-time&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;But Orch is shipping now, it's stable, and it solves the #1 pain point: &lt;strong&gt;agents that don't step on each other.&lt;/strong&gt;&lt;/p&gt;






&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;npm &lt;span class="nb"&gt;install&lt;/span&gt; &lt;span class="nt"&gt;-g&lt;/span&gt; @ruah-dev/orch
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;a href="https://github.com/ruah-dev/ruah-orch" rel="noopener noreferrer"&gt;GitHub&lt;/a&gt; | &lt;a href="https://www.npmjs.com/package/@ruah-dev/orch" rel="noopener noreferrer"&gt;npm&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you've felt the pain of merging parallel AI agent work, give it a try. Stars welcome. Issues more welcome. PRs most welcome.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Have you tried running multiple AI agents in parallel? What was your experience? Drop a comment — I'd love to hear your war stories.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>ai</category>
      <category>opensource</category>
      <category>programming</category>
      <category>productivity</category>
    </item>
  </channel>
</rss>
