[Showcase / Tool] Antigravity Quota Bar: Track your Gemini, Claude & Argon usage & reset countdown from the macOS Menu Bar! ♊

Hey everyone! :waving_hand:

While working on long agentic coding sessions in Google Antigravity, I often found myself wondering how much quota I had left before hitting a 5-hour rolling limit or exhausting my weekly budget—especially when switching between frontier models like Gemini Flash/Pro, Claude 3.7/3.5 Sonnet, and the new Gemini 4 Argon.

To solve this, I built Antigravity Quota Bar, a lightweight native macOS Menu Bar application that lives right next to your system clock and gives you real-time visibility into all your model quotas and reset countdowns.

I wanted to share it with the community here in case anyone else finds it useful!

:link: GitHub Repository: https://github.com/cursoraiht-maker/gemini_antigravity


:rocket: What it does

Instead of waiting for an agent error to know you’re running low on tokens, this menu bar app connects directly to the local Antigravity background process (agy / language_server) via internal Connect-RPC and tracks:

  1. Google Gemini Models (Flash & Pro):
    • 5-Hour Rolling Window: Percentage available + exact countdown (e.g. ⏳ 1h 28m).
    • Weekly Budget: Remaining percentage + days/hours until renewal (e.g. ⏳ 2d 2h).
  2. Claude & GPT Models (Sonnet, Opus, GPT-OSS):
    • Tracks both the 5-hour session and weekly cycles.
  3. Gemini 4 Argon (New Reasoning Model):
    • Tracks its dedicated separate weekly quota bucket.
  4. Exact Reset Timers:
    • Displays the countdown in days and hours (Reset: in 2 days, 2 hours) along with your local date/time of renewal.

:sparkles: Highlights

  • 100% Native & Lightweight: Written in pure Swift with AppKit/Cocoa. No Electron, no heavy dependencies, uses almost zero CPU/RAM.
  • Color-Coded Status Emojis:
    • :green_circle: > 50% available
    • :yellow_circle: 20% – 50% available
    • :red_circle: < 20% (low quota warning)
  • 10 Display Styles for the Menu Bar:
    • Standard with time: ♊ 5h: 78% (1h 28m) · Sem: 38% (2d 2h)
    • Compact: ♊ 78% | 38%
    • Argon-only: 🪐 Argon: 1% · ⏳ 5d 17h
    • Lowest-remaining: ⚠️ Mín: 1% (5d 17h)
  • Zero Config: Automatically detects your local Antigravity session port and CSRF token—no external API keys or login setup needed.
  • Launch at Login: Optional toggle to start automatically on macOS boot.

:hammer_and_wrench: Quick Installation

Requirements: macOS 13.0+ (Apple Silicon M1/M2/M3/M4 or Intel) and Xcode command line tools (swiftc).

git clone https://github.com/cursoraiht-maker/gemini_antigravity.git
cd gemini_antigravity
chmod +x GeminiQuotaBar/build.sh
./GeminiQuotaBar/build.sh

# Move to Applications and open:
cp -rf GeminiQuotaBar/build/GeminiQuotaBar.app /Applications/
open /Applications/GeminiQuotaBar.app

Hope this helps you manage your token burn and plan heavy agent workflows without getting surprised by rate limits!

Feedback, PRs, and suggestions are welcome on GitHub!

Nice work on this, @Jean_Paul_Raimond_Ke. Really appreciate that you built it in native AppKit instead of dumping another 300MB Electron wrapper into the menu bar.

Tested your Connect-RPC logic against a Windows box—turns out it works identically against language_server.exe.

One quirk on Windows: Antigravity starts the process with --https_server_port 0, so it binds to a random ephemeral port rather than passing a static --hub-port. You just have to grab the listening port via Get-NetTCPConnection.

Threw together a quick PowerShell script for anyone on Windows who wants the same live quota breakdown in their terminal:

$lsProcess = Get-Process -Name "language_server" -ErrorAction SilentlyContinue | Select-Object -First 1
if (-not $lsProcess) { Write-Host "Antigravity language_server not running."; exit }
$lsPid = $lsProcess.Id

$cmd = (Get-CimInstance Win32_Process -Filter "ProcessId=$lsPid").CommandLine
$token = if ($cmd -match '--csrf_token[=\s]+([^\s"''\n]+)') { $matches[1] } else { $null }

$ports = Get-NetTCPConnection -OwningProcess $lsPid -State Listen | Select-Object -ExpandProperty LocalPort
foreach ($port in $ports) {
    try {
        $headers = @{ "Content-Type" = "application/json"; "x-codeium-csrf-token" = $token }
        $resp = Invoke-RestMethod -Uri "http://127.0.0.1:$port/exa.language_server_pb.LanguageServerService/RetrieveUserQuotaSummary" `
            -Method Post -Headers $headers -Body "{}" -TimeoutSec 2 -ErrorAction Stop
        if ($resp.response.groups) {
            Write-Host "`n=== ANTIGRAVITY QUOTA TELEMETRY (Windows CLI) ===" -ForegroundColor Cyan
            foreach ($g in $resp.response.groups) {
                Write-Host "`n[$($g.displayName)]" -ForegroundColor Yellow
                foreach ($b in $g.buckets) {
                    $pct = [math]::Round($b.remainingFraction * 100, 1)
                    $color = if ($pct -gt 50) { "Green" } elseif ($pct -gt 20) { "Yellow" } else { "Red" }
                    Write-Host "  • $($b.displayName) ($($b.window)): $pct% remaining (Reset: $($b.resetTime))" -ForegroundColor $color
                }
            }
            break
        }
    } catch {}
}

Super handy to check this before kicking off heavy multi-turn tasks. Cheers!

I will check it out, thanks!

Coincidentally, I built something very similar earlier this week that’s very similar to what you’ve created. Unfortunately, I didn’t come across your app until today, or I would have saved myself some effort