<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/">
    <channel>
        <title>liteLLM Blog</title>
        <link>https://docs.litellm.ai/blog</link>
        <description>liteLLM Blog</description>
        <lastBuildDate>Thu, 03 Sep 2026 11:00:00 GMT</lastBuildDate>
        <docs>https://validator.w3.org/feed/docs/rss2.html</docs>
        <generator>https://github.com/jpmonette/feed</generator>
        <language>en</language>
        <item>
            <title><![CDATA[Day 0 Support: GPT-6 Astra]]></title>
            <link>https://docs.litellm.ai/blog/gpt_6_astra</link>
            <guid>https://docs.litellm.ai/blog/gpt_6_astra</guid>
            <pubDate>Thu, 03 Sep 2026 11:00:00 GMT</pubDate>
            <description><![CDATA[Day 0 support for OpenAI's GPT-6 Astra on LiteLLM, with pricing, reasoning params, and the Responses API bridge.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="LiteLLM x GPT-6 Astra" src="https://docs.litellm.ai/assets/images/litellm_gpt_6_astra_announcement-89c4f0c429040efb16e5151e796956f9.png" width="4800" height="2508" class="img_ev3q"></p>
<p>LiteLLM now supports <code>gpt-6-astra</code>, OpenAI's next major model. Route traffic to it through the LiteLLM AI Gateway with the same config you use for every other OpenAI model.</p>
<!-- -->
<p>Astra is the first model on the GPT-6 name, and OpenAI's own <a href="https://openai.com/index/ten-advances-in-mathematics-and-theoretical-computer-science/" target="_blank" rel="noopener noreferrer">research post</a> previewed it producing machine-checked proofs for ten open problems in mathematics and theoretical computer science. It scores 98% on FrontierMath Tier 4, 99.9% on ARC-AGI 3, and 100% on ExploitBench, with a 1,050,000-token context window, 128K max output, an April 30 2026 knowledge cutoff, and text and image input. Through the API it behaves like the GPT-5 reasoning line: <code>max_completion_tokens</code> instead of <code>max_tokens</code>, <code>reasoning_effort</code> up to <code>xhigh</code>, no <code>temperature</code> while reasoning is on, prompt caching, and the long-context pricing tier above 272K input tokens.</p>
<div class="theme-admonition theme-admonition-note admonition_xJq3 alert alert--secondary"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"></path></svg></span>note</div><div class="admonitionContent_BuS1"><p><strong>Cost tracking works on the version you already run.</strong> Hit the <strong>Reload Model Cost Map</strong> button in the Admin UI (or <code>POST /reload/model_cost_map</code>) to pull the <code>gpt-6-astra</code> pricing from GitHub. This feature is available on <code>v1.76.0</code> and above.</p><p><strong>Parameter handling needs the next release.</strong> The GPT-5 reasoning classifier in LiteLLM matched <code>gpt-5*</code> names only, so on older versions a <code>gpt-6-astra</code> request keeps <code>max_tokens</code> and <code>temperature</code> as sent and OpenAI rejects them. The fix widening it to GPT-6 is on <code>main</code> now and ships in this Saturday's release candidate; until you upgrade, send <code>max_completion_tokens</code> yourself and leave <code>temperature</code> unset.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="usage">Usage<a href="https://docs.litellm.ai/blog/gpt_6_astra#usage" class="hash-link" aria-label="Direct link to Usage" title="Direct link to Usage">​</a></h2>
<div class="tabs-container tabList__CuJ"><ul role="tablist" aria-orientation="horizontal" class="tabs"><li role="tab" tabindex="0" aria-selected="true" class="tabs__item tabItem_LNqP tabs__item--active">LiteLLM Proxy</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">LiteLLM Python SDK</li></ul><div class="margin-top--md"><div role="tabpanel" class="tabItem_Ymn6"><p><strong>1. Setup config.yaml</strong></p><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">6</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">astra</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> openai/gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">6</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">astra</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/OPENAI_API_KEY</span><br></span></code></pre></div></div><p><strong>2. Start the proxy</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">docker run -d \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -p 4000:4000 \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -e OPENAI_API_KEY=$OPENAI_API_KEY \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -v $(pwd)/config.yaml:/app/config.yaml \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  ghcr.io/berriai/litellm:main-latest \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  --config /app/config.yaml</span><br></span></code></pre></div></div><p><strong>3. Test it</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">curl -X POST "http://0.0.0.0:4000/chat/completions" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H "Content-Type: application/json" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H "Authorization: Bearer $LITELLM_KEY" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -d '{</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "model": "gpt-6-astra",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "messages": [</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      {"role": "user", "content": "Prove that there are infinitely many primes."}</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    ],</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "reasoning_effort": "high"</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  }'</span><br></span></code></pre></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><div class="language-python codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-python codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token keyword" style="color:rgb(0, 0, 255)">from</span><span class="token plain"> litellm </span><span class="token keyword" style="color:rgb(0, 0, 255)">import</span><span class="token plain"> completion</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">response </span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token plain"> completion</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    model</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token string" style="color:rgb(163, 21, 21)">"openai/gpt-6-astra"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    messages</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token string" style="color:rgb(163, 21, 21)">"role"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"user"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"content"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"Prove that there are infinitely many primes."</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    reasoning_effort</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token string" style="color:rgb(163, 21, 21)">"high"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token keyword" style="color:rgb(0, 0, 255)">print</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain">response</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">choices</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token number" style="color:rgb(9, 134, 88)">0</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">message</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">content</span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><br></span></code></pre></div></div></div></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="responses-api">Responses API<a href="https://docs.litellm.ai/blog/gpt_6_astra#responses-api" class="hash-link" aria-label="Direct link to Responses API" title="Direct link to Responses API">​</a></h2>
<p>For agentic and multi-turn workflows, use <code>/v1/responses</code> to preserve reasoning state across turns. A <code>litellm.completion()</code> call that combines function tools with active reasoning is bridged to <code>/v1/responses</code> automatically, the same way it is for GPT-5.4 and newer.</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">curl -X POST "http://0.0.0.0:4000/v1/responses" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H "Content-Type: application/json" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H "Authorization: Bearer $LITELLM_KEY" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -d '{</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "model": "gpt-6-astra",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "input": "Plan and write a Python script that scrapes a webpage and summarizes it.",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "reasoning": {"effort": "high"}</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  }'</span><br></span></code></pre></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="pricing">Pricing<a href="https://docs.litellm.ai/blog/gpt_6_astra#pricing" class="hash-link" aria-label="Direct link to Pricing" title="Direct link to Pricing">​</a></h2>
<p>Prices are per 1M tokens (USD), shown as short context (≤272K tokens) / long context (&gt;272K tokens).</p>
<table><thead><tr><th>Model</th><th>Input</th><th>Cached input</th><th>Cache write</th><th>Output</th></tr></thead><tbody><tr><td><code>gpt-6-astra</code></td><td>$10.00 / $20.00</td><td>$1.00 / $2.00</td><td>$12.50 / $25.00</td><td>$50.00 / $75.00</td></tr></tbody></table>
<p>The <code>flex</code> service tier is billed at half the standard rate and <code>priority</code> at double, on both the short and long context tiers, and the Batch API is billed at half the standard input and output rate. Pass <code>service_tier</code> on the request and LiteLLM picks the matching rate. Fast mode costs 2x the applicable rate for up to 2.5x the speed.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="notes">Notes<a href="https://docs.litellm.ai/blog/gpt_6_astra#notes" class="hash-link" aria-label="Direct link to Notes" title="Direct link to Notes">​</a></h2>
<ul>
<li><code>gpt-6-astra</code> accepts <code>reasoning_effort</code> values <code>low</code>, <code>medium</code>, <code>high</code>, and <code>xhigh</code> on Chat Completions, plus <code>max</code> on the Responses API; <code>none</code> and <code>minimal</code> are rejected, so <code>temperature</code> cannot be used with it.</li>
<li>Availability is rolling out through the API; check your OpenAI account for model access.</li>
<li>See the <a href="https://docs.litellm.ai/docs/providers/openai">OpenAI provider docs</a> for the full parameter reference.</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="feedback">Feedback<a href="https://docs.litellm.ai/blog/gpt_6_astra#feedback" class="hash-link" aria-label="Direct link to Feedback" title="Direct link to Feedback">​</a></h2>
<p>Running GPT-6 Astra through LiteLLM and hitting something unexpected? Share it on <a href="https://github.com/BerriAI/litellm/discussions/39633" target="_blank" rel="noopener noreferrer">GitHub discussion #39633</a>.</p>]]></content:encoded>
            <category>openai</category>
            <category>gpt-6</category>
            <category>gpt-6-astra</category>
            <category>completion</category>
            <category>day 0 support</category>
        </item>
        <item>
            <title><![CDATA[Day 0 support: Meta Muse Spark 1.3]]></title>
            <link>https://docs.litellm.ai/blog/muse_spark_1_3</link>
            <guid>https://docs.litellm.ai/blog/muse_spark_1_3</guid>
            <pubDate>Wed, 02 Sep 2026 18:00:00 GMT</pubDate>
            <description><![CDATA[Day 0 support for Meta Muse Spark 1.3 on LiteLLM, with cost tracking for both the standard and contributor tiers.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="LiteLLM x Muse Spark 1.3" src="https://docs.litellm.ai/assets/images/hero-dfaf06db6341992107a8ea774ee2337b.png" width="4800" height="2508" class="img_ev3q"></p>
<p>LiteLLM now offers <code>muse-spark-1.3</code> and <code>muse-spark-1.3-contributor</code> on day 0, through the <code>meta/</code> route on the Meta Model API. Meta ships 1.3 today in Muse Code and the Model API, tuned for long-horizon agentic and coding work, and reports roughly 20% fewer tool calls and 25% fewer tokens than 1.2 internally.</p>
<!-- -->
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="pricing">Pricing<a href="https://docs.litellm.ai/blog/muse_spark_1_3#pricing" class="hash-link" aria-label="Direct link to Pricing" title="Direct link to Pricing">​</a></h2>
<p>Standard pricing is unchanged from 1.2.</p>
<table><thead><tr><th>Per 1M tokens</th><th>Standard</th><th>Contributor</th></tr></thead><tbody><tr><td>Input</td><td>$1.25</td><td>$0.10</td></tr><tr><td>Output</td><td>$4.25</td><td>$0.20</td></tr><tr><td>Cached input</td><td>$0.15</td><td>$0.002</td></tr></tbody></table>
<p>The contributor tier runs 12.5x cheaper on input and 21x cheaper on output, with no end date attached. Rate limits differ as well, 100 RPM on contributor against 3,000 RPM on standard, enforced per team rather than per key. Web search grounding bills $2.50 per 1,000 queries on both.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="quick-start">Quick Start<a href="https://docs.litellm.ai/blog/muse_spark_1_3#quick-start" class="hash-link" aria-label="Direct link to Quick Start" title="Direct link to Quick Start">​</a></h2>
<div class="tabs-container tabList__CuJ"><ul role="tablist" aria-orientation="horizontal" class="tabs"><li role="tab" tabindex="0" aria-selected="true" class="tabs__item tabItem_LNqP tabs__item--active">SDK</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">PROXY</li></ul><div class="margin-top--md"><div role="tabpanel" class="tabItem_Ymn6"><div class="language-python codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-python codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token keyword" style="color:rgb(0, 0, 255)">from</span><span class="token plain"> litellm </span><span class="token keyword" style="color:rgb(0, 0, 255)">import</span><span class="token plain"> completion</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">response </span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token plain"> completion</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    model</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token string" style="color:rgb(163, 21, 21)">"meta/muse-spark-1.3"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    messages</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token string" style="color:rgb(163, 21, 21)">"role"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"user"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"content"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"Summarize this article in 3 bullet points."</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token keyword" style="color:rgb(0, 0, 255)">print</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain">response</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">choices</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token number" style="color:rgb(9, 134, 88)">0</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">message</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">content</span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><br></span></code></pre></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><p><strong>1. Setup config.yaml</strong></p><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> muse</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">spark</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1.3</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> meta/muse</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">spark</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1.3</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/META_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token comment" style="color:rgb(0, 128, 0)"># Cheaper tier, but Meta may train on your prompts and completions</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> muse</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">spark</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">1.3</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">contributor</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> meta/muse</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">spark</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">1.3</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">contributor</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/META_API_KEY</span><br></span></code></pre></div></div><p><strong>2. Start proxy</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">litellm --config /path/to/config.yaml</span><br></span></code></pre></div></div><p><strong>3. Make requests</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">curl -X POST http://localhost:4000/v1/chat/completions \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H "Content-Type: application/json" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H "Authorization: Bearer &lt;YOUR-LITELLM-KEY&gt;" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -d '{</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "model": "muse-spark-1.3",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "messages": [{"role": "user", "content": "Hello!"}]</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  }'</span><br></span></code></pre></div></div></div></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="reasoning-modalities-and-audio">Reasoning, modalities, and audio<a href="https://docs.litellm.ai/blog/muse_spark_1_3#reasoning-modalities-and-audio" class="hash-link" aria-label="Direct link to Reasoning, modalities, and audio" title="Direct link to Reasoning, modalities, and audio">​</a></h2>
<p>Muse Spark 1.3 is a reasoning model. LiteLLM passes <code>reasoning_effort</code> through in OpenAI shape, accepting <code>minimal</code>, <code>low</code>, <code>medium</code>, <code>high</code>, and <code>xhigh</code>. Meta's announcement names a higher "max reasoning" mode that is not available yet, so <code>xhigh</code> is the ceiling today. Reasoning tokens bill as output tokens.</p>
<p>Text, image, video, and PDF input work as they did on 1.2, across <code>/v1/chat/completions</code>, <code>/v1/responses</code>, and <a href="https://docs.litellm.ai/docs/anthropic_unified"><code>/v1/messages</code></a>, with a 1,048,576-token context window.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="feedback">Feedback<a href="https://docs.litellm.ai/blog/muse_spark_1_3#feedback" class="hash-link" aria-label="Direct link to Feedback" title="Direct link to Feedback">​</a></h2>
<p>Running Muse Spark 1.3 through LiteLLM and hitting something unexpected? Share it in <a href="https://github.com/BerriAI/litellm/discussions/39439" target="_blank" rel="noopener noreferrer">GitHub discussions</a>.</p>]]></content:encoded>
            <category>meta</category>
            <category>muse-spark-1.3</category>
            <category>day 0 support</category>
            <category>llms</category>
        </item>
        <item>
            <title><![CDATA[Day 0 support: Gemini 3.8 Flash]]></title>
            <link>https://docs.litellm.ai/blog/gemini_3_8_flash</link>
            <guid>https://docs.litellm.ai/blog/gemini_3_8_flash</guid>
            <pubDate>Wed, 02 Sep 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[day 0 support for Gemini 3.8 Flash on LiteLLM, with launch pricing tracked across Google AI Studio and Vertex AI.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="LiteLLM x Gemini 3.8 Flash" src="https://docs.litellm.ai/assets/images/hero-338772bd587729cecdcc4e4b05122911.png" width="4800" height="2508" class="img_ev3q"></p>
<p>LiteLLM now supports <code>gemini-3.8-flash</code> on day 0, on both Google AI Studio (<code>gemini/</code>) and Vertex AI (<code>vertex_ai/</code>). Google calls its newest Flash model its primary general-purpose model, with gains over 3.7 Flash on long-horizon software engineering, agentic tasks, and multi-step reasoning, and on DeepSWE v1.1 it outperforms most larger frontier models at a fraction of the cost.</p>
<!-- -->
<div class="theme-admonition theme-admonition-note admonition_xJq3 alert alert--secondary"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"></path></svg></span>note</div><div class="admonitionContent_BuS1"><p><strong>No Docker image upgrade needed.</strong> Gemini 3.8 Flash routes through the existing Gemini configs, so any recent LiteLLM version works out of the box for inference. For cost tracking, hit the <strong>Reload Model Cost Map</strong> button in the Admin UI (or <code>POST /reload/model_cost_map</code>) to pull the latest pricing from GitHub. This is available on <code>v1.76.0</code> and above. The <code>gemini-3.8-flash</code> pricing and metadata are also bundled for anyone running with <code>LITELLM_LOCAL_MODEL_COST_MAP=true</code>, starting with the next dev tag, <code>v1.101.0-dev.2</code>, and the <code>v1.101.0-rc.1</code> RC.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="launch-pricing">Launch pricing<a href="https://docs.litellm.ai/blog/gemini_3_8_flash#launch-pricing" class="hash-link" aria-label="Direct link to Launch pricing" title="Direct link to Launch pricing">​</a></h2>
<p>Gemini 3.8 Flash launches at a 50% discount that runs through December 31, 2026. Standard pricing applies from January 1, 2027. LiteLLM tracks cost at the promotional rate.</p>
<table><thead><tr><th></th><th>Promotional</th><th>Standard</th></tr></thead><tbody><tr><td>Input</td><td>$0.75 / 1M tokens</td><td>$1.50 / 1M tokens</td></tr><tr><td>Output</td><td>$3.75 / 1M tokens</td><td>$7.50 / 1M tokens</td></tr></tbody></table>
<p>Cache reads, batch, flex, and priority tiers are discounted proportionally.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="quick-start">Quick Start<a href="https://docs.litellm.ai/blog/gemini_3_8_flash#quick-start" class="hash-link" aria-label="Direct link to Quick Start" title="Direct link to Quick Start">​</a></h2>
<div class="tabs-container tabList__CuJ"><ul role="tablist" aria-orientation="horizontal" class="tabs"><li role="tab" tabindex="0" aria-selected="true" class="tabs__item tabItem_LNqP tabs__item--active">SDK</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">PROXY</li></ul><div class="margin-top--md"><div role="tabpanel" class="tabItem_Ymn6"><div class="language-python codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-python codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token keyword" style="color:rgb(0, 0, 255)">from</span><span class="token plain"> litellm </span><span class="token keyword" style="color:rgb(0, 0, 255)">import</span><span class="token plain"> completion</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">response </span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token plain"> completion</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    model</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token string" style="color:rgb(163, 21, 21)">"gemini/gemini-3.8-flash"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    messages</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token string" style="color:rgb(163, 21, 21)">"role"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"user"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"content"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"Summarize this article in 3 bullet points."</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token keyword" style="color:rgb(0, 0, 255)">print</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain">response</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">choices</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token number" style="color:rgb(9, 134, 88)">0</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">message</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">content</span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><br></span></code></pre></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><p><strong>1. Setup config.yaml</strong></p><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gemini</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">3.8</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">flash</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gemini/gemini</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">3.8</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">flash</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/GEMINI_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token comment" style="color:rgb(0, 128, 0)"># Or use Vertex AI</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> vertex</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">gemini</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">3.8</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">flash</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> vertex_ai/gemini</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">3.8</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">flash</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">vertex_project</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> your</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">project</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">id</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">vertex_location</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> us</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">central1</span><br></span></code></pre></div></div><p><strong>2. Start proxy</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">litellm --config /path/to/config.yaml</span><br></span></code></pre></div></div><p><strong>3. Make requests</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">curl -X POST http://localhost:4000/v1/chat/completions \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H "Content-Type: application/json" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H "Authorization: Bearer &lt;YOUR-LITELLM-KEY&gt;" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -d '{</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "model": "gemini-3.8-flash",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "messages": [{"role": "user", "content": "Hello!"}]</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  }'</span><br></span></code></pre></div></div></div></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="thinking-levels">Thinking levels<a href="https://docs.litellm.ai/blog/gemini_3_8_flash#thinking-levels" class="hash-link" aria-label="Direct link to Thinking levels" title="Direct link to Thinking levels">​</a></h2>
<p>Gemini 3.8 Flash is a reasoning model and thinks by default. LiteLLM maps OpenAI <code>reasoning_effort</code> to Gemini's <code>thinkingLevel</code>, so the same request shape you use for other reasoning models works here.</p>
<div class="language-python codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-python codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token keyword" style="color:rgb(0, 0, 255)">from</span><span class="token plain"> litellm </span><span class="token keyword" style="color:rgb(0, 0, 255)">import</span><span class="token plain"> completion</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">response </span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token plain"> completion</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    model</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token string" style="color:rgb(163, 21, 21)">"gemini/gemini-3.8-flash"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    messages</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token string" style="color:rgb(163, 21, 21)">"role"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"user"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"content"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"What's 2+2?"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    reasoning_effort</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token string" style="color:rgb(163, 21, 21)">"low"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token keyword" style="color:rgb(0, 0, 255)">print</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain">response</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">choices</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token number" style="color:rgb(9, 134, 88)">0</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">message</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">content</span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><br></span></code></pre></div></div>
<div class="theme-admonition theme-admonition-warning admonition_xJq3 alert alert--warning"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 16 16"><path fill-rule="evenodd" d="M8.893 1.5c-.183-.31-.52-.5-.887-.5s-.703.19-.886.5L.138 13.499a.98.98 0 0 0 0 1.001c.193.31.53.501.886.501h13.964c.367 0 .704-.19.877-.5a1.03 1.03 0 0 0 .01-1.002L8.893 1.5zm.133 11.497H6.987v-2.003h2.039v2.003zm0-3.004H6.987V5.987h2.039v4.006z"></path></svg></span>Known limitation at launch</div><div class="admonitionContent_BuS1"><p>The <code>minimal</code> thinking level is not supported on <code>gemini-3.8-flash</code>, same as on 3.7 Flash. The Gemini API returns a 400 (<code>Thinking level MINIMAL is not supported for this model</code>). The <code>low</code>, <code>medium</code>, and <code>high</code> levels work as expected.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="supported-endpoints">Supported Endpoints<a href="https://docs.litellm.ai/blog/gemini_3_8_flash#supported-endpoints" class="hash-link" aria-label="Direct link to Supported Endpoints" title="Direct link to Supported Endpoints">​</a></h2>
<p>LiteLLM provides full end-to-end support for Gemini 3.8 Flash on:</p>
<ul>
<li><code>/v1/chat/completions</code> - OpenAI-compatible chat completions endpoint</li>
<li><code>/v1/responses</code> - OpenAI Responses API endpoint (streaming and non-streaming)</li>
<li><a href="https://docs.litellm.ai/docs/anthropic_unified"><code>/v1/messages</code></a> - Anthropic-compatible messages endpoint</li>
<li><code>/v1/generateContent</code> - <a href="https://docs.litellm.ai/docs/generateContent">Google Gemini API</a> compatible endpoint</li>
</ul>
<p>All endpoints support streaming and non-streaming responses, function calling with thought signatures, multi-turn conversations, and full multimodal input (text, image, audio, video).</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="feedback">Feedback<a href="https://docs.litellm.ai/blog/gemini_3_8_flash#feedback" class="hash-link" aria-label="Direct link to Feedback" title="Direct link to Feedback">​</a></h2>
<p>Running Gemini 3.8 Flash through LiteLLM and hitting something unexpected? Share it on <a href="https://github.com/BerriAI/litellm/discussions/39357" target="_blank" rel="noopener noreferrer">GitHub discussion #39357</a>.</p>]]></content:encoded>
            <category>gemini</category>
            <category>gemini-3.8-flash</category>
            <category>day 0 support</category>
            <category>llms</category>
        </item>
        <item>
            <title><![CDATA[Introducing AutoRouter Heuristic v2: 27% More Tasks Solved at 45% Lower Cost]]></title>
            <link>https://docs.litellm.ai/blog/heuristic-v2</link>
            <guid>https://docs.litellm.ai/blog/heuristic-v2</guid>
            <pubDate>Wed, 02 Sep 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[Heuristic v2 is a new classifier for LiteLLM's AutoRouter, pretrained across multiple rounds of graded response data so it ships with zero cold start. On a 21-task Terminal-Bench 2.0 subset it solved 3 more tasks than Heuristic v1, at 45% lower cost per solved task and lower latency.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="Heuristic v2 is cheaper, faster, and better: -45% cost per solved task, -20% median task time, +27% more quality than Heuristic v1, on a 21-task Terminal-Bench 2.0 subset" src="https://docs.litellm.ai/assets/images/hero-5766c81066e5ab90076a1e67bbc5236a.png" width="2400" height="1464" class="img_ev3q"></p>
<p><strong>Heuristic v2, LiteLLM's new AutoRouter classifier, is up to 45% more efficient than Heuristic v1: more tasks solved, at lower cost, in less time.</strong> Only the classifier changed.</p>
<!-- -->
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a><br><br><p>Already testing it? Share your results in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="key-findings">Key findings<a href="https://docs.litellm.ai/blog/heuristic-v2#key-findings" class="hash-link" aria-label="Direct link to Key findings" title="Direct link to Key findings">​</a></h2>
<ul>
<li><strong>No cold start.</strong> Heuristic v2 ships pretrained across multiple rounds of graded response data, so it already knows which tier to trust before it sees your first prompt</li>
<li><strong>3 more tasks solved.</strong> 14/21 against 11/21, a 27% jump in solve rate on this subset</li>
<li><strong>45% lower cost per solved task.</strong> $0.70 against $1.28, and 30% lower total spend across the run ($9.78 against $14.06)</li>
<li><strong>Faster, too.</strong> Mean LLM call latency fell 10% (13.1s against 14.5s), p90 fell 10% (30.7s against 34.1s), and median task completion time fell from 8m53s to 7m08s</li>
<li><strong>Steadier tier choices mean fewer cache misses.</strong> 87% of input tokens were cache reads, against 82% for Heuristic v1</li>
<li><strong>Just as reliable.</strong> Zero failed requests in either arm, across 933 combined LLM calls</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="what-changed">What changed<a href="https://docs.litellm.ai/blog/heuristic-v2#what-changed" class="hash-link" aria-label="Direct link to What changed" title="Direct link to What changed">​</a></h2>
<p>Heuristic v1 scores a prompt's complexity and maps the score to a tier. Heuristic v2 estimates each tier's odds of success on the request and routes to the cheapest tier that clears a probability bar, not the tier that matches a difficulty score.</p>
<div class="language-text codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-text codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">Prompt</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -&gt; Detect request type and similarity cohort</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -&gt; Estimate success probability for all four tiers</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -&gt; Make probabilities monotonic</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -&gt; Select the first tier with at least 75% predicted success</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -&gt; Route to a model configured in that tier</span><br></span></code></pre></div></div>
<p>The probability estimate blends three levels of evidence:</p>
<ul>
<li><strong>Tier-wide performance:</strong> how the tier does across all requests</li>
<li><strong>Request-type performance:</strong> how it does on this kind of request (code, technical design, analytical reasoning, writing, factual lookup, or general)</li>
<li><strong>Similar-request performance:</strong> how it does on requests that look most like this one</li>
</ul>
<p>Thin evidence defers to the broader estimate; a large sample overrides it. A stronger tier should never look less capable than a weaker one, so the router corrects the four probabilities to be monotonic, then picks the first one that clears the bar:</p>
<div class="language-text codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-text codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">raw:       [0.60, 0.72, 0.69, 0.91]</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">corrected: [0.60, 0.72, 0.72, 0.91]</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">           SIMPLE MEDIUM COMPLEX REASONING</span><br></span></code></pre></div></div>
<p>Same four abstract tiers as before, <code>SIMPLE</code>, <code>MEDIUM</code>, <code>COMPLEX</code>, <code>REASONING</code>. You still decide which models live in each one.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="pretrained-zero-cold-start">Pretrained, zero cold start<a href="https://docs.litellm.ai/blog/heuristic-v2#pretrained-zero-cold-start" class="hash-link" aria-label="Direct link to Pretrained, zero cold start" title="Direct link to Pretrained, zero cold start">​</a></h2>
<p>Adaptive routing earns its edge by watching your traffic: a Thompson-sampled tier pool loses a few rounds on the wrong model before it learns which one wins. Heuristic v2 skips that step. Its success-probability tables are calibrated across multiple rounds of graded response data before the classifier ever ships, so it already knows which tier to trust before it sees your first prompt, no ramp-up period on your traffic required.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="results">Results<a href="https://docs.litellm.ai/blog/heuristic-v2#results" class="hash-link" aria-label="Direct link to Results" title="Direct link to Results">​</a></h2>
<table><thead><tr><th>Classifier</th><th style="text-align:right">Solve rate</th><th style="text-align:right">Solved/21</th><th style="text-align:right">Total cost</th><th style="text-align:right">$/solved</th><th style="text-align:right">Mean call latency</th><th style="text-align:right">p90 call latency</th><th style="text-align:right">Median task time</th></tr></thead><tbody><tr><td><strong>Heuristic v2</strong></td><td style="text-align:right"><strong>66.7%</strong></td><td style="text-align:right"><strong>14/21</strong></td><td style="text-align:right"><strong>$9.78</strong></td><td style="text-align:right"><strong>$0.70</strong></td><td style="text-align:right"><strong>13.1s</strong></td><td style="text-align:right"><strong>30.7s</strong></td><td style="text-align:right"><strong>7m08s</strong></td></tr><tr><td>Heuristic v1</td><td style="text-align:right">52.4%</td><td style="text-align:right">11/21</td><td style="text-align:right">$14.06</td><td style="text-align:right">$1.28</td><td style="text-align:right">14.5s</td><td style="text-align:right">34.1s</td><td style="text-align:right">8m53s</td></tr></tbody></table>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="where-the-savings-come-from">Where the savings come from<a href="https://docs.litellm.ai/blog/heuristic-v2#where-the-savings-come-from" class="hash-link" aria-label="Direct link to Where the savings come from" title="Direct link to Where the savings come from">​</a></h2>
<table><thead><tr><th>Classifier</th><th style="text-align:right">SIMPLE (Haiku)</th><th style="text-align:right">MEDIUM (Sonnet)</th><th style="text-align:right">COMPLEX (Opus)</th><th style="text-align:right">REASONING (Opus, high effort)</th></tr></thead><tbody><tr><td>Heuristic v2</td><td style="text-align:right">45% ($1.61)</td><td style="text-align:right">55% ($8.17)</td><td style="text-align:right">0%</td><td style="text-align:right">0%</td></tr><tr><td>Heuristic v1</td><td style="text-align:right">39% ($1.15)</td><td style="text-align:right">45% ($5.18)</td><td style="text-align:right">15% ($7.43)</td><td style="text-align:right">1% ($0.29)</td></tr></tbody></table>
<p>Heuristic v2 never escalated to Opus on this benchmark. Heuristic v1 sent 16% of turns to Opus, and those turns made up 55% of its total spend. That escalation didn't buy extra solves this run: the four tasks Heuristic v2 solved that v1 missed (<code>adaptive-rejection-sampler</code>, <code>crack-7z-hash</code>, <code>install-windows-3.11</code>, <code>password-recovery</code>) were all solved on Haiku and Sonnet alone. v1 opened one of those four on Opus and still failed it.</p>
<p>Heuristic v1 also switches tiers more often turn to turn, which costs it some prompt-cache hits: 82% of its input tokens were cache reads, against 87% for Heuristic v2.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="try-it">Try it<a href="https://docs.litellm.ai/blog/heuristic-v2#try-it" class="hash-link" aria-label="Direct link to Try it" title="Direct link to Try it">​</a></h2>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockTitle_OeMC">config.yaml</div><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> smart</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> auto_router/complexity_router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">tiers</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">SIMPLE</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">MEDIUM</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">COMPLEX</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">   claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">REASONING</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_type</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> trained_heuristic</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_default_model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><br></span></code></pre></div></div>
<div class="theme-admonition theme-admonition-note admonition_xJq3 alert alert--secondary"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"></path></svg></span>Free trial scope</div><div class="admonitionContent_BuS1"><p>The free trial covers Heuristic v2 on one auto router. If you want it on more than one, <a href="https://calendar.app.google/i2e7qVEJphHi5S8UA" target="_blank" rel="noopener noreferrer">apply to be a design partner</a> and we'll sort it out with you directly.</p></div></div>
<p>Heuristic v2 makes no LLM classifier call on the request path, and reuses the same tier config as Heuristic v1 or the LLM classifier. Swap <code>classifier_type</code> and compare against your current setup. Full reference on the <a href="https://docs.litellm.ai/docs/proxy/auto_routing">Auto Routing docs page</a>.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="how-it-was-measured">How it was measured<a href="https://docs.litellm.ai/blog/heuristic-v2#how-it-was-measured" class="hash-link" aria-label="Direct link to How it was measured" title="Direct link to How it was measured">​</a></h2>
<ul>
<li><strong>Benchmark:</strong> a 21-task subset of Terminal-Bench 2.0, both classifiers run concurrently through one LiteLLM proxy, harbor 0.20.0 + terminus-2, <code>max_turns=50</code>, <code>-n 6</code> per arm, 1 trial per task</li>
<li><strong>Tiers:</strong> identical for both arms, SIMPLE to <code>claude-haiku-4-5</code>, MEDIUM to <code>claude-sonnet-5</code>, COMPLEX and REASONING to <code>claude-opus-5</code> at high effort. Only <code>classifier_type</code> differs</li>
<li><strong>Cost:</strong> total USD across all 21 tasks from gateway spend logs</li>
<li><strong>Latency:</strong> per-LLM-call latency measured at the proxy, 437 calls for Heuristic v1 against 496 for Heuristic v2</li>
<li><strong>Caveat:</strong> one run per arm on 21 tasks. Heuristic v1 scored 12-13/21 in two earlier runs against 11/21 here, so a few tasks of run-to-run noise is expected and a 3-task gap is suggestive, not conclusive. Total run wall clock ran longer for Heuristic v2 (46m30s against 37m55s, with 6 tasks per arm running concurrently) because of long-running tasks in the tail and one timeout on <code>chess-best-move</code>; that's a property of this run's slowest tasks, not a per-request latency regression, which is why the headline numbers above are per-call latency and median task time instead</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="related-reading">Related reading<a href="https://docs.litellm.ai/blog/heuristic-v2#related-reading" class="hash-link" aria-label="Direct link to Related reading" title="Direct link to Related reading">​</a></h2>
<p><a href="https://docs.litellm.ai/blog/auto-router-terminal-bench-benchmark">Opus-level quality at 27% lower cost</a>, <a href="https://docs.litellm.ai/blog/fusion-terminal-bench-benchmark">LiteLLM Fusion: 56% more tasks solved than Fable 5</a>, and <a href="https://docs.litellm.ai/blog/auto-router-production-savings">what auto-routing saved in production</a>.</p>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>info</div><div class="admonitionContent_BuS1"><p>Point Heuristic v2 at your own workload and compare it against your current classifier. Share numbers or questions in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>. To work on this with us directly, <a href="https://calendar.app.google/i2e7qVEJphHi5S8UA" target="_blank" rel="noopener noreferrer">apply to be a design partner</a>.</p></div></div>]]></content:encoded>
            <category>routing</category>
            <category>complexity-router</category>
            <category>cost</category>
            <category>benchmarks</category>
            <category>engineering</category>
            <category>product</category>
        </item>
        <item>
            <title><![CDATA[Introducing LiteLLM Fusion: 56% More Tasks Solved Than Fable 5]]></title>
            <link>https://docs.litellm.ai/blog/fusion-terminal-bench-benchmark</link>
            <guid>https://docs.litellm.ai/blog/fusion-terminal-bench-benchmark</guid>
            <pubDate>Tue, 01 Sep 2026 14:00:00 GMT</pubDate>
            <description><![CDATA[LiteLLM Auto Router Fusion ran three models on the same task and synthesized their work, solving 14 of 21 Terminal-Bench tasks against 9 for Claude Fable-5 alone. Total spend rose 36%, cost per solved task fell 12%, and turn latency went up 5x.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="LiteLLM Auto Router Fusion solved 14 of 21 tasks against 9 for Fable 5" src="https://docs.litellm.ai/assets/images/lite-fusion-light-e71f12a15c702bc6300a27db97428ab5.png" width="2000" height="1148" class="img_ev3q"></p>
<p><strong>LiteLLM Auto Router Fusion solved 14 of 21 Terminal-Bench tasks; Claude Fable-5 on its own solved 9.</strong> Fusion runs the task on several models in parallel and has one of them synthesize the candidate work into a single answer. Both arms ran the same 21 tasks.</p>
<!-- -->
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a><br><br><p>Already testing it? Share your results in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="key-findings">Key findings<a href="https://docs.litellm.ai/blog/fusion-terminal-bench-benchmark#key-findings" class="hash-link" aria-label="Direct link to Key findings" title="Direct link to Key findings">​</a></h2>
<ul>
<li><strong>Fusion solved 5 more tasks</strong>, 14/21 against 9/21, a 24 point jump in solve rate on this subset</li>
<li><strong>Total spend rose 36%</strong> ($67.13 to $91.64) while <strong>cost per solved task fell 12%</strong> ($7.46 to $6.55)</li>
<li><strong>The extra models are cheap; the synthesis is not.</strong> Opus-5 and Kimi-K3 together account for $21.27 of the fusion bill. The Fable-5 component alone is $70.37, more than the entire single model arm</li>
<li><strong>Latency is the real cost.</strong> Median turn went from 6s to 30s and p95 from 55s to 237s, with median wall clock per task moving from 5 to 8 minutes</li>
<li><strong>Fusion is not strictly better.</strong> It lost one task the single model solved, and it lost it to a timeout rather than a wrong answer</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="results">Results<a href="https://docs.litellm.ai/blog/fusion-terminal-bench-benchmark#results" class="hash-link" aria-label="Direct link to Results" title="Direct link to Results">​</a></h2>
<table><thead><tr><th>Arm</th><th style="text-align:right">Solve rate</th><th style="text-align:right">Solved/n</th><th style="text-align:right">Total cost</th><th style="text-align:right">$/solved</th><th style="text-align:right">Median turn</th><th style="text-align:right">p95 turn</th><th style="text-align:right">Median task wall clock</th><th style="text-align:right">Agent turns</th></tr></thead><tbody><tr><td>Fusion: Fable-5 + Opus-5 + Kimi-K3</td><td style="text-align:right"><strong>66.7%</strong></td><td style="text-align:right"><strong>14/21</strong></td><td style="text-align:right">$91.64</td><td style="text-align:right"><strong>$6.55</strong></td><td style="text-align:right">30s</td><td style="text-align:right">237s</td><td style="text-align:right">8 min</td><td style="text-align:right">169</td></tr><tr><td>Fable-5 only</td><td style="text-align:right">42.9%</td><td style="text-align:right">9/21</td><td style="text-align:right">$67.13</td><td style="text-align:right">$7.46</td><td style="text-align:right">6s</td><td style="text-align:right">55s</td><td style="text-align:right">5 min</td><td style="text-align:right">395</td></tr></tbody></table>
<p>Fusion needed 57% fewer agent turns to get further, because a synthesized answer arrives closer to correct and the agent spends less time iterating. Each of those turns costs roughly 5x more wall clock, so the task still takes longer end to end.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="where-the-extra-tasks-came-from">Where the extra tasks came from<a href="https://docs.litellm.ai/blog/fusion-terminal-bench-benchmark#where-the-extra-tasks-came-from" class="hash-link" aria-label="Direct link to Where the extra tasks came from" title="Direct link to Where the extra tasks came from">​</a></h2>
<p>Eight tasks were solved by both arms. Fusion added six that the single model missed: <code>chess-best-move</code>, <code>crack-7z-hash</code>, <code>largest-eigenval</code>, <code>llm-inference-batching-scheduler</code>, <code>password-recovery</code>, and <code>write-compressor</code>. Six were solved by neither. The one regression, <code>winning-avg-corewars</code>, timed out under fusion.</p>
<table><thead><tr><th>Task</th><th>Fable-5</th><th>Fusion</th></tr></thead><tbody><tr><td>adaptive-rejection-sampler</td><td>failed</td><td>failed (timeout)</td></tr><tr><td>build-pmars</td><td>solved</td><td>solved</td></tr><tr><td>chess-best-move</td><td>failed (timeout)</td><td><strong>solved</strong></td></tr><tr><td>cobol-modernization</td><td>solved</td><td>solved</td></tr><tr><td>crack-7z-hash</td><td>failed</td><td><strong>solved</strong></td></tr><tr><td>filter-js-from-html</td><td>failed</td><td>failed</td></tr><tr><td>gcode-to-text</td><td>failed (timeout)</td><td>failed (timeout)</td></tr><tr><td>install-windows-3.11</td><td>failed</td><td>failed</td></tr><tr><td>largest-eigenval</td><td>failed</td><td><strong>solved</strong></td></tr><tr><td>llm-inference-batching-scheduler</td><td>failed (timeout)</td><td><strong>solved</strong></td></tr><tr><td>merge-diff-arc-agi-task</td><td>solved</td><td>solved</td></tr><tr><td>multi-source-data-merger</td><td>solved</td><td>solved</td></tr><tr><td>overfull-hbox</td><td>solved</td><td>solved</td></tr><tr><td>password-recovery</td><td>failed</td><td><strong>solved</strong></td></tr><tr><td>polyglot-c-py</td><td>failed</td><td>failed</td></tr><tr><td>prove-plus-comm</td><td>solved</td><td>solved</td></tr><tr><td>pypi-server</td><td>solved</td><td>solved</td></tr><tr><td>sparql-university</td><td>solved</td><td>solved</td></tr><tr><td>train-fasttext</td><td>failed</td><td>failed (timeout)</td></tr><tr><td>winning-avg-corewars</td><td><strong>solved</strong></td><td>failed (timeout)</td></tr><tr><td>write-compressor</td><td>failed</td><td><strong>solved</strong></td></tr></tbody></table>
<p>The six tasks fusion picked up are the ones where a second opinion changes the answer: cracking a hash, finding an eigenvalue, writing a compressor. Different models attack these differently, and the synthesis step gets to pick the line of attack that worked instead of committing to one up front.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="where-the-money-goes">Where the money goes<a href="https://docs.litellm.ai/blog/fusion-terminal-bench-benchmark#where-the-money-goes" class="hash-link" aria-label="Direct link to Where the money goes" title="Direct link to Where the money goes">​</a></h2>
<table><thead><tr><th>Model</th><th style="text-align:right">Spend in fusion arm</th><th style="text-align:right">Share</th></tr></thead><tbody><tr><td>claude-fable-5</td><td style="text-align:right">$70.37</td><td style="text-align:right">76.8%</td></tr><tr><td>claude-opus-5</td><td style="text-align:right">$17.37</td><td style="text-align:right">19.0%</td></tr><tr><td>kimi-k3</td><td style="text-align:right">$3.90</td><td style="text-align:right">4.3%</td></tr></tbody></table>
<p>Adding Opus-5 and Kimi-K3 as candidate generators cost $21.27 across all 21 tasks. The Fable-5 line item grew past the entire single model baseline because Fable both generates a candidate and synthesizes on 167 of 169 turns. If you want to bring the fusion bill down, the lever is the synthesizer, not the size of the candidate pool.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="how-it-was-measured">How it was measured<a href="https://docs.litellm.ai/blog/fusion-terminal-bench-benchmark#how-it-was-measured" class="hash-link" aria-label="Direct link to How it was measured" title="Direct link to How it was measured">​</a></h2>
<ul>
<li><strong>Benchmark:</strong> the same 21 task subset of Terminal-Bench 2.0 used in our <a href="https://docs.litellm.ai/blog/auto-router-terminal-bench-benchmark">earlier auto router benchmark</a></li>
<li><strong>Baseline arm:</strong> every request to <code>claude-fable-5</code> at high effort</li>
<li><strong>Fusion arm:</strong> <code>claude-fable-5</code>, <code>claude-opus-5</code>, and <code>kimi-k3</code> each produce candidate work at high effort; <code>claude-fable-5</code> synthesizes the final answer. Synthesis ran on 167 of 169 turns</li>
<li><strong>Cost:</strong> total USD across all 21 tasks from gateway spend logs, including every candidate call and the synthesis call</li>
<li><strong>Failures:</strong> agent timeouts count as failures. The fusion arm hit 5 timeout rows against 3 for the baseline, which is consistent with its higher per turn latency</li>
<li><strong>Provider errors:</strong> failed rows per model group were 7 for Fable-5, 6 for Opus-5, and 4 for Kimi-K3, plus 2 arm level failures on each side. The fusion arm also logged 21 <code>content_filter</code> rows, all on candidate generations</li>
</ul>
<p>One run per arm on 21 tasks is a directional result, not a confidence interval. It says fusion is worth measuring on your own workload; it does not establish a solve rate for Terminal-Bench overall, and these numbers should not be read against the arms in the earlier post, which used a different configuration.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="when-to-reach-for-it">When to reach for it<a href="https://docs.litellm.ai/blog/fusion-terminal-bench-benchmark#when-to-reach-for-it" class="hash-link" aria-label="Direct link to When to reach for it" title="Direct link to When to reach for it">​</a></h2>
<p>Fusion buys completed tasks with latency and total spend. That trade works when finishing the task is what you are paying for, which covers migrations, hard debugging, offline agent runs, and evaluation harnesses. It does not work behind an interactive request where a 237s p95 turn is visible to a user. If you are already running a frontier model at high effort and still watching tasks fail, the question worth asking is whether a second and third candidate would have solved them, and this subset says that about a quarter of the time it would.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="try-it">Try it<a href="https://docs.litellm.ai/blog/fusion-terminal-bench-benchmark#try-it" class="hash-link" aria-label="Direct link to Try it" title="Direct link to Try it">​</a></h2>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>info</div><div class="admonitionContent_BuS1"><p>Point an agent at several models on the same task, synthesize the results, and compare completed tasks per dollar against your current single model. Share numbers or questions in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>. To work on this with us directly, <a href="https://calendar.app.google/i2e7qVEJphHi5S8UA" target="_blank" rel="noopener noreferrer">apply to be a design partner</a>.</p></div></div>
<p>Related reading: <a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark">stacking auto-routing on prompt caching</a> and <a href="https://docs.litellm.ai/blog/auto-router-production-savings">what auto-routing saved in production</a>.</p>]]></content:encoded>
            <category>routing</category>
            <category>auto-router</category>
            <category>benchmarks</category>
            <category>cost</category>
            <category>engineering</category>
        </item>
        <item>
            <title><![CDATA[Auto-Router: Route on Context Size and Modality]]></title>
            <link>https://docs.litellm.ai/blog/auto-router-more-routing-configurations</link>
            <guid>https://docs.litellm.ai/blog/auto-router-more-routing-configurations</guid>
            <pubDate>Tue, 01 Sep 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[The Auto-Router now supports more routing configurations: context-window escalation moves oversized prompts to the cheapest tier that fits them before dispatch, modality routing sends image requests to tiers that can see, classification can run on user turns only, and shadow evaluations can compare several router configs on a team's live traffic.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="Auto-Router: one router, more routing signals; complexity, context size, and modality" src="https://docs.litellm.ai/assets/images/hero-f0bffd88c9f6c659db6e733b866ca5cf.png" width="2400" height="1260" class="img_ev3q"></p>
<p>The Auto-Router picks a model by asking how hard the request is. This release adds the questions that come right after: does the request fit the model we picked, and can that model even see it?</p>
<!-- -->
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a><br><br><p>Already testing it? Share your results in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>.</p></div></div>
<p>Complexity tiers don't predict routability. A trivially simple question asked 300k tokens into a coding session still can't go to a small model, and a "what's in this screenshot?" request can't go to a text-only model no matter how easy the question is. The router now checks for both before dispatch, and shadow evaluations let you prove any of these configurations on a team's live traffic before rolling it out.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="one-router-more-routing-signals">One router, more routing signals<a href="https://docs.litellm.ai/blog/auto-router-more-routing-configurations#one-router-more-routing-signals" class="hash-link" aria-label="Direct link to One router, more routing signals" title="Direct link to One router, more routing signals">​</a></h2>
<table><thead><tr><th>Routing signal</th><th>What it does</th><th>Config key</th><th>Default</th></tr></thead><tbody><tr><td><strong>Complexity</strong></td><td>Classifies the request and picks a tier</td><td><code>tiers</code></td><td>core behavior</td></tr><tr><td><strong>Context size</strong></td><td>Escalates prompts that provably don't fit the decided tier</td><td><code>enable_context_window_escalation</code></td><td><strong>on</strong></td></tr><tr><td><strong>Modality</strong></td><td>Routes image-bearing requests to vision-capable tiers</td><td><code>modality_routing</code></td><td>off, opt-in</td></tr><tr><td><strong>Turn type</strong></td><td>Classifies new user asks only, skipping continuation turns</td><td><code>classification_mode: user_turn</code></td><td><code>every_request</code></td></tr></tbody></table>
<p>Every gate reports what it did. Escalated decisions carry <code>context_escalated</code> or <code>modality_escalation</code> plus the tier the classifier originally picked, so nothing the router does is invisible.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="context-window-based-routing">Context-window based routing<a href="https://docs.litellm.ai/blog/auto-router-more-routing-configurations#context-window-based-routing" class="hash-link" aria-label="Direct link to Context-window based routing" title="Direct link to Context-window based routing">​</a></h2>
<p>The market-standard answer to "the prompt didn't fit" is reactive: send the request, catch the context-length 400, retry on a bigger model. You pay for the failed call and the latency, on every turn of a long session. When we surveyed how routing products handle this, reactive fallback was the norm; we didn't find one that filters candidates by token count before dispatch.</p>
<p>The Auto-Router now does it pre-dispatch:</p>
<ul>
<li><strong>Estimates the full prompt footprint before sending</strong>, including system prompts and tool definitions; for coding agents like Claude Code those carry most of the payload</li>
<li><strong>Escalates to the cheapest tier that provably fits.</strong> A fitting model group in the decided tier wins first, so you never pay for more model than the prompt requires</li>
<li><strong>Unknown context windows are left alone.</strong> The gate acts only when it can prove a mismatch</li>
<li><strong>Escalated decisions are never session-pinned.</strong> When the session shrinks back down, routing comes back down with it</li>
<li><strong>On by default</strong>, with a safety buffer (<code>context_window_escalation_buffer: 0.95</code>) so prompts near the limit escalate instead of gambling</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="modality-based-routing">Modality-based routing<a href="https://docs.litellm.ai/blog/auto-router-more-routing-configurations#modality-based-routing" class="hash-link" aria-label="Direct link to Modality-based routing" title="Direct link to Modality-based routing">​</a></h2>
<p>If your cheap tier is text-only and a request carries an image, the old outcome was a provider-side error after the request had already left the gateway. With <code>modality_routing: true</code>:</p>
<ul>
<li><strong>Images are detected anywhere in the request</strong>: OpenAI <code>image_url</code> and <code>input_image</code> parts, Anthropic <code>image</code> blocks, and images nested inside tool results, the shape real agent screenshots arrive in</li>
<li><strong>The router walks up to the nearest vision-capable tier</strong> from the one the classifier decided</li>
<li><strong>No tier can see? A clear 400 from the gateway</strong>, instead of a confusing provider error</li>
<li><strong>Conservative by design.</strong> Only models explicitly marked as lacking vision are excluded; unknown models stay eligible</li>
<li><strong>Opt-in</strong>, off by default</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="classify-when-it-matters">Classify when it matters<a href="https://docs.litellm.ai/blog/auto-router-more-routing-configurations#classify-when-it-matters" class="hash-link" aria-label="Direct link to Classify when it matters" title="Direct link to Classify when it matters">​</a></h2>
<p>Agentic sessions fire many requests per conversation, and most of them (tool results, follow-ups, retries) aren't new questions. With <code>classification_mode: user_turn</code>, the classifier runs only when the newest message is an actual new user ask, and the standing decision carries the continuation turns. Fewer classifier calls, less routing overhead, and steadier model selection mid-task.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="shadow-evaluate-it-on-a-team-before-anyone-notices">Shadow-evaluate it on a team, before anyone notices<a href="https://docs.litellm.ai/blog/auto-router-more-routing-configurations#shadow-evaluate-it-on-a-team-before-anyone-notices" class="hash-link" aria-label="Direct link to Shadow-evaluate it on a team, before anyone notices" title="Direct link to Shadow-evaluate it on a team, before anyone notices">​</a></h2>
<p><a href="https://docs.litellm.ai/blog/auto-router-shadow-evaluations">Shadow evaluations</a> test the Auto-Router against your live traffic without changing a single user-facing response. Here's what you can do with them now:</p>
<ul>
<li><strong>Target a <code>key</code>, a <code>team</code>, or a <code>user</code>.</strong> JWT-authenticated traffic has no virtual key to point at; team and user targeting makes it evaluable for the first time</li>
<li><strong>Compare several router configs in one job</strong>, against the same sampled traffic</li>
<li><strong>Trust the comparison: sampling is paired.</strong> Every config sees the identical request, so quality and cost differences come from the config, never traffic luck</li>
</ul>
<p>That closes the loop on everything above: draft a config with the new gates on, shadow it against your current router on a real team's traffic, read the paired comparison, promote the winner.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="turning-it-on">Turning it on<a href="https://docs.litellm.ai/blog/auto-router-more-routing-configurations#turning-it-on" class="hash-link" aria-label="Direct link to Turning it on" title="Direct link to Turning it on">​</a></h2>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4o</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">mini</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> openai/gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4o</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">mini</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"> </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/OPENAI_API_KEY</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4o</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> openai/gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4o</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"> </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/OPENAI_API_KEY</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"> </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5.5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> openai/gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5.5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"> </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/OPENAI_API_KEY</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> smart</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> auto_router/complexity_router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">tiers</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">SIMPLE</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4o</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">mini</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">MEDIUM</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4o</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">COMPLEX</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">   claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">REASONING</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5.5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token comment" style="color:rgb(0, 128, 0)"># on by default: escalate prompts that provably don't fit</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">enable_context_window_escalation</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token boolean important">true</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">context_window_escalation_buffer</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(9, 134, 88)">0.95</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token comment" style="color:rgb(0, 128, 0)"># opt-in: route image requests to vision-capable tiers</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">modality_routing</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token boolean important">true</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token comment" style="color:rgb(0, 128, 0)"># classify new user asks, carry the decision through continuation turns</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classification_mode</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> user_turn</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_default_model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4o</span><br></span></code></pre></div></div>
<p>Context-window escalation is already on; long sessions just stop failing. Modality routing is one line. Both show up in the routing decision, so you can watch exactly when and why each gate fired.</p>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>Try it on your traffic</div><div class="admonitionContent_BuS1"><p>Point a shadow-eval job at your busiest team, compare your current config against one with the new gates on, and tell us what you see in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>, or</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a></div></div>]]></content:encoded>
            <category>routing</category>
            <category>complexity-router</category>
            <category>engineering</category>
        </item>
        <item>
            <title><![CDATA[Day 0 Support: Claude Fable 5.1]]></title>
            <link>https://docs.litellm.ai/blog/claude_fable_5_1</link>
            <guid>https://docs.litellm.ai/blog/claude_fable_5_1</guid>
            <pubDate>Tue, 01 Sep 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[Day 0 support for Claude Fable 5.1 on the LiteLLM AI Gateway, with the 0.025x cache read price tracked from the first call.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="LiteLLM x Claude Fable 5.1" src="https://docs.litellm.ai/assets/images/litellm_claude_fable_5_1_announcement-dd783c4bc96339d15895dc7e5d9275fc.png" width="4800" height="2508" class="img_ev3q"></p>
<p>LiteLLM supports <a href="https://www.anthropic.com/claude-fable-and-mythos-5-1" target="_blank" rel="noopener noreferrer">Claude Fable 5.1</a> on Day 0 across Anthropic, Bedrock, Gemini Enterprise Agent Platform, and Azure, with spend, rate limits, fallbacks, and logging in one place.</p>
<!-- -->
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="whats-new-in-fable-51">What's new in Fable 5.1<a href="https://docs.litellm.ai/blog/claude_fable_5_1#whats-new-in-fable-51" class="hash-link" aria-label="Direct link to What's new in Fable 5.1" title="Direct link to What's new in Fable 5.1">​</a></h2>
<p>Pricing, the 1M-token context window, the 128K output ceiling, and always-on adaptive thinking carry over from Fable 5. What changed, in the order it costs a gateway work:</p>
<ul>
<li><strong>Cache reads cost $0.25 / MTok, down from $1.00.</strong> That is 0.025x base input, where every other Claude model sits at 0.1x. LiteLLM reads the rate from the cost map and falls back to base input without it, a 40x overcount.</li>
<li><strong>Forced tool use returns a 400.</strong> Thinking is always on, and a forced call would skip it. LiteLLM maps OpenAI's <code>tool_choice: "required"</code> to Anthropic's <code>any</code>, so a request that worked on Fable 5 fails here unchanged. Keep <code>auto</code> with <code>strict: true</code> for schema-valid JSON, or name the tool in the prompt to force a call.</li>
<li><strong>Thinking blocks are bound to the model that wrote them.</strong> Fable 5.1 reads earlier models' blocks; none of them read its own.</li>
<li><strong>Editing earlier turns invalidates thinking blocks.</strong> Rebuilding <code>system</code> or <code>tools</code> mid-conversation errors with <code>The block is bound to a different conversation</code>, on accounts created from August 31, 2026.</li>
<li><strong>Effort is steerable per message</strong> behind the <code>mid-conversation-output-config-2026-07-01</code> beta header, without invalidating the prompt cache.</li>
</ul>
<p>Anthropic's <a href="https://platform.claude.com/docs/en/models/fable-5-1/whats-new-fable-5-1" target="_blank" rel="noopener noreferrer">what's new page</a> has the benchmarks and capability gains.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="usage">Usage<a href="https://docs.litellm.ai/blog/claude_fable_5_1#usage" class="hash-link" aria-label="Direct link to Usage" title="Direct link to Usage">​</a></h2>
<div class="tabs-container tabList__CuJ"><ul role="tablist" aria-orientation="horizontal" class="tabs"><li role="tab" tabindex="0" aria-selected="true" class="tabs__item tabItem_LNqP tabs__item--active">Anthropic</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">Bedrock</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">Gemini Enterprise Agent Platform</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">Azure</li></ul><div class="margin-top--md"><div role="tabpanel" class="tabItem_Ymn6"><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">fable</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">fable</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span></code></pre></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">fable</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> bedrock/converse/us.anthropic.claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">fable</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">aws_access_key_id</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/AWS_ACCESS_KEY_ID</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">aws_secret_access_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/AWS_SECRET_ACCESS_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">aws_region_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> us</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">east</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1</span><br></span></code></pre></div></div><p>Bedrock serves it through inference profiles. <code>us.</code> and <code>eu.</code> carry the 10% regional premium, <code>global.</code> stays at base.</p></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">fable</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> vertex_ai/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">fable</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">vertex_project</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/VERTEX_PROJECT</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">vertex_location</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> global</span><br></span></code></pre></div></div><p>Google renamed Vertex AI to Gemini Enterprise Agent Platform; the LiteLLM prefix is still <code>vertex_ai/</code>. Pinned regions carry a 10% premium over global, which LiteLLM applies.</p></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">fable</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> azure_ai/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">fable</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/AZURE_AI_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_base</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/AZURE_AI_API_BASE  </span><span class="token comment" style="color:rgb(0, 128, 0)"># https://&lt;resource&gt;.services.ai.azure.com</span><br></span></code></pre></div></div></div></div></div>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">curl --location 'http://0.0.0.0:4000/chat/completions' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--header 'Content-Type: application/json' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--header 'Authorization: Bearer $LITELLM_KEY' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--data '{</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  "model": "claude-fable-5-1",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  "messages": [{"role": "user", "content": "what llm are you"}],</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  "reasoning_effort": "xhigh"</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">}'</span><br></span></code></pre></div></div>
<p><code>reasoning_effort</code> maps to adaptive thinking, the only mode Fable 5.1 accepts. Fixed budgets, assistant prefill, and non-default <code>temperature</code> or <code>top_p</code> return a 400. Pass <code>output_config: {"effort": "max"}</code> for the full ladder <a href="https://docs.litellm.ai/blog/claude_fable_5">Fable 5 uses</a>.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="feedback">Feedback<a href="https://docs.litellm.ai/blog/claude_fable_5_1#feedback" class="hash-link" aria-label="Direct link to Feedback" title="Direct link to Feedback">​</a></h2>
<p>Hitting something unexpected? Share it on <a href="https://github.com/BerriAI/litellm/discussions/39163" target="_blank" rel="noopener noreferrer">GitHub discussion #39163</a>.</p>]]></content:encoded>
            <category>anthropic</category>
            <category>claude</category>
            <category>fable 5.1</category>
            <category>day 0 support</category>
        </item>
        <item>
            <title><![CDATA[August Townhall Updates: Security, Stability, and Product]]></title>
            <link>https://docs.litellm.ai/blog/august-townhall-updates</link>
            <guid>https://docs.litellm.ai/blog/august-townhall-updates</guid>
            <pubDate>Thu, 27 Aug 2026 12:00:00 GMT</pubDate>
            <description><![CDATA[A recap of the August LiteLLM town hall: 79 security fixes, 375 bug fixes, 142 feature commits, a new Director of Security, the public status dashboard, and Auto-Router results from production.]]></description>
            <content:encoded><![CDATA[<p>Thank you to everyone who joined our August town hall. We used it to share this month's security and stability work and our latest product updates: <strong>79 security fixes</strong>, <strong>375 bug fixes</strong>, and <strong>142 feature commits</strong>, a new Director of Security, a public status dashboard, and Auto-Router results from production.</p>
<!-- -->
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="security">Security<a href="https://docs.litellm.ai/blog/august-townhall-updates#security" class="hash-link" aria-label="Direct link to Security" title="Direct link to Security">​</a></h2>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="79-security-fixes-shipped-this-month">79 security fixes shipped this month<a href="https://docs.litellm.ai/blog/august-townhall-updates#79-security-fixes-shipped-this-month" class="hash-link" aria-label="Direct link to 79 security fixes shipped this month" title="Direct link to 79 security fixes shipped this month">​</a></h3>
<p>Here is where they landed:</p>
<table><thead><tr><th>Category</th><th>Fixes</th><th>Share</th></tr></thead><tbody><tr><td>Access control / authz hardening</td><td>25</td><td>32%</td></tr><tr><td>Credential / secret / PII hardening</td><td>23</td><td>29%</td></tr><tr><td>General hardening (unsafe outbound, UI role gating)</td><td>21</td><td>27%</td></tr><tr><td>Quota / budget / rate-limit hardening</td><td>10</td><td>13%</td></tr></tbody></table>
<p>We backport security fixes across the last four minor release lines. If you're on a version older than a month, upgrading to a newer version is recommended. The current release is v1.99.</p>
<p>We also announced that Oliver Jensen has joined as Director of Security; he was most recently CISO at Regrello.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="whats-next-for-security">What's next for security<a href="https://docs.litellm.ai/blog/august-townhall-updates#whats-next-for-security" class="hash-link" aria-label="Direct link to What's next for security" title="Direct link to What's next for security">​</a></h3>
<p>We're expanding the bug bounty program and hardening the recurring code patterns through the stability sprint.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="stability">Stability<a href="https://docs.litellm.ai/blog/august-townhall-updates#stability" class="hash-link" aria-label="Direct link to Stability" title="Direct link to Stability">​</a></h2>
<p>In August we shipped <strong>375 bug fixes</strong>.</p>
<table><thead><tr><th>Area</th><th>Fixes</th></tr></thead><tbody><tr><td>Other / SDK</td><td>118</td></tr><tr><td>Proxy Core &amp; Resilience</td><td>88</td></tr><tr><td>UI + Auth / SSO</td><td>66</td></tr><tr><td>Cost, Budgets &amp; Observability</td><td>34</td></tr><tr><td>Providers &amp; Model Transforms</td><td>29</td></tr><tr><td>Streaming / Realtime APIs</td><td>22</td></tr><tr><td>MCP Gateway</td><td>18</td></tr></tbody></table>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="statuslitellmai-is-live">status.litellm.ai is live<a href="https://docs.litellm.ai/blog/august-townhall-updates#statuslitellmai-is-live" class="hash-link" aria-label="Direct link to status.litellm.ai is live" title="Direct link to status.litellm.ai is live">​</a></h3>
<p>In an effort to increase transparency, we shipped a public dashboard to display what tests actually ran on the release. You can open any recent release and see which tests passed, drill into a specific area like quota management or Claude Code, and go through the full run history. For example, on the 1.98.0rc1 release, 104 Claude Code tests ran and all of them passed before it shipped.</p>
<p><img decoding="async" loading="lazy" alt="status.litellm.ai showing all 677 executed tests passing on the 1.99.0rc1 release, broken down by module" src="https://docs.litellm.ai/assets/images/status-dashboard-a71fc1f8d57927b217631b273f96748d.png" width="1866" height="1354" class="img_ev3q"></p>
<p>Tracked live at <a href="https://status.litellm.ai/" target="_blank" rel="noopener noreferrer">status.litellm.ai</a>. If you have feedback on how we can improve transparency around releases, let us know.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="what-kinds-of-fixes-shipped">What kinds of fixes shipped<a href="https://docs.litellm.ai/blog/august-townhall-updates#what-kinds-of-fixes-shipped" class="hash-link" aria-label="Direct link to What kinds of fixes shipped" title="Direct link to What kinds of fixes shipped">​</a></h3>
<ul>
<li><strong>Cost tracking and budgets.</strong> Spend logs capture every entry under load, budget resets land on schedule, and cost maps stay accurate as pricing changes roll in.</li>
<li><strong>Batches API.</strong> Multi-pod polling bills each batch exactly once, cost attribution on passthrough batches is correct, and malformed batch uploads get caught before they run.</li>
<li><strong>MCP credential hygiene.</strong> 18 MCP-scoped fixes. Tool calls run under each caller's own credentials, and OAuth sessions stay valid for the full length of a task.</li>
<li><strong>AI gateway auth.</strong> Billing and identity data stay in sync. Cost maps reflect current pricing, spend records persist through traffic spikes, and budgets enforce correctly at renewal and across multi-team splits.</li>
<li><strong>Guardrail masking.</strong> PII and PCI stay masked across spend logs, debug logs, and logging-only responses. Coverage spans every path data can take out of the system.</li>
</ul>
<p>Spend tracking under heavy load was a large area of investment, and it will keep getting attention in the next months.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="the-target-80-e2e-coverage-in-september">The target: 80% E2E coverage in September<a href="https://docs.litellm.ai/blog/august-townhall-updates#the-target-80-e2e-coverage-in-september" class="hash-link" aria-label="Direct link to The target: 80% E2E coverage in September" title="Direct link to The target: 80% E2E coverage in September">​</a></h3>
<p>End-to-end coverage is at 70% across endpoints today. The goal for September is 80%, holding current velocity on bug fixes while we get there.</p>
<p>Most of that work is catching real customer use cases and getting them into the E2E suite. If there's a scenario you think our testing misses, feel free to let us know.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="product">Product<a href="https://docs.litellm.ai/blog/august-townhall-updates#product" class="hash-link" aria-label="Direct link to Product" title="Direct link to Product">​</a></h2>
<p><strong>142 feature commits</strong> this month.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="dark-mode-is-here">Dark mode is here<a href="https://docs.litellm.ai/blog/august-townhall-updates#dark-mode-is-here" class="hash-link" aria-label="Direct link to Dark mode is here" title="Direct link to Dark mode is here">​</a></h3>
<p>Dark mode shipped on the dashboard. Choose dark, light, or follow your system setting.</p>
<p><img decoding="async" loading="lazy" alt="The LiteLLM usage dashboard in dark mode, showing project spend, usage metrics, and daily spend" src="https://docs.litellm.ai/assets/images/dark-mode-ecb2895481ccd36ae462b363559e24cc.png" width="2046" height="1133" class="img_ev3q"></p>
<p>The dashboard is now moved onto one shared component system. The navbar, playground, guardrails, usage, cost tracking, models and endpoints, team and user surfaces, the log details drawer, and the AI Hub, all migrated onto shadcn.</p>
<p>Two engineers did this in under a month, alongside their stability work. The UI looks noticeably different from a month ago as a result.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="day-0-model-support-in-under-an-hour">Day 0 model support in under an hour<a href="https://docs.litellm.ai/blog/august-townhall-updates#day-0-model-support-in-under-an-hour" class="hash-link" aria-label="Direct link to Day 0 model support in under an hour" title="Direct link to Day 0 model support in under an hour">​</a></h3>
<p>Over the last month and a half we've brought time-to-release for a new model down from a day to under an hour.</p>
<ul>
<li><strong>Gemini 3.7 Flash</strong> (Google) shipped in under an hour.</li>
<li><strong>Grok 4.6</strong> (xAI) on a similar timeline.</li>
</ul>
<p>Both landed August 13, the day each provider launched, and shipped in the v1.98.0 stable release on August 22.</p>
<p>Developers ask for the newest model the day it lands, and we're pushing to make this under an hour.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="auto-router-51-cost-savings-in-production">Auto-Router: 51% cost savings in production<a href="https://docs.litellm.ai/blog/august-townhall-updates#auto-router-51-cost-savings-in-production" class="hash-link" aria-label="Direct link to Auto-Router: 51% cost savings in production" title="Direct link to Auto-Router: 51% cost savings in production">​</a></h3>
<p>A design partner ran Auto-Router across 450+ users between April 15 and August 9, covering 272,876 requests and 7.08 billion tokens. Spend came in at $12,249 against a $23,985 all-flagship baseline, a 51.1% reduction, with no meaningful quality impact. Savings climbed from 42.9% in May to 60.7% in August as tier maps were tuned on real traffic. 95% of requests never needed the flagship tier.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="the-classifier-got-smarter">The classifier got smarter<a href="https://docs.litellm.ai/blog/august-townhall-updates#the-classifier-got-smarter" class="hash-link" aria-label="Direct link to The classifier got smarter" title="Direct link to The classifier got smarter">​</a></h3>
<p>Auto-Router now reads the last N turns of a conversation. That change produced a <strong>5.6x improvement in routing accuracy</strong> on referential follow-ups, at no measurable latency cost. It came directly out of community feedback.</p>
<p><img decoding="async" loading="lazy" alt="LiteLLM Auto-Router V2 routing accuracy on complex scenarios, 5.6x more accurate when the classifier reads the last three turns of the conversation" src="https://docs.litellm.ai/assets/images/autorouter-classifier-7f85d531121021d7963ba96867f43774.png" width="2046" height="1069" class="img_ev3q"></p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="auto-routing-and-prompt-caching-stack">Auto-routing and prompt caching stack<a href="https://docs.litellm.ai/blog/august-townhall-updates#auto-routing-and-prompt-caching-stack" class="hash-link" aria-label="Direct link to Auto-routing and prompt caching stack" title="Direct link to Auto-routing and prompt caching stack">​</a></h3>
<p>The most common concern we heard was whether auto-routing would break prompt caching, since caching delivers real savings on its own.</p>
<p>It doesn't. The two stack. Router plus caching came in around 50% cheaper than caching alone in our benchmarks.</p>
<p>The reason is TTL. Prompt cache entries live at least five minutes, and when the router switches models as often as it does, you typically come back to a given model inside that window while its cache is still warm. The hit still lands. <a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark" target="_blank" rel="noopener noreferrer">Full writeup</a>.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="att-cut-ai-costs-56">AT&amp;T cut AI costs 56%<a href="https://docs.litellm.ai/blog/august-townhall-updates#att-cut-ai-costs-56" class="hash-link" aria-label="Direct link to AT&amp;T cut AI costs 56%" title="Direct link to AT&amp;T cut AI costs 56%">​</a></h3>
<p>AT&amp;T reported a 56% cost reduction on coding and other advanced AI tasks after adopting LiteLLM model routing, with a 2% quality drop. Open-source models handle 40% of their employee queries today, and they plan to take that to 60-70%. Reported by <a href="https://www.pymnts.com/news/artificial-intelligence/2026/att-slashes-ai-costs-by-adopting-model-routers-and-open-source/" target="_blank" rel="noopener noreferrer">PYMNTS</a>.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="auto-router-benchmarks">Auto-Router benchmarks<a href="https://docs.litellm.ai/blog/august-townhall-updates#auto-router-benchmarks" class="hash-link" aria-label="Direct link to Auto-Router benchmarks" title="Direct link to Auto-Router benchmarks">​</a></h3>
<p>Four benchmarks published this month, each against its own baseline.</p>
<ul>
<li><strong>Claude Code coding tasks.</strong> 40.4% lower cost at 97.1% of top-model quality.</li>
<li><strong>RouterArena.</strong> On a wider, independently graded prompt set, 74.5% lower cost at 87.3% quality.</li>
<li><strong>Prompt caching.</strong> Stacked with caching, the router beats caching alone by up to 69% on cost.</li>
<li><strong>Terminal-Bench 2.0.</strong> Matches the top model's solve rate on real agentic tasks at 27% lower cost.</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="what-else-shipped-on-auto-router">What else shipped on Auto-Router<a href="https://docs.litellm.ai/blog/august-townhall-updates#what-else-shipped-on-auto-router" class="hash-link" aria-label="Direct link to What else shipped on Auto-Router" title="Direct link to What else shipped on Auto-Router">​</a></h3>
<ul>
<li>
<p><strong>1-click deploy templates.</strong> Pick a model family instead of configuring tiers by hand. Choose Anthropic or OpenAI and the simple, medium, complex, and reasoning tiers come pre-populated. When a provider adds a new model, we update the configuration so you don't have to. Custom configuration is still there if you want it.</p>
<p><img decoding="async" loading="lazy" alt="Add Auto Router dialog with the Anthropic Family, OpenAI Family, and Lite templates listed, each showing whether it matches your deployments" src="https://docs.litellm.ai/assets/images/autorouter-templates-38e4e5bacadd66f5a3cd690bdd3468a9.png" width="2048" height="1314" class="img_ev3q"></p>
</li>
<li>
<p><strong>Auto-Router dashboard.</strong> A usage tab under Cost Optimization showing savings per session, turns per session, session length, and cache-hit analytics. You can compare multiple auto-routers side by side.</p>
<p><img decoding="async" loading="lazy" alt="Auto-Router usage tab under Cost Optimization, showing total estimated savings, average saved per session, and prompt cache hit rate by bucket" src="https://docs.litellm.ai/assets/images/autorouter-dashboard-a85fa567b14f0abc6c87b9a85bf1fbfc.png" width="2048" height="1184" class="img_ev3q"></p>
</li>
<li>
<p><strong>Shadow evaluations.</strong> The biggest blocker to adoption was wanting to see how the router would perform in production before rolling it out. Now you can sample a percentage of one key's traffic through a router, set a spend budget for the test, and pick your own judge model. In our run, the router matched or beat the current model on 75% of sessions.</p>
<p><img decoding="async" loading="lazy" alt="Shadow eval results showing the router matched or beat the current model on 75% of judged responses, broken down by model compared against and prompt difficulty" src="https://docs.litellm.ai/assets/images/shadow-evals-1716120d260b4db421bed90b11a55241.png" width="2048" height="777" class="img_ev3q"></p>
</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="try-auto-router">Try Auto-Router<a href="https://docs.litellm.ai/blog/august-townhall-updates#try-auto-router" class="hash-link" aria-label="Direct link to Try Auto-Router" title="Direct link to Try Auto-Router">​</a></h3>
<ul>
<li><strong>Local CLI:</strong> <a href="https://docs.litellm.ai/docs/learn/autorouter_cli" target="_blank" rel="noopener noreferrer">docs.litellm.ai/docs/learn/autorouter_cli</a></li>
<li><strong>On proxy:</strong> <a href="https://docs.litellm.ai/docs/proxy/auto_routing" target="_blank" rel="noopener noreferrer">docs.litellm.ai/docs/proxy/auto_routing</a></li>
<li><strong>Join the discussion:</strong> <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">GitHub Discussion #32168</a>, pinned in our repo. The community there is actively shaping the roadmap.</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="questions-from-the-audience">Questions from the audience<a href="https://docs.litellm.ai/blog/august-townhall-updates#questions-from-the-audience" class="hash-link" aria-label="Direct link to Questions from the audience" title="Direct link to Questions from the audience">​</a></h2>
<p><strong>How are model prices updated, and where does the data come from?</strong>
<code>model_prices_and_context_window.json</code> is the definitive source. We have automations that alert the team when a provider changes pricing. Where we pull each entry from varies, because providers publish this information in different places. When a provider like OpenAI announces a change, we update that provider, then check the other providers' own pages before propagating, so we don't show a discount on Azure that Azure hasn't actually applied.</p>
<p><strong>Is there a fair-share system if one user sends far more traffic than another?</strong>
Yes. Dynamic request limiting supports thresholds and quotas per user today.</p>
<p><strong>SSO is free up to five users. Is that users sending requests, or users logging in?</strong>
It's the number of user accounts created, counted as rows in the internal users table. One key making a large volume of requests doesn't count against it.</p>
<p><strong>Do you need an Auto-Router configured before running a shadow eval?</strong>
Today, yes. Creating a router first is one extra step, and the model-family template makes it quick. Going straight from shadow eval to picking a family, skipping router creation, is a reasonable flow we haven't built yet. If you want to try it and give feedback, we'll pick it up.</p>
<p><strong>How is the cost reduction figure calculated?</strong>
You pick a target model to benchmark against when you create the router. By default we use the most expensive model in your tier.</p>
<p><strong>Are you clearing the GitHub issue and PR backlog?</strong>
The honest answer is that we need to resource open source better. We're hiring engineers dedicated to maintaining the repo, and expect to have more to share in the next two to three weeks.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="whats-next">What's next<a href="https://docs.litellm.ai/blog/august-townhall-updates#whats-next" class="hash-link" aria-label="Direct link to What's next" title="Direct link to What's next">​</a></h2>
<p>Thanks again for all the questions and feedback. We'll keep sharing concrete progress as this work ships, especially on the September coverage target.</p>
<p>We're also considering bringing customers onto future town halls to talk about their own setups. If that would be useful to you, let us know.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="were-hiring">We're hiring<a href="https://docs.litellm.ai/blog/august-townhall-updates#were-hiring" class="hash-link" aria-label="Direct link to We're hiring" title="Direct link to We're hiring">​</a></h2>
<p>LiteLLM is the open-source gateway thousands of teams use to run every model behind one API, from startups to the Fortune 500. We move fast: 142 features and 375 fixes shipped this month alone.</p>
<p>We're hiring across the core gateway, including on the security team Oliver is building out and on a dedicated open-source maintenance team. Small team, huge surface area, real ownership from day one. Want in, or know someone great? Reach us at <a href="mailto:recruiting@berri.ai" target="_blank" rel="noopener noreferrer">recruiting@berri.ai</a>.</p>
<p>Reach us at <a href="mailto:support@berri.ai" target="_blank" rel="noopener noreferrer">support@berri.ai</a>, or <a href="mailto:product@berri.ai" target="_blank" rel="noopener noreferrer">product@berri.ai</a> for product feedback.</p>
<p>Thank you for using LiteLLM. <strong>Krrish &amp; Ishaan</strong></p>]]></content:encoded>
            <category>townhall</category>
            <category>security</category>
            <category>reliability</category>
            <category>product</category>
        </item>
        <item>
            <title><![CDATA[Shadow Evaluations: Test the Auto-Router on Your Own Production Traffic]]></title>
            <link>https://docs.litellm.ai/blog/auto-router-shadow-evaluations</link>
            <guid>https://docs.litellm.ai/blog/auto-router-shadow-evaluations</guid>
            <pubDate>Tue, 18 Aug 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[Shadow evaluations duplicate a sampled slice of one key's live traffic through an auto-router and have an LLM judge blindly compare the answers. On our own traffic the router matched or beat the current model on 88.1% of judged responses, measured before a single user-facing response changed.]]></description>
            <content:encoded><![CDATA[<p>We have shown the Auto-Router <a href="https://docs.litellm.ai/blog/auto-router-production-savings">saving 51% in production</a> and <a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark">69% stacked on prompt caching</a>. The question we hear next is always the same: <strong>"would it hold quality on my traffic?"</strong></p>
<p><img decoding="async" loading="lazy" alt="Shadow Evaluations: test the Auto-Router on your own production traffic" src="https://docs.litellm.ai/assets/images/hero-222e2672cd20efc8bb9ebd061cdf0794.png" width="3200" height="1676" class="img_ev3q"></p>
<!-- -->
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a></div></div>
<p>Shadow evaluations answer that on your own production traffic, and boil it down to one number. On our own traffic below: <strong>the router matched or beat the current model on 88.1% of judged responses</strong>. Nothing your users see changes while it runs.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="what-a-shadow-eval-does">What a shadow eval does<a href="https://docs.litellm.ai/blog/auto-router-shadow-evaluations#what-a-shadow-eval-does" class="hash-link" aria-label="Direct link to What a shadow eval does" title="Direct link to What a shadow eval does">​</a></h2>
<ul>
<li><strong>Samples a slice of one key's live traffic</strong>; you pick the percentage</li>
<li><strong>Duplicates each sampled request through the auto-router.</strong> The caller still gets the real response; the shadow response is never served to anyone</li>
<li><strong>A blind LLM judge compares the two answers.</strong> It sees answer A and answer B, never which arm produced them</li>
<li><strong>You get a win rate</strong>: real vs. router, overall and per complexity tier</li>
</ul>
<!-- -->
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="two-questions-it-answers">Two questions it answers<a href="https://docs.litellm.ai/blog/auto-router-shadow-evaluations#two-questions-it-answers" class="hash-link" aria-label="Direct link to Two questions it answers" title="Direct link to Two questions it answers">​</a></h2>
<table><thead><tr><th>Direction</th><th>Question</th><th>Real arm</th><th>Shadow arm</th></tr></thead><tbody><tr><td><code>forward</code></td><td>Should this key adopt the router?</td><td>The model the key calls today</td><td>The router's pick</td></tr><tr><td><code>reverse</code></td><td>Is the router still worth it?</td><td>The router's pick, already serving the key</td><td>A fixed baseline model, e.g. the flagship</td></tr></tbody></table>
<p>In forward mode, a shadow arm at rough parity means the router matches your current model's quality at a fraction of the cost. In reverse mode, the real arm holding its own means the router keeps earning its place.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="safe-on-production-traffic-by-construction">Safe on production traffic by construction<a href="https://docs.litellm.ai/blog/auto-router-shadow-evaluations#safe-on-production-traffic-by-construction" class="hash-link" aria-label="Direct link to Safe on production traffic by construction" title="Direct link to Safe on production traffic by construction">​</a></h2>
<ul>
<li>The user-facing response is untouched; the shadow arm is a duplicate nobody receives</li>
<li>Only the one key you pick is sampled, at the percentage you set</li>
<li><code>max_turns</code> is a hard sample budget (default 200, max 2,000); the job judges at most that many turns, then completes. Judge spend is bounded at roughly one judge call per turn</li>
<li><code>duration_days</code> auto-stops the job (default 7, max 30); you can stop it earlier at any time</li>
<li>Requests with logging redaction on are never sampled</li>
<li>Works across <code>/chat/completions</code>, <code>/v1/messages</code>, and <code>/v1/responses</code> traffic</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="reading-the-results">Reading the results<a href="https://docs.litellm.ai/blog/auto-router-shadow-evaluations#reading-the-results" class="hash-link" aria-label="Direct link to Reading the results" title="Direct link to Reading the results">​</a></h2>
<p>One glance answers the question. A completed job on our own traffic, 143 judged turns for $1.55 of judge spend:</p>
<p><img decoding="async" loading="lazy" alt="Shadow eval results: router matched or beat the current model on 88.1% of 143 judged responses" src="https://docs.litellm.ai/assets/images/results_card-f4b797c46551b139f2c73aed2aff0e73.png" width="2000" height="538" class="img_ev3q"></p>
<p>Ties are the point. The router mostly picks a cheaper model, so every tie is the same quality at a lower price; here only 11.9% of turns preferred the current model, and per-tier slices show exactly where those live.</p>
<p>The job also reports:</p>
<ul>
<li><strong>Win rates</strong>: real wins, shadow wins, and ties, as shares of judged turns</li>
<li><strong>Per complexity tier</strong>, so you can see exactly which tier a quality gap lives in and fix that one tier's model instead of abandoning the router</li>
<li><strong>Average judge confidence</strong> per slice</li>
<li><strong>Judge spend so far</strong>, tracked on the job</li>
</ul>
<p>At 88.1% matched-or-beat, the remaining question is not quality; it is why you are still paying flagship prices for every request.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="start-a-shadow-evaluation-on-your-own-production-traffic">Start a shadow evaluation on your own production traffic<a href="https://docs.litellm.ai/blog/auto-router-shadow-evaluations#start-a-shadow-evaluation-on-your-own-production-traffic" class="hash-link" aria-label="Direct link to Start a shadow evaluation on your own production traffic" title="Direct link to Start a shadow evaluation on your own production traffic">​</a></h2>
<p>In the UI: <strong>Cost Optimization → Auto Router → Shadow Evals</strong>, pick a key and a router, start. Or over the API:</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">curl -X POST 'http://localhost:4000/auto_router/shadow_eval/start' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H 'Authorization: Bearer sk-admin' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H 'Content-Type: application/json' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -d '{</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "api_key_id": "88dc28..",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "router_name": "claude-auto-latest",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "shadow_percentage": 10</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  }'</span><br></span></code></pre></div></div>
<p>The judge defaults to <code>anthropic/claude-sonnet-5</code>; a mid-tier judge is the sweet spot, since it only has to compare two answers. Poll <code>GET /auto_router/shadow_eval/{job_id}</code> for live results while the job runs.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="try-it">Try it<a href="https://docs.litellm.ai/blog/auto-router-shadow-evaluations#try-it" class="hash-link" aria-label="Direct link to Try it" title="Direct link to Try it">​</a></h2>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>info</div><div class="admonitionContent_BuS1"><p>Start a shadow eval against a key you already run in production and let it judge a week of real traffic. Share numbers or questions in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>. To work on this with us directly, <a href="https://calendar.app.google/i2e7qVEJphHi5S8UA" target="_blank" rel="noopener noreferrer">apply to be a design partner</a>.</p></div></div>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockTitle_OeMC">config.yaml</div><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">auto</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">latest</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> auto_router/complexity_router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">tiers</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">SIMPLE</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">MEDIUM</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">COMPLEX</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">   claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">REASONING</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_default_model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><br></span></code></pre></div></div>
<p>Full reference, including every shadow eval knob, on the <a href="https://docs.litellm.ai/docs/proxy/auto_routing">Auto Routing docs page</a>.</p>]]></content:encoded>
            <category>routing</category>
            <category>complexity-router</category>
            <category>evals</category>
            <category>quality</category>
            <category>engineering</category>
        </item>
        <item>
            <title><![CDATA[Day 0 support: Gemini 3.7 Flash]]></title>
            <link>https://docs.litellm.ai/blog/gemini_3_7_flash</link>
            <guid>https://docs.litellm.ai/blog/gemini_3_7_flash</guid>
            <pubDate>Thu, 13 Aug 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[day 0 support for Gemini 3.7 Flash on LiteLLM, with launch pricing tracked across Google AI Studio and Vertex AI.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="LiteLLM x Gemini 3.7 Flash" src="https://docs.litellm.ai/assets/images/hero-e8c5fa48706299f3be1e0eea539f5246.png" width="4800" height="2508" class="img_ev3q"></p>
<p>LiteLLM now supports <code>gemini-3.7-flash</code> on day 0, on both Google AI Studio (<code>gemini/</code>) and Vertex AI (<code>vertex_ai/</code>). Google's newest Flash model delivers faster responses with meaningfully better quality than 3.6 Flash and scores higher on complex multi-step agentic, coding, and reasoning benchmarks.</p>
<!-- -->
<div class="theme-admonition theme-admonition-note admonition_xJq3 alert alert--secondary"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"></path></svg></span>note</div><div class="admonitionContent_BuS1"><p><strong>No Docker image upgrade needed.</strong> Gemini 3.7 Flash routes through the existing Gemini configs, so any recent LiteLLM version works out of the box for inference. For cost tracking, hit the <strong>Reload Model Cost Map</strong> button in the Admin UI (or <code>POST /reload/model_cost_map</code>) to pull the latest pricing from GitHub. This is available on <code>v1.76.0</code> and above. The <code>gemini-3.7-flash</code> pricing and metadata are also bundled starting in <code>v1.98.0-dev.2</code> for anyone running with <code>LITELLM_LOCAL_MODEL_COST_MAP=true</code>.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="launch-pricing">Launch pricing<a href="https://docs.litellm.ai/blog/gemini_3_7_flash#launch-pricing" class="hash-link" aria-label="Direct link to Launch pricing" title="Direct link to Launch pricing">​</a></h2>
<p>Gemini 3.7 Flash launches at a 50% discount that runs through December 31, 2026. LiteLLM tracks cost at the promotional rate.</p>
<table><thead><tr><th></th><th>Promotional</th><th>Standard</th></tr></thead><tbody><tr><td>Input</td><td>$0.75 / 1M tokens</td><td>$1.50 / 1M tokens</td></tr><tr><td>Output</td><td>$3.75 / 1M tokens</td><td>$7.50 / 1M tokens</td></tr></tbody></table>
<p>Cache reads, batch, flex, and priority tiers are discounted proportionally.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="quick-start">Quick Start<a href="https://docs.litellm.ai/blog/gemini_3_7_flash#quick-start" class="hash-link" aria-label="Direct link to Quick Start" title="Direct link to Quick Start">​</a></h2>
<div class="tabs-container tabList__CuJ"><ul role="tablist" aria-orientation="horizontal" class="tabs"><li role="tab" tabindex="0" aria-selected="true" class="tabs__item tabItem_LNqP tabs__item--active">SDK</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">PROXY</li></ul><div class="margin-top--md"><div role="tabpanel" class="tabItem_Ymn6"><div class="language-python codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-python codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token keyword" style="color:rgb(0, 0, 255)">from</span><span class="token plain"> litellm </span><span class="token keyword" style="color:rgb(0, 0, 255)">import</span><span class="token plain"> completion</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">response </span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token plain"> completion</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    model</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token string" style="color:rgb(163, 21, 21)">"gemini/gemini-3.7-flash"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    messages</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token string" style="color:rgb(163, 21, 21)">"role"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"user"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"content"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"Summarize this article in 3 bullet points."</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token keyword" style="color:rgb(0, 0, 255)">print</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain">response</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">choices</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token number" style="color:rgb(9, 134, 88)">0</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">message</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">content</span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><br></span></code></pre></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><p><strong>1. Setup config.yaml</strong></p><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gemini</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">3.7</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">flash</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gemini/gemini</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">3.7</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">flash</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/GEMINI_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token comment" style="color:rgb(0, 128, 0)"># Or use Vertex AI</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> vertex</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">gemini</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">3.7</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">flash</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> vertex_ai/gemini</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">3.7</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">flash</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">vertex_project</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> your</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">project</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">id</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">vertex_location</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> us</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">central1</span><br></span></code></pre></div></div><p><strong>2. Start proxy</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">litellm --config /path/to/config.yaml</span><br></span></code></pre></div></div><p><strong>3. Make requests</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">curl -X POST http://localhost:4000/v1/chat/completions \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H "Content-Type: application/json" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -H "Authorization: Bearer &lt;YOUR-LITELLM-KEY&gt;" \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -d '{</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "model": "gemini-3.7-flash",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "messages": [{"role": "user", "content": "Hello!"}]</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  }'</span><br></span></code></pre></div></div></div></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="thinking-levels">Thinking levels<a href="https://docs.litellm.ai/blog/gemini_3_7_flash#thinking-levels" class="hash-link" aria-label="Direct link to Thinking levels" title="Direct link to Thinking levels">​</a></h2>
<p>Gemini 3.7 Flash is a reasoning model. LiteLLM maps OpenAI <code>reasoning_effort</code> to Gemini's <code>thinkingLevel</code>, so the same request shape you use for other reasoning models works here.</p>
<div class="language-python codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-python codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token keyword" style="color:rgb(0, 0, 255)">from</span><span class="token plain"> litellm </span><span class="token keyword" style="color:rgb(0, 0, 255)">import</span><span class="token plain"> completion</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">response </span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token plain"> completion</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    model</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token string" style="color:rgb(163, 21, 21)">"gemini/gemini-3.7-flash"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    messages</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token string" style="color:rgb(163, 21, 21)">"role"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"user"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"content"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"What's 2+2?"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    reasoning_effort</span><span class="token operator" style="color:rgb(0, 0, 0)">=</span><span class="token string" style="color:rgb(163, 21, 21)">"low"</span><span class="token punctuation" style="color:rgb(4, 81, 165)">,</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain"></span><span class="token keyword" style="color:rgb(0, 0, 255)">print</span><span class="token punctuation" style="color:rgb(4, 81, 165)">(</span><span class="token plain">response</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">choices</span><span class="token punctuation" style="color:rgb(4, 81, 165)">[</span><span class="token number" style="color:rgb(9, 134, 88)">0</span><span class="token punctuation" style="color:rgb(4, 81, 165)">]</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">message</span><span class="token punctuation" style="color:rgb(4, 81, 165)">.</span><span class="token plain">content</span><span class="token punctuation" style="color:rgb(4, 81, 165)">)</span><br></span></code></pre></div></div>
<div class="theme-admonition theme-admonition-warning admonition_xJq3 alert alert--warning"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 16 16"><path fill-rule="evenodd" d="M8.893 1.5c-.183-.31-.52-.5-.887-.5s-.703.19-.886.5L.138 13.499a.98.98 0 0 0 0 1.001c.193.31.53.501.886.501h13.964c.367 0 .704-.19.877-.5a1.03 1.03 0 0 0 .01-1.002L8.893 1.5zm.133 11.497H6.987v-2.003h2.039v2.003zm0-3.004H6.987V5.987h2.039v4.006z"></path></svg></span>Known limitation at launch</div><div class="admonitionContent_BuS1"><p>The <code>minimal</code> thinking level is not yet supported on <code>gemini-3.7-flash</code>. The Gemini API returns a 400 (<code>Thinking level MINIMAL is not supported for this model</code>). Google plans minimal thinking support as a fast follow. All other thinking levels work as expected.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="supported-endpoints">Supported Endpoints<a href="https://docs.litellm.ai/blog/gemini_3_7_flash#supported-endpoints" class="hash-link" aria-label="Direct link to Supported Endpoints" title="Direct link to Supported Endpoints">​</a></h2>
<p>LiteLLM provides full end-to-end support for Gemini 3.7 Flash on:</p>
<ul>
<li><code>/v1/chat/completions</code> - OpenAI-compatible chat completions endpoint</li>
<li><code>/v1/responses</code> - OpenAI Responses API endpoint (streaming and non-streaming)</li>
<li><a href="https://docs.litellm.ai/docs/anthropic_unified"><code>/v1/messages</code></a> - Anthropic-compatible messages endpoint</li>
<li><code>/v1/generateContent</code> - <a href="https://docs.litellm.ai/docs/generateContent">Google Gemini API</a> compatible endpoint</li>
</ul>
<p>All endpoints support streaming and non-streaming responses, function calling with thought signatures, multi-turn conversations, and full multimodal input (text, image, audio, video).</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="feedback">Feedback<a href="https://docs.litellm.ai/blog/gemini_3_7_flash#feedback" class="hash-link" aria-label="Direct link to Feedback" title="Direct link to Feedback">​</a></h2>
<p>Running Gemini 3.7 Flash through LiteLLM and hitting something unexpected? Share it on <a href="https://github.com/BerriAI/litellm/discussions/36799" target="_blank" rel="noopener noreferrer">GitHub discussion #36799</a>.</p>]]></content:encoded>
            <category>gemini</category>
            <category>gemini-3.7-flash</category>
            <category>day 0 support</category>
            <category>llms</category>
        </item>
        <item>
            <title><![CDATA[August Townhall: Product + Roadmap Updates]]></title>
            <link>https://docs.litellm.ai/blog/august-townhall-announcement</link>
            <guid>https://docs.litellm.ai/blog/august-townhall-announcement</guid>
            <pubDate>Mon, 10 Aug 2026 12:00:00 GMT</pubDate>
            <description><![CDATA[Join the LiteLLM August townhall on Thursday, 27 August at 7:30 AM PT to learn about LiteLLM's product updates and roadmap.]]></description>
            <content:encoded><![CDATA[<p>We are hosting our August townhall on <strong>Thursday, 27 August at 7:30 AM PT</strong>.</p>
<div style="background-size:cover;background-repeat:no-repeat;position:relative;background-image:url(&quot;data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAoAAAADCAIAAAAlXwkiAAAACXBIWXMAAA7EAAAOxAGVKw4bAAAAZUlEQVR4nGPgUnHkVrTlVHUT0nRUN7f1iguOrCkJLCx0Scy0C09ikNR31rBy908rjCooSW9siS1vCMso9k8pNnANUrTxY9DU1tI2MLKwsdZSVtGVVdCRkNWXlteWkDUWFDERlQYAaHoWfDiAvK8AAAAASUVORK5CYII=&quot;)"><svg style="width:100%;height:auto;max-width:100%;margin-bottom:-4px" width="640" height="160"></svg><noscript><img style=width:100%;height:auto;max-width:100%;margin-bottom:-4px;position:absolute;top:0;left:0 src=/assets/ideal-img/august_townhall_banner.bf052e7.640.png srcset="/assets/ideal-img/august_townhall_banner.bf052e7.640.png 640w,/assets/ideal-img/august_townhall_banner.73eee77.800.png 800w" width=640 height=160></noscript></div>
<!-- -->
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="agenda">Agenda<a href="https://docs.litellm.ai/blog/august-townhall-announcement#agenda" class="hash-link" aria-label="Direct link to Agenda" title="Direct link to Agenda">​</a></h2>
<ul>
<li>Product updates and roadmap progress</li>
<li>Reliability and security updates</li>
<li>Open Q&amp;A with the team</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="stability">Stability<a href="https://docs.litellm.ai/blog/august-townhall-announcement#stability" class="hash-link" aria-label="Direct link to Stability" title="Direct link to Stability">​</a></h2>
<p>Our team is focused on stability: improving reliability and reducing regressions across releases. Follow the roadmap here: <a href="https://github.com/BerriAI/litellm/issues/30484" target="_blank" rel="noopener noreferrer">Stability roadmap</a>.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="how-to-contribute">How to contribute<a href="https://docs.litellm.ai/blog/august-townhall-announcement#how-to-contribute" class="hash-link" aria-label="Direct link to How to contribute" title="Direct link to How to contribute">​</a></h2>
<p>Add the topics and questions you'd like us to cover when you register below. We use your responses to set the agenda.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="register">Register<a href="https://docs.litellm.ai/blog/august-townhall-announcement#register" class="hash-link" aria-label="Direct link to Register" title="Direct link to Register">​</a></h2>
<p>Register here: <a href="https://forms.gle/ti1BATLWmYQNb7bcA" target="_blank" rel="noopener noreferrer">LiteLLM August Townhall Form</a></p>
<p>We will hold the townhall from <strong>7:30 AM to 8:30 AM PT on Zoom</strong>.</p>
<p>For security, attendance is restricted to corporate emails. If you register with a non-corporate email, we will share the townhall slides and accompanying blog post after the event.</p>]]></content:encoded>
            <category>announcement</category>
            <category>townhall</category>
        </item>
        <item>
            <title><![CDATA[51% Cost Savings Reported From a Live Production Deployment]]></title>
            <link>https://docs.litellm.ai/blog/auto-router-production-savings</link>
            <guid>https://docs.litellm.ai/blog/auto-router-production-savings</guid>
            <pubDate>Mon, 10 Aug 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[A LiteLLM customer rolled the Auto Router out to 450+ users in production and shared four months of numbers: 272,876 requests, 7.08 billion tokens, and $12,249 saved against an all-flagship baseline.]]></description>
            <content:encoded><![CDATA[<p>You can expect roughly 40% cost reductions from day one with the Auto Router, and more as the tier maps are tuned. One of our production users shared their statistics to show what that looks like at scale.</p>
<p>They rolled out the Auto-Router to 450+ users across dev, staging, and prod instances and saved <strong>$12,249 over 270k+ requests</strong>.</p>
<p><img decoding="async" loading="lazy" alt="Production traffic recorded 51% cost-savings with the Auto-Router" src="https://docs.litellm.ai/assets/images/hero-5a5c7b9f2640e96f1ae0cc7929966f32.png" width="3200" height="1676" class="img_ev3q"></p>
<!-- -->
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="key-findings">Key findings<a href="https://docs.litellm.ai/blog/auto-router-production-savings#key-findings" class="hash-link" aria-label="Direct link to Key findings" title="Direct link to Key findings">​</a></h2>
<ul>
<li><strong>Half the bill.</strong> $12,249 saved on $23,985 of would-be flagship spend, a 51.1% reduction</li>
<li><strong>95% of requests never needed the flagship tier.</strong> Blended cost landed at $1.66 per 1M tokens against $3.39 per 1M at the flagship</li>
<li><strong>The savings rate kept climbing</strong>, from 42.9% in the first full month to 60.7% by August, as the team tuned the tier maps</li>
<li><strong>Nothing changed in their applications.</strong> Users kept calling one model name and the router picked the tier</li>
</ul>
<table><thead><tr><th></th><th></th></tr></thead><tbody><tr><td>Requests through the auto-routers</td><td>272,876</td></tr><tr><td>Tokens</td><td>7.08 B</td></tr><tr><td>Distinct end users</td><td>450+</td></tr><tr><td>Window</td><td>2026-04-15 to 2026-08-09</td></tr><tr><td><strong>Actual spend</strong></td><td><strong>$11,736</strong></td></tr><tr><td>Cost if every request had gone to the top tier</td><td>$23,985</td></tr><tr><td><strong>Saved</strong></td><td><strong>$12,249 (51.1%)</strong></td></tr></tbody></table>
<p>That 95% number is the whole thesis. Nineteen out of twenty requests did not need the biggest model, and nobody had to decide that by hand.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="three-routers-three-model-families">Three routers, three model families<a href="https://docs.litellm.ai/blog/auto-router-production-savings#three-routers-three-model-families" class="hash-link" aria-label="Direct link to Three routers, three model families" title="Direct link to Three routers, three model families">​</a></h2>
<p>The Auto-Router works across Anthropic, Gemini, and GPT, so they ran one complexity router per model family and let their users pick a family rather than a model.</p>
<p>Key findings:</p>
<ul>
<li>Largest absolute savings came from the busiest and most expensive router</li>
<li>GPT family (<code>gpt-auto-latest</code>) recorded the largest relative savings between its flagship and cheap tier</li>
</ul>
<table><thead><tr><th>Router</th><th>Requests</th><th>Spent</th><th>Saved</th><th>Savings</th></tr></thead><tbody><tr><td><code>claude-auto-latest</code></td><td>109,675</td><td>$8,997</td><td>$7,951</td><td><strong>46.9%</strong></td></tr><tr><td><code>gemini-auto-latest</code></td><td>90,294</td><td>$1,327</td><td>$1,280</td><td><strong>49.1%</strong></td></tr><tr><td><code>gpt-auto-latest</code></td><td>72,906</td><td>$1,412</td><td>$3,019</td><td><strong>68.1%</strong></td></tr></tbody></table>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="it-got-better-every-month">It got better every month<a href="https://docs.litellm.ai/blog/auto-router-production-savings#it-got-better-every-month" class="hash-link" aria-label="Direct link to It got better every month" title="Direct link to It got better every month">​</a></h2>
<p>The savings rate is still climbing as the tier maps mature.</p>
<table><thead><tr><th>Month</th><th>Saved</th><th>Savings rate</th></tr></thead><tbody><tr><td>2026-05</td><td>$2,282</td><td>42.9%</td></tr><tr><td>2026-06</td><td>$3,274</td><td>50.0%</td></tr><tr><td>2026-07</td><td>$4,917</td><td>53.7%</td></tr><tr><td>2026-08 (to the 9th)</td><td>$1,769</td><td><strong>60.7%</strong></td></tr></tbody></table>
<ul>
<li>Month one already returned 43%, which is the install-it-and-walk-away number</li>
<li>Four months in they are at <strong>60.7%</strong></li>
<li>The difference is tuning. As the team learned which prompts belonged in which tier, they adjusted the maps</li>
</ul>
<p>Day-one value is real, and it compounds.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="how-it-was-measured">How it was measured<a href="https://docs.litellm.ai/blog/auto-router-production-savings#how-it-was-measured" class="hash-link" aria-label="Direct link to How it was measured" title="Direct link to How it was measured">​</a></h2>
<p>This is production traffic rather than a curated benchmark. 450+ real people, every environment including dev and staging with all the messy traffic that implies, four months rather than a single afternoon, and no prompt curation at all; whatever users typed is what got routed.</p>
<p>The method matters as much as the number, so here it is in full.</p>
<ul>
<li>Numbers come straight from <strong><code>LiteLLM_SpendLogs</code></strong>, with no sampling and no estimation</li>
<li>Every row records the requested <code>model_group</code>, the model the router <strong>actually</strong> served, and the full token split: fresh input, cache read, cache write, output</li>
<li>For each request, the <strong>exact same tokens</strong>, with the same cache read and write split, are re-priced at that router's <strong>REASONING-tier model</strong></li>
<li>That re-price is the counterfactual, meaning "what if we had always called the flagship"</li>
<li>Prices come from <strong>the same loaded LiteLLM cost map</strong> that produced the recorded spend, so both sides are like-for-like USD list price</li>
<li>Flagship prices did not change over the window (opus $5/$25, gemini pro $2/$12, gpt flagship $5/$30 per 1M), so the baseline needs no time-varying assumption</li>
</ul>
<p>Two caveats belong with the number:</p>
<ol>
<li><strong>This is a model, not an A/B test.</strong> It assumes the flagship would have emitted the same number of output tokens. Flagships usually emit more, because of reasoning tokens, so 51% is a conservative floor rather than a ceiling</li>
<li><strong>Prices are USD list prices</strong> from the cost map, not the customer's invoiced amounts</li>
</ol>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="the-config">The config<a href="https://docs.litellm.ai/blog/auto-router-production-savings#the-config" class="hash-link" aria-label="Direct link to The config" title="Direct link to The config">​</a></h2>
<p>This is the shape they deployed, one router per model family:</p>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockTitle_OeMC">config.yaml</div><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain">           </span><span class="token comment" style="color:rgb(0, 128, 0)"># $1 / $5 per 1M tokens</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain">            </span><span class="token comment" style="color:rgb(0, 128, 0)"># $3 / $15</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain">              </span><span class="token comment" style="color:rgb(0, 128, 0)"># $5 / $25</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">auto</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">latest</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> auto_router/complexity_router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">tiers</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">SIMPLE</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">MEDIUM</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">COMPLEX</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">   claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">REASONING</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_default_model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><br></span></code></pre></div></div>
<p>Note that SIMPLE and MEDIUM both point at the cheapest model rather than doubling up on the flagship, which is where most of the 95% below-flagship share comes from. The flagship stays reserved for the REASONING tier, which is also the tier the counterfactual prices against.</p>
<p>Point a client at <code>claude-auto-latest</code> and every response carries <code>x-litellm-model-name</code> and <code>x-litellm-response-cost</code>, which is the same instrumentation this study was built on. Full reference, including the classifier and tier-boundary knobs, on the <a href="https://docs.litellm.ai/docs/proxy/auto_routing">Auto Routing docs page</a>.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="try-it">Try it<a href="https://docs.litellm.ai/blog/auto-router-production-savings#try-it" class="hash-link" aria-label="Direct link to Try it" title="Direct link to Try it">​</a></h2>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>info</div><div class="admonitionContent_BuS1"><p>Point an agent at an auto router and compare it against your current single model on your own workload. Share numbers or questions in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>. To work on this with us directly, <a href="https://calendar.app.google/i2e7qVEJphHi5S8UA" target="_blank" rel="noopener noreferrer">apply to be a design partner</a>.</p></div></div>]]></content:encoded>
            <category>routing</category>
            <category>complexity-router</category>
            <category>cost</category>
            <category>case-study</category>
            <category>engineering</category>
        </item>
        <item>
            <title><![CDATA[Auto Router: Opus level quality at up to 27% lower cost]]></title>
            <link>https://docs.litellm.ai/blog/auto-router-terminal-bench-benchmark</link>
            <guid>https://docs.litellm.ai/blog/auto-router-terminal-bench-benchmark</guid>
            <pubDate>Sat, 08 Aug 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[On a 21 task subset of Terminal-Bench 2.0, an auto router matched Claude Opus-5 solve rate at 27% lower cost. Adding the last 3 user messages as classifier context raised relative quality 14% but cost 44% more; adding assistant replies made both worse.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="Auto Router: Opus level quality at 27% less cost, on a 21 task subset of Terminal-Bench 2.0" src="https://docs.litellm.ai/assets/images/hero-ae82a5735050b96c082cf035e2878b50.png" width="2400" height="1260" class="img_ev3q"></p>
<p><strong>An auto router matched Claude Opus-5 solve rate on a 21 task subset of Terminal-Bench 2.0 at 27% lower cost.</strong> Every arm ran the same 21 tasks, so the comparisons are like for like.</p>
<!-- -->
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a><br><br><p>Already testing it? Share your results in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="key-findings">Key findings<a href="https://docs.litellm.ai/blog/auto-router-terminal-bench-benchmark#key-findings" class="hash-link" aria-label="Direct link to Key findings" title="Direct link to Key findings">​</a></h2>
<ul>
<li><strong>Opus level quality at 27% lower cost.</strong> The 5.4-mini classifier (single message context) router solved 16/21 tasks, the same as Opus-5, for $14.34 against $19.74</li>
<li><strong>Instead of increasing context-window, consider a better model</strong> Going from 1-message context to the last 3 user messages took the 4o-mini router from 66.7% to 76.2%, and cost from $12.86 to $18.58: +14% relative quality, +44% cost. GPT 5.4-mini classifier with 1-message context beats these results at lower cost.</li>
<li><strong>Context slows tasks down.</strong> Median wall clock per task went from 6.8 min to 8.3 min when adding 3-6 messages as context</li>
<li><strong>Adding assistant replies isn't worth it.</strong> A window of 6 messages including LLM replies <em>dropped</em> relative quality 7% (66.7% to 61.9%) and raised cost 34%</li>
<li><strong>The heuristic router is a good value option.</strong> 87% of Opus quality at 56% of the cost, with no classifier call and the lowest median wall clock of any arm</li>
</ul>
<p><img decoding="async" loading="lazy" alt="Routers vs single models: quality against total cost on Terminal-Bench 2.0" src="https://docs.litellm.ai/assets/images/routers-vs-single-models-00537efb2b208a462fed6b6fdc4243bd.png" width="2248" height="1192" class="img_ev3q"></p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="results">Results<a href="https://docs.litellm.ai/blog/auto-router-terminal-bench-benchmark#results" class="hash-link" aria-label="Direct link to Results" title="Direct link to Results">​</a></h2>
<table><thead><tr><th>Configuration</th><th style="text-align:right">Solve rate</th><th style="text-align:right">Solved/n</th><th style="text-align:right">Total cost</th><th style="text-align:right">$/solved</th><th style="text-align:right">Median task wall clock</th><th style="text-align:right">p95 turn</th><th>Haiku/Sonnet/Opus</th><th style="text-align:right">Switch rate</th><th style="text-align:right">Cache hit</th></tr></thead><tbody><tr><td>Router: 5.4-mini</td><td style="text-align:right">76.2%</td><td style="text-align:right">16/21</td><td style="text-align:right"><strong>$14.34</strong></td><td style="text-align:right">$0.90</td><td style="text-align:right">6.7 min</td><td style="text-align:right">62.8s</td><td>20%/39%/40%</td><td style="text-align:right">54%</td><td style="text-align:right">78%</td></tr><tr><td>Router: 4o-mini (3 user)</td><td style="text-align:right">76.2%</td><td style="text-align:right">16/21</td><td style="text-align:right">$18.58</td><td style="text-align:right">$1.16</td><td style="text-align:right">8.3 min</td><td style="text-align:right">67.9s</td><td>18%/36%/45%</td><td style="text-align:right">55%</td><td style="text-align:right">78%</td></tr><tr><td>Opus-5 only</td><td style="text-align:right">76.2%</td><td style="text-align:right">16/21</td><td style="text-align:right">$19.74</td><td style="text-align:right">$1.23</td><td style="text-align:right">6.4 min</td><td style="text-align:right">94.6s</td><td>0%/0%/99%</td><td style="text-align:right">4%</td><td style="text-align:right">89%</td></tr><tr><td>Router: heuristic</td><td style="text-align:right">66.7%</td><td style="text-align:right">14/21</td><td style="text-align:right">$11.11</td><td style="text-align:right">$0.79</td><td style="text-align:right">5.6 min</td><td style="text-align:right">43.3s</td><td>32%/53%/14%</td><td style="text-align:right">48%</td><td style="text-align:right">83%</td></tr><tr><td>Router: 4o-mini (1-message)</td><td style="text-align:right">66.7%</td><td style="text-align:right">14/21</td><td style="text-align:right">$12.86</td><td style="text-align:right">$0.92</td><td style="text-align:right">6.8 min</td><td style="text-align:right">53.1s</td><td>33%/34%/34%</td><td style="text-align:right">58%</td><td style="text-align:right">79%</td></tr><tr><td>Router: 4o-mini (6 both)</td><td style="text-align:right">61.9%</td><td style="text-align:right">13/21</td><td style="text-align:right">$17.23</td><td style="text-align:right">$1.33</td><td style="text-align:right">6.3 min</td><td style="text-align:right">112.3s</td><td>5%/50%/44%</td><td style="text-align:right">46%</td><td style="text-align:right">80%</td></tr><tr><td>Sonnet-5 only</td><td style="text-align:right">57.1%</td><td style="text-align:right">12/21</td><td style="text-align:right">$9.76</td><td style="text-align:right">$0.81</td><td style="text-align:right">8.5 min</td><td style="text-align:right">60.5s</td><td>0%/99%/0%</td><td style="text-align:right">1%</td><td style="text-align:right">93%</td></tr><tr><td>Haiku-4.5 only</td><td style="text-align:right">33.3%</td><td style="text-align:right">7/21</td><td style="text-align:right">$4.24</td><td style="text-align:right">$0.61</td><td style="text-align:right">4.9 min</td><td style="text-align:right">12.6s</td><td>100%/0%/0%</td><td style="text-align:right">0%</td><td style="text-align:right">93%</td></tr></tbody></table>
<p>Cost is the total for all 21 tasks and includes the classifier call, which ran between $0.05 and $0.34 depending on the classifier.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="breakdown-of-context-window-results">Breakdown of Context Window Results<a href="https://docs.litellm.ai/blog/auto-router-terminal-bench-benchmark#breakdown-of-context-window-results" class="hash-link" aria-label="Direct link to Breakdown of Context Window Results" title="Direct link to Breakdown of Context Window Results">​</a></h2>
<p><code>1-message</code> sends only the current user message to the classifier. <code>3 user</code> sends the last 3 user messages. <code>6 both</code> sends the last 6 messages including assistant replies. All three use the same 4o-mini classifier and the same tier mapping, so the only variable is what the classifier reads. 5.4-mini with no context beat all, overall.</p>
<table><thead><tr><th>Context window</th><th style="text-align:right">Solve rate</th><th style="text-align:right">Relative to 1-message</th><th style="text-align:right">Total cost</th><th style="text-align:right">Relative to 1-message</th><th style="text-align:right">Median task wall clock</th></tr></thead><tbody><tr><td>1-message</td><td style="text-align:right">66.7%</td><td style="text-align:right">reference</td><td style="text-align:right">$12.86</td><td style="text-align:right">reference</td><td style="text-align:right">6.8 min</td></tr><tr><td>Last 3 user messages</td><td style="text-align:right">76.2%</td><td style="text-align:right">+14%</td><td style="text-align:right">$18.58</td><td style="text-align:right">+44%</td><td style="text-align:right">8.3 min</td></tr><tr><td>Last 6 messages, user and assistant</td><td style="text-align:right">61.9%</td><td style="text-align:right">-7%</td><td style="text-align:right">$17.23</td><td style="text-align:right">+34%</td><td style="text-align:right">6.3 min</td></tr></tbody></table>
<p>Prior user turns tell the classifier what the task actually is, so it escalates to Opus on the turns that need it: the Opus share goes from 34% to 45%, which is where most of the extra cost comes from. Assistant replies pull in tool output and long generated text that read as complexity signal without adding task intent; that arm routed almost nothing to Haiku (5%) yet still scored worst of the three.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="how-it-was-measured">How it was measured<a href="https://docs.litellm.ai/blog/auto-router-terminal-bench-benchmark#how-it-was-measured" class="hash-link" aria-label="Direct link to How it was measured" title="Direct link to How it was measured">​</a></h2>
<ul>
<li><strong>Benchmark:</strong> a 21 task subset of Terminal-Bench 2.0, completed by all 8 arms: adaptive-rejection-sampler, build-pmars, chess-best-move, cobol-modernization, crack-7z-hash, filter-js-from-html, gcode-to-text, install-windows-3.11, largest-eigenval, llm-inference-batching-scheduler, merge-diff-arc-agi-task, multi-source-data-merger, overfull-hbox, password-recovery, polyglot-c-py, prove-plus-comm, pypi-server, sparql-university, train-fasttext, winning-avg-corewars, write-compressor</li>
<li><strong>Router arms:</strong> one model group, four tiers. SIMPLE to <code>claude-haiku-4-5</code>, MEDIUM to <code>claude-sonnet-5</code>, COMPLEX and REASONING to <code>claude-opus-5</code>. Classifier is either the heuristic or an LLM (<code>gpt-4o-mini</code>, <code>gpt-5.4-mini</code>)</li>
<li><strong>Baseline arms:</strong> every request to one fixed model, with prompt caching on in all arms</li>
<li><strong>Cost:</strong> total USD across all 21 tasks from gateway spend logs, classifier calls included</li>
<li><strong>Errors:</strong> 0 to 4 per arm, from harness and provider failures, excluded from solve rate denominators only where the task did not complete for that arm</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="config">Config<a href="https://docs.litellm.ai/blog/auto-router-terminal-bench-benchmark#config" class="hash-link" aria-label="Direct link to Config" title="Direct link to Config">​</a></h2>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockTitle_OeMC">config.yaml</div><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> smart</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> auto_router/complexity_router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">tiers</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">SIMPLE</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">MEDIUM</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">COMPLEX</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">   claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">REASONING</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_type</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> llm</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_llm_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5.4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">mini</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_context_window_size</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(9, 134, 88)">0</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_default_model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><br></span></code></pre></div></div>
<p>Every response carries <code>x-litellm-model-name</code> and <code>x-litellm-response-cost</code>, and per router cost and usage land in the Auto-Router Benchmarks tab. Full reference on the <a href="https://docs.litellm.ai/docs/proxy/auto_routing">Auto Routing docs page</a>.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="try-it">Try it<a href="https://docs.litellm.ai/blog/auto-router-terminal-bench-benchmark#try-it" class="hash-link" aria-label="Direct link to Try it" title="Direct link to Try it">​</a></h2>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>info</div><div class="admonitionContent_BuS1"><p>Point an agent at an auto router and compare it against your current single model on your own workload. Share numbers or questions in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>. To work on this with us directly, <a href="https://calendar.app.google/i2e7qVEJphHi5S8UA" target="_blank" rel="noopener noreferrer">apply to be a design partner</a>.</p></div></div>]]></content:encoded>
            <category>routing</category>
            <category>complexity-router</category>
            <category>cost</category>
            <category>benchmarks</category>
            <category>engineering</category>
        </item>
        <item>
            <title><![CDATA[AutoRouter: Easy Visibility to Your Savings]]></title>
            <link>https://docs.litellm.ai/blog/auto-router-spend-visibility</link>
            <guid>https://docs.litellm.ai/blog/auto-router-spend-visibility</guid>
            <pubDate>Thu, 06 Aug 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[A new Auto-Router Usage tab in Cost Optimization, per-request classifier cost reporting, preset matching against your own deployments, and two routing fixes.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="Your savings, in one tab" src="https://docs.litellm.ai/assets/images/auto-router-v2-hero-df07fbab3e9c36de67cdb1cbff00ba24.png" width="2400" height="1260" class="img_ev3q"></p>
<!-- -->
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a><br><br><p>Already testing it? Share your results in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>.</p></div></div>
<p>Everything below ships in <strong>v1.97.x</strong>.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="see-auto-router-savings--usage-benchmarked-against-a-relevant-model">See Auto-Router savings + usage benchmarked against a relevant model<a href="https://docs.litellm.ai/blog/auto-router-spend-visibility#see-auto-router-savings--usage-benchmarked-against-a-relevant-model" class="hash-link" aria-label="Direct link to See Auto-Router savings + usage benchmarked against a relevant model" title="Direct link to See Auto-Router savings + usage benchmarked against a relevant model">​</a></h2>
<p>The most common question from teams piloting the Auto-Router is "how much is this actually saving me". There is now a tab that answers it.</p>
<p>Cost Optimization has a new <strong>Auto-Router Usage</strong> tab. It covers the last 24 hours, 7 days, or 30 days, for a single router or all routers combined, and shows:</p>
<ul>
<li><strong>Total estimated savings:</strong> in $ and %, with your actual routed spend next to what the same traffic would have cost if every request went to the most expensive model in the router. It prices the router against the "just always use the best model" setup it replaces, and the estimate accounts for caching in both directions</li>
<li><strong>Usage:</strong> total sessions and turns on the Auto-Router, plus per-session averages for spend, turns, duration, and tokens</li>
<li><strong>Prompt caching:</strong> the overall cache hit rate, broken down by what the router did on each turn (stayed on the same model, first visit to a tier, or returned to a tier used earlier), so you can tell whether a longer cache TTL or a background cache warmer would pay for itself</li>
</ul>
<p>The numbers come from a new per-session rollup table so the tab stays fast at scale; in our load tests, a 30-day window over 400k sessions reads in 38 ms.</p>
<p><img decoding="async" loading="lazy" alt="The Auto-Router Usage tab in Cost Optimization" src="https://docs.litellm.ai/assets/images/auto-router-usage-tab-983d5e3ebc66cc60dd2870cd1620a8a2.png" width="2176" height="1934" class="img_ev3q"></p>
<p>Next up: benchmarking the Auto-Router quality and # of turns against equivalent usage for your org.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="per-request-logging-of-the-llm-classifier-cost">Per-request logging of the LLM classifier cost<a href="https://docs.litellm.ai/blog/auto-router-spend-visibility#per-request-logging-of-the-llm-classifier-cost" class="hash-link" aria-label="Direct link to Per-request logging of the LLM classifier cost" title="Direct link to Per-request logging of the LLM classifier cost">​</a></h2>
<p>When the complexity router uses an LLM classifier, that classifier call is billed, but until now it was invisible on the request that triggered it. You can now quantify routing overhead per request.</p>
<ul>
<li>The classifier call's cost is recorded on the <code>routing_decision</code> record as <code>classifier_cost</code>, so it reaches spend-log metadata and every <code>StandardLoggingPayload</code> consumer (Langfuse, OTel, S3, and the rest)</li>
<li>A new <code>x-litellm-classifier-cost</code> response header reports it per request on <code>/v1/chat/completions</code>, <code>/v1/messages</code> and <code>/v1/responses</code>, streaming included</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="presets-now-match-your-actual-deployments">Presets now match your actual deployments<a href="https://docs.litellm.ai/blog/auto-router-spend-visibility#presets-now-match-your-actual-deployments" class="hash-link" aria-label="Direct link to Presets now match your actual deployments" title="Direct link to Presets now match your actual deployments">​</a></h2>
<p>The 1-click Anthropic and OpenAI presets no longer depend on your deployment names lining up with what the preset expects.</p>
<ul>
<li>Presets now resolve against your deployment's underlying provider model ID (<code>litellm_params.model</code>, plus <code>model_info.base_model</code> where set) instead of a direct string match on the name</li>
<li>Presets that resolve this way show a "Matches your deployments" hint, sort ahead of unavailable ones, and keep the config open so you see what got mapped</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="long-prompts-no-longer-fail-at-the-routing-step">Long prompts no longer fail at the routing step<a href="https://docs.litellm.ai/blog/auto-router-spend-visibility#long-prompts-no-longer-fail-at-the-routing-step" class="hash-link" aria-label="Direct link to Long prompts no longer fail at the routing step" title="Direct link to Long prompts no longer fail at the routing step">​</a></h2>
<p>Previously, when using semantic routing long prompts could fail due to an embedding-model's short context window.</p>
<ul>
<li>The prompt is now truncated before embedding, at 2000 characters by default, tunable per deployment with <code>auto_router_max_input_chars</code>.</li>
<li>The truncation applies to the routing step only; guardrails and filters still see the whole prompt</li>
<li>Every no-match and route-failure path now resolves to <code>default_model</code> instead of erroring</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="keyword-based-routing-now-supports-chinese-japanese-and-korean-characters">Keyword-based routing now supports Chinese, Japanese and Korean characters<a href="https://docs.litellm.ai/blog/auto-router-spend-visibility#keyword-based-routing-now-supports-chinese-japanese-and-korean-characters" class="hash-link" aria-label="Direct link to Keyword-based routing now supports Chinese, Japanese and Korean characters" title="Direct link to Keyword-based routing now supports Chinese, Japanese and Korean characters">​</a></h2>
<p><code>keyword_tier_rules</code> matched on regex word boundaries, which do not exist between CJK characters, so a rule on <code>发票</code> never fired inside <code>我需要开发票</code>. That traffic silently fell through to complexity scoring.</p>
<ul>
<li>Keywords containing CJK characters now match as substrings</li>
<li>Latin keywords keep word-boundary matching unchanged</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="try-it">Try it<a href="https://docs.litellm.ai/blog/auto-router-spend-visibility#try-it" class="hash-link" aria-label="Direct link to Try it" title="Direct link to Try it">​</a></h2>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>info</div><div class="admonitionContent_BuS1"><p>Open Cost Optimization in the dashboard and pick the Auto-Router Usage tab. Questions and results in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>, or <a href="https://calendar.app.google/i2e7qVEJphHi5S8UA" target="_blank" rel="noopener noreferrer">apply to be a design partner</a> to work on the Auto-Router with us directly.</p></div></div>
<p>Full reference on the <a href="https://docs.litellm.ai/docs/proxy/auto_routing">Auto Routing docs page</a>.</p>]]></content:encoded>
            <category>routing</category>
            <category>complexity-router</category>
            <category>cost-optimization</category>
            <category>ui</category>
            <category>engineering</category>
        </item>
        <item>
            <title><![CDATA[AutoRouter: 1 Click Deploy]]></title>
            <link>https://docs.litellm.ai/blog/auto-router-setup-and-testing</link>
            <guid>https://docs.litellm.ai/blog/auto-router-setup-and-testing</guid>
            <pubDate>Wed, 05 Aug 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[Six changes to the Auto-Router: 1-click Anthropic and OpenAI presets, a one-line agent setup skill, Test Routing in the UI, a replaceable classifier prompt, customizable tiers, and configurable reminder markers.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="LiteLLM Autorouter V2: always use the latest models" src="https://docs.litellm.ai/assets/images/hero-5b0c02502e1bcdd7fc7aa7eccdf60370.png" width="1200" height="630" class="img_ev3q"></p>
<p>We've made it easier than ever to setup and test your Auto-Router, and with customizable tier names + classifier system prompts you can go beyond complexity routing.</p>
<!-- -->
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>Availability</div><div class="admonitionContent_BuS1"><p>Everything below ships in <strong>v1.97.x</strong>.</p></div></div>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a><br><br><p>Already testing it? Share your results in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="1-click-presets-for-anthropic-and-openai-families">1-Click Presets for Anthropic and OpenAI Families<a href="https://docs.litellm.ai/blog/auto-router-setup-and-testing#1-click-presets-for-anthropic-and-openai-families" class="hash-link" aria-label="Direct link to 1-Click Presets for Anthropic and OpenAI Families" title="Direct link to 1-Click Presets for Anthropic and OpenAI Families">​</a></h2>
<p><img decoding="async" loading="lazy" alt="Add Auto Router form with the Anthropic Family template applied and the detailed configuration collapsed to a tier summary" src="https://docs.litellm.ai/assets/images/presets-0af17ba42e45c336d7872000165bf936.png" width="714" height="408" class="img_ev3q"></p>
<ul>
<li>Add Auto Router now opens on a name field and a <strong>Template</strong> dropdown: Anthropic family, OpenAI family, or Custom</li>
<li>Picking a family builds the whole config for you with the <strong>latest models</strong> in that family, so every tier is on current models without writing any YAML</li>
<li>The detail collapses behind a one-line tier summary; presets that reference a model your proxy doesn't serve grey out and tell you which one is missing</li>
<li>More families are coming; today Anthropic and OpenAI are covered, and Custom is there for everything else</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="let-your-agent-set-up-the-router">Let your agent set up the router<a href="https://docs.litellm.ai/blog/auto-router-setup-and-testing#let-your-agent-set-up-the-router" class="hash-link" aria-label="Direct link to Let your agent set up the router" title="Direct link to Let your agent set up the router">​</a></h2>
<p>Paste this into Claude Code, Codex, Cursor, or any agent with shell access:</p>
<div class="language-text codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-text codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">run curl -fsSL https://docs.litellm.ai/skills/auto-router and follow the instructions</span><br></span></code></pre></div></div>
<ul>
<li>It reads the models your proxy already serves, then interviews you for the router name and the model behind each tier</li>
<li>It writes the config for you, whether your proxy is file-based or DB-managed</li>
<li>Before finishing it lists the defaults it left in place, with what changing each one buys, and asks whether you want any changed</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="test-routing-in-the-ui-during-setup">Test Routing in the UI during setup<a href="https://docs.litellm.ai/blog/auto-router-setup-and-testing#test-routing-in-the-ui-during-setup" class="hash-link" aria-label="Direct link to Test Routing in the UI during setup" title="Direct link to Test Routing in the UI during setup">​</a></h2>
<ul>
<li><strong>Test Routing</strong> now sits beside Test Connection on the Add Auto Router form</li>
<li>Send a prompt, see the tier it lands in and why, against the config currently on screen</li>
<li>Nothing is created and nothing is sent to the routed model, so it costs nothing beyond your LLM classifier (if enabled)</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="replace-the-classifiers-system-prompt">Replace the classifier's system prompt<a href="https://docs.litellm.ai/blog/auto-router-setup-and-testing#replace-the-classifiers-system-prompt" class="hash-link" aria-label="Direct link to Replace the classifier's system prompt" title="Direct link to Replace the classifier's system prompt">​</a></h2>
<p>The LLM classifier shipped with one built-in rubric, so the router could only grade complexity. <code>classifier_llm_config.system_prompt</code> now allows you to define your own routing criteria, whether you want a more in-depth prompt for complexity or routing based on another criterion such as data sensitivity or model capability (vision, audio, image).</p>
<ul>
<li><code>classifier_fallback</code> decides what happens when classification fails: the heuristic scorer, or straight to <code>default_model</code></li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="customize-your-tiers">Customize your tiers<a href="https://docs.litellm.ai/blog/auto-router-setup-and-testing#customize-your-tiers" class="hash-link" aria-label="Direct link to Customize your tiers" title="Direct link to Customize your tiers">​</a></h2>
<p>Along with the above change, you can now change the tier names from the default: SIMPLE / MEDIUM / COMPLEX / REASONING. If your team prefers Fast / Standard / Premium / Deep or Image / Video / Audio / Text, an optional <code>tier_labels</code> map renames them.</p>
<ul>
<li>Names change in the dashboard, the spend logs, and the LLM classifier's rubric, so the classifier reasons in your vocabulary</li>
<li>Display-only. Config keys stay canonical, routing behavior doesn't move, and API callers never see these names</li>
<li>Partial maps are fine; unlisted tiers keep the default name</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="configurable-reminder-markers-easy-openclaw-integration">Configurable reminder markers, easy OpenClaw integration<a href="https://docs.litellm.ai/blog/auto-router-setup-and-testing#configurable-reminder-markers-easy-openclaw-integration" class="hash-link" aria-label="Direct link to Configurable reminder markers, easy OpenClaw integration" title="Direct link to Configurable reminder markers, easy OpenClaw integration">​</a></h2>
<p>The router strips harness-injected context before classifying, so a token-budget note doesn't get graded as the user's actual question. That marker pair was hardcoded to <code>&lt;system-reminder&gt;</code>; a new <code>reminder_markers</code> field lets harnesses like OpenClaw use their own markers.</p>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token key atrule">reminder_markers</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"&lt;&lt;&lt;begin_ctx&gt;&gt;&gt;"</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token string" style="color:rgb(163, 21, 21)">"&lt;&lt;&lt;end_ctx&gt;&gt;&gt;"</span><br></span></code></pre></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="try-it">Try it<a href="https://docs.litellm.ai/blog/auto-router-setup-and-testing#try-it" class="hash-link" aria-label="Direct link to Try it" title="Direct link to Try it">​</a></h2>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>info</div><div class="admonitionContent_BuS1"><p>Start with the one-line agent command, or open Add Model → Auto Router in the dashboard and pick a family preset. Questions and results in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>, or <a href="https://calendar.app.google/i2e7qVEJphHi5S8UA" target="_blank" rel="noopener noreferrer">apply to be a design partner</a> to work on this with us directly.</p></div></div>
<p>Full reference on the <a href="https://docs.litellm.ai/docs/proxy/auto_routing">Auto Routing docs page</a>.</p>]]></content:encoded>
            <category>routing</category>
            <category>complexity-router</category>
            <category>ui</category>
            <category>engineering</category>
        </item>
        <item>
            <title><![CDATA[Auto Router v1.97: usage benchmarks and better quality for lower cost]]></title>
            <link>https://docs.litellm.ai/blog/auto-router-context-and-benchmarks</link>
            <guid>https://docs.litellm.ai/blog/auto-router-context-and-benchmarks</guid>
            <pubDate>Tue, 04 Aug 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[v1.97 adds cost and usage benchmarks for the auto router, gives the LLM classifier a window of prior turns, and turns session affinity off by default. Across 5,600 live classifier calls, prior turns raised tier agreement on referential follow-ups from 14% to 78% at under a tenth of a cent per request, with no measurable latency change.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="LiteLLM Autorouter V2: routing accuracy on complex scenarios, 5.6x more accurate by reading the last N turns of the conversation before picking a model" src="https://docs.litellm.ai/assets/images/autorouter-v2-hero-540bd44400e62fda0fffb63cb41bc631.png" width="2400" height="1254" class="img_ev3q"></p>
<br>
<br>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a><br><br><p>Already testing it? Share your results in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>.</p></div></div>
<p>v1.97 makes three changes to the auto router.</p>
<ul>
<li>The LLM classifier now receives a window of prior conversation turns, defaulting to three. This improves accuracy of follow-up classifications from 14% to 78%, costs at most $0.61 per 1,000 requests, and no additional latency.</li>
<li>A new Benchmarks view prices routed traffic against an all-frontier baseline and reports the difference, and those savings now also appear in the Cost Optimization totals.</li>
<li>Session affinity is now off by default, following our <a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark">previous post</a> showing this was leading to worse quality without cost improvements.</li>
</ul>
<div class="theme-admonition theme-admonition-warning admonition_xJq3 alert alert--warning"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 16 16"><path fill-rule="evenodd" d="M8.893 1.5c-.183-.31-.52-.5-.887-.5s-.703.19-.886.5L.138 13.499a.98.98 0 0 0 0 1.001c.193.31.53.501.886.501h13.964c.367 0 .704-.19.877-.5a1.03 1.03 0 0 0 .01-1.002L8.893 1.5zm.133 11.497H6.987v-2.003h2.039v2.003zm0-3.004H6.987V5.987h2.039v4.006z"></path></svg></span>Two defaults changed</div><div class="admonitionContent_BuS1"><p><code>classifier_context_window_size</code> now defaults to <code>3</code> (LLM classifier only), and <code>session_affinity</code> now defaults to <code>false</code> (all routers). Config files are not modified, but the new defaults apply to any key left unset, so a config that never mentioned <code>session_affinity</code> will reclassify every turn after upgrading. Configs that set either key explicitly are unaffected.</p></div></div>
<!-- -->
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="cost-and-usage-benchmarks">Cost and usage benchmarks<a href="https://docs.litellm.ai/blog/auto-router-context-and-benchmarks#cost-and-usage-benchmarks" class="hash-link" aria-label="Direct link to Cost and usage benchmarks" title="Direct link to Cost and usage benchmarks">​</a></h2>
<p>The Benchmarks view shows your savings using your router against a fixed model (Opus, for example) on your actual usage.</p>
<p><img decoding="async" loading="lazy" alt="Auto-Router Benchmarks tab showing total estimated savings against an all-frontier baseline, session counts, and prompt cache behaviour by bucket" src="https://docs.litellm.ai/assets/images/benchmarks-overview-50ed479481128ffa71a2873e359bf524.png" width="1505" height="1014" class="img_ev3q"></p>
<p>Per router and per time range, it prices routed traffic against the same traffic sent to one frontier model at list prices and reports the difference in dollars and percent, alongside: sessions on the router, turns per session, tokens per session, and savings per session. The baseline is priced with a warm single-model cache rather than a cold one.</p>
<p>The view also estimates the value of a background cache warmer on your traffic, netting rescued cache writes against the cost of the replays. The Benchmarks numbers are queryable directly:</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">GET /auto_router/benchmarks?start_date=2026-07-01&amp;end_date=2026-07-31</span><br></span></code></pre></div></div>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="savings-roll-up-into-cost-optimization">Savings roll up into Cost Optimization<a href="https://docs.litellm.ai/blog/auto-router-context-and-benchmarks#savings-roll-up-into-cost-optimization" class="hash-link" aria-label="Direct link to Savings roll up into Cost Optimization" title="Direct link to Savings roll up into Cost Optimization">​</a></h3>
<p>Router savings now feed into the Cost Optimization section alongside prompt compression and prompt caching, with their own card, savings line, and slice of the by-driver breakdown.</p>
<p><img decoding="async" loading="lazy" alt="Cost Optimization usage tab showing total saved split across compression, prompt caching, and auto-router savings" src="https://docs.litellm.ai/assets/images/cost-optimization-acd9a53165c7c5d7ad9bcd487b4e53ce.png" width="4688" height="3064" class="img_ev3q"></p>
<p>The two views answer different questions and their savings figures will not match. Benchmarks prices traffic against one frontier model end to end; the Cost Optimization card counts the difference between the tier the router picked and the priciest tier it could have picked.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="the-llm-classifier-can-see-prior-turns">The LLM classifier can see prior turns<a href="https://docs.litellm.ai/blog/auto-router-context-and-benchmarks#the-llm-classifier-can-see-prior-turns" class="hash-link" aria-label="Direct link to The LLM classifier can see prior turns" title="Direct link to The LLM classifier can see prior turns">​</a></h2>
<div class="theme-admonition theme-admonition-note admonition_xJq3 alert alert--secondary"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"></path></svg></span>note</div><div class="admonitionContent_BuS1"><p>Everything in this section requires <code>classifier_type: llm</code>. The heuristic scorer does not call a model and has nowhere to put the context, so it is unchanged; the three fields below are read only on the LLM path.</p></div></div>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="the-problem">The problem<a href="https://docs.litellm.ai/blog/auto-router-context-and-benchmarks#the-problem" class="hash-link" aria-label="Direct link to The problem" title="Direct link to The problem">​</a></h3>
<p>The LLM classifier previously only saw the current turn, which does not work well for multi-turn queries:</p>
<ul>
<li>Turn 1: "Make a plan to redesign this component"</li>
<li>Turn 2: "Yes, go ahead"</li>
</ul>
<p>Turn 2 may be classified as simple while the work it authorises is substantial.</p>
<p>Three new fields on <code>complexity_router_config</code> address this:</p>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> auto_router/complexity_router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_type</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> llm</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_llm_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5.4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">mini</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_context_window_size</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(9, 134, 88)">3</span><span class="token plain">                  </span><span class="token comment" style="color:rgb(0, 128, 0)"># default 3; 0 = old behavior</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_context_per_turn_chars</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(9, 134, 88)">200</span><span class="token plain">             </span><span class="token comment" style="color:rgb(0, 128, 0)"># default 200</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_context_include_assistant_turns</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token boolean important">false</span><span class="token plain">  </span><span class="token comment" style="color:rgb(0, 128, 0)"># default false</span><br></span></code></pre></div></div>
<p>Prior turns are inserted oldest-first, numbered <code>[1]</code>, <code>[2]</code>, <code>[3]</code>, each clipped to <code>classifier_context_per_turn_chars</code> with a trailing ellipsis marking the cut.</p>
<p>Turns without human-written text do not consume a slot. Tool output is excluded, <code>&lt;system-reminder&gt;</code> blocks are stripped, turns left empty after stripping are skipped, and a turn identical to the ask being classified is dropped.</p>
<p>With <code>classifier_context_include_assistant_turns</code> enabled, assistant messages join the window with role labels, and that text reaches the classifier payload only; keyword rules, escalation, the heuristic scorer, and semantic matching continue to read the human message alone.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="what-we-measured">What we measured<a href="https://docs.litellm.ai/blog/auto-router-context-and-benchmarks#what-we-measured" class="hash-link" aria-label="Direct link to What we measured" title="Direct link to What we measured">​</a></h3>
<p>5,600 live classifier calls against real providers: two sweeps of seven configurations each (<code>classifier_context_window_size</code> of 0, 1, 2, 3, 5, 8, 10), one with assistant turns in the window and one without, across three multi-turn datasets, with two repeats per conversation. Everything else was identical between configurations, including the conversations, the rubric, the classifier model (<code>gpt-5.4-mini</code>), and the per-turn cap.</p>
<p><strong>Quality.</strong> Agreement between the tier the router picked and the reference tier:</p>
<table><thead><tr><th>Window</th><th>Short-reply follow-ups</th><th>MT-Bench 2nd turns</th><th>ShareGPT multi-turn</th></tr></thead><tbody><tr><td>0</td><td>50.0%</td><td>49.4%</td><td>83.8%</td></tr><tr><td>1</td><td>71.2%</td><td>53.1%</td><td>84.4%</td></tr><tr><td>2</td><td>87.5%</td><td>53.1%</td><td>90.6%</td></tr><tr><td><strong>3</strong> <em>(default)</em></td><td><strong>85.0%</strong></td><td><strong>55.0%</strong></td><td><strong>91.9%</strong></td></tr><tr><td>5</td><td>86.2%</td><td>53.8%</td><td>91.9%</td></tr><tr><td>8</td><td>87.5%</td><td>55.6%</td><td>91.2%</td></tr><tr><td>10</td><td>90.0%</td><td>55.6%</td><td>88.8%</td></tr></tbody></table>
<p>The largest effect is on the 36 follow-ups whose final turn only resolves against the history. Agreement there is <strong>14% at N=0, 47% at N=1, and 78% at N=2</strong>, and flat from there out to N=10. Self-describing controls in the same set sit at 80% with no window and 91 to 95% with one, so the window is not raising every number uniformly.</p>
<p>N=1 recovers less than half the gap. One prior turn tells the classifier that a conversation exists without establishing its subject, and roughly a third of referential cases remain misrouted at that setting.</p>
<p>MT-Bench's ceiling reflects its reference labels rather than router behaviour. Its category-to-tier mapping assigns MEDIUM to every "writing" second turn, so that column is usable as a trend and not as an accuracy score.</p>
<p><img decoding="async" loading="lazy" alt="Agreement against window size across three datasets" src="https://docs.litellm.ai/assets/images/agreement-vs-window-ba57aca31e3c9e8f5c8c7622d64d6ddb.png" width="1360" height="748" class="img_ev3q"></p>
<p><strong>Latency.</strong> Paired per conversation against N=0, every 95% bootstrap CI contains <strong>zero</strong> in both sweeps:</p>
<table><thead><tr><th>Window</th><th>Assistant turns on</th><th>Assistant turns off</th></tr></thead><tbody><tr><td>1</td><td>+21.5 ms [-19.6, +63.9]</td><td>-17.8 ms [-68.9, +29.6]</td></tr><tr><td>2</td><td>+10.5 ms [-31.2, +55.2]</td><td>-14.3 ms [-67.2, +34.4]</td></tr><tr><td>3</td><td>+6.2 ms [-30.0, +43.0]</td><td>-10.8 ms [-61.1, +37.1]</td></tr><tr><td>5</td><td>+6.0 ms [-37.5, +52.6]</td><td>+11.7 ms [-40.6, +61.9]</td></tr><tr><td>8</td><td>-10.5 ms [-45.0, +23.9]</td><td>+10.2 ms [-43.6, +63.9]</td></tr><tr><td>10</td><td>+9.0 ms [-25.9, +43.1]</td><td>-15.3 ms [-65.6, +30.0]</td></tr></tbody></table>
<p>Prompt tokens and latency correlate at r = 0.007 with assistant turns on and r = 0.018 with them off, across a 318 to 1,043 token range. The window adds prefill only; output remains a small fixed structured tier. p50 sits near 600 ms in every configuration.</p>
<p><strong>Cost.</strong> The classifier costs at most $0.61 per 1,000 requests:</p>
<table><thead><tr><th>Window</th><th>Classifier $/1k req (follow-ups / MT-Bench / ShareGPT)</th><th>Modelled routed $/1k req</th></tr></thead><tbody><tr><td>0</td><td>$0.31 / $0.32 / $0.34</td><td>$2.87 / $5.41 / $5.48</td></tr><tr><td>2</td><td>$0.38 / $0.42 / $0.44</td><td>$6.79 / $4.65 / $5.31</td></tr><tr><td>3</td><td>$0.38 / $0.42 / $0.47</td><td>$6.49 / $5.13 / $5.14</td></tr><tr><td>10</td><td>$0.38 / $0.42 / $0.61</td><td>$6.42 / $4.87 / $5.22</td></tr></tbody></table>
<p>Tier selection dominates the cost effect, and it moves in both directions depending on the traffic.</p>
<p>On the short-reply set, routed cost rises from $2.87 to about $6.50 per 1k. At N=0 those requests went to the cheap tier while authorising substantial work, with a tier mix of 66% SIMPLE at N=0 against 30% at N=2, so the increase reflects requests being priced at the tier they required. On MT-Bench and ShareGPT routed cost drifts down instead, as context resolves ambiguous follow-ups to MEDIUM rather than REASONING.</p>
<p>Which direction applies to a given deployment depends on its traffic, which is what the Benchmarks view is for: compare routed spend against the baseline after a day of traffic.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="what-to-run">What to run<a href="https://docs.litellm.ai/blog/auto-router-context-and-benchmarks#what-to-run" class="hash-link" aria-label="Direct link to What to run" title="Direct link to What to run">​</a></h3>
<p>The default of 3 sits past the point where every curve flattens, and additional classifier tokens beyond it produce no measurable gain. The tables above come from the assistant-turns-on sweep; the user-only sweep, which is the default, plateaus one slot earlier because an assistant turn otherwise consumes a slot, so 3 is sufficient in both modes.</p>
<p><code>classifier_context_include_assistant_turns</code> ships off because enabling it shifts tier decisions, and therefore spend, on routers already in production.</p>
<p><code>classifier_context_per_turn_chars</code> is best left at 200. The plateau arrives well before the cap takes effect, and the truncation marker is sufficient signal that a turn was cut.</p>
<details class="details_lb9f alert alert--info details_b_Ee" data-collapsed="true"><summary>Caveats</summary><div><div class="collapsibleContent_i85q"><p>Reference tiers are judgement calls. The hand labels and the ShareGPT judge pass both encode the rule that a short reply inherits the difficulty of the work it approves, which is the behaviour the window produces, making the follow-up set both the sharpest instrument here and the most favourable one.</p><p>Routed completion cost is modelled rather than billed: the chosen tier's price applied to the conversation's prompt tokens plus 600 output tokens. No tier model was called, which isolates the effect of the tier choice from the effect of any particular answer.</p><p>One classifier model was swept. A reasoning-heavier model carries more absolute latency, though the marginal cost of roughly 200 extra prefill tokens should remain negligible.</p><p>Latency was measured on a single VM at concurrency 10. The paired differences carry the finding; the absolute numbers reflect that setup.</p></div></div></details>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="session-affinity-now-off-by-default">Session affinity now off by default<a href="https://docs.litellm.ai/blog/auto-router-context-and-benchmarks#session-affinity-now-off-by-default" class="hash-link" aria-label="Direct link to Session affinity now off by default" title="Direct link to Session affinity now off by default">​</a></h2>
<p>Session affinity pins a session to the model that handled its first turn and skips reclassification thereafter, with the goal of keeping provider prompt caches warm. Two things motivated the change of default.</p>
<p>Our <a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark">prompt caching benchmark</a> examined 4,684 switch-backs and found 97.4% still warm at the 5-minute TTL and 99.3% at an hour. Provider caches survive routing changes well enough that pinning was trading routing quality for cache hits that would have occurred anyway.</p>
<p>Additionally, pinning served in part as a substitute for a classifier without access to conversation history, which is no longer needed.</p>
<p>Configs that do not mention <code>session_affinity</code> will classify every turn after upgrading. To retain the previous behaviour, for strict per-session model consistency or for prefixes long enough that a miss is expensive, set it explicitly:</p>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">session_affinity</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token boolean important">true</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">session_affinity_ttl_seconds</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(9, 134, 88)">3600</span><br></span></code></pre></div></div>
<p>Affinity requires a resolvable <code>session_id</code> in metadata and is ignored when <code>plugins</code> are set.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="try-it">Try it<a href="https://docs.litellm.ai/blog/auto-router-context-and-benchmarks#try-it" class="hash-link" aria-label="Direct link to Try it" title="Direct link to Try it">​</a></h2>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5.4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">nano</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> openai/gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5.4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">nano</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5.4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">mini</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> openai/gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5.4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">mini</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5.5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token punctuation" style="color:rgb(4, 81, 165)">{</span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> openai/gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5.5</span><span class="token punctuation" style="color:rgb(4, 81, 165)">}</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> smart</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> auto_router/complexity_router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_default_model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_type</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> llm</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_llm_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5.4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">mini</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">timeout_ms</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(9, 134, 88)">2000</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_context_window_size</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(9, 134, 88)">3</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_context_per_turn_chars</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> </span><span class="token number" style="color:rgb(9, 134, 88)">200</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">tiers</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">SIMPLE</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5.4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">nano</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">MEDIUM</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">5.4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">mini</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">COMPLEX</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">REASONING</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> gpt</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5.5</span><br></span></code></pre></div></div>
<p>Every response carries <code>x-litellm-model-name</code> and <code>x-litellm-response-cost</code>, so the tier for a given request can be checked before relying on any aggregate. After a day of production traffic, the routed-versus-baseline figure in Benchmarks describes a specific workload more accurately than any of the datasets used here.</p>
<p>Full docs: <a href="https://docs.litellm.ai/docs/proxy/auto_routing" target="_blank" rel="noopener noreferrer">Auto Routing</a>.</p>]]></content:encoded>
            <category>routing</category>
            <category>complexity-router</category>
            <category>cost</category>
            <category>benchmarks</category>
            <category>observability</category>
            <category>product</category>
        </item>
        <item>
            <title><![CDATA[Prompt Caching Works with Auto Router]]></title>
            <link>https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark</link>
            <guid>https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark</guid>
            <pubDate>Fri, 31 Jul 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[The most common objection to auto-routing is that switching models throws away your prompt cache. We measured it across five datasets, including real gateway traffic with the provider's own cache accounting, and the answer is no.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="Auto-Router x Prompt Caching: measured across five datasets" src="https://docs.litellm.ai/assets/images/hero-71dfbc8e920f13551e2f05f2916245de.png" width="3200" height="1676" class="img_ev3q"></p>
<p><strong>Yes, you can use prompt caching with Auto-Routing.</strong> The two compound rather than cancel out. We measured it across five datasets, two of which report what the provider's cache actually did.</p>
<!-- -->
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a><br><br><p>Already testing it? Share your results in <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="the-results">The results<a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark#the-results" class="hash-link" aria-label="Direct link to The results" title="Direct link to The results">​</a></h2>
<ul>
<li><strong>Auto-routing does not break prompt caching.</strong> The two compound on every dataset we measured</li>
<li><strong>37% to 69% cheaper</strong> than caching alone on a single model</li>
<li><strong>The real failure mode is the opposite one.</strong> Running a router with caching switched off is about <strong>4x more expensive</strong> than caching one fixed model</li>
</ul>
<table><thead><tr><th>Evaluation</th><th>Sample</th><th>Router + caching, vs caching alone</th></tr></thead><tbody><tr><td>Simulation, general chat (<a href="https://huggingface.co/datasets/allenai/WildChat-1M" target="_blank" rel="noopener noreferrer">WildChat-1M</a>)</td><td>30,769 multi-turn conversations</td><td><strong>68.7% cheaper</strong></td></tr><tr><td>Simulation, developer chat (<a href="https://github.com/NAIST-SE/DevGPT" target="_blank" rel="noopener noreferrer">DevGPT</a>)</td><td>1,011 conversations</td><td><strong>46% cheaper</strong></td></tr><tr><td>Real agent traces, provider cache accounting</td><td>95 sessions, 8,174 API calls</td><td><strong>37.4% cheaper</strong></td></tr><tr><td><a href="https://github.com/CommonstackAI/TwinRouterBench" target="_blank" rel="noopener noreferrer">TwinRouterBench</a> static track</td><td>81 multi-step instances</td><td><strong>44 to 50% cheaper</strong></td></tr></tbody></table>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="how-it-was-measured">How it was measured<a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark#how-it-was-measured" class="hash-link" aria-label="Direct link to How it was measured" title="Direct link to How it was measured">​</a></h2>
<ul>
<li><strong>Router arm:</strong> one model group, four tiers. SIMPLE to <code>claude-haiku-4-5</code>, MEDIUM to <code>claude-sonnet-5</code>, COMPLEX and REASONING to <code>claude-opus-5</code></li>
<li><strong>Baseline arm:</strong> every request to one frontier model with prompt caching on, the strongest realistic baseline rather than a cold-priced strawman</li>
<li><strong>Cache behaviour:</strong> read from <code>usage.cache_read_input_tokens</code> and <code>cache_creation_input_tokens</code> on the gateway spend logs and agent traces; modelled on the other three legs</li>
<li><strong>Turn classification:</strong> one window function partitioned by session and model, labelling each turn as staying on a model, first visiting a tier, or returning to one already used</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="why-auto-routing-doesnt-break-prompt-caching">Why auto-routing doesn't break prompt caching<a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark#why-auto-routing-doesnt-break-prompt-caching" class="hash-link" aria-label="Direct link to Why auto-routing doesn't break prompt caching" title="Direct link to Why auto-routing doesn't break prompt caching">​</a></h2>
<p><strong>99.3% of the time a session switches back to a model it used earlier, that model's cache is still warm.</strong> The router comes back long before the cache expires, so a switch is not an eviction.</p>
<p>We measured this on <strong>4,684 real switch-backs</strong> from live LiteLLM gateway traffic.</p>
<table><thead><tr><th>Provider cache state</th><th>% of Model Returns with Warm Cache</th></tr></thead><tbody><tr><td>Still warm at 5m TTL</td><td><strong>97.4%</strong></td></tr><tr><td>Still warm at 1h TTL</td><td><strong>99.3%</strong></td></tr><tr><td>Past TTL, the only ones a switch could have hurt</td><td><strong>2.6% / 0.7%</strong></td></tr></tbody></table>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="we-tried-a-background-cache-warmer-it-wasnt-worth-it">We tried a background cache warmer. It wasn't worth it<a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark#we-tried-a-background-cache-warmer-it-wasnt-worth-it" class="hash-link" aria-label="Direct link to We tried a background cache warmer. It wasn't worth it" title="Direct link to We tried a background cache warmer. It wasn't worth it">​</a></h2>
<p>If switching really did strand the cache, a background refresher that replays a session's prefix would be the fix. We built the measurement for it first.</p>
<p><strong>Only 4% of cache misses are preventable by a background cache warmer.</strong> The rest either happened while the cache was still alive, or after the model had been idle so long that keeping it warm costs more than the write it avoids.</p>
<table><thead><tr><th>Traffic</th><th>Typical prefix</th><th>What warming does to total cost</th></tr></thead><tbody><tr><td>General chat</td><td>~1,700 tokens</td><td><strong>0.10% more expensive</strong></td></tr><tr><td>Agent traces, multi-hour gaps</td><td>large</td><td><strong>0.63% more expensive</strong></td></tr><tr><td>Our gateway, agentic</td><td>~190,000 tokens</td><td><strong>0.9% cheaper</strong></td></tr></tbody></table>
<p>Warming is worth roughly plus or minus two percent: a narrow optimization for long sessions with large stable prefixes, not the thing standing between a deployment and its savings.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="see-it-on-your-own-traffic">See it on your own traffic<a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark#see-it-on-your-own-traffic" class="hash-link" aria-label="Direct link to See it on your own traffic" title="Direct link to See it on your own traffic">​</a></h2>
<p>The Auto-Router Benchmarks tab now reports prompt cache behaviour per router, from the provider's own usage payload:</p>
<ul>
<li><strong>Hit rate</strong>, split by whether the turn stayed on a model, first visited a tier, or returned to one</li>
<li><strong>Expired-miss share</strong>, narrowing return misses to those whose tier went idle past the TTL</li>
<li><strong>Savable by warming</strong>, the share of all misses a refresher could prevent</li>
<li><strong>Warming cost and net estimate</strong>, in dollars</li>
<li><strong>Coverage</strong>, so a low hit rate caused by response logging being off does not read as a cold cache</li>
</ul>
<div class="language-text codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-text codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">GET /auto_router/benchmarks?start_date=2026-07-01&amp;end_date=2026-07-31</span><br></span></code></pre></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="try-it">Try it<a href="https://docs.litellm.ai/blog/auto-router-prompt-caching-benchmark#try-it" class="hash-link" aria-label="Direct link to Try it" title="Direct link to Try it">​</a></h2>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>info</div><div class="admonitionContent_BuS1"><p>Point a client at an auto-router with prompt caching on, then check the Auto-Router Benchmarks tab against your own traffic. Share numbers or questions on <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">discussion #32168</a>. To work on this with us directly, <a href="https://calendar.app.google/i2e7qVEJphHi5S8UA" target="_blank" rel="noopener noreferrer">apply to be a design partner</a>.</p></div></div>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockTitle_OeMC">config.yaml</div><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> smart</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> auto_router/complexity_router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">tiers</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">SIMPLE</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">MEDIUM</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">COMPLEX</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">   claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">REASONING</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_type</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> heuristic</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_default_model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><br></span></code></pre></div></div>
<p>Every response carries <code>x-litellm-model-name</code> and <code>x-litellm-response-cost</code>, and the provider's cache token counts land in the spend logs. Full reference on the <a href="https://docs.litellm.ai/docs/proxy/auto_routing">Auto Routing docs page</a>.</p>]]></content:encoded>
            <category>routing</category>
            <category>complexity-router</category>
            <category>caching</category>
            <category>cost</category>
            <category>benchmarks</category>
            <category>engineering</category>
        </item>
        <item>
            <title><![CDATA[Cut 75% Claude Code cost with near frontier model quality]]></title>
            <link>https://docs.litellm.ai/blog/auto-router-cost-quality-benchmark</link>
            <guid>https://docs.litellm.ai/blog/auto-router-cost-quality-benchmark</guid>
            <pubDate>Mon, 27 Jul 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[Two independent evaluations of a four-tier Auto Router config against an all-frontier baseline: 8,619 graded prompts, 14,000 simulated real conversations, and what the cost and quality numbers actually depend on.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="Introducing LiteLLM Autorouter: 75% cost savings with near frontier model quality" src="https://docs.litellm.ai/assets/images/hero-a45559e4634d7d106b05e63327f543c8.png" width="1600" height="838" class="img_ev3q"></p>
<p>Auto routing promises a smaller bill without a worse answer. We measured both halves against a baseline that sends every request to <code>claude-opus-5</code>: 8,619 graded prompts and cost simulations over 14,000 real conversations.</p>
<!-- -->
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>🚀 Help shape the Auto-Router</div><div class="admonitionContent_BuS1"><p>Get early access, work directly with the LiteLLM team, and influence the roadmap with your production traffic.</p><a class="button button--primary button--lg" style="background:#2e8555;border-color:#2e8555;color:#fff" href="https://calendar.app.google/i2e7qVEJphHi5S8UA">Apply to Become a Design Partner</a><br><br><p>Already testing it? Share your results in <a href="https://github.com/BerriAI/litellm/discussions/32172" target="_blank" rel="noopener noreferrer">discussion #32172</a>.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="the-results">The results<a href="https://docs.litellm.ai/blog/auto-router-cost-quality-benchmark#the-results" class="hash-link" aria-label="Direct link to The results" title="Direct link to The results">​</a></h2>
<ul>
<li><strong>40.4% cheaper at 97.1% of frontier quality</strong>, on 220 prompts from six public benchmarks replayed through a live proxy</li>
<li><strong>74.5% cheaper at 87.3% of frontier quality</strong>, on RouterArena's full 8,399-query set</li>
<li><strong>Around 65% cheaper</strong> on simulated real chat and developer traffic, where most requests are short</li>
</ul>
<table><thead><tr><th>Evaluation</th><th>Sample</th><th>Quality retained vs Opus-5</th><th>Cost savings vs Opus-5</th><th>Routing mix (haiku/sonnet/opus)</th></tr></thead><tbody><tr><td>Live proxy, six public benchmarks</td><td>220 prompts</td><td><strong>97.1%</strong> (Auto Router 91.8% pass, Opus-5 94.5%)</td><td><strong>40.4%</strong> (Auto Router $10.47 / 1k, Opus-5 $17.57)</td><td>27% / 70% / 3%</td></tr><tr><td><a href="https://github.com/RouteWorks/RouterArena" target="_blank" rel="noopener noreferrer">RouterArena</a> full set, paired</td><td>8,399 prompts</td><td><strong>87.3%</strong> (Auto Router 68.6% accuracy, Opus-5 78.5%)</td><td><strong>74.5%</strong> (Auto Router $2.15 / 1k, Opus-5 $8.45)</td><td>79% / 17% / 4%</td></tr><tr><td>Simulation, general consumer chat (<a href="https://huggingface.co/datasets/allenai/WildChat-1M" target="_blank" rel="noopener noreferrer">WildChat-1M</a>)</td><td>12,000 conversations</td><td>not measured</td><td><strong>64.9%</strong></td><td>76% / 14% / 10%</td></tr><tr><td>Simulation, developer chat (<a href="https://github.com/NAIST-SE/DevGPT" target="_blank" rel="noopener noreferrer">DevGPT</a>)</td><td>2,056 conversations</td><td>not measured</td><td><strong>65.4%</strong></td><td>48% / 27% / 25%</td></tr><tr><td>Simulation, code-in-prompt heavy (<a href="https://huggingface.co/datasets/allenai/WildChat-1M" target="_blank" rel="noopener noreferrer">WildChat</a> code-filtered)</td><td>993 conversations</td><td>not measured</td><td><strong>20.0%</strong></td><td>13% / 34% / 53%</td></tr></tbody></table>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="how-it-was-measured">How it was measured<a href="https://docs.litellm.ai/blog/auto-router-cost-quality-benchmark#how-it-was-measured" class="hash-link" aria-label="Direct link to How it was measured" title="Direct link to How it was measured">​</a></h2>
<ul>
<li><strong>Router arm:</strong> one model group, four tiers. SIMPLE to <code>claude-haiku-4-5</code>, MEDIUM to <code>claude-sonnet-5</code>, COMPLEX and REASONING both to <code>claude-opus-5</code>, since Opus 5 already thinks by default. Heuristic classifier, no keyword rules, no adaptive sampling</li>
<li><strong>Baseline arm:</strong> the same prompts sent straight to <code>claude-opus-5</code>, which is what most teams do today when they point a workload at one frontier model</li>
<li><strong>Cost savings:</strong> what the router spent against what the baseline spent. On the live proxy, LiteLLM reports the cost of every request back in a response header; on the other legs we price the tokens each request actually used</li>
<li><strong>Quality retained:</strong> the router's pass rate against the baseline's, evaluating identical prompts with the same grader on both arms</li>
</ul>
<p>What counts as a pass:</p>
<table><thead><tr><th>Dataset</th><th>How a pass is decided</th></tr></thead><tbody><tr><td><a href="https://huggingface.co/datasets/openai/openai_humaneval" target="_blank" rel="noopener noreferrer">HumanEval</a>, <a href="https://huggingface.co/datasets/google-research-datasets/mbpp" target="_blank" rel="noopener noreferrer">MBPP</a></td><td>the datasets' own unit tests run in a subprocess; pass only if every official assert passes</td></tr><tr><td><a href="https://huggingface.co/datasets/openai/gsm8k" target="_blank" rel="noopener noreferrer">GSM8K</a>, <a href="https://huggingface.co/datasets/HuggingFaceH4/MATH-500" target="_blank" rel="noopener noreferrer">MATH-500</a>, <a href="https://huggingface.co/datasets/TIGER-Lab/MMLU-Pro" target="_blank" rel="noopener noreferrer">MMLU-Pro</a></td><td>answer-key match: the extracted final number, LaTeX normalisation with a SymPy equivalence fallback, and the final answer letter</td></tr><tr><td><a href="https://huggingface.co/datasets/princeton-nlp/SWE-bench_Lite" target="_blank" rel="noopener noreferrer">SWE-bench Lite</a></td><td>LLM as judge, comparing the named files, functions, and diff sketch against the patch upstream actually merged</td></tr><tr><td><a href="https://github.com/RouteWorks/RouterArena" target="_blank" rel="noopener noreferrer">RouterArena</a></td><td>RouterArena's own evaluator; about 74% of queries are multiple choice matched on a <code>\boxed{X}</code> letter, the rest use per-dataset scorers</td></tr></tbody></table>
<div class="theme-admonition theme-admonition-note admonition_xJq3 alert alert--secondary"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"></path></svg></span>note</div><div class="admonitionContent_BuS1"><p>SWE-bench Lite is the only slice scored by LLM as judge; everything else is checked against the dataset's own answer key or test suite. Every SWE-bench answer was judged twice, by <code>claude-opus-5</code> and by <code>gemini-3.6-flash</code>, and retention holds at 96.6% under the stricter judge.</p></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="where-the-savings-come-from-and-what-they-cost">Where the savings come from, and what they cost<a href="https://docs.litellm.ai/blog/auto-router-cost-quality-benchmark#where-the-savings-come-from-and-what-they-cost" class="hash-link" aria-label="Direct link to Where the savings come from, and what they cost" title="Direct link to Where the savings come from, and what they cost">​</a></h2>
<table><thead><tr><th>Dataset</th><th>Auto Router pass</th><th>Opus-5 pass</th><th>Auto Router $/1k</th><th>Opus-5 $/1k</th><th>Savings</th></tr></thead><tbody><tr><td><a href="https://huggingface.co/datasets/openai/gsm8k" target="_blank" rel="noopener noreferrer">GSM8K</a></td><td>98% (39/40)</td><td>98% (39/40)</td><td>1.08</td><td>5.68</td><td>81%</td></tr><tr><td><a href="https://huggingface.co/datasets/openai/openai_humaneval" target="_blank" rel="noopener noreferrer">HumanEval</a></td><td>100% (40/40)</td><td>98% (39/40)</td><td>2.85</td><td>8.16</td><td>65%</td></tr><tr><td><a href="https://huggingface.co/datasets/TIGER-Lab/MMLU-Pro" target="_blank" rel="noopener noreferrer">MMLU-Pro</a></td><td>85% (34/40)</td><td>88% (35/40)</td><td>4.21</td><td>11.70</td><td>64%</td></tr><tr><td><a href="https://huggingface.co/datasets/HuggingFaceH4/MATH-500" target="_blank" rel="noopener noreferrer">MATH-500</a></td><td>90% (36/40)</td><td>98% (39/40)</td><td>5.70</td><td>13.16</td><td>57%</td></tr><tr><td><a href="https://huggingface.co/datasets/google-research-datasets/mbpp" target="_blank" rel="noopener noreferrer">MBPP</a></td><td>95% (38/40)</td><td>98% (39/40)</td><td>2.20</td><td>5.01</td><td>56%</td></tr><tr><td><a href="https://huggingface.co/datasets/princeton-nlp/SWE-bench_Lite" target="_blank" rel="noopener noreferrer">SWE-bench Lite</a></td><td>75% (15/20)</td><td>85% (17/20)</td><td>83.08</td><td>105.83</td><td>21%</td></tr><tr><td><strong>Blended</strong></td><td><strong>91.8%</strong></td><td><strong>94.5%</strong></td><td><strong>10.47</strong></td><td><strong>17.57</strong></td><td><strong>40%</strong></td></tr></tbody></table>
<p>The split runs opposite to intuition:</p>
<ul>
<li><strong>Short, cheap traffic saves the most at no quality cost.</strong> GSM8K is identical at a fifth of the price, and HumanEval came out one prompt ahead of the frontier baseline</li>
<li><strong>Repo-level work saves the least.</strong> Those prompts are long enough to dominate absolute spend, and the classifier correctly declines to send them to Haiku</li>
<li><strong>Quality is given up in two places.</strong> MATH-500, where Haiku took 19 of the 40 prompts and the arm finished three behind, and SWE-bench Lite</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="auto-routing-and-prompt-caching">Auto-routing and prompt caching<a href="https://docs.litellm.ai/blog/auto-router-cost-quality-benchmark#auto-routing-and-prompt-caching" class="hash-link" aria-label="Direct link to Auto-routing and prompt caching" title="Direct link to Auto-routing and prompt caching">​</a></h2>
<p>A question we keep hearing: do I have to choose between auto-routing and prompt caching?</p>
<p>No. Session affinity already lets you keep a conversation on the model its first turn picked, so the cache holds for the rest of that conversation. What it costs you is the routing decision on every turn after the first: once a session is pinned, a one-line follow-up stays on whatever model the opening turn earned. Closing that gap is the first item below.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="whats-next">What's next<a href="https://docs.litellm.ai/blog/auto-router-cost-quality-benchmark#whats-next" class="hash-link" aria-label="Direct link to What's next" title="Direct link to What's next">​</a></h2>
<ul>
<li><strong>Prompt caching that survives a tier change.</strong> Affinity pins a conversation today because switching models means a cold cache. We are testing a background refresher that keeps the prefix warm on every tier, so a session can move without paying the write cost twice</li>
<li><strong>Routing decisions you can inspect.</strong> Surfacing why a request landed on the tier it did, not just which model served it. That same signal feeds back into the classifier, so it improves against real traffic rather than benchmarks</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="try-it">Try it<a href="https://docs.litellm.ai/blog/auto-router-cost-quality-benchmark#try-it" class="hash-link" aria-label="Direct link to Try it" title="Direct link to Try it">​</a></h2>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>info</div><div class="admonitionContent_BuS1"><p>Try it yourself with the configuration below, and post any feedback, questions, or numbers from your own traffic on <a href="https://github.com/BerriAI/litellm/discussions/32172" target="_blank" rel="noopener noreferrer">discussion #32172</a>. If you want to work on this with us directly, <a href="https://calendar.app.google/i2e7qVEJphHi5S8UA" target="_blank" rel="noopener noreferrer">apply to be a design partner</a>.</p></div></div>
<div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockTitle_OeMC">config.yaml</div><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain">           </span><span class="token comment" style="color:rgb(0, 128, 0)"># $1 / $5 per 1M tokens</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain">            </span><span class="token comment" style="color:rgb(0, 128, 0)"># $3 / $15</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain">              </span><span class="token comment" style="color:rgb(0, 128, 0)"># $5 / $25</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain" style="display:inline-block"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> smart</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> auto_router/complexity_router</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_config</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">tiers</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">SIMPLE</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">haiku</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">4</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">MEDIUM</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">    claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">COMPLEX</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain">   claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">          </span><span class="token key atrule">REASONING</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        </span><span class="token key atrule">classifier_type</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> heuristic         </span><span class="token comment" style="color:rgb(0, 128, 0)"># local scoring, sub-millisecond, no API call</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">complexity_router_default_model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">sonnet</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><br></span></code></pre></div></div>
<p>Point a client at <code>smart-router</code> and every response carries <code>x-litellm-model-name</code> and <code>x-litellm-response-cost</code>, which is all the instrumentation this study needed. Full reference, including the classifier and tier-boundary knobs, on the <a href="https://docs.litellm.ai/docs/proxy/auto_routing">Auto Routing docs page</a>.</p>]]></content:encoded>
            <category>routing</category>
            <category>complexity-router</category>
            <category>cost</category>
            <category>benchmarks</category>
            <category>engineering</category>
        </item>
        <item>
            <title><![CDATA[July Townhall Updates: 38 Security Fixes, 317 Bug Fixes, and Autorouter V2]]></title>
            <link>https://docs.litellm.ai/blog/july-townhall-updates</link>
            <guid>https://docs.litellm.ai/blog/july-townhall-updates</guid>
            <pubDate>Fri, 24 Jul 2026 12:00:00 GMT</pubDate>
            <description><![CDATA[A recap of the July LiteLLM town hall: 38 security fixes, 317 bug fixes, 140 feature commits, new Rust gateway benchmarks, and the launch of Autorouter V2.]]></description>
            <content:encoded><![CDATA[<p>Thank you to everyone who joined our July town hall. We used it to share this month's security and stability work and our latest product updates: <strong>38 security fixes</strong>, <strong>317 bug fixes</strong>, and <strong>140 feature commits</strong>, headlined by new Rust benchmarks and the launch of Autorouter V2.</p>
<!-- -->
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="security">Security<a href="https://docs.litellm.ai/blog/july-townhall-updates#security" class="hash-link" aria-label="Direct link to Security" title="Direct link to Security">​</a></h2>
<p><strong>38 security fixes shipped this month</strong>, including two critical vulnerabilities closed for good. Here is where they landed:</p>
<table><thead><tr><th>Category</th><th>Fixes</th><th>Share</th></tr></thead><tbody><tr><td>Secret / credential exposure prevention</td><td>12</td><td>32%</td></tr><tr><td>Access-control / privilege-escalation</td><td>11</td><td>29%</td></tr><tr><td>Guardrail-bypass</td><td>6</td><td>16%</td></tr><tr><td>SSRF / secret exfiltration</td><td>5</td><td>13%</td></tr><tr><td>CVE / dependency / supply-chain</td><td>4</td><td>11%</td></tr></tbody></table>
<p>We backport security fixes across the last four minor release lines, so staying current is the whole defense. Upgrade to stay covered.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="how-we-review-every-pr">How we review every PR<a href="https://docs.litellm.ai/blog/july-townhall-updates#how-we-review-every-pr" class="hash-link" aria-label="Direct link to How we review every PR" title="Direct link to How we review every PR">​</a></h3>
<p>Every pull request runs a security pass before it can merge, and every release runs a full scan before it ships.</p>
<ul>
<li><strong>Veria scan.</strong> A required check on every PR, built on Veria AI, zizmor, and semgrep. False positives get flagged, never blocking.</li>
<li><strong>Dependency scan.</strong> osv-scanner gates every lockfile change and runs nightly, so a known-CVE dependency can't ship.</li>
<li><strong>Image scan.</strong> Grype checks the runtime image for OS and library CVEs and fails the build on fixable High/Critical findings.</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="we-pay-for-security-reports">We pay for security reports<a href="https://docs.litellm.ai/blog/july-townhall-updates#we-pay-for-security-reports" class="hash-link" aria-label="Direct link to We pay for security reports" title="Direct link to We pay for security reports">​</a></h3>
<p>The bug bounty is live.</p>
<ul>
<li><strong>Scope:</strong> the LiteLLM gateway and SDK.</li>
<li><strong>Submit</strong> through a private vulnerability report on GitHub.</li>
<li><strong>Triaged</strong> by maintainers and the Veria Labs security team.</li>
<li><a href="https://github.com/BerriAI/litellm/security" target="_blank" rel="noopener noreferrer">github.com/BerriAI/litellm/security</a></li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="whats-next-for-security">What's next for security<a href="https://docs.litellm.ai/blog/july-townhall-updates#whats-next-for-security" class="hash-link" aria-label="Direct link to What's next for security" title="Direct link to What's next for security">​</a></h3>
<p>We're expanding the bug bounty program, hardening the recurring code patterns we keep finding through the stability sprint, and hiring to match. This is a structural investment, not a one-month sprint.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="stability">Stability<a href="https://docs.litellm.ai/blog/july-townhall-updates#stability" class="hash-link" aria-label="Direct link to Stability" title="Direct link to Stability">​</a></h2>
<p>We've grown fast, and want to prioritize staying on top of bugs so they don't accumulate. In July we shipped <strong>317 bug fixes</strong>.</p>
<table><thead><tr><th>Area</th><th>Fixes</th></tr></thead><tbody><tr><td>UI + Auth / SSO</td><td>76</td></tr><tr><td>MCP Gateway</td><td>50</td></tr><tr><td>Providers &amp; Model Transforms</td><td>48</td></tr><tr><td>Cost, Budgets &amp; Observability</td><td>44</td></tr><tr><td>Proxy Core &amp; Resilience</td><td>43</td></tr><tr><td>Streaming / Realtime APIs</td><td>36</td></tr><tr><td>Other / SDK</td><td>20</td></tr></tbody></table>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="the-target-95-e2e-coverage-by-end-of-month">The target: 95% E2E coverage by end of month<a href="https://docs.litellm.ai/blog/july-townhall-updates#the-target-95-e2e-coverage-by-end-of-month" class="hash-link" aria-label="Direct link to The target: 95% E2E coverage by end of month" title="Direct link to The target: 95% E2E coverage by end of month">​</a></h3>
<p>We're treating end-to-end testing as a first-class citizen. Every new customer journey now ships with its own E2E test, tracked live on the dashboard. The goal is to cover roughly 97 more customer journeys this month, taking us from 309 to 406 of 427 identified journeys, about 95% coverage.</p>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="what-kinds-of-fixes-shipped">What kinds of fixes shipped<a href="https://docs.litellm.ai/blog/july-townhall-updates#what-kinds-of-fixes-shipped" class="hash-link" aria-label="Direct link to What kinds of fixes shipped" title="Direct link to What kinds of fixes shipped">​</a></h3>
<p>The headline categories were billing, identity, and MCP.</p>
<ul>
<li><strong>Billing accuracy.</strong> We closed the gaps where spend used to slip through. Cached and tiered usage on Anthropic and Bedrock is priced correctly now, budgets reset on the right schedule, and partial spend gets captured when a stream drops mid-request.</li>
<li><strong>Identity and access.</strong> Caller identity now resolves once into a single record, so team IDs and spend attribution stay correct, and auth no longer fails open on DB errors.</li>
<li><strong>MCP reliability.</strong> Tools list and call consistently across every auth method now, with per-user credentials and proper OAuth token refresh.</li>
<li><strong>Resource leaks.</strong> Guardrails no longer re-initialize on every request, which kills the runner leaks, latency spikes, and OOMs they used to cause.</li>
<li><strong>Resilience.</strong> Streaming requests recover cost on interruption, the proxy self-heals on dropped DB connections, and OTEL metrics no longer overload Splunk.</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="watch-our-progress-live">Watch our progress live<a href="https://docs.litellm.ai/blog/july-townhall-updates#watch-our-progress-live" class="hash-link" aria-label="Direct link to Watch our progress live" title="Direct link to Watch our progress live">​</a></h3>
<p>Progress is tracked in public on <a href="https://github.com/BerriAI/litellm/issues/30484" target="_blank" rel="noopener noreferrer">GitHub issue #30484</a>, with the bar set at zero reported regressions by the August 29 release.</p>
<ul>
<li><strong>June.</strong> 13 bugs triaged and the stability sprint opens. Root-cause analysis begins.</li>
<li><strong>July.</strong> MCP improvements complete, with 80+ fixes shipped, and E2E coverage climbing toward the 95% target.</li>
<li><strong>August.</strong> Fireworks, Cloudflare, and Baseten providers join the E2E suite. Load-testing gates get added to stable releases, with progress reported alongside the August 29 release.</li>
</ul>
<p>Find our latest stable release <a href="https://docs.litellm.ai/release_notes/v1.93.0/v1-93-0" target="_blank" rel="noopener noreferrer">here</a>.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="product">Product<a href="https://docs.litellm.ai/blog/july-townhall-updates#product" class="hash-link" aria-label="Direct link to Product" title="Direct link to Product">​</a></h2>
<p>Alongside the security and stability work, we shipped <strong>140 feature commits in July.</strong></p>
<ul>
<li><strong>Rust:</strong> pyo3 0.29, Python 3.14 support, a Mistral OCR bridge, and /v1/messages on Azure.</li>
<li><strong>Tokens and budgets:</strong> Headroom cuts 60-95% of tokens; budget fallbacks reroute at the cap.</li>
<li><strong>New models:</strong> Claude Sonnet 5 on Day 0, Gemini 3.5 Flash, and Muse Spark 1.1.</li>
</ul>
<h3 class="anchor anchorWithStickyNavbar_LWe7" id="performance">Performance<a href="https://docs.litellm.ai/blog/july-townhall-updates#performance" class="hash-link" aria-label="Direct link to Performance" title="Direct link to Performance">​</a></h3>
<p>We've been testing LiteLLM, benchmarked with <a href="https://github.com/BerriAI/ai-gateway-bench" target="_blank" rel="noopener noreferrer">AIGatewayBench</a>. This is gateway overhead against a local deterministic mock, n=5000 per endpoint on one host.</p>
<table><thead><tr><th>Metric</th><th>LiteLLM Rust</th><th>Bifrost</th><th>Portkey</th><th>LiteLLM Python v1</th></tr></thead><tbody><tr><td>Gateway overhead (p99 added latency)</td><td>0.7 ms</td><td>4.5 ms</td><td>2.3 ms</td><td>257.7 ms</td></tr><tr><td>Peak memory footprint</td><td>21.8 MB</td><td>199.1 MB</td><td>90.4 MB</td><td>329.5 MB</td></tr><tr><td>Estimated cost per 1M requests</td><td>$0.000175</td><td>$0.001008</td><td>$0.001042</td><td>$0.015354</td></tr></tbody></table>
<p><em>*Overhead is gateway p99 minus direct-to-mock p99 on the same endpoint. Cost is a footprint estimate from measured CPU and peak RSS at 4 vCPU / 16 GB, and excludes token cost.</em></p>
<p>Beta v0 is live now for testing. It supports /v1/messages for Azure and all /ocr providers today. See the <a href="https://docs.litellm.ai/docs/proxy/rust_gateway" target="_blank" rel="noopener noreferrer">docs</a>. Next up is /v1/messages for Bedrock Invoke, with support for all known Bedrock auth methods: STS, keys, and IAM.</p>
<p>This is a gradual rollout, one route at a time, each proven in production before the next begins. We're targeting full rollout by December 1st. Same config, same database, same API. There's nothing for you to change.</p>
<p><a href="https://docs.litellm.ai/docs/proxy/rust_gateway" target="_blank" rel="noopener noreferrer">Get started.</a></p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="announcing-autorouter-v2">Announcing Autorouter V2<a href="https://docs.litellm.ai/blog/july-townhall-updates#announcing-autorouter-v2" class="hash-link" aria-label="Direct link to Announcing Autorouter V2" title="Direct link to Announcing Autorouter V2">​</a></h2>
<p>Autorouter V2 routes each request to the right model by how hard it is. Four complexity tiers, classified by default with rule-based scoring that needs no training data, no API calls, and under 1 ms of latency.</p>
<ul>
<li><strong>Simple.</strong> "Hello", "What is Python?", "Thanks."</li>
<li><strong>Medium.</strong> "Explain how REST APIs work", "Debug this error."</li>
<li><strong>Complex.</strong> "Design a microservices architecture", "Implement a rate limiter."</li>
<li><strong>Reasoning.</strong> "Think step by step...", "Analyze the pros and cons..."</li>
</ul>
<p>That default is a heuristic scorer weighing seven signals: token count, code presence, reasoning markers, technical terms, simple indicators, multi-step patterns, and question complexity. The combined score sets the tier (Simple &lt; 0.15, Medium 0.15-0.35, Complex 0.35-0.60, Reasoning &gt; 0.60 or 2+ reasoning markers). V2 adds four ways to make that routing smarter:</p>
<ol>
<li><strong>An LLM classifier.</strong> Swap the heuristic for a model call (say anthropic/claude-haiku-4-5, with a configurable timeout) to pick the tier. If the classifier errors, times out, or returns something unparseable, it falls back to the heuristic scorer automatically.</li>
<li><strong>Routing that learns.</strong> An adaptive bandit mode watches how each conversation actually goes: does the user have to rephrase or correct the model, does it get stuck repeating itself or run out of tool calls, does the user seem satisfied. That live feedback shifts future routing toward the models that are actually working. Quality-vs-cost weighting (we recommend 30/70), the eligible model pool, and a tier-distance penalty are all configurable.</li>
<li><strong>Tier escalation.</strong> A configured keyword bumps a request one tier higher when it appears in the user's message. Matching is case-sensitive, so a phrase like LITELLM ESCALATE only fires on the exact, shouted form.</li>
<li><strong>Semantic keyword matching.</strong> Keyword overrides already route requests containing specific terms straight to a tier (for example, "invoice, refund, billing" goes to Medium). Semantic matching extends this with an embedding model and a minimum similarity score, trading a little latency for matches that don't need an exact keyword hit.</li>
</ol>
<p>We shipped Autorouter V2 to get your feedback on it. Try it today:</p>
<ul>
<li><a href="https://docs.litellm.ai/docs/learn/autorouter_cli" target="_blank" rel="noopener noreferrer">Local CLI</a></li>
<li><a href="https://docs.litellm.ai/docs/proxy/auto_routing" target="_blank" rel="noopener noreferrer">On Proxy</a></li>
<li>Tell us what breaks: <a href="https://github.com/BerriAI/litellm/discussions/32168" target="_blank" rel="noopener noreferrer">GitHub Discussion #32168</a>, or #litellm-autorouter on Discord.</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="whats-next">What's next<a href="https://docs.litellm.ai/blog/july-townhall-updates#whats-next" class="hash-link" aria-label="Direct link to What's next" title="Direct link to What's next">​</a></h2>
<p>Thanks again for all the questions and feedback. We'll keep sharing concrete progress as this work ships, especially as we get closer to the August 29 release.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="were-hiring">We're hiring<a href="https://docs.litellm.ai/blog/july-townhall-updates#were-hiring" class="hash-link" aria-label="Direct link to We're hiring" title="Direct link to We're hiring">​</a></h2>
<p>LiteLLM is the open-source gateway thousands of teams use to run every model behind one API, from startups to the Fortune 500. We move fast: 140 features and 300+ fixes shipped this month alone.</p>
<p>We're hiring a Security Engineer for the core gateway. Small team, huge surface area, real ownership from day one. Want in, or know someone great? Reach us at <a href="mailto:recruiting@berri.ai" target="_blank" rel="noopener noreferrer">recruiting@berri.ai</a>.</p>
<p>Thank you for using LiteLLM. <strong>Krrish &amp; Ishaan</strong></p>
<p><strong>Questions? Join the conversation</strong> <a href="https://github.com/BerriAI/litellm/discussions/34595" target="_blank" rel="noopener noreferrer">GitHub Discussion #34595</a></p>]]></content:encoded>
            <category>townhall</category>
            <category>security</category>
            <category>reliability</category>
            <category>product</category>
        </item>
        <item>
            <title><![CDATA[Day 0 Support: Claude Opus 5]]></title>
            <link>https://docs.litellm.ai/blog/claude_opus_5</link>
            <guid>https://docs.litellm.ai/blog/claude_opus_5</guid>
            <pubDate>Fri, 24 Jul 2026 10:00:00 GMT</pubDate>
            <description><![CDATA[Day 0 support for Claude Opus 5 on the LiteLLM AI Gateway. Use it across Anthropic, Azure, Vertex AI, and Bedrock.]]></description>
            <content:encoded><![CDATA[<p><img decoding="async" loading="lazy" alt="LiteLLM x Claude Opus 5" src="https://docs.litellm.ai/assets/images/litellm_claude_opus_5_announcement-1d34c01c812a0646ecc86bd93912c9e4.png" width="4800" height="2508" class="img_ev3q"></p>
<p>LiteLLM now supports <a href="https://www.anthropic.com/news/claude-opus-5" target="_blank" rel="noopener noreferrer">Claude Opus 5</a> on Day 0. Use it across Anthropic, Azure, Vertex AI, and Bedrock through the LiteLLM AI Gateway. Call it with the same OpenAI-compatible request you already use, and track spend, rate limits, and logging in one place.</p>
<!-- -->
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="whats-new-in-opus-5">What's new in Opus 5<a href="https://docs.litellm.ai/blog/claude_opus_5#whats-new-in-opus-5" class="hash-link" aria-label="Direct link to What's new in Opus 5" title="Direct link to What's new in Opus 5">​</a></h2>
<p>Key changes (<a href="https://www.anthropic.com/news/claude-opus-5" target="_blank" rel="noopener noreferrer">details from Anthropic</a>):</p>
<ul>
<li><strong>Much better coding agents:</strong> stronger at large refactors, debugging, multi-file features, and finishing end-to-end work without leaving stubs</li>
<li><strong>Better self-verification:</strong> it checks and iterates on its own work more proactively</li>
<li><strong>Better vision and artifacts:</strong> improved screenshots → website, charts and documents, spreadsheets, and slide decks</li>
<li><strong>Same base API price as Opus 4.8:</strong> $5 / MTok input and $25 / MTok output</li>
<li><strong>Thinking is on by default</strong></li>
<li><strong>Fast mode:</strong> about 2.5x faster, but costs 2x</li>
</ul>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="before-you-switch-from-opus-48">Before you switch from Opus 4.8<a href="https://docs.litellm.ai/blog/claude_opus_5#before-you-switch-from-opus-48" class="hash-link" aria-label="Direct link to Before you switch from Opus 4.8" title="Direct link to Before you switch from Opus 4.8">​</a></h2>
<p>The swap is not free. Priority Tier and web fetch are both gone on Opus 5, so plan that capacity and that tooling separately. Opus 5's cybersecurity classifiers can also decline a request outright with <code>stop_reason: "refusal"</code> and a category in <code>stop_details</code>, which is worth handling explicitly or routing around with LiteLLM <a href="https://docs.litellm.ai/docs/proxy/reliability">fallbacks</a>.</p>
<p>Sampling parameters (<code>temperature</code>, <code>top_p</code>, <code>top_k</code>), fixed thinking budgets, and assistant message prefill remain unsupported, same as Opus 4.8. Anthropic's <a href="https://platform.claude.com/docs/en/about-claude/models/migration-guide" target="_blank" rel="noopener noreferrer">Opus 5 migration guide</a> has the full compatibility checklist.</p>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="enabling-opus-5">Enabling Opus 5<a href="https://docs.litellm.ai/blog/claude_opus_5#enabling-opus-5" class="hash-link" aria-label="Direct link to Enabling Opus 5" title="Direct link to Enabling Opus 5">​</a></h2>
<p>Opus 5 ships in the <strong><code>v1.95.0-dev.3</code></strong> image, cutting later today, but most proxies do not need to upgrade at all. On the default remote cost map, open the <strong>Price Data</strong> tab under <strong>Models + Endpoints</strong> in the UI and click <strong>Reload Price Data</strong> (or <code>POST /reload/model_cost_map</code> as a proxy admin). That refetches pricing and re-registers provider routing in one step, so <code>claude-opus-5</code> becomes available across Anthropic, Azure, Vertex AI, and Bedrock even on an older version.</p>
<p>The exception is <code>LITELLM_LOCAL_MODEL_COST_MAP=true</code>, which bakes the cost map into the image and puts it out of the Reload button's reach. Pull <code>v1.95.0-dev.3</code> or later for the bundled Opus 5 metadata:</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">docker pull ghcr.io/berriai/litellm:v1.95.0-dev.3</span><br></span></code></pre></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="usage">Usage<a href="https://docs.litellm.ai/blog/claude_opus_5#usage" class="hash-link" aria-label="Direct link to Usage" title="Direct link to Usage">​</a></h2>
<p>Pick your provider below. Each tab wires up <code>claude-opus-5</code> for that provider; the request you send afterward is identical everywhere.</p>
<div class="tabs-container tabList__CuJ"><ul role="tablist" aria-orientation="horizontal" class="tabs"><li role="tab" tabindex="0" aria-selected="true" class="tabs__item tabItem_LNqP tabs__item--active">Anthropic</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">Azure</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">Vertex AI</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">Bedrock</li></ul><div class="margin-top--md"><div role="tabpanel" class="tabItem_Ymn6"><p><strong>1. Setup config.yaml</strong></p><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> anthropic/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/ANTHROPIC_API_KEY</span><br></span></code></pre></div></div><p><strong>2. Start the proxy</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">docker run -d \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -p 4000:4000 \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -e ANTHROPIC_API_KEY=$ANTHROPIC_API_KEY \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -v $(pwd)/config.yaml:/app/config.yaml \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  ghcr.io/berriai/litellm:v1.95.0-dev.3 \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  --config /app/config.yaml</span><br></span></code></pre></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><p><strong>1. Setup config.yaml</strong></p><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> azure_ai/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/AZURE_AI_API_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">api_base</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/AZURE_AI_API_BASE  </span><span class="token comment" style="color:rgb(0, 128, 0)"># https://&lt;resource&gt;.services.ai.azure.com</span><br></span></code></pre></div></div><p><strong>2. Start the proxy</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">docker run -d \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -p 4000:4000 \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -e AZURE_AI_API_KEY=$AZURE_AI_API_KEY \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -e AZURE_AI_API_BASE=$AZURE_AI_API_BASE \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -v $(pwd)/config.yaml:/app/config.yaml \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  ghcr.io/berriai/litellm:v1.95.0-dev.3 \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  --config /app/config.yaml</span><br></span></code></pre></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><p><strong>1. Setup config.yaml</strong></p><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> vertex_ai/claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">vertex_project</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/VERTEX_PROJECT</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">vertex_location</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> global</span><br></span></code></pre></div></div><p><strong>2. Start the proxy</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">docker run -d \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -p 4000:4000 \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -e VERTEX_PROJECT=$VERTEX_PROJECT \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -e GOOGLE_APPLICATION_CREDENTIALS=/app/credentials.json \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -v $(pwd)/config.yaml:/app/config.yaml \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -v $(pwd)/credentials.json:/app/credentials.json \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  ghcr.io/berriai/litellm:v1.95.0-dev.3 \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  --config /app/config.yaml</span><br></span></code></pre></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><p><strong>1. Setup config.yaml</strong></p><div class="language-yaml codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-yaml codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token key atrule">model_list</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  </span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain"> </span><span class="token key atrule">model_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    </span><span class="token key atrule">litellm_params</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">model</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> bedrock/anthropic.claude</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">opus</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">5</span><span class="token plain"></span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">aws_access_key_id</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/AWS_ACCESS_KEY_ID</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">aws_secret_access_key</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> os.environ/AWS_SECRET_ACCESS_KEY</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      </span><span class="token key atrule">aws_region_name</span><span class="token punctuation" style="color:rgb(4, 81, 165)">:</span><span class="token plain"> us</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token plain">east</span><span class="token punctuation" style="color:rgb(4, 81, 165)">-</span><span class="token number" style="color:rgb(9, 134, 88)">1</span><br></span></code></pre></div></div><div class="theme-admonition theme-admonition-note admonition_xJq3 alert alert--secondary"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"></path></svg></span>note</div><div class="admonitionContent_BuS1"><p>For cross-region routing, swap the model ID for a regional inference profile (<code>us.</code>, <code>eu.</code>, <code>au.</code>, or <code>jp.</code> prefix), e.g. <code>bedrock/converse/us.anthropic.claude-opus-5</code>. These carry a 10% regional premium; the <code>global.</code> profile stays at base price. LiteLLM tracks the cost of each variant automatically.</p></div></div><p><strong>2. Start the proxy</strong></p><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">docker run -d \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -p 4000:4000 \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -e AWS_ACCESS_KEY_ID=$AWS_ACCESS_KEY_ID \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -e AWS_SECRET_ACCESS_KEY=$AWS_SECRET_ACCESS_KEY \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  -v $(pwd)/config.yaml:/app/config.yaml \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  ghcr.io/berriai/litellm:v1.95.0-dev.3 \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  --config /app/config.yaml</span><br></span></code></pre></div></div></div></div></div>
<p><strong>3. Test it!</strong></p>
<p>The request is the same regardless of which provider you configured above:</p>
<div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">curl --location 'http://0.0.0.0:4000/chat/completions' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--header 'Content-Type: application/json' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--header 'Authorization: Bearer $LITELLM_KEY' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--data '{</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  "model": "claude-opus-5",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  "messages": [</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    {</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      "role": "user",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      "content": "what llm are you"</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    }</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  ]</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">}'</span><br></span></code></pre></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="fast-mode">Fast Mode<a href="https://docs.litellm.ai/blog/claude_opus_5#fast-mode" class="hash-link" aria-label="Direct link to Fast Mode" title="Direct link to Fast Mode">​</a></h2>
<div class="theme-admonition theme-admonition-info admonition_xJq3 alert alert--info"><div class="admonitionHeading_Gvgb"><span class="admonitionIcon_Rf37"><svg viewBox="0 0 14 16"><path fill-rule="evenodd" d="M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"></path></svg></span>info</div><div class="admonitionContent_BuS1"><p>Fast mode is <strong>only supported on the Anthropic provider</strong> (<code>anthropic/claude-opus-5</code>). It is not available on Azure AI, Vertex AI, or Bedrock, and it cannot be combined with the Batch API.</p></div></div>
<p>Opus 5 runs roughly 2.5x faster with <code>speed: "fast"</code>, billed at $10 / MTok input and $50 / MTok output (2x the standard rate, down from the 6x premium on Opus 4.6). LiteLLM adds the <code>fast-mode-2026-02-01</code> beta header and tracks the premium in cost calculations automatically.</p>
<div class="tabs-container tabList__CuJ"><ul role="tablist" aria-orientation="horizontal" class="tabs"><li role="tab" tabindex="0" aria-selected="true" class="tabs__item tabItem_LNqP tabs__item--active">/v1/chat/completions</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">/v1/messages</li><li role="tab" tabindex="-1" aria-selected="false" class="tabs__item tabItem_LNqP">/v1/responses</li></ul><div class="margin-top--md"><div role="tabpanel" class="tabItem_Ymn6"><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">curl --location 'http://0.0.0.0:4000/v1/chat/completions' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--header 'Content-Type: application/json' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--header 'Authorization: Bearer $LITELLM_KEY' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--data '{</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  "model": "claude-opus-5",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  "messages": [</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    {</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      "role": "user",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">      "content": "Refactor this module..."</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    }</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  ],</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  "max_tokens": 4096,</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">  "speed": "fast"</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">}'</span><br></span></code></pre></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><div class="language-bash codeBlockContainer_Ckt0 theme-code-block" style="--prism-color:#000000;--prism-background-color:#ffffff"><div class="codeBlockContent_QJqH"><pre tabindex="0" class="prism-code language-bash codeBlock_bY9V thin-scrollbar" style="color:#000000;background-color:#ffffff"><code class="codeBlockLines_e6Vv"><span class="token-line" style="color:#000000"><span class="token plain">curl --location 'http://0.0.0.0:4000/v1/messages' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--header 'x-api-key: sk-12345' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--header 'content-type: application/json' \</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">--data '{</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "model": "claude-opus-5",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "max_tokens": 4096,</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "speed": "fast",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    "messages": [</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        {</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">            "role": "user",</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">            "content": "Refactor this module..."</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">        }</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">    ]</span><br></span><span class="token-line" style="color:#000000"><span class="token plain">}'</span><br></span></code></pre></div></div></div><div role="tabpanel" class="tabItem_Ymn6" hidden=""><p>Fast mode on the Responses API is coming soon. The <code>speed</code> parameter is not yet forwarded on <code>/v1/responses</code>, so requests there run at standard speed and price until support lands.</p></div></div></div>
<h2 class="anchor anchorWithStickyNavbar_LWe7" id="feedback">Feedback<a href="https://docs.litellm.ai/blog/claude_opus_5#feedback" class="hash-link" aria-label="Direct link to Feedback" title="Direct link to Feedback">​</a></h2>
<p>Running Opus 5 through LiteLLM and hitting something unexpected? Share it on <a href="https://github.com/BerriAI/litellm/discussions/34517" target="_blank" rel="noopener noreferrer">GitHub discussion #34517</a>.</p>]]></content:encoded>
            <category>anthropic</category>
            <category>claude</category>
            <category>opus 5</category>
            <category>day 0 support</category>
        </item>
    </channel>
</rss>