Skip to content

fix(models): de-dupe favorites by model id (nickname no longer lists a model twice)#138

Open
yanalialiuk wants to merge 1 commit into
AtomicBot-ai:mainfrom
yanalialiuk:fix/models-favorites-dedupe
Open

fix(models): de-dupe favorites by model id (nickname no longer lists a model twice)#138
yanalialiuk wants to merge 1 commit into
AtomicBot-ai:mainfrom
yanalialiuk:fix/models-favorites-dedupe

Conversation

@yanalialiuk

Copy link
Copy Markdown
Contributor

Summary

  • De-duplicate favorite models in the model dropdown by model id.
  • When the same model id appears under multiple providers (e.g. llamacpp + llamacpp-upstream), favorites now collapse to a single entry instead of showing twice after nicknaming.
  • Prefer the copy that carries a user nickname (model.displayName); otherwise keep the first match.

Problem

Favorites are keyed by model id, but searchableItems can include the same id from more than one provider. Nicknaming one copy caused the favorite list to show the model twice — once with the nickname and once with the raw id.

Test plan

  • Favorite a model that exists under multiple providers
  • Set a nickname on the favorite
  • Confirm the favorites section shows only one entry for that model id

Made with Cursor

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants