pi-vertex-ai-provider

Pi package that enables Google Vertex AI ADC auth and adds latest Gemini Vertex models.

Packages

Package details

extension

Install pi-vertex-ai-provider from npm and Pi will load the resources declared by the package manifest.

$ pi install npm:pi-vertex-ai-provider
Package
pi-vertex-ai-provider
Version
0.1.0
Published
May 20, 2026
Downloads
not available
Author
alyuslabs
License
MIT
Types
extension
Size
8.5 KB
Dependencies
0 dependencies · 2 peers
Pi manifest JSON
{
  "extensions": [
    "./src/index.ts"
  ]
}

Security note

Pi packages can execute code and influence agent behavior. Review the source before installing third-party packages.

README

pi-vertex-ai-provider

Pi package/extension that makes Pi's built-in google-vertex provider use Vertex AI Application Default Credentials (ADC) instead of an API key, plus registers gemini-3.5-flash until Pi ships it built-in.

Why extension, not a new provider?

Pi already ships an official google-vertex provider and model serializer for Gemini on Vertex AI, including streaming, tools/function calling, multimodal input, usage accounting, and thinking controls. This package keeps those built-in models, overrides provider auth/config so the official provider runs with Google Cloud ADC, and appends gemini-3.5-flash.

Setup

# 1) Install/login Google Cloud CLI
 gcloud auth login
 gcloud auth application-default login

# 2) Select project and optional location
 gcloud config set project YOUR_PROJECT_ID
 # Optional; defaults to global
 set GOOGLE_CLOUD_LOCATION=global

You can also configure without changing gcloud defaults:

set PI_VERTEX_AI_PROJECT=YOUR_PROJECT_ID
set PI_VERTEX_AI_LOCATION=global

Use with Pi

Install from npm:

pi install npm:pi-vertex-ai-provider

Or from GitHub:

pi install git:github.com/AlyusLabs/pi-vertex-ai-provider

For local development from this repo:

pi -e .

Then select a Vertex model such as:

google-vertex/gemini-3.5-flash
google-vertex/gemini-3-pro-preview
google-vertex/gemini-2.5-pro
google-vertex/gemini-2.5-flash

gemini-3.5-flash is registered with a 1,048,576-token context window, 65,536 max output tokens, thinking enabled, and base-tier Vertex pricing in Pi's usage display.

Check status

Inside Pi:

/vertex-ai-status

Environment variables

  • PI_VERTEX_AI_PROJECT - preferred project override.
  • PI_VERTEX_AI_LOCATION - preferred location override; defaults to global.
  • PI_VERTEX_AI_FORCE_ADC=0 - do not force-disable GOOGLE_CLOUD_API_KEY.

By default, the extension sets Pi's Vertex API-key marker (gcp-vertex-credentials) so Pi uses ADC/gcloud credentials, not API keys.