41 Commits

Author SHA1 Message Date
William Valentin ebc944702f chore: drop retired orb and sun VMs
Only the zap VM remains in the fleet. Remove orb/sun from the README
architecture/config docs, the getVMClassName allowlist, and their
.timeline-vm-tag color styles.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-27 10:38:04 -07:00
William Valentin 69eb87ebc9 feat(web-ui): improve Agents page legibility and scannability
Targeted UI/UX polish on the Agents page, keeping the existing dark
aesthetic and both Overview/Live view modes:

- Add a readable --text-mute token (dark + light) and apply it to the
  summary chips, lane meta, and idle/offline status, which previously
  used the near-invisible --text-dim.
- Event feed: demote the generic "Span Started/Completed" label to a
  quiet mono category tag and promote the tool name, with a left-edge
  accent by event kind (run/span/error/session). Scoped to
  #agents-content so other pages' feeds are unaffected.
- Active-op pills: add a per-kind left accent bar (tool/subagent/run).
- Lane sparkline: raise opacity and add a gradient so it actually reads.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-27 10:35:33 -07:00
William Valentin 5014d89258 feat(metrics): surface tool-span latency in stats and dashboard
Tool spans already carry duration_ms and status, but the metrics layer
only counted them. Expose that data:

- GetTopTools now returns avg/p95 duration and error count per tool.
- Timeseries buckets gain tool_avg_ms / tool_p95_ms (filtered
  percentile_cont over tool spans).
- Dashboard Top Tools shows avg latency per tool; the Latency panel,
  previously always empty (it read run-level duration that is never
  emitted), now plots real tool-span latency (min/avg/p95).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-23 11:16:23 -07:00
William Valentin c44e7fe72e refactor(web-ui): extract shared component primitives
Introduce components.js with barTrack, barRow, barRankList, metricPill,
metricStrip, and chartHeader helpers. Migrate dashboard.js and usage.js
to use these primitives, replacing 13 families of duplicated CSS
(stat-list, fw-bar, token-bar, metric-pill, chart-insight, chart-header,
usage-chart-total, etc.) with a unified .am-* namespace. Net: -256 lines.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-22 12:21:48 -07:00
William Valentin 8753c0c9d5 feat(web-ui): better stats and ergonomics
Usage page: add 7-day trend chart (activity/tokens/cost tabs),
framework breakdown panel with per-framework run/tool/error counts
and proportional bars, and 7d aggregate pills above the chart.

Dashboard: add avg cost/run metric pill to the metrics strip.

Run detail: extract and display prompt preview from the first agent
span's payload above the spans table.

Bug fixes: stat-list bars now render correctly (flex-direction:column),
right-panel-tab active background uses correct accent color, missing
framework colors added for hermes/codex/gemini/copilot. Dead code
renderSessionRow removed from sessions.js. Hardcoded font-family
replaced with CSS variable in metric-pill-value and token-stat-value.
Usage page cleanup() wired into router teardown.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-21 16:49:05 -07:00
William Valentin 78376bdd83 feat(query): include session totals and stable framework names 2026-05-20 17:35:56 -07:00
William Valentin 476c0e347f fix: count only live dashboard sessions 2026-04-30 17:07:17 -07:00
William Valentin 184aa5e6cb fix(web-ui): security hardening, SPA nav, and modularization
Ship the in-progress ES-module refactor of the web-ui (new static/modules/
layout, Usage/Settings pages, uplot-based dashboard) alongside a round of
security and UX fixes:

- main.go: add CSP + X-Frame-Options: DENY + X-Content-Type-Options:
  nosniff + Referrer-Policy middleware on every response; WS CheckOrigin
  now requires Origin host to match Host (blocks cross-site WebSocket
  hijacking); upgrade client before dialing upstream so origin check
  runs first; fatal on unparseable AGENTMON_QUERY_BASE.
- app.js: delegated click handler intercepts same-origin <a> clicks for
  SPA navigation (prev. every nav link caused a full page reload,
  dropping WS + in-memory state); delegated .copy-btn[data-copy]
  handler replaces inline onclick=; removed window.navigate /
  window.copyToClipboard globals and the duplicated handleGlobalSearch.
- modules/nav-signal.js: per-route AbortController so in-flight fetches
  are cancelled when the user navigates away, preventing stale toasts
  and wasted renders.
- modules/api.js: honours the nav signal by default; AbortError is
  silent.
- modules/router.js: resets the nav controller on every route; dropped
  the fixed 80ms transition delay; breadcrumbs no longer emit inline
  onclick= (delegated handler picks them up).
- modules/utils.js: renderCopyButton emits data-copy=\"...\" instead of
  nesting a JS string inside an HTML attribute — fixes an XSS where
  values containing ' broke out via &#39; decoding.

Verified: go build clean; `node --check` clean on all modified modules;
manual curl probes confirm security headers present on every response
and WS upgrade returns 403 for cross-origin/missing Origin while 101
for same-origin.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-04-23 15:36:12 -07:00
William Valentin 43113f6241 feat(web-ui): improve navigation and session UX 2026-04-21 13:07:05 -07:00
William Valentin c53283ac07 feat: improve web UI UX with global search, breadcrumbs, and better feedback 2026-03-26 14:24:52 -07:00
William Valentin 8bca99573b feat(web-ui): redesign dashboard and live sessions 2026-03-26 11:22:49 -07:00
William Valentin 5ff4794d98 feat(openclaw-monitor): add MinIO telemetry 2026-03-26 11:22:45 -07:00
William Valentin 6605780b58 feat(ingest): batch event writes and harden transport 2026-03-26 11:22:42 -07:00
William Valentin 43877a5448 feat(query-api): add richer stats and retention 2026-03-26 11:22:34 -07:00
William Valentin d49785cb25 fix: filter dashboard activity feed events 2026-03-20 14:05:59 -07:00
William Valentin 687a7aa79d Add live agent views and improve Codex monitoring 2026-03-20 13:59:51 -07:00
William Valentin f8ddea3698 feat: add agentmon services section to infrastructure page
Label all agentmon docker-compose services with agentmon.monitor=true
and agentmon.group=agentmon so the swarm-monitor picks them up.
Adds Group field to ServiceSnapshot, probes /healthz for api/web roles,
and renders a separate "Agentmon" section below Swarm Services on the
Infrastructure page with new api and worker card renderers.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-18 13:41:26 -07:00
William Valentin 1b3c74b441 fix: add /infrastructure to SPA catch-all routes 2026-03-18 10:27:06 -07:00
William Valentin cd2f345454 feat: rename OpenClaw to Infrastructure page, add service cards
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-18 10:20:28 -07:00
William Valentin 93edd39a2b feat: add infrastructure page CSS 2026-03-18 10:16:50 -07:00
William Valentin 07c16653cd feat: add swarm strip to dashboard
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-18 10:14:48 -07:00
William Valentin 7c043b78a4 feat: add swarm-monitor binary 2026-03-18 10:12:18 -07:00
William Valentin 13356adfbd feat: openclaw card dividers, running pulse, issue label section
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-14 12:16:30 -07:00
William Valentin acd89e95a9 feat: stat card top accents, timeline time hierarchy 2026-03-14 12:14:15 -07:00
William Valentin 5dbfd68fb5 feat: meta tiles, back link button, css chevron, span-details bg fix
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-14 12:11:55 -07:00
William Valentin eb12319f19 feat: framework color dots in sessions table, filter toolbar panel
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-14 12:05:40 -07:00
William Valentin 1c6255d688 feat: chart legend, fw bar height, feed fade, top tools mini bars 2026-03-14 12:02:49 -07:00
William Valentin 2c4b212ae6 feat: semantic accent colors on summary cards, infrastructure label
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-14 11:59:38 -07:00
William Valentin a6902e8d6c feat: refine global tokens, nav active state, section title 2026-03-14 11:55:58 -07:00
William Valentin ab7a83c50d feat: stacked area chart, framework breakdown on active sessions, tool bar visualization 2026-03-14 11:34:15 -07:00
William Valentin 063e41616a fix: active sessions query, chart update performance
- Active sessions query now finds truly active sessions (started
  anytime, no session.end ever) instead of only today's sessions
- Use uPlot setData() for live WS updates instead of destroying
  and recreating the chart on every event
- Destroy chart only on window change so it recreates with new scale

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-14 11:25:06 -07:00
William Valentin e7dd954f6a fix: ResizeObserver leak, CSS class lowercase, active sessions live update 2026-03-14 11:11:42 -07:00
William Valentin eaf73e5ff5 feat: add real-time dashboard with charts, stats, and activity feed
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-14 11:05:07 -07:00
William Valentin cac3404aa4 feat: add dashboard CSS styles 2026-03-14 11:03:26 -07:00
William Valentin d593c745aa feat: add uPlot CDN and dashboard nav link 2026-03-14 11:02:23 -07:00
William Valentin 9b78d65b1d feat: add stats summary and timeseries API endpoints 2026-03-14 11:01:40 -07:00
William Valentin 3434db3c59 feat: complete agent monitoring - hook, UI, and backend filter
- Add event_type and framework filters to events query endpoint
- Add /agents SPA route to web-ui server
- Add Agents nav link and route in frontend
- Add agents page CSS (timeline, VM pills, stats panel)
- Build VM status strip, activity timeline, and real-time stats
- Add agentmon hook for OpenClaw (HOOK.md + handler.ts)
- Add docker-compose, Dockerfile, and supporting infra files

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-14 00:26:42 -07:00
William Valentin 1927ec6622 feat: add static frontend with SPA routing
- Sessions list with filters (time, framework, host)
- Session detail with runs table
- Run detail with expandable spans
- Dark theme GitHub-style UI
- API proxy to query-api via /api

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-17 01:59:16 -08:00
William Valentin d71b6ae537 feat: add sessions and runs endpoints to query-api
GET /v1/sessions - list sessions with filters
GET /v1/sessions/:id - session detail with runs
GET /v1/runs/:id - run detail with spans

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-17 01:57:40 -08:00
William Valentin 2fd4fe0ae0 feat: add validation to ingest gateway
HTTP and WebSocket handlers now validate events before publishing.
Returns detailed error info on validation failures.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-17 01:56:04 -08:00
William Valentin 256b841cbf feat: scaffold agentmon services and k8s deploy
Adds Go microservices (ingest-gateway, event-processor, query-api, web-ui), NATS+Postgres wiring, initial schema/init job, ingress manifests for LAN+tailnet, and a multi-arch image build script.
2026-01-17 01:06:57 -08:00