1:1 Minimalist Real-time Context Usage Meter & Zero-Loss Session Migration for Google Antigravity
High-precision local token tracking, HUD floating capsule, and smart continuity extraction.
English • 简体中文
Key Features • Showcase • Quick Start • Why We Built This • Benchmarks • Contributing
When using Google Antigravity for multi-turn autonomous coding tasks, developers frequently face these challenges:
- Context Window Blindspot: You never know when the token limit is reached until the agent begins hallucinating, forgetting earlier architecture decisions, or degrading.
- Checking Usage Wastes Tokens: Asking the agent
/contextin chat consumes valuable tokens and pollutes the conversation history. - Hard Context Transitions: When reaching 80%~90% capacity, manually summarizing everything to start a fresh chat is slow and prone to missing key decisions.
Antigravity Context Meter solves this completely, featuring zero-token local monitoring and 1-click zero-loss session migration.
- Dynamic Ring Meter: Real-time percentage display with 4-level health alerts (Optimal / Moderate / Warning / Critical).
- 4-Color Breakdown Bar: Clear visual breakdown for Rules (System), MCP (Tools), Messages (Chat), and Outputs (Tool dumps).
- Native macOS Immersion: Smooth
backdrop-filter: blur(28px)dark HUD with native hardware rendering.
- Powered entirely by local event-driven transcript streaming (
fs.watch+ SSE). - Zero API calls, Zero Prompts sent, 0 Token Cost.
- Ultra-fast hybrid tokenizer executes in 0.039 ms with 0.0% idle CPU footprint.
- Auto-discovers all active projects and sessions across Antigravity Desktop and Antigravity IDE.
- Pin and monitor any specific project, or enable ⚡ Auto-follow latest active session.
- Pinpoint heavy tool calls, large file dumps, or verbose responses in milliseconds.
- When crossing the 80% saturation threshold, click
⚡ 1-Click Distill New Session Prompt. - Instantly distill completed work, key technical decisions, and pending tasks to continue in a fresh session with 100% memory continuity.
Choose the mode that fits your workflow:
| Form Factor | Best For | Tech Stack | Footprint / Memory |
|---|---|---|---|
| 💊 Native macOS HUD Capsule | Standalone Antigravity Desktop App, multi-screen setups | Objective-C Cocoa + WebKit | Only 53 KB / ~15MB RAM |
| 🛠️ IDE Status Bar Extension | Antigravity IDE / VS Code embedded workflow | VS Code Extension API | Only 68 KB (.vsix) |
# 1. Clone this repository
git clone https://github.com/Dunphil692/antigravity-context-meter.git
cd antigravity-context-meter
# 2. Launch the floating capsule (runs in background, top-right of screen)
./start-capsule.sh
# 3. To stop / quit (or click the red [✕] button on the card):
./stop-capsule.sh- Go to the Releases Page and download
antigravity-context-meter-1.0.0.vsix. - Open Antigravity IDE / VS Code, open Extensions (
Cmd+Shift+X). - Click the
...menu on the top-right -> SelectInstall from VSIX.... - The live context ring will appear in your status bar!
Stress-tested on M-series Mac with 100-turn chat history (200,000+ characters of real engineering logs):
| Metric | Antigravity Context Meter | Chat /context Prompt |
Advantage |
|---|---|---|---|
| API Token Cost | 0 Tokens | 1,000 ~ 5,000 Tokens per check | 🟢 100% Free |
| Latency | 0.039 ms | 1.5 s ~ 3.0 s | 🟢 50,000x Faster |
| Binary Size | 53 KB (Native) | - | 🟢 Ultra Lightweight |
| Idle CPU Usage | 0.0% ~ 0.1% | - | 🟢 Zero Battery Drain |
- Minimalist dark frosted glass UI & 4-color breakdown bar
- Multi-project and multi-session dropdown switcher with pinning
- Native macOS floating HUD capsule with smooth screen dragging
- 1-Click zero-loss structured prompt distillation
- Windows / Linux floating window support
- Customizable threshold alerts (e.g. desktop notification at 80%)
- Official Antigravity Plugin Marketplace distribution
Contributions are warmly welcomed! Whether you want to file an issue, suggest improvements, or add support for new platforms:
- Fork this repository
- Create your feature branch (
git checkout -b feature/CoolFeature) - Commit your changes (
git commit -m 'feat: Add CoolFeature') - Push to the branch (
git push origin feature/CoolFeature) - Open a Pull Request
This project is licensed under the MIT License.



