ClaudeCodeMod

All shelves / Mods / Usage

agent-router

By alexandernicholson

agent-router is a Claude Code usage mod by alexandernicholson.

Assigns a model and effort to each subagent role from your endpoint's catalog, and draws that model beside the prompt.

DrawsHolds a command

Install

The marketplace name is agent-router-tools.

In Claude Code
/plugin marketplace add alexandernicholson/agent-router
/plugin install agent-router@agent-router-tools
Open the repo

It runs inside the Claude Code process. The side panel is only what the author's README names. Read the repo before you install, or run claude plugin validate on the plugin folder.

Version
0.17.1
License
MIT
Repo stars
7
Last change
2026-10-14

What it can reach

  • Draws in the session
  • Reads usage or context figures
  • Holds a command
  • Reaches the network or an outside service
  • Sees tool calls
  • Calls another program on this machine

Needs Claude Code 2.1.289 or newer, and Node.js 22 or newer on PATH. The README asks you to start Claude Code with CLAUDE_CODE_ENABLE_FUNCTION_HOOKS=1. The official docs say 2.1.287 and later ignore that flag. Routing turns on when ANTHROPIC_BASE_URL is set, including an explicit https://api.anthropic.com. Model discovery calls GET /v1/models on that base URL. A remote endpoint is HTTPS, and the key or token you set is sent there. A loopback address, localhost, 127.0.0.1, or ::1, keeps that same call on this machine. /agent-models opens the picker. Choose a model for all five roles: scout, reviewer, security-reviewer, task, and sonic. Each role's effort defaults to Claude Code's own, or you pin low, medium, high, xhigh, or max. Saved changes apply to the next session, or now with /agent-models-apply. Subagents already running keep the model they started with. The prompt shows a clickable icon while routing is on, and the model and effort of the agent whose transcript you are viewing. Click it to cycle Activity, Usage, and Routing. The README's sample counts are a layout, not a measured session. Usage totals are completed-turn input, output, and cache-read tokens for this session. Plan, and agent types this plugin does not map, are refused as teammates. Other teammate types take the role's model, or teammate_model when you set it. Records stay under ~/.claude/plugins/data/agent-router-agent-router-tools/. The routes file holds model, effort, and teammate links, and no prompts or credentials. The README does not say how to delete those records. A terminal of at least 110 columns is needed for the picker.

The marketplace agent-router-tools also holds keepalive. The slug is this plugin's own name. The icon beside the prompt shows the model and effort of the agent in view, which is why this page files it under usage. claude-router picks a model and effort for each turn from a classifier and draws the tier above the prompt. This one assigns a model and effort you choose to each subagent role, from your endpoint's catalog. A discovery call to a remote endpoint is the network access. The same call to a loopback address is the local program, and it is not also listed as network. Refusing Plan and unmapped types as teammates is the hold. The role's own model calls are Claude Code's requests to the endpoint you set, so this page does not list those as this mod's network access.

Demo

The agent-router README on the author's GitHub page
Screenshot of the author's GitHub page.

What it hooks into

  • tool.callAround a tool call, where it can hold one
  • session.startWhen a session starts
  • agent.spawnWhen a subagent starts
  • turn.stepAt each step of a turn
  • turn.completeWhen a turn ends
  • ui.renderDraws into the sessionAbovePromptPane
  • session.endWhen a session ends
  • command.runWhen you run its slash command/agent-models-apply/agent-models
  • ui.closeWhen its pane closes

Read from the on() calls in its hook modules. Open its source under Files to check what each one does.

Slash commands 1

  • /agent-models-applyApply saved Agent Router role models and efforts to this session now.

Files

The author's README and source, 4 files. They load when you open them.

Facts

Author
alexandernicholson
Category
Usage
Marketplace
agent-router-tools
Repo
alexandernicholson/agent-router
Folder
agent-router
Version
0.17.1
License
MIT
Repo stars
7
Last change
2026-10-14
Language
JavaScript
Files
50

Other mods in Usage

keepalivealexandernicholsonDraws a prompt-cache bar for each conversation, and can keep an idle cache warm or compact it before it expires.hudhoobnnDraws model, context, and plan-usage gauges above the prompt, with git, the running tools, and a one-line task summary.limits-meterice-lfernandesDraws plan limits and context above the prompt, in tokens and percent, with the model, effort, and a toast on a costly switch.elizabeth-progressYaxin9LuoDraws Elizabeth from Gintama walking a context-window bar above the prompt, with the usage split, turns left, and rate limits.spending-effort-with-jevYaxin9LuoAsks TypeSafe's Jev which /effort level a message needs, sends that message to api.typesafe.ai, and switches on your OK.cache-paneldanyuchnAfter 50 idle minutes, draws a prompt-cache line and a panel to keep it warm, ping it once, or compact, with a cost for each.context-cardNongfsqDraws context fill, the prompt cache, and weekly plan usage in one line above the prompt, with a breakdown on click. One of two mods for running many sessions.statuslineryanclarkDraws context, the 5-hour and 7-day limits, and extra usage under the prompt, from statusline, a status-line binary you install first.usage-headerSzotaszDraws the context window above the prompt, a color per category, with the 5-hour and weekly limits under it.green-lanternvogiaan1904Draws the 5-hour and 7-day limits as Green Lantern charge that drains as you use it, with a power-ring spinner and an emerald theme.long-live-the-claudeLapis0x0Draws the 5-hour and 7-day limits, context, and cache time above the prompt. Long-run, off by default, keeps the cache warm and pauses near the limit.usage-petmanson341349-beepDraws context, the 5-hour and weekly limits, and the cache hit rate above the prompt. The desktop Code tab draws four rings, with a pixel pet beside them.
All 183 in Usage