Skip to content

Latest commit

 

History

545 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MuxLayer Logo

MuxLayer

The local model control layer for coding agents.
Use Codex, Claude Code, Gemini CLI, and OpenCode with the models you actually want.

Codex · Claude Code · Gemini CLI · OpenCode

MuxLayer

DeepSeek · Kimi · MiMo · OpenAI · Anthropic · OpenRouter · Ollama · 25+ model providers

Release Stars Downloads License

中文 · Download · Quick Start · Full Reference · 💬 Discussions

MuxLayer intercepts requests from Claude Code, Codex, and Gemini CLI at a local gateway — converting, passing through, routing, or failing over across 25+ model providers, with every request traced live

MuxLayer is a local gateway for AI coding workflows. Requests enter through one controlled endpoint, then MuxLayer routes, converts, passes through, fails over, and records what happened.

Why MuxLayer

  • Keep your clients: Continue using Codex, Claude Code, Gemini CLI, OpenCode, and AtomCode with one-click config restore.
  • Choose the model path: Route each request to the provider and model you want, with protocol conversion when needed.
  • See every request: Inspect route decisions, payload diffs, upstream errors, tokens, cost, latency, and failover locally.

MuxLayer is not a hosted API reseller or a generic proxy. It is a local control layer between your coding agents and the model APIs they use.

Quick Start

  1. Download MuxLayer and open it.
  2. Open Quick Setup or Providers, then paste a provider API key.
  3. Start the gateway. The default endpoint is http://127.0.0.1:9090.
  4. Open Clients and apply the Codex, Claude Code, OpenCode, Gemini CLI, or AtomCode configuration.

Send a test request, then open Logs to see the selected provider, model, route, status, and latency. The original client configuration can be restored at any time.

What it handles

Capability What it gives you
Protocol conversion Responses, Chat Completions, and Anthropic Messages can meet the upstream protocol they need.
Routing and failover Select providers by route profile, conditions, health, cooldown, and fallback order.
Request tracing Compare raw and converted payloads, route decisions, upstream status, latency, tokens, and cost.
Session affinity Keep multi-turn conversations on the provider that started them, unless an override is required.
Local models and budgets Discover Ollama / LM Studio endpoints and optionally gate daily spend.

Screenshots

Request trace Overview
MuxLayer request trace MuxLayer overview

Supported clients and providers

Clients: Codex · Claude Code · Gemini CLI · OpenCode · AtomCode · Cursor / Continue / Cline

Providers: OpenAI · Anthropic · DeepSeek · Kimi · MiMo · Gemini · OpenRouter · Groq · Mistral · Ollama · LM Studio · and 25+ model providers.

See the full provider compatibility matrix and the usage guides.

All supported providers
Provider Type Native Protocols Provider-Specific Handling
Xiaomi MiMo mimo Chat + Anthropic Multi-turn reasoning_content round-trip, region-aware tp-* host auto-routing, temperature strip in thinking mode, tool_choice non-auto strip, omni web_search strip, web_search builtin gated by matrix, Web Search Plugin auto-degrade / retry
DeepSeek deepseek Chat + Anthropic Vision model preserves image inputs; text-only models strip images with an explicit notice; DeepSeek V4 thinking history reasoning backfill, schema cleaning, message reordering
Anthropic (Claude) anthropic Anthropic tool_use/tool_result, input_schema, thinking budget, native cache_control
GitHub Copilot copilot Chat + Anthropic GitHub token → Copilot bearer exchange, x-initiator billing classification, Claude model dash→dot normalization
OpenAI openai Chat + Responses None (Responses passthrough or Chat conversion)
Google Gemini google_gemini Chat None
Kimi / Moonshot kimi Chat + Anthropic web_searchbuiltin_function/$web_search; K3 uses reasoning_effort:max (no K2 thinking param); coding models keep thinking on/off control
MiniMax minimax Chat Strip reasoning_effort / response_format, <think> extraction
GLM (Zhipu) glm Chat Generic
DashScope (Qwen) dashscope Chat Generic
SiliconFlow siliconflow Chat Generic
Volcengine (Doubao) volcengine Chat Generic
Baichuan baichuan Chat Generic
StepFun stepfun Chat Generic
SenseNova sensenova Chat Drops null strict / response_format / non-function tools, merges system messages
Yi (01.AI) yi Chat Generic
ModelScope modelscope Chat Generic
xAI (Grok) xai Chat Generic
Mistral mistral Chat Generic
Groq groq Chat Generic
Together together Chat Generic
Fireworks fireworks Chat Generic
Cerebras cerebras Chat Generic
Perplexity perplexity Chat Generic
Cohere cohere Chat Generic
OpenRouter openrouter Chat None
Custom custom_openai_compatible Chat None (set Base URL yourself)

Install

Platform Package
macOS Apple Silicon MuxLayer 2.0.1
macOS Intel MuxLayer 2.0.1
Windows 10 / 11 MuxLayer 2.0.1
Debian / Ubuntu MuxLayer 2.0.1
Other Linux distros MuxLayer 2.0.1

On macOS:

brew install --cask dengmengmian/tap/muxlayer

Windows: Builds are currently unsigned, so SmartScreen may warn on first install. See the installation and build notes.

Existing installations using the legacy agentgate cask remain supported and continue receiving the MuxLayer app. New installations should use muxlayer.

Documentation

Open-source toolkit

MuxLayer is part of a small AI developer toolkit:

  • CodeLeveler — inspect, edit, run, and verify code in the terminal.
  • ReviewGate — review code changes and surface high-confidence issues.

Development

pnpm install
pnpm tauri dev
pnpm brand:check
pnpm test:run
pnpm build

Community

Compatibility

MuxLayer was formerly AgentGate. Existing desktop update identity, data directories, and legacy headless names remain compatible; see the brand migration plan.

License

MIT

Releases

Packages

Contributors

Languages