A collection of guides and examples for Generative AI on Vertex AI.
Explore more in the Generative AI Repository on GitHub.
Gemini Quickstarts
-
Intro to Gemini 2.0 Flash
Get started with Gemini 2.0 in Vertex AI with the Gen AI Python SDK.
Function Calling Gemini Grounding Multimodal Prompting
View on GitHub -
Getting Started with the Multimodal Live API
Get started with Gemini 2.0 Flash Multimodal Live API in Vertex AI using the Gen AI Python SDK
Gemini Live API Multimodal
View on GitHub -
Getting Started with Gemini 2.0 Flash Thinking Mode
Get started with Gemini 2.0 Flash Thinking Mode in Vertex AI using the Gen AI Python SDK to get more detailed reasoning and thinking steps.
Gemini Multimodal
View on GitHub -
Intro to Prompt Engineering
Learn the essentials and best practices of prompt engineering.
Gemini Prompting
View on GitHub -
Function Calling with Gemini
Connect Gemini to external tools using function calling.
Function Calling Gemini
View on GitHub -
Grounding with Gemini
Connect Gemini to real-world data from Google Search or Vertex AI Search to improve response quality.
Gemini Grounding RAG Search
View on GitHub -
Batch Prediction with Gemini
Use Batch Prediction to run inference on a large number of examples.
Batch Prediction Gemini
View on GitHub -
Long Context Window
Use the Long Context Window to process large amounts of multimodal data.
Gemini
View on GitHub -
-
Intro to Controlled Generation with the Gemini API
Learn to control Gemini API output formats for easier data processing.
Gemini
View on GitHub -
Call Gemini by using the OpenAI Library
Learn how to call Gemini using Chat Completions.
Gemini
View on GitHub
Featured Tutorials
-
Creating Marketing Assets using Gemini 2.0 Flash
Learn how to combine the multimodal capabilities of Gemini and Grounding with Google Search to create a marketing campaign brief and marketing assets.
Gemini Grounding Search
View on GitHub -
Get started with Chirp 2 for Speech-to-Text
Learn about how to use Chirp 2, the latest generation of Google's multilingual Automatic Speech Recognition models.
Chirp Speech
View on GitHub -
Intro to Imagen 3 Image Generation
Use Imagen 3 to create photorealistic images.
Imagen Multimodal
View on GitHub -
Imagen 3 Image Editing
Use Imagen 3 to edit photorealistic images using inpainting, outpainting, and Product Image Editing.
Imagen Multimodal
View on GitHub -
Get Started with Text Embeddings + Vertex AI Vector Search
Use AI's multitool, Embeddings, and Vertex AI Vector Search perform semantic matching.
Embeddings Vector Search
View on GitHub -
Intro to LangGraph with Gemini
Learn how to combine LangGraph's workflow capabilities with Gemini's language understanding and generation skills to streamline and automate complex financial analysis tasks.
Gemini LangChain LangGraph Orchestration
View on GitHub -
Create custom podcast episodes
Use Gemini, LangGraph, and Text-to-Speech to create custom podcast episodes.
Gemini LangChain LangGraph Orchestration Speech
View on GitHub -
Storytelling with Gemini and Text-to-Speech
Use Gemini and Text-to-Speech to create and read a story with multiple characters.
Gemini Speech
View on GitHub -
Analyze a codebase
Use Gemini to generate code, summarize a codebase, debug, improve code, and assess code.
Gemini Multimodal
View on GitHub -
LLM Security for developers
Learn about prompt injection attacks and how to mitigate them.
Gemini Prompting Security
View on GitHub -
Gen AI Evaluation Service
Evaluate Gemini responses using metrics and custom datasets.
Evaluation Gemini
View on GitHub -
Supervised Fine-tuning with Gemini
Learn how to fine-tune Gemini for specific tasks.
Gemini Tuning
View on GitHub -
Intro to Vertex AI RAG Engine
Build custom RAG workflows with Gemini and Vertex AI RAG Engine.
Gemini RAG
View on GitHub -
Document Processing with Gemini
Use Gemini to process documents for classification, extraction, and summarization.
Gemini Multimodal
View on GitHub -
Patents Document Understanding with Gemini 2.0
Use Gemini 2.0 Flash to process patent documents using classification, entity extraction, and object detection.
Gemini Multimodal
View on GitHub
All Tutorials
Function Calling
Gemini
Grounding
Multimodal
Prompting
|
Intro to Gemini 2.0 Flash Get started with Gemini 2.0 in Vertex AI with the Gen AI Python SDK. |
View on GitHub |
Gemini
Live API
Multimodal
|
Getting Started with the Multimodal Live API Get started with Gemini 2.0 Flash Multimodal Live API in Vertex AI using the Gen AI Python SDK |
View on GitHub |
Gemini
Multimodal
|
Getting Started with Gemini 2.0 Flash Thinking Mode Get started with Gemini 2.0 Flash Thinking Mode in Vertex AI using the Gen AI Python SDK to get more detailed reasoning and thinking steps. |
View on GitHub |
Gemini
Prompting
|
Intro to Prompt Engineering Learn the essentials and best practices of prompt engineering. |
View on GitHub |
Function Calling
Gemini
|
Function Calling with Gemini Connect Gemini to external tools using function calling. |
View on GitHub |
Gemini
Grounding
RAG
Search
|
Grounding with Gemini Connect Gemini to real-world data from Google Search or Vertex AI Search to improve response quality. |
View on GitHub |
Batch Prediction
Gemini
|
Batch Prediction with Gemini Use Batch Prediction to run inference on a large number of examples. |
View on GitHub |
Gemini
|
Long Context Window Use the Long Context Window to process large amounts of multimodal data. |
View on GitHub |
Gemini
|
Intro to Context Caching Use context caching to store frequently used data. |
View on GitHub |
Gemini
|
Intro to Controlled Generation with the Gemini API Learn to control Gemini API output formats for easier data processing. |
View on GitHub |
Gemini
|
Call Gemini by using the OpenAI Library Learn how to call Gemini using Chat Completions. |
View on GitHub |
Gemini
Grounding
Search
|
Creating Marketing Assets using Gemini 2.0 Flash Learn how to combine the multimodal capabilities of Gemini and Grounding with Google Search to create a marketing campaign brief and marketing assets. |
View on GitHub |
Chirp
Speech
|
Get started with Chirp 2 for Speech-to-Text Learn about how to use Chirp 2, the latest generation of Google's multilingual Automatic Speech Recognition models. |
View on GitHub |
Imagen
Multimodal
|
Intro to Imagen 3 Image Generation Use Imagen 3 to create photorealistic images. |
View on GitHub |
Imagen
Multimodal
|
Imagen 3 Image Editing Use Imagen 3 to edit photorealistic images using inpainting, outpainting, and Product Image Editing. |
View on GitHub |
Embeddings
Vector Search
|
Get Started with Text Embeddings + Vertex AI Vector Search Use AI's multitool, Embeddings, and Vertex AI Vector Search perform semantic matching. |
View on GitHub |
Gemini
LangChain
LangGraph
Orchestration
|
Intro to LangGraph with Gemini Learn how to combine LangGraph's workflow capabilities with Gemini's language understanding and generation skills to streamline and automate complex financial analysis tasks. |
View on GitHub |
Gemini
LangChain
LangGraph
Orchestration
Speech
|
Create custom podcast episodes Use Gemini, LangGraph, and Text-to-Speech to create custom podcast episodes. |
View on GitHub |
Gemini
Speech
|
Storytelling with Gemini and Text-to-Speech Use Gemini and Text-to-Speech to create and read a story with multiple characters. |
View on GitHub |
Gemini
Multimodal
|
Analyze a codebase Use Gemini to generate code, summarize a codebase, debug, improve code, and assess code. |
View on GitHub |
Gemini
Prompting
Security
|
LLM Security for developers Learn about prompt injection attacks and how to mitigate them. |
View on GitHub |
Evaluation
Gemini
|
Gen AI Evaluation Service Evaluate Gemini responses using metrics and custom datasets. |
View on GitHub |
Gemini
Tuning
|
Supervised Fine-tuning with Gemini Learn how to fine-tune Gemini for specific tasks. |
View on GitHub |
Gemini
RAG
|
Intro to Vertex AI RAG Engine Build custom RAG workflows with Gemini and Vertex AI RAG Engine. |
View on GitHub |
Gemini
Multimodal
|
Document Processing with Gemini Use Gemini to process documents for classification, extraction, and summarization. |
View on GitHub |
Gemini
Multimodal
|
Patents Document Understanding with Gemini 2.0 Use Gemini 2.0 Flash to process patent documents using classification, entity extraction, and object detection. |
View on GitHub |
Gemini
Multimodal
|
Intro to the Google Gen AI SDK Intro to the Google Gen AI SDK. |
View on GitHub |
Gemini
Multimodal
Prompting
|
Gemini with Multimodal Data How to prompt Gemini with multimodal data (text, documents, images, video, and audio). |
View on GitHub |
Gemini
|
Getting started with Gemini 2.0 in Vertex AI using REST API Use Gemini 2.0 with REST/curl. |
View on GitHub |
Evaluation
Gemini
Prompting
|
Prompt Engineering, Evaluation, and Prompt Templating Use Gen AI Evaluation Service SDK for prompt engineering and evaluation. |
View on GitHub |
Embeddings
Multimodal
|
Intro to Multimodal Embeddings Learn about multimodal embeddings. |
View on GitHub |
Embeddings
Tuning
|
Intro to Embeddings Tuning Learn how to tune embeddings models. |
View on GitHub |
Embeddings
Vector Search
|
Task Type Embeddings Learn how to get better embeddings for your specific task. |
View on GitHub |
Embeddings
Vector Search
|
Hybrid Search with Vertex AI Vector Search Learn how to use hybrid search with Vertex AI Vector Search combining semantic & keyword search. |
View on GitHub |
Agents
Gemini
LangChain
LangGraph
|
AI Agents for Engineers (Evolution of AI Agents) This notebook demonstrates 3 different approaches to generating essays using the Gemini API, Zero-Shot, Step-by-Step with LangChain, and Iterative with LangGraph. |
View on GitHub |
Gemma
Hugging Face
|
Hugging Face DLCs: Serving Gemma with Text Generation Inference (TGI) on Vertex AI Learn how to deploy Google Gemma from the Hugging Face Hub on Vertex AI using the Hugging Face Deep Learning Container (DLC) for Text Generation Inference (TGI). |
View on GitHub |
Gemma
LangChain
RAG
|
Cloud Run GPU Inference: Gemma 2 RAG Q&A with Ollama and LangChain Learn how to deploy Gemma 2 in Cloud Run to build a simple RAG Q&A application. |
View on GitHub |
Gemma
Hugging Face
|
Hugging Face DLCs: Serving PaliGemma using Pytorch Inference on Vertex AI with Custom Handler Learn how to deploy Google PaliGemma from the Hugging Face Hub on Vertex AI using the Hugging Face Deep Learning Container (DLC) for Pytorch Inference in combination with a custom handler. |
View on GitHub |
Gemma
Hugging Face
Tuning
|
Hugging Face DLCs: Fine-tuning Gemma with Transformer Reinforcement Learning (TRL) on Vertex AI Learn how to fine-tune Gemma with Transformer Reinforcement Learning (TRL) on Vertex AI. |
View on GitHub |
Hugging Face
|
Guess who or what app using Hugging Face Deep Learning container model on Vertex AI Create a"Guess who or what" application using Vertex AI, Hugging Face Deep Learning container, an image generation open model, and Gemini to solve and visualize riddles. |
View on GitHub |
Embeddings
|
Visualizing embedding similarity from text documents using t-SNE plots Visualize embedding similarity from text documents using t-SNE plots. |
View on GitHub |
Embeddings
Vector Search
|
Vertex AI Vector Search Quickstart Learn how to use Vertex AI Vector Search to find similar text documents. |
View on GitHub |
Embeddings
Gemini
Vector Search
|
Anomaly Detection of Infrastructure Logs using Gemini and BigQuery Vector Search Learn how to large volumes of infrastructure logs using Gemini, vector embeddings and BigQuery Vector Search to perform anomaly detection. |
View on GitHub |
Embeddings
Gemini
|
Log Anomaly Detection & Investigation with Text Embeddings + BigQuery Vector Search Learn how to large volumes of audit logs using Gemini, vector embeddings and BigQuery Vector Search to perform anomaly detection. |
View on GitHub |
Function Calling
Gemini
|
Working with Data Structures and Schemas in Gemini Function Calling Learn how to use Gemini Function Calling with data structures and schemas. |
View on GitHub |
Function Calling
Gemini
|
Working with Parallel Function Calls and Multiple Function Responses in Gemini Learn how to use parallel function calls and multiple function responses in Gemini. |
View on GitHub |
Function Calling
Gemini
Prompting
|
Introduction to ReAct Agents with Gemini & Function Calling Learn how to use ReAct Agents with Gemini and Function Calling. |
View on GitHub |
Function Calling
Gemini
|
Forced Function Calling with Tool Configurations in Gemini Learn how to use forced function calling with tool configurations in Gemini. |
View on GitHub |
Function Calling
Gemini
|
Using Gemini Function Calling to Get Real-Time Company News and Insights Learn how to use Gemini Function Calling to get real-time company news and insights. |
View on GitHub |
Function Calling
Gemini
Multimodal
|
Multimodal Function Calling with the Gemini API & Python SDK Learn how to use Gemini Multimodal Function Calling. |
View on GitHub |
Gemini
RAG
RAG Engine
|
Advanced RAG Techniques - Vertex RAG Engine Retrieval Quality Evaluation and Hyperparameters Tuning Learn about advanced RAG techniques with evaluation and hyperparameter tuning. |
View on GitHub |
Gemini
RAG
RAG Engine
|
Vertex AI RAG Engine with Pinecone Learn how to use Pinecone with Vertex AI RAG Engine. |
View on GitHub |
Gemini
RAG
RAG Engine
|
Vertex AI RAG Engine with Weaviate Learn how to use Weaviate with Vertex AI RAG Engine. |
View on GitHub |
Gemini
RAG
RAG Engine
|
Vertex AI RAG Engine with Vertex AI Feature Store Learn how to use Vertex AI Feature Store with Vertex AI RAG Engine. |
View on GitHub |
Gemini
RAG
RAG Engine
|
Vertex AI RAG Engine with Vertex AI Vector Search Learn how to use Vertex AI Vector Search with Vertex AI RAG Engine. |
View on GitHub |
Gemini
RAG
RAG Engine
|
Vertex AI RAG Engine with Vertex AI Search Learn how to use Vertex AI Search with Vertex AI RAG Engine. |
View on GitHub |
Agents
Gemini
Reasoning Engine
|
Debugging and Optimizing Agents: A Guide to Tracing in Reasoning Engine Learn how to use Tracing in Reasoning Engine. |
View on GitHub |
Gemini
LangChain
Reasoning Engine
|
Deploying a RAG Application with AlloyDB to LangChain on Vertex AI |
View on GitHub |
Agents
Gemini
RAG
Reasoning Engine
Search
|
Building a Conversational Search Agent with Reasoning Engine and RAG on Vertex AI Search |
View on GitHub |
Agents
Gemini
Reasoning Engine
|
Intro to Building and Deploying an Agent with Reasoning Engine in Vertex AI |
View on GitHub |
Agents
Gemini
LangGraph
RAG
Reasoning Engine
|
Building a Multi-Agent RAG Application with LangGraph and Reasoning Engine |
View on GitHub |
Gemini
LangGraph
RAG
Reasoning Engine
|
Deploying a RAG Application with Cloud SQL for PostgreSQL to LangChain on Vertex AI |
View on GitHub |
Agents
Gemini
Reasoning Engine
|
Building and Deploying a Google Maps API Agent with Reasoning Engine |
View on GitHub |
Gemini
LangGraph
Reasoning Engine
|
Building and Deploying a LangGraph Application with Reasoning Engine in Vertex AI |
View on GitHub |
Gemini
Multimodal
|
Gemini 1.5: A workshop in multimodal use cases |
View on GitHub |
Gemini
Multimodal
|
Video Analysis with Gemini |
View on GitHub |
Gemini
Multimodal
|
YouTube Video Analysis with Gemini |
View on GitHub |
Gemini
Multimodal
Vector Search
|
Building a Multimodal Chatbot for Warranty Claims using Gemini and Vector Search in Vertex AI |
View on GitHub |
Gemini
Multimodal
RAG
|
Multimodal Retrieval Augmented Generation (RAG) using Gemini API in Vertex AI |
View on GitHub |
Gemini
LlamaIndex
RAG
|
LlamaIndex with Vertex AI Vector Search to perform question answering RAG |
View on GitHub |
Gemini
LangChain
Multimodal
RAG
|
Multimodal Retrieval Augmented Generation (RAG) with Gemini, Vertex AI Vector Search, and LangChain |
View on GitHub |
Gemini
RAG
|
Small-to-big Retrieval-Augmented Generation |
View on GitHub |
Gemini
Prompting
|
ReAct (Reasoning + Acting) + Custom tool for Healthcare NL API + Gemini 1.5 Pro + LangChain |
View on GitHub |
Gemini
Prompting
|
Using Gemini in Education |
View on GitHub |
Gemini
Prompting
|
AI Quick Build Experience |
View on GitHub |
Gemini
Multimodal
RAG
|
Code Retrieval Augmented Generation (RAG) with Gemini API |
View on GitHub |
Gemini
Multimodal
|
Product listing generation with Gemini 1.5 Pro |
View on GitHub |
Gemini
Multimodal
|
Multimodal retail recommendation: using Gemini to recommend items based on images and image reasoning |
View on GitHub |
Gemini
Multimodal
Prompting
|
Sheet Music Analysis with Gemini |
View on GitHub |
Gemini
Multimodal
|
Analyzing movie posters in BigQuery with Gemini 1.5 Flash |
View on GitHub |
Gemini
LangChain
|
Getting Started with LangChain 🦜️🔗 + Gemini API in Vertex AI |
View on GitHub |
Agents
Gemini
|
Building a Weather Agent with AutoGen and Gemini |
View on GitHub |
Gemini
Prompting
|
Vertex AI Prompt Optimizer Notebook UI |
View on GitHub |
Gemini
Prompting
|
Vertex AI Prompt Optimizer - Tool usage |
View on GitHub |
Gemini
Prompting
|
Vertex AI Prompt Optimizer - Custom metric |
View on GitHub |
Gemini
Prompting
|
Intro to Vertex AI Prompt Optimizer |
View on GitHub |
Gemini
Prompting
|
Text Summarization with Generative Models on Vertex AI |
View on GitHub |
Gemini
Prompting
|
Ideation with Generative Models on Vertex AI |
View on GitHub |
Gemini
Prompting
|
Chain of Thought & ReAct |
View on GitHub |
Gemini
Prompting
|
Question Answering with Generative Models on Vertex AI |
View on GitHub |
Gemini
Prompting
|
Text Classification with Generative Models on Vertex AI |
View on GitHub |
Gemini
Prompting
|
Text Extraction with Generative Models on Vertex AI |
View on GitHub |
Gemini
Tuning
|
Supervised Fine Tuning with Gemini 1.5 Flash for Change Detection |
View on GitHub |
Gemini
Tuning
|
Vertex AI Supervised Tuning Token Count and Cost Estimation |
View on GitHub |
Gemini
Tuning
|
Supervised Fine-Tuning with Gemini 1.5 Flash for Q&A |
View on GitHub |
Gemini
Tuning
|
Supervised Fine Tuning with Gemini 1.5 Pro for Image Captioning |
View on GitHub |
Evaluation
Gemini
Model Garden
|
Use Gen AI Evaluation SDK to Evaluate Models in Vertex AI Studio, Model Garden, and Model Registry |
View on GitHub |
Evaluation
Gemini
RAG
|
Evaluate Generated Answers from RAG using Rapid Evaluation and Dataflow ML with Vertex AI Pipelines |
View on GitHub |
Evaluation
Gemini
|
Enhancing Quality and Explainability with Vertex AI Evaluation |
View on GitHub |
Evaluation
Gemini
|
Evaluate and Compare Gen AI Model Settings |
View on GitHub |
Evaluation
Gemini
|
Bring-Your-Own-Autorater using Custom Metrics |
View on GitHub |
Evaluation
Gemini
|
Evaluate a Translation Model |
View on GitHub |
Evaluation
Gemini
|
Compare and Migrate from PaLM to Gemini Model |
View on GitHub |
Evaluation
Gemini
Multimodal
|
Evaluating Multimodal Tasks |
View on GitHub |
Evaluation
Gemini
LangChain
|
Evaluate LangChain |
View on GitHub |
Evaluation
Gemini
|
Compare Generative AI Models |
View on GitHub |
Evaluation
Gemini
RAG
|
Evaluate Generated Answers from RAG for QA with Gen AI Evaluation Service SDK |
View on GitHub |
Evaluation
Gemini
|
Customize Model-based Metrics to Evaluate a Gen AI Model |
View on GitHub |
Evaluation
Gemini
RAG
|
Evaluate Generative Model Tool Use |
View on GitHub |
Evaluation
Gemini
|
Get Started with Generative AI Evaluation Service |
View on GitHub |
Gemini
Prompting
RAG
Security
|
Gen AI and LLM Security - ReAct and RAG Attacks & Mitigations |
View on GitHub |
Gemini
Security
|
Responsible AI with Gemini API in Vertex AI: Safety Ratings and Thresholds |
View on GitHub |
Batch Prediction
Gemini
|
Monitor Batch Prediction with Gemini API |
View on GitHub |
Batch Prediction
Gemini
|
Intro to Batch Predictions with the Gemini API using BigQuery Input |
View on GitHub |
Imagen
Multimodal
|
Imagen 3 Customized Images |
View on GitHub |
Gemini
Imagen
Multimodal
|
Create High Quality Visual Assets with Imagen and Gemini |
View on GitHub |
Imagen
Multimodal
|
Create a Photoshop Document with Image Segmentation on Vertex AI |
View on GitHub |
Gemini
Imagen
Multimodal
|
Enhance Imagen Prompts with Gemini |
View on GitHub |
Imagen
Multimodal
|
Image Segmentation on Vertex AI |
View on GitHub |
Search
|
Vertex AI Search with Filters & Metadata |
View on GitHub |
Gemini
Search
|
Vertex AI Search - Querying Blended Data Apps and Summarization with Gemini |
View on GitHub |
Search
|
Create a Vertex AI Search Datastore and Search Engine |
View on GitHub |
Search
|
Building Search Applications with Vertex AI Search |
View on GitHub |
Gemini
LangChain
RAG
Search
|
Question Answering Over Documents |
View on GitHub |
Gemini
RAG
Search
|
Bulk Question Answering with Vertex AI Search |
View on GitHub |
Embeddings
Search
|
Custom Embeddings with Vertex AI Search |
View on GitHub |
Chirp
Speech
|
Get Started with Chirp 2 - Advanced Features |
View on GitHub |
Claude
Function Calling
Model Garden
|
Multimodal Function Calling with Claude Models |
View on GitHub |
Agents
Search
|
Vertex AI Search and Conversation Data Store Status Checker |
View on GitHub |
Agents
Gemini
|
Building a Research Multi Agent System - a Design Pattern Overview with Gemini 2.0 |
View on GitHub |
Code Execution
Gemini
|
Intro to Generating and Executing Python Code with Gemini 2.0 |
View on GitHub |
Agents
Evaluation
Gemini
|
Evaluating Agents - Evaluate a CrewAI agent with Vertex AI Gen AI Evaluation |
View on GitHub |
Agents
Evaluation
Gemini
LangGraph
|
Evaluating Agents - Evaluate a LangGraph agent with Vertex AI Gen AI Evaluation |
View on GitHub |
Gemini
Live API
Multimodal
RAG
|
Interactive Loan Application Assistant (Financial Services) |
View on GitHub |
RAG
RAG Engine
Search
|
Vertex AI RAG Engine with Vertex AI Search |
View on GitHub |
Agents
Evaluation
Reasoning Engine
|
Evaluate a CrewAI agent on Vertex AI Reasoning Engine (Customized template) |
View on GitHub |
Agents
Evaluation
LangChain
Reasoning Engine
|
Evaluating a LangChain Agent on Vertex AI Reasoning Engine (Prebuilt template) |
View on GitHub |
Agents
Evaluation
LangGraph
Reasoning Engine
|
Evaluate a LangGraph agent on Vertex AI Reasoning Engine (Customized template) |
View on GitHub |
Gemini
Multimodal
Tuning
|
Supervised Fine Tuning with Gemini 1.5 Flash for change detection using the Google Gen AI SDK |
View on GitHub |
Gemini
Tuning
|
Supervised fine-tuning with Gemini 1.5 Flash for Q&A using the Google Gen AI SDK |
View on GitHub |
What's next
- Learn about LLMs, Vertex AI, and Generative AI models with Generative AI beginner's guide.
- Explore more resources in the Generative AI GitHub repo.