Performance Monitor — Claude Code subagent: what it does
Performance Monitor collects system and agent metrics, hunts bottlenecks and watches SLA thresholds. Useful when several agents run at once and it is unclear which one is slow.
no license ★ 850 updated 2026-10-26
.claude/agents/performance-monitor.mdWhat Performance Monitor does
Metrics come from several places at once: CPU load, memory pressure, disk and network I/O, process and thread counts. The agent also calls agent_list and agent_metrics over MCP and scores each agent on efficiency, responsiveness and reliability. Those calls need a running MCP server with both tools, otherwise that half of the report stays empty.
Bottleneck hunting is split across six detectors: CPU, memory, I/O, network, coordination, task queue. They run in parallel and the findings get ranked by severity. A ring buffer holding 1000 entries keeps signatures of past incidents, so a problem that keeps returning is recognised instead of rediscovered.
SLA work goes through defineSLA. Defaults are 99.9% availability, 1000 ms response time, 100 requests per second, 0.1% error rate and 300 s recovery, checked every 60 s over a 300 s window. Alert thresholds sit at 0.8, 0.9 and 1.0 of the target.
What it helps with
- spot which agent is eating the most CPU
- separate a one-off spike from a recurring bottleneck
- set SLA limits and catch breaches as they happen
- read system and agent numbers in a single report
- see whether tasks stall on memory, disk or coordination
Example prompts for the agent
- Collect the current system and agent metrics and show which agent uses the most CPU.
- Analyze the bottlenecks and rank them by severity.
- Define an SLA for the
apiservice with 99.9% availability and 1000 ms response time, then check for violations.
How to install Performance Monitor
Manually: put the files in place
.claude/agents/performance-monitor.mdFor all projects use ~/.claude/agents/. Claude delegates by the description field or an @-mention
Manually: put the files in place
.codex/agents/performance-monitor.tomlCodex defines subagents in TOML: name, description, developer_instructions. Move the Markdown text into developer_instructions by hand. For all projects use ~/.codex/agents/
Manually: put the files in place
.cursor/agents/performance-monitor.mdCursor also reads .claude/agents/
Step by step, with commands for each platform: Claude Code subagents: how to create one, call it and keep context clean
Questions about Performance Monitor
How do I install Performance Monitor in Claude Code?
Put the file at .claude/agents/performance-monitor.md inside your project. The subagent then shows up in the agent list.
What does Performance Monitor do?
It gathers system and agent metrics, detects bottlenecks across several layers, tracks SLA compliance and flags anomalies.
Which SLA thresholds does it use by default?
99.9% availability, 1000 ms response time, 100 requests per second, 0.1% error rate and 300 s recovery, evaluated every 60 s over a 300 s window.