Pulse-Claude-Code-Analytics
Open-source Claude Code + OpenAI Codex analytics dashboard with Discord Rich Presence. Accurate cost for Claude Opus 4.8 (with fast mode) and Codex GPT-5.5, A-F cache health, per-session context, inflection alerts, one-click Fix-with-Claude prompts. Native Tauri desktop, 100% local, zero telemetry.
- 3
- Stars
- 0
- Forks
Media
- Last updated
- Jun 17, 2026
- Original upload
- May 31, 2026
- Language
- Rust
- License
- Apache-2.0
- Type
- Tool
Topics
About this project
Open-source Claude Code + OpenAI Codex analytics dashboard with Discord Rich Presence. Accurate cost for Claude Opus 4.8 (with fast mode) and Codex GPT-5.5, A-F cache health, per-session context, inflection alerts, one-click Fix-with-Claude prompts. Native Tauri desktop, 100% local, zero telemetry.
See where every Claude Code dollar actually goes.
The open-source Claude Code & OpenAI Codex analytics dashboard + Discord Rich Presence for devs on Claude Pro / Max / Teams and ChatGPT Plus / Pro / Business.Grade your cache A – F, catch runaway sessions before they burn your plan, and copy one-click Fix with Claude Code prompts. Native desktop. 100 % local. Zero telemetry.
Download · What's New · About · Screenshots · Features · Docs · Sponsor
- Faithful Discord Live Preview — the preview now renders the real Rich Presence artwork (the Claude Code mascot and the Codex mark), bundled in-app and mapped by provider/surface, in a card that mirrors Discord's layout, with a Fast-tier
⚡indicator. - Plan override that sticks — a manual plan choice in Settings now persists to disk, reaches the live broadcast, and stays selected instead of snapping back to Auto-detect; the control uses a canonical plan-key contract.
- Live plan auto-detect — a Claude plan upgrade (e.g. Max 5x → Max 20x) is reflected without restarting Pulse.
- Codex Fast mode detected — the Codex service tier is read from
~/.codex/config.toml(where current Codex versions store it), so Fast renders as⚡ … · Fastagain. - Clearer cost + cache UI — cost is reported per 1M tokens (the per-1K figure rounded to
$0.00), and the dashboard cache grade shows a neutral—instead of a redFwhen there's no data yet. - Hardened core — centralized the Claude plan mapping, bounded the session/report scans, and log previously-swallowed failures instead of dropping them.
Download v1.3.0 · Full changelog
You pay for Claude Code every month. Maybe $20 on Pro, $100 – $200 on Max, or a seat on Teams. And yet, if someone asked "which of your sessions burned the most context this week?" or "what percentage of your tokens are actually cache hits?" — you probably can't answer.
Pulse answers. It reads Claude Code's own JSONL transcripts (zero-config — just install and launch) and surfaces the things that actually move the needle on your plan:
- A – F cache-health letter grade — trend-weighted, so you see the direction your cache efficiency is heading, not just today's number.
- Opus-4.7-tokenizer aware — Opus 4.7's new tokenizer inflates tokens by up to 35 %; Pulse flags the inflation so you know when you're hitting limits faster than expected.
- 1 M context GA pricing — flat per-token rate across the full 1 M window for Fable 5 · Mythos 5 · Opus 4.6 · Opus 4.7 · Opus 4.8 · Sonnet 4.6 (per Anthropic's official pricing). Older betas (Sonnet 4 / 4.5, Opus 4 / 4.5) still get 2× input · 1.5× output · 2× cache at > 200 K. Pulse applies the correct math per-model so you compare sessions like-for-like. Plan-level Extra Usage on Pro / Max / Teams is tracked separately.
- Inflection alerts — any session that blows past 2 × your rolling baseline gets flagged with context and a suggested fix.
- Fix-with-Claude prompts — every recommendation has a Copy Fix Prompt button. Paste it into Claude Code. Problem fixed.
- Plan usage limits — live tracking of your 5-hour window, weekly, Sonnet-only, and Extra Usage quotas. Sound alert when Extra Usage spikes.
- Release awareness — startup and 6-hour update checks surface new stable GitHub Releases inside the app without pretending a signed auto-installer exists before release metadata is published.
- Discord Rich Presence — five-tier reasoning effort, live project / model / branch. Your flow state, on your profile.
Works with OpenAI Codex too. Flip the provider toggle and Pulse reads your Codex CLI sessions the same way — per-model pricing for the GPT-5 family including GPT-5.5 ($5 / $30 per Mtok), 400 K context tracking, and reasoning-effort detection. Fast mode (/fast) is priced correctly on both sides: Codex GPT-5.5 bills at 2.5× and GPT-5.4 at 2× the standard rate, and Claude Opus 4.8 Fast bills at 2× — each flagged with a ⚡ marker in Sessions and Discord presence.
Codex Discord Rich Presence has its own source-of-truth repo: xt0n1-t3ch/Codex-Discord-Rich-Presence. Pulse mirrors that Rust core into src/codex/ through checked sync scripts and CI freshness gates, so Codex support can move fast here while the standalone Rich Presence project keeps its own audience.
Written in Rust + Tauri 2 + Svelte 5. ≈ 12 MB on Windows, ≈ 18 MB on macOS. Cold-starts in under 200 ms. One-click installers for Windows (NSIS + MSI), macOS (DMG — Apple Silicon + Intel), and Linux (deb, rpm, AppImage). Apache-2.0 licensed (attribution required — see NOTICE). The data never leaves your machine.
Dashboard — at-a-glance cost · tokens · cache-hit ratio · plan limits · extra usage · activity heatmap.
Reports & Insights — letter-grade cache health · rule-based recommendations · cost inflection detection · one-click Fix with Claude Code prompts.
Discord Rich Presence — live model · reasoning effort · project · branch · tokens · cost · 5 h / 7 d / Extra Usage, right on your profile.
Windows
irm https://raw.githubusercontent.com/xt0n1-t3ch/Pulse-Claude-Code-Analytics/main/scripts/install.ps1 | iex
Or grab an installer from the latest release:
| Asset | Description |
|---|---|
Pulse_x.y.z_x64-setup.exe | NSIS installer — recommended |
Pulse_x.y.z_x64_en-US.msi | MSI installer |
macOS
curl -fsSL https://raw.githubusercontent.com/xt0n1-t3ch/Pulse-Claude-Code-Analytics/main/scripts/install.sh | bash
| Asset | Architecture |
|---|---|
Pulse_x.y.z_aarch64.dmg | Apple Silicon (M1 / M2 / M3 / M4) |
Pulse_x.y.z_x64.dmg | Intel |
Linux
curl -fsSL https://raw.githubusercontent.com/xt0n1-t3ch/Pulse-Claude-Code-Analytics/main/scripts/install.sh | bash
| Asset | Distro |
|---|---|
pulse_x.y.z_amd64.deb | Debian / Ubuntu |
pulse-x.y.z-1.x86_64.rpm | Fedora / RHEL |
pulse_x.y.z_amd64.AppImage | Any (portable) |
From source
git clone https://github.com/xt0n1-t3ch/Pulse-Claude-Code-Analytics.git
cd Pulse-Claude-Code-Analytics
cd frontend && npm install && npm run build && cd ..
cd src-tauri && cargo tauri build
Analytics dashboard
| Accurate cost math | Per session · day · model. Published pricing for every Claude — Fable 5, Mythos 5, Opus 4.8 (with fast mode), 4.7, 4.6, 4.5, 4.1, 4, 3; Sonnet 4.6, 4.5, 4; Haiku 4.5, 3.5, 3. Speed-aware per-turn, so fast turns price at 2×. Compare like-for-like whatever plan you're on. |
| A – F cache health grade | Trend-weighted hit ratio — cchubber-style. See your direction, not just your current number. |
| Model routing insights | Opus / Sonnet / Haiku split + "you could save $X by rerouting N sessions to Sonnet" estimate. |
| Inflection detection | Any session ≥ 2 × baseline cost-per-session gets flagged with context. |
| Recommendations engine | Every finding has a Copy Fix Prompt button. Paste it into Claude Code. Problem fixed. |
| Plan usage limits | 5-hour window · weekly all-models · Sonnet-only · Extra Usage monthly spend. Auto-detects Pro / Max / Teams. Sound alert on Extra Usage spikes. |
| Heatmap · sparklines · charts | All-local Chart.js. Zero network. |
| Reports export | Branded HTML + Markdown. One click. |
| OpenAI Codex support | Full GPT-5 family pricing — GPT-5.5, 5.4, 5.3-Codex, 5.2, 5.1 (+ Codex / max / mini), 5, mini, nano. Fast mode (/fast) surfaced at 2.5× (5.5) / 2× (5.4). One-click provider switch. |
| Codex RP upstream sync | Codex Discord Rich Presence logic is mirrored from Codex-Discord-Rich-Presence with scripts and CI checks, instead of drifting as a private fork. |
Discord Rich Presence
| Live fields | Project · git branch · model · reasoning effort · activity status. |
| Session timer | Elapsed since start. Persists through Discord restarts. |
| Reasoning tiers | Five tiers (Low / Medium / High / Extra High / Max) — Opus 4.7 native. |
| Asset resolver | Multi-tier — portal keys → Media Proxy → plain URLs → fallback. |
| Presets | Minimal · Standard · Full. Customize per-field too. |
Privacy & ownership
- 100 % local. Your session data never leaves your machine. No telemetry, no phone-home, no cloud.
- SQLite at
~/.claude/pulse-analytics.db— yours to inspect, export, back up, or delete. - Apache-2.0 licensed with required attribution. Fork it, audit it, ship your own version — just keep the
NOTICEfile and credit the original author per the license.
| Pulse | Generic dashboards | |
|---|---|---|
| Opus 4.7 tokenizer awareness (flags inflated counts) | ✓ | — |
| 1 M context pricing correctly applied per model (GA flat vs. beta surcharge) | ✓ | — |
| A – F cache health grade (trend-weighted) | ✓ | — |
| Fix with Claude Code one-click prompts | ✓ | — |
| Zero-config — reads JSONL transcripts directly | ✓ | setup required |
| Discord Rich Presence | ✓ | — |
| Native desktop (Tauri 2 + Rust, no Electron bloat) | ✓ | — |
| Open source | Apache-2.0 | varies |
First launch → install Pulse → launch → it auto-detects your ~/.claude/ folder → keep using Claude Code; sessions stream in live.
Discord Rich Presence → open the Discord tab → pick a preset (Minimal · Standard · Full) or customize fields → toggle on. Custom presence artwork in docs/discord-assets.md.
Reports → open the Reports tab → read your cache grade + recommendations → click Copy Fix Prompt on any item → paste into Claude Code → done. Export HTML / Markdown for your team.
- Linux tray icon — system-tray quick toggles (Discord presence on/off, pause analytics, open dashboard) via Tauri's
tray-iconfeature. Parity with the Windows tray. - MCP server inventory — list every MCP server Claude Code has loaded for each session, with its tool count, per-tool invocation frequency, and an estimated token cost per tool call. Helps spot noisy MCPs silently inflating your context.
- Budget-threshold desktop notifications — native OS notification when you cross configurable thresholds (e.g. "80 % of weekly limit", "Extra Usage just passed $150 of your $200 cap"). Replaces eyeballing the dashboard.
- Custom Discord presence templates — save / share named field layouts beyond Minimal · Standard · Full. Export a preset as JSON; import one from a teammate.
- Session replay — step through a past session's prompts and tool-call timeline with the same filters the live dashboard uses. Currently the data is there (JSONL traces) but there's no dedicated UI.
- Smarter cost forecast — weekly-reset-aware projections with a confidence band, instead of today's linear daily-average multiplication.
Track on the project board.
PRs welcome. CONTRIBUTING.md has the dev setup, style guide, and release process. Please read the Code of Conduct first.
If Pulse saves you money (or sanity), sponsor its development:
Every contribution goes toward faster releases, better analyzers, and keeping Pulse free and open-source forever.
Responsible-disclosure policy in SECURITY.md. Report privately via GitHub Security Advisories.
Apache-2.0 © 2026 xt0n1-t3ch. Use Pulse for anything (personal or commercial) — but per the license you must keep the copyright notice and the NOTICE file with original-author attribution in any redistribution or derivative work.
Windows + WSL session roots
Pulse is Windows-native by default. On Windows it does not launch wsl.exe while polling sessions, because broken WSL installs can raise OS-level crash dialogs. If you intentionally keep Claude/Codex transcripts inside WSL and want Pulse to scan them, opt in before launch:
$env:CC_PRESENCE_INCLUDE_WSL = "1"
Linux and macOS continue to use their native session paths; WSL path bridging remains available only through the explicit Windows opt-in.