-
Notifications
You must be signed in to change notification settings - Fork 2.6k
feat: enable grounding features for Vertex AI #6777
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- Add enableUrlContext and enableGrounding options to vertexSchema in provider-settings.ts - Update Vertex.tsx UI component to include URL context and grounding checkboxes - Add comprehensive tests for the new grounding features in Vertex.spec.tsx - Reuse existing localization strings from Gemini provider Fixes #6776
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewing my own code because apparently I trust no one, not even myself.
| </Select> | ||
| </div> | ||
|
|
||
| <div className="mt-6"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it intentional that these grounding options aren't wrapped in a !fromWelcomeView condition like they are in the Gemini component (line 77 in Gemini.tsx)? Just curious if we want to show these options in the welcome view for Vertex when we hide them for Gemini.
| </Select> | ||
| </div> | ||
|
|
||
| <div className="mt-6"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since grounding features only work with Gemini models on Vertex AI (not Claude models), would it be helpful to add a comment here explaining this limitation? Something like:
| <div className="mt-6"> | |
| {/* Note: Grounding features only work with Gemini models on Vertex AI, not Claude models */} | |
| <div className="mt-6"> |
This could help future developers understand when these options are actually functional.
| }) | ||
| }) | ||
|
|
||
| describe("Both checkboxes interaction", () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great test coverage for the UI! Would it be valuable to add a test that verifies these options work correctly when using Gemini models (like "gemini-2.5-flash") on Vertex? Since grounding is Gemini-specific, it might be good to have a test that validates the integration with actual Gemini model IDs.
|
@roomote-agent Is it necessary to make changes to the provider logic at all? Just answer the question don't make any changes |
|
Hi @daniel-lxs! No, it is not necessary to make changes to the provider logic at all. The backend implementation is already complete because:
Since Vertex AI inherits from Gemini, the grounding features work automatically once the UI passes these options. No additional backend changes are needed! 🎉 |
daniel-lxs
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
Haven’t tried this out but I agree with the bot’s feedback:
|
…w and only show for Gemini models
Closes #6776
Description
This PR enables the grounding features (URL context and Google Search grounding) for Vertex AI that were previously only available for the Gemini provider. Since the Vertex AI provider inherits from the Gemini provider, the backend functionality was already in place - we just needed to expose the UI options.
Changes
enableUrlContextandenableGroundingoptions tovertexSchemainprovider-settings.tsVertex.tsxUI component to include URL context and grounding checkboxesVertex.spec.tsxTesting
Screenshots
The Vertex AI settings page now includes the same grounding options as the Gemini provider:
Both options work independently and use the same backend implementation that was already available through inheritance from the Gemini provider.
Important
Enable grounding features for Vertex AI by adding UI options and tests, reusing Gemini provider functionality.
enableUrlContextandenableGroundingoptions tovertexSchemainprovider-settings.ts.Vertex.tsxto include checkboxes for URL context and grounding.Vertex.spec.tsxto verify the rendering and functionality of the new checkboxes.This description was created by
for e9f6590. You can customize this summary. It will automatically update as commits are pushed.