Skip to content

Commit c30a588

Browse files
committed
New OpenAI models
* Update OpenAI text model list * Remove o1-preview usage from test and production code * Remove o1-preview from places where it was mentioned in documentation
1 parent 306803c commit c30a588

File tree

6 files changed

+8
-14
lines changed

6 files changed

+8
-14
lines changed

+llms/+openai/models.m

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,14 @@
1515
"gpt-4-1106-preview",...
1616
"gpt-3.5-turbo","gpt-3.5-turbo-0125","gpt-3.5-turbo-1106",...
1717
"gpt-3.5-turbo-16k",...
18-
"o1-preview","o1-preview-2024-09-12",...
1918
"o1-mini","o1-mini-2024-09-12",...
2019
"o1","o1-2024-12-17",...
2120
"o3-mini", "o3-mini-2025-01-31",...
2221
"o4-mini", "o4-mini-2025-04-16",...
2322
"o3", "o3-2025-04-16",...
23+
"gpt-5", "gpt-5-2025-08-07",...
24+
"gpt-5-mini", "gpt-5-mini-2025-08-07",...
25+
"gpt-5-nano", "gpt-5-nano-2025-08-07",...
26+
"gpt-5-chat-latest",...
2427
];
2528
end

+llms/+openai/validateResponseFormat.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ function validateResponseFormat(format,model,messages)
99
end
1010

1111
if isequal(format, "json")
12-
if ismember(model,["gpt-4","gpt-4-0613","o1-preview","o1-mini","o1"])
12+
if ismember(model,["gpt-4","gpt-4-0613","o1-mini","o1"])
1313
error("llms:invalidOptionAndValueForModel", ...
1414
llms.utils.errorMessageCatalog.getMessage("llms:invalidOptionAndValueForModel", "ResponseFormat", "json", model));
1515
elseif nargin > 2

doc/functions/azureChat.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -209,7 +209,6 @@ The JSON response format is not supported for these models:
209209

210210
- `"gpt-4"`
211211
- `"gpt-4-0613"`
212-
- `"o1-preview"`
213212
- `"o1-mini"`
214213

215214
#### Structured Output

doc/functions/generate.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,6 @@ The JSON response format is not supported for these models:
192192

193193
- `"gpt-4"`
194194
- `"gpt-4-0613"`
195-
- `"o1-preview"`
196195
- `"o1-mini"`
197196

198197
#### Structured Output

doc/functions/openAIChat.md

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -44,10 +44,7 @@ character vector | string scalar
4444

4545
Specify the system prompt and set the `SystemPrompt` property. The system prompt is a natural language description that provides the framework in which a large language model generates its responses. The system prompt can include instructions about tone, communications style, language, etc.
4646

47-
Specifying a system prompt is not supported for these models:
48-
49-
- `ModelName="o1-preview"`
50-
- `ModelName="o1-mini"`
47+
Specifying a system prompt is not supported for `ModelName="o1-mini"`.
5148

5249
**Example**: `"You are a helpful assistant who provides answers to user queries in iambic pentameter."`
5350

@@ -191,7 +188,6 @@ The JSON response format is not supported for these models:
191188

192189
- `"gpt-4"`
193190
- `"gpt-4-0613"`
194-
- `"o1-preview"`
195191
- `"o1-mini"`
196192

197193
#### Structured Output
@@ -218,10 +214,7 @@ The system prompt is a natural\-language description that provides the framework
218214

219215
To set the `SystemPrompt` property at construction, specify the `systemPrompt` input argument.
220216

221-
Specifying a system prompt is not supported for these models:
222-
223-
- `ModelName="o1-preview"`
224-
- `ModelName="o1-mini"`
217+
Specifying a system prompt is not supported for `ModelName="o1-mini"`.
225218

226219
**Example**: `"You are a helpful assistant who provides answers to user queries in iambic pentameter."`
227220

tests/topenAIChat.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -550,7 +550,7 @@ function specialErrorForUnsupportedResponseFormat(testCase)
550550
"Input",{{ "APIKey" ["abc" "abc"] }},...
551551
"Error","MATLAB:validators:mustBeTextScalar"),...
552552
"StructuredOutputForWrongModel",struct( ...
553-
"Input",{{ "ModelName" "o1-preview" "ResponseFormat" struct("a", 1)}},...
553+
"Input",{{ "ModelName" "gpt-3.5-turbo" "ResponseFormat" struct("a", 1)}},...
554554
"Error","llms:noStructuredOutputForModel"));
555555
end
556556

0 commit comments

Comments
 (0)