feat: Implement Ollama embedding

Adds support for Ollama embedding, enabling the use of Ollama as an embedding model for RAG.

This allows users to leverage Ollama's advanced embedding capabilities for better document understanding and retrieval.
This commit is contained in:
n4ze3m
2024-10-13 19:07:01 +05:30
parent ff4473c35b
commit d64c84fc83
4 changed files with 23 additions and 60 deletions

View File

@@ -11,7 +11,8 @@ import {
defaultEmbeddingChunkOverlap,
defaultEmbeddingChunkSize,
defaultEmbeddingModelForRag,
saveForRag
saveForRag,
getEmbeddingModels
} from "~/services/ollama"
import {
@@ -77,7 +78,7 @@ export const SettingsBody = () => {
getOllamaURL(),
systemPromptForNonRag(),
promptForRag(),
getAllModels({ returnEmpty: true }),
getEmbeddingModels({ returnEmpty: true }),
defaultEmbeddingChunkOverlap(),
defaultEmbeddingChunkSize(),
defaultEmbeddingModelForRag(),