<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="3.10.0">Jekyll</generator><link href="https://swingtempo.github.io/feed.xml" rel="self" type="application/atom+xml" /><link href="https://swingtempo.github.io/" rel="alternate" type="text/html" /><updated>2026-07-18T23:38:02+00:00</updated><id>https://swingtempo.github.io/feed.xml</id><title type="html">Jay Ongg’s Blog</title><subtitle>Former Microsoft, learn new tech, democratize AI.</subtitle><entry><title type="html">OmniRoute, the AI Gateway</title><link href="https://swingtempo.github.io/omniroute-the-ai-gateway" rel="alternate" type="text/html" title="OmniRoute, the AI Gateway" /><published>2026-07-18T09:12:01+00:00</published><updated>2026-07-18T09:12:01+00:00</updated><id>https://swingtempo.github.io/omniroute-the-ai-gateway</id><content type="html" xml:base="https://swingtempo.github.io/omniroute-the-ai-gateway"><![CDATA[<h1 id="free-cloud-coding-agent">Free cloud coding agent?</h1>

<p>One of the things I miss from Microsoft is the access to Github Copilot CLI with nigh-unlimited token usage. I looked for cost-effective ways for LLM access that can augment any paid or local LLMs I have. That’s how I discovered an Open Source project, <a href="https://omniroute.online">OmniRoute</a> (<a href="https://github.com/diegosouzapw/OmniRoute">GitHub</a>).</p>

<h1 id="so-whats-omniroute">So, what’s OmniRoute?</h1>
<p><img src="/assets/images/omniroute-for-coding-llms/omniroute-routing-llm-for-developer.png" alt="Server routing LLM messages to different LLMs" /></p>

<p>With OmniRoute, you can leverage multiple LLM providers with your favorite CLI or harness (like Claude Code, Codex, or Continue.dev). This is what happens:</p>

<ul>
  <li>OmniRoute exposes a <code class="language-plaintext highlighter-rouge">localhost:20128</code> endpoint with a dashboard so you can configure which providers to leverage, like OpenAI, Claude, or Chipotle (not kidding). You specify the priority of the LLMs - you can mix paid and free providers. There are 236 available as of this date.</li>
  <li><code class="language-plaintext highlighter-rouge">localhost</code> also serves an OpenAI-compatible API that a harness can hit.</li>
  <li>Configure your favorite harness to route requests to your <code class="language-plaintext highlighter-rouge">localhost</code>. I was chagrined to see that GitHub Copilot (CLI and in VSCode) does not allow you to switch endpoints that I could see.</li>
  <li>Each request sends a model parameter to use. Instead of using a well-known model name (e.g. <code class="language-plaintext highlighter-rouge">gpt-5.6-sol</code>), the client sends up a “model” (aka “combo”) that only OmniRoute knows (like <code class="language-plaintext highlighter-rouge">auto/best-coding</code>). Use one that’s <a href="https://github.com/diegosouzapw/OmniRoute/blob/735e2d0783bdecc1aae5cea158d8e8192eeff31a/src/domain/assessment/types.ts#L231">built-in</a> to OmniRoute, or you can add your own.
    <ul>
      <li>OmniRoute suggests starting with the <code class="language-plaintext highlighter-rouge">auto</code> combo.</li>
      <li>OmniRoute will try all providers associated with a combo for your prompts, with smart caching of what works.</li>
      <li>You can provide API keys for paid models if you want to use them in your combo.</li>
    </ul>
  </li>
</ul>

<p>OmniRoute embodies this insightful principle:</p>
<div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>Every computer science problem can be solved by just another layer of abstraction.
 -- David Wheeler
</code></pre></div></div>
<p>As a developer working with an agent, you can choose which models you want on the fly. For your specific configuration, you can pick and choose from multiple paid and free models out there. This extra layer of abstraction allows OmniRoute to support:</p>
<ul>
  <li>Smart failure modes - if you hit a 429 or timeout in the middle of a chat, you won’t lose context.</li>
  <li><a href="https://github.com/rtk-ai/rtk">RTK</a> + <a href="https://getcaveman.dev/">Caveman</a> compression to optimize your model usage.</li>
  <li>Not to mention, you can use the same harness/CLI, and select which backend you want to hit by switching your model/combo.
    <ul>
      <li>For example, I’m OK with using the cloud-based services for most queries, but I want to hit my local LLM to do my taxes.</li>
    </ul>
  </li>
