Skip to content

Commit 3cec11d

Browse files
authored
Add Claude 4.5 model variants (Haiku, Sonnet, Opus) to OpenRouter client (#1254)
<!-- Thank you for opening a pull request! Please add a brief description of the proposed change here. Also, please tick the appropriate points in the checklist below. --> ## Motivation and Context <!-- Why is this change needed? What problem does it solve? --> #1199 (comment) A user asked to add Claude 4.5 Opus to the list of OpenRouter models. ## Breaking Changes <!-- Will users need to update their code or configurations? --> --- #### Type of the changes - [x] New feature (non-breaking change which adds functionality) - [ ] Bug fix (non-breaking change which fixes an issue) - [ ] Breaking change (fix or feature that would cause existing functionality to change) - [ ] Documentation update - [ ] Tests improvement - [ ] Refactoring #### Checklist - [x] The pull request has a description of the proposed change - [x] I read the [Contributing Guidelines](https://github.com/JetBrains/koog/blob/main/CONTRIBUTING.md) before opening the pull request - [x] The pull request uses **`develop`** as the base branch - [x] Tests for the changes have been added - [x] All new and existing tests passed ##### Additional steps for pull requests adding a new feature - [ ] An issue describing the proposed change exists - [ ] The pull request includes a link to the issue - [ ] The change was discussed and approved in the issue - [ ] Docs have been added / updated
1 parent 521e64d commit 3cec11d

File tree

1 file changed

+36
-0
lines changed
  • prompt/prompt-executor/prompt-executor-clients/prompt-executor-openrouter-client/src/commonMain/kotlin/ai/koog/prompt/executor/clients/openrouter

1 file changed

+36
-0
lines changed

prompt/prompt-executor/prompt-executor-clients/prompt-executor-openrouter-client/src/commonMain/kotlin/ai/koog/prompt/executor/clients/openrouter/OpenRouterModels.kt

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,42 @@ public object OpenRouterModels : LLModelDefinitions {
137137
maxOutputTokens = 32_000,
138138
)
139139

140+
/**
141+
* Claude Haiku 4.5 is Anthropic’s fastest and most efficient model,
142+
* delivering near-frontier intelligence at a fraction of the cost and latency of larger Claude models.
143+
*/
144+
public val Claude4_5Haiku: LLModel = LLModel(
145+
provider = LLMProvider.OpenRouter,
146+
id = "anthropic/claude-haiku-4.5",
147+
capabilities = multimodalCapabilities + additionalCapabilities,
148+
contextLength = 200_000,
149+
maxOutputTokens = 64_000,
150+
)
151+
152+
/**
153+
* Claude Sonnet 4.5 is Anthropic’s most advanced Sonnet model to date, optimized for real-world agents
154+
* and coding workflows.
155+
*/
156+
public val Claude4_5Sonnet: LLModel = LLModel(
157+
provider = LLMProvider.OpenRouter,
158+
id = "anthropic/claude-sonnet-4.5",
159+
capabilities = multimodalCapabilities + additionalCapabilities,
160+
contextLength = 1_000_000,
161+
maxOutputTokens = 64_000,
162+
)
163+
164+
/**
165+
* Claude Opus 4.5 is Anthropic’s frontier reasoning model optimized for complex software engineering,
166+
* agentic workflows, and long-horizon computer use.
167+
*/
168+
public val Claude4_5Opus: LLModel = LLModel(
169+
provider = LLMProvider.OpenRouter,
170+
id = "anthropic/claude-opus-4.5",
171+
capabilities = multimodalCapabilities + additionalCapabilities,
172+
contextLength = 200_000,
173+
maxOutputTokens = 32_000,
174+
)
175+
140176
/**
141177
* Represents the GPT-4o-mini model hosted on OpenRouter.
142178
*

0 commit comments

Comments
 (0)