Skip to content
Agent Workspaces
Skill

/session-search

Find Claude Code sessions tracked by the Agent Monitor by project (cwd), model, status, or date, then rank the matches by cost or recency. Pulls the session list and the distinct cwd / facet values so filters use real values rather than guesses. Use when locating a session —

From plugin
claude-code-agent-monitor
1.1k75 skills21 agents33 commands1 MCP

Claude Code

$ npx -y skills add hoangsonww/Claude-Code-Agent-Monitor --skill session-search --agent claude-code

SKILL.md

session-search.SKILL.md
name: session-search
description: >
  Find Claude Code sessions tracked by the Agent Monitor by project (cwd), model,
  status, or date, then rank the matches by cost or recency. Pulls the session list
  and the distinct cwd / facet values so filters use real values rather than guesses.
  Use when locating a session — "find my EstateWise sessions", "which Opus runs
  errored this week", "most expensive sessions in /repo".

Session Search

Locate Claude Code sessions in the Agent Monitor by project, model, status, or date.

Input

The user provides: **$ARGUMENTS**

A free-form query naming any combination of:

  • **project / cwd** — a working-directory path or basename (e.g. `EstateWise`, `/Users/.../repo`)
  • **model** — `opus`, `sonnet`, `haiku`, or a full model id substring
  • **status** — `active`, `working`, `completed`, `error`
  • **date** — `today`, `this week`, or an ISO date / range matched against `started_at`
  • **ranking** — `by cost` (default when cost is mentioned) or `recent` (default otherwise)

If the query is empty, return the most recent sessions ranked by recency.

Data Sources

| Endpoint | Returns | |----------|---------| | `GET /api/sessions?limit=N` | session list: id, status, model, cwd, started_at, ended_at, cost, metadata (thinking_blocks, turn_count, total_turn_duration_ms, usage_extras) | | `GET /api/run/cwds` | the distinct working directories that have sessions — use to resolve a fuzzy project name to exact cwd values | | `GET /api/events/facets` | distinct facet values (event types, tool names, models, statuses) for validating filters |

Report Sections

1. Resolve filters

Fetch `/api/run/cwds` and `/api/events/facets` to map the user's loose terms to real values: pick the cwd(s) whose path contains the project term, confirm the model substring exists, and validate the status against known statuses. State which concrete filters you settled on.

2. Pull candidates

`GET /api/sessions?limit=200` (raise the limit if the date window is wide). Filter in-memory by cwd, model (substring, case-insensitive), status, and `started_at` date window.

3. Rank

Sort by `cost` descending when the user asked "by cost"; otherwise by `started_at` descending (most recent first). Keep the top 20 unless the user asked for more.

4. Matches

One row per session.

5. Summary

Count of matches, summed cost across matches, and the model / status distribution.

Output

Markdown table: `# | id (short) | status | model | cwd (basename) | started_at | cost`. Currency as USD to 4 decimal places; token / count fields with thousands separators. If a filter resolved to zero rows, say so and show the closest available values (e.g. the cwds that *do* exist) rather than fabricating results. If the dashboard is unreachable, tell the user to start it with `npm start` from the repo root.

Read more
@hoangsonww
Ships withclaude-code-agent-monitor

🚀 A real-time monitoring dashboard for Claude Code & Codex, built with SQLite3, Node.js, Express, React, Vite, TailwindCSS, & WebSockets. It tracks sessions, agent activity, tool usage, and subagent orchestration, providing live analytics, a Kanban status board, status notifications, a cute buddy, & an interactive web UI/MacOS/Windows native app.

1.1k75 skills21 agents1 MCP
Get the whole plugin

Stars on GitHub

Momentum

stars in total
1.1k
Star history of hoangsonww/Claude-Code-Agent-Monitor on GitHub, a chart by star-history.com

Other skills on claude-code-agent-monitor.

More skills from other plugins.

paseo

paseo

Paseo reference for managing hosts, projects, workspaces, workspace scripts, agents, schedules, and heartbeats.

paseo10d23k
@getpaseo@getpaseoInstall Skill
10x
Auto-invoked

10x

Personalized audit that teaches the advanced Paradev (formerly Superset) features the user isn't using yet (automations, parallel…

paradev1d16k
@superset-sh@superset-shInstall Skill
capabilities

capabilities

Your capability catalog — read this at boot. Lists the temporal date-range skills and the external integrations (reached via the…

@chaitanyagiri@chaitanyagiriInstall Skill

Questions about session-search.

Which coding agents can use session-search?
session-search installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.