← Blog

I wanted my coding subscriptions to work as one fleet. The config was the easy part.

Building ReddiDotAgents: quota-aware routing across coding subscriptions, two launch-path bugs caught in review, and configuration updates that preserve personal settings.

Nissan Dookeran7 min readCoding AgentsOpen SourceDeveloper Tools

I wanted my coding subscriptions to work as one fleet. The config was the easy part.

I wanted to give a coding task to an agent and have it choose between Claude, ChatGPT and Google Antigravity based on the work and the quota available. Pick the cheapest model that could do the job. Use the subscriptions I already had.

That became ReddiDotAgents, an open-source setup built around Oh My Pi (omp), Firstmate and herdr. Getting the providers into a configuration file was straightforward. Getting the supervisor, quota routing and reasoning settings to agree took the rest of the session.

The review caught two bugs where automatic reasoning effort disappeared when an agent launched or the supervisor restarted. The setting was right in the config. The running agent still lost it.

I'll come back to those. First, we needed to decide who should get the work.

Having quota left isn't the same as using it well

The first request was to balance subagents between Claude and ChatGPT. We found an omp event that runs before each subagent starts and can replace its model. That gave us a place to make the routing decision.

We defined cheap, mid and high model roles, then wrote a roughly 200-line extension that reads omp usage --json before spawning a child. It weights providers by their remaining quota and the time left in the quota window, interleaves work with weighted round-robin, and keeps the other providers as fallbacks.

The reset time changes the decision. If a subscription has 80% left on day one of a seven-day window, there's plenty of time to use it. With 80% left on day six, most of that allowance is about to expire. A router looking only at the remaining percentage would treat those as the same situation.

The first live check launched four trivial subagents. Two went to Claude, two to ChatGPT, all at low reasoning effort. Harder tasks selected high effort on Sonnet and GPT-6.1 Sol.

Roles handle task difficulty; the balancer handles provider availability. Keeping those decisions separate means I can change the model behind a role without rewriting the routing logic. Frontier models stay opt-in.

The cheapest Gemini candidates got the files wrong

Adding Google Antigravity exposed another detail: it had two quota pools. Gemini used one; Claude and GPT shared another. We treated them as separate balancing lanes.

Before relying on any provider, the agent sent a real request through each login. An account appearing in a list tells you it's configured. A successful request tells you it can take work.

Then we tested the cheap Gemini candidates on file inspection. The answers were easy to check against the actual files: file size and line count.

The two cheapest flash-lite candidates invented a file size and miscounted lines. Gemini 3.8 Flash and Gemini 4 Argon got them right. For that job, we moved past the cheapest candidates.

That is the part of “cheapest sufficient” I care about. A cheaper answer that sends the next agent looking for the wrong thing creates more work. File inspection gave us a quick way to reject a model before putting it into the routing tier.

Firstmate could bypass the fleet it was supervising

Firstmate supervises the fleet. omp runs the agents. herdr provides the terminal panes.

Installing herdr's omp integration made the work visible: a pane stayed marked “working” while background subagents ran, and omp's Agent Hub showed each child's routed model, reasoning effort and cost. I could inspect what had actually been dispatched.

Moving Firstmate's supervisor from Pi to omp then uncovered three problems.

A Node upgrade had left npm-installed command-line tools attached to the old Node version. omp wasn't loading the global rules file Pi had used. And Firstmate's delegation guard missed two ways to start children: omp's built-in task tool and subagents launched through its eval kernel.

That last one defeated the point of supervising a fleet. Firstmate could have a dispatch policy while its own supervisor started children outside it.

We fixed the tool paths and rule loading, then wired the guard into both spawn routes. Live checks confirmed that both bypass attempts were refused. The ReddiDotAgents README describes the Firstmate integration and the checkout it requires.

A rule in an instructions file is a starting point. Here, enforcement needed to happen where the child process was created.

We stopped making both layers choose the model

Firstmate expected to pin an execution tool, model and effort for each task. omp already had model roles and auto reasoning effort, where a small judge selects the lowest sufficient effort level.

Hard-coding everything in Firstmate would have duplicated decisions omp already knew how to make. It would also have scattered model names across dispatch profiles.

We changed the profiles to carry an omp role name and a declared quota provider. Firstmate kept fleet-level quota ranking. omp resolved the model behind the role and selected the effort.

That left one configuration file to update when changing the models in a tier. The supervisor could choose where work belonged without taking over every detail of how the agent ran it.

The shared instructions also set a five-agents-per-provider-family concurrency cap, cheapest-sufficient model selection, local-first CI and two independent reviews of the exact commit before automerge.

The review found what a config check missed

The changes went through no-mistakes. Its review found that auto reasoning effort was silently dropped in two places: raw launch commands and supervisor relaunch.

Both paths could start an agent. Both could appear to work. Neither preserved the setting we'd chosen.

Checking that auto existed in the config would have passed. We needed to follow it through the launch command and through a restart. The test stage required live evidence, so we exercised the scenarios in a disposable lab rather than experimenting on the working fleet.

Restart behaviour had already exposed a separate limitation: herdr 0.9.1 didn't automatically resume omp after a server restart. Seeing a running session correctly and recovering it after a restart are separate jobs. We had to check each one.

There was some Git housekeeping too. Local main had diverged from GitHub. We preserved the unique local commits with a Git reference and a verified bundle before reconciling the histories in a second pull request.

The review earned its place by finding two concrete bugs. The bundle meant reconciliation could proceed with the local work preserved.

An updater shouldn't erase the user's settings

Once the pieces worked together, I wanted to reuse the setup on another machine and refresh it when the repository changed.

That makes the sync script as important as the initial configuration. A script that replaces whole files might work beautifully on an empty machine and wipe out someone's preferences on the next run.

Our script merges only the configuration keys it manages. In each AGENTS.md, it replaces a marked block and leaves the surrounding instructions alone. Credentials stay untouched. --apply backs up each changed file before writing.

We tested it against throwaway configuration directories: detecting drift, running twice without introducing extra changes, preserving personal settings, and replacing an outdated managed block. Those are the situations an updater has to survive after its first successful install.

Before publishing the kit, we ran gitleaks across the repository's history and manually checked for personal data and private project names.

Try it against your setup

ReddiDotAgents is MIT-licensed. Start with the README and AGENTS.md. From the root of a local clone, run:

scripts/sync.sh --check

That reports configuration drift without changing files. Review the proposed changes before using --apply to install or refresh the managed settings.

Linux is tested. The macOS and Windows instructions are documented and awaiting verification.

The kit builds on Oh My Pi by can1357, Firstmate and no-mistakes by kunchenguid, and herdr by herdrdev. Their tools do the underlying work; ReddiDotAgents packages the configuration and integration so it can be installed and refreshed together.

If you're running several coding subscriptions, try the read-only check. And follow one task all the way through dispatch, child launch and supervisor restart. That's where our reasoning setting disappeared, twice.