skip to content
agentmash get started

claude code for teams.

when several developers each run Claude Code on one repository, every agent works from what it read and knows nothing of the others. agentmash adds hooks to each developer’s Claude Code that report every edit to one room for the repository, and tell an agent what teammates’ agents are changing before it edits.

what goes wrong without it

edits collide: two agents touch the same file, one breaks the interface the other is building against, both write the same helper.

what each hook adds

PreToolUse
before each edit, it checks the room. if a teammate’s agent touched the same file, or changed a symbol your file depends on anywhere in the repo, the advisory goes into your agent’s context, graded by severity.
PostToolUse
reports every Write, Edit and MultiEdit to the room, with the exported symbols the edit changed. it runs in the background, so the edit doesn’t wait for it.
UserPromptSubmit
sends the first 500 characters of your prompt as a task hint, so every event says what a teammate is doing, not only which files. at a prompt, your agent also gets a short heads-up when a teammate’s agent is on your branch or in a file your session changed: at most once every ten minutes, and only when that’s news.
SessionStart
the same heads-up when a session starts, or its context is cleared or compacted.
Stop
if a file this session edited was also edited by someone else, the person is told once, as the session finishes, with whose change it meets. it only advises: the agent finishes as it would have, and a person decides what happens to the two changes.
SessionEnd
says the session ended, so the board says gone when someone is gone.
the MCP server
lets an agent ask the room while it plans, before it has picked its files: who is working on what, whether anyone has touched a file, which files are contested, and claims, to divide the work before anyone writes. a repository registers it with a committed install.

what the agent reads

this is what bob’s agent is told before it edits a file alice’s agent changed two minutes earlier, word for word:

[AgentMash: ACTIVE COLLISION] alice's agent is working in src/models/user.ts — last write 2 min ago on your branch (main), while working on 'add soft deletes to the user model' (+12/-3 lines, touching deletedAt). Their write is already in your working tree, so whatever you read from this file earlier is out of date. Re-read src/models/user.ts now and rebuild this edit against what is actually there: a stale old_string either fails to match or quietly reverts their change. Leave deletedAt named and shaped as alice left it — that is what they just changed. If your task genuinely needs those same lines, change them and say so in your reply, so the overlap is visible.

it re-reads the file, adapts, and says so in its reply. that’s the loudest of five levels; a change on another branch, or one older than five minutes, is worded more quietly.

setup, in three steps

  1. someone who can push to the repository connects it once, at agentmash.dev/install: they sign in with GitHub and pick it. nothing is committed to it and there is no pull request.
  2. each developer runs npx agentmash login once and signs in with GitHub in the browser it opens. it puts the hooks in their own Claude Code settings, ~/.claude/settings.json, never in a repository.
  3. each developer restarts Claude Code. from the next prompt on, their prompts and edits go to the room.

setup has the steps for claude code and the other coding agents, and a prompt that does them for you. to see it first, how it works plays a made-up team of four in your browser, with nothing to set up.

how it fits what you already use

what it doesn’t do

setup →the five levels →the MCP server →reconciliation →known limitations →