Skip to content

Pool every provider's limits, weigh accounts by plan, add a reset calendar - #1

Merged
rune-oai merged 3 commits into
mainfrom
update/all-providers
Nov 16, 2026
Merged

rune-oai merged 3 commits into
mainfrom
update/all-providers

Conversation

@rune-oai

@rune-oai rune-oai commented Nov 16, 2026 •

Copy link
Copy Markdown
Owner

The hub treated Claude and Codex as first-class and everything else as an afterthought: Grok and Gemini had no pooled limits, every account counted the same whatever its plan, and the panel had no single place to see when each allowance resets. This makes every provider the hub holds work the same way.

What changes for someone running a hub

  • Every provider gets pooled limits. Quota history now records Grok, Gemini (Antigravity), Kimi, Muse, Devin and Mistral as well as Claude and Codex, and each gets the same pool card on the Overview page.
  • Plans count. Accounts are weighed by plan in pooled figures and in routing. Pool figures read in percent of the heaviest plan, so a Max 5x plus a Pro account is "of 120%".
  • A Resets view. A calendar of every account window, with the next resets and the allowance still unspent on each. Account details open in the table row; the separate account cards are gone.
  • Routing. soonest-reset-first spreads ties by plan weight and keeps new conversations off an account with little 5-hour headroom left. It also no longer sends work to an account it knows is spent while the account with allowance is only on a short hold (seen on a live hub: one "overloaded" answer led to a two-day "usage limit" refusal).
  • Burn rate. The estimate copes with whole-percent readings and bursty use, says when it has too little data, and projections are capped by what the 5-hour window allows.
  • Mistral. An api.mistral.ai API-key upstream reports its monthly API and Vibe Code budgets as money spent of the monthly amount.
  • Moving a Windows hub. scripts/migrate-windows.ps1 replaces a CLIProxyAPI hub in place (backup, detached switch, health checks, rollback), and t3code-proxy doctor -check-config validates a config first.
  • Docs and logo. Guides for every provider, T3 Code environments over Tailscale, and box setup. New logo.

T3 Code needs no change. The /v0/management endpoints it reads are pinned by test/t3code_contract_test.go, and Mistral accounts stay out of auth-files.

Behavior changes to know about

  • The 5-hour headroom guard is on by default (routing.plan-headroom-reserve: 10; 0 turns it off).
  • Default plan weights: Codex prolite 5, pro 20, promax 50; xAI supergrok_heavy 10. The Codex pro and promax figures are estimates; override under routing.plan-weights.
  • With quota history on and no quota-history.providers list, every supported provider is polled.

Checks

make verify passes locally: lint, all Go tests, build, and 2233 web tests. The Windows migration ran on a real hub (8 seconds, no rollback, all accounts present). Quota reads for Claude, Codex, Grok and Antigravity ran against live accounts; Mistral's two billing endpoints were probed live. Kimi, Muse and Devin quota reads are fixture-tested only.

Council review

Rounds: 7

Delegate Round 1 Round 2 Round 3 Round 4 Round 5 Round 6 Round 7
Fable 5.2 7/10 8/10 9/10 9/10 8/10 no score no score
Opus 5.5 8/10 8/10 9/10 9/10 9/10 9/10 8.5/10
Sol 6.1 6/10 8/10 9/10 9/10 8/10 9/10 8.5/10

Rounds 1 to 4 reviewed the first candidate; rounds 5 to 7 reviewed the later additions. Fable's seat was not run in rounds 6 and 7 (the candidate changed mid-round, then the Fable allowance ran low). No reviewer found a blocker in round 7; its findings are fixed in this branch.

Created with Claude Fable 5.2 in Claude Code, with Claude Opus 5.5, GPT-6.1 Sol, Gemini 3.8 Flash and Grok 4.7 subagents.

🤖 Generated with Claude Code

rune-oai and others added 3 commits November 15, 2026 19:32
…endar

One home hub should treat every subscription it holds the same way, and an
account on a bigger plan should count for more. This brings Grok, Gemini
(Antigravity), Kimi, Muse, Devin and Mistral up to what Claude and Codex
already had, and makes pooled figures and routing plan-aware.

- Quota history records every provider, and each one gets the same pool card
  on the Overview page. Pool figures read in percent of the heaviest plan
  (Max 5x 100% + Pro 20% = "of 120%").
- A Resets view shows every account window on a calendar with the next resets
  and the allowance still unspent on each. Account details open in the table
  row instead of separate cards.
- soonest-reset-first spreads ties by plan weight, guards 5-hour headroom, and
  no longer sends work to a spent account while one with allowance is only on
  hold.
- Burn rate copes with whole-percent readings and bursty use; projections are
  capped by what the 5-hour window allows.
- Mistral API-key upstreams report their monthly API and Vibe Code budgets.
- A Windows migration script moves a CLIProxyAPI hub over in place, and
  `doctor -check-config` validates a config before the switch.
- Guides for every provider, T3 Code environments over Tailscale, and box
  setup. New logo.

T3 Code is unchanged; `/v0/management` stays pinned by its contract test.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
…r month

History is always fetched seven days back, the range the burn estimate reads,
and a month-long window renews on the calendar month instead of every 720
hours. Both found in review.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
One of their tests fails intermittently on CI: the terminal error frame is
sometimes lost to an abnormal close. The code is hours old upstream. The hub's
own fix (no fallback to a spent account while another is on hold) stays.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@rune-oai
rune-oai merged commit 10cb29f into main Nov 16, 2026
5 of 6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant