refactor: finish the AgentHub rename and drop the MCP server

Two leftovers from the rebrand, done together because they touch the same
docs and manifests.

**Data directory.** `agent-dashboard` could not simply be renamed in the
source: it names a real directory holding the live SQLite database. Startup
now moves it once, via `migrateLegacyDataDir()` in `server/lib/claude-home.js`
— a same-filesystem rename, so it is instant even at multiple gigabytes and
cannot leave two divergent copies. `getDataDir()` stays PURE and resolves to
the legacy path until the move happens; the first version of this put the
rename inside the getter, which meant `npm run test:server` relocated the
developer's real database as a side effect. The call sits behind
`require.main === module` and ahead of the router requires, because those pull
in db.js, which opens SQLite at module load. A failed rename is silent and the
old directory keeps being used: an unfashionable directory name beats a blank
database beside an unreachable one. Same treatment for the port-discovery file
(`.agent-dashboard.json` → `.agenthub.json`, old one dropped on write).

Not renamed on purpose: the Sagi localStorage keys (renaming silently resets
everyone's prefs) and the PWA manifest `id` (changing it orphans an installed
app).

**MCP server.** 4 tool calls in 46 days across 577,132 events, against 4,556
lines of TypeScript, a 2 MB committed build artifact, and a pre-commit guard
that had already blocked commits twice. Deleted: `mcp/`, the maintainer skills
and `mcp-reviewer` agent, the build check, `plugins/agenthub/.mcp.json`,
`docs/MCP.md`, 12 npm scripts, 5 Makefile targets, and every doc section
describing it.

Kept, because they are unrelated things sharing the name: the Config
Explorer's MCP tab and its API, per-lane Playwright MCP, the agenthub-config
plugin's MCP audit, and the historical `mcp__plugin_agenthub_*` events that
analytics must keep attributing.

