Model switches back to the original selection after prompting #2829

Closed
opened 2026-02-16 17:37:24 -05:00 by yindo · 17 comments
Owner

Originally created by @AdiKsOnDev on GitHub (Nov 13, 2025).

Originally assigned to: @rekram1-node on GitHub.

Description

if you start Opencode with a specific model set as a default (in my case - Anthropic Claude Sonnet 4.5), then during session you switch to another model (in my case - Bedrock Claude Sonnet 4.5), after the model finished working on the prompt and you try prompting again - the model will switch back to the original (default) selection. This was not the case before

Note

In my case, I also notice that I can't prompt anymore during that session anymore. My prompts just don't trigger anything
However I left this out because I've currently hit my limit on Claude MAX account so I could blame this bug to the way
OpenCode handles Claude MAX limits (I think it doesn't, KEKW)

OpenCode version

1.0.61

Steps to reproduce

  1. Open the TUI with Anthropic Claude Sonnet 4.5 selected
  2. Switch the model using <leader> + m keybind to Bedrock Claude Sonnet 4.5
  3. Prompt
  4. Prompt again
  5. (Hopefully) Notice the model being switched back.

Screenshot and/or share link

https://opencode.ai/s/52SxnB2F

Operating System

Arch Linux (6.17.7-arch1-1) with Hyprland

Terminal

Kitty terminal + zsh

Originally created by @AdiKsOnDev on GitHub (Nov 13, 2025). Originally assigned to: @rekram1-node on GitHub. ### Description if you start Opencode with a specific model set as a default (in my case - Anthropic Claude Sonnet 4.5), then during session you switch to another model (in my case - Bedrock Claude Sonnet 4.5), after the model finished working on the prompt and you try prompting again - the model will switch back to the original (default) selection. This was not the case before >[!NOTE] >In my case, I also notice that I can't prompt anymore during that session anymore. My prompts just don't trigger anything >However I left this out because I've currently hit my limit on Claude MAX account so I could blame this bug to the way >OpenCode handles Claude MAX limits (I think it doesn't, KEKW) ### OpenCode version 1.0.61 ### Steps to reproduce 1. Open the TUI with `Anthropic Claude Sonnet 4.5` selected 2. Switch the model using `<leader> + m` keybind to `Bedrock Claude Sonnet 4.5` 3. Prompt 4. Prompt again 5. (Hopefully) Notice the model being switched back. ### Screenshot and/or share link https://opencode.ai/s/52SxnB2F ### Operating System Arch Linux (6.17.7-arch1-1) with Hyprland ### Terminal Kitty terminal + zsh
yindo added the opentuibug labels 2026-02-16 17:37:24 -05:00
yindo closed this issue 2026-02-16 17:37:24 -05:00
Author
Owner

@github-actions[bot] commented on GitHub (Nov 13, 2025):

This issue might be a duplicate of existing issues. Please check:

  • #4243: Model cycling issues when default model is set (same version 1.0.61) - describes the exact same problem where model selection reverts to default after switching
  • #1661: Model switching problems between plan/build modes - similar behavior where models don't persist selection properly

Feel free to ignore if none of these address your specific case.

@github-actions[bot] commented on GitHub (Nov 13, 2025): This issue might be a duplicate of existing issues. Please check: - #4243: Model cycling issues when default model is set (same version 1.0.61) - describes the exact same problem where model selection reverts to default after switching - #1661: Model switching problems between plan/build modes - similar behavior where models don't persist selection properly Feel free to ignore if none of these address your specific case.
Author
Owner

@rekram1-node commented on GitHub (Nov 13, 2025):

/oc can u figure out what's causing this bug

@rekram1-node commented on GitHub (Nov 13, 2025): /oc can u figure out what's causing this bug
Author
Owner

@opencode-agent[bot] commented on GitHub (Nov 13, 2025):

Created PR #4296

New%20session%20-%202025-11-13T18%3A00%3A55.675Z
opencode session  |  github run

@opencode-agent[bot] commented on GitHub (Nov 13, 2025): Created PR #4296 <a href="https://opencode.ai/s/1e5VyuQ3"><img width="200" alt="New%20session%20-%202025-11-13T18%3A00%3A55.675Z" src="https://social-cards.sst.dev/opencode-share/TmV3IHNlc3Npb24gLSAyMDI1LTExLTEzVDE4OjAwOjU1LjY3NVo=.png?model=opencode/glm-4.6&version=1.0.62&id=1e5VyuQ3" /></a> [opencode session](https://opencode.ai/s/1e5VyuQ3)&nbsp;&nbsp;|&nbsp;&nbsp;[github run](/sst/opencode/actions/runs/19341070384)
Author
Owner

@rekram1-node commented on GitHub (Nov 18, 2025):

Hm I can't replicate think this was fixed

@rekram1-node commented on GitHub (Nov 18, 2025): Hm I can't replicate think this was fixed
Author
Owner

@AdiKsOnDev commented on GitHub (Nov 18, 2025):

Hm I can't replicate think this was fixed

Haven't faced this issue since last couple updates too, so perhaps. I'll lyk if it happens again, thanks 4 attention

@AdiKsOnDev commented on GitHub (Nov 18, 2025): > Hm I can't replicate think this was fixed Haven't faced this issue since last couple updates too, so perhaps. I'll lyk if it happens again, thanks 4 attention
Author
Owner

@dekoza commented on GitHub (Jan 20, 2026):

Current OpenCode (1.1.25) changes model after entering the first prompt after launching. I have Copilot connected and the starting box shows the last model I worked with (say GPT 5.2). After I enter any prompt the model changes to Gemini 3 Pro Preview from Copilot. This is super-annoying as I cannot change this behavior in any way. Pre-selecting other model does nothing.

@dekoza commented on GitHub (Jan 20, 2026): Current OpenCode (1.1.25) changes model after entering the first prompt after launching. I have Copilot connected and the starting box shows the last model I worked with (say GPT 5.2). After I enter any prompt the model changes to `Gemini 3 Pro Preview` from Copilot. This is super-annoying as I cannot change this behavior in any way. Pre-selecting other model does nothing.
Author
Owner

@ebreen commented on GitHub (Jan 21, 2026):

Current OpenCode (1.1.25) changes model after entering the first prompt after launching. I have Copilot connected and the starting box shows the last model I worked with (say GPT 5.2). After I enter any prompt the model changes to Gemini 3 Pro Preview from Copilot. This is super-annoying as I cannot change this behavior in any way. Pre-selecting other model does nothing.

im having this same exact issue, but instead the model always changes to Claude Opus 4.5. So annoying.

@ebreen commented on GitHub (Jan 21, 2026): > Current OpenCode (1.1.25) changes model after entering the first prompt after launching. I have Copilot connected and the starting box shows the last model I worked with (say GPT 5.2). After I enter any prompt the model changes to `Gemini 3 Pro Preview` from Copilot. This is super-annoying as I cannot change this behavior in any way. Pre-selecting other model does nothing. im having this same exact issue, but instead the model always changes to Claude Opus 4.5. So annoying.
Author
Owner

@iam-brain commented on GitHub (Jan 21, 2026):

I'm having this issue in 1.1.26 as well. It will default to a seemingly random model, Gemini 3 Pro in this instance, and changing the model to anything else will apply on a new session. I hate to enter the first prompt, interrupt, change the model, and then redo the initial message.

@iam-brain commented on GitHub (Jan 21, 2026): I'm having this issue in 1.1.26 as well. It will default to a seemingly random model, Gemini 3 Pro in this instance, and changing the model to anything else will apply on a new session. I hate to enter the first prompt, interrupt, change the model, and then redo the initial message.
Author
Owner

@rekram1-node commented on GitHub (Jan 21, 2026):

Are any of you using plugins? Because if so I think your plugin is changing it in some way...

@rekram1-node commented on GitHub (Jan 21, 2026): Are any of you using plugins? Because if so I think your plugin is changing it in some way...
Author
Owner

@iam-brain commented on GitHub (Jan 21, 2026):

Are any of you using plugins? Because if so I think your plugin is changing it in some way...

My current setup only has obra superpowers, opencode antigravity auth, and playwright MCP. Standard opencode install otherwise.

@iam-brain commented on GitHub (Jan 21, 2026): > Are any of you using plugins? Because if so I think your plugin is changing it in some way... My current setup only has [obra superpowers](https://github.com/obra/superpowers), [opencode antigravity auth](https://github.com/NoeFabris/opencode-antigravity-auth), and [playwright MCP](https://github.com/microsoft/playwright-mcp). Standard opencode install otherwise.
Author
Owner

@rekram1-node commented on GitHub (Jan 21, 2026):

well that's an obra issue https://github.com/obra/superpowers/issues/301 @iam-brain

@rekram1-node commented on GitHub (Jan 21, 2026): well that's an obra issue https://github.com/obra/superpowers/issues/301 @iam-brain
Author
Owner

@rekram1-node commented on GitHub (Jan 21, 2026):

How about the rest of you?

@rekram1-node commented on GitHub (Jan 21, 2026): How about the rest of you?
Author
Owner

@ebreen commented on GitHub (Jan 22, 2026):

How about the rest of you?

Can confirm it was the Superpowers skill that caused this issue for me.
Fixed after uninstalling Superpowers.

@ebreen commented on GitHub (Jan 22, 2026): > How about the rest of you? Can confirm it was the Superpowers skill that caused this issue for me. Fixed after uninstalling Superpowers.
Author
Owner

@iam-brain commented on GitHub (Jan 22, 2026):

Unfortunately, uninstalling superpowers seems to have fixed it for me as well. Looks like there might not be a good fix for it at the moment.

@iam-brain commented on GitHub (Jan 22, 2026): Unfortunately, uninstalling superpowers seems to have fixed it for me as well. Looks like there might not be a good fix for it at the moment.
Author
Owner

@koosty commented on GitHub (Jan 24, 2026):

Update superpowers

cd ~/.config/opencode/superpowers
git pull
@koosty commented on GitHub (Jan 24, 2026): Update superpowers ``` cd ~/.config/opencode/superpowers git pull ```
Author
Owner

@golamt313 commented on GitHub (Jan 29, 2026):

Update superpowers

cd ~/.config/opencode/superpowers
git pull

This did it for me. Also make sure to also replace ~/.config/opencode/plugin/superpowers.js with ~/.config/opencode/superpowers/.opencode/plugins/superpowers.js. Otherwise you will black screen.

@golamt313 commented on GitHub (Jan 29, 2026): > Update superpowers > > ``` > cd ~/.config/opencode/superpowers > git pull > ``` This did it for me. Also make sure to also replace ~/.config/opencode/plugin/superpowers.js with ~/.config/opencode/superpowers/.opencode/plugins/superpowers.js. Otherwise you will black screen.
Author
Owner

@iam-brain commented on GitHub (Jan 29, 2026):

Update superpowers

cd ~/.config/opencode/superpowers
git pull

I can also confirm that Obra has finally fixed the issue since that comment was posted.

@iam-brain commented on GitHub (Jan 29, 2026): > Update superpowers > > ``` > cd ~/.config/opencode/superpowers > git pull > ``` I can also confirm that Obra has finally fixed the issue since that comment was posted.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#2829