summaryrefslogtreecommitdiffhomepage
path: root/src/components/Table.svelte
diff options
context:
space:
mode:
authorAdam Malczewski <[email protected]>2026-06-10 10:34:37 +0900
committerAdam Malczewski <[email protected]>2026-06-10 10:34:37 +0900
commit89ca80bac1e143a4ec5ba6e2e1d4998acce2553c (patch)
tree7af49f5fd2385c02153accb5fdb0a6c43ba37229 /src/components/Table.svelte
parentf8bf715abc8a89ec0c6370b40403c509b1ce2870 (diff)
downloaddispatch-web-89ca80bac1e143a4ec5ba6e2e1d4998acce2553c.tar.gz
dispatch-web-89ca80bac1e143a4ec5ba6e2e1d4998acce2553c.zip
feat(metrics): inline cache hit-rate badges (last turn + chat total)
Derive cache hit rate (cacheReadTokens / inputTokens) from data already folded in core/metrics — no backend/contract change. - core/metrics: computeCachePct + viewCacheRate (pct + success/warning/error level by 66/33 thresholds + isHit); thread a running cumulativeUsage onto each finalized turn-metrics row for the conversation total. - ChatView: render two labelled, colour-coded percentage badges in the turn-total bubble — "Last turn:" (that turn) and "Chat Total:" (cumulative). - Honour backend caveats: absent cache fields -> 0, divide-by-zero guarded, a legitimate 0% renders plainly (not "no data").
Diffstat (limited to 'src/components/Table.svelte')
0 files changed, 0 insertions, 0 deletions