Skip to content
single9Public

Repository files navigation

ertangle

Crates.io Crates.io Downloads GitHub Release License: MIT

English | 繁體中文

Orchestrate multiple coding agents concurrently in your terminal—each in its own Git worktree, collaborating over MCP, reviewed and merged from one keyboard-driven TUI.

Run Claude Code, Antigravity (Gemini), OpenCode, and Codex side by side on the same repository without file conflicts, vendor lock-in, or heavy Electron IDEs (< 20 MB Rust daemon).

ertangle-demo.mp4

ertangle TUI Overview: Multi-Agent Session Tree, Live Streaming, and Flow Topology


What Makes ertangle Different?

  • Multi-Vendor Multi-Agent Collaboration: Mix Claude Code, Antigravity, OpenCode, and Codex in one team. Every structured session receives a built-in 16-tool MCP server so a Coordinator can create dependency-aware tasks, spawn isolated Workers, exchange messages, and wait for results autonomously.
  • Zero-Conflict Worktrees + Inline Review & Safe Merge: Every worker runs in its own git worktree (ertangle/<session>). Inspect colored diffs live in the TUI, press c on any line to send review feedback back to the agent, discard unwanted hunks with X, and merge safely with M (or delegate conflict resolution to the worker via :merge --resolve).
  • Quota Awareness & Cross-Agent Handoff: Track real-time 5h / 7d quotas across accounts. When one provider nears its limit, hand off the exact same worktree, branch, and synthesized briefing to another agent (:handoff)—messages to the old session automatically forward to the successor.
  • Detachable Daemon, Multi-Host SSH & Mobile Web PWA: Built in Rust + Ratatui (< 20 MB RAM). Detach with q and agents keep running; aggregate multiple remote machines over Tailscale; press Space w to pop up a terminal QR code and approve permissions, answer agent questions, or merge diffs from your phone.
You (TUI / CLI / Mobile PWA)
  └─► Coordinator (main checkout · plans & tracks shared MCP task board)
        ├─► Worker A (claude  · worktree @ertangle/ses_a1) ──┐
        └─► Worker B (gemini  · worktree @ertangle/ses_b2) ──┴─► Inline Diff Review (c) ─► Safe Merge (M)

Quick Start

1. Install

# Quick install script (Linux x86_64/arm64, macOS arm64/x86_64; SHA-256 verified, installs ertangle + ert alias)
curl -fsSL https://raw.githubusercontent.com/single9/ertangle/main/install.sh | sh

# Or install from crates.io
cargo install ertangle
Other installation methods (cargo-binstall, manual binary, git, build from source, shell completions)

Prebuilt binary via cargo-binstall

cargo binstall ertangle

Manual download from Releases

curl -fsSL https://github.com/single9/ertangle/releases/latest/download/ertangle-linux-x86_64.tar.gz | tar -xz
install -m 755 ertangle-linux-x86_64 ~/.local/bin/ertangle

Install directly from git

cargo install --git https://github.com/single9/ertangle
# Pin a release tag:
cargo install --git https://github.com/single9/ertangle --tag v1.7.0

Build from source

git clone https://github.com/single9/ertangle && cd ertangle
make install                  # installs to ~/.local/bin/ertangle + ert symlink
make install-completions      # installs bash / zsh / fish completions

2. Run in Any Git Repo

ertangle   # or short alias: ert

The resident daemon starts automatically in the background. Inside the TUI:

  • Press n to spawn an agent (or run :playbook coord-review <goal> to launch a multi-agent team).
  • Press Tab to switch between Overview, Diff, Worktrees, Tasks, and Flow (F).
  • Press Space for the Helix-style which-key menu, or : for commands (Tab completion).
Key Action
n Spawn a new session (pick Agent, Model, Role, Worktree, Effort)
i / Enter Send a prompt (supports @file fuzzy attach, !<cmd> shell exec, Alt-Enter queue)
Tab / F Cycle views (Overview / Diff / Worktrees / Tasks / Flow)
c / M / G (Diff) Inline review comment / Safe merge to main / GC merged worktrees
Space s m Fuzzy model switcher for the active session
Space w / Space , Mobile Web QR code / Settings panel
q Detach TUI (daemon and agents keep running)

Supported Agents

ertangle talks directly to each agent's native structured protocol (no screen-scraping wrappers), with automatic PTY fallback:

Agent Protocol Highlights
Claude Code stream-json Streaming, tool calls, cost & 5h/7d quota tracking, MCP injection, granular approval forwarding
Antigravity acp Full bidirectional ACP, MCP injection, multi-model pool quota tracking
OpenCode acp Full bidirectional ACP, tool calls, permission forwarding, MCP injection
GitHub Copilot acp Full bidirectional ACP (copilot --acp), MCP injection, elicitation forms, session resume
Codex app-server Structured protocol & thread resume (requires codex login)
Any CLI Agent pty Automatic PTY pass-through fallback

See docs/CLI.md for launch commands and docs/VERIFICATION.md for real-world compatibility notes.


More Screenshots

Task Board, Inline Diff Review & Quota Monitor

Shared Task Board with Dependencies (Tasks tab)

ertangle Task Board

Git Diff & Inline Review Comments (Diff tab)

ertangle Diff & Inline Review

Agent Quota Monitor (:quota)

ertangle Quota Monitor


Documentation


License, Acknowledgements & Name Origin

  • License: MIT License.
  • Acknowledgements: Inspired by Orca (MIT); independently implemented from scratch.
  • Name Origin: ertangle ("er-tangle") combines ER (Einstein–Rosen bridge) and entangle (ER=EPR)—each agent lives in its own universe (a Git worktree) and connects through entanglement (the MCP message bus). Sibling project of erbridge.

Releases

Packages

Contributors

Languages