| name | quota-axi |
| description | Check remaining subscription quota across providers (Claude, Codex) before routing or delegating token-heavy work, so a session sends bulk work to the model family with more headroom. Use at session start and before large delegations or fan-outs. |
Quota-aware routing
You are running through CLIProxyAPI with two subscription backends — Claude
(Anthropic OAuth) and Codex/GPT (ChatGPT OAuth). The scarce resource is
quota, not dollars. Before committing token-heavy work to a family, check
what's left.
How to read quota
Run the recommendation command immediately before choosing workers:
<skill-dir>/scripts/quota-axi recommend --task-shape bulk
Use fanout for several parallel workers and review for an independent review. The command
runs quota-axi --json, applies the policy below, and prints ROUTE, headroom, freshness,
the reason, and the exact next action. Follow NEXT. If FRESHNESS=stale, treat the route as
advisory and refresh authentication before a large irreversible fan-out.
(One-time: the user must run quota-axi --allow-keychain-prompt and approve the
macOS Keychain dialog before Claude quota is readable; Codex works without it.)
Each provider reports windows[] with percentRemaining and resetsAt. Treat
the lowest relevant window as the provider's headroom.
Routing rules
Apply these when choosing which model does the bulk (worker/executor) role.
Keep the lead model as configured unless its family is critically low.
- Both families healthy (>40%) — use the configured pattern from the
model-orchestration skill unchanged (Claude spine + GPT review layer).
- Codex/GPT low (<20%) — avoid
gpt-* workers and the GPT reviewer; run an
all-Claude spine (Fable/Sonnet/Haiku). Note the switch to the user.
- Claude low (<20%) — shift the token-heavy worker role to
gpt-5.6-* and
lean on Codex; keep only light Claude usage.
- One family critically low (<5%) — do not route any new heavy work there;
tell the user which window is nearly exhausted and when it
resetsAt.
Always state, in one line, the emitted route and reason so the routing decision is visible.
Notes
- Read-only tool; it never mutates provider state or logs in.
- If a provider is unreadable, the command routes only to a readable alternative or emits
ROUTE=stop; never guess its quota.
- Re-check quota before a large parallel fan-out, not just at session start.