- Notifications
You must be signed in to change notification settings - Fork1k
feat: Add Google Search grounding to GoogleModel - open issue #840#2161
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
PR Change SummaryImplemented Google Search grounding in the GoogleModel, enhancing its ability to provide real-time information.
Modified Files
How can I customize these reviews?Check out theHyperlint AI Reviewer docs for more information on how to customize the review. If you just want to ignore it on this PR, you can add the Note specifically for link checks, we only check the first 30 links in a file and we cache the results for several hours (for instance, if you just added a page, you might experience this). Our recommendation is to add |
This is already covered in#2102 which will be merged soon! |
Closes#840
Description
This pull request implements native Google Search grounding for the
GoogleModel
, enabling it to answer questions about current events and access real-time information. This provides a direct and intuitive way to leverage one of Gemini's core features within thepydantic-ai
framework, resolving the feature request in issue#840.Key Changes
✨ Feature Implementation:
enable_google_search: bool
parameter to theGoogleModel
constructor.True
, the model is configured to automatically use theGoogleSearch
tool for grounding.🧪 Test Coverage:
vcrpy
cassette to ensure the test runs offline and validates the feature's behavior without needing a live API key during CI/CD runs.📚 Documentation: