refactor!: rebrand CCAM to AgentHub

Clean break, no compatibility alias. Renames the product name, the CLI
binary (`ccam` -> `agenthub`), the env var prefix (`CCAM_` ->
`AGENTHUB_`), the Prometheus metric namespace (`ccam_*` ->
`agenthub_*`), the tmux session prefix (`ccam-lane-<id>` ->
`agenthub-lane-<id>`), the per-repo runtime profile directory
(`.ccam/profile` -> `.agenthub/profile`), the lanes state root
(`~/.claude/ccam-lanes` -> `~/.claude/agenthub-lanes`), the bundled
plugins (`plugins/ccam*` -> `plugins/agenthub*`) and their slash
commands (`/ccam-doctor` -> `/agenthub-doctor`, `/ccam:*` ->
`/agenthub:*`).

Because there is no alias, an existing install has to be updated by
hand: rename its `.ccam/profile` directory and any `CCAM_*` variables,
and reinstall the plugin under its new name.

Two other name families are deliberately left alone here, since they are
not just strings: the `Claude-Code-Monitor` repository/marketplace name,
and the `agent-dashboard` npm package plus its `~/.claude/agent-dashboard`
runtime directory, which holds the live database and needs a migration
rather than a rename.

Verified: server 1406/1406, client 459/459, `grep -i ccam` clean across
tracked files, `openapi.yaml` regenerated (95 paths, unchanged count).
This commit is contained in:
2026-09-07 12:09:15 +07:00
parent ae9b3dbcd5
commit 17d56d0e01
345 changed files with 2705 additions and 2727 deletions
@@ -0,0 +1,33 @@
---
description: Diagnose a plugin-installed AgentHub — Node, bootstrap, server, hooks, CLI, MCP build
---
Run the diagnostic and report what it found. Do not fix anything unless the user
asks.
```bash
node "${CLAUDE_PLUGIN_ROOT}/scripts/plugin-doctor.js"
```
Print the output verbatim, then add at most three lines of guidance based on the
`FAIL` and `WARN` rows:
- `FAIL Node` → the installed Node is too old for `node:sqlite`; the server
cannot start until Node is upgraded.
- `FAIL Hooks` → duplicate hook entries double every token and cost figure.
Starting a new Claude Code session removes them automatically (the bootstrap
backs the file up as `settings.json.agenthub-bak` first).
- `FAIL Server` or `FAIL Runtime deps` → run `/agenthub-update`, then check
`~/.claude/agent-dashboard/runtime/bootstrap.log` and `server.log`.
- `FAIL MCP build` → `mcp/build/` is out of date; run `npm run mcp:build` in a
checkout and commit it.
- `WARN agenthub CLI` → print the exact `export PATH=...` line from the output.
- `WARN Skill plugins` → the pipelines name slash commands no installed plugin
provides. The dashboard is unaffected; `/agenthub:ship-feature(-lane)` is what
stops partway. The bootstrap normally installs these itself, so this row also
means that attempt has not run or did not succeed — say `/agenthub-update` retries
it, and print the `claude plugin install …` line from the output as the manual
route.
- `WARN Dashboard UI` → run `/agenthub-open` to build the bundle.
No preamble, no summary of things that passed.
@@ -0,0 +1,32 @@
---
description: Rebuild the dashboard UI and print its URL
---
Rebuild the dashboard bundle, then print the URL. Always forces a rebuild so a
stale bundle (e.g. after a fix commit landed but the bootstrap's build predates
it) never serves silently. Also finishes the build if the bootstrap's own
attempt failed (check `~/.claude/agent-dashboard/runtime/client-build.log`).
```bash
node "${CLAUDE_PLUGIN_ROOT}/scripts/plugin-open.js" --force
```
Install + build takes a few minutes if the client toolchain isn't already
installed; otherwise the rebuild itself takes ~10-15s. The server serves from
that directory, so it usually needs no restart — but if it is down, or still
running from a plugin root a mid-session `/plugin` update retired, the command
re-runs bootstrap first and prints `Server restarted on the current plugin
version.` (without it, the fresh bundle would call routes that old server
never had).
Then help the user open it:
```bash
uname -s
```
- `Darwin` → `open <url>`
- `Linux` → `xdg-open <url>`
- otherwise → tell them to open the URL in a browser.
Keep the output to a few lines.
@@ -0,0 +1,49 @@
---
description: Pull the latest agenthub plugin version and refresh the dashboard runtime
---
Pull the newest `agenthub` release from its marketplace, then reinstall the runtime
dependencies and restart the dashboard server against it. Use this to get a new
dashboard build, or when `/agenthub-doctor` reports missing dependencies or a dead
server.
First, find which marketplace this install's `agenthub` came from and pull the
latest version into the plugin cache:
```bash
INSTALLED=$(claude plugin list 2>/dev/null | grep -o 'agenthub@[^ ]*' | head -1)
MARKETPLACE="${INSTALLED#agenthub@}"
if [ -z "$MARKETPLACE" ]; then
echo "agenthub is not installed as a plugin (checkout install?) - nothing to update this way."
else
claude plugin marketplace update "$MARKETPLACE"
claude plugin update "agenthub@$MARKETPLACE" -y
fi
```
That downloads the new version into `~/.claude/plugins/cache/` but does not
take effect in *this* session — Claude Code only re-resolves `${CLAUDE_PLUGIN_ROOT}`
on `/reload-plugins` (a REPL-only action, not scriptable from a command). Say
so plainly: **tell the user to run `/reload-plugins` now**, then either
re-run `/agenthub-update` (this time the bootstrap step below runs against the new
version) or just start a new session — `plugin-bootstrap.js` compares the
recorded state against the current plugin version on every `SessionStart` and
rebuilds automatically if they differ.
Then, whether or not a plugin update was just pulled, refresh the runtime
against whatever `${CLAUDE_PLUGIN_ROOT}` currently resolves to. This stops the
running dashboard server before starting the new one. Say so, then run:
```bash
node "${CLAUDE_PLUGIN_ROOT}/scripts/plugin-bootstrap.js" --force
```
It runs in the foreground and can take a few minutes on a cold cache. When it
finishes, verify:
```bash
node "${CLAUDE_PLUGIN_ROOT}/scripts/plugin-doctor.js"
```
Report the final state in a few lines. If the bootstrap failed, quote the
decisive line from `~/.claude/agent-dashboard/runtime/bootstrap.log`.
+23
View File
@@ -0,0 +1,23 @@
---
description: Declare the lane done
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `done` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node done $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Declare e2e passed (ship-feature only)
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `e2e-passed` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node e2e-passed $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: E2e on the feature branch (ship-feature only)
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `e2e` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node e2e $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Senior GO/NO-GO gate
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `gate` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node gate $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Implement (TDD)
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `implement` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node implement $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Intake — brainstorm the requirement
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `intake` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node intake $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Declare merged (ship-feature only)
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `merged` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node merged $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Plan — write the implementation plan
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `plan` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node plan $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Open the PR
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `pr-open` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node pr-open $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Publish the branch
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `publishing` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node publishing $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Declare the QC plan (ship-feature only)
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `qc-plan` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node qc-plan $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Browser QC + proof gallery (ship-feature only)
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `qc` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node qc $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Declare the run reported (ship-feature only)
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `reported` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node reported $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Code review
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `review` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node review $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Run the full 16-stage lane pipeline (implement → gates → e2e → review → QC → senior gate → PR, watched until merged)
argument-hint: <requirement>
allowed-tools: Bash(agenthub lanes pipeline:*)
---
Put this lane on the 16-node `ship-feature` template first, so the dashboard
renders the right node count from the first stage rather than after the skill
self-corrects:
!`agenthub lanes pipeline ship-feature`
Then run the pipeline **in this session** by invoking `/agenthub:ship-feature-lane`
with this requirement:
$ARGUMENTS
- No requirement given → ask for one. Never guess what to build.
- The switch above failed (no lane owns this directory) → say so and stop; the
skill has no lane to report stages against.
This is the in-session twin of `agenthub ship-full "<requirement>"`, which does the
same two steps from a terminal by spawning its own `claude`.
+23
View File
@@ -0,0 +1,23 @@
---
description: Run the 8-stage in-repo pipeline (plan → implement → tests → review → gate → ship). No PR, no browser QC
argument-hint: <requirement>
allowed-tools: Bash(agenthub lanes pipeline:*)
---
Put this lane on the 8-node `default` template first, so the dashboard renders
the right node count from the first stage:
!`agenthub lanes pipeline default`
Then run the pipeline **in this session** by invoking `/agenthub:ship-feature` with
this requirement:
$ARGUMENTS
- No requirement given → ask for one. Never guess what to build.
- The switch above failed (no lane owns this directory) → say so and stop; the
skill has no lane to report stages against.
This is the in-session twin of `agenthub ship-quick "<requirement>"`. It stops at
review/gate: no PR is opened and no browser QC runs — use `/ship-full` when the
work should reach reviewers.
+23
View File
@@ -0,0 +1,23 @@
---
description: Tests / pre-push CI gates
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `tests` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node tests $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)
+23
View File
@@ -0,0 +1,23 @@
---
description: Watch the PR / CI (ship-feature only)
argument-hint: [extra prompt words]
allowed-tools: Bash(agenthub lanes node:*)
---
The command this lane pipeline template declares for its `watching-pr` node, resolved
against whichever template the lane is actually on (matched by id or alias):
!`agenthub lanes node watching-pr $ARGUMENTS --print`
Run that here, in THIS session - never start a nested `claude` process:
- Line reads `cd <dir> && "claude" "<slash command>"` -> invoke that slash
command yourself, passing any extra words as its argument.
- Anything else is a shell argv -> run it with Bash from `<dir>`.
- Line is an error (`no node ...`, `declares no command`, no lane owns this
directory) -> print it verbatim and stop. Do not guess a substitute.
Do NOT call `agenthub stage` afterwards: a command running is not proof the node
passed. Declare the stage when the work is actually done. (The exception is a
node whose command already IS `agenthub stage <id>` - there the declaration is the
whole step.)