Skip to content

Commit 933c21e

Browse files
committed
feat: telemetry intelligence, UI overhaul, and provider fixes
Fixes: local-day bucketing for Claude analytics, single-number model pricing (fable), stale-cache fallback on transient API failures, health aliases, Gemini key via header, DeepSeek stringification, exclusive MOONSHOT_API_BASE override. UI: redesigned popout hero with progress ring and stat band, status filter chips, animated cards with usage rings, indeterminate loading bar, redesigned settings with health chips and section headers, daily bar hover details, expand/collapse all, copy buttons on diagnostics. Features: threshold desktop notifications, Claude 5h burn forecast and monthly cost projection, persistent usage history with sparklines and trend arrows, provider pinning, per-provider retry, console deep links, top pill mode, weekly top Claude projects by session cwd.
1 parent ea93ddb commit 933c21e

12 files changed

Lines changed: 1558 additions & 206 deletions

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,4 @@
77

88
.codex
99
.claude
10-
10+
CLAUDE.md

AiOverviewControlSettings.qml

Lines changed: 364 additions & 31 deletions
Large diffs are not rendered by default.

AiOverviewControlWidget.qml

Lines changed: 967 additions & 137 deletions
Large diffs are not rendered by default.

CHANGELOG.md

Lines changed: 35 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
## [Unreleased]
44

5-
## 1.3.0 - 2026-06-10
5+
## 1.3.0 - 2026-06-11
66

77
### Architecture
88
- Removed the external aggregation executable and its settings, detection, dispatcher arguments, documentation, and diagnostics.
@@ -20,11 +20,45 @@
2020
- Added provider filtering when more than eight cards are visible.
2121
- Rebuilt settings around provider health, telemetry coverage, informational coverage, and plugin-managed diagnostics.
2222
- Removed obsolete source mode and external-binary path controls.
23+
- Redesigned the popout hero: animated circular progress gauge, status eyebrow with live pulse, badge row, and a stat band (active/attention/engine/last sync) replacing the metric tiles.
24+
- Added status filter chips (All/Live/Issues) with counts above the provider list; the name filter now appears from six providers.
25+
- Provider cards gained an animated expand/collapse, a usage ring around the provider icon, and a rotating chevron.
26+
- Added an indeterminate loading bar at the top of the popout while fetching.
27+
- Redesigned settings: gradient hero with icon tile, version pill, health summary chips, and a re-check health action; section headers with icons and dividers; provider chips animate on hover; selected providers show colored health status pills; diagnostics commands render in monospace.
28+
- Provider cards sort by usage (highest first) with failed providers at the end.
29+
- Claude daily bars show per-day tokens and cost on hover, with animated bar heights.
30+
- Added expand-all/collapse-all toggle next to the provider list header.
31+
- Bar pill entries gained a usage-colored status dot and percent, replacing flat text.
32+
- Diagnostics commands gained a one-click copy button (wl-copy) with confirmation feedback.
33+
34+
### Features
35+
- Desktop notifications when a provider crosses a configurable usage threshold (75/85/95%), de-duplicated per reset window.
36+
- Claude 5h burn-rate forecast: warns "At this pace: 100% in Xm" when the window will be exhausted before reset.
37+
- Claude projected month cost tile based on average daily spend; turns red when projecting 1.5× current spend.
38+
- Usage history: the dispatcher records snapshots to `~/.cache/AiOverviewControl/usage-history.jsonl`; expanded cards render a sparkline via the new `get-usage-history` helper.
39+
- Trend arrows on cards (up/down vs the previous snapshot).
40+
- Pin providers (star) to keep them at the top of the list, persisted in settings.
41+
- "Open console" button on expanded cards deep-links to each provider's usage page.
42+
- Per-provider retry badge on failed cards re-fetches only that provider.
43+
- New "top" pill mode shows only the most critical provider in the bar.
44+
- Top Claude projects of the week (by real session `cwd`) with token bars, toggleable via the restored `showClaudeProjects` setting.
2345

2446
### Quality
2547
- Updated CI for the new dispatcher contract, health schema, and a regression check preventing the removed dependency from returning.
2648
- Rebuilt English, Brazilian Portuguese, and Simplified Chinese locale bundles with key parity.
2749

