Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

fix: azure embedding model credentials include base_model_name is invalid for openai sdk (#917)

takatost1c552ff23aa7
diff --git a/api/core/model_providers/models/embedding/azure_openai_embedding.py b/api/core/model_providers/models/embedding/azure_openai_embedding.py
index 127bf640eee..1b9149392b7 100644
--- a/api/core/model_providers/models/embedding/azure_openai_embedding.py
+++ b/api/core/model_providers/models/embedding/azure_openai_embedding.py
@@ -26,7 +26,8 @@ class AzureOpenAIEmbedding(BaseEmbedding):
openai_api_version=AZURE_OPENAI_API_VERSION,
chunk_size=16,
max_retries=1,
- **self.credentials
+ openai_api_key=self.credentials.get('openai_api_key'),
+ openai_api_base=self.credentials.get('openai_api_base')
)
super().__init__(model_provider, client, name)