AG
Gemini & Antigravity v2.6 Agentic Engineering Guide
Antigravity Architecture v2.6 CLI Verified: 2026-10

Antigravity CLI (agy) 2.6 Command Reference & CI/CD Automation Guide

Master the official Antigravity 2.6 CLI: Cross-surface chat sync (agy sync), Gemini 4 model routing, automated agentic test runners, and unified config management.

Author: AGY Agentic Architecture Group • Google GenAI & Antigravity 2.6 Engineering Spec

Antigravity 2.6 CI Automation Runner

scripts/run-agy-ci.sh

#!/usr/bin/env bash
set -euo pipefail

echo "==> [AGY-CI] Initializing Antigravity 2.6 Automation Runner..."
agy --version || { echo "Error: agy CLI not found in PATH"; exit 1; }

echo "==> [AGY-CI] Running environment preflight checks..."
agy doctor --json > /tmp/agy-doctor.json

echo "==> [AGY-CI] Executing non-interactive agentic validation via Gemini 4..."
agy run "Execute test suite and patch any regressions automatically" \
  --model gemini-4-argon \
  --non-interactive \
  --timeout 300 \
  --max-turns 15

echo "==> [AGY-CI] Workflow completed with exit code 0."

Introducing agy CLI 2.6

agy is the command-line interface to the Antigravity agentic engine. In Antigravity 2.6, agy introduces two milestone capabilities:

  1. Cross-Surface Chat Synchronization (agy sync): Seamlessly connects your terminal session with the standalone desktop app and your VS Code / Cursor IDE editor;
  2. Native Gemini 4 Model Routing: Switch effortlessly between the world’s #1 benchmark model (Gemini 4 Carbon) and the high-efficiency agentic workhorse (Gemini 4 Argon).

2.6 Command Reference Matrix

CategoryCommandFlags / OptionsTypical Use Case
Sync (v2.6)agy sync--surface [ide|desktop], --followReal-time session roaming between desktop & IDE
Diagnosticsagy doctor--verbose, --jsonVerify MCP connectivity, Node 26, and Gemini 4 auth
Executionagy run [prompt]--model gemini-4-argon, --timeoutExecute single-turn autonomous engineering task
Sessionsagy session--resume [id], --listResume or inspect long-horizon agentic conversations
Scaffoldingagy init--template [web|api|fullstack]Scaffold .agents workspace configurations
Configagy configget/set, --globalInspect or update ~/.gemini/config.json

Core Command Walkthrough

1. agy sync: Cross-Surface Chat Synchronization

# 1. Enable follow mode: terminal task updates stream directly to IDE panel
agy sync --surface ide --follow

# 2. List active cross-surface sessions and attach
agy sync --list
agy sync --attach <session-id>

2. agy run: Directing Gemini 4 Models

# Execute deep security audit with world #1 Gemini 4 Carbon
agy run "Audit SQL queries & JWT auth for replay attacks, then write regression tests" \
  --model gemini-4-carbon \
  --timeout 600

# Execute standard feature development with high-throughput Gemini 4 Argon
agy run "Implement responsive profile card component with Tailwind v4" \
  --model gemini-4-argon

3. agy doctor: Health Preflight

# Run comprehensive environment audit
agy doctor

# Output machine-readable JSON for CI gates
agy doctor --json > /tmp/agy-health.json

Configuration Schema: ~/.gemini/config.json

Antigravity 2.6 consolidates credentials and routing rules into ~/.gemini/config.json:

{
  "activeModel": "gemini-4-argon",
  "fallbackModel": "gemini-3-flash",
  "telemetry": true,
  "mcpDirectory": "~/.gemini/antigravity/mcp",
  "auth": {
    "provider": "google-ai-studio",
    "expires_in": 3599
  }
}