llm-router-ops

llm-router-ops is a skill for Claude Code, Codex from dryvist/claude-code-plugins. It costs 112 tokens per session (999 once invoked), scanned A, original, Apache-2.0.

A guide for operating a self-hosted router that gives several AI clients one OpenAI-compatible address and sends requests to different model backends.

In plain words
What is it for?
Use it to connect command-line tools, Python programs, chat interfaces, or agent builders to a shared model router.
Why use it?
It avoids repeating backend details in every client and highlights configuration issues involving model context limits, stored settings, and health checks.

Skill for Claude CodeCodex

Part of the homelab-ops plugin — 8 skills shipped together

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.

agentmods
npx agentmods add skills/dryvist/claude-code-plugins/llm-router-ops
Any agent
npx skills add dryvist/claude-code-plugins --skill llm-router-ops
Clone the repo
git clone --depth 1 https://github.com/dryvist/claude-code-plugins

Made for: Claude Code, Codex.

Or install homelab-ops, the plugin that ships this one along with the rest of its 8 skills.

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 llm-router-ops

README.md
[![agentmods](https://agentmods.dev/badge/skills/dryvist/claude-code-plugins/llm-router-ops.svg)](https://agentmods.dev/skills/dryvist/claude-code-plugins/llm-router-ops)
Your own site
<a href="https://agentmods.dev/skills/dryvist/claude-code-plugins/llm-router-ops"><img src="https://agentmods.dev/badge/skills/dryvist/claude-code-plugins/llm-router-ops.svg" alt="Measured on agentmods" height="20"></a>
Per session 112 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 999 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
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 $0.00112 $0.00999
Opus 5 $0.00056 $0.00500
Sonnet 5 $0.00022 $0.00200
Haiku 4.5 $0.00011 $0.00100

Measured yesterday against content hash 10fb22b19e21, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

llm-router-ops scanned grade A with 1 finding 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 yesterday.

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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -s https://<router-host>/v1/chat/completions \
homelab-ops/skills/llm-router-ops/SKILL.md · 89 lines

How it starts

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

Operating an OpenAI-compatible LLM router

A self-hosted LLM router (e.g. LiteLLM) gives every consumer — human tool or agent — one shared base URL and one shared bearer key, and load-balances or routes to whichever backend actually serves a given model alias. This is the generic client-wiring and operational-gotcha pattern; your own base URL, model aliases, and key-storage location stay in your own inventory.

Minimal client wiring

Every client type needs the same three things: base URL, bearer key, model alias. The alias is what decouples a client from knowing which backend is really serving it.

curl -s https://<router-host>/v1/chat/completions \
  -H "Authorization: Bearer $ROUTER_MASTER_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model": "<alias>", "messages": [{"role": "user", "content": "hello"}]}'
from openai import OpenAI
client = OpenAI(base_url="https://<router-host>/v1", api_key=os.environ["ROUTER_MASTER_KEY"])

Any tool with an "OpenAI-Compatible" or "OpenAI API" provider type (chat UIs, low-code agent builders, Ansible-style role group vars) takes the same two values — base URL and key — with no other client-specific config needed.

Adding a backend model

  1. Add the model block to the router config: alias name, backend model id, backend base URL.
  2. Set the context window explicitly if the router doesn't already know the backend's real native context. An unrecognized backend id otherwise resolves to a null/unset advertised context, which starves any consumer that trusts the router's advertised limit to decide how much to send.
  3. Restart/reload the router process so the new config takes effect.
  4. Verify: GET /v1/models (with the bearer key) lists the new alias, and its advertised context window is the real one, not null.

Gotcha: env var vs. the tool's own persisted config

Many chat-UI-style front ends persist their provider config in their own database and will silently let that override the environment on a redeploy — so a correct env var stops mattering after the UI's admin panel has ever been touched. If the front end has a "persistent config" or equivalent toggle, disable it so the environment is authoritative on every restart, instead of the tool re-applying whatever was last saved in its UI.

Read the full file on GitHub · 89 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. yesterday First seen · 89 lines · 112 tokens per session scan A 10fb22b19e21

Subscribe to this mod's changes

llm-router-ops is a skill published in the GitHub repository dryvist/claude-code-plugins (3 stars, last pushed today), licensed Apache-2.0. It adds 112 tokens to every session and 999 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-04.

Related

Other skills, from other repositories

prompt-decompiler

This skill should be used when the user says "decompile this prompt", "reverse engineer this prompt", "analyze this prompt", "break down this prompt", "what does this prompt do", "adapt this prompt for", "simplify this prompt", "split this prompt", "migrate this prompt", "why does this prompt work", "explain this…

RadOrigin-LLC/RAD-Claude-Skills · 153 tokens

prompt-engineering

This skill should be used when the user says "write a prompt", "prompt engineering", "system prompt", "optimize my prompt", "create instructions for", "context engineering", "CLAUDE.md", "few-shot examples", "write me a Midjourney prompt", "create a GPT prompt", "prompt for Claude Code", "agentic prompt", "tool…

RadOrigin-LLC/RAD-Claude-Skills · 130 tokens

render-html

Render an ARIS Markdown / JSON artifact (IDEAREPORT, AUTOREVIEW, KILLARGUMENT, PAPERPLAN, research-wiki state, etc.) into a single-file HTML view designed for human reading. Use when the user says "渲染 HTML", "出一份 HTML 报告", "render html", "make this readable", "export to html", or wants a polished web-rendered view of…

wanshuiyin/Auto-claude-code-research-in-sleep · 92 tokens

run-experiment

Deploy and run ML experiments on local, remote, Vast.ai, or Modal serverless GPU. Use when user says "run experiment", "deploy to server", "跑实验", or needs to launch training jobs.

wanshuiyin/Auto-claude-code-research-in-sleep · 47 tokens

serverless-modal

Run GPU workloads on Modal — training, fine-tuning, inference, batch processing. Zero-config serverless: no SSH, no Docker, auto scale-to-zero. Use when user says "modal run", "modal training", "modal inference", "deploy to modal", "need a GPU", "run on modal", "serverless GPU", or needs remote GPU compute.

wanshuiyin/Auto-claude-code-research-in-sleep · 79 tokens

qzcli

Manage GPU compute jobs on the Qizhi (启智) platform using qzcli — a kubectl-style CLI tool. Use when user says "qzcli", "启智平台", "submit job", "stop job", "查计算组", "avail", "list jobs", "batch submit", or needs to manage distributed training jobs on a Qizhi instance.

wanshuiyin/Auto-claude-code-research-in-sleep · 82 tokens