tools fix and formatting (#2441)
This commit is contained in:
@@ -13,7 +13,16 @@ class EmbedderConfig(BaseModel):
|
||||
@field_validator("config")
|
||||
def validate_config(cls, v, values):
|
||||
provider = values.data.get("provider")
|
||||
if provider in ["openai", "ollama", "huggingface", "azure_openai", "gemini", "vertexai", "together", "lmstudio"]:
|
||||
if provider in [
|
||||
"openai",
|
||||
"ollama",
|
||||
"huggingface",
|
||||
"azure_openai",
|
||||
"gemini",
|
||||
"vertexai",
|
||||
"together",
|
||||
"lmstudio",
|
||||
]:
|
||||
return v
|
||||
else:
|
||||
raise ValueError(f"Unsupported embedding provider: {provider}")
|
||||
|
||||
Reference in New Issue
Block a user