mux

mux is a skill for Claude Code from wowoyong/agent-mux. It costs 15 tokens per session (1,825 once invoked), scanned A, original, MIT.

A task-routing system that chooses between Claude Code and Codex CLI, two command-line tools for working with code.

In plain words
What is it for?
Use it to route coding, review, debugging, design, and other tasks; it can also escalate a failed Codex task to Claude.
Why use it?
It helps send each task to the intended tool while considering task type, available features, and subscription usage.

Skill for Claude Code

Written for Claude Code: SessionStart hook event. Also seen: mentions Claude Code; mentions AGENTS.md; mentions Codex.

Part of the agent-mux plugin — 1 skill, 4 commands, 4 agents, 1 hook shipped together

Good fit Use it to route coding, review, debugging, design, and other tasks; it can also escalate a failed Codex task to Claude.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/wowoyong/agent-mux/mux
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 wowoyong/agent-mux --skill mux
Clone the repo
git clone --depth 1 https://github.com/wowoyong/agent-mux

Made for: Claude Code.

Or install agent-mux, the plugin that ships this one along with the rest of its 1 skill, 4 commands, 4 agents, 1 hook.

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 mux

README.md
[![agentmods](https://agentmods.dev/badge/skills/wowoyong/agent-mux/mux/github.svg)](https://agentmods.dev/skills/wowoyong/agent-mux/mux)
Your own site
<a href="https://agentmods.dev/skills/wowoyong/agent-mux/mux"><img src="https://agentmods.dev/badge/skills/wowoyong/agent-mux/mux/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 mux

Your own site · 80×15
<a href="https://agentmods.dev/skills/wowoyong/agent-mux/mux"><img src="https://agentmods.dev/badge/skills/wowoyong/agent-mux/mux.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 15 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,825 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.00015 $0.01825
Opus 5 $0.00008 $0.00912
Sonnet 5 $0.00003 $0.00365
Haiku 4.5 $0.00002 $0.00183

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

Security

Grade A, and why

mux 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 9d 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/mux/SKILL.md · 149 lines

How it starts

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

agent-mux: Intelligent Task Router

You are the agent-mux orchestrator. Your job is to analyze user tasks and route them to the optimal CLI (Claude Code or Codex CLI) based on task characteristics and subscription budget.

Core Principles

  1. Zero-overhead routing at Budget tier: Use keyword matching and heuristics. Do NOT consume Claude messages for routing decisions.
  2. Codex-first at Budget tier: When uncertain, route to Codex to conserve Claude messages.
  3. Escalation over duplication: If Codex fails, pass its output to Claude to FIX (1-2 msgs), not REDO (3-8 msgs).

Workflow

When the user runs /mux "task description":

  1. Call the get_mux_status MCP tool to check current budget and tier
  2. Analyze the task using keyword patterns:
    • Codex signals: write tests, create file, add docs, fix lint, rename, implement endpoint, update deps, convert, fix bug/error
    • Claude signals: architect, design, scaffold, debug (complex), review, explain, refactor across, security audit (project-wide), best approach
  3. Apply hard rules (Phase 1):
    • Needs MCP tools -> Claude (only Claude Code can access MCP tools)
    • Interactive/conversation context -> Claude (session context lives in Claude Code)
    • Security audit (standalone, single file) -> Codex (systematic scanning is Codex strength)
    • Multi-file refactoring (>5 files) -> Claude (requires cross-file understanding)
    • Scaffolding -> Claude (needs full architecture context)
  4. If no hard rule matches, use weighted scoring (Phase 2):
    • Compute score = sum(signal_weight * signal_value) + sum(interaction_modifier)
    • confidence = |score| / max_possible_score
    • score > 0 -> Codex, score < 0 -> Claude, score == 0 -> budget tiebreaker
  5. Show routing decision: [agent-mux] Routing -> {target} ({reason}, confidence: {pct}%)

Signal Weights

Claude-favoring signals (negative weight)

Signal Weight Description
needsMCP -100 Hard rule: MCP tool access required
needsConversationContext -100 Hard rule: previous conversation context needed
isInteractive -100 Hard rule: interactive dialogue required
isScaffolding -100 Hard rule: project structure creation
isArchitectural -40 Architecture design or system-level thinking
isMultiFileOrchestration -35 Coordinating changes across many files
needsProjectContext -30 Deep project structure understanding
isFrontend -20 Frontend/UI work (visual feedback helpful)

Read the full file on GitHub · 149 lines

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. 9d ago First seen · 149 lines · 15 tokens per session scan A 125101ff706d

Subscribe to this mod's changes

mux is a skill published in the GitHub repository wowoyong/agent-mux (1 stars, last pushed 5mo ago), licensed MIT. It adds 15 tokens to every session and 1,825 once invoked, about $0.0001 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.

Related

Other skills, from other repositories

claude-code-session-broker

Use when running Arcgentic V2 in Claude Code and fixed Planner, Developer, and Auditor role sessions must be coordinated through a broker.

Arch1eSUN/Arcgentic · 35 tokens

arcgentic

Use when the user says Arcgentic, asks to use Arcgentic, or wants an idea taken through a complete plan → development → self-audit → external audit workflow in Codex.

Arch1eSUN/Arcgentic · 43 tokens

espalier-migrate

Migrate an existing harness/espalier install to the current Espalier version — auto-detects which of v0.1→v0.2, v0.3→v0.4, v0.4→v0.5, the v0.5.3 coder-agent patch, v0.5→v0.6 (Stage 1 grill), v0.6→v0.7 (read-only /espalier-ask lane), v0.7→v0.8 (requirements approval gate), the v0.8.1 impact-analysis agent patch, the…

Junhanliu-dev/espalier-engineering · 0 tokens

verify-gates

Runs the mechanical quality gates that the arcgentic state machine requires for state transitions. Invoked indirectly by transition.sh OR directly by orchestrator agent before declaring a state transition. Use when about to call transition.sh OR when manually verifying that a round artifact meets the gate criteria.…

Arch1eSUN/Arcgentic · 75 tokens

session-mode

Use when a project has not yet stored session mode, when a user asks for complete arcgentic workflow execution, or when role identity handoff prompts are needed.

Arch1eSUN/Arcgentic · 36 tokens

cross-session-handoff

Read, write, snapshot, and lock .arcgentic/state.yaml across planner, dev, audit, and optional test sessions.

Arch1eSUN/Arcgentic · 31 tokens