[RECIPE PROPOSAL] Google Trends agent — natural language to BigQuery SQL
⚠️ Scope Notice
For contrib/ recipes only. core/ recipes follow a different process.
1- What is the intent/purpose of your new recipe? In what way will it help the ADK community?
Context
This re-introduces the Google Trends Agent, restructured to the new ADK recipe
format. An earlier version shipped in this repo as
python/agents/google-trends-agent (added in #331, maintained through #1857)
until it was removed on 2026-07-23 by #2291 — the bulk sweep that retired 40
agents and 998 files from the legacy python/agents/ tree. It was not dropped
on merit; the entire directory went. This brings it back under
contrib/python/, rebuilt against the current contribution guidelines, with a
correctness fix to how it queries refresh_date
Purpose
Lets a non-SQL user ask questions like "what are the top 5 trending terms in
Canada this week?" and get an interpreted answer back, over the public
bigquery-public-data.google_trends dataset.
The intended use is as a trend-discovery step inside a marketing or product research agentic workflow. The dataset carries rising terms with a percent_gain (breakout detection),
region_name (sub-national targeting), rank/score, and a weekly history —
so the agent answers the questions that normally start a campaign cycle:
- What is breaking out right now in my market, and how fast?
- Which regions within a country are driving a term?
- Is this term seasonal, or genuinely new this week?
- How do rising terms differ from established top terms for my category?
Scope boundary: the recipe is read-only and request-driven. It does not schedule runs, push alerts, or write anywhere — those would be the caller's job in a larger workflow.
2- What language is your recipe is implemented in (e.g. Python, Go, etc)? Python.
3- Will this be a deployable recipe, either by having a Dockerfile, or by utilizing Vertex AI?
Yes — Vertex AI Agent Engine, via deployment/deploy.py. manifest.yaml sets
deployable: true. No Dockerfile.
4- What GCP services or third-party APIs (Salesforce, Jira, etc.) are required?
- BigQuery — reads the public
bigquery-public-data.google_trendsdataset (a billing project is needed for query jobs; the data itself is public) - Vertex AI — Gemini for both sub-agents
- Vertex AI Agent Engine + a GCS bucket, for the optional deployment path
5- Who (individual/team) will own and maintain this? individual - @yelshater
6- Please include any additional information you'd like to share.
Already passing locally: uv run validate (4/4), ruff format, ruff check,
uv lock --check, and pytest with the CI exclusions. The integration test hits
real Gemini + BigQuery and also passes.
Source: google/adk-samples