fix(ollama): add missing api field to auto-discovered models
Auto-discovered Ollama models from discoverOllamaModels() were missing the `api` field, causing "Unhandled API in mapOptionsForApi: undefined" errors when the model was used at runtime. This adds `api: "openai-completions"` to match the provider-level configuration in buildOllamaProvider(). Fixes #3153
This commit is contained in:
parent
01e0d3a320
commit
e508d925b1
@ -120,6 +120,7 @@ async function discoverOllamaModels(): Promise<ModelDefinitionConfig[]> {
|
|||||||
cost: OLLAMA_DEFAULT_COST,
|
cost: OLLAMA_DEFAULT_COST,
|
||||||
contextWindow: OLLAMA_DEFAULT_CONTEXT_WINDOW,
|
contextWindow: OLLAMA_DEFAULT_CONTEXT_WINDOW,
|
||||||
maxTokens: OLLAMA_DEFAULT_MAX_TOKENS,
|
maxTokens: OLLAMA_DEFAULT_MAX_TOKENS,
|
||||||
|
api: "openai-completions",
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user