feat: add cache-aware token usage dashboard (#1338)

* feat: add cache-aware token usage dashboard

Track normalized Claude, Codex, and ACP usage with incremental SQLite backfill. Exclude imported transcript history, rebuild usage after history rewrites, and expose an owner-only dashboard with cache-aware totals and breakdowns.

via [HAPI](https://hapi.run)

Co-Authored-By: HAPI <noreply@hapi.run>

* fix: preserve usage model and local dates

via [HAPI](https://hapi.run)

Co-Authored-By: HAPI <noreply@hapi.run>

* fix: normalize cached usage and timezone buckets

via [HAPI](https://hapi.run)

Co-Authored-By: HAPI <noreply@hapi.run>

---------

Co-authored-by: HAPI <noreply@hapi.run>
This commit is contained in:
2026-08-03 18:02:26 +08:00
committed by GitHub
co-authored by HAPI
parent 518bd7a9a9
commit 1761b696f7
49 changed files with 1904 additions and 46 deletions
+1 -1
View File
@@ -195,7 +195,7 @@ class CursorRemoteLauncher extends RemoteLauncherBase {
} else if (event.type === 'assistant' || event.type === 'tool_call' || event.type === 'result') {
const agentMsg = convertCursorEventToAgentMessage(event);
if (agentMsg) {
const codexMsg = convertAgentMessage(agentMsg);
const codexMsg = convertAgentMessage(agentMsg, session.model);
if (codexMsg) {
session.sendAgentMessage(codexMsg);
}