---
title: "Guides: Cork blog · Cork"
description: "How to run more than one coding agent on a codebase, step by step."
canonical: "https://corkcli.com/blog/c/guides"
last_updated: "2026-11-14"
---

# Guides

How to run more than one coding agent on a codebase, step by step.

- [How AI agents talk to each other](https://corkcli.com/guides/how-ai-agents-talk-to-each-other): Direct messaging (A2A), shared tools (MCP), and shared state: the three real patterns for agent communication, and which one coding agents need.
- [Multiple AI coding agents, one codebase](https://corkcli.com/guides/multiple-ai-coding-agents-one-codebase): The four failure modes of parallel agents and the four coordination patterns that prevent them, with honest tradeoffs.
- [Do you need git worktrees to run AI coding agents in parallel?](https://corkcli.com/guides/do-you-need-git-worktrees-for-ai-coding-agents): When a worktree per agent pays off, when one shared checkout is the better choice, and what it needs instead.
- [Clean up the worktrees your agents leave behind](https://corkcli.com/guides/clean-up-git-worktrees-ai-coding-agents): Where Claude Code, Codex, Cursor and Conductor put their worktrees, and how to remove one without losing work.
- [How to review pull requests from several AI agents at once](https://corkcli.com/blog/review-pull-requests-from-multiple-ai-agents): Review pull requests from several AI coding agents at once: triage with gh, review for cross-PR conflicts, use CODEOWNERS, AI review passes and a merge queue.
- [How to reduce token usage when running several coding agents at once](https://corkcli.com/blog/reduce-token-usage-multiple-coding-agents): Several Claude Code, Codex or Cursor agents at once multiply token spend. Cut it with lean shared context, cheaper models, less rediscovery and less rework.
- [Why AI coding agents cause merge conflicts, and how to prevent them](https://corkcli.com/blog/why-ai-coding-agents-cause-merge-conflicts): Parallel AI coding agents create merge conflicts through stale bases, shared hotspots and drive-by edits. Here is why, and seven concrete ways to prevent them.
- [How to reduce Claude Code token usage](https://corkcli.com/blog/reduce-claude-code-token-usage): Cut Claude Code token usage with the official levers: /clear, /compact, /context, model and effort choice, a lean CLAUDE.md, subagents, hooks, fewer re-reads.
- [Getting started with Cork's MCP tools: get_symbol, blast_radius, recap, remember](https://corkcli.com/blog/cork-mcp-tools-get-symbol-blast-radius-recap-remember): Use Cork's MCP tools in Claude Code, Codex and Cursor: get_symbol, blast_radius, recap, remember and recall, with when to call each and example prompts.
- [Why AI agents re-read the same files, and how to stop it](https://corkcli.com/blog/why-ai-agents-reread-same-files): Why Claude Code, Codex and Cursor agents keep re-reading the same files, and how to stop it: specific prompts, lean context, symbol lookups and briefings.
- [Pre-commit checks for code written by AI agents](https://corkcli.com/blog/pre-commit-checks-ai-generated-code): Pre-commit checks for AI-written code: git hooks, the pre-commit framework, secret scanning, and agent hooks in Claude Code, Codex and Cursor.
- [From one machine to a team: moving from Cork Free to agent hours](https://corkcli.com/blog/cork-free-to-team): Move from Cork Free to agent hours: what changes when agents on teammates' machines see each other, how cork login and cork upgrade work, and what it costs.
- [Trunk-based development with AI coding agents](https://corkcli.com/blog/trunk-based-development-ai-coding-agents): Trunk-based development when AI coding agents write much of the code: short-lived agent branches, daily merges, feature flags, rebase-test-push, merge queues.
- [Cork Free: set up multiplayer coding agents on one machine in one command](https://corkcli.com/blog/cork-free-setup-one-machine): Set up Cork Free in one command so Claude Code, Codex and Cursor agents on one machine stop overwriting each other. No account; data stays on the machine.
- [How to onboard an engineer when AI agents write half the code](https://corkcli.com/blog/onboard-engineers-ai-coding-agents): Onboard a new engineer on a codebase where AI agents write much of the code: agent instruction files, guardrails, ownership, and a first week plan that works.
- [How to track AI coding agent costs per developer and per repo](https://corkcli.com/blog/track-ai-coding-agent-costs-per-developer-repo): Track Claude Code, Cursor and Codex spend per developer and per repository: /usage, OpenTelemetry with repo attributes, admin APIs, and tagging scripted runs.
- [Codex hooks and Cursor hooks: how to use them for team coordination](https://corkcli.com/blog/codex-cursor-hooks-team-coordination): How Codex and Cursor hooks work as of October 2026, where the config lives, how to block or brief an agent, and how to use hooks to coordinate a team's agents.
- [Multiplayer AI coding for remote teams](https://corkcli.com/blog/multiplayer-ai-coding-remote-teams): How remote teams run AI coding agents on one codebase: shared agent instructions, async handoffs, ownership, landing rules, and cross-machine awareness.
- [How to stop Claude Code agents from overwriting each other's changes](https://corkcli.com/blog/stop-claude-code-agents-overwriting-changes): Why parallel Claude Code agents overwrite each other's edits, and how to stop it with worktrees, file ownership, deny rules, PreToolUse hooks and a write gate.
- [Code graphs for AI coding agents: why agents need one](https://corkcli.com/blog/code-graph-for-ai-coding-agents): Why AI coding agents work better with a code graph: fewer file reads, exact callers before an edit, and a map that stays current as several agents edit.
- [Do more AI agents mean fewer tokens? What one benchmark measured](https://corkcli.com/blog/more-ai-agents-fewer-tokens-benchmark): Do more AI coding agents use fewer tokens? Usually more. What Anthropic's docs and research report, and what Cork's 12-agent benchmark measured.
- [How to keep AI coding agents from duplicating each other's work](https://corkcli.com/blog/stop-ai-coding-agents-duplicating-work): Stop parallel AI coding agents fixing the same bug twice or writing the same helper: claim work, share a task list, publish findings, check before starting.
- [How to run Claude Code on two machines on the same repo](https://corkcli.com/blog/claude-code-two-machines-same-repo): Run Claude Code on a laptop and a desktop against one repo: what syncs through git, what stays local, and how to move sessions and context between machines.
- [MCP servers for coordinating coding agents: what they are and how to use one](https://corkcli.com/blog/mcp-servers-coordinating-coding-agents): What an MCP server for coordinating coding agents does, how it differs from hooks, and how to connect one to Claude Code, Codex, Cursor and Gemini CLI.
- [How to stop an agent editing a file someone else is changing](https://corkcli.com/blog/stop-agent-editing-file-someone-else-is-changing): Block an AI coding agent from editing a file another session is changing: a tested Claude Code PreToolUse lock hook, Cursor and Codex equivalents, and limits.
- [Claude Code subagents vs parallel sessions: when to use which](https://corkcli.com/blog/claude-code-subagents-vs-parallel-sessions): Subagents or parallel Claude Code sessions? Compare context, control, file isolation and cost, with a decision checklist and setup for each, as of October 2026.
- [How to land agent changes in one step: rebase, test and push](https://corkcli.com/blog/land-agent-changes-rebase-test-push): Land AI agent commits in one step: fetch, rebase onto teammates' work, rerun tests and push, using a script, a pre-push hook or a merge queue.
- [Parallel AI coding agents on a team: how to split who works on what](https://corkcli.com/blog/split-work-parallel-ai-coding-agents-team): How a team splits work across parallel AI coding agents: slice by code ownership, name shared files, one branch per agent, small tasks, and live coordination.
- [Setting up Claude Code multi-agent work on Windows (Git Bash and PowerShell)](https://corkcli.com/blog/claude-code-multi-agent-windows-setup): Run several Claude Code agents on Windows: install, Git Bash vs PowerShell, worktrees, hooks in either shell, agent teams, messaging and WSL, per the docs.
- [How to split a big task across several AI coding agents](https://corkcli.com/blog/split-big-task-across-multiple-ai-coding-agents): Split a large coding task across parallel AI agents: land contracts first, cut units by file ownership, pick /batch, agent teams or worktrees, land in order.
- [Humans and AI agents on one branch: how to coordinate](https://corkcli.com/blog/humans-and-ai-agents-same-branch): Share a branch between developers and AI coding agents without lost work: who owns which files, commit and rebase rhythm, safe pushes, and review rules.
- [Claude Code hooks explained: PreToolUse, PostToolUse and team workflows](https://corkcli.com/blog/claude-code-hooks-pretooluse-posttooluse-team-workflows): How Claude Code hooks work: settings locations, PreToolUse allow and deny, PostToolUse checks, SessionStart context, exit codes, and hook patterns for teams.
- [Shared memory for coding agents: notes anchored to code](https://corkcli.com/blog/shared-memory-coding-agents-anchored-notes): Give AI coding agents shared memory: instruction files, path-scoped rules, auto memory, and notes anchored to functions so the right agent reads them.
- [How to hand work from one AI coding agent to another](https://corkcli.com/blog/hand-off-work-between-ai-coding-agents): Hand off work between AI coding agents without losing context: commit, write a handoff note, resume or fork sessions in Claude Code and Codex, and verify first.
- [Claude Code agent teams vs separate sessions on one repo](https://corkcli.com/blog/claude-code-agent-teams-vs-separate-sessions): Claude Code agent teams vs separate sessions on one repo: how each works, token cost, same-file conflicts, worktrees, and when to pick which (October 2026).
- [How to share context between Codex and Claude Code](https://corkcli.com/blog/share-context-codex-claude-code): Make Codex and Claude Code work from the same context: one AGENTS.md, shared MCP servers, handoff files, and live awareness when both edit the same repo.
- [How to give AI coding agents context about recent changes](https://corkcli.com/blog/give-ai-coding-agents-context-recent-changes): Give Claude Code, Codex and Cursor context about recent changes: good commit messages, SessionStart and prompt hooks that inject git history, and live updates.
- [Blast radius: how to know what a code change breaks before you make it](https://corkcli.com/blog/blast-radius-code-change): Find a code change's blast radius before you make it: callers via LSP and git grep, dependents with Nx or Turborepo, history, tests, and teammates' work.
- [How to share context between Claude Code sessions](https://corkcli.com/blog/share-context-between-claude-code-sessions): Six ways to carry context between Claude Code sessions: CLAUDE.md, auto memory, handoff files, resume and fork, cross-session messaging, SessionStart hooks.
- [Git worktrees for parallel AI coding agents: setup and limits](https://corkcli.com/blog/git-worktrees-parallel-ai-coding-agents): Set up git worktrees for parallel AI coding agents like Claude Code and Codex: exact commands, environment setup, cleanup, and what worktrees do not solve.
- [Running AI coding agents in a monorepo: what to watch for](https://corkcli.com/blog/ai-coding-agents-monorepo): What breaks when AI coding agents work in a monorepo: instruction files, context size, shared packages, affected tests and parallel agents, with fixes for each.
- [Semantic merge conflicts: when the merge is clean but the code breaks](https://corkcli.com/blog/semantic-merge-conflicts): A semantic merge conflict is a clean git merge that breaks the program. Why git misses them, examples with AI agents, and how to catch and prevent them.
- [How to know when another agent renamed a function you call](https://corkcli.com/blog/detect-renamed-function-another-agent): Find out when another AI agent renamed or changed a function your code calls: git pickaxe, type checks after rebase, session hooks, and live awareness.
- [Agent-to-agent messaging between coding agents: how it works](https://corkcli.com/blog/agent-to-agent-messaging-coding-agents): How coding agents message each other as of October 2026: Claude Code SendMessage, team mailboxes, cross-session sockets, A2A, and what a useful message holds.
- [How to see what all your AI coding agents are doing at once](https://corkcli.com/blog/see-what-all-ai-coding-agents-are-doing): See every AI coding agent's status in one place: Claude Code agent view, Cursor's Agents Window, git worktree checks, OpenTelemetry, and a team-wide view.
- [How to coordinate Cursor and Claude Code on the same codebase](https://corkcli.com/blog/coordinate-cursor-and-claude-code-same-codebase): Run Cursor and Claude Code on one repo without clobbered edits: shared AGENTS.md instructions, worktrees, shared MCP servers, hooks, and a coordination layer.
- [What data an agent coordination tool needs (and what it should not see)](https://corkcli.com/blog/agent-coordination-tool-data-privacy): What data an AI agent coordination tool needs to stop agents overwriting each other, what it should never see, and the questions to ask before you install one.
- [How to run multiple Claude Code agents on one repo without conflicts](https://corkcli.com/blog/run-multiple-claude-code-agents-one-repo): Run several Claude Code agents on one repository safely: worktrees, subagents, agent teams, cross-session messaging, and a clean landing routine, step by step.
- [How to coordinate AI coding agents across a team's machines](https://corkcli.com/blog/coordinate-ai-coding-agents-across-team): Coordinate AI coding agents across a team's machines: shared agent instructions, branch and PR rules, CI gates, live signals, and what built-in tools cover.
- [How to add a remote MCP server to Claude Code, Codex, Cursor and Gemini CLI](https://corkcli.com/blog/add-remote-mcp-server-claude-code-codex-cursor-gemini-cli): Exact, verified commands and config to add a remote HTTP MCP server to Claude Code, Codex, Cursor and Gemini CLI, with scopes, auth headers and OAuth sign-in.
- [How to run Codex and Claude Code side by side on one project](https://corkcli.com/blog/run-codex-and-claude-code-side-by-side): Run OpenAI Codex CLI and Claude Code on one repo: one AGENTS.md for both, a worktree each, shared MCP servers, matching hooks, and live coordination.
- [Setting up Cork for a team of five](https://corkcli.com/blog/cork-team-of-five-setup): Set up Cork for a five-person team running Claude Code, Codex and Cursor agents: install, login, agent hours, AGENTS.md, working habits, and what it costs.
- [Running 10 or more coding agents at once: what breaks and how to fix it](https://corkcli.com/blog/run-10-coding-agents-at-once): What breaks when you run 10 or more AI coding agents at once (rate limits, disk, ports, git races, duplicated work, review load) and practical fixes for each.
- [Messaging between your coding agents with cork message](https://corkcli.com/blog/cork-message-coding-agents): Use cork message to reach every coding agent in a repo, one agent, or whoever is working on a function, across Claude Code, Codex and Cursor. With examples.

[All articles](https://corkcli.com/blog.md) · [Cork in Markdown](https://corkcli.com/index.md) · [llms.txt](https://corkcli.com/llms.txt)

This page in HTML: https://corkcli.com/blog/c/guides
