Change Ollama model selector to filterable dropdown (#3999)
* use dropdown for Ollama model list when possible Code changes by Qwen3 30B A3B, based on OpenRouterModelPicker * Document libasound2 and libnss3 test dependencies, sort list * add test for OllamaModelPicker Code by Claude Sonnet 3.7 * Add changeset
This commit is contained in:
1 parent
4a3f5c4f69
commit
00901e01b7
6 files changed
+530
-42
No files matched your search
@@ -18,7 +18,7 @@ export async function getOllamaModels(controller: Controller, request: StringReq
|
||||
|
||||
const response = await axios.get(`${baseUrl}/api/tags`)
|
||||
const modelsArray = response.data?.models?.map((model: any) => model.name) || []
|
||||
const models = [...new Set<string>(modelsArray)]
|
||||
const models = [...new Set<string>(modelsArray)].sort()
|
||||
|
||||
return StringArray.create({ values: models })
|
||||
} catch (error) {
|
||||
|
||||
Reference in new issue
Block a user