Skip to content

Commit 109f0ec

Browse files
authored
Add gpt-4.1 (RooCodeInc#2880)
* Add gpt-4.1 * Create eighty-carpets-attack.md
1 parent e2cd3d7 commit 109f0ec

File tree

2 files changed

+30
-1
lines changed

2 files changed

+30
-1
lines changed
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"claude-dev": patch
3+
---
4+
5+
Add gpt-4.1

src/shared/api.ts

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -604,8 +604,32 @@ export const geminiModels = {
604604
// OpenAI Native
605605
// https://openai.com/api/pricing/
606606
export type OpenAiNativeModelId = keyof typeof openAiNativeModels
607-
export const openAiNativeDefaultModelId: OpenAiNativeModelId = "gpt-4o"
607+
export const openAiNativeDefaultModelId: OpenAiNativeModelId = "gpt-4.1"
608608
export const openAiNativeModels = {
609+
"gpt-4.1": {
610+
maxTokens: 32_768,
611+
contextWindow: 1_047_576,
612+
supportsImages: true,
613+
supportsPromptCache: true,
614+
inputPrice: 2,
615+
outputPrice: 8,
616+
},
617+
"gpt-4.1-mini": {
618+
maxTokens: 32_768,
619+
contextWindow: 1_047_576,
620+
supportsImages: true,
621+
supportsPromptCache: true,
622+
inputPrice: 0.4,
623+
outputPrice: 1.6,
624+
},
625+
"gpt-4.1-nano": {
626+
maxTokens: 32_768,
627+
contextWindow: 1_047_576,
628+
supportsImages: true,
629+
supportsPromptCache: true,
630+
inputPrice: 0.1,
631+
outputPrice: 0.4,
632+
},
609633
"o3-mini": {
610634
maxTokens: 100_000,
611635
contextWindow: 200_000,

0 commit comments

Comments
 (0)