summaryrefslogtreecommitdiffhomepage
path: root/internal/llm/models
diff options
context:
space:
mode:
authorphantomreactor <[email protected]>2025-05-18 18:59:53 +0530
committerGitHub <[email protected]>2025-05-18 08:29:53 -0500
commit2f8984fadb24ba7b369d0d09c6ad4823f7f48a63 (patch)
treeb2622de3be116971f00f31e4b7c376d51dd98609 /internal/llm/models
parentc84918cb47d17c10286985bce7539161dfd13869 (diff)
downloadopencode-2f8984fadb24ba7b369d0d09c6ad4823f7f48a63.tar.gz
opencode-2f8984fadb24ba7b369d0d09c6ad4823f7f48a63.zip
Codex mini (#34)
Diffstat (limited to 'internal/llm/models')
-rw-r--r--internal/llm/models/groq.go2
-rw-r--r--internal/llm/models/openai.go15
2 files changed, 17 insertions, 0 deletions
diff --git a/internal/llm/models/groq.go b/internal/llm/models/groq.go
index 19917f20b..0a54053de 100644
--- a/internal/llm/models/groq.go
+++ b/internal/llm/models/groq.go
@@ -41,6 +41,7 @@ var GroqModels = map[ModelID]Model{
CostPer1MInCached: 0,
CostPer1MOutCached: 0,
CostPer1MOut: 0.34,
+ DefaultMaxTokens: 8192,
ContextWindow: 128_000, // 10M when?
SupportsAttachments: true,
},
@@ -54,6 +55,7 @@ var GroqModels = map[ModelID]Model{
CostPer1MInCached: 0,
CostPer1MOutCached: 0,
CostPer1MOut: 0.20,
+ DefaultMaxTokens: 8192,
ContextWindow: 128_000,
SupportsAttachments: true,
},
diff --git a/internal/llm/models/openai.go b/internal/llm/models/openai.go
index abe0e30c5..fdca5bed3 100644
--- a/internal/llm/models/openai.go
+++ b/internal/llm/models/openai.go
@@ -3,6 +3,7 @@ package models
const (
ProviderOpenAI ModelProvider = "openai"
+ CodexMini ModelID = "codex-mini"
GPT41 ModelID = "gpt-4.1"
GPT41Mini ModelID = "gpt-4.1-mini"
GPT41Nano ModelID = "gpt-4.1-nano"
@@ -18,6 +19,20 @@ const (
)
var OpenAIModels = map[ModelID]Model{
+ CodexMini: {
+ ID: CodexMini,
+ Name: "Codex Mini",
+ Provider: ProviderOpenAI,
+ APIModel: "codex-mini-latest",
+ CostPer1MIn: 1.50,
+ CostPer1MInCached: 0.375,
+ CostPer1MOutCached: 0.0,
+ CostPer1MOut: 6.00,
+ ContextWindow: 200_000,
+ DefaultMaxTokens: 100_000,
+ CanReason: true,
+ SupportsAttachments: true,
+ },
GPT41: {
ID: GPT41,
Name: "GPT 4.1",