Make Codex and Claude Code subscriptions go further: a local model router that gives routine agent work to economical models and keeps your strongest model for the hard parts.
Rust ai-agentsai-gatewayclaude-codecodexcoding-agentcost-optimizationdeepseekllm-gatewayllm-routerlocal-firstmodel-routingrusttask-routingtauri
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN"
"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg xmlns:xlink="http://www.w3.org/1999/xlink" width="720pt" height="345.6pt" viewBox="0 0 720 345.6" xmlns="http://www.w3.org/2000/svg" version="1.1">
<metadata>
<rdf:RDF xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:cc="http://creativecommons.org/ns#" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<cc:Work>
<dc:type rdf:resource="http://purl.org/dc/dcmitype/StillImage"/>
<dc:format>image/svg+xml</dc:format>
<dc:creator>
<cc:Agent>
<dc:title>Matplotlib v3.11.2, https://matplotlib.org/</dc:title>
</cc:Agent>
</dc:creator>
</cc:Work>
</rdf:RDF>
</metadata>
<defs>
<style type="text/css">*{stroke-linejoin: round; stroke-linecap: butt}</style>
</defs>
<g id="figure_1">
<g id="patch_1">
<path d="M 0 345.6
L 720 345.6
L 720 0
L 0 0
z
" style="fill: #ffffff"/>
</g>
<g id="axes_1">
<g id="patch_2">
<path d="M 92.64625 255.093656
L 709.2 255.093656
L 709.2 45.235547
L 92.64625 45.235547
z
" style="fill: #ffffff"/>
</g>
<g id="patch_3">
<path d="M 92.64625 54.774552
L 559.732424 54.774552
L 559.732424 114.88335
L 92.64625 114.88335
z
" clip-path="url(#p81abc4844e)" style="fill: #5564bd"/>
</g>
<g id="patch_4">
<path d="M 92.64625 185.445853
L 131.481507 185.445853
L 131.481507 245.554651
L 92.64625 245.554651
z
" clip-path="url(#p81abc4844e)" style="fill: #078677"/>
</g>
<g id="matplotlib.axis_1">
<g id="xtick_1">
<g id="line2d_1">
<defs>
<path id="m82bb2c2545" d="M 0 0
L 0 3.5
" style="stroke: #000000; stroke-width: 0.8"/>
</defs>
<g>
<use xlink:href="#m82bb2c2545" x="92.64625" y="255.093656" style="stroke: #000000; stroke-width: 0.8"/>
</g>
</g>
<g id="text_1">
<text style="font-size: 10px; font-family: 'DejaVu Sans'; text-anchor: middle" x="92.64625" y="269.691312" transform="rotate(-0 92.64625 269.691312)">0%</text>
</g>
</g>
<g id="xtick_2">
<g id="line2d_2">
<g>
<use xlink:href="#m82bb2c2545" x="209.417794" y="255.093656" style="stroke: #000000; stroke-width: 0.8"/>
</g>
</g>
<g id="text_2">
<text style="font-size: 10px; font-family: 'DejaVu Sans'; text-anchor: middle" x="209.417794" y="269.691312" transform="rotate(-0 209.417794 269.691312)">25%</text>
</g>
</g>
<g id="xtick_3">
<g id="line2d_3">
<g>
<use xlink:href="#m82bb2c2545" x="326.189337" y="255.093656" style="stroke: #000000; stroke-width: 0.8"/>
</g>
</g>
<g id="text_3">
<text style="font-size: 10px; font-family: 'DejaVu Sans'; text-anchor: middle" x="326.189337" y="269.691312" transform="rotate(-0 326.189337 269.691312)">50%</text>
</g>
</g>
<g id="xtick_4">
<g id="line2d_4">
<g>
<use xlink:href="#m82bb2c2545" x="442.960881" y="255.093656" style="stroke: #000000; stroke-width: 0.8"/>
</g>
</g>
<g id="text_4">
<text style="font-size: 10px; font-family: 'DejaVu Sans'; text-anchor: middle" x="442.960881" y="269.691312" transform="rotate(-0 442.960881 269.691312)">75%</text>
</g>
</g>
<g id="xtick_5">
<g id="line2d_5">
<g>
<use xlink:href="#m82bb2c2545" x="559.732424" y="255.093656" style="stroke: #000000; stroke-width: 0.8"/>
</g>
</g>
<g id="text_5">
<text style="font-size: 10px; font-family: 'DejaVu Sans'; text-anchor: middle" x="559.732424" y="269.691312" transform="rotate(-0 559.732424 269.691312)">100%</text>
</g>
</g>
<g id="text_6">
<text style="font-size: 10px; font-family: 'DejaVu Sans'; text-anchor: middle" x="400.923125" y="283.692094" transform="rotate(-0 400.923125 283.692094)">Whole-task API-equivalent cost · All Astra = 100%</text>
</g>
</g>
<g id="matplotlib.axis_2">
<g id="ytick_1">
<g id="line2d_6">
<defs>
<path id="m7cbd49e816" d="M 0 0
L -3.5 0
" style="stroke: #000000; stroke-width: 0.8"/>
</defs>
<g>
<use xlink:href="#m7cbd49e816" x="92.64625" y="84.828951" style="stroke: #000000; stroke-width: 0.8"/>
</g>
</g>
<g id="text_7">
<text style="font-size: 10px; font-family: 'DejaVu Sans'; text-anchor: end" x="85.64625" y="88.62817" transform="rotate(-0 85.64625 88.62817)">All Astra</text>
</g>
</g>
<g id="ytick_2">
<g id="line2d_7">
<g>
<use xlink:href="#m7cbd49e816" x="92.64625" y="215.500252" style="stroke: #000000; stroke-width: 0.8"/>
</g>
</g>
<g id="text_8">
<text style="font-size: 10px; font-family: 'DejaVu Sans'; text-anchor: end" x="85.64625" y="219.299471" transform="rotate(-0 85.64625 219.299471)">HiRoute mixed</text>
</g>
</g>
</g>
<g id="patch_5">
<path d="M 92.64625 255.093656
L 709.2 255.093656
" style="fill: none; stroke: #000000; stroke-width: 0.8; stroke-linejoin: miter; stroke-linecap: square"/>
</g>
<g id="text_9">
<text style="font-weight: 700; font-size: 12px; font-family: 'DejaVu Sans'; text-anchor: start; fill: #192439" x="569.074148" y="87.946607" transform="rotate(-0 569.074148 87.946607)">$1.953–1.987</text>
</g>
<g id="text_10">
<text style="font-weight: 700; font-size: 12px; font-family: 'DejaVu Sans'; text-anchor: start; fill: #192439" x="140.823231" y="218.617908" transform="rotate(-0 140.823231 218.617908)">$0.150–0.162</text>
</g>
<g id="text_11">
<text style="font-weight: 700; font-size: 23px; font-family: 'DejaVu Sans'; text-anchor: end; fill: #087464" x="699.858277" y="221.474861" transform="rotate(-0 699.858277 221.474861)">−91.69%</text>
</g>
<g id="text_12">
<text style="font-size: 19px; font-family: 'DejaVu Sans'; text-anchor: start" x="92.64625" y="25.235547" transform="rotate(-0 92.64625 25.235547)">Same delivery standard. Over 90% lower cost.</text>
</g>
</g>
<g id="text_13">
<text style="font-size: 9px; font-family: 'DejaVu Sans'; fill: #566078" transform="translate(57.6 322.701539)">Mean cost across two runs meeting the same gate, including all attempts and routing evaluation.</text>
<text style="font-size: 9px; font-family: 'DejaVu Sans'; fill: #566078" transform="translate(57.6 333.504)">Conservative comparison: mixed upper bound ÷ Astra lower bound. All three runs remain in the record.</text>
</g>
</g>
<defs>
<clipPath id="p81abc4844e">
<rect x="92.64625" y="45.235547" width="616.55375" height="209.858109"/>
</clipPath>
</defs>
</svg>