50+
### Fixes
51+
- Claude analytics now bucket session timestamps by local day instead of UTC, fixing shifted daily bars and undercounted today cost/tokens in non-UTC timezones.
52+
- Claude pricing now matches single-number model versions (e.g. `claude-fable-5`), which previously priced whole families at $0; pricing cache is invalidated via a schema marker.
53+
- Claude quota falls back to the last good snapshot on transient API failures (429, 5xx, network) instead of erroring the card; auth failures still surface.
54+
- Claude card shows 5h/7d reset countdowns and an "Extra usage on" badge.
55+
- Provider health checks now recognize dispatcher aliases (`moonshot`, `zhipu`, `nim`, `vertex`, `ark`, `modelark`, `dashscope`, `alibaba`).
56+
- Gemini API key moved from the URL query string to the `x-goog-api-key` header so it no longer leaks via process listings.
57+
- DeepSeek balance fields are stringified defensively so numeric API responses cannot break JSON output.
58+
- `MOONSHOT_API_BASE` override is now exclusive: no silent fallback to the China host when an explicit base is set.
59+
- Messages without a timestamp are excluded from Claude weekly aggregation instead of being miscounted.
60+
- Removed the unused USD→EUR exchange-rate fetch and dead `costCurrency`/`showClaudeProjects` settings references.
61+
2862
## 1.2.4 - 2026-05-26
2963

3064
### Dashboard — UX

CLAUDE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ Runtime: QML/Quickshell plus Bash helpers. Core dependencies: `bash`, `jq`, and
2424

2525
## Settings
2626

27-
`refreshInterval`, `providerSelection`, `showErrorProviders`, `pillMode`, `pillProviders`, `densityMode`, `costCurrency`, `showClaudeProjects`, `languageOverride`.
27+
`refreshInterval`, `providerSelection`, `showErrorProviders`, `pillMode`, `pillProviders`, `densityMode`, `languageOverride`, `quotaNotifications`, `notifyThreshold`, `showClaudeProjects`, `pinnedProviders`.
2828

2929
## Validation
3030

i18n/en.json

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,31 @@
77
"card.backend": "Backend",
88
"card.claude_details": "Claude Code details",
99
"card.claude_since": "Since {date} · {sessions} sessions · {messages} messages",
10+
"card.collapse_all": "Collapse all",
1011
"card.credits": "Credits",
1112
"card.engine": "Engine",
13+
"card.expand_all": "Expand all",
14+
"card.extra_usage_on": "Extra usage on",
1215
"card.filter_providers": "Filter providers by name or source",
16+
"card.history": "History",
1317
"card.login": "Login",
1418
"card.models_week": "Models this week",
1519
"card.month": "Month",
20+
"card.open_console": "Open console",
21+
"card.projected_month": "Projected month",
1622
"card.provider": "Provider",
1723
"card.provider_control": "Provider control",
1824
"card.provider_description": "Choose a provider managed by this plugin.",
1925
"card.providers": "Providers",
2026
"card.refresh": "Refresh",
27+
"card.retry": "Retry",
2128
"card.today_cost": "Today cost",
2229
"card.today_tokens": "Today tokens",
30+
"card.top_projects": "Top projects this week",
2331
"card.updated_at": "Updated {time}",
2432
"card.week": "Week",
33+
"claude.burn_pace_exceed": "At this pace: 100% in {time}",
34+
"claude.burn_pace_ok": "Usage on pace for this window",
2535
"error.claude_timeout": "Claude Code usage fetch timed out.",
2636
"error.claude_unavailable": "Claude Code usage details are unavailable. Check claude, jq, and curl.",
2737
"error.fetch_failed": "Failed to fetch usage from providers.",
@@ -30,30 +40,46 @@
3040
"error.helper_timeout": "Provider helper timed out while fetching usage data.",
3141
"error.parse_failed": "Failed to parse provider helper output.",
3242
"error.providers_need_attention": "{count} provider(s) need attention.",
43+
"filter.all": "All",
44+
"filter.issues": "Issues",
45+
"filter.live": "Live",
46+
"notify.body": "{window} window · resets in {time}",
47+
"notify.title": "{provider} at {percent}%",
3348
"popout.details_stale": "Stale since {time} · local adapters",
3449
"popout.details_updated": "Updated {time} · local adapters",
50+
"popout.last_sync": "Last sync",
3551
"popout.provider_dashboard": "Provider dashboard",
3652
"settings.active_count": "{count} active",
3753
"settings.configured_count": "{count} configured",
54+
"settings.copy_command": "Copy command",
3855
"settings.current_selection": "Current selection",
3956
"settings.density.description": "Comfortable keeps full previews. Compact reduces card height and visual detail.",
4057
"settings.density.label": "Dashboard density",
4158
"settings.diagnostics": "Diagnostics and tests",
4259
"settings.diagnostics_desc": "Commands for validating the plugin-managed pipeline.",
60+
"settings.health.missing_count": "{count} missing",
4361
"settings.health.pending": "Not checked",
4462
"settings.health.ready": "Ready",
63+
"settings.health.ready_count": "{count} ready",
64+
"settings.health.recheck": "Re-check health",
4565
"settings.hero.self_managed": "Provider collection, health checks, refresh policy and rendering are managed by this plugin. No external aggregation tool is required.",
4666
"settings.informational_providers": "Informational providers",
4767
"settings.informational_providers_desc": "These providers expose no public read-only quota API. Their cards point to the official usage surface.",
4868
"settings.language.description": "UI language for this plugin. Auto follows system locale.",
4969
"settings.language.label": "Language",
70+
"settings.notify.description": "Send a desktop notification when a provider crosses the threshold.",
71+
"settings.notify.label": "Quota notifications",
72+
"settings.notify.threshold": "Notification threshold",
73+
"settings.notify.threshold_desc": "Usage percent that triggers a notification.",
5074
"settings.pill_mode.description": "Auto shows providers with measurable usage. Custom uses the configured list.",
5175
"settings.pill_mode.label": "Pill mode",
5276
"settings.refresh_description": "How often the plugin queries selected local adapters and provider APIs.",
5377
"settings.refresh_interval": "Refresh interval",
5478
"settings.section.interface": "Interface",
5579
"settings.show_errors": "Show providers with errors",
5680
"settings.show_errors_desc": "Keep authentication and configuration failures visible in the dashboard.",
81+
"settings.show_projects": "Show Claude projects",
82+
"settings.show_projects_desc": "List the week's top projects inside the Claude card.",
5783
"settings.telemetry_providers": "Telemetry providers",
5884
"settings.telemetry_providers_desc": "Adapters backed by official CLIs, documented APIs, or local usage stores.",
5985
"settings.test_backend": "Test selected providers",

