Lorenze/tools drop litellm (#3710)

* completely drop litellm and correctly pass config for qdrant

* feat: add support for additional embedding models in EmbeddingService

- Expanded the list of supported embedding models to include Google Vertex, Hugging Face, Jina, Ollama, OpenAI, Roboflow, Watson X, custom embeddings, Sentence Transformers, Text2Vec, OpenClip, and Instructor.
- This enhancement improves the versatility of the EmbeddingService by allowing integration with a wider range of embedding providers.

* fix: update collection parameter handling in CrewAIRagAdapter

- Changed the condition for setting vectors_config in the CrewAIRagAdapter to check for QdrantConfig instance instead of using hasattr. This improves type safety and ensures proper configuration handling for Qdrant integration.
This commit is contained in:
Lorenze Jay
2025-10-15 15:34:44 -07:00
committed by GitHub
parent a9aff87db3
commit 2d5ad7a187
6 changed files with 875 additions and 32 deletions

View File

@@ -4,6 +4,7 @@ from dataclasses import field
from typing import Literal, cast
from pydantic.dataclasses import dataclass as pyd_dataclass
from qdrant_client.models import VectorParams
from crewai.rag.config.base import BaseRagConfig
from crewai.rag.qdrant.constants import DEFAULT_EMBEDDING_MODEL, DEFAULT_STORAGE_PATH
@@ -53,3 +54,4 @@ class QdrantConfig(BaseRagConfig):
embedding_function: QdrantEmbeddingFunctionWrapper = field(
default_factory=_default_embedding_function
)
vectors_config: VectorParams | None = field(default=None)

View File

@@ -4,8 +4,8 @@ import asyncio
from typing import TypeGuard
from uuid import uuid4
from qdrant_client import AsyncQdrantClient # type: ignore[import-not-found]
from qdrant_client import (
AsyncQdrantClient, # type: ignore[import-not-found]
QdrantClient as SyncQdrantClient, # type: ignore[import-not-found]
)
from qdrant_client.models import ( # type: ignore[import-not-found]