Skip to content

feat(vertexai): integrate Claude model support#14

Draft
CorieW wants to merge 15 commits into
mainfrom
vertexai-add-claude
Draft

feat(vertexai): integrate Claude model support#14
CorieW wants to merge 15 commits into
mainfrom
vertexai-add-claude

Conversation

@CorieW

@CorieW CorieW commented Apr 27, 2026

Copy link
Copy Markdown
Member

Adds support for Claude models in VertexAI plugin

Testing

image

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces support for Anthropic Claude models within the Genkit Vertex AI plugin. Key changes include the implementation of a VertexClaudeModelFactory to handle model interactions, updates to the plugin to list and resolve Anthropic publisher models, and new documentation and examples. Feedback focuses on critical technical refinements: ensuring image inputs are base64-encoded to meet API requirements, renaming internal tools to prevent user-defined conflicts, optimizing tool output encoding, and correcting non-standard regional endpoint URLs.

Comment thread packages/genkit_vertexai/lib/src/claude.dart Outdated
Comment thread packages/genkit_vertexai/lib/src/claude.dart Outdated
Comment thread packages/genkit_vertexai/lib/src/claude.dart Outdated
Comment thread packages/genkit_vertexai/lib/src/vertex_api_client.dart
@CorieW
CorieW requested a review from cabljac April 28, 2026 12:34
Comment thread packages/genkit_vertexai/lib/src/claude.dart Outdated
) {
final systemMessage = req.messages
.where((m) => m.role == Role.system)
.firstOrNull;

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we have multiple system messages here?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could do, but consider:

genkit_openai: allows/preserves multiple system messages.
genkit_anthropic: only uses first, drops the rest.
genkit_google_genai: only uses first, drops the rest.
genkit_firebase_ai: only uses first, drops the rest.

Should we?

Comment thread packages/genkit_vertexai/lib/src/claude.dart
@CorieW
CorieW force-pushed the vertexai-add-claude branch from 455b597 to 9d625b2 Compare May 7, 2026 01:15
@CLAassistant

CLAassistant commented May 25, 2026

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
2 out of 4 committers have signed the CLA.

✅ CorieW
✅ kevmoo
❌ github-actions[bot]
❌ MichaelDoyle
You have signed the CLA already but the status is still pending? Let us recheck it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants