Skip to content

feat(plugin): use exact Claude Code stdin telemetry in status bar (#1325)#1330

Merged
JeremyDev87 merged 1 commit into
masterfrom
taskmaestro/1775305982/pane-2
Apr 4, 2026
Merged

feat(plugin): use exact Claude Code stdin telemetry in status bar (#1325)#1330
JeremyDev87 merged 1 commit into
masterfrom
taskmaestro/1775305982/pane-2

Conversation

@JeremyDev87

Copy link
Copy Markdown
Owner

Summary

  • Refactor codingbuddy-hud.py to prefer exact Claude Code stdin telemetry over estimates
  • Explicit fallback order per field: stdin > HUD state > estimate
  • Show $ prefix for exact cost, ~$ for estimated cost
  • Surface rate limits (5h/7d usage), worktree name, model display name, and stdin agent name

Changes

Field Before After
Cost Always estimated from tokens cost.total_cost_usdestimate_cost()
Duration Always from hud-state timestamp cost.total_duration_ms → hud-state → 0m
Agent Env var only agent.name → env var
Model model.id for pricing only Show model.display_name in status bar
Rate limits Not shown RL:5h:X%,7d:Y% when present
Worktree Not shown WT:<name> when present

Test plan

  • 63 HUD tests pass (was 27, added 36 new)
  • Full plugin suite: 698 passed
  • TypeScript: tsc --noEmit clean
  • Vitest: 5959 passed

Closes #1325

)

Prefer exact telemetry from Claude Code stdin over estimates:
- cost: stdin cost.total_cost_usd > estimate_cost() (show $ vs ~$)
- duration: stdin cost.total_duration_ms > hud-state timestamp
- agent: stdin agent.name > CODINGBUDDY_ACTIVE_AGENT env
- model: show display_name when available
- rate_limits: show 5h/7d usage when present
- worktree: show WT name when present

Closes #1325
@JeremyDev87 JeremyDev87 added feat plugin packages/claude-code-plugin wow-experience Plugin Wow Experience Design labels Apr 4, 2026
@vercel

vercel Bot commented Apr 4, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
codingbuddy-landing Ready Ready Preview, Comment Apr 4, 2026 0:54am

@JeremyDev87 JeremyDev87 left a comment

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review: ✅ APPROVE

CI Status: ALL PASS

Files: codingbuddy-hud.py

  • Refactored to prefer exact Claude Code stdin telemetry (cost, duration, model, context, rate limits)
  • Explicit fallback order: stdin > HUD state > estimate
  • Agent field: stdin.agent.name > HUD activeAgent > env fallback

✅ Status bar first line now uses exact telemetry.

@JeremyDev87 JeremyDev87 self-assigned this Apr 4, 2026
@JeremyDev87 JeremyDev87 merged commit e154ec1 into master Apr 4, 2026
29 checks passed
@JeremyDev87 JeremyDev87 deleted the taskmaestro/1775305982/pane-2 branch April 4, 2026 13:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feat plugin packages/claude-code-plugin wow-experience Plugin Wow Experience Design

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(plugin): use exact Claude Code stdin telemetry in codingbuddy-hud.py

1 participant