Skip to content
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/curly-frogs-pull.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"roo-cline": patch
---

Use gemini provider when using Gemini on vertex ai
13 changes: 0 additions & 13 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,6 @@
"@anthropic-ai/sdk": "^0.37.0",
"@anthropic-ai/vertex-sdk": "^0.7.0",
"@aws-sdk/client-bedrock-runtime": "^3.779.0",
"@google-cloud/vertexai": "^1.9.3",
"@google/genai": "^0.9.0",
"@mistralai/mistralai": "^1.3.6",
"@modelcontextprotocol/sdk": "^1.7.0",
Expand Down
8 changes: 7 additions & 1 deletion src/api/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import { AnthropicHandler } from "./providers/anthropic"
import { AwsBedrockHandler } from "./providers/bedrock"
import { OpenRouterHandler } from "./providers/openrouter"
import { VertexHandler } from "./providers/vertex"
import { AnthropicVertexHandler } from "./providers/anthropic-vertex"
import { OpenAiHandler } from "./providers/openai"
import { OllamaHandler } from "./providers/ollama"
import { LmStudioHandler } from "./providers/lmstudio"
Expand Down Expand Up @@ -45,6 +46,7 @@ export interface ApiHandler {

export function buildApiHandler(configuration: ApiConfiguration): ApiHandler {
const { apiProvider, ...options } = configuration

switch (apiProvider) {
case "anthropic":
return new AnthropicHandler(options)
Expand All @@ -55,7 +57,11 @@ export function buildApiHandler(configuration: ApiConfiguration): ApiHandler {
case "bedrock":
return new AwsBedrockHandler(options)
case "vertex":
return new VertexHandler(options)
if (options.apiModelId?.startsWith("claude")) {
return new AnthropicVertexHandler(options)
} else {
return new VertexHandler(options)
}
case "openai":
return new OpenAiHandler(options)
case "ollama":
Expand Down
Loading
Loading