57dc91585d
Internal SmartGift build of a Claude Code monitoring dashboard. Lanes: a durable unit of parallel agent work, one per working directory, tracked across session restarts. Managed lanes are git worktrees the dashboard provisions and can reset or remove behind a three-check destroy guard and a counted preflight; adopted lanes are directories you already own and are never destroyable. Pipelines: a lane moves through pipeline stages. A stage the agent declares with evidence renders green; a stage inferred from the tool-event stream renders dashed amber and never counts as done. Detection is forward-only within a 30-minute window, and never writes the declared stage. Workspace: one page at /run with a lane grid, the selected lane's pipeline, and a full Claude console behind a disclosure.
997 B
997 B
description, argument-hint
| description | argument-hint |
|---|---|
| List the top N most expensive Claude Code sessions by inline cost. | [N] |
List the most expensive Claude Code sessions from the Agent Monitor dashboard.
N = $ARGUMENTS (default 10 if empty).
Fetch the session list (each session carries an inline cost field from bulk pricing):
curl -s "http://localhost:4820/api/sessions?limit=200"
Then:
- Sort sessions by
costdescending. - Print the top
Nas a numbered list, one line each:<rank>. $<cost to 4dp> — <model> — <cwd basename or id> — <started_at> - After the list, print the summed cost of the top N and what percent that is of the summed cost of all returned sessions.
Currency as USD to 4 decimal places. Skip sessions with no/zero cost only if it would otherwise pad the list past meaningful entries — otherwise include them. Keep it terse, no extra commentary.
If the dashboard is unreachable, tell the user to start it with npm start from the repo root.