ralph-antigravity is a lightweight, Bash-based orchestrator designed to integrate the power of the Gemini CLI into specific Antigravity developer workflows.
Inspired by the "Ralph" methodology, it provides environment abstraction, context injection, and safety guardrails for autonomous coding tasks.
- Context Injection: Automatically gathers relevant source files and project rules to feed into Gemini.
- Safety First: Integrated Git checks to ensure you never run an autonomous task on a dirty worktree without a checkpoint.
- Rule-Based Guidance: Uses
.agrulesto define architectural patterns, build commands, and file restrictions. - Native Efficiency: Built as a set of Bash scripts for zero-latency execution and minimal dependencies.
-
Prerequisites:
- Install the Gemini CLI:
npm install -g @google/gemini-cli
- Ensure you are authenticated:
gemini /auth
- Install the Gemini CLI:
-
Setup:
- Clone this repository.
- Run the setup script for your platform:
- Windows (PowerShell):
.\setup.ps1
- macOS/Linux/Git Bash:
./setup.sh
- Windows (PowerShell):
- Restart your terminal.
Navigate to your Antigravity project root and run:
ag-code initag-code initThis creates a .agrules file where you can define your project-specific constraints.
Describe what you want to achieve:
ag-code run "Refactor the gravity-well component to use the new standard logger"The .agrules file is the brain of your project's Ralph-Antigravity implementation. Use it to tell Gemini about:
- Build Commands: e.g.,
ag build,ag test. - Standards: "Always use functional components in React."
- Strictures: "Don't touch anything in
src/internal/."
bin/ag-code: The main entry point.lib/context.sh: Logic for gathering project context.lib/gemini.sh: Integration with the@google/gemini-cli.lib/safety.sh: Git-based safety and reversible operations.lib/utils.sh: General helper functions.
To contribute or modify:
- Core logic is in
bin/ag-code. - Add new capabilities by creating new scripts in
lib/. - Ensure all scripts use LF line endings for compatibility.
Created for the Antigravity developer ecosystem.