1.0 KiB
1.0 KiB
Google Cloud & Vertex AI Authentication Setup for trollagent_gear
trollagent_gear connects to Google Cloud Vertex AI (or Google AI Studio) to query Gemini models (gemini-2.5-flash, gemini-1.5-flash, etc.) for tactical spatial navigation, obstacle avoidance, and health regeneration decisions.
Quick Setup Options
Option A: Application Default Credentials (ADC) - Recommended
# 1. Login with your Google Cloud account:
gcloud auth application-default login
# 2. Set your default project:
gcloud config set project YOUR_PROJECT_ID
export VERTEX_PROJECT_ID="YOUR_PROJECT_ID"
Option B: Direct API Key (Google AI Studio or Vertex AI)
export GEMINI_API_KEY="AIzaSy..."
# Or:
export VERTEX_API_KEY="AIzaSy..."
Option C: Service Account Key
export GOOGLE_APPLICATION_CREDENTIALS="/path/to/service-account.json"
export VERTEX_PROJECT_ID="YOUR_PROJECT_ID"
Verifying Authentication
Run the auth check directly by starting the bot with --help:
python3 trollagent_gear/bot.py --help