mirror of
https://github.com/langgenius/dify.git
synced 2024-11-15 19:22:36 +08:00
fix: use gpt-4o-mini for validating credentials (#9387)
This commit is contained in:
parent
568d5c46ed
commit
423df67042
|
@ -19,9 +19,9 @@ class OpenAIProvider(ModelProvider):
|
|||
try:
|
||||
model_instance = self.get_model_instance(ModelType.LLM)
|
||||
|
||||
# Use `gpt-3.5-turbo` model for validate,
|
||||
# Use `gpt-4o-mini` model for validate,
|
||||
# no matter what model you pass in, text completion model or chat model
|
||||
model_instance.validate_credentials(model="gpt-3.5-turbo", credentials=credentials)
|
||||
model_instance.validate_credentials(model="gpt-4o-mini", credentials=credentials)
|
||||
except CredentialsValidateFailedError as ex:
|
||||
raise ex
|
||||
except Exception as ex:
|
||||
|
|
Loading…
Reference in New Issue
Block a user