Navid MoazzezNavid Moazzez

Switchyard

Switchyard is a Rust proxy and library for LLM traffic. It routes requests across providers, translates between OpenAI and Anthropic APIs, records operational metrics, and provides typed, composable routing algorithms. Why Switchyard? Point a coding agent such as Claude Code or Codex at an open-source model. Switchyard translates between the OpenAI Chat, Anthropic Messages, and OpenAI Responses formats, so the agent keeps speaking its native API while the request is served by vLLM, NVIDIA NIM, Ollama, or any OpenAI-compatible endpoint. The same proxy can spread traffic across several models for A/B benchmarking, apply signal-driven stage routing, or run a custom algorithm you write yourself. Protocol Translation: convert between OpenAI Chat, Anthropic Messages, and OpenAI Responses formats Multi-Backend Routing: random routing, LLM-as-classifier routing, signal-driven stage-router, or your own algorithm Operational Metrics: Prometheus metrics cover requests, errors, latency, tokens, and routing overhead Switchyard is pre-alpha software that is evolving rapidly. The API and algorithms are expected to change significantly before we reach v1.0.

View Switchyard on GitHub
Navid Moazzezby Navid Moazzez·Updated Sept 30, 2026·1 min read
Switchyard

Switchyard is a Rust proxy and library for LLM traffic. It routes requests across providers, translates between OpenAI and Anthropic APIs, records operational metrics, and provides typed, composable routing algorithms.

Why Switchyard? Point a coding agent such as Claude Code or Codex at an open-source model. Switchyard translates between the OpenAI Chat, Anthropic Messages, and OpenAI Responses formats, so the agent keeps speaking its native API while the request is served by vLLM, NVIDIA NIM, Ollama, or any OpenAI-compatible endpoint. The same proxy can spread traffic across several models for A/B benchmarking, apply signal-driven stage routing, or run a custom algorithm you write yourself. Protocol Translation: convert between OpenAI Chat, Anthropic Messages, and OpenAI Responses formats Multi-Backend Routing: random routing, LLM-as-classifier routing, signal-driven stage-router, or your own algorithm Operational Metrics: Prometheus metrics cover requests, errors, latency, tokens, and routing overhead

Switchyard is pre-alpha software that is evolving rapidly. The API and algorithms are expected to change significantly before we reach v1.0.

Switchyard at a glance

Stars3.2k
Forks315
LanguageRust
LicenseApache-2.0
Last update2026-09-28
Contributors57

How to install Switchyard

bash curl -LsSf https://astral.sh/uv/install.sh | sh 

Navid Moazzez

AI business strategist & AI OS builder

Navid Moazzez helps creators and founders master AI and build their own AI Operating System (AI OS) to automate their business and life.

Navid.me is reader-supported. When you buy through links on this site, I may earn an affiliate commission. Learn more.

More free tools

Related MCP servers & CLIs

Free AI newsletter

The most actionable AI newsletter for founders

Every week, get proven AI strategies, curated tools, and step-by-step systems to grow your audience, create better content, and build a profitable creator business.

No fluff, no filler, no BS. Just five minutes each week that might level up your online business and life.

P.S. Sign up now to get free access to my ultimate AI tools guide for creators.

Loved by 10,000+ readers