Verified: server 1432/1432, client 459/459, tsc clean, prettier clean. Both
directions of the migration proven — a sandbox-HOME test run leaves the legacy
directory untouched, and a real boot moves it with its contents intact.
This commit is contained in:
2026-09-08 09:48:40 +07:00
parent 11dcc04ac4
commit c7dbaf2d9f
210 changed files with 405 additions and 59408 deletions
-21
View File
@@ -1,21 +0,0 @@
---
name: mcp-maintainer
description: Operate and maintain the local MCP server for this repository. Use for MCP tool updates, policy-guard changes, host configuration, and MCP runtime troubleshooting.
---
# MCP Maintainer Skill
## Workflow
- Confirm dashboard API availability (`/api/health`).
- Inspect affected MCP domain modules under `mcp/src/tools/domains/`.
- Preserve safety gates in `mcp/src/policy/tool-guards.ts`.
- Validate with `npm run mcp:typecheck` and `npm run mcp:build`.
## Safety rules
- Keep loopback-only target checks enabled.
- Keep mutating and destructive tools behind explicit flags.
- Do not log protocol data to stdout.
## References
- `references/tool-domain-map.md`
- `references/operations-runbook.md`
@@ -1,4 +0,0 @@
interface:
display_name: "MCP Maintainer"
short_description: "Maintain MCP tools, policy gates, and host integration."
default_prompt: "Use mcp-maintainer to update MCP tooling safely and verify runtime integrity."
@@ -1,14 +0,0 @@
# MCP Operations Runbook
## Modes
- Read-only:
- `MCP_DASHBOARD_ALLOW_MUTATIONS=false`
- `MCP_DASHBOARD_ALLOW_DESTRUCTIVE=false`
- Admin:
- Set mutations true for controlled maintenance operations.
- Destructive:
- Set both true and require `confirmation_token = CLEAR_ALL_DATA`.
## Verification
- `npm run mcp:typecheck`
- `npm run mcp:build`
@@ -1,8 +0,0 @@
# MCP Tool Domain Map
- `observability-tools.ts`: health, stats, analytics, snapshots, export.
- `session-tools.ts`: list/get/create/update sessions.
- `agent-tools.ts`: list/get/create/update agents.
- `event-tools.ts`: event listing and hook ingestion.
- `pricing-tools.ts`: pricing CRUD and cost calculations.
- `maintenance-tools.ts`: cleanup, reimport, reinstall hooks, destructive clear.
-1
View File
@@ -14,7 +14,6 @@ description: Run release-readiness checks for this repository. Use when validati
## Focus areas
- Hook flow and failure behavior.
- Session/agent lifecycle semantics.
- MCP safety gates and host setup instructions.
- Troubleshooting accuracy.
## References
@@ -1,7 +1,7 @@
# Release Checklist
- Commands in docs exist in root `package.json`.
- Validation steps are documented for backend, frontend, and MCP.
- Validation steps are documented for backend and frontend.
- Behavior-changing diffs mention migration/compatibility impacts.
- Safety-sensitive operations remain guarded by explicit flags.
- Troubleshooting sections reflect the current architecture.
+1 -2
View File
@@ -7,14 +7,13 @@ description: Understand this repository quickly before making changes. Use for a
## Workflow
- Read `AGENTS.md`, `README.md`, and `ARCHITECTURE.md`.
- Determine target layer: `server/`, `client/`, `mcp/`, or docs.
- Determine target layer: `server/`, `client/`, or docs.
- Identify the minimal file set needed for the task.
- Select verification commands before editing.
## Verification defaults
- Backend: `npm run test:server`
- Frontend: `npm run test:client`
- MCP: `npm run mcp:typecheck` and `npm run mcp:build`
## References
- `references/module-map.md`
@@ -6,4 +6,3 @@
- `server/websocket.js`: live update broadcast path.
- `client/src/pages/`: route-level UI.
- `client/src/components/`: reusable UI primitives.
- `mcp/src/tools/domains/`: MCP tool families.
@@ -4,8 +4,5 @@
- `npm run test:server`
- Frontend changes:
- `npm run test:client`
- MCP changes:
- `npm run mcp:typecheck`
- `npm run mcp:build`
- Docs-only changes:
- validate command consistency against root `package.json`
+5 -5
View File
@@ -1,6 +1,6 @@
{
"name": "claude-code-agent-monitor-plugins",
"description": "Official plugin marketplace for AgentHub — the `agenthub` plugin installs the dashboard itself (hooks, server, CLI, MCP), plus 10 focused plugins for analytics, cost guardrails, productivity, developer tools, AI insights, session forensics, workflow/fleet intelligence, reliability/SLOs, config & memory governance, and dashboard connectivity. Every plugin is powered by the local Agent Monitor API.",
"description": "Official plugin marketplace for AgentHub — the `agenthub` plugin installs the dashboard itself (hooks, server, CLI), plus 10 focused plugins for analytics, cost guardrails, productivity, developer tools, AI insights, session forensics, workflow/fleet intelligence, reliability/SLOs, config & memory governance, and dashboard connectivity. Every plugin is powered by the local Agent Monitor API.",
"owner": {
"name": "smartgift",
"url": "https://git.smartgift.io.vn/Smartgift-AI"
@@ -11,8 +11,8 @@
{
"name": "agenthub",
"source": "./",
"description": "The dashboard itself. Installs the Claude Code event hooks, boots the local server, puts the `agenthub` CLI on PATH and connects the MCP tools — no checkout and no `npm run setup`. Install this one first; the ten focused plugins below all read from the API it provides.",
"tags": ["dashboard", "monitoring", "hooks", "mcp", "cli"]
"description": "The dashboard itself. Installs the Claude Code event hooks, boots the local server, and puts the `agenthub` CLI on PATH — no checkout and no `npm run setup`. Install this one first; the ten focused plugins below all read from the API it provides.",
"tags": ["dashboard", "monitoring", "hooks", "cli"]
},
{
"name": "agenthub-analytics",
@@ -71,8 +71,8 @@
{
"name": "agenthub-dashboard",
"path": "plugins/agenthub-dashboard",
"description": "Dashboard connector — quick status checks, one-line metrics, live activity watch, endpoint probing, and MCP server integration for direct tool access to the Agent Monitor API.",
"tags": ["dashboard", "status", "mcp", "connector"]
"description": "Dashboard connector — quick status checks, one-line metrics, live activity watch, and endpoint probing against the Agent Monitor API.",
"tags": ["dashboard", "status", "connector"]
}
]
}
+2 -3
View File
@@ -1,6 +1,6 @@
{
"name": "agenthub",
"description": "AgentHub — the full local-first dashboard as a plugin. Installs the event hooks, boots the dashboard server, puts the `agenthub` CLI on PATH, and connects the MCP tools. No checkout, no npm run setup.",
"description": "AgentHub — the full local-first dashboard as a plugin. Installs the event hooks, boots the dashboard server, and puts the `agenthub` CLI on PATH. No checkout, no npm run setup.",
"author": {
"name": "Nguyễn Ngọc Trí Vĩ",
"url": "https://git.smartgift.io.vn/Smartgift-AI"
@@ -8,7 +8,7 @@
"homepage": "https://git.smartgift.io.vn/Smartgift-AI/Claude-Code-Monitor",
"repository": "https://git.smartgift.io.vn/Smartgift-AI/Claude-Code-Monitor.git",
"license": "MIT",
"keywords": ["dashboard", "monitoring", "sessions", "cost", "lanes", "mcp", "claude-code"],
"keywords": ["dashboard", "monitoring", "sessions", "cost", "lanes", "claude-code"],
"commands": [
"./plugins/agenthub/commands/agenthub-doctor.md",
"./plugins/agenthub/commands/agenthub-update.md",
@@ -32,7 +32,6 @@
"./plugins/agenthub/commands/ship-full.md",
"./plugins/agenthub/commands/ship-quick.md"
],
"mcpServers": "./plugins/agenthub/.mcp.json",
"hooks": {
"PreToolUse": [
{
+1 -1
View File
@@ -8,5 +8,5 @@ paths:
- Keep command examples executable and aligned with actual scripts.
- Use absolute or clearly rooted paths when discussing project files.
- When adding architecture claims, reflect current code behavior.
- Update all affected docs together (`README`, `ARCHITECTURE`, `SETUP`, `INSTALL`, `mcp/README`) when workflows change.
- Update all affected docs together (`README`, `ARCHITECTURE`, `SETUP`, `INSTALL`) when workflows change.
- Prefer concise sections and concrete troubleshooting steps.
-17
View File
@@ -1,17 +0,0 @@
---
paths:
- "mcp/src/**/*.ts"
- "mcp/package.json"
- "mcp/tsconfig.json"
- "mcp/.env.example"
- "mcp/README.md"
---
# MCP Server Rules
- Keep MCP tool names stable and descriptive.
- Keep destructive operations behind explicit guardrails.
- Route all logs to stderr only; never write protocol logs to stdout.
- Keep tool input schemas strict and bounded.
- Preserve loopback-only API target enforcement unless security posture changes by request.
- Verify MCP with `npm run mcp:typecheck` and `npm run mcp:build` after code edits.
-1
View File
@@ -25,5 +25,4 @@ This directory contains all project-scoped Codex extensions:
## Included skills
- `repo-onboarding` — architecture discovery and verification selection
- `mcp-maintainer` — MCP server operations and troubleshooting
- `release-guard` — release readiness checks
-21
View File
@@ -1,21 +0,0 @@
---
name: mcp-maintainer
description: Operate and maintain the local MCP server for this repository. Use for MCP tool updates, policy-guard changes, host configuration, and MCP runtime troubleshooting.
---
# MCP Maintainer Skill
## Workflow
- Confirm dashboard API availability (`/api/health`).
- Inspect affected MCP domain modules under `mcp/src/tools/domains/`.
- Preserve safety gates in `mcp/src/policy/tool-guards.ts`.
- Validate with `npm run mcp:typecheck` and `npm run mcp:build`.
## Safety rules
- Keep loopback-only target checks enabled.
- Keep mutating and destructive tools behind explicit flags.
- Do not log protocol data to stdout.
## References
- `references/tool-domain-map.md`
- `references/operations-runbook.md`
@@ -1,4 +0,0 @@
interface:
display_name: "MCP Maintainer"
short_description: "Maintain MCP tools, policy gates, and host integration."
default_prompt: "Use mcp-maintainer to update MCP tooling safely and verify runtime integrity."
@@ -1,14 +0,0 @@
# MCP Operations Runbook
## Modes
- Read-only:
- `MCP_DASHBOARD_ALLOW_MUTATIONS=false`
- `MCP_DASHBOARD_ALLOW_DESTRUCTIVE=false`
- Admin:
- Set mutations true for controlled maintenance operations.
- Destructive:
- Set both true and require `confirmation_token = CLEAR_ALL_DATA`.
## Verification
- `npm run mcp:typecheck`
- `npm run mcp:build`
@@ -1,8 +0,0 @@
# MCP Tool Domain Map
- `observability-tools.ts`: health, stats, analytics, snapshots, export.
- `session-tools.ts`: list/get/create/update sessions.
- `agent-tools.ts`: list/get/create/update agents.
- `event-tools.ts`: event listing and hook ingestion.
- `pricing-tools.ts`: pricing CRUD and cost calculations.
- `maintenance-tools.ts`: cleanup, reimport, reinstall hooks, destructive clear.
-1
View File
@@ -14,7 +14,6 @@ description: Run release-readiness checks for this repository. Use when validati
## Focus areas
- Hook flow and failure behavior.
- Session/agent lifecycle semantics.
- MCP safety gates and host setup instructions.
- Troubleshooting accuracy.
## References
@@ -1,7 +1,7 @@
# Release Checklist
- Commands in docs exist in root `package.json`.
- Validation steps are documented for backend, frontend, and MCP.
- Validation steps are documented for backend and frontend.
- Behavior-changing diffs mention migration/compatibility impacts.
- Safety-sensitive operations remain guarded by explicit flags.
- Troubleshooting sections reflect the current architecture.
+1 -2
View File
@@ -7,14 +7,13 @@ description: Understand this repository quickly before making changes. Use for a
## Workflow
- Read `AGENTS.md`, `README.md`, and `ARCHITECTURE.md`.
- Determine target layer: `server/`, `client/`, `mcp/`, or docs.
- Determine target layer: `server/`, `client/`, or docs.
- Identify the minimal file set needed for the task.
- Select verification commands before editing.
## Verification defaults
- Backend: `npm run test:server`
- Frontend: `npm run test:client`
- MCP: `npm run mcp:typecheck` and `npm run mcp:build`
## References
- `references/module-map.md`
@@ -6,4 +6,3 @@
- `server/websocket.js`: live update broadcast path.
- `client/src/pages/`: route-level UI.
- `client/src/components/`: reusable UI primitives.
- `mcp/src/tools/domains/`: MCP tool families.
@@ -4,8 +4,5 @@
- `npm run test:server`
- Frontend changes:
- `npm run test:client`
- MCP changes:
- `npm run mcp:typecheck`
- `npm run mcp:build`
- Docs-only changes:
- validate command consistency against root `package.json`
+1 -3
View File
@@ -16,8 +16,7 @@ Node, build tools, or Python on your machine — or if you're on a GitHub Codesp
- **GitHub Codespaces:** *Code → Create codespace on this branch*.
The first build runs `.devcontainer/post-create.sh`, which installs all workspace
dependencies (`npm run setup`) and builds the MCP server (`npm run mcp:install`,
`npm run mcp:build`).
dependencies (`npm run setup`).
## What's inside
@@ -38,7 +37,6 @@ npm run dev # server on :4820 + Vite client on :5173
npm start # production-style server (serves client/dist)
npm run test:server # node --test
npm run test:client # vitest
npm run test:mcp # MCP server tests
npm run openapi:yaml # regenerate openapi.yaml from the live spec
```
+2 -2
View File
@@ -5,7 +5,7 @@
// open the repo in a GitHub Codespace. It changes nothing for host-based dev.
//
// Covers the full project: the Express server (4820), the React/Vite client
// (5173), the MCP server, and the VS Code extension. The native `better-sqlite3`
// (5173) and the VS Code extension. The native `better-sqlite3`
// addon builds here (build-essential + python3 are installed in the Dockerfile).
//
// NOTE (issue #193): Claude Code hooks are a HOST-side concern. This container
@@ -40,7 +40,7 @@
}
},
// Install root + client + vscode-extension deps and build the MCP server.
// Install root + client + vscode-extension deps.
// Never installs Claude Code hooks (host-only — see note above).
"postCreateCommand": "bash .devcontainer/post-create.sh",
"waitFor": "postCreateCommand",
+2 -8
View File
@@ -1,6 +1,6 @@
#!/usr/bin/env bash
# Dev-container bootstrap. Installs all workspace dependencies and builds the
# MCP server. Runs once, after the container is created.
# Dev-container bootstrap. Installs all workspace dependencies. Runs once,
# after the container is created.
#
# Deliberately does NOT install Claude Code hooks: hooks are a host-side concern
# (issue #193) and `scripts/install-hooks.js` refuses to run inside a container.
@@ -10,10 +10,6 @@ set -euo pipefail
echo "▶ Installing server + client + vscode-extension dependencies (npm run setup)…"
npm run setup
echo "▶ Installing and building the MCP server…"
npm run mcp:install
npm run mcp:build
cat <<'EOF'
✅ Dev environment ready.
@@ -25,8 +21,6 @@ cat <<'EOF'
Test:
npm run test:server # node --test
npm run test:client # vitest
npm run test:mcp # MCP server tests
npm run mcp:typecheck # MCP type check
Docs:
npm run openapi:yaml # regenerate openapi.yaml from the live spec
+1 -1
View File
@@ -8,7 +8,7 @@
# DASHBOARD_PORT=4820
# Directory the built client is served from in production (default: client/dist).
# The `agenthub` plugin install points this at ~/.claude/agent-dashboard/runtime/client-dist
# The `agenthub` plugin install points this at ~/.claude/agenthub/runtime/client-dist
# because the plugin cache directory is read-only and replaced on every update.
# DASHBOARD_CLIENT_DIST=
-4
View File
@@ -6,10 +6,6 @@ jspm_packages/
dist/
build/
client/dist/
# mcp/build/ is deliberately COMMITTED: Claude Code starts a plugin's MCP
# servers the moment the session opens, so the artifact has to exist before any
# bootstrap could build it. Freshness is enforced by scripts/check-mcp-build.js.
!mcp/build/
desktop/out/
desktop/release/
desktop/assets/icon.iconset/
+1 -10
View File
@@ -36,16 +36,7 @@ else
echo "🎨 No staged files to format."
fi
# ── 2. Committed MCP build must match mcp/src ───────────────────────────────
# mcp/build/ is committed because a plugin's MCP server starts before any
# bootstrap could build it. Only enforced when mcp/src is part of this commit,
# so unrelated commits are not blocked by a stale artifact.
if git diff --cached --name-only --diff-filter=ACMR | grep -q '^mcp/src/'; then
echo "🔌 Checking the committed MCP build against mcp/src..."
node scripts/check-mcp-build.js
fi
# ── 3. Run tests — commit is blocked unless all pass ────────────────────────
# ── 2. Run tests — commit is blocked unless all pass ────────────────────────
# Each suite is retried once on failure. The full run executes dozens of test
# files concurrently, each starting its own server (plus the CLI suite's
# spawned child processes with hard kill timeouts), so a loaded machine can
-1
View File
@@ -13,7 +13,6 @@ index.html
wiki/index.html
*.yml
*.yaml
mcp/build/
desktop/out/
desktop/release/
desktop/node_modules/
+1 -4
View File
@@ -2,7 +2,7 @@
## Project intent
- Keep this repository a stable, local-first Claude Code monitoring platform.
- Maintain correctness across hooks, API, DB, websocket, UI, and MCP integration.
- Maintain correctness across hooks, API, DB, websocket, and UI.
## Priorities
- Correctness over cleverness.
@@ -51,13 +51,11 @@ it as the same instruction as this section and just make the real call.
## Where to work
- `server/` for API/routes/data processing.
- `client/` for React UI behavior.
- `mcp/` for local MCP server tooling.
- `scripts/` for hook/install/import/cleanup utilities.
## Validation expectations
- Backend changes: run `npm run test:server` when possible.
- Frontend changes: run `npm run test:client` when possible.
- MCP changes: run `npm run mcp:typecheck` and `npm run mcp:build`.
- If any check is skipped, report it explicitly.
## Safety expectations
@@ -69,4 +67,3 @@ it as the same instruction as this section and just make the real call.
- Setup: `npm run setup`
- Dev: `npm run dev`
- Build/start: `npm run build` then `npm start`
- MCP helpers: `npm run mcp:install`, `npm run mcp:build`, `npm run mcp:start`
+9 -161
View File
File diff suppressed because one or more lines are too long
+2 -8
View File
@@ -5,15 +5,13 @@ _Last synced: 58774f2 (2026-09-04) + per-node run command (`agenthub lanes node`
## Project mission
- Maintain a reliable local-first dashboard for Claude Code session monitoring.
- Preserve real-time behavior (hooks -> API -> SQLite -> WebSocket -> UI).
- Keep MCP integration production-ready for local use (`mcp/`).
## Repo map
- `server/`: Express API, hook ingestion, SQLite access, websocket broadcast (includes optional git upstream checks and `routes/updates.js`, plus `lib/workflow-ingest.js` which ingests on-disk Workflow-tool run journals — fleets that emit no hooks — and `lib/codex-ingest.js`, the same idea for `codex` lanes: it tails Codex's own rollout journals because Codex emits no hooks at all).
- `client/`: React + Vite UI.
- `scripts/`: hook installer/handler, import, seed, cleanup utilities. (Update detection lives server-side in `server/lib/update-check.js`. `POST /api/updates/apply` (only when the checkout is fast-forwardable) pulls, rebuilds, and self-restarts via `server/lib/self-restart.js` + the detached `scripts/restart-helper.js`; otherwise users run the printed manual command, surfaced in the UI and by `agenthub update-check`.)
- `mcp/`: local MCP server exposing dashboard operations as tools. **`mcp/build/` is committed on purpose** — plugin MCP servers start before any bootstrap could build them; `scripts/check-mcp-build.js` (content hash in `mcp/build/.srchash`, run by pre-commit and `/agenthub-doctor`) keeps it honest. Rebuild with `npm run mcp:build`, never hand-edit `mcp/build/`.
- `skills/`: this repo's skills. Because the repo root **is** the `agenthub` plugin root, this is also the plugin's skills directory — every skill here ships to anyone who installs the plugin, addressed as `/agenthub:<name>` (bare `/<name>` works as an alias). Put a skill here only if it should reach plugin users; `agenthub skills install` remains a fallback that copies `ship-feature-lane` into `~/.claude/skills/` for plain checkouts. - `agents/`: the same story for subagents — plugin root, so all five (`qc-local`, `senior-gate-reviewer`, `backend-reviewer`, `frontend-reviewer`, `mcp-reviewer`) ship as `agenthub:<name>`. This is also the source `agenthub lanes agents install` copies the two pipeline agents from into a lane's `.claude/agents/`, which is what keeps the bare `subagent_type: qc-local` working there. One file per agent, never a second copy.
- `.claude-plugin/`: the marketplace plus the root `agenthub` plugin manifest (`"source": "./"` — the whole repo is the plugin). Its hooks are inline in `plugin.json`; its commands live in `plugins/agenthub/commands/`, which is NOT a subdirectory plugin. `scripts/plugin-bootstrap.js` runs from `SessionStart` and owns the writable runtime under `~/.claude/agent-dashboard/runtime/` — it never writes into the plugin cache, which Claude Code replaces on every update. See `docs/PLUGINS.md`.
- `skills/`: this repo's skills. Because the repo root **is** the `agenthub` plugin root, this is also the plugin's skills directory — every skill here ships to anyone who installs the plugin, addressed as `/agenthub:<name>` (bare `/<name>` works as an alias). Put a skill here only if it should reach plugin users; `agenthub skills install` remains a fallback that copies `ship-feature-lane` into `~/.claude/skills/` for plain checkouts. - `agents/`: the same story for subagents — plugin root, so all four (`qc-local`, `senior-gate-reviewer`, `backend-reviewer`, `frontend-reviewer`) ship as `agenthub:<name>`. This is also the source `agenthub lanes agents install` copies the two pipeline agents from into a lane's `.claude/agents/`, which is what keeps the bare `subagent_type: qc-local` working there. One file per agent, never a second copy.
- `.claude-plugin/`: the marketplace plus the root `agenthub` plugin manifest (`"source": "./"` — the whole repo is the plugin). Its hooks are inline in `plugin.json`; its commands live in `plugins/agenthub/commands/`, which is NOT a subdirectory plugin. `scripts/plugin-bootstrap.js` runs from `SessionStart` and owns the writable runtime under `~/.claude/agenthub/runtime/` — it never writes into the plugin cache, which Claude Code replaces on every update. See `docs/PLUGINS.md`.
- **Reporting a required plugin is derived; installing one is allowlisted.** `server/lib/skill-plugins.js` reads the `/plugin:skill` strings out of the loaded pipeline templates — right for the `/agenthub-doctor` row, wrong for an install: a template is a file anyone can drop into `DASHBOARD_PIPELINES_DIR`, so installing whatever name it contains would make "edit a JSON file" mean "run this vendor's install command next session". The bootstrap installs only what `AUTO_INSTALLABLE` (a constant in that file, `superpowers` today) lists, in its DETACHED worker, never in the 10 s hook, recorded once as `state.skillPluginsSettled` (also gating `fastPathOk`), never throwing, and off under `AGENTHUB_AUTO_INSTALL_PLUGINS=0|false|off`. Do not derive an install target from a template.
## Lanes
@@ -57,15 +55,11 @@ See `docs/LANES.md` for full guide: stage reporting, custom templates, lane acti
- Prod build/start: `npm run build` then `npm start`
- Server tests: `npm run test:server`
- Client tests: `npm run test:client`
- MCP install/build/start: `npm run mcp:install`, `npm run mcp:build`, `npm run mcp:start`
- MCP build freshness: `npm run mcp:check-build` (must pass whenever `mcp/src` changes)
- MCP typecheck: `npm run mcp:typecheck`
- CLI (after setup): `agenthub <command>` — terminal access to the full dashboard surface (`bin/agenthub.js`; `agenthub help` lists commands)
## Testing and verification policy
- Backend changes: run `npm run test:server` before finishing.
- Frontend changes: run `npm run test:client` when relevant. This includes per-screen render snapshots (`client/src/pages/__tests__/screens.snapshot.test.tsx`). If a UI change is intentional, review the snapshot diff and regenerate baselines with `cd client && npx vitest run -u`; never blindly update snapshots to make tests pass.
- MCP changes: run `npm run mcp:typecheck` and `npm run mcp:build`.
- If you cannot run a verification step, state exactly what was not run and why.
## Change guidelines by area
+1 -1
View File
@@ -60,7 +60,7 @@ ENV NODE_ENV=production
ENV DASHBOARD_HOST=0.0.0.0
# The recommended ~/.claude bind mount is read-only, so the server cannot write
# its default data dir (~/.claude/agent-dashboard). Persist to the mounted
# its default data dir (~/.claude/agenthub). Persist to the mounted
# volume at /app/data instead.
ENV DASHBOARD_DATA_DIR=/app/data
+5 -46
View File
@@ -12,7 +12,7 @@ If all you want is a working dashboard, skip every step below. From Claude Code:
```
The next session start installs the hooks, boots the server, puts the `agenthub` CLI
on PATH and connects the MCP tools — no clone, no `npm run setup`, no
on PATH — no clone, no `npm run setup`, no
`npm run install-hooks`, no manual `npm start`. Run `/agenthub-doctor` to check the
result and `/agenthub-open` to build the UI and get the URL.
@@ -61,7 +61,7 @@ npm install
`npm run setup` additionally installs the VS Code extension and links the `agenthub` CLI. (If you install with `--ignore-scripts`, the `postinstall` hook is skipped — run `cd client && npm install` manually in that case.)
Or via Makefile (also installs MCP dependencies):
Or via Makefile:
```bash
make setup
@@ -204,47 +204,6 @@ and, for plugin installs, [`docs/PLUGINS.md` → Auto-start on boot](docs/PLUGIN
---
## Optional: Local MCP server
If you want AI agents to call dashboard functionality through MCP tools, run the local MCP server in `mcp/`:
```bash
npm run mcp:install
npm run mcp:build
npm run mcp:start # stdio (for MCP host integration)
npm run mcp:start:http # HTTP + SSE server on port 8819
npm run mcp:start:repl # interactive CLI with tab completion
```
The MCP server supports three transport modes:
```mermaid
graph LR
HOST["MCP Host<br/>(Claude Code / Desktop)"] -->|"stdin/stdout"| STDIO["stdio mode<br/>mcp:start"]
RC["Remote Client"] -->|"POST /mcp<br/>GET /sse"| HTTP["HTTP mode<br/>mcp:start:http<br/>:8819"]
OP["Operator"] -->|"interactive CLI"| REPL["REPL mode<br/>mcp:start:repl"]
STDIO --> API["Dashboard API<br/>http://127.0.0.1:4820/api/*"]
HTTP --> API
REPL --> API
style STDIO fill:#6366f1,stroke:#818cf8,color:#fff
style HTTP fill:#f59e0b,stroke:#fbbf24,color:#000
style REPL fill:#a855f7,stroke:#c084fc,color:#fff
```
See [mcp/README.md](./mcp/README.md) for host config, tool catalog, and safety flags.
To build the MCP server as a container image instead:
```bash
npm run mcp:docker:build
# or
npm run mcp:podman:build
```
---
## Optional: Agent extension packs
This repository includes extension packs for both Claude Code and Codex.
@@ -329,7 +288,7 @@ podman build -t agent-monitor .
podman run -d --name agent-monitor \
-p 127.0.0.1:4820:4820 \
-v "$HOME/.claude:/root/.claude:ro" \
-v "$HOME/.claude/agent-dashboard:/app/data" \
-v "$HOME/.claude/agenthub:/app/data" \
agent-monitor
```
@@ -338,10 +297,10 @@ podman run -d --name agent-monitor \
| Mount | Purpose |
|---|---|
| `~/.claude:/root/.claude:ro` | Lets the server import legacy Claude session history |
| `~/.claude/agent-dashboard:/app/data` | **Canonical SQLite database** (shared with native installs) |
| `~/.claude/agenthub:/app/data` | **Canonical SQLite database** (shared with native installs) |
> [!NOTE]
> The image sets `DASHBOARD_HOST=0.0.0.0` and `DASHBOARD_DATA_DIR=/app/data` internally (baked into the `Dockerfile`). The `0.0.0.0` bind is required because a container's loopback is a separate namespace the published port cannot reach; `/app/data` is bind-mounted to `~/.claude/agent-dashboard` on the host so Docker uses the same database as `npm start`. The trust boundary is the **host** port publish — the examples use `-p 127.0.0.1:4820:4820`, so the dashboard is local-only. To expose it on a LAN, publish on `0.0.0.0` (`-p 4820:4820`) **and** set `DASHBOARD_TOKEN`.
> The image sets `DASHBOARD_HOST=0.0.0.0` and `DASHBOARD_DATA_DIR=/app/data` internally (baked into the `Dockerfile`). The `0.0.0.0` bind is required because a container's loopback is a separate namespace the published port cannot reach; `/app/data` is bind-mounted to `~/.claude/agenthub` on the host so Docker uses the same database as `npm start`. The trust boundary is the **host** port publish — the examples use `-p 127.0.0.1:4820:4820`, so the dashboard is local-only. To expose it on a LAN, publish on `0.0.0.0` (`-p 4820:4820`) **and** set `DASHBOARD_TOKEN`.
> [!IMPORTANT]
> Claude Code hooks run on the host, not inside the container. After the container is healthy on `http://localhost:4820`, run `npm run install-hooks` on the host so Claude Code posts hook events back to the containerized server. The installer refuses to run inside a container (issue #193) to avoid writing a container-internal handler path into a bind-mounted `~/.claude`; use `AGENTHUB_ALLOW_CONTAINER_HOOKS=1` only if you run Claude Code inside the same container.
+1 -31
View File
@@ -10,7 +10,6 @@
# make start # Start the production server
# make test # Run all tests
# make format # Format all files with Prettier
# make mcp-dev # Start MCP server in watch mode
# make seed # Load deterministic demo data
# For more commands, run `make help` to see descriptions, or see below.
# ─────────────────────────────────────────────────────────────────────────────
@@ -21,10 +20,9 @@ SHELL := /bin/bash
# ─── Setup ──────────────────────────────────────────────────────────────────
.PHONY: setup
setup: ## Install all dependencies (root + client + MCP)
setup: ## Install all dependencies (root + client)
npm install
cd client && npm install
npm --prefix mcp install
.PHONY: install-hooks
install-hooks: ## Register Claude Code hooks in ~/.claude/settings.json
@@ -82,28 +80,6 @@ format: ## Format all files with Prettier
format-check: ## Check formatting without writing
npx prettier --check .
# ─── MCP Server ─────────────────────────────────────────────────────────────
.PHONY: mcp-install
mcp-install: ## Install MCP server dependencies
npm --prefix mcp install
.PHONY: mcp-build
mcp-build: ## Compile MCP TypeScript → JavaScript
npm --prefix mcp run build
.PHONY: mcp-typecheck
mcp-typecheck: ## Type-check MCP source without emitting
npm --prefix mcp run typecheck
.PHONY: mcp-start
mcp-start: ## Start the MCP stdio server
npm --prefix mcp run start
.PHONY: mcp-dev
mcp-dev: ## Start MCP server in watch mode
npm --prefix mcp run dev
# ─── Data Management ───────────────────────────────────────────────────────
.PHONY: seed
@@ -136,17 +112,11 @@ docker-down: ## Stop docker-compose stack
docker-logs: ## Tail docker-compose logs
docker compose logs -f
.PHONY: mcp-docker-build
mcp-docker-build: ## Build MCP Docker image
docker build -f mcp/Dockerfile -t agent-dashboard-mcp:local .
.PHONY: podman-build
podman-build: ## Build dashboard Podman image
podman build -t localhost/claude-agent-monitor:local .
.PHONY: mcp-podman-build
mcp-podman-build: ## Build MCP Podman image
podman build -f mcp/Dockerfile -t localhost/agent-dashboard-mcp:local .
# ─── Help ───────────────────────────────────────────────────────────────────
+4 -5
View File
@@ -27,7 +27,7 @@ Internal build — all rights reserved.
you'd see locally, fully interactive, resumable, and attachable from a real
terminal too via `agenthub lanes shell`. Which CLI it starts is the lane's own
setting.
- **Analytics (in-dashboard tab), alerts, and a workflow view**, plus an MCP server and a CLI.
- **Analytics (in-dashboard tab), alerts, and a workflow view**, plus a CLI.
## Requirements
@@ -41,7 +41,7 @@ by the dashboard. `/agenthub:ship-feature` and `/agenthub:ship-feature-lane` dri
`superpowers:brainstorming`, `writing-plans`, `test-driven-development`,
`requesting-code-review` and `verification-before-completion` phase by phase,
and both built-in pipeline templates name those same slash commands as their
per-node drivers. Without it the dashboard, hooks, CLI and MCP all work
per-node drivers. Without it the dashboard, hooks and CLI all work
normally — the two pipeline skills are what stop partway. `/agenthub-doctor` reports
it as a `WARN` row.
@@ -49,7 +49,7 @@ it as a `WARN` row.
bootstrap installs it for you, once, in its detached worker — so a session never
waits on the clone, and the current session needs `/reload-plugins` before the
skills resolve (any later session picks them up on its own). The outcome is
logged to `~/.claude/agent-dashboard/runtime/bootstrap.log`, and `/agenthub-update`
logged to `~/.claude/agenthub/runtime/bootstrap.log`, and `/agenthub-update`
retries a failed one. To install it by hand instead, or after opting out:
```bash
@@ -73,7 +73,7 @@ Two commands on a machine that has nothing but Claude Code, no clone and no
```
The first session start installs the hooks, boots the server, puts `agenthub` on
PATH and connects the MCP tools; it runs detached, so the session never waits on
PATH; it runs detached, so the session never waits on
it. `/agenthub-doctor` reports the state, `/agenthub-open` builds the UI and prints the
URL, `/agenthub-update` refreshes after a plugin update. This path needs Node
**>= 22.5** (no native `better-sqlite3`, so the server uses `node:sqlite`).
@@ -224,7 +224,6 @@ Both must be green before a commit; the pre-commit hook runs them plus Prettier.
| `server/` | Express API, SQLite schema, hook ingest, lane and worktree libraries |
| `client/` | React 18 + Vite + Tailwind dashboard |
| `bin/agenthub.js` | CLI |
| `mcp/` | MCP server exposing read-only dashboard tools |
| `docs/` | Architecture, API, lanes, database |
| `plugins/` | Claude Code plugins shipped with the dashboard |
+2 -4
View File
@@ -27,8 +27,7 @@ Internal build — all rights reserved.
thật, render bằng xterm.js) gắn vào thư mục của lane — đúng cái TUI bạn thấy ở
máy, tương tác đầy đủ, resume được, và attach được từ terminal thật qua
`agenthub lanes shell`. Chạy CLI nào là thiết lập riêng của từng lane.
- **Analytics (tab trong dashboard), alert và workflow view**, cộng thêm MCP
server và CLI.
- **Analytics (tab trong dashboard), alert và workflow view**, cộng thêm CLI.
## Yêu cầu
@@ -47,7 +46,7 @@ Hai lệnh, trên máy chỉ có Claude Code, không cần clone repo, không c
```
Lần session-start đầu tiên sẽ cài hooks, boot server, đưa `agenthub` vào PATH và
kết nối MCP tools; chạy detached nên session không phải chờ. `/agenthub-doctor`
chạy detached nên session không phải chờ. `/agenthub-doctor`
báo trạng thái, `/agenthub-open` build UI và in URL, `/agenthub-update` refresh sau
khi plugin update. Đường này cần Node **>= 22.5** (không dùng
`better-sqlite3` native, server dùng `node:sqlite`). Chi tiết, kể cả những gì
@@ -190,7 +189,6 @@ thêm Prettier.
| `server/` | Express API, schema SQLite, hook ingest, thư viện lane và worktree |
| `client/` | Dashboard React 18 + Vite + Tailwind |
| `bin/agenthub.js` | CLI |
| `mcp/` | MCP server expose các tool đọc dữ liệu dashboard (read-only) |
| `docs/` | Architecture, API, lanes, database |
| `plugins/` | Các Claude Code plugin đi kèm dashboard |
+4 -61
View File
@@ -77,7 +77,7 @@ podman build -t agent-monitor .
podman run -d --name agent-monitor \
-p 127.0.0.1:4820:4820 \
-v "$HOME/.claude:/root/.claude:ro" \
-v "$HOME/.claude/agent-dashboard:/app/data" \
-v "$HOME/.claude/agenthub:/app/data" \
agent-monitor
```
@@ -87,7 +87,7 @@ Container-specific behavior:
- The image sets `DASHBOARD_HOST=0.0.0.0` (bind inside the container — its loopback is a separate namespace the published port cannot reach) and `DASHBOARD_DATA_DIR=/app/data` internally; both are baked into the `Dockerfile`
- The examples publish on `127.0.0.1` only, so the dashboard is local-only. To expose it on a LAN, publish on `0.0.0.0` (`-p 4820:4820`) **and** set `DASHBOARD_TOKEN`
- `~/.claude:/root/.claude:ro` is used for history import only
- `~/.claude/agent-dashboard:/app/data` is the **canonical** SQLite database (shared with native installs)
- `~/.claude/agenthub:/app/data` is the **canonical** SQLite database (shared with native installs)
- Claude Code hooks still execute on the host, so install them from the host with `npm run install-hooks`
### Environment variables
@@ -102,12 +102,6 @@ Container-specific behavior:
| `AGENTHUB_IMPORT_MAX_BYTES` | `1073741824` (1 GB) | Maximum size per uploaded file on `/api/import/upload` |
| `AGENTHUB_IMPORT_MAX_FILES` | `2000` | Maximum number of files per upload request |
| `AGENTHUB_IMPORT_MAX_EXTRACT_BYTES` | `4294967296` (4 GB) | Maximum uncompressed bytes any single archive is allowed to expand to (zip-bomb defense) |
| `MCP_DASHBOARD_BASE_URL` | `http://127.0.0.1:4820` | Base URL used by the local MCP server to call dashboard APIs |
| `MCP_DASHBOARD_ALLOW_MUTATIONS` | `false` | Enables mutating MCP tools |
| `MCP_DASHBOARD_ALLOW_DESTRUCTIVE` | `false` | Enables destructive MCP tools (in addition to mutations) |
| `MCP_TRANSPORT` | `stdio` | MCP transport mode: `stdio`, `http`, `repl` |
| `MCP_HTTP_PORT` | `8819` | Port for the MCP HTTP+SSE server (only when `MCP_TRANSPORT=http`) |
| `MCP_HTTP_HOST` | `127.0.0.1` | Bind address for the MCP HTTP server |
Example with a custom port:
@@ -116,7 +110,7 @@ DASHBOARD_PORT=9000 npm run dev
```
> [!NOTE]
> You usually do **not** need to set `DASHBOARD_PORT` manually. `npm run dev` is wrapped by `scripts/dev.js`, which probes both `127.0.0.1` and `::1` (so an SSH `LocalForward` bound to one loopback can't slip past) and picks the first free port in `4820–4859` automatically. The chosen port is propagated to the Vite dev proxy via `DASHBOARD_PORT`, and the Express server writes it to `~/.claude/.agent-dashboard.json` so the Claude Code hook handler discovers it without any env var.
> You usually do **not** need to set `DASHBOARD_PORT` manually. `npm run dev` is wrapped by `scripts/dev.js`, which probes both `127.0.0.1` and `::1` (so an SSH `LocalForward` bound to one loopback can't slip past) and picks the first free port in `4820–4859` automatically. The chosen port is propagated to the Vite dev proxy via `DASHBOARD_PORT`, and the Express server writes it to `~/.claude/.agenthub.json` so the Claude Code hook handler discovers it without any env var.
>
> Multiple dashboards can run side by side — for example two `npm run dev` checkouts, or `npm run dev` alongside `npm start`. Each one appends its `{port, pid, startedAt}` entry to the discovery file, and `scripts/hook-handler.js` fan-outs every hook event to every live entry, so both UIs keep their real-time stream.
>
@@ -124,43 +118,6 @@ DASHBOARD_PORT=9000 npm run dev
>
> If you bypass the picker (e.g. `npm run dev:raw`, container builds, or anything else that calls `node server/index.js` directly), make sure your client is built / proxied against the port the server actually bound.
### MCP server (optional)
The project includes a local MCP server under `mcp/` so AI agents can call dashboard operations through standardized tools. It supports three transport modes: stdio for MCP host integration, HTTP+SSE for networked clients, and an interactive REPL for operator debugging.
```mermaid
graph LR
subgraph "MCP Transport Modes"
STDIO["stdio\n(default)"]
HTTP["HTTP + SSE\n(:8819)"]
REPL["Interactive REPL"]
end
HOST["MCP Host"] -->|"stdin/stdout"| STDIO
RC["Remote Client"] -->|"POST /mcp · GET /sse"| HTTP
OP["Operator"] -->|"interactive CLI"| REPL
STDIO --> API["Dashboard API<br/>http://127.0.0.1:4820/api/*"]
HTTP --> API
REPL --> API
style STDIO fill:#6366f1,stroke:#818cf8,color:#fff
style HTTP fill:#f59e0b,stroke:#fbbf24,color:#000
style REPL fill:#a855f7,stroke:#c084fc,color:#fff
```
Quick start:
```bash
npm run mcp:install
npm run mcp:build
npm run mcp:start # stdio (for Claude Code / Claude Desktop)
npm run mcp:start:http # HTTP + SSE server on port 8819
npm run mcp:start:repl # interactive CLI with tab completion
```
For full host config and tool catalog, see [mcp/README.md](./mcp/README.md).
### Agent extension setup (Claude Code + Codex)
This repository ships extension files for both agent ecosystems:
@@ -359,18 +316,6 @@ node scripts/import-history.js --project my-project
| `clear-data` | `npm run clear-data` | Delete all data from the database |
| `seed` | `npm run seed` | Insert demo sessions/agents/events |
| `import-history` | `npm run import-history` | Import legacy sessions from `~/.claude/` (also runs on startup) |
| `mcp:install` | `npm run mcp:install` | Install MCP package dependencies |
| `mcp:build` | `npm run mcp:build` | Build MCP server into `mcp/build/` |
| `mcp:start` | `npm run mcp:start` | Start MCP server (stdio, for MCP hosts) |
| `mcp:start:http` | `npm run mcp:start:http` | Start MCP HTTP+SSE server on port 8819 |
| `mcp:start:repl` | `npm run mcp:start:repl` | Start interactive MCP REPL |
| `mcp:dev` | `npm run mcp:dev` | Start MCP server in dev mode (stdio) |
| `mcp:dev:http` | `npm run mcp:dev:http` | Start MCP HTTP server in dev mode |
| `mcp:dev:repl` | `npm run mcp:dev:repl` | Start MCP REPL in dev mode |
| `mcp:typecheck` | `npm run mcp:typecheck` | Type-check MCP source |
| `mcp:docker:build` | `npm run mcp:docker:build` | Build MCP container image with Docker |
| `mcp:podman:build` | `npm run mcp:podman:build` | Build MCP container image with Podman |
| `test:mcp` | `npm run test:mcp` | Run MCP server unit tests |
| `claude` | Claude CLI | Uses `CLAUDE.md`, `.claude/rules`, and `.claude/skills` automatically |
| `test` | `npm test` | Run all server and client tests |
| `test:server` | `npm run test:server` | Run server integration tests only |
@@ -392,7 +337,7 @@ Commonly used targets:
| Make target | Equivalent npm command | Description |
|---|---|---|
| `make setup` | `npm run setup` + MCP install | Install all dependencies (root + client + MCP) |
| `make setup` | `npm run setup` | Install all dependencies (root + client) |
| `make dev` | `npm run dev` | Start server + client in watch mode |
| `make build` | `npm run build` | Build the React client for production |
| `make start` | `npm start` | Start the production server |
@@ -402,8 +347,6 @@ Commonly used targets:
| `make test-client` | `npm run test:client` | Run client tests only |
| `make format` | `npm run format` | Format all files with Prettier |
| `make format-check` | `npm run format:check` | Check formatting without writing |
| `make mcp-build` | `npm run mcp:build` | Compile MCP TypeScript |
| `make mcp-typecheck` | `npm run mcp:typecheck` | Type-check MCP source |
| `make seed` | `npm run seed` | Load demo data |
| `make clear-data` | `npm run clear-data` | Delete all data rows |
| `make docker-up` | `docker compose up -d` | Start via docker-compose |
-27
View File
@@ -1,27 +0,0 @@
---
name: mcp-reviewer
description: Review MCP server changes for tool safety, schema quality, and host integration correctness.
tools: Read, Grep, Glob, Bash
model: opus
memory: project
---
You are an MCP-focused reviewer for this repository. Review ONLY files under `mcp/` in the diff you are given — ignore `server/`, `client/`, or any other path even if it appears in the same diff range; another reviewer covers those.
Focus on:
- Tool naming and schema strictness.
- Safety gate enforcement for mutating/destructive operations.
- API client timeout/retry/error handling.
- Stdio protocol safety (stderr-only logs).
- Host configuration and runbook documentation accuracy.
## Output (MANDATORY — the caller parses your last line)
- Findings as `path:line — severity — problem — suggested fix`, most severe first.
- End with exactly one of:
- `MCP-REVIEW: CLEAN`
- `MCP-REVIEW: FINDINGS — <n>`
## Agent memory
Record recurring MCP defect patterns and false-positive traps you find here (e.g. schema shapes that look loose but are intentional, host quirks). Future mcp-reviewer runs read this.
+3 -3
View File
@@ -28,7 +28,7 @@
*
* Port resolution mirrors the hook handler: an explicit
* CLAUDE_DASHBOARD_PORT / DASHBOARD_PORT env var wins, otherwise the live
* server is discovered from ~/.claude/.agent-dashboard.json (written by every
* server is discovered from ~/.claude/.agenthub.json (written by every
* running dashboard, PID-liveness-checked on read), falling back to 4820.
*
* Read commands are always safe. Mutating commands are explicit user actions
@@ -1370,7 +1370,7 @@ async function cmdReinstallHooks() {
* the live URL when a server is already up. The child is fully detached with
* its output appended to data/agenthub-server.log, so closing this terminal does
* not stop the dashboard; stop it later with `kill <pid>` (the PID is
* printed and registered in ~/.claude/.agent-dashboard.json).
* printed and registered in ~/.claude/.agenthub.json).
*/
async function cmdStart(flags) {
if (await serverIsUp()) {
@@ -3025,7 +3025,7 @@ function catalogRow(name, args, desc) {
function helpFooter() {
return `
${c.bold("Server discovery:")} CLAUDE_DASHBOARD_PORT / DASHBOARD_PORT env vars win,
otherwise the live server is found via ~/.claude/.agent-dashboard.json,
otherwise the live server is found via ~/.claude/.agenthub.json,
falling back to http://127.0.0.1:4820.
${c.bold("Output:")} colors auto-enable on a TTY and turn off when piped.
+2 -2
View File
@@ -1,11 +1,11 @@
{
"name": "agent-dashboard-client",
"name": "agenthub-client",
"version": "1.0.0",
"lockfileVersion": 3,
"requires": true,
"packages": {
"": {
"name": "agent-dashboard-client",
"name": "agenthub-client",
"version": "1.0.0",
"dependencies": {
"@fontsource/inter": "^5.2.8",
+1 -1
View File
@@ -1,5 +1,5 @@
{
"name": "agent-dashboard-client",
"name": "agenthub-client",
"private": true,
"version": "1.0.0",
"type": "module",
+2 -2
View File
@@ -1,7 +1,7 @@
{
"id": "claude-code-agent-dashboard",
"name": "Agent Dashboard - Claude Code Monitor",
"short_name": "Agent Dashboard",
"name": "AgentHub",
"short_name": "AgentHub",
"description": "Real-time monitoring platform for Claude Code agent activity.",
"author": "Nguyễn Ngọc Trí Vĩ",
"start_url": "/",
-1
View File
@@ -48,7 +48,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -31,7 +31,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -45,7 +45,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -38,7 +38,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -26,7 +26,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -42,7 +42,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -38,7 +38,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -40,7 +40,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -37,7 +37,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -36,7 +36,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -40,7 +40,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -46,7 +46,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -41,7 +41,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -44,7 +44,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -32,7 +32,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -35,7 +35,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -47,7 +47,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -33,7 +33,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -29,7 +29,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -33,7 +33,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -38,7 +38,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -37,7 +37,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -37,7 +37,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -34,7 +34,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -37,7 +37,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -31,7 +31,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -34,7 +34,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -33,7 +33,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -38,7 +38,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -32,7 +32,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -38,7 +38,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -48,7 +48,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -42,7 +42,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -31,7 +31,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -37,7 +37,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -38,7 +38,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -37,7 +37,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -35,7 +35,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -29,7 +29,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -33,7 +33,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -39,7 +39,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -46,7 +46,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -32,7 +32,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -35,7 +35,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -30,7 +30,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -31,7 +31,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -29,7 +29,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -31,7 +31,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -32,7 +32,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -29,7 +29,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -44,7 +44,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
@@ -30,7 +30,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -32,7 +32,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -31,7 +31,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -48,7 +48,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.
-1
View File
@@ -128,7 +128,6 @@
* ## Testing pointers
* - Prefer colocated `__tests__` with Vitest + Testing Library for UI.
* - Server contract changes require `npm run test:server` and OpenAPI sync.
* - MCP edits: `npm run mcp:typecheck` and `npm run mcp:build`.
*
* ## Related docs
* - `ARCHITECTURE.md` — hooks → API → SQLite → WebSocket → UI pipeline.

Some files were not shown because too many files have changed in this diff Show More