Skip to content

Commit

Permalink
fix: use gpt-4o-mini for validating credentials (#9387)
Browse files Browse the repository at this point in the history
  • Loading branch information
crazywoola authored Oct 16, 2024
1 parent 568d5c4 commit 423df67
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions api/core/model_runtime/model_providers/openai/openai.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ def validate_provider_credentials(self, credentials: Mapping) -> None:
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:
Expand Down

0 comments on commit 423df67

Please sign in to comment.