Google Vertex AI Integration
This guide provides detailed instructions for integrating Google Vertex AI with NudgeBee's LLM Server and RAG Server applications.
Overview
Google Vertex AI is a unified platform that brings together Google Cloud's machine learning tools for training and deploying ML models and building AI applications. For language models, Vertex AI offers both pre-trained foundation models through its Model Garden and the ability to deploy custom models.
Prerequisites
- Google Cloud Platform account with billing enabled
- Google Cloud project with Vertex AI API enabled
- Service account with appropriate permissions
- Basic understanding of ML model deployment concepts
Setting up Google Vertex AI Credentials
-
Create a Google Cloud Project (or use an existing one):
- Go to the Google Cloud Console
- Click "Select a project" at the top of the page
- Click "New Project"
- Enter a name and select your organization
- Click "Create"
-
Enable the Vertex AI API:
- Go to API Library
- Search for "Vertex AI API"
- Click on the API and select "Enable"
-
Create a Service Account:
- Go to Service Accounts
- Click "Create Service Account"
- Enter name and description
- Add the following roles:
- "Vertex AI User"
- "Vertex AI Admin" (if you need to create resources)
- "Storage Object Admin" (for model artifacts)
- Create and download the JSON key file
Add it in NudgeBee (UI)
In Admin → Integrations → LLM → Add LLM Provider, choose vertexai and enter the LLM Model Name. Vertex AI authenticates with Application Default Credentials — the service account available to the LLM Server's pod — not an API key. The form still asks for an API Key; enter any placeholder, it is ignored. See Add an LLM Provider. Test Connection checks the configuration for Vertex AI but doesn't call the model, so send a test question to NuBi after saving.
Integrating with LLM Server (environment variables)
LLM_PROVIDER=vertexai
LLM_MODEL_NAME=<Vertex AI model name, e.g. gemini-2.5-flash>
LLM_PROVIDER_REGION=<your Vertex location, e.g. us-central1>
GOOGLE_CLOUD_PROJECT=<your project id>
The project comes from GOOGLE_CLOUD_PROJECT and the location from LLM_PROVIDER_REGION. Always set the region: if it's unset it falls back to us-west-2, which isn't a Vertex AI location for most models. Authentication uses the service account available to the pod (Application Default Credentials).
Integrating with RAG Server
EMBEDDINGS_PROVIDER=vertexai
EMBEDDINGS_MODEL_NAME=<embedding model, e.g. text-embedding-005>
EMBEDDINGS_PROVIDER_REGION=<your Vertex location, e.g. us-central1>
Set the region explicitly — EMBEDDINGS_PROVIDER_REGION also defaults to us-west-2.