</ul>

<p>And since the code is open source, you as a developer can make changes to decorate any requests to fulfill your specific needs.</p>

<h1 id="ok-how-do-i-get-it-working-with-codex">OK, how do I get it working with Codex?</h1>
<p>One of the problems I had to work through when I first started using OmniRoute is “how do I get started”? Below is a quickstart for users. I’ll start with Codex for a CLI, and Continue.dev for VSCode integration.</p>

<ol>
  <li>Install OmniRoute with <code class="language-plaintext highlighter-rouge">npm install -g omniroute</code>.</li>
  <li>Run <code class="language-plaintext highlighter-rouge">omniroute</code>, this will open up the dashboard. Default password is <code class="language-plaintext highlighter-rouge">CHANGEME</code>.</li>
  <li>From the left sidebar, click on “<a href="http://localhost:20128/dashboard/api-manager">API Keys</a>” and create a new API key. Record it separately since it will not be visible again.</li>
  <li>In your operating system, set the environment variable persistently. e.g., in Windows:
    <div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>setx OMNIROUTE_API_KEY &lt;APIKEY&gt;
</code></pre></div>    </div>
  </li>
  <li>Now let’s launch Codex, but configured for OmniRoute. Do:
    <div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>omniroute launch-codex --model auto
</code></pre></div>    </div>
    <p>You can do this manually via <code class="language-plaintext highlighter-rouge">codex</code> and command line parameters to specify endpoint and api key, but with the above command, OmniRoute takes care of everything for you.</p>
  </li>
  <li>(optional) You can see the details of the request by clicking <a href="http://localhost:20128/dashboard/logs">Monitoring/Logs</a> from the left sidebar:
<img src="/assets/images/omniroute-for-coding-llms/successful-log-ux.png" alt="Screenshot from dashboard" />
Clicking through shows you more details. As a side note, you can see what info gets sent up from your favorite harness. This is helpful from an educational and debugging perspective.</li>
</ol>

<h1 id="but-i-like-ides">But I like IDEs!</h1>
<p>I couldn’t figure out a way to get VSCode’s native GitHub chat to point to a different endpoint. I ended up downloading the <a href="https://continue.dev">Continue.dev</a> extension and used that instead. OmniRoute doesn’t auto-configure this for you, so it’s a little bit involved.</p>

<p>First, go through steps 1-3 above. Then:</p>
<ol>
  <li>In <code class="language-plaintext highlighter-rouge">%USERPROFILE%\.continue\config.yaml</code> or <code class="language-plaintext highlighter-rouge">~/.continue/config.yaml</code>, find the <code class="language-plaintext highlighter-rouge">models</code> data structure. Add the following lines to add the <code class="language-plaintext highlighter-rouge">auto</code> model config, and replace <APIKEY> with the api key you generated above.
</APIKEY>    <div class="language-plaintext highlighter-rouge"><div class="highlight"><pre class="highlight"><code>  - name: OmniRoute - Auto
 provider: openai
 model: auto
 apiBase: http://localhost:20128/v1
 apiKey: &lt;APIKEY&gt;
</code></pre></div>    </div>
  </li>
  <li>In the Continue.dev chat pane, select <code class="language-plaintext highlighter-rouge">OmniRoute - Auto</code> and you will make requests to OmniRoute.</li>
  <li>(Optional) Exercise for the reader - have your IDE update the <code class="language-plaintext highlighter-rouge">config.yaml</code> with all the other prebuilt configurations 😊</li>
</ol>

<p><img src="/assets/images/omniroute-for-coding-llms/continue-dev-screenshot.png" alt="Screenshot from Continue.dev" /></p>

<h2 id="tradeoffs">Tradeoffs</h2>
<p>Like everything in engineering, there are tradeoffs. When you’re working with free models, you need to deal with higher latency and availability. For me, I’m not currently working on huge code bases (like Microsoft Teams or Loop), so the tradeoffs swing the right way for me.</p>

<h1 id="closing-thoughts">Closing thoughts</h1>
<p>That should get you started! Hopefully this gives you enough info so you can pattern match to other harnesses. OmniRoute is Open Source, and they welcome contributions if you find any issues or if you have any suggestions!</p>]]></content><author><name></name></author><category term="ai" /><category term="agents" /><category term="free" /><category term="omniroute" /><summary type="html"><![CDATA[Free cloud coding agent?]]></summary></entry></feed>