Token Monitor
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Antigravity Token Monitor
A local, read-only plugin for Google Antigravity that adds live session context window visibility and historical daily token usage analytics directly inside the harness — with zero LLM token overhead, zero external network calls, and zero runtime npm install required.
Supports English and Polish (EN | PL) out of the box (auto-detected from your locale, switchable in one click).
Screenshots
Live Session Context Monitor (Side Pane) | Usage KPIs, Daily Heatmap & Models |
|
|
Related MCP server: Agy X-Ray
Features
1. Live Session Context Monitor (Auxiliary Side Pane — Sidecar)
Auto-bound to the active conversation: tracks whichever chat tab you have open (and lets you switch to inspect any recent session).
Closable anytime: lives as a native Side Pane tab (
Token Monitor) so you can close it (×), switch to Files/Terminal/Swarm, or reopen it via+whenever you want.Real-time occupancy gauge: shows exact active context (
input_tokens + cache_read_tokens), percentage ring + linear progress bar, and a clear auto-compaction threshold marker (~500k) with remaining tokens countdown.Step-by-step trajectory chart: interactive SVG chart plotting context growth across turns and marking
CHECKPOINTcompaction drops.Session metrics & subagent rollup: latest & cumulative cache hit rate, step/compaction counts, fresh (
in + out) vs total tokens, plus automatic rollup of spawned subagents/swarm workers.Compact Usage tab: quick glance at 7-day, lifetime, peak day, daily average, today, and a 16-week heatmap right from the side pane.
2. Full-Page Usage Analytics & Daily Heatmap (Left Sidebar — MCP App)
5 KPI summary cards:
Last 7 days (rolling 7 local calendar days + trend delta vs prior 7 days)
Lifetime usage (all-time totals, active days, main vs subagent sessions)
Peak day (most intense local calendar day, clickable to drill down)
Daily average (average per active day + average per calendar day)
Today (live running total, clickable to drill down)
GitHub-style daily heatmap: 90 / 180 / 365 days bucketed in your local timezone with quartile-based intensity levels and hover breakdowns.
Day drill-down & model breakdown: click any day cell to inspect per-model shares and every active session (main vs subagent badge, peak context mini-bar, fresh & total tokens, step count).
Persistent filters: toggle All (with cache) vs Fresh (
in + out), With subagents vs Main only, range (90d / 180d / 365d), and EN / PL language (saved locally inPLUGIN_DATA/prefs.json).
Requirements
Google Antigravity 2.0 (Desktop / CLI)
Node.js ≥ 22.5 (uses built-in
node:sqlite; pre-bundled runtime requires nonpm install)
Installation
All runtime artifacts (dist/mcp-server.cjs, dist/sidebar-app.html, sidecars/token-monitor/web/index.html) are pre-built in this repository so installation is a single step.
Option 1 — Antigravity CLI (agy)
agy plugin install https://github.com/vus955-gif/antigravity-token-monitorOption 2 — Manual git clone (macOS / Linux)
git clone https://github.com/vus955-gif/antigravity-token-monitor.git ~/.gemini/config/plugins/token-monitorOption 3 — Manual git clone (Windows PowerShell)
git clone https://github.com/vus955-gif/antigravity-token-monitor.git "$env:USERPROFILE\.gemini\config\plugins\token-monitor"Antigravity automatically discovers plugins placed under ~/.gemini/config/plugins/.
Usage
Side Pane: open any conversation, click
+in the right Auxiliary Side Pane, and select Token Monitor.Left Sidebar: click Token Monitor in the left navigation bar for the full-page heatmap and analytics dashboard.
Slash command: type
/token-monitorin any chat to surface a one-click toggle pill.
Privacy & How It Works
100% local & offline: reads Antigravity's local
transcript.jsonlfiles (~/.gemini/antigravity/brain/<id>/.system_generated/logs/transcript.jsonl) andconversation_summaries.dbin strict read-only mode.Zero telemetry / zero external requests: no analytics, no CDNs, strict CSP (
default-src 'none').Fast mtime/size caching: only re-parses transcripts that have changed on disk; typical warm dashboard queries take ~15–25 ms across 100+ sessions.
How context fill is calculated: Antigravity records
input_tokens(uncached prompt tokens),cache_read_tokens(cached prompt tokens), andoutput_tokenson eachPLANNER_RESPONSEandCHECKPOINTstep. Active context window occupancy isinput_tokens + cache_read_tokens.
Development & Testing
npm install
npm run build
npm testlib/telemetry.mjs— cached JSONL parser, read-onlynode:sqlitemetadata loader, session & daily aggregatorslib/models.mjs— model context limits,~500kcompaction threshold, human-readable model formattinglib/prefs.mjs— persisted user preferences (metric,scope,days,lang)sidecars/token-monitor/— Auxiliary Side Pane sidecar server & UI (web/template.html,web/styles.css,web/app.js)mcp/— Left Sidebar MCP App server & UI (mcp/server.mjs,mcp/ui/*)scripts/build-ui.mjs— esbuild pipeline producing zero-dependencydist/mcp-server.cjs,dist/sidebar-app.html, and self-containedsidecars/token-monitor/web/index.html
License
MIT © 2026 vus955-gif
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Read-only context from your desktop activity, so your AI assistant knows what you worked on.
Interactive data visualization and executive PDF dashboards for ChatGPT, Claude, and Cursor.
Read-only analytics for Convex apps, queryable via MCP from Claude, Cursor, and other clients.
Privacy-first work tracking with summaries, reports, coaching, and AI-ready long-term memory.
Related MCP Servers
- AlicenseNot gradedqualityBmaintenanceEnables users to inspect real-time prompt cache hit rate, task throughput, and per-model token usage for Antigravity sessions and 5h/1d/7d windows through an interactive local dashboard. It combines lifecycle hook timing with local transcript data, with zero outbound network telemetry.MIT
- AlicenseNot gradedqualityBmaintenanceEnables inspecting Google Antigravity sessions to break down context window composition and prefix-cache hits, rank token-heavy tool output hotspots, track every workspace file the agent read or modified, and search past transcripts and artifacts bilingually. It also lets users open touched files natively in a side pane and inject redacted historical excerpts or file references directly into the next prompt.MIT
- AlicenseNot gradedqualityBmaintenanceEnables live monitoring of Antigravity context-window token usage, CHECKPOINT compaction events, and collapsible chat/subchat trees grouped by project, context size, or date.MIT
- AlicenseNot gradedqualityCmaintenanceEnables visualization of live context-window usage, cache hit rates, token growth trends, and compaction events from local desktop session logs with no model-context overhead.MIT

