diff --git a/src/lib/components/chat/ModelSelector/Selector.svelte b/src/lib/components/chat/ModelSelector/Selector.svelte index 2d73e2248..720ee55e1 100644 --- a/src/lib/components/chat/ModelSelector/Selector.svelte +++ b/src/lib/components/chat/ModelSelector/Selector.svelte @@ -33,7 +33,7 @@ : items; const pullModelHandler = async () => { - const sanitizedModelTag = searchValue.trim(); + const sanitizedModelTag = searchValue.trim().replace(/^ollama\s+(run|pull)\s+/, ''); console.log($MODEL_DOWNLOAD_POOL); if ($MODEL_DOWNLOAD_POOL[sanitizedModelTag]) {