i18n/pt_BR.json

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,31 @@
77
"card.backend": "Backend",
88
"card.claude_details": "Detalhes do Claude Code",
99
"card.claude_since": "Desde {date} · {sessions} sessões · {messages} mensagens",
10+
"card.collapse_all": "Recolher tudo",
1011
"card.credits": "Créditos",
1112
"card.engine": "Motor",
13+
"card.expand_all": "Expandir tudo",
14+
"card.extra_usage_on": "Uso extra ativo",
1215
"card.filter_providers": "Filtrar provedores por nome ou fonte",
16+
"card.history": "Histórico",
1317
"card.login": "Login",
1418
"card.models_week": "Modelos nesta semana",
1519
"card.month": "Mês",
20+
"card.open_console": "Abrir console",
21+
"card.projected_month": "Projeção do mês",
1622
"card.provider": "Provedor",
1723
"card.provider_control": "Gerenciar provedores",
1824
"card.provider_description": "Escolha um provedor administrado por este plugin.",
1925
"card.providers": "Provedores",
2026
"card.refresh": "Atualizar",
27+
"card.retry": "Tentar de novo",
2128
"card.today_cost": "Custo hoje",
2229
"card.today_tokens": "Tokens hoje",
30+
"card.top_projects": "Top projetos da semana",
2331
"card.updated_at": "Atualizado às {time}",
2432
"card.week": "Semana",
33+
"claude.burn_pace_exceed": "Neste ritmo: 100% em {time}",
34+
"claude.burn_pace_ok": "Uso dentro do ritmo da janela",
2535
"error.claude_timeout": "A coleta de uso do Claude Code excedeu o tempo limite.",
2636
"error.claude_unavailable": "Os detalhes de uso do Claude Code estão indisponíveis. Verifique claude, jq e curl.",
2737
"error.fetch_failed": "Falha ao coletar uso dos provedores.",
@@ -30,30 +40,46 @@
3040
"error.helper_timeout": "O helper excedeu o tempo limite durante a coleta.",
3141
"error.parse_failed": "Falha ao interpretar a saída do helper.",
3242
"error.providers_need_attention": "{count} provedor(es) precisam de atenção.",
43+
"filter.all": "Todos",
44+
"filter.issues": "Problemas",
45+
"filter.live": "Ativos",
46+
"notify.body": "Janela {window} · reseta em {time}",
47+
"notify.title": "{provider} em {percent}%",
3348
"popout.details_stale": "Desatualizado desde {time} · adaptadores locais",
3449
"popout.details_updated": "Atualizado às {time} · adaptadores locais",
50+
"popout.last_sync": "Última sincronização",
3551
"popout.provider_dashboard": "Painel de provedores",
3652
"settings.active_count": "{count} ativos",
3753
"settings.configured_count": "{count} configurados",
54+
"settings.copy_command": "Copiar comando",
3855
"settings.current_selection": "Seleção atual",
3956
"settings.density.description": "Confortável mantém prévias completas. Compacta reduz altura e detalhes visuais.",
4057
"settings.density.label": "Densidade do painel",
4158
"settings.diagnostics": "Diagnósticos e testes",
4259
"settings.diagnostics_desc": "Comandos para validar o pipeline administrado pelo plugin.",
60+
"settings.health.missing_count": "{count} pendentes",
4361
"settings.health.pending": "Não verificado",
4462
"settings.health.ready": "Pronto",
63+
"settings.health.ready_count": "{count} prontos",
64+
"settings.health.recheck": "Reverificar saúde",
4565
"settings.hero.self_managed": "A coleta, a saúde, a atualização e a renderização dos provedores são administradas por este plugin. Nenhum agregador externo é necessário.",
4666
"settings.informational_providers": "Provedores informativos",
4767
"settings.informational_providers_desc": "Estes provedores não expõem API pública somente leitura para cotas. Os cartões apontam para a tela oficial de uso.",
4868
"settings.language.description": "Idioma da interface deste plugin. Automático segue o idioma do sistema.",
4969
"settings.language.label": "Idioma",
70+
"settings.notify.description": "Envia notificação na área de trabalho quando um provider cruza o limiar.",
71+
"settings.notify.label": "Notificações de quota",
72+
"settings.notify.threshold": "Limiar de notificação",
73+
"settings.notify.threshold_desc": "Percentual de uso que dispara a notificação.",
5074
"settings.pill_mode.description": "Automático mostra provedores com uso mensurável. Personalizado usa a lista configurada.",
5175
"settings.pill_mode.label": "Modo do indicador",
5276
"settings.refresh_description": "Frequência de consulta aos adaptadores locais e APIs selecionadas.",
5377
"settings.refresh_interval": "Intervalo de atualização",
5478
"settings.section.interface": "Interface",
5579
"settings.show_errors": "Mostrar provedores com erro",
5680
"settings.show_errors_desc": "Mantém falhas de autenticação e configuração visíveis no painel.",
81+
"settings.show_projects": "Mostrar projetos do Claude",
82+
"settings.show_projects_desc": "Lista os principais projetos da semana no card do Claude.",
5783
"settings.telemetry_providers": "Provedores com telemetria",
5884
"settings.telemetry_providers_desc": "Adaptadores baseados em CLIs oficiais, APIs documentadas ou armazenamento local de uso.",
5985
"settings.test_backend": "Testar provedores selecionados",

i18n/zh_CN.json

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,21 +7,31 @@
77
"card.backend": "后端",
88
"card.claude_details": "Claude Code 详情",
99
"card.claude_since": "自 {date} · {sessions} 个会话 · {messages} 条消息",
10+
"card.collapse_all": "全部收起",
1011
"card.credits": "额度",
1112
"card.engine": "引擎",
13+
"card.expand_all": "全部展开",
14+
"card.extra_usage_on": "已启用额外用量",
1215
"card.filter_providers": "按名称或来源筛选提供商",
16+
"card.history": "历史",
1317
"card.login": "登录",
1418
"card.models_week": "本周模型",
1519
"card.month": "本月",
20+
"card.open_console": "打开控制台",
21+
"card.projected_month": "本月预测",
1622
"card.provider": "提供商",
1723
"card.provider_control": "管理提供商",
1824
"card.provider_description": "选择由此插件管理的提供商。",
1925
"card.providers": "提供商",
2026
"card.refresh": "刷新",
27+
"card.retry": "重试",
2128
"card.today_cost": "今日费用",
2229
"card.today_tokens": "今日令牌",
30+
"card.top_projects": "本周项目排行",
2331
"card.updated_at": "更新于 {time}",
2432
"card.week": "本周",
33+
"claude.burn_pace_exceed": "按此速度:{time} 后达到 100%",
34+
"claude.burn_pace_ok": "本窗口用量正常",
2535
"error.claude_timeout": "Claude Code 用量获取超时。",
2636
"error.claude_unavailable": "Claude Code 用量详情不可用。请检查 claude、jq 和 curl。",
2737
"error.fetch_failed": "获取提供商用量失败。",
@@ -30,30 +40,46 @@
3040
"error.helper_timeout": "获取用量时提供商助手超时。",
3141
"error.parse_failed": "无法解析提供商助手输出。",
3242
"error.providers_need_attention": "{count} 个提供商需要注意。",
43+
"filter.all": "全部",
44+
"filter.issues": "异常",
45+
"filter.live": "正常",
46+
"notify.body": "{window} 窗口 · {time} 后重置",
47+
"notify.title": "{provider} 已达 {percent}%",
3348
"popout.details_stale": "自 {time} 起已过期 · 本地适配器",
3449
"popout.details_updated": "更新于 {time} · 本地适配器",
50+
"popout.last_sync": "上次同步",
3551
"popout.provider_dashboard": "提供商仪表板",
3652
"settings.active_count": "{count} 个已启用",
3753
"settings.configured_count": "{count} 个已配置",
54+
"settings.copy_command": "复制命令",
3855
"settings.current_selection": "当前选择",
3956
"settings.density.description": "舒适模式保留完整预览;紧凑模式减少卡片高度和视觉细节。",
4057
"settings.density.label": "仪表板密度",
4158
"settings.diagnostics": "诊断和测试",
4259
"settings.diagnostics_desc": "验证插件管理管线的命令。",
60+
"settings.health.missing_count": "{count} 个缺失",
4361
"settings.health.pending": "未检查",
4462
"settings.health.ready": "就绪",
63+
"settings.health.ready_count": "{count} 个就绪",
64+
"settings.health.recheck": "重新检查健康",
4565
"settings.hero.self_managed": "提供商采集、健康检查、刷新策略和渲染均由此插件管理,无需外部聚合工具。",
4666
"settings.informational_providers": "信息型提供商",
4767
"settings.informational_providers_desc": "这些提供商没有公开的只读配额 API,卡片会指向官方用量页面。",
4868
"settings.language.description": "此插件的界面语言。自动模式跟随系统区域设置。",
4969
"settings.language.label": "语言",
70+
"settings.notify.description": "当服务商超过阈值时发送桌面通知。",
71+
"settings.notify.label": "配额通知",
72+
"settings.notify.threshold": "通知阈值",
73+
"settings.notify.threshold_desc": "触发通知的使用百分比。",
5074
"settings.pill_mode.description": "自动显示有可测用量的提供商;自定义使用配置列表。",
5175
"settings.pill_mode.label": "栏指示器模式",
5276
"settings.refresh_description": "插件查询所选本地适配器和提供商 API 的频率。",
5377
"settings.refresh_interval": "刷新间隔",
5478
"settings.section.interface": "界面",
5579
"settings.show_errors": "显示错误提供商",
5680
"settings.show_errors_desc": "在仪表板中保留身份验证和配置失败。",
81+
"settings.show_projects": "显示 Claude 项目",
82+
"settings.show_projects_desc": "在 Claude 卡片中列出本周项目排行。",
5783
"settings.telemetry_providers": "遥测提供商",
5884
"settings.telemetry_providers_desc": "由官方 CLI、文档化 API 或本地用量存储支持的适配器。",
5985
"settings.test_backend": "测试所选提供商",

0 commit comments

Comments
 (0)