agy-subagent-mcp
Provides integration with Google Antigravity (Gemini) through the agy CLI, enabling codebase exploration, multi-file code generation, and general technical Q&A using Gemini models.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@agy-subagent-mcpUse agy_research to analyze the authentication flow in this repository."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
agy-subagent-mcp
Run Google Antigravity (Gemini) as an autonomous subagent inside Claude Code.
agy-subagent-mcp is a Model Context Protocol (MCP) server that exposes Google Antigravity (agy CLI) as callable tools for Claude Code. Claude can delegate tasks—such as codebase exploration, architecture analysis, second opinions, and multi-file code generation—to Gemini without needing external API keys or cloud credentials.
Why Use This?
Zero API Keys Required: Leverages your existing local
agyauthentication.Access to Gemini Models: Use Gemini 3.8 Flash, Gemini 3.1 Pro, and other models alongside Claude.
Safety First:
agy_researchruns sandboxed (read-only against real files; edits redirected to scratch).agy_generateis opt-in (AGY_ALLOW_WRITES=1) to prevent unsupervised file modifications.
Standard MCP Protocol: Compatible with Claude Code, Claude Desktop, and any other MCP-compliant client.
Related MCP server: antigravity-claude-mcp
Tools Exposed
Tool | Mode | Description |
| Sandboxed (Read-only) | Explores the codebase, searches files, reads implementations, and traces architecture. Cannot modify your working tree. |
| Unsandboxed (Write access) | Performs multi-step code generation, writes files, and runs shell commands. Disabled by default unless |
| Sandboxed | Ask Gemini general technical questions, brainstorm solutions, or get a second opinion. |
Prerequisites
Antigravity CLI (
agy):curl -fsSL https://antigravity.google/cli/install.sh | bashVerify with:
agy --versionPython 3.10+ (tested on macOS / Linux).
Installation & Setup
1. Clone the Repository
git clone https://github.com/naren-m/agy-subagent-mcp.git ~/Projects/agy-subagent-mcp
cd ~/Projects/agy-subagent-mcp2. Create Virtual Environment & Install Dependencies
python3 -m venv .venv
./.venv/bin/pip install -r requirements.txt3. Register with Claude Code
Add the server to your user-wide Claude Code configuration:
claude mcp add --scope user agy-subagent -- \
/Users/$USER/Projects/agy-subagent-mcp/.venv/bin/python3 \
/Users/$USER/Projects/agy-subagent-mcp/server.pyVerify that the server is connected:
claude mcp listConfiguration
You can configure options via environment variables using claude mcp set-env:
# Change default model
claude mcp set-env agy-subagent AGY_MODEL=gemini-3.1-pro-high
# Increase timeout (seconds)
claude mcp set-env agy-subagent AGY_TIMEOUT=600
# Enable unsupervised code generation (agy_generate)
claude mcp set-env agy-subagent AGY_ALLOW_WRITES=1Available Environment Variables
Variable | Default | Description |
|
| Path to the Antigravity CLI binary |
|
| Default Gemini model to invoke |
|
| Execution timeout in seconds |
|
| Set to |
Example Usage in Claude Code
Once registered, you can prompt Claude naturally:
"Use
agy_researchto analyze how authentication and sessions are handled in this repository."
"Ask
agy_askto compare CRDTs and Operational Transformation for collaborative text editing."
"Use
agy_generateto implement unit tests for the parser module." (requiresAGY_ALLOW_WRITES=1)
License
MIT © Naren Mudivarthy
This server cannot be deployed
Maintenance
Related MCP Connectors
Use Claude, ChatGPT, Grok Bot or Muse from the agent you are in: hand it a task, get the work back.
1Agent personas for Claude. 16 tools, 13 personas, 3 workflows. Zero extra API cost. Free.
Multiple Google accounts (Gmail, Calendar, Drive, Contacts, Tasks) in one Claude connector.
Multiple Google accounts (Gmail, Calendar, Drive, Contacts, Tasks) in one Claude connector.
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables Claude Code to consult Gemini for complex coding problems with session management, file attachments, and conversation persistence.106MIT
- AlicenseAqualityDmaintenanceEnables Claude Code to request independent code reviews and second opinions from other AI models (like Gemini, GPT-OSS) via the Antigravity CLI, directly from the chat.178 npmMIT
- AlicenseAqualityAmaintenanceEnables Claude Code and Claude Desktop to delegate token-heavy tasks to Antigravity headless subagents, offloading file edits, test runs, and exploration while preserving Claude's context window.1212 npm1MIT
- FlicenseNot gradedqualityAmaintenanceEnables Claude Code to escalate complex code analysis tasks to Google's Gemini AI for execution-flow tracing, cross-system impact analysis, performance bottleneck detection, hypothesis testing, and AI-to-AI conversational debugging over large codebases, logs, and traces.-