Skip to content

[Feature Request] Fallback chains for subagent complexity tiers (light/medium/heavy) when a model's limit is exhausted #105

Open

Description

@sashalab

Summary

Please let each subagent complexity tier (light, medium, heavy) take an ordered fallback chain of models instead of a single model. When the first model in the chain can't serve a request because a usage limit, quota, or rate limit is exhausted, Droid should move on to the next model in the list automatically.

I am not asking for the agent to pick arbitrary models. I like the current design, where the agent passes only complexity and the user or org decides which model backs each tier. The request is only to make each tier resilient to running out of one provider's limits.

Motivation

Many users have several independent sources of model capacity at the same time: the Factory plan (including Droid Core), a connected ChatGPT subscription provider, Anthropic API keys, OpenAI-compatible BYOK endpoints, and local models. Each has its own limits and reset windows.

Today subagentModelSettings maps each tier to exactly one model. When that model's limit runs out:

  • subagents on that tier fail until the limit resets, and
  • the only fix is to open /settings → Subagents and switch the tier by hand, then switch it back after the reset.

With parallel subagents this happens often and gets in the way. The spare capacity in the other subscriptions goes unused, even though it is already configured.

The documented fallback (pinned model → parent model) only covers models blocked by policy or BYOK models that aren't configured. It doesn't cover an exhausted limit.

Proposed behavior

  1. Each tier accepts an ordered list, for example:

    {
      "subagentModelSettings": {
        "heavyModel": ["custom:chatgpt/gpt-6.2-astra", "claude-opus-5-5", "custom:k3.1-pro"],
        "heavyReasoningEffort": ["high", "high", null],
        "mediumModel": ["custom:chatgpt/gpt-6.2-sol", "claude-sonnet-5-5", "glm-5.3"],
        "lightModel": ["custom:chatgpt/gpt-6-luna", "claude-haiku-5-5", "deepseek-v4.1-flash-1017"]
      }
    }

    (Or a separate heavyFallbackModels array next to the existing scalar, to stay backward compatible. Either shape is fine.)

  2. Move to the next model only on capacity failures: usage or quota limit reached, 429 after retries are exhausted, the provider being unavailable, or an expired subscription or auth that can't be refreshed. Don't move on normal model errors or task failures.

  3. Once a model fails this way, skip it for later subagent launches until a cooldown ends or its known reset time passes, so each launch doesn't hit the exhausted model again.

  4. Make the switch visible: show which model actually ran in the Task result and UI, and say why the earlier entries were skipped.

  5. Keep a running subagent on the same model while it can serve requests, so prompt caching isn't broken. Switch only when it can't continue, and say so in its transcript.

  6. Allow auto (Factory Router) and inherit as entries in the list, for example [..., "auto"] as the last resort.

  7. Keep org controls working: modelPolicy still filters the list, and with allowSubagentModelOverrides org tier chains act as defaults users can override.

Optional follow-up: the same chain idea for the main session model and for missionModelSettings (worker and validator models).

Current workaround and its limitations

  • Switching the tier models in /settings by hand whenever a limit runs out. This is tedious and easy to forget to undo.
  • Defining one custom droid per provider so the parent agent can retry on another droid after a failure. This leaks provider names into the agent's routing, works against the tier abstraction, and leaves fallback to the model's judgment instead of the harness.
  • An external LiteLLM-style gateway with fallbacks. This only works with API keys, not with subscription providers or the Factory plan, and adds infrastructure to maintain.

Environment

  • Droid CLI 1.12.1, macOS, Factory desktop app
  • Tier routing configured with a ChatGPT subscription provider; Anthropic and several OpenAI-compatible BYOK models also configured

Activity

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

Metadata

Metadata

Assignees

No one assigned

    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