Google announced that developers can now integrate Google Search into the Gemini API, a feature called "Grounding with Google Search."
The integration aims to provide more accurate and up-to-date AI answers, but comes with a price tag of $35 per 1,000 searches. Developers may want to consider carefully if, where and how they want to add search functionality.
By incorporating Google Search, the API enables Gemini to access current Google search results and summarize them in chat responses, complete with source links for verification. Google says this should result in more precise answers and reduce AI hallucinations, and can also make LLM answers more detailed.
The system uses dynamic retrieval to automatically determine when a search would improve response quality. Developers can adjust a threshold value (default 0.3 on a 0-1 scale) that controls when searches are triggered. This approach mirrors OpenAI's recent ChatGPT search implementation.
AI Web Retrieval vs. WWW
Google also states that the feature should drive traffic to the sites that Gemini paraphrases. However, this increase is likely to be minimal compared to traditional search traffic. App developers should be aware that, similar to Perplexity AI and the like, they're venturing into uncharted territory by paraphrasing websites found via Google search in chat.
Search integration is available for all public versions of Gemini 1.5 models. Developers can test the feature for free in Google AI Studio.
Mandatory search suggestions
Developers implementing the search feature must include "Google Search Suggestions" in their applications. For this, the API also provides the corresponding search queries in the metadata. These suggestions must appear in full width below the AI answers, in both light and dark modes, exactly as specified by Google.
When users click on these suggestions, they must be taken directly to Google search results, either through an in-app browser or an external browser application. This is Google's way of generating additional searches and revenue while scaling its LLM search services.