cmux

cmux is a skill for Claude Code from ph3on1x/claude-cmux-skill. It costs 64 tokens per session (3,922 once invoked), scanned A, original, MIT.

A control tool for cmux, a macOS terminal designed for running coding agents in separate panes and browser surfaces.

In plain words
What is it for?
It helps create parallel agent sessions, arrange panes or workspaces, inspect the current terminal layout, automate browsers, and send cmux notifications.
Why use it?
It makes it easier to start, organize, monitor, and automate several agent sessions in a terminal workspace.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: reads .claude/ paths; positional $N argument; mentions Claude Code.

Part of the claude-cmux-skill plugin — 1 skill, 3 hooks shipped together

Good fit It helps create parallel agent sessions, arrange panes or workspaces, inspect the current terminal layout, automate browsers, and send cmux notifications.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ph3on1x/claude-cmux-skill/cmux
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add ph3on1x/claude-cmux-skill --skill cmux
Clone the repo
git clone --depth 1 https://github.com/ph3on1x/claude-cmux-skill

Made for: Claude Code.

Or install claude-cmux-skill, the plugin that ships this one along with the rest of its 1 skill, 3 hooks.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for cmux

README.md
[![agentmods](https://agentmods.dev/badge/skills/ph3on1x/claude-cmux-skill/cmux/github.svg)](https://agentmods.dev/skills/ph3on1x/claude-cmux-skill/cmux)
Your own site
<a href="https://agentmods.dev/skills/ph3on1x/claude-cmux-skill/cmux"><img src="https://agentmods.dev/badge/skills/ph3on1x/claude-cmux-skill/cmux/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for cmux

Your own site · 80×15
<a href="https://agentmods.dev/skills/ph3on1x/claude-cmux-skill/cmux"><img src="https://agentmods.dev/badge/skills/ph3on1x/claude-cmux-skill/cmux.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 64 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 3,922 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00064 $0.03922
Opus 5 $0.00032 $0.01961
Sonnet 5 $0.00013 $0.00784
Haiku 4.5 $0.00006 $0.00392

Measured 10d ago against content hash e8d9df38bedd, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

cmux scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/cmux/SKILL.md · 386 lines

How it starts

The opening of the file, as written. The whole thing — 386 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Using cmux

cmux is a macOS terminal built for AI coding agents. The session runs inside cmux when CMUX_SOCKET_PATH is set.

Quick Orientation

cmux identify --json    # Current workspace, pane, surface
cmux tree --json        # Full hierarchy of windows/workspaces/panes/surfaces

Hierarchy: Window -> Workspace (sidebar tab) -> Pane (split region) -> Surface (terminal or browser tab)

Refs format: workspace:2, pane:1, surface:7 — always prefer short refs over UUIDs.

Environment Variables (Auto-Set)

Variable Purpose
CMUX_SOCKET_PATH Control socket (CLI uses automatically)
CMUX_WORKSPACE_ID Current workspace UUID
CMUX_SURFACE_ID Current surface UUID

Commands default to the current workspace/surface when flags are omitted.

Agent Orchestration

The core pattern for running multiple agents in parallel, each in its own pane.

Default: panes, not workspaces. Use cmux new-split to create splits within the current workspace. Only use cmux new-workspace when agents need completely separate project directories (e.g., monorepo subprojects with different --cwd).

Creating Balanced Pane Layouts

Each new-split returns the created surface ref — always capture it to target subsequent splits and commands:

S1=$(cmux new-split right | awk '{print $2}')   # Capture "surface:N" from "OK surface:N workspace:N"

Critical rule: always use --surface to target which pane to split. Without it, cmux splits whichever pane has focus — leading to recursive halving of one pane while others stay untouched.

Layout recipes by agent count

1 agent — single split:

S1=$(cmux new-split right | awk '{print $2}')
# Layout: [orchestrator 50% | agent-1 50%]

2 agents — split right, then subdivide:

S1=$(cmux new-split right | awk '{print $2}')
S2=$(cmux new-split down --surface $S1 | awk '{print $2}')
# Layout: [orchestrator 50% | agent-1 25%]
#                            | agent-2 25%]

Read the full file on GitHub · 386 lines

Files

What ships with it

4 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 386 lines · 64 tokens per session scan A e8d9df38bedd

Subscribe to this mod's changes

cmux is a skill published in the GitHub repository ph3on1x/claude-cmux-skill (9 stars, last pushed 5mo ago), licensed MIT. It adds 64 tokens to every session and 3,922 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.