TagTeam β Sync Claude Code, Gemini (Antigravity), Grok CLI, OpenAI Codex & Grok Build (Cursor) Conversations
English Β· PortuguΓͺs (Brasil) Β· Project site
Hit a usage limit in the middle of a task? Tag out.
The next AI picks up the same conversation β history, context and a handoff note included.
You are deep into a refactor with Claude Code and the 5-hour limit hits. You open Gemini (Antigravity), the Grok CLI, OpenAI Codex or Grok Build (formerly Cursor)β¦ and start from zero, pasting context, re-explaining the task, losing the thread.
TagTeam makes your conversations travel. Every Claude Code session shows up in Gemini, Grok, Codex and Grok Build β and every
Gemini, Grok, Codex or Grok Build session shows up in claude --resume (and from there in the others) β automatically, both
ways, with the right title. Close to the
limit, the agent that is about to stop writes a five-line handoff so the next one knows exactly where to continue.
As far as we know, it is the first open-source tool that keeps one conversation alive across five different AI coding agents β not a chat wrapper, not an API proxy: your real sessions, in each tool's native format.
| π Five-way sync, both directions | Claude Code β Gemini (Antigravity app and agy CLI) β Grok CLI β OpenAI Codex (app and CLI) β Grok Build, formerly Cursor (desktop app and cursor-agent CLI), through hooks β no command to remember. |
Sessions land in each tool's own storage: claude --resume, the Antigravity sidebar, agy, grok --resume, the Codex app, codex resume, the Grok Build app's list and cursor-agent --resume. |
|
| π€ Automatic handoff | At 95% of the Claude limit (or the Gemini quota) a hook makes the agent write Request / Done / In progress / Next step / Watch out before stopping. |
| π§ Same brain in every tool | Gemini and Grok read your ~/.claude/CLAUDE.md, the same skills, the Claude plugins and your MCP servers β by reference, never copied. Codex too: a generated AGENTS.md block, one junction per skill, Claude's plugins installed natively from Claude's own marketplaces, and the same MCP servers. Grok Build (Cursor) already reads Claude's skills, CLAUDE.md and plugins by itself; TagTeam adds the MCP servers and the hook. |
| π‘οΈ Single thread, never clobbers | Relaying across AIs fast-forwards the same thread with zero duplicates (replacing superseded copies cleanly). When two AIs continue it at the same time, the new turns from both are merged into that same Claude session (no (<AI> branch) forks, nothing lost). Mirrors never bounce back. |
| π» Multi-PC friendly | Paths from another machine (other user, other drive) are remapped to this one; state is per PC. |
| πͺΆ Zero dependencies | Pure Python standard library (SQLite, protobuf parsing, TOML) + the official installers of each CLI. |
| π Local only | Nothing leaves your machine. No telemetry, no server, no API keys. |
Requirements: Windows 10/11 and Claude Code. Python 3.11+ (the installer offers to install it with winget). The other AIs are optional: TagTeam shows which ones you have and installs the official
agy, Grok and Codex CLIs if you check them.
Paste this in PowerShell:
irm https://mop4r.github.io/tagteam/install.ps1 | iexIt downloads the latest release (checked against the SHA-256 GitHub publishes for it) and opens the TagTeam setup:
- Pick the AIs. It shows what is installed on your PC; check the ones that should share conversations with Claude Code.
- Pick the options. Default folder, the same Claude environment (CLAUDE.md, skills, plugins, MCP) in each AI, Start
Menu shortcuts (as admin and without approval prompts only if you say so), the usage status line, the automatic
handoff and its %, folders whose conversations must never leave Claude, and keeping the
agy, Grok, Codex and Grok Build (cursor-agent) CLIs up to date by themselves (their ownupdatecommand, once a day, in the background). - Watch it install. Each step with a β or the reason it failed; then open each CLI once to sign in.
Open TagTeam from the Start Menu (or run it again) and the same program is a live monitor: health, chats in each direction per AI, when each AI's hook last fired, the runs of the last 24 h and any errors. From there you can sync now, do a dry run, add or remove an AI (one you skipped, or one you installed later), change the options, repair the setup, open the log, update TagTeam or uninstall it (hooks, shortcuts and generated blocks go; no conversation is deleted).
That's it. Start a conversation in any of the five; open another one and it is already there.
Install with git instead (or without the screens)
git clone https://github.com/mop4r/tagteam "$HOME\.claude\skills\tagteam"
python -I "$HOME\.claude\skills\tagteam\scripts\tagteam.py" # setup + monitor
python -I "$HOME\.claude\skills\tagteam\scripts\tagteam.py" --simples # numbered prompts, no full screen
python -I "$HOME\.claude\skills\tagteam\scripts\tagteam.py" --status # print health and exit
python -I "$HOME\.claude\skills\tagteam\scripts\instalar.py" --seco # what the setup would change
python -I "$HOME\.claude\skills\tagteam\scripts\sincronizar.py" --seco # what a sync would doWithout ~/.tagteam/config.json TagTeam behaves as before it existed (every AI, shortcuts as admin and without
approval prompts), so an existing install changes nothing until you save options in the monitor.
flowchart LR
C["π Claude Code<br/><sub>~/.claude/projects/*.jsonl</sub>"]
G["π£ Gemini Β· Antigravity<br/><sub>app + agy CLI (SQLite + protobuf)</sub>"]
K["β« Grok CLI<br/><sub>~/.grok/sessions/*/updates.jsonl</sub>"]
X["π’ OpenAI Codex<br/><sub>app + CLI Β· ~/.codex (official app-server API)</sub>"]
U["π΅ Grok Build Β· ex-Cursor<br/><sub>cursor-agent CLI Β· ~/.cursor/chats<br/>desktop app Β· agent host sessions</sub>"]
C <-- "hooks: Stop Β· SessionEnd" --> G
C <-- "hooks: Stop Β· SessionEnd" --> K
C <-- "hooks: Stop Β· SessionEnd" --> X
C <-- "hooks: stop Β· sessionEnd" --> U
G -. "relayed through Claude in the same run" .-> K
K -. "relayed through Claude" .-> X
- Claude Code is the hub. Each AI syncs with Claude; whatever just arrived from one of them is relayed to the others in the same run, so all five converge.
- Hooks do the work. Claude Code (
SessionStart,Stop,SessionEnd), Antigravity (Stop), Grok, Codex and Grok Build (Stop,SessionEnd) each call TagTeam after every reply β throttled to once every 2 minutes per conversation, and the last reply inside that window is synced when it closes. A sync that finds another one running waits for its turn. - Native formats. Claude JSONL, Antigravity's per-conversation SQLite with protobuf steps (written through its
local language server when the app is open), Grok's ACP
updates.jsonl+chat_history.jsonl, and Codex through its own local API (codex app-server) and native session import β the app and the CLI share~/.codexβ and Grok Build's agent format (content-addressed SQLite blobs with protobuf turns), used by both its CLI chat store and the desktop app's agent host. - No ping-pong. Every imported copy carries a marker (
entrypoint, aclaude_importtable, aclaude_import.json); a copy nobody continued is never sent back. Continued copies spawn a new version instead of being overwritten.
Deep dive: docs/HOW-IT-WORKS.md.
When the Claude Code status line reports β₯ 95% of the 5-hour or 7-day limit (or Antigravity's quota API says the
same for Gemini), the Stop hook blocks once and the agent writes, as its last message:
## Handoff to Gemini or Grok
- Request: migrate the auth module to async.
- Done: login, token and middleware migrated; 34 tests green (commit 3f2a91c).
- In progress: session.py half done, branch feat/async-auth.
- Next step: finish SessionStore.refresh() and run tests/auth.
- Watch out: don't touch the legacy /v1 routes; credentials are in .env.local.The receiving AI is told (by the generated GEMINI.md / AGENTS.md) to look for it and follow the Next step. No
handoff because the limit hit hard? It reconstructs those five lines from the last messages before acting.
Test it without waiting for the limit: set TAGTEAM_HANDOFF_THRESHOLD=10.
| From Claude Code | Gemini (Antigravity / agy) | Grok CLI | OpenAI Codex (app / CLI) |
|---|---|---|---|
| Conversations | β both ways (app + CLI) | β both ways | β both ways (app + CLI) |
~/.claude/CLAUDE.md |
β
via generated ~/.gemini/GEMINI.md |
β
loaded natively + ~/.grok/AGENTS.md |
β
via a generated block in ~/.codex/AGENTS.md |
Skills (~/.claude/skills) |
β
config/skills.json |
β native | β
one junction per skill in ~/.codex/skills |
claude.ai account skills (~/.claude/skills/synced) |
β
config/skills.json |
β
junctions in ~/.grok/skills (so Claude's docx/pdf/pptx/xlsx win over Grok's built-ins) |
β junctions |
| Claude plugins | β skills + Antigravity-ready plugins | β
enabled in config.toml |
β installed natively from Claude's local marketplaces (reinstalled when Claude's version changes) |
MCP servers (~/.claude.json) |
β
config/mcp_config.json |
β
remote servers in config.toml |
β
config.toml, through Codex's config API |
| Automatic handoff at the limit | β (quota API) | β manual β Grok doesn't expose usage outside its TUI | β manual |
| Resume picker shortcut | β "Agy CLI --resume" | β "Grok --resume" | β "Codex --resume" |
Grok Build (formerly Cursor): Cursor became Grok Build at the end of November 2026; the desktop app and the
cursor-agent CLI kept their data folders, so TagTeam follows both under the new name. Conversations go both ways with
the CLI; the app reads CLAUDE.md, Claude's skills and enabled plugins natively, and TagTeam writes ~/.cursor/mcp.json,
the ~/.cursor/hooks.json hook and the claude.ai skill junctions.
The desktop app works both ways too. Since version 3.32 it keeps chats in a local agent host
(~/.grok/agent-host-daemon/sessions) and, when it starts, migrates older chats from its previous database β but only
chats that carry the agent's conversation state. TagTeam writes Claude's sessions into that database with the state (the
same protobuf the CLI uses) and clears them for migration, so the app imports them on its next start, with the full
history, and you can continue them there; chats made or continued in the app are read from the agent host and reach
Claude (and the others). Writing happens only while the app is closed (the next run catches up), only for folders the
app already knows, for the 50 most recent sessions of the last 30 days (like the app's own importer), and it stops with
a message if an update changes the format. The app's built-in Import Claude Code Conversations finds nothing on
Windows, which is why TagTeam does it.
Local MCP servers (node.exe, wsl.exeβ¦) are launched without a console window (the app's agent worker would
otherwise open a terminal for each one every time it starts or reloads them).
cd "$HOME\.claude\skills\tagteam\scripts"
python -I sincronizar.py # sync everything, every direction
python -I sincronizar.py --direcao grok # Claude -> Grok only (antigravity | claude | grok | claude-de-grok | codex | claude-de-codex | cursor | claude-de-cursor)
python -I sincronizar.py --sessao <claude-id> # one Claude session (--cascade <gemini-id> / --grok <grok-id> / --codex <codex-id> / --cursor <cursor-id>)
python -I sincronizar.py --forcar # rewrite / recreate deleted copies (never a continued one)
python -m unittest discover -p "test_*.py" # 300+ tests (the Codex ones run the real Codex in a throwaway folder)
python -I dev.py pausar "why" # hacking on the scripts: automatic runs (hooks) write nothing for 8 h
python -I dev.py liberar # runs the test suite; the pause only ends if it is green| Environment variable | Default | What it does |
|---|---|---|
TAGTEAM_HANDOFF_THRESHOLD |
95 |
% of the limit that triggers the handoff (wins over the monitor's option) |
TAGTEAM_WORKSPACE |
your home | default working folder (shortcuts, fallback for sessions whose folder doesn't exist here; wins over the monitor's option) |
TAGTEAM_STATE_DIR |
~/.tagteam |
per-PC sync state, config.json (the monitor's options) and eventos-<PC>.jsonl (one line per run) |
Logs: %TEMP%\tagteam\sincronizar.log (each run's output in one block, so parallel runs never mix lines).
Is this affiliated with Anthropic, Google, xAI or OpenAI?
No. TagTeam is an independent community project (not affiliated with Anysphere either, the company behind Grok Build, formerly Cursor). It only reads and writes files on your own machine, in the formats these tools already use.
Does it send my conversations anywhere?
No. Everything is local file I/O plus the local servers of Antigravity and Codex. No network calls except the official CLI installers, when you don't have them yet.
Can I use it across several PCs?
Yes. Sync ~/.claude/projects with whatever you like (git, Syncthing, OneDriveβ¦). On each PC, TagTeam imports the
Claude sessions into that PC's Gemini, Grok, Codex and Grok Build, remapping paths from other users and drives.
How do I stop syncing one AI, or uninstall?
Open TagTeam (Start Menu) and press I to uncheck the AI (or only its chats, or only its environment) and the setup takes its hook, shortcuts and generated blocks out; press D to uninstall everything. The conversations already copied, and the AIs themselves, stay where they are.
What happens if I continue the same chat in two tools?
Nothing is lost. A copy that was continued is never overwritten; the next sync creates a new version next to it.
Grok CLI and Grok Build β aren't they the same?
No. The Grok CLI (grok, xAI's terminal agent, sessions in ~/.grok/sessions) and Grok Build (formerly
Cursor: the desktop app and the cursor-agent CLI) are separate tools with separate chats. TagTeam syncs both, each in
its own format.
I updated Cursor / Grok Build and my synced chats disappeared from the app
Grok Build 3.32 moved chats to its agent host and only migrated chats with the agent's conversation state, which copies
from TagTeam 0.5 and older did not have. Update TagTeam (0.6+), close the app and let one sync run (or run
python -I sincronizar.py --direcao cursor): the copies are rewritten with the state and the app imports them the next
time it opens.
Why are some comments in Portuguese?
TagTeam was born as a personal tool in Brazil. User-facing text is English; code comments are being translated β PRs welcome.
macOS / Linux?
Not yet: the shortcuts, the Grok picker and some paths are Windows-specific. The sync core is portable β help wanted!
- Claude Code β Antigravity app +
agyCLI - Grok CLI, three-way relay
- Automatic handoff (Claude, Gemini)
- OpenAI Codex (app + CLI), four-way relay
- Cursor CLI, five-way relay
- Grok Build (formerly Cursor) 3.32 desktop app: agent host sessions both ways
- macOS and Linux
- More agents: Gemini CLI, Copilot CLI
- Optional cleanup command for test conversations
Issues and PRs are very welcome β see CONTRIBUTING.md. If TagTeam saved your flow, a β helps other people find it.
MIT. Claude, Gemini, Antigravity, Grok, Grok Build, Cursor, OpenAI and Codex are trademarks of their respective owners; TagTeam is not endorsed by them.
Built for people who refuse to lose a train of thought to a rate limit.

