[integration][openai] Update stale default model gpt-3.5-turbo to gpt-4o-mini#906
Merged
Merged
Conversation
…-4o-mini gpt-3.5-turbo is a legacy OpenAI model. Update the OpenAI Chat Completions default to gpt-4o-mini, its current low-cost successor and the value the Java Javadoc example already uses, keeping a sensible zero-config default and Java/Python parity. Updates the Java and Python defaults and the OpenAICompletionsSetup parameter tables in the docs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Linked issue: #905
Purpose of change
The OpenAI Chat Completions chat model defaults to
gpt-3.5-turbowhen the caller omitsmodel. This is a legacy OpenAI model, superseded by cheaper and more capable small models. A user who takes the default silently gets an outdated model — and the Java Javadoc example already usesgpt-4o-mini, so the code base is inconsistent with its own default.This change updates the default to
gpt-4o-mini— the current low-cost successor togpt-3.5-turbo— in both language runtimes and the docs, keeping a sensible zero-config default while dropping the legacy model and keeping Java and Python in parity.OpenAICompletionsSetup.DEFAULT_MODELDEFAULT_OPENAI_MODELOpenAICompletionsSetupparameter tables for both languagesTests
No new tests. The existing Python test asserts against the imported
DEFAULT_OPENAI_MODELconstant rather than a hard-coded string, so it continues to pin the default without change (test_openai_chat_model.py). There is no equivalent Java assertion on the default. Verified the Python OpenAI chat-model tests pass and the OpenAI Java module compiles.API
No API signature change. Only the value of the default model changes; callers that pass
modelexplicitly are unaffected.Documentation
doc-neededdoc-not-neededdoc-included