Merge pull request #58 from LuckyForce/main

Solves #57 for o3
This commit is contained in:
yoannchb-pro
2025-07-30 10:52:03 -04:00
committed by GitHub
6 changed files with 449 additions and 469 deletions
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+444 -464
View File
File diff suppressed because it is too large Load Diff
+1 -1
View File
@@ -7,7 +7,7 @@ import { ChatCompletionCreateParamsNonStreaming } from 'openai/resources/chat/co
* @returns
*/
export function fixeO1(model: string, data: ChatCompletionCreateParamsNonStreaming) {
if (!model.startsWith('o1')) return data;
if (!model.startsWith('o1') && !model.startsWith('o3')) return data;
if (data.max_tokens) {
data.max_completion_tokens = data.max_tokens;