From 53199d31016cc559715b856befec6731984dc2c6 Mon Sep 17 00:00:00 2001 From: Lumia <130642629+SpeedupMaster@users.noreply.github.com> Date: Mon, 30 Dec 2024 17:00:47 +0800 Subject: [PATCH 1/4] Add o1 model in Openai models --- src/config/modelProviders/openai.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/config/modelProviders/openai.ts b/src/config/modelProviders/openai.ts index 14e955652568..da4b52ba5d56 100644 --- a/src/config/modelProviders/openai.ts +++ b/src/config/modelProviders/openai.ts @@ -17,6 +17,21 @@ const OpenAI: ModelProviderCard = { }, releasedAt: '2024-09-12', }, + { + contextWindowTokens: 200_000, + description: + 'o1是OpenAI新的推理模型,支持图文输入并输出文本,适用于需要广泛通用知识的复杂任务。该模型具有200K上下文和2023年10月的知识截止日期。', + displayName: 'OpenAI o1', + enabled: true, + id: 'o1-2024-12-17', + maxOutput: 100_000, + pricing: { + input: 15, + output: 60, + }, + vision: true, + releasedAt: '2024-12-17', + }, { contextWindowTokens: 128_000, description: From 7e54cb25f80d5e5917a70bc3bd242d3e97f0a8f3 Mon Sep 17 00:00:00 2001 From: Lumia <130642629+SpeedupMaster@users.noreply.github.com> Date: Mon, 30 Dec 2024 17:16:52 +0800 Subject: [PATCH 2/4] Add o1 model in Openrouter models --- src/config/modelProviders/openrouter.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/config/modelProviders/openrouter.ts b/src/config/modelProviders/openrouter.ts index d0efaa821b37..41babf61f716 100644 --- a/src/config/modelProviders/openrouter.ts +++ b/src/config/modelProviders/openrouter.ts @@ -27,6 +27,21 @@ const OpenRouter: ModelProviderCard = { }, releasedAt: '2024-09-12', }, + { + contextWindowTokens: 200_000, + description: + 'o1是OpenAI新的推理模型,支持图文输入并输出文本,适用于需要广泛通用知识的复杂任务。该模型具有200K上下文和2023年10月的知识截止日期。', + displayName: 'OpenAI o1', + enabled: true, + id: 'openai/o1', + maxOutput: 100_000, + pricing: { + input: 15, + output: 60, + }, + releasedAt: '2024-09-12', + vision: true, + }, { contextWindowTokens: 128_000, description: From 045661d4ba3c59c81bc9e8fd97f7e4ae4c06e4c9 Mon Sep 17 00:00:00 2001 From: Lumia <130642629+SpeedupMaster@users.noreply.github.com> Date: Mon, 30 Dec 2024 17:20:38 +0800 Subject: [PATCH 3/4] Update openrouter.ts --- src/config/modelProviders/openrouter.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/config/modelProviders/openrouter.ts b/src/config/modelProviders/openrouter.ts index 41babf61f716..9480a1942c37 100644 --- a/src/config/modelProviders/openrouter.ts +++ b/src/config/modelProviders/openrouter.ts @@ -39,7 +39,7 @@ const OpenRouter: ModelProviderCard = { input: 15, output: 60, }, - releasedAt: '2024-09-12', + releasedAt: '2024-12-17', vision: true, }, { From 9e56e4e52c5864106ff448604db3d6527f07999d Mon Sep 17 00:00:00 2001 From: Lumia <130642629+SpeedupMaster@users.noreply.github.com> Date: Tue, 31 Dec 2024 17:18:57 +0800 Subject: [PATCH 4/4] Update modelProvider.test.ts --- src/store/user/slices/modelList/selectors/modelProvider.test.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/store/user/slices/modelList/selectors/modelProvider.test.ts b/src/store/user/slices/modelList/selectors/modelProvider.test.ts index 9287d0cf97fd..d385ea8cb9d9 100644 --- a/src/store/user/slices/modelList/selectors/modelProvider.test.ts +++ b/src/store/user/slices/modelList/selectors/modelProvider.test.ts @@ -51,6 +51,7 @@ describe('modelProviderSelectors', () => { const result = modelProviderSelectors.getDefaultEnabledModelsById('openai')(s); expect(result).toEqual([ 'o1-mini', + 'o1-2024-12-17', 'o1-preview', 'gpt-4o-mini', 'gpt-4o-2024-11-20',