{"id":51951738,"url":"https://github.com/dubsopenhub/terminal-stampede","last_synced_at":"2026-07-29T06:01:29.580Z","repository":{"id":341481141,"uuid":"1170267344","full_name":"DUBSOpenHub/terminal-stampede","owner":"DUBSOpenHub","description":"A parallel agent runtime for your terminal. Run up to 20 AI coding agents simultaneously in tmux panes. Works with any CLI agent.","archived":false,"fork":false,"pushed_at":"2026-04-10T17:33:27.000Z","size":12989,"stargazers_count":4,"open_issues_count":1,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-07-07T22:21:29.546Z","etag":null,"topics":["ai-agents","ai-coding","cli-tools","copilot-cli","copilot-extensions","developer-tools","github-copilot","multi-agent","orchestration","parallel","parallel-agents","terminal","tmux"],"latest_commit_sha":null,"homepage":"","language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/DUBSOpenHub.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-03-01T23:34:57.000Z","updated_at":"2026-05-21T19:49:08.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/DUBSOpenHub/terminal-stampede","commit_stats":null,"previous_names":["dubsopenhub/terminal-stampede"],"tags_count":6,"template":false,"template_full_name":null,"purl":"pkg:github/DUBSOpenHub/terminal-stampede","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DUBSOpenHub%2Fterminal-stampede","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DUBSOpenHub%2Fterminal-stampede/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DUBSOpenHub%2Fterminal-stampede/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DUBSOpenHub%2Fterminal-stampede/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DUBSOpenHub","download_url":"https://codeload.github.com/DUBSOpenHub/terminal-stampede/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DUBSOpenHub%2Fterminal-stampede/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":36020486,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-07-20T02:08:10.276Z","status":"online","status_checked_at":"2026-07-29T02:00:04.910Z","response_time":95,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ai-agents","ai-coding","cli-tools","copilot-cli","copilot-extensions","developer-tools","github-copilot","multi-agent","orchestration","parallel","parallel-agents","terminal","tmux"],"created_at":"2026-07-29T06:01:27.934Z","updated_at":"2026-07-29T06:01:29.570Z","avatar_url":"https://github.com/DUBSOpenHub.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🦬 Terminal Stampede\n\nA parallel agent runtime for your terminal. Up to 20 AI agents. Zero infrastructure. Built-in quality scoring. Works with any CLI coding agent.\n\n[![Latest Release](https://img.shields.io/github/v/release/DUBSOpenHub/terminal-stampede?label=latest\u0026color=gold)](https://github.com/DUBSOpenHub/terminal-stampede/releases/latest)\n\n\u003e ### ⚡ One Command. That’s It.\n\u003e\n\u003e **Never used the CLI before? No problem.** Follow these 3 steps:\n\u003e\n\u003e **1. Open your terminal**\n\u003e - 🍎 **Mac:** Press `⌘ + Space`, type **Terminal**, hit Enter\n\u003e - 🪩 **Windows:** Press `Win + X`, choose **Terminal** or **PowerShell**\n\u003e - 🐧 **Linux:** Press `Ctrl + Alt + T`\n\u003e\n\u003e **2. Paste this line and press Enter:**\n\u003e ```bash\n\u003e curl -fsSL https://raw.githubusercontent.com/DUBSOpenHub/terminal-stampede/main/quickstart.sh | bash\n\u003e ```\n\u003e *Already have the CLI? No worries — this detects it and skips straight to adding the skill.*\n\u003e\n\u003e **3. When Copilot opens, type:** `stampede`\n\u003e\n\u003e That’s it — unleash the herd! ⚡\n\u003e\n\u003e *Requires an active [Copilot subscription](https://github.com/features/copilot/plans). [Get one here →](https://github.com/features/copilot/plans)*\n\u003e\n\u003e \u003cimg width=\"661\" height=\"263\" alt=\"Screenshot 2026-03-02 at 11 38 03 PM\" src=\"https://github.com/user-attachments/assets/51036365-4b51-4568-bccd-db5e68665deb\" /\u003e\n\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"assets/stampede-demo-new.gif\" alt=\"Animated demonstration of Terminal Stampede showing 8 AI agents working in parallel across separate tmux panes, each processing code, reading files, and making git commits independently while coordinated through a filesystem message queue\" width=\"900\" /\u003e\n\u003c/p\u003e\n\n**A parallel agent runtime for your terminal.** Run up to 20 AI coding agents simultaneously, each in its own tmux pane with its own context window and git branch. Works with any CLI agent that can take a prompt and write code. The sweet spot is 6–8 agents (the default is 3; configurable with `--count`).\n\n- 🏠 **Zero-infrastructure local swarm**\n- 🖥️ **tmux as execution surface**\n- 📂 **Filesystem as atomic message bus**\n- 👀 **Human-in-the-loop observability**\n- 🧱 **Simplicity over complexity** — no frameworks, no servers, no message brokers. The simpler the system, the more reliable the output.\n- 🎯 **[Shadow scoring](https://github.com/DUBSOpenHub/shadow-score-spec)** — quality defined before agents run, measured silently after\n\n---\n\nYou've been doing AI coding one task at a time. Ask, wait, ask again, wait again. Terminal Stampede splits your terminal into multiple panes, drops an AI agent into each one, and lets them all charge through your codebase simultaneously. Each agent gets its own brain, its own branch, its own mission. You watch them work in real time through the gold ⚡ borders. Minutes later, everything's done.\n\n**Zero infrastructure.** No Redis, no HTTP, no Docker, no cloud. Just files on disk and tmux.\n\n**Human in the loop, not after the fact.** Every agent runs in a visible pane. Zoom in on any one, type into it, kill it, or just watch. Most multi-agent systems give you logs when it's over. This one puts you in the room while it's happening.\n\n**tmux is the runtime.** Each pane is a full CLI agent session with its own context window. The filesystem is the message bus — task claiming is an atomic file rename, no locks, no coordination server. Point it at any repo.\n\n**Works with any CLI agent.** Built with GitHub Copilot CLI, but the pattern is tool-agnostic — swap the agent command for Aider, Claude Code, or any CLI tool that can read a task and write code.\n\n📝 **[Read the full story →](BLOG.md)** *\"What If You Could Run 20 AI Agents in One Terminal?\"* — How Havoc Hackathon, Shadow Score, Dark Factory, and Agent X-Ray led to this experiment.\n\n---\n\n## 🚀 Quick Start\n\n### Prerequisites\n\n- macOS or Linux\n- `tmux` (`brew install tmux`)\n- A CLI coding agent (e.g., [GitHub Copilot CLI](https://docs.github.com/copilot/concepts/agents/about-copilot-cli), Aider, Claude Code)\n- `python3`, `jq`, `openssl`, `git`\n\n### Install\n\n```bash\ngit clone https://github.com/DUBSOpenHub/terminal-stampede.git\ncd terminal-stampede\nchmod +x install.sh \u0026\u0026 ./install.sh\n```\n\nSix files land in their working locations:\n\n| File | Location | Purpose |\n|------|----------|---------|\n| Orchestrator skill | `~/.copilot/skills/stampede/SKILL.md` | Parses commands, generates tasks, monitors, synthesizes |\n| Worker agent | `~/.copilot/agents/stampede-agent.agent.md` | Claims tasks, does the work, writes results |\n| Merger agent | `~/.copilot/agents/stampede-merger.agent.md` | Auto-merges all branches, resolves conflicts, shadow-scores |\n| Launcher | `~/bin/stampede.sh` | Creates tmux session, spawns panes, tracks PIDs |\n| Monitor | `~/bin/stampede-monitor.sh` | Live progress, stuck detection, runtime stats |\n| Merger script | `~/bin/stampede-merge.sh` | Discovers branches, sorts by size, launches merger |\n\n\u003e **Note:** The skill and agent files install to `~/.copilot/` paths for GitHub Copilot CLI. If you use a different CLI agent (Aider, Claude Code, etc.), you only need the shell scripts in `~/bin/` — see Option B below.\n\n### Run\n\n**Option A: From the command line** (works with any CLI agent)\n\nCreate task files yourself, then launch:\n\n```bash\n# 1. Create a run directory (inside your repo)\ncd ~/my-project\nRUN_ID=\"run-$(date +%Y%m%d-%H%M%S)\"\nmkdir -p .stampede/$RUN_ID/{queue,claimed,results,logs}\n\n# 2. Add task files (one JSON per task)\ncat \u003e .stampede/$RUN_ID/queue/task-001.json \u003c\u003c 'EOF'\n{\n  \"task_id\": \"task-001\",\n  \"description\": \"Add input validation to the auth module\",\n  \"scope\": [\"src/auth.py\"],\n  \"branch\": \"stampede/task-001\"\n}\nEOF\n# ... repeat for each task\n\n# 3. Launch the fleet\nstampede.sh --run-id $RUN_ID --count 8 --repo ~/my-project --model claude-haiku-4.5\n```\n\nA Terminal window opens. Eight panes tile across the screen. Gold ⚡ borders show the model and task for each agent. A monitor pane tracks progress in real time. You watch them work.\n\nBy default, workers launch with GitHub Copilot CLI. To use a different CLI agent, pass `--agent-cmd`:\n\n```bash\n# Claude Code\nstampede.sh --run-id $RUN_ID --count 8 --repo ~/my-project --agent-cmd 'claude -p \"{prompt}\"'\n\n# Aider\nstampede.sh --run-id $RUN_ID --count 8 --repo ~/my-project --agent-cmd 'aider --message \"{prompt}\"'\n```\n\n**Option B: From a Copilot CLI session** (if using GitHub Copilot CLI)\n\nOpen a Copilot CLI session and tell the stampede skill what to do:\n\n```\nstampede 8 agents on ~/my-project — add error handling, write tests, improve docs\n```\n\nThe orchestrator reads your codebase, generates task files, launches the fleet, and monitors progress. You watch.\n\n---\n\n## 📊 We Pointed It at Itself\n\nTo test Terminal Stampede, we pointed it at this repo. 8 agents ran simultaneously on the terminal-stampede codebase — adding error handling, creating docs, improving the agent prompts, updating the changelog, and more. Nobody touched anything. They just ran.\n\n| | Result |\n|---|---|\n| Tasks | 8 |\n| Agents | 8 (claude-haiku-4.5) |\n| Wall clock | ~6 minutes |\n| Success rate | 8/8 |\n| Coordination failures | 0 |\n\n| Task | Changes |\n|------|---------|\n| Defensive error handling for stampede.sh | +218 -33 |\n| CONTRIBUTING.md (from scratch) | +219 |\n| Agent hard-exit rules | +218 -33 |\n| Orchestrator failure recovery docs | +132 -1 |\n| CHANGELOG update from git history | +100 |\n| copilot-instructions.md improvements | +85 -3 |\n| Blog accuracy review | +30 -30 |\n| Install.sh: uninstall, --check, versioning | +100 |\n\n8 branches. ~800 lines of real changes. The simplest possible architecture — files on disk, atomic renames, no coordination server — was also the most reliable. Nothing broke. Nothing conflicted. The agents didn't even know each other existed.\n\n---\n\n## 💡 The Problem\n\nYou're a developer. Monday morning. Your codebase needs error handling added to 4 modules, test coverage expanded, docs updated, and the CLI cleaned up. That's 8 tasks.\n\nToday, you work through them one at a time. Ask your AI agent for the first task. Wait. Ask for the second. Wait. Context-switch. Lose momentum. Some tasks take a minute, some take ten, but you're stuck in a queue of your own making.\n\nTerminal Stampede runs them all at once. One command, up to 20 panes, each agent working in parallel on its own git branch. Instead of feeding tasks one by one, you define the batch and let them run. Your development time scales with the longest single task, not the sum of all of them.\n\n| | Sequential | Parallel (Stampede) |\n|---|---|---|\n| Workflow | One task at a time | All tasks at once |\n| Context windows | One shared session | Up to 20 independent sessions |\n| Git branches | 1 (sequential) | Up to 20 (parallel, isolated) |\n| Your involvement | Babysit each task | Start it and walk away |\n\n---\n\n## 🤔 What Is This?\n\nEvery multi-agent framework out there (LangGraph, CrewAI, AutoGen) runs agents as function calls inside one process. They share one brain. When Agent A is thinking, Agent B waits.\n\nTerminal Stampede does something different. Each agent is a fully independent CLI session running in its own tmux pane with its own context window. It can read code, edit files, run tests, see failures, and fix them. No other agent is competing for its attention.\n\n\u003e **Each agent = one tmux pane = one independent CLI session = one git branch.** They share nothing — no memory, no context, no files in progress. Twenty agents means twenty completely isolated AI coding sessions running side by side.\n\nBranches are named `stampede/task-001`, `stampede/task-002`, etc. After a run, the merger combines them into `stampede/merged-{run_id}`. Task branches stay around for inspection until you clean up with `--teardown`.\n\nThe \"message queue\" is just files on disk. The \"orchestrator\" is just a script. The \"agent runtime\" is just your terminal. Point it at any repo.\n\n---\n\n## 🗺️ How It Works\n\nThink of a deli counter. Tasks are tickets on the wall. Agents grab one at a time.\n\n### Task claiming (race-safe)\n\n```\nAgent A: mv queue/task-001.json claimed/task-001.json  ← succeeds\nAgent B: mv queue/task-001.json claimed/task-001.json  ← file gone, tries next\n```\n\nNo locks. No database. Just filesystem rename — atomic by POSIX guarantee.\n\n### Each agent works alone\n\n1. Claim a task (atomic `mv`)\n2. Create git branch: `stampede/task-001`\n3. Read the code, make improvements, run tests\n4. Write result file (atomic: `.tmp-` then `mv`)\n5. Claim next task or exit\n\n### The orchestrator watches\n\n```\n⚙️ [████████████████░░░░] 75% (6/8) | alive=8 dead=0\n```\n\nIf an agent dies mid-task, the orchestrator detects it via PID check, re-queues the task, and another agent picks it up.\n\n### Conflict detection\n\nWhen all results are in, the orchestrator checks if any two agents modified the same file:\n\n```\n⚠️ CONFLICT: lib/state.py modified by task-001 and task-003\n✅ No conflicts on remaining 6 branches — ready to merge\n```\n\n### Auto-merge with shadow scoring\n\n\u003e **\"Did you define what good looks like before AI ran, or after?\"**\n\u003e Most people using AI coding tools have no definition of quality — they eyeball the output and hope for the best. Stampede bakes evaluation into the runtime itself. The scoring criteria are defined before agents run. Measurement happens silently during and after. The agents never know they're being scored.\n\nAfter all agents finish, the merger agent combines every branch into one. It merges sequentially (smallest changes first to build a clean base), resolves conflicts using AI that reads both task descriptions to understand intent, and skips anything irreconcilable.\n\nWhile merging, the merger silently **shadow-scores** each agent's work across 3 layers:\n\n| Layer | When | What It Measures |\n|-------|------|-----------------|\n| Runtime | During stampede | Time to complete, stuck events, files changed |\n| Merge | During merge | Conflict friendliness (clean merge vs. conflicts caused) |\n| Quality | After all merges | Completeness, scope adherence, code quality, test impact |\n\nScores are weighted — Completeness (30%) matters most, Conflict Friendliness (10%) matters least since it's partly outside the agent's control. The agents never know they're being scored.\n\n```\n🦬 Shadow Scorecard (weighted)\n═══════════════════════════════════════════════════════════════════════════\n Agent       Model              Comp  Scope  Qual  Conflt  Test   Total  +/-\n                                (30%)  (25%) (20%)  (10%) (15%)   /50\n ─────────────────────────────────────────────────────────────────────────\n task-001    claude-sonnet-4.5    10     10     8     10     5    44.2  ⚡+2\n task-002    gpt-5.1              10     10     8     10     5    44.2\n task-003    claude-sonnet-4.5    10     10     8     10     5    44.2  🐌-1\n═══════════════════════════════════════════════════════════════════════════\n```\n\nScores persist across runs to `~/.stampede/model-stats.json`, building a leaderboard that shows which AI models consistently produce the best work over time.\n\n### Which AI model is actually best for your codebase?\n\nEvery vendor publishes benchmarks. Every benchmark uses synthetic tests. None of them tell you which model writes the best code *on your repo, with your patterns, in your language*.\n\nThe stampede leaderboard answers that question empirically. Every run shadow-scores each model's work. Scores accumulate across runs. Over time, you get a ranking built from real work on your real codebase — not from HumanEval, not from vendor marketing, not from someone else's synthetic tests. From your code, your tasks, your results.\n\n```\n📊 Model Leaderboard (12 runs)\n─────────────────────────────────────────────────────\n  claude-sonnet-4.5         avg 44.2/50  (18 branches)\n  gpt-5.1-codex             avg 42.8/50  (14 branches)\n  claude-haiku-4.5          avg 41.1/50  (22 branches)\n  gpt-5.1                   avg 39.7/50  (16 branches)\n  gemini-3-pro              avg 38.4/50  (10 branches)\n\n📈 Model stats updated (12 total runs)\n```\n\n---\n\n## 🏇 Usage\n\n```\nstampede.sh --run-id \u003cid\u003e --count \u003cn\u003e --repo \u003cpath\u003e [--model \u003cmodel\u003e] [--agent-cmd \u003ccmd\u003e]\nstampede.sh --teardown --run-id \u003cid\u003e\n\nOptions:\n  --run-id      Run identifier (format: run-YYYYMMDD-HHMMSS)\n  --count       Number of agents (1-20, sweet spot: 6-8)\n  --repo        Path to any git repository\n  --model       AI model (default: claude-haiku-4.5)\n  --agent-cmd   Custom CLI agent command (default: GitHub Copilot CLI)\n                Use {prompt} and {model} as placeholders.\n  --teardown    Kill agents, clean up\n  --no-attach   Don't auto-open Terminal window\n```\n\n## 🎮 Tmux Navigation\n\n| Key | What it does |\n|-----|-------------|\n| `tmux attach -t stampede-{run_id}` | Attach to the fleet |\n| `Ctrl-B z` | Zoom one pane full screen |\n| `Ctrl-B z` again | Zoom back out to the grid |\n| `Ctrl-B arrow` | Move between panes |\n| `Ctrl-B d` | Detach (agents keep running) |\n\n\u003e 💬 **Zoom into any pane and talk to the agent mid-task.** Every pane is a live session — watch, redirect, or course-correct while the stampede runs.\n\n\u003e 🖥️ **Best on ultrawide.** 20 agents on a 49\" ultrawide gives each one the space of a normal terminal. One monitor, 20 AI brains, all visible at once.\n\n---\n\n## 🏗️ Architecture\n\n```\n┌─────────────────────────────────────────────────┐\n│  Orchestrator (SKILL.md)                        │\n│  Parses intent → generates tasks → launches     │\n│  agents → polls results → synthesizes           │\n└───────────┬─────────────────────────────────────┘\n            │\n            ▼\n┌─────────────────────────────────────────────────┐\n│  Launcher (stampede.sh)                         │\n│  tmux session → N panes → PID tracking          │\n└───────┬───────┬───────┬───────┬─────────────────┘\n        ▼       ▼       ▼       ▼\n     ┌─────┐┌─────┐┌─────┐┌─────┐\n     │  🦬  ││  🦬  ││  🦬  ││  🦬  │  Each agent: own terminal,\n     │     ││     ││     ││     │  own context window, own branch\n     └──┬──┘└──┬──┘└──┬──┘└──┬──┘\n        │      │      │      │\n        ▼      ▼      ▼      ▼\n   ┌─────────────────────────────────┐\n   │  repo/.stampede/{run_id}/       │\n   │  queue/ → claimed/ → results/  │\n   │                                 │\n   └───────────────┬─────────────────┘\n                   │ all done\n                   ▼\n   ┌─────────────────────────────────┐\n   │  Merger (stampede-merger)       │\n   │  Auto-merge → resolve conflicts│\n   │  → shadow score → leaderboard  │\n   └─────────────────────────────────┘\n```\n\n## 🧠 Design Decisions\n\n| Decision | Why |\n|----------|-----|\n| Filesystem as message queue | Simpler than anything else. `ls queue/` is your debugger |\n| Agents for tasks, skill for orchestrator | Skills load globally, agents load per-session. Clean role isolation. Skill/agent format is Copilot CLI; shell scripts work with any CLI agent |\n| Branch per task | No two agents touch main. Conflicts caught at synthesis |\n| Auto-merger with AI conflict resolution | Reads both task descriptions to resolve conflicts semantically, not just syntactically |\n| Weighted shadow scoring | Completeness (30%) matters most; conflict friendliness (10%) is partly luck |\n| Cross-run model leaderboard | Shows which AI models consistently produce the best work over time |\n| 500-word result cap | Verbose summaries would blow the orchestrator's context |\n| `--max-autopilot-continues 30` | Prevents runaway agents from burning unlimited quota (Copilot CLI flag; other CLIs have their own limits) |\n| Lightweight models for grunt work | Save the powerful model for synthesis, use fast ones for parallel tasks |\n\n---\n\n## 🦬 Origin\n\nBuilt during a [Havoc Hackathon](https://github.com/DUBSOpenHub/havoc-hackathon), where AI models competed to design this framework across elimination rounds with sealed judging. The winning architecture was synthesized from Claude Opus 4.6 (Fast) and GPT-5.3-Codex, then battle-tested with live stampedes on real codebases.\n\n**Read the full story:** [I Split One Terminal Into 20 AI Brains. Here's What Happened. →](BLOG.md)\n\n## 📄 License\n\n[MIT](LICENSE) — use it, fork it, stampede with it. 🦬\n\n---\n\n## 🐙 Created with 💜 by [@DUBSOpenHub](https://github.com/DUBSOpenHub) with the [GitHub Copilot CLI](https://docs.github.com/copilot/concepts/agents/about-copilot-cli).\n\nLet's build! 🚀✨\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdubsopenhub%2Fterminal-stampede","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdubsopenhub%2Fterminal-stampede","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdubsopenhub%2Fterminal-stampede/lists"}