← Catalog

@3d24rd0/pi-antigravity-bridge

Antigravity's models in Pi, through Google's own agy CLI and ACP server: no reimplemented API, no impersonated client. Pi's tools reach the model, so it works in your repo. Subscription, no API key.

ExtensionProvider

Install

Install with PiG

pig install npm:@3d24rd0/pi-antigravity-bridge

Install with Pi

pi install npm:@3d24rd0/pi-antigravity-bridge
Review before installing

Packages run code with your permissions and influence agent behavior. Catalog inclusion is not a security audit. Review the source before installing a third-party package.

Pi manifest JSON

The pi field of package.json.

{
  "image": "https://cdn.jsdelivr.net/gh/3d24rd0/antigravity-bridge@main/assets/logo-1024.jpg",
  "extensions": [
    "./src/entry.ts"
  ]
}

README

Written by the package's publisher, shown as published in version 1.4.1 (README.md). PiG does not review it.

Antigravity Bridge

Antigravity Bridge

Google Antigravity as a Pi model provider.
Gemini 4 Argon, Gemini 4 Hydrogen, Gemini 3.8 Flash, Claude Sonnet 5.5 and Claude Opus 5.5 on the subscription you already pay for.

npm MIT Pi-native package

Built with Gentle-AI


What it does

Pi speaks to models. Antigravity only speaks through its own CLI and its own protocol. This package puts a provider in between:

   Pi  ──▶  Antigravity Bridge  ──▶  agy CLI  /  ACP server  ──▶  Google
             │
             └──◀ Pi's tools, served over a localhost MCP bridge
  • Two engines, chosen by the model name. -acp drives Google's official ACP server (images, native diff cards); -cli drives the stream-json agy CLI.
  • Pi's tools work. The model reads files, edits, runs commands and delegates to subagents through a localhost bridge — with real Pi cards, not text dumps.
  • No API key. It rides the Antigravity CLI and server you already signed into. No per-token billing, no key to paste.

Install

Pi

pi install npm:@3d24rd0/pi-antigravity-bridge

Gentle Shell

gentle-shell install npm:@3d24rd0/pi-antigravity-bridge

Then restart. /agy joins the command list and antigravity/ models appear in /model.

Install from git instead, or by hand
pi install git:github.com/3d24rd0/antigravity-bridge

By hand, in ~/.pi/agent/settings.json (Gentle Shell: ~/.gentle-shell/agent/settings.json):

{ "packages": ["git:github.com/3d24rd0/antigravity-bridge"] }

Use it

1. Pick a model. /model → anything under antigravity/. The suffix picks the engine; Pi's thinking toggle picks the reasoning level.

ModelEngineInputBest for
antigravity/gemini-4-argon-acpACPtext + imageDeep reasoning, native diff cards
antigravity/gemini-4-hydrogen-acpACPtext + imageLongest-horizon reasoning; the only model reaching xhigh
antigravity/gemini-3-8-flash-acpACPtext + imageLow latency, light quota use
antigravity/gemini-4-argon-cliCLItext + imageSame model, stream-json engine
antigravity/gemini-3-8-flash-cliCLItext + imageFast execution
antigravity/claude-sonnet-5-5-cliCLItext + imageBalanced speed and quality
antigravity/claude-opus-5-5-cliCLItext + imageAdvanced Claude reasoning

Claude models are CLI-only: the ACP server rejects non-Gemini models. On the CLI engine the prompt carries text only, so an attached image is staged on disk and the model is pointed at it.

The thinking toggle offers exactly the tiers agy lists for the model you picked: gemini-4-hydrogen goes up to xhigh, gemini-4-argon stops at high, and a model agy lists with a single tier has no toggle at all. The list follows agy's catalog, so agy update shows up after the next model refresh instead of waiting for a reload.

2. Check the wiring once.

/agy doctor     # driver state, CLI and server versions, paths, effective config
/agy quota      # what your subscription has left

3. Just talk. Provider turns, Pi tools, subagents and review all work. The first ACP turn downloads Google's server (~1.5 GB) and asks for a second Google sign-in — one time only, and the -cli models skip it entirely.

/agy

Bare /agy opens the settings menu. Every setting also exists as a subcommand, and Tab completes them:

/agy  doctor  auth  auth-manual  quota  clear  patch-cleanup
      mode  readonly  permissions  timeout  ask  stop  web  bridge  tools
      digest  system-prompt  model  thinking  agent
      tasks  artifacts  subagents  acp-bin  acp-update
/agy mode accept-edits|plan      # plan is refused, not faked (see Safety)
/agy readonly on|off             # refuse every provider turn
/agy permissions on|off          # native agy tool auto-approval
/agy timeout <1-1440|off>        # overall turn cap
/agy bridge all|mcp|none         # which Pi tools the model can call
/agy stop [runId-prefix]         # stop a running background AskAntigravity run
/agy tasks [tail <id>]           # background task logs of this conversation
/agy artifacts [open <n|name>]   # files this conversation produced or received

Background delegations

AskAntigravity is blocking by default. With background: true the call returns a bg_ run id at once and the detached agy -p keeps running: Esc does not kill it, and when it settles the full answer arrives as one message marked UNTRUSTED and carrying the conversationId resume handle. Up to four runs at a time, one per conversation, and /agy stop ends one (no argument = the only running one). A background run lives and dies with the Pi session: /new, /resume, /fork and /reload kill it silently, and print/json mode refuses it because the process exits before the answer could arrive.

Full reference, every flag and every environment variable: docs/how-it-works.md.

Safety, up front

  • agy runs its own tool loop and is not prompted by Pi by default. An Antigravity turn can execute commands and write files on this machine.
  • The approval gate is opt-in. AGY_APPROVALS=shadow routes mutating native tools through Pi's permission flow; headless sessions deny.
  • Read-only is enforced, never promised. Plan mode cannot be enforced upstream, so the bridge refuses provider turns instead of faking it. Use /agy readonly on, Pi's tool restrictions, or the gate.
  • Your credentials are never read. Auth checks ask whether acp_token.json exists (stat, never opened) and whether GEMINI_API_KEY is set (a boolean, never the value). When an agy update rewrites auth.type to a method this machine cannot satisfy, the bridge restores oauth-personal in ~/.gemini/antigravity-acp/settings.json — merging, so other keys survive — and says what it did. No credential file is opened, and nothing leaves the machine.

Details and threat model: docs/how-it-works.md#safety.

Requirements

(blank)(blank)
PiTested against 1.0+; peers are declared * (pi-coding-agent, pi-tui, pi-ai, typebox)
Node≥ 22
Antigravity CLIagy, signed in once (required by the CLI engine and by AskAntigravity)
Google accountwith Antigravity access; ACP additionally asks its own sign-in

Development

git clone https://github.com/3d24rd0/antigravity-bridge
cd antigravity-bridge && npm install
npm run check      # tsc --noEmit + vitest

The package ships TypeScript and Pi loads it directly: no build step, so src/ is published as written. Pi finds the entry point through pi.extensions in package.json.

Acknowledgements

Based on the original extension by @EstebanForge. Licensed under MIT.