Skip to content

feat(webapp): console dashboard driven by kb.activity#454

Merged
plind-junior merged 16 commits into
testfrom
feat/console-dashboard
Jul 10, 2026
Merged

feat(webapp): console dashboard driven by kb.activity#454
plind-junior merged 16 commits into
testfrom
feat/console-dashboard

Conversation

@plind-junior

Copy link
Copy Markdown
Member

adds a console dashboard as the landing view, modeled on agents-view style session analytics but driven by vouch's own audit log: a 12-month activity calendar (ember heat ramp, themed for dark and light), last-30-days bars, an hour-of-week heatmap, top actors and event mix, plus stat tiles from kb.status / kb.stats. / now redirects to /dashboard instead of chat and the tab leads the sidebar.

the data comes from a new kb.activity read method — one pass over the audit log returning per-day buckets with proposal/decision breakdowns, a 7×24 hour-of-week matrix, and actor/event histograms. kb.audit's tail-limited raw events and kb.stats' review aggregates don't cover this, and shipping raw events to the browser wouldn't scale with the append-only log. registered at all four sites (mcp tool, jsonl handler, capabilities methods, vouch activity cli) plus trust read methods; pure read, no new write path.

windowing is viewer-local calendar days so the oldest heatmap cell is never partially counted (days=0 for all-time, negatives rejected). local bucketing prefers an iana tz name — dst-correct across the year — and falls back to a clamped fixed utc offset. scoping goes through the same viewer context as kb.audit so multi-project kbs don't leak actor names or activity timing across project boundaries.

the view degrades cleanly: endpoints that don't advertise kb.activity get an upgrade hint, empty audit logs get an empty state, and a malformed stats payload can't blank the landing page. the calendar fetches 371 days so its oldest drawn column always sits inside the server window, and chart aria-labels carry totals and peaks for non-mouse users.

note: this branch is based on the local transcript-viewer work (14 commits ending at 776bffb) that wasn't yet on origin/test, so those commits ride along here; the dashboard itself is the last two commits. merge-tree against origin/test is clean, including the bulk-clear merge (#434).

verified on the exact shipped commits in a detached worktree: pytest 1185 passed, mypy and ruff clean, vitest 145 passed, tsc clean; rendered live against a real kb in both themes.

one pass over the audit log returning per-day counts (with
proposal/decision breakdowns), an hour-of-week matrix, and actor/event
histograms — the data a dashboard needs that kb.audit's tail-limited
raw events and kb.stats' review aggregates don't cover.

windowed in viewer-local calendar days so the oldest heatmap cell is
never partially counted (days=0 for all-time, negatives rejected).
local bucketing prefers an iana tz name (dst-correct across the year)
and falls back to a clamped fixed utc offset. scope-filtered through
the same viewer context as kb.audit so multi-project kbs don't leak
actor names or activity timing across project boundaries.

registered at all four sites (mcp tool, jsonl handler, capabilities
methods, vouch activity cli) plus trust read methods.
new /dashboard view driven by kb.activity: a 12-month activity
calendar (ember heat ramp themed for dark and light via --heat-* css
vars), last-30-days bars, an hour-of-week heatmap, and top-actor /
event-mix bar lists, with stat tiles fed by kb.status and kb.stats.

the calendar fetches 371 days so its oldest drawn column always sits
inside the server window, sends the browser's iana timezone for
dst-correct bucketing, and degrades cleanly: endpoints that don't
advertise kb.activity get an upgrade hint, empty audit logs get an
empty state, and a malformed stats payload no longer crashes the view.

/ now redirects to the dashboard instead of chat and the tab leads the
sidebar; the e2e smoke flow clicks through to chat accordingly.
@coderabbitai

coderabbitai Bot commented Jul 10, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 688dc37a-6c92-45e0-9dee-2f6ba7b53e9d

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/console-dashboard

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions github-actions Bot added docs documentation, specs, examples, and repo guidance cli command line interface mcp mcp, jsonl, and http surfaces tests tests and fixtures size: XL 1000 or more changed non-doc lines labels Jul 10, 2026
@plind-junior plind-junior merged commit 02bcd3a into test Jul 10, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli command line interface docs documentation, specs, examples, and repo guidance mcp mcp, jsonl, and http surfaces size: XL 1000 or more changed non-doc lines tests tests and fixtures

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant