Skip to content

Support per rule model fallbacks for outages and credit depletion #1267

Closed

Description

@esafak

Support the specification of multiple models per mode, in order of preference like so:

"mode": {
    "build": { "models": ["google/gemini-2.5-pro", "openai/o4-mini"] }
}

Activity

  1. self-assigned this
    on Jul 25, 2025
  2. Sewer56 commented on Sep 30, 2025

    @Sewer56
    Contributor

    I'm also quite interested in this actually, but I've nothing else to add outside of that unfortunately.
    The idea of being able to burn up one subscription to the end and fall back to another seems quite appealing- it'd help me make the most of my limits.

  3. 0serna commented on Jan 2, 2026

    @0serna

    This would be very useful, I use OpenCode with subscriptions to GitHub Copilot, Claude Code, and GLM. When I hit the usage limits on any of them mid-task, the workflow gets interrupted. Having fallback models would make the tool more reliable and efficient.

  4. smashah commented on Jan 11, 2026

    @smashah

    this would definitely be a gamechanger especially with recent (un)developments r.e claude and their gatekeeping

  5. pdobrev commented on Jan 11, 2026

    @pdobrev

    Another use-case for this feature would be using the same model from different providers. For example, zAI's GLM-4.7 is offered by Cerebras at insane speeds, but the token-per-minute limits are exhausted pretty quickly. If we could have that by default, but then fallback onto Zen's GLM-4.7 and then after the minute go back to Cerebras, this would make the experience extremely smooth.

  6. manascb1344 commented on Jan 14, 2026

    @manascb1344

    Very useful feature

  7. manascb1344 commented on Jan 14, 2026

    @manascb1344

    Hey! I’m looking into implementing this. I’ve poked around the repo and the plan seems pretty straightforward:

    1. Update PermissionObject in config.ts so models can take an array.
    2. In processor.ts, wrap the LLM calls in a loop that catches 429s or credit depletion errors.
    3. If a model hits a wall, it just cycles to the next one in the list and retries the request.

    I'm ready to start on a PR for this if the approach looks good to you guys.

  8. Sewer56 commented on Jan 14, 2026

    @Sewer56
    Contributor

    Looks sensible to me. @manascb1344
    It's more less what I expect.

  9. elijahdev0 commented on Jan 15, 2026

    @elijahdev0

    +1 really need this!

  10. manascb1344 commented on Jan 16, 2026

    @manascb1344

    I've made the PR for this!

  11. github-actions commented on Mar 26, 2026

    @github-actions
    Contributor

    To stay organized issues are automatically closed after 90 days of no activity. If the issue is still relevant please open a new one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions