feat: pre-select models in the webui using alias (#25492)

Co-authored-by: example name <example@example.org>
This commit is contained in:
felix
2026-07-10 13:04:00 +00:00
committed by GitHub
parent 9f623c683d
commit 07d9378286
+6 -1
View File
@@ -633,7 +633,12 @@ class ModelsStore {
}
findModelByName(modelName: string): ModelOption | null {
return this.models.find((model) => model.model === modelName) ?? null;
return (
this.models.find(
(model) =>
model.model === modelName || model.id === modelName || model.aliases?.includes(modelName)
) ?? null
);
}
findModelById(modelId: string): ModelOption | null {