|
|
@@ -198,7 +198,8 @@ export class ChatGPTApi implements LLMApi {
|
|
|
const isDalle3 = _isDalle3(options.config.model);
|
|
|
const isO1OrO3 =
|
|
|
options.config.model.startsWith("o1") ||
|
|
|
- options.config.model.startsWith("o3");
|
|
|
+ options.config.model.startsWith("o3") ||
|
|
|
+ options.config.model.startsWith("o4-mini");
|
|
|
if (isDalle3) {
|
|
|
const prompt = getMessageTextContent(
|
|
|
options.messages.slice(-1)?.pop() as any,
|
|
|
@@ -243,7 +244,7 @@ export class ChatGPTApi implements LLMApi {
|
|
|
}
|
|
|
|
|
|
// add max_tokens to vision model
|
|
|
- if (visionModel) {
|
|
|
+ if (visionModel && !isO1OrO3) {
|
|
|
requestPayload["max_tokens"] = Math.max(modelConfig.max_tokens, 4000);
|
|
|
}
|
|
|
}
|