mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-03-13 11:26:18 +01:00
🦙 fix: Memory Agent Fails to Initialize with Ollama Provider (#11680)
Fixed an issue where memory agents would fail with 'Provider Ollama not supported' error when using Ollama as a custom endpoint. The getCustomEndpointConfig function was only normalizing the endpoint config name but not the endpoint parameter during comparison. Changes: - Modified getCustomEndpointConfig to normalize both sides of the endpoint comparison - Added comprehensive test coverage for getCustomEndpointConfig including: - Test for case-insensitive Ollama endpoint matching (main fix) - Tests for various edge cases and error handling This ensures that endpoint name matching works correctly for Ollama regardless of case sensitivity in the configuration.
This commit is contained in:
parent
2e42378b16
commit
8e3b717e99
2 changed files with 76 additions and 4 deletions
|
|
@ -64,7 +64,7 @@ export const getCustomEndpointConfig = ({
|
|||
|
||||
const customEndpoints = appConfig.endpoints?.[EModelEndpoint.custom] ?? [];
|
||||
return customEndpoints.find(
|
||||
(endpointConfig) => normalizeEndpointName(endpointConfig.name) === endpoint,
|
||||
(endpointConfig) => normalizeEndpointName(endpointConfig.name) === normalizeEndpointName(endpoint),
|
||||
);
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue