Skip to content

[BUG] Default small_model charges users when free alternative exists on Copilot #6802

Closed

Description

@peixotorms

Description

When using GitHub Copilot provider, OpenCode defaults small_model to gemini-3-flash-preview (paid) instead of gpt-5-mini (free). This silently incurs charges for users who have free model options available.

I logged in with GPT 5.2 and my usage of premium requests for Gemini 3 Flash kept increasing.

However, it should default to a free model, like the gpt 5 mini instead of a paid model.
If a large context model is used, then GPT-4.1 is also free, but gpt 5 mini is probably a better fit do to the larger output.

Plugins

No response

OpenCode version

1.0.223

Steps to reproduce

Steps to Reproduce

  1. Login to opencode with GitHub Copilot provider
  2. Select any model (e.g., gpt-5.2)
  3. Use opencode normally
  4. Check GitHub Copilot usage page → unexpected Gemini 3 Flash charges

The Problem

  | Model                  | Used For                | Cost |
  |------------------------|-------------------------|------|
  | gpt-5-mini             | Available but NOT used  | Free |
  | gemini-3-flash-preview | Default for small tasks | Paid |

OpenCode's small_model default picks a paid model when a free alternative (gpt-5-mini) exists in the same provider. Users are charged without knowing why.

Evidence from Logs

  modelID=gemini-3-flash-preview ... small=true agent=title   <- PAID, used silently
  modelID=gpt-5.2 ... small=false agent=build                 <- User's selection

Expected Behavior

  1. Default small_model should prefer free models when available
  2. At minimum, users should be informed that a paid model is being used for background tasks

Suggested Fix

For GitHub Copilot provider, change the default small_model priority to prefer gpt-5-mini (free) over gemini-3-flash-preview (paid).

Workaround

Add to ~/.config/opencode/opencode.jsonc:

  {
    "small_model": "github-copilot/gpt-5-mini"
  }

Screenshot and/or share link

No response

Operating System

No response

Terminal

No response

Activity

  1. rekram1-node commented on Jan 4, 2026

    @rekram1-node
    Contributor

    ez fix will do

  2. rekram1-node commented on Jan 4, 2026

    @rekram1-node
    Contributor

    should be fixed in next release: 96a00ff

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

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingzenRelates to Zen

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions