Metrics

Metrics Dashboard

The home page tabbed dashboard for tool usage, code reviews, knowledge reads, and review performance.

The home page is a tabbed dashboard of organization metrics rendered with Apache ECharts. Every panel is a single-organization, window-scoped query served by cached read endpoints; the dashboard never reads raw rows. See Metrics Pipeline for how the underlying data is captured and stored.

Window and Refresh

A shared time window selector sits above the tabs and applies to every panel, so switching the range reshapes the whole dashboard at once. Nine fixed windows are available — 15m, 30m, 1h, 4h, 12h, 24h (default), 7d, 14d, and 30d — and the set is closed on the server, so arbitrary ranges are rejected by construction and query plans stay predictable.

Auto-refresh runs next to the window selector with three modes: off, every 45 seconds, and every 3 minutes (persisted per browser). A manual refresh button and an "Updated Xs ago" label are always available. Auto-refresh pauses while you interact with a chart (for example dragging a zoom brush) so a tick never yanks a chart out from under you, and it never overlaps an in-flight refresh.

Only the active tab is mounted; switching to a tab (or changing the window or a filter) reloads just that tab's panels.

Tabs

Overview

Headline stat cards for the window: total tool calls, knowledge reads, and reviews, plus critical and major finding totals and the p95 review duration. New installs with no data in the window show an empty state instead of zeros-everywhere noise.

MCP Usage

  • Tool calls by user — a stacked area of MCP tool-call volume, one band per user.
  • Tool calls by agent — a stacked bar grouped by the connecting agent (for example claude-code, opencode, cursor).

Filters: user and tool (multi-select). High-cardinality groupings are capped to the top series with the remainder folded into a single Other band so the chart stays readable.

Code Reviews

Sourced directly from code-review records (not the metric pipeline):

  • Findings by severity — a stacked bar of critical/major/minor/suggestion/comment totals per repository (or author).
  • Review volume — bucketed review counts over time.
  • Review mix — a donut of review volume by series.

Filters: repository and author (multi-select) and origin (single-select: repository webhook, agent, or manual). Repository options include repositories whose mapping was later removed, so historical review data stays selectable; repositories that share a display name are disambiguated with a short id suffix.

Knowledge Base

  • Knowledge reads by library — a stacked area of document, section, and snippet reads combined, one band per library.
  • Most-read paths — a ranked horizontal bar (a leaderboard, not a time series) of the most-read document paths across section and snippet reads.

Filter: library (single-select), which scopes both panels.

Performance & Cost

  • Review duration percentiles — p50/p95/p99 lines over the window.
  • Duration vs. tokens — a scatter of review duration against token count; samples with no recorded token count are omitted.
  • Review cost — reserved for a future per-run cost feature; it shows a "coming soon" empty state today.

Empty States

Every panel renders an explicit "no data for this window" placeholder rather than a blank chart, because a new organization (or a short window) legitimately has empty partitions. Stat cards fall back to an em dash while loading.