[FEATURE]: Refresh models manually #3111

Open
opened 2026-02-16 17:38:41 -05:00 by yindo · 3 comments
Owner

Originally created by @sazary on GitHub (Nov 25, 2025).

Originally assigned to: @thdxr on GitHub.

Feature hasn't been suggested before.

  • I have verified this feature I'm about to request hasn't been suggested before.

Describe the enhancement you want to request

the problem

afaik there is no way to manually refresh the models list. there are several issues reported that are basically saying "i can't see the latest model just released" and the devs are pointing to manually remove the cache file (~/.cache/opencode/models.json). e.g. look at #4493, #4463, #2961. this is not a good ux and wastes dev time.

the solution

i think we could just add a keyboard shortcut in the "select model" modal, named "refresh models list" with the possible default shortcut of ctrl+r which would basically just call the refresh method at ./packages/opencode/src/provider/models.ts

if this makes sense i could work on a pr

Originally created by @sazary on GitHub (Nov 25, 2025). Originally assigned to: @thdxr on GitHub. ### Feature hasn't been suggested before. - [x] I have verified this feature I'm about to request hasn't been suggested before. ### Describe the enhancement you want to request ## the problem afaik there is no way to manually refresh the models list. there are several issues reported that are basically saying "i can't see the latest model just released" and the devs are pointing to manually remove the cache file (`~/.cache/opencode/models.json`). e.g. look at #4493, #4463, #2961. this is not a good ux and wastes dev time. ## the solution i think we could just add a keyboard shortcut in the "select model" modal, named "refresh models list" with the possible default shortcut of `ctrl+r` which would basically just call the `refresh` method at `./packages/opencode/src/provider/models.ts` if this makes sense i could work on a pr
yindo added the discussion label 2026-02-16 17:38:41 -05:00
Author
Owner

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

This issue might be a duplicate of or closely related to existing issues. Please check:

  • #2047: LM Studio Failure to refresh models - Users need manual refresh when local model lists change
  • #2223: Cloudflare Workers AI models not appearing in interactive interface - Models exist but aren't visible due to cache/loading issues
  • #156: feat: refresh cached results - General request for refresh capability on cached data

These issues all describe the same root problem: users cannot refresh the models list when it becomes stale, requiring manual cache file deletion as a workaround. Implementing the refresh shortcut proposed in this issue would resolve all of them.

@github-actions[bot] commented on GitHub (Nov 25, 2025): This issue might be a duplicate of or closely related to existing issues. Please check: - #2047: LM Studio Failure to refresh models - Users need manual refresh when local model lists change - #2223: Cloudflare Workers AI models not appearing in interactive interface - Models exist but aren't visible due to cache/loading issues - #156: feat: refresh cached results - General request for refresh capability on cached data These issues all describe the same root problem: users cannot refresh the models list when it becomes stale, requiring manual cache file deletion as a workaround. Implementing the refresh shortcut proposed in this issue would resolve all of them.
Author
Owner

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

Yup definitely wanna do that. Also note that you can do opencode models --refresh now but still yeah needs to be in the tui

@rekram1-node commented on GitHub (Nov 25, 2025): Yup definitely wanna do that. Also note that you can do `opencode models --refresh` now but still yeah needs to be in the tui
Author
Owner

@kristopolous commented on GitHub (Feb 5, 2026):

Also it doesn't add all the models. Essentially this should be blank

diff \
  <(opencode models --refresh | grep openrouter | cut -d '/' -f 2- | sort) \
  <(curl -s https://openrouter.ai/api/v1/models | jq -r '.data[].id' | sort ) 

but instead it's very different and the opencode models list has a bunch of invalid entries

@kristopolous commented on GitHub (Feb 5, 2026): Also it doesn't add all the models. Essentially this should be blank ``` diff \ <(opencode models --refresh | grep openrouter | cut -d '/' -f 2- | sort) \ <(curl -s https://openrouter.ai/api/v1/models | jq -r '.data[].id' | sort ) ``` but instead it's very different and the opencode models list has a bunch of invalid entries
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#3111