mirror of
https://github.com/crewAIInc/crewAI.git
synced 2026-05-03 00:02:36 +00:00
'add specific providers to provider type'
This commit is contained in:
@@ -1,5 +1,5 @@
|
|||||||
import os
|
import os
|
||||||
from typing import Any, Callable, cast
|
from typing import Any, Callable, Literal, cast
|
||||||
|
|
||||||
from chromadb import Documents, EmbeddingFunction, Embeddings
|
from chromadb import Documents, EmbeddingFunction, Embeddings
|
||||||
from chromadb.api.types import validate_embedding_function
|
from chromadb.api.types import validate_embedding_function
|
||||||
@@ -26,7 +26,19 @@ class EmbeddingProviderConfig(BaseModel):
|
|||||||
|
|
||||||
|
|
||||||
class EmbeddingConfig(BaseModel):
|
class EmbeddingConfig(BaseModel):
|
||||||
provider: str
|
provider: Literal[
|
||||||
|
"openai",
|
||||||
|
"azure",
|
||||||
|
"ollama",
|
||||||
|
"vertexai",
|
||||||
|
"google",
|
||||||
|
"cohere",
|
||||||
|
"voyageai",
|
||||||
|
"bedrock",
|
||||||
|
"huggingface",
|
||||||
|
"watson",
|
||||||
|
"custom",
|
||||||
|
]
|
||||||
config: EmbeddingProviderConfig | None = None
|
config: EmbeddingProviderConfig | None = None
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user