<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/">
  <channel>
    <title>Claude Code on Victor Flores, PhD</title>
    <link>https://vflores-io.github.io/tags/claude-code/</link>
    <description>Recent content in Claude Code on Victor Flores, PhD</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    <lastBuildDate>Tue, 06 Oct 2026 00:00:00 +0800</lastBuildDate><atom:link href="https://vflores-io.github.io/tags/claude-code/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Choosing a Model for Every Coding-Agent Task</title>
      <link>https://vflores-io.github.io/posts/20261006_jev_agent_router/jev_agent_router/</link>
      <pubDate>Tue, 06 Oct 2026 00:00:00 +0800</pubDate>
      
      <guid>https://vflores-io.github.io/posts/20261006_jev_agent_router/jev_agent_router/</guid>
      <description>A small router can help coding agents choose a model for each subtask. The useful engineering is in the guardrails around that choice.</description>
      <content:encoded><![CDATA[<p>The classifier is the easy part. The harder question is what happens around its answer.</p>
<p>Coding agents can hand pieces of work to subagents: one might inspect a bug, another might write a test, and another might review a design. Those tasks do not all need the same model. Sending every task to the most capable model can waste money; choosing a model by hand each time adds friction.</p>
<p>I built Jev Agent Router to make that choice when a subagent starts. Jev is a classifier model; I call it through OpenRouter and give it the task title and brief. It chooses among four tiers, from straightforward work to the rare case where a previous attempt at the same task has already fallen short. The main coding-agent conversation keeps its model; only the new subagent&rsquo;s model can change.</p>
<h2 id="keep-the-input-small">Keep the input small</h2>
<p>The router sends Jev the task title and brief, not the whole conversation transcript. That keeps the decision focused on the work the subagent has been asked to do.</p>
<p>Jev returns a tier choice. The router applies the relevant harness configuration to turn that choice into a model for Claude Code or Codex. The point is to pick the least costly tier that looks capable of doing the job, while still leaving the model choice configurable.</p>
<figure>
  <img src="/images/jev-agent-router/jev-router-design.svg" alt="Design diagram: a subagent spawn flows through its task brief, Jev, the configured model ladder, an approval gate for the top Claude Code tier, and the decision log.">
  <figcaption>Design diagram: the route from a subagent request to a model choice.</figcaption>
</figure>
<h2 id="the-guardrails-are-the-useful-part">The guardrails are the useful part</h2>
<p>A classifier can be wrong. So the router can put a configured tier behind an approval step. In the default Claude Code configuration, the top tier, Fable, is gated. The router also appends decisions to a JSONL log so I can inspect what it chose and why. If I want it out of the way, there is a kill switch: set <code>JEV_ROUTER=off</code> or turn the mode off in the config.</p>
<p>The Claude Code and Codex integrations are separate adapters around a shared decision core. They run at subagent spawn time and apply a model to that subagent. The main conversation is left alone. The project uses Node&rsquo;s built-in APIs and <code>fetch</code>; it has no npm dependencies.</p>
<h2 id="what-the-local-log-says">What the local log says</h2>
<p>Over eleven days, from September 23 to October 4, 2026, my local log recorded 239 Claude Code routing decisions. Of those, 231 included an OpenRouter call; their median logged latency was 688 milliseconds.</p>
<p>That is a measure of the extra wait, not a measure of whether Jev picked the best model. I am not treating it as an accuracy result. The more important lesson for me is the one I keep coming back to: the classifier is the easy part. An approval gate, a decision log, and a kill switch are what make the routing usable.</p>
<p>The code is <a href="https://github.com/vflores-io/jev-agent-router">on GitHub</a>.</p>
]]></content:encoded>
    </item>
    
  </channel>
</rss>
