Auten gives your AI agent hands: it clicks, types and reads a real screen on your computer (Mac/Windows/Linux) and Android phone (beta). Works with any MCP client.
To your question: in our setup the expensive collisions were never in the repo. We run three agent sessions in parallel on one machine, and the two that cost the most time were:
Duplicate work. Two sessions picked up the same task from a shared notes file, because "read the notes first" was advice, not a gate. What fixed it was an explicit claim step: a task is claimed (who, when) before any work starts, and a stale claim has to be taken over visibly, not silently redone. Your intent publish is the same idea one level up, with scopes instead of task ids.
Shared resources that are not files at all: one screen and mouse, one logged-in browser profile, one test phone. Worktrees give each agent its own checkout, but if two agents drive the same GUI, one types into the other's window. We ended up with a lease (acquire before touching the GUI, release after, a holder that goes quiet for ~30 s counts as dead) rather than a merge-time check, because by merge time the damage is a sent message, not a diff.
So I'd add "anything with side effects outside the repo" to your list of things worktrees don't isolate. On scope hierarchy: a class-level replace matching every method-level scope under it sounds like exactly the pair your PaymentService example needs.
Building Foremerge (open-source coordination for parallel coding agents, above Git) and GPTree. I write up what the agents broke and what actually fixed it.
Auten gives your AI agent hands: it clicks, types and reads a real screen on your computer (Mac/Windows/Linux) and Android phone (beta). Works with any MCP client.
Yes, anything where the damage happens outside the repo and can't be merged away. The ones that bit us, roughly in order:
Logged-in accounts and rate limits. Two agents posting or emailing from the same account share one daily limit and one reputation. We keep a per-account counter both have to check before acting, and a shared "already answered" log keyed by the message id so the same inbound item never gets two replies.
Login state. A browser profile or a token refresh is shared state: one agent logging out or rotating a token silently breaks the other. One owner per profile, the others ask it.
Physical devices. A test phone is the same problem as the screen, one lease per device.
Local ports and dev servers, databases with fixtures. Cheaper fix there: give each agent its own port range or schema instead of a lock.
Rule of thumb we ended up with: if it can be duplicated per agent (port, DB schema, checkout), duplicate it; if it can't (one account, one phone, one screen), lease it and log every side effect.
Our costliest collision was agent-versus-gate, not agent-versus-agent: a batch of otherwise-clean commits swept a gated post onto the live site — no overlapping lines, every diff merged fine, and the outcome was still wrong, because the violation was against an intent, not against any text. That's "Git compares text, not intent" with receipts attached, and it's also why the fix wasn't task splitting: the checks that came in afterwards run on the merged result and look for policy breaks specifically. On your scope-hierarchy question — a whole-class change contradicting a method-level one is exactly the shape our incident had, one level up: file-level changes contradicting a repo-level rule. Nothing in any diff could ever have shown it.
Building Foremerge (open-source coordination for parallel coding agents, above Git) and GPTree. I write up what the agents broke and what actually fixed it.
This is exactly why we built Foremerge. Agents declare their intent and claim scopes before writing, so potential conflicts show up early, not just in the text. It helps catch those issues before they affect the merged output.
On the scope hierarchy question: matching a whole-class scope against a method scope matters a lot in practice. When one agent touches PaymentService#authenticate and another replaces PaymentService, every human reviewer reads that as one story, so flagging that overlap would catch exactly the merge-time failures git stays silent on.
Building Foremerge (open-source coordination for parallel coding agents, above Git) and GPTree. I write up what the agents broke and what actually fixed it.
How do you flag that overlap in your workflow? In Foremerge, agents log their intent and claim a scope before writing, so conflicts show up while it’s still a plan.
Honestly, mine is less tooling and more process: before an agent starts, I write the claimed scopes into a shared plans file, and I expand class-level claims into their method symbols so overlaps surface at comparison time. A whole-class replace claim against a method-level extend claim is exactly the pair I read as a red flag.
Building Foremerge (open-source coordination for parallel coding agents, above Git) and GPTree. I write up what the agents broke and what actually fixed it.
The question I’d most like answers to: if you run two or more agents on one repo, what are the collisions that cost you the most time? Was it two agents in the same file, or two that never touched the same file and still contradicted each other, like the PaymentService one above?
Also let me know whether scope hierarchy would matter for how you work: a change to a whole class not matching a change to one of its methods. It’s the biggest gap our own replay showed, and I’d rather build it from real cases.
A technologist working in automation. Here I write up what I actually learn building tools, engineering AI agents, and keeping systems running, along with the workflows and habits that stick.
The collision that costs me the most time across parallel sessions is contract drift on shared test fixtures and mock generators.Two agents get tasks on separate modules that both depend on a common factory or schema definition. One agent refactors a mock helper to satisfy a new nullable field, while the other updates an integration test assuming the old fixture signature. Neither touches the other's source files, Git merges the branches cleanly, and the failure only surfaces when the full test suite runs on the merged branch.The second messy failure mode is lockfile churn. Even with separate worktrees, if two agents add different packages around the same time, merging their pnpm or poetry lockfiles creates merge conflicts where automatic resolution silently drops dependencies or scrambles transitive pins. Enforcing that only the primary integrating branch runs package additions stopped the lockfile corruption.
Building Foremerge (open-source coordination for parallel coding agents, above Git) and GPTree. I write up what the agents broke and what actually fixed it.
We built Foremerge to address contract drift. It should solve your use case perfectly. Agents log their intent and claim a scope before they write, so conflicts show up while they're still plans. This helps catch issues before they impact the test suite.
Building Foremerge (open-source coordination for parallel coding agents, above Git) and GPTree. I write up what the agents broke and what actually fixed it.
If you’ve hit the replace-versus-extend failure (two agents, both correct, jointly wrong), I’d love to hear how you caught it. In our case it was the merged tests, a day later.
On your second bullet: in our setup each ticket gets its own branch, its own services and its own copy of the dev database, so two agents can run migrations at once without touching each other. That fixes the collisions you can see. It does nothing for the rest of your table: each ticket is green on its own stack, and the contradiction shows only once both land in dev. Does Foremerge treat a new migration as additive, or does shared numbering make two of them collide by default?
I build software for drilling robots and private AI that runs inside a company network. C++/Python, DDS, PLC, local LLMs. Founder, Yantrakar AS, Stavanger.
One more thing all worktrees share: the repo's git config. Every agent commits under the same name and email. With client and personal accounts on one laptop, that is where I kept getting the wrong author.
I ended up building a small open-source CLI for it, gitpro: it picks the identity from the remote URL, and it can add a Claude Code hook that refuses a commit or push under the wrong identity. I wrote up how it works here: dev.to/yantrakar/wrong-git-email-a...
We're a place where coders share, stay up-to-date and grow their careers.
To your question: in our setup the expensive collisions were never in the repo. We run three agent sessions in parallel on one machine, and the two that cost the most time were:
Duplicate work. Two sessions picked up the same task from a shared notes file, because "read the notes first" was advice, not a gate. What fixed it was an explicit claim step: a task is claimed (who, when) before any work starts, and a stale claim has to be taken over visibly, not silently redone. Your
intent publishis the same idea one level up, with scopes instead of task ids.Shared resources that are not files at all: one screen and mouse, one logged-in browser profile, one test phone. Worktrees give each agent its own checkout, but if two agents drive the same GUI, one types into the other's window. We ended up with a lease (acquire before touching the GUI, release after, a holder that goes quiet for ~30 s counts as dead) rather than a merge-time check, because by merge time the damage is a sent message, not a diff.
So I'd add "anything with side effects outside the repo" to your list of things worktrees don't isolate. On scope hierarchy: a class-level replace matching every method-level scope under it sounds like exactly the pair your PaymentService example needs.
the lease for GUI control makes sense, do you think other shared resources might need a similar approach?
Yes, anything where the damage happens outside the repo and can't be merged away. The ones that bit us, roughly in order:
Rule of thumb we ended up with: if it can be duplicated per agent (port, DB schema, checkout), duplicate it; if it can't (one account, one phone, one screen), lease it and log every side effect.
Our costliest collision was agent-versus-gate, not agent-versus-agent: a batch of otherwise-clean commits swept a gated post onto the live site — no overlapping lines, every diff merged fine, and the outcome was still wrong, because the violation was against an intent, not against any text. That's "Git compares text, not intent" with receipts attached, and it's also why the fix wasn't task splitting: the checks that came in afterwards run on the merged result and look for policy breaks specifically. On your scope-hierarchy question — a whole-class change contradicting a method-level one is exactly the shape our incident had, one level up: file-level changes contradicting a repo-level rule. Nothing in any diff could ever have shown it.
This is exactly why we built Foremerge. Agents declare their intent and claim scopes before writing, so potential conflicts show up early, not just in the text. It helps catch those issues before they affect the merged output.
foremerge.com
On the scope hierarchy question: matching a whole-class scope against a method scope matters a lot in practice. When one agent touches PaymentService#authenticate and another replaces PaymentService, every human reviewer reads that as one story, so flagging that overlap would catch exactly the merge-time failures git stays silent on.
How do you flag that overlap in your workflow? In Foremerge, agents log their intent and claim a scope before writing, so conflicts show up while it’s still a plan.
Honestly, mine is less tooling and more process: before an agent starts, I write the claimed scopes into a shared plans file, and I expand class-level claims into their method symbols so overlaps surface at comparison time. A whole-class replace claim against a method-level extend claim is exactly the pair I read as a red flag.
The question I’d most like answers to: if you run two or more agents on one repo, what are the collisions that cost you the most time? Was it two agents in the same file, or two that never touched the same file and still contradicted each other, like the PaymentService one above?
Also let me know whether scope hierarchy would matter for how you work: a change to a whole class not matching a change to one of its methods. It’s the biggest gap our own replay showed, and I’d rather build it from real cases.
The collision that costs me the most time across parallel sessions is contract drift on shared test fixtures and mock generators.Two agents get tasks on separate modules that both depend on a common factory or schema definition. One agent refactors a mock helper to satisfy a new nullable field, while the other updates an integration test assuming the old fixture signature. Neither touches the other's source files, Git merges the branches cleanly, and the failure only surfaces when the full test suite runs on the merged branch.The second messy failure mode is lockfile churn. Even with separate worktrees, if two agents add different packages around the same time, merging their pnpm or poetry lockfiles creates merge conflicts where automatic resolution silently drops dependencies or scrambles transitive pins. Enforcing that only the primary integrating branch runs package additions stopped the lockfile corruption.
We built Foremerge to address contract drift. It should solve your use case perfectly. Agents log their intent and claim a scope before they write, so conflicts show up while they're still plans. This helps catch issues before they impact the test suite.
foremerge.com
If you’ve hit the replace-versus-extend failure (two agents, both correct, jointly wrong), I’d love to hear how you caught it. In our case it was the merged tests, a day later.
On your second bullet: in our setup each ticket gets its own branch, its own services and its own copy of the dev database, so two agents can run migrations at once without touching each other. That fixes the collisions you can see. It does nothing for the rest of your table: each ticket is green on its own stack, and the contradiction shows only once both land in dev. Does Foremerge treat a new migration as additive, or does shared numbering make two of them collide by default?
One more thing all worktrees share: the repo's git config. Every agent commits under the same name and email. With client and personal accounts on one laptop, that is where I kept getting the wrong author.
I ended up building a small open-source CLI for it, gitpro: it picks the identity from the remote URL, and it can add a Claude Code hook that refuses a commit or push under the wrong identity. I wrote up how it works here: dev.to/yantrakar/wrong-git-email-a...