Implement provider formatting improvements and fix client-side compatibility

- Add PROVIDER_INFO metadata to each provider file with proper display names
- Create centralized PROVIDER_METADATA in index.ts for consistent reference
- Update settings UI to use provider metadata for display names
- Fix client/server compatibility for Node.js modules in config.ts
This commit is contained in:
haddadrm
2025-04-01 19:26:15 +04:00
parent aa240009ab
commit 7e1dc33a08
11 changed files with 97 additions and 26 deletions

View File

@@ -1,6 +1,11 @@
import axios from 'axios';
import { getKeepAlive, getOllamaApiEndpoint } from '../config';
import { ChatModel, EmbeddingModel } from '.';
export const PROVIDER_INFO = {
key: 'ollama',
displayName: 'Ollama'
};
import { ChatOllama } from '@langchain/community/chat_models/ollama';
import { OllamaEmbeddings } from '@langchain/community/embeddings/ollama';