Isolate parallel tasks

On this page

Choose how to separate agents before asking them to make overlapping changes.

Before you start

Use a Git repository with a committed starting point. Decide whether agents are collaborating on different files or producing alternative implementations of the same change.

Collaborate in one checkout

  1. Launch agents in the same workspace.
  2. Assign a distinct file or directory scope to each writer.
  3. Identify one agent to integrate the results and run the combined checks.
  4. Ask writers to report any change that would cross another agent's ownership boundary before making it.

This is the route used by Code Overlord's reviewed built-in delegation workflow. Ownership is an instruction, not filesystem isolation.

Open independent checkouts

For competing implementations, clone the repository into two separate folders using your normal repository URL. Open each clone as its own Code Overlord workspace.

  1. Confirm both clones start from the same committed revision.
  2. Create a distinct feature branch in each clone, such as experiment-a and experiment-b.
  3. Launch a base Grunt in each workspace and verify its working directory and branch before editing.
  4. Install dependencies and configure local environment files for each checkout. Use different ports for simultaneously running development servers.
  5. Give both agents the same task and acceptance criteria.
  6. Review and test the alternatives separately. Integrate the chosen result through your normal branch and pull-request process.

Each clone has its own Git metadata and working files. Uncommitted edits in the original checkout are not automatically included; preserve the intended starting point before creating the experiments.

Keep a coordinator over separate copies

The video uses a second arrangement: keep the coordinator in the original project and ask it to launch each worker with the exact path to a different full clone. Give each copy its own branch and assign a bounded job to each worker.

  1. Have the coordinator create the local clones and verify their starting revision before launching workers.
  2. In the launch instruction, name each worker’s full working directory and the files it may change.
  3. Select each worker in Code Overlord. Its folder label, reported working directory and Git branch should agree. Confirm a new project’s folder-trust prompt if the coding agent requests it.
  4. Inspect each worker’s actual diff, then have the coordinator verify both copies and the unchanged original. The worker’s session menu links back to its coordinator under Ancestors.

Separate copies prevent these working files from overlapping. They do not restrict an agent’s filesystem permissions. In the recording, one worker needed a restart at its folder-trust prompt; the other copy’s completed work remained intact.

Use worktrees through Git

Git also supports a lighter alternative with shared repository metadata. From the original repository root, the following creates worktrees from the current commit. Choose unused names and paths:

git worktree add -b experiment-a ../app-experiment-a HEAD
git worktree add -b experiment-b ../app-experiment-b HEAD
git worktree list

These are ordinary Git operations, not Code Overlord worktree controls. The reviewed desktop repository scanner looks for a .git directory; linked worktrees use a .git file. They therefore are not a verified route to the app's normal repository discovery and Review UI. Use the separate-clone recipe above when you need that integrated workflow. See the Git worktree reference.

For CLI-only work in a prepared worktree, launch the agent in that exact directory and use Git's own review and cleanup commands. Avoid saved workflows whose instructions prohibit worktrees.

Example instruction

Work only in this experiment directory and branch. Implement the empty-state fix and run the relevant tests. Leave the result for comparison; report the changed files and test results.

Check the result

A change made in one experiment directory should not appear in the other's working files. Confirm the branch and diff in each clone, then run the same checks against both results. Preserve the selected work before stopping sessions and cleaning up experiments.

Where the approach differs

Code Overlord does not document Orca-style automatic worktree creation, comparison and cleanup. The clone recipe uses ordinary Git and workspace launching; it does not provide container or process isolation.

More detail

Workspaces · Git History