Skip to main content
Prerequisite: Install the engram binary first via Homebrew or binary download.
Antigravity is Google’s AI-first IDE with native MCP and skill support.

Add the MCP Server

1

Open MCP Store

Click the ... dropdown in the agent panel → Manage MCP Servers
2

View raw config

Click View raw config
3

Edit mcp_config.json

Add to ~/.gemini/antigravity/mcp_config.json:
{
  "mcpServers": {
    "engram": {
      "command": "engram",
      "args": ["mcp"]
    }
  }
}
4

Save and restart

Save the file. Antigravity will reload the MCP servers automatically.
Without the Memory Protocol, the agent has the tools but doesn’t know WHEN to use them.

Option A: Global Rule

Add to ~/.gemini/GEMINI.md:
## Memory

You have access to Engram persistent memory via MCP tools (mem_save, mem_search, mem_session_summary, etc.).

- Save proactively after significant work — don't wait to be asked.
- After any compaction or context reset, call `mem_context` to recover session state before continuing.

Option B: Workspace Rule

Add to .agent/rules/engram-memory.md in your project:
## Engram Persistent Memory

You have access to Engram persistent memory via MCP tools.

### WHEN TO SAVE

Call `mem_save` IMMEDIATELY after:
- Bug fix completed
- Architecture or design decision made
- Non-obvious discovery about the codebase
- Configuration change or environment setup
- Pattern established (naming, structure, convention)
- User preference or constraint learned

### WHEN TO SEARCH

When the user asks to recall something ("remember", "what did we do").
Also search proactively when starting work that might overlap past sessions.

### SESSION CLOSE

Before ending, call `mem_session_summary` with:
- Goal
- Discoveries
- Accomplished
- Next Steps
- Relevant Files
See Memory Protocol for the full text.

Platform-Specific Notes

macOS / Linux

Config path: ~/.gemini/antigravity/mcp_config.json

Windows

Config path: %USERPROFILE%\.gemini\antigravity\mcp_config.json

Antigravity vs. VS Code

Antigravity has its own skill, rule, and MCP systems separate from VS Code.
Do not use .vscode/mcp.json with Antigravity. Use ~/.gemini/antigravity/mcp_config.json instead. Antigravity’s agent system:
  • Skills — Reusable knowledge bundles
  • Rules — Project-specific agent instructions
  • MCP — Tool integrations via stdio transport

Memory Protocol Behavior

With the Memory Protocol in GEMINI.md or .agent/rules/, the agent:
  • Saves proactively after bugfixes, decisions, discoveries, patterns
  • Searches reactively when you say “remember” or “what did we do”
  • Searches proactively when starting work that might overlap past sessions
  • Closes sessions with mem_session_summary before saying “done”
  • Recovers state after compaction with mem_context

Troubleshooting

MCP tools not available

Check MCP config:
# macOS/Linux
cat ~/.gemini/antigravity/mcp_config.json

# Windows
type %USERPROFILE%\.gemini\antigravity\mcp_config.json
Verify the engram server entry exists.

Binary not found

Antigravity can’t find engram command:
# Check PATH
echo $PATH

# Check binary location
which engram  # macOS/Linux
where engram  # Windows
If missing, install via Homebrew or binary download.

Agent doesn’t use memory

Check that global or workspace rules include the Memory Protocol:
# Global
cat ~/.gemini/GEMINI.md

# Workspace
cat .agent/rules/engram-memory.md

Next Steps

Build docs developers (and LLMs) love