Google Cloud Generative AI: The Complete Guide to Official Gemini & Vertex AI Samples
Google's official repository of sample code and notebooks for building with Generative AI on Google Cloud. With 14,000+ stars, 303 contributors, and coverage spanning Gemini models, Vertex AI Search, RAG & grounding, vision, audio, and a massive ecosystem of related repositories — this is where enterprise generative AI development starts.
Google Cloud Generative AI on GitHub
What Is This Repository?
The official GoogleCloudPlatform repository containing notebooks, code samples, and sample apps demonstrating how to use, develop, and manage generative AI workflows using Vertex AI and Gemini on Google Cloud.
- Language: Jupyter Notebook (Python)
- License: Apache 2.0
- Stars: 14,000+ ⭐
- Forks: 3,900+
- Contributors: 303
- Maintained by: Google Cloud Platform
- Homepage: cloud.google.com/vertex-ai
Repository Structure
| Directory | What It Covers |
|---|---|
gemini/ | Gemini models — text, multimodal, code, function calling. Includes getting-started notebooks for Gemini 3.1 Pro |
search/ | Vertex AI Search — enterprise search powered by generative AI |
rag-grounding/ | RAG & Grounding — retrieval-augmented generation with grounding |
vision/ | Image generation, image editing, visual captioning, visual question answering |
audio/ | Audio processing and generation |
setup-env/ | Environment setup guides for Google Cloud |
RESOURCES.md | Curated list of additional resources |
Latest: Gemini 3.1 Pro
The repository stays current with Google's latest model releases. The newest addition:
gemini/getting-started/intro_gemini_3_1_pro.ipynb
The Google Cloud AI Ecosystem
This repo is the hub of a massive ecosystem of related repositories:
Agent Development
- ADK Samples — Ready-to-use agents built with the Agent Development Kit
- Agent Starter Pack — Production-ready GenAI Agent templates with deployment, operations, evaluation, and observability
Gemini & API
- Gemini Cookbook — Examples and guides for the Gemini API
- Gemini by Example — Practical Gemini examples
Applied AI
- Applied AI Engineering — Google Cloud Applied AI Engineering samples
- GenMedia Creative Studio — Generative media foundational models + custom workflows
- MCP Servers for GenMedia — Empower agents with generative media tools
Industry Solutions
- GenAI for Marketing — Marketing-focused generative AI
- GenAI for Developers — Developer productivity with generative AI
Infrastructure
- AI on GKE — AI workloads on Google Kubernetes Engine
- AI Infra Cluster Provisioning — Cluster provisioning for AI
- Terraform GenAI — Infrastructure as code for GenAI
Vertex AI Core
- Vertex AI Samples — Core Vertex AI samples
- MLOps with Vertex AI — ML operations workflows
Conversational & Document AI
- Contact Center AI — Customer service AI
- Document AI — Document processing with AI
Quick Start
git clone https://github.com/GoogleCloudPlatform/generative-ai.git
cd generative-ai
# Set up your environment
cd setup-env
# Follow setup instructions for your Google Cloud project
# Try the Gemini 3.1 Pro intro notebook
cd ../gemini/getting-started
jupyter notebook intro_gemini_3_1_pro.ipynb
Google Cloud Generative AI vs Alternatives
Category: This is an official cloud platform AI sample repository.
| Feature | GCP Generative AI | Gemini Cookbook | Azure OpenAI Samples |
|---|---|---|---|
| Focus | Full Google Cloud AI platform | Gemini API examples | Azure OpenAI service |
| Stars | 14K ⭐ | 16.7K ⭐ | 1.3K ⭐ |
| License | Apache 2.0 | Apache 2.0 | MIT |
| Language | Jupyter Notebook | Jupyter Notebook | Jupyter Notebook |
| Contributors | 303 | 100+ | 30+ |
| Maintained by | GoogleCloudPlatform | google-gemini | Azure-Samples |
| Gemini Models | ✅ Full Vertex AI | ✅ Gemini API | ❌ |
| OpenAI Models | ❌ | ❌ | ✅ GPT-4/GPT-4o |
| RAG & Grounding | ✅ Dedicated directory | ✅ | ✅ |
| Vision/Image | ✅ Gen/Edit/Caption/VQA | ✅ | ❌ |
| Audio | ✅ | ✅ | ❌ |
| Search | ✅ Vertex AI Search | ❌ | ✅ Azure AI Search |
| Agent Development | ✅ ADK + Starter Pack | ✅ | ✅ |
| MCP Integration | ✅ GenMedia MCP | ❌ | ❌ |
| Industry Solutions | ✅ Marketing, Developers | ❌ | ❌ |
| Infrastructure/Terraform | ✅ GKE, Terraform | ❌ | ✅ ARM |
| MLOps | ✅ Vertex AI MLOps | ❌ | ✅ |
| Contact Center AI | ✅ | ❌ | ❌ |
| Document AI | ✅ | ❌ | ✅ Azure Doc Intelligence |
| Ecosystem Size | ✅ 20+ related repos | Standalone | 10+ related repos |
| Cloud Platform | Google Cloud | Cloud-agnostic API | Azure |
When to choose GCP Generative AI: You're building on Google Cloud and need official, enterprise-grade samples covering the full Vertex AI platform — from Gemini models to search, RAG, vision, audio, agents, MLOps, and infrastructure. The 20+ related repo ecosystem is unmatched.
When to choose Gemini Cookbook: You want to use the Gemini API directly without the Google Cloud platform layer. Lighter, more API-focused, works anywhere with just an API key.
When to choose Azure OpenAI Samples: You're building on Azure and need samples for Azure OpenAI Service with GPT-4, Azure AI Search, and Azure infrastructure.
Conclusion
GoogleCloudPlatform/generative-ai is Google Cloud's central hub for generative AI development. With 303 contributors, coverage of every Vertex AI capability (Gemini, Search, RAG, Vision, Audio), and an ecosystem of 20+ related repositories spanning agents, MLOps, industry solutions, and infrastructure — this repository is the starting point for any enterprise building generative AI on Google Cloud. The latest Gemini 3.1 Pro notebooks ensure you're always working with the cutting edge.
Explore Google Cloud Generative AI on GitHub
