Spaces:
Running
Running
File size: 18,397 Bytes
660d724 b763d2f 660d724 b763d2f 660d724 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 | <!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>Switchboard</title>
<meta name="description" content="A 0.5B open-weights router that picks the cheapest model that can handle each prompt. Try it in your browser.">
<meta property="og:title" content="Switchboard">
<meta property="og:description" content="You don't call a surgeon to put on a plaster. Switchboard sends each prompt to the cheapest model that can handle it: 64.5% cheaper than always using Claude Opus 5.5 on 10,000 held-out prompts.">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,500;9..144,600;9..144,700&family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@400;600&display=swap" rel="stylesheet">
<link rel="icon" href="data:image/svg+xml,%3Csvg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 24 24%22%3E%3Ccircle cx=%225%22 cy=%2212%22 r=%223%22 fill=%22%23ea580c%22/%3E%3Ccircle cx=%2219%22 cy=%225%22 r=%222.4%22 fill=%22%23ea580c%22/%3E%3Ccircle cx=%2219%22 cy=%2212%22 r=%222.4%22 fill=%22%23ea580c%22/%3E%3Ccircle cx=%2219%22 cy=%2219%22 r=%222.4%22 fill=%22%23ea580c%22/%3E%3C/svg%3E">
<link rel="stylesheet" href="style.css?v=14">
</head>
<body>
<header class="top">
<div class="top-inner">
<a class="brand" href="#">
<svg class="brand-mark" viewBox="0 0 24 24" aria-hidden="true"><circle cx="5" cy="12" r="3"/><circle cx="19" cy="5" r="2.4"/><circle cx="19" cy="12" r="2.4"/><circle cx="19" cy="19" r="2.4"/><path d="M8 12c4 0 5-7 8.6-7"/></svg>
Switchboard
</a>
<nav class="nav">
<a href="#demo">Demo</a>
<a href="#how">How it works</a>
<a href="#agents">Agents</a>
<a href="savings.html">Savings</a>
<a href="evaluation.html">Evaluation</a>
<a href="#faq">FAQ</a>
<a href="https://huggingface.co/switchboardllm/switchboard-router-0.5b">Model card</a>
</nav>
<a class="btn btn-primary btn-sm" href="#demo">Try the router</a>
</div>
</header>
<main>
<section class="hero">
<div class="wrap center">
<p class="badge"><span class="dot" aria-hidden="true"></span>Open weights. Runs in your browser.</p>
<h1>You don't call a surgeon<br><span class="accent">to put on a plaster</span>.</h1>
<p class="lede">Most questions to AI are plasters. Switchboard reads each prompt first and sends it to the cheapest model that can handle it, so you only pay frontier prices when a prompt needs it.</p>
<div class="receipts">
<p class="receipts-title">The receipts, on 10,000 prompts it never saw</p>
<ul>
<li><b>64.5% cheaper</b> than always using Claude Opus 5.5</li>
<li><b>5.5%</b> sent to a model too small (random routing: 10.0%)</li>
<li>Every prompt and every answer is public</li>
</ul>
</div>
<div class="cta-row">
<a class="btn btn-primary" href="#demo">Route a prompt</a>
<a class="btn btn-green" href="evaluation.html">See every answer</a>
</div>
<p class="spec">0.5B parameters · <a href="https://huggingface.co/switchboardllm/switchboard-router-0.5b">open weights, Apache 2.0</a> · one line of JSON out</p>
</div>
<div class="wrap">
<figure class="board-card">
<canvas id="board" class="board-canvas" aria-label="Animation: prompts flowing into the router and out to the small, mid or frontier line"></canvas>
<figcaption class="board-note">Real prompts from the held-out set and the tier Switchboard v0.1 actually picked. We show an equal number per tier, so the mix isn't to scale.</figcaption>
</figure>
</div>
</section>
<section class="tiers-strip">
<div class="wrap">
<p class="strip-title">Three tiers, one decision per prompt</p>
<ul class="tier-cards" id="tier-cards">
<li class="tier-card" data-tier="small"><span class="lamp" aria-hidden="true"></span><b>Small</b><span class="tier-model" data-model="small"></span></li>
<li class="tier-card" data-tier="mid"><span class="lamp" aria-hidden="true"></span><b>Mid</b><span class="tier-model" data-model="mid"></span></li>
<li class="tier-card" data-tier="frontier"><span class="lamp" aria-hidden="true"></span><b>Frontier</b><span class="tier-model" data-model="frontier"></span></li>
</ul>
</div>
</section>
<section class="band white" id="demo">
<div class="wrap">
<h2 class="center">Try it on your own prompt</h2>
<p class="section-lede center">The real model runs in this tab. Nothing you type leaves your device.</p>
<div class="demo">
<label for="prompt" class="field-label">Prompt</label>
<textarea id="prompt" rows="4" maxlength="2000" placeholder="Paste any prompt you'd send to an LLM"></textarea>
<div class="samples" role="group" aria-label="Sample prompts">
<button type="button" class="chip" data-prompt="What is the capital of France?">Capital of France</button>
<button type="button" class="chip" data-prompt="Write a haiku about rain">Haiku about rain</button>
<button type="button" class="chip" data-prompt="Design a rate limiter for 10M requests per second across 5 regions, with failure modes and consistency trade-offs">Global rate limiter</button>
<button type="button" class="chip" data-prompt="Unscramble the following words: eglar, ngareo, kobo">Unscramble words</button>
</div>
<div class="demo-actions">
<button type="button" id="route" class="btn btn-primary">Route prompt</button>
<p id="status" class="status" role="status" aria-live="polite">The first route downloads the router once (660 MB). After that it runs offline in this tab.</p>
</div>
<div class="meter" id="meter" hidden><span id="meter-fill"></span></div>
<div class="readout" id="readout" hidden>
<div class="readout-tiers" aria-hidden="true">
<span data-pick="small">Small</span><span data-pick="mid">Mid</span><span data-pick="frontier">Frontier</span>
</div>
<pre id="json"></pre>
<p id="verdict"></p>
</div>
</div>
</div>
</section>
<section class="band cream" id="how">
<div class="wrap">
<h2 class="center">How it works</h2>
<p class="analogy">Think of an old telephone switchboard. An operator listened to each caller and plugged the line into the right place. Switchboard does the same with your questions to AI: it reads each one and connects it to an AI that's good enough for it, without paying for the most expensive one every time.</p>
<div class="explainer">
<div class="story">
<div class="story-step"><span class="step-n">1</span><div><h3>You ask something</h3><p>A question, a request to write or fix something, anything you'd type into a chatbot.</p></div></div>
<div class="story-step"><span class="step-n">2</span><div><h3>Switchboard reads it first</h3><p>A small AI decides how hard the question is. "What's the capital of France?" is easy. A tricky math proof is hard. This takes less than half a second (288 ms median on a laptop) and costs almost nothing.</p></div></div>
<div class="story-step"><span class="step-n">3</span><div><h3>It goes to the right AI</h3><p>Easy questions go to a small, cheap AI. Medium ones go to a mid-size AI. Only the hard ones go to the most powerful, most expensive AI.</p></div></div>
<div class="story-step"><span class="step-n">4</span><div><h3>You pay less for the same answers</h3><p>Most everyday questions are easy, so most of them stop being billed at the top price. On 10,000 test prompts, the bill came out 64.5% lower than always using the top model. When Switchboard can't read its own answer, it plays it safe and picks the powerful AI.</p></div></div>
</div>
<aside class="bill" aria-labelledby="bill-title">
<h3 id="bill-title">Same 1,000 questions, two bills</h3>
<p>Each answer about 500 tokens (roughly 375 words), at list output prices.</p>
<div class="bill-row"><span>Every question to Claude Opus 5.5</span><b id="bill-all">…</b><span class="bill-bar"><i style="width:100%"></i></span></div>
<div class="bill-row ours"><span>With Switchboard picking the AI</span><b id="bill-routed">…</b><span class="bill-bar"><i id="bill-routed-bar" style="width:0%"></i></span></div>
<p class="fineprint" id="bill-note">Based on Switchboard's results on 10,000 test questions.</p>
</aside>
</div>
</div>
</section>
<section class="band white" id="results">
<div class="wrap">
<h2 class="center">Results</h2>
<p class="section-lede center" id="results-intro">Loading the latest evaluation.</p>
<div class="stats" id="figures"></div>
<p class="fineprint center" id="fineprint"></p>
<div class="cta-row"><a class="btn btn-ghost" href="evaluation.html">See the full evaluation</a></div>
</div>
</section>
<section class="band cream" id="start">
<div class="wrap narrow">
<h2 class="center">Up and running in a few minutes</h2>
<p class="section-lede center">Run it on your own computer. No GPU, account or API key needed.</p>
<ol class="steps">
<li><span class="step-n">1</span><h3>Get Ollama</h3><p>Download it free from <a href="https://ollama.com">ollama.com</a> and open it once.</p></li>
<li><span class="step-n">2</span><h3>Ask Switchboard</h3><p>Paste the line below into a terminal. The first run downloads the model once (994 MB).</p></li>
<li><span class="step-n">3</span><h3>Read the answer</h3><p>The tier tells you which size of AI to use. Here, a small one is enough.</p></li>
</ol>
<pre class="code run-code"><code><span class="prompt">$</span> ollama run hf.co/switchboardllm/switchboard-router-0.5b-GGUF "Write a haiku about rain"
<span class="answer">{"tier":"small","domain":"writing"}</span></code></pre>
<h3 class="facts-title">From your own code</h3>
<pre class="code run-code"><code><span class="prompt">$</span> pip install switchboard-router
from switchboard_router import Router
router = Router() # uses Ollama on this computer
router.pick_model("Write a haiku about rain")
<span class="answer">'anthropic/claude-haiku-5.5'</span></code></pre>
<p class="fineprint center">No other dependencies. It works with Ollama, any OpenAI-compatible server, or Transformers, and falls back to the frontier model if routing fails. <a href="https://pypi.org/project/switchboard-router/">switchboard-router on PyPI</a></p>
<h3 class="facts-title">What's inside Switchboard</h3>
<div class="table-wrap">
<table class="facts">
<tr><th>Size</th><td>0.5 billion parameters. 994 MB to run on your computer, 660 MB in the browser.</td></tr>
<tr><th>Built on</th><td>Qwen2.5-0.5B-Instruct (Apache 2.0), fully fine-tuned</td></tr>
<tr><th>Trained on</th><td>63,749 real prompts from routellm/gpt4_dataset (Apache 2.0)</td></tr>
<tr><th>Training time</th><td>55 minutes on one RTX 5070 Ti</td></tr>
<tr><th>Answers with</th><td>One line of JSON: a tier (small, mid or frontier) and a topic (code, math, writing or general)</td></tr>
<tr><th>Runs on</th><td>Ollama, llama.cpp, Transformers, and your browser</td></tr>
<tr><th>License</th><td>Apache 2.0, free for commercial use</td></tr>
</table>
</div>
</div>
</section>
<section class="band white" id="agents">
<div class="wrap narrow">
<h2 class="center">For agents: pick the model at every step</h2>
<p class="section-lede center">An agent calls a model at every step: read a file, search, call an API, write the answer. Most of those steps are plasters too. The agent router reads the tools and the conversation so far, and picks the model for the next step.</p>
<ol class="steps">
<li><span class="step-n">1</span><h3>Your agent offers tools</h3><p>Any agent that uses an OpenAI client sends <code>model="auto"</code> with its tools to <code>switchboard serve</code>.</p></li>
<li><span class="step-n">2</span><h3>Switchboard reads the step</h3><p>A separate 0.5B router reads the tools, the task and the latest turns. Can a small model make this tool call right?</p></li>
<li><span class="step-n">3</span><h3>Unsure steps go up</h3><p>If it gives the big model even a 20% chance of being needed, the step goes to the big model.</p></li>
</ol>
<div class="receipts">
<p class="receipts-title">The receipts, on 2,805 agent steps it never saw</p>
<ul>
<li><b>5.8%</b> sent to a model too small in careful mode, <b>19.2%</b> saved</li>
<li><b>13.5%</b> on its own pick, <b>31.4%</b> saved (random routing: 24.9%)</li>
<li>Labels are real tests: did Qwen3-1.7B or Qwen3-8B make the right call?</li>
</ul>
</div>
<pre class="code run-code agent-code"><code><span class="prompt">$</span> pip install switchboard-router
<span class="prompt">$</span> switchboard serve
client = OpenAI(base_url="http://127.0.0.1:8787/v1", api_key="sk-or-...")
client.chat.completions.create(model="auto", messages=messages, tools=tools)
<span class="answer">x-switchboard-router: step x-switchboard-tier: small</span></code></pre>
<div class="cta-row"><a class="btn btn-ghost" href="https://huggingface.co/switchboardllm/switchboard-agent-router-0.5b">Every number on the agent router card</a></div>
</div>
</section>
<section class="band cream" id="faq">
<div class="wrap">
<h2 class="center">Questions & answers</h2>
<div class="faq-groups">
<div class="faq-group">
<h3>Switchboard</h3>
<details class="faq-item"><summary><span class="faq-n">01</span>What is Switchboard?</summary><p>A small, open AI model that reads a prompt and decides how capable an AI needs to be to answer it: small, mid or frontier. You then send the prompt to an AI of that size.</p></details>
<details class="faq-item"><summary><span class="faq-n">02</span>Why not always use the best AI?</summary><p>Price. An answer from Claude Opus 5.5 costs 40 times more than the same answer from Claude Haiku 5.5. Most everyday prompts get an equally good answer from the smaller model.</p></details>
<details class="faq-item"><summary><span class="faq-n">03</span>Which base model is it built on?</summary><p>Qwen2.5-0.5B-Instruct from Alibaba, fully fine-tuned on routing examples. It's small on purpose: a router sits in front of every request, so it has to be fast and almost free.</p></details>
<details class="faq-item"><summary><span class="faq-n">04</span>Who is behind it?</summary><p>An independent project. It is not affiliated with Anthropic, OpenAI, Alibaba, Robinhood, Surplus or the Switchboard oracle network. Model names appear only to describe where prompts can be sent.</p></details>
</div>
<div class="faq-group">
<h3>Model & use</h3>
<details class="faq-item"><summary><span class="faq-n">05</span>Does it run on my computer?</summary><p>Yes. The 994 MB build runs with Ollama or llama.cpp on Windows, macOS and Linux, on a normal CPU. The demo on this page runs in your browser.</p></details>
<details class="faq-item"><summary><span class="faq-n">06</span>Does my prompt leave my device?</summary><p>Not in the demo on this page, and not when you run it with Ollama. If you call Switchboard through a hosted API, the prompt goes to that server like any other API call.</p></details>
<details class="faq-item"><summary><span class="faq-n">07</span>How good is it?</summary><p>On 10,000 test prompts it cut the bill by <span data-fill="cost_saved">…</span> compared with always using Claude Opus 5.5, and sent <span data-fill="under_routed">…</span> of prompts to a cheaper tier than they needed. All the numbers, including the weak spots, are on the <a href="evaluation.html">evaluation page</a>.</p></details>
<details class="faq-item"><summary><span class="faq-n">08</span>What if it picks the wrong tier?</summary><p>Too high costs a bit more. Too low can mean a weaker answer, which is the mistake we work hardest to reduce. If its answer can't be read, it falls back to the frontier tier, so a broken routing call never sends you to a weaker AI.</p></details>
<details class="faq-item"><summary><span class="faq-n">09</span>Is it free?</summary><p>Yes. The model is Apache 2.0, and running it yourself costs nothing: in your browser, in Ollama, or on your own GPU.</p></details>
<details class="faq-item"><summary><span class="faq-n">10</span>What data was it trained on?</summary><p>Real prompts from <a href="https://huggingface.co/datasets/routellm/gpt4_dataset">routellm/gpt4_dataset</a> (Apache 2.0, from LMSYS). Each prompt's label comes from how well a 2023 open model answered it, as scored by a GPT-4 judge. The model card has the details.</p></details>
</div>
</div>
</div>
</section>
<section class="closing">
<canvas id="closing-board" class="closing-canvas" aria-hidden="true"></canvas>
<div class="wrap center closing-inner">
<h2>Three sizes, all open</h2>
<p class="section-lede">0.5B runs in your browser, 4B runs in Ollama, and 32B runs on one 48 GB GPU. Same data, same test, Apache 2.0.</p>
<div class="cta-row">
<a class="btn btn-primary" href="#demo">Try the router</a>
<a class="btn btn-ghost" href="https://huggingface.co/switchboardllm">See all the models</a>
</div>
</div>
</section>
</main>
<script type="module" src="app.js?v=14"></script>
</body>
</html>
|