Switchback MCP
Switchback MCP
MCP server for Switchback — 按复杂度对 AI 智能体回合进行分类,并选择能处理它们的最便宜模型。可直接用于 Claude Desktop、Cursor、Cline 以及任何 MCP 客户端。
功能
通过 Model Context Protocol 暴露两个工具:
classify_turn— 给定用户消息,返回{tier: 0|1|2, why, fallback, durationMs}。当您决定是否在旗舰模型上花费,还是为下一个智能体步骤保留便宜模型时使用它。recommend_model— 给定用户消息 + 模型阶梯(便宜 → 旗舰),返回阶梯上能合理处理它的最便宜模型。是classify_turn的便捷包装。
两个工具都通过 OpenRouter 发起一次小型模型调用(默认:openai/gpt-5.4-mini,约 $0.0001/次)。故障软降级:任何错误都返回 tier 1 且 fallback: true,而不是阻塞您的智能体。
Related MCP server: oracle-models
安装
npm install -g vibekit-switchback-mcp配置
设置您的 OpenRouter 密钥(在 https://openrouter.ai/keys 获取):
export OPENROUTER_API_KEY=sk-or-...可选:覆盖分类器模型:
export SWITCHBACK_CLASSIFIER_MODEL=anthropic/claude-haiku-4.5Claude Desktop
添加到您的 ~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"switchback": {
"command": "npx",
"args": ["-y", "vibekit-switchback-mcp"],
"env": {
"OPENROUTER_API_KEY": "sk-or-..."
}
}
}
}Cursor / Cline / 其他
任何支持 stdio 服务器的 MCP 客户端。使用相同的 npx 调用。
示例调用
classify_turn:
{
"userMessage": "rebuild the auth flow with passkeys"
}返回:
{
"tier": 2,
"why": "architectural rework + new auth method",
"fallback": false,
"durationMs": 412
}recommend_model:
{
"userMessage": "fix typo in README",
"ladder": [
"openai/gpt-5.4-mini",
"openai/gpt-5.4",
"openai/gpt-5.5"
]
}返回:
{
"recommended_model": "openai/gpt-5.4-mini",
"tier": 0,
"ladder_size": 3,
"classifier": { "tier": 0, "why": "trivial copy edit", "fallback": false, "durationMs": 318 }
}何时使用
多步智能体,可以在各轮之间切换模型。
BYOK 风格产品,希望将所有路由保留在用户选择的品牌内 — 为每个用户传递品牌锁定的阶梯。
成本敏感的编排器,希望避免在琐碎回合上花费旗舰费率。
何时不要使用
一次性聊天补全,无法在首次调用后更换模型 — 请改用 OpenRouter 的
auto或 NotDiamond/Martian。延迟关键的 200ms 以下首 token 体验 — 分类器会增加 200-500ms。
许可证
MIT。参见 LICENSE。
由 VibeKit 构建。核心库是 vibekit-switchback — 本包是其 MCP 包装器。
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA model routing advisor for autonomous agents — get cost-optimised LLM recommendations via MCP.15MIT
- AlicenseAqualityDmaintenanceClassifies development task complexity (LIGHT/MEDIUM/HEAVY) and recommends the most cost-efficient AI model per provider, enabling optimized model selection for coding tasks.3666MIT
- AlicenseAqualityDmaintenanceOptimizes token costs by intelligently delegating low-complexity tasks to local LLMs via LiteLLM, enabling cost-effective development workflows.31MIT
- AlicenseAqualityCmaintenancePre-execution cost estimation for LLM agent workflows, providing cost estimates before running tasks and improving accuracy over time through calibration.62MIT
Related MCP Connectors
Reduces AI Agent token usage by 40% via three-stage SOP workflow.
SaaS intelligence for AI agents. 5 unified tools cover 1,000+ services with 91-96% token savings.
See, price, and control every tool call your AI agents make: policy checks, cost, and audit tools.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/VibeKit-Bot/vibekit-switchback-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server