Local Router — AI skill for Claude Code
A local AI gateway for coding agents, with provider routing, protocol translation, console, and CLI.
How to install Local Router
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open huifer/local-router and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Local Router does
A local AI gateway for coding agents, with provider routing, protocol translation, console, and CLI.
Alternatives in AI
- CliRelay — Self-hosted AI gateway for coding CLIs — one OpenAI/Claude/Gemini/Codex-compatible endpoint, with a multi-tena 1k ★
- My Free Code — Open-source multi-provider AI gateway for Claude Code and other coding agents, with model routing, streaming 633 ★
- NeoRead — NeoRead: a local-first EPUB/PDF reader with annotations, side-by-side translation, and AI assistance through C 294 ★
README
local-router
[English](#english) · [中文](#中文)
English
local-router is a local AI gateway that puts multiple model providers behind one process and gives coding agents (Claude Code, Codex, Gemini CLI, OpenCode, and any client that accepts a base URL) one routed, observable API.
Highlights
- One Rust binary: gateway, React console, and CLI.
- Protocol translation: OpenAI Chat, OpenAI Responses, Anthropic Messages, and Gemini, including streaming, tools, reasoning blocks, and token usage.
- Routing groups: ordered failover, rotation, usage-aware, smart, and weighted routing, with sticky sessions, nested groups, and multiple keys.
- Multi-node deployment: run one gateway per machine and cascade them —
point a provider at another local-router (or any OpenAI/Anthropic/Gemini-compatible
endpoint) to route through an overseas egress, with unified routing, failover,
cooldowns, and one trace across hops. Bare model ids resolve when exactly one
provider serves them, so every node can keep the same model names. Each node
is remotely manageable over its own console API (
--lan+ a caller key + your reverse proxy): full config snapshots move between nodes with export/import and optimistic concurrency,local-router remote …queries another node's state, per-node rate limits keep hot nodes in check, and every node exposes/metricsfor Prometheus. See examples/multi-machine and USAGE.md § 8. - Monitoring & tracing exports: a Prometheus
/metricsendpoint for live state — requests, in-flight, cooldowns, token throughput, p99 latency — and an optional OTLP export (cargo build --features otlp) that mirrors the session span tree to Tempo/Jaeger. - Session-backed providers: WorkBuddy and QwenWork without API keys, with account pools, renewal, quota visibility, and check-in support.
- Console: provider, model, route, usage, session, project, conte
Related Skills
AginxBrain
Local-first AI gateway with bidirectional protocol conversion (Anthropic ↔ OpenAI ↔ Responses). Route Claude C
Aethryn
Aethryn — premium multi-provider AI router, gateway and agentic workspace. OpenAI + Anthropic compatible APIs,
Little Mungbean
A free, lightweight AI gateway manager that lets Codex and Claude clients share a switchable, observable local
Agent Switch
A free, lightweight AI gateway manager that lets Codex and Claude clients share a switchable, observable local
Evolve Router
A local-first LLM routing gateway that thinks before it routes — a decision model (Jev / laya) picks the most
Floway
Serverless LLM API gateway with telemetry, full protocol translation and Stateful Responses support. Use any L
Related Agents
Pi Implementer
Implementation lane driven by the pi CLI (a local multi-provider coding agent, distinct from omp). Model-agnos
Local Worker
Coding worker on a local model (Ollama, LM Studio, vLLM) served by the multi-model gateway's upstream. Use whe
Opencode
Coding subagent that runs inside opencode, on any provider and model opencode supports (OpenAI, Google, Moonsh