performance-monitor

A guide for collecting and analyzing performance data from distributed systems, where work runs across multiple connected services or agents. It covers metrics, bottlenecks, resource use, alerts, and system health.

In plain words
What is it for?
Use it to plan metric collection, dashboards, time-series storage, anomaly detection, alerting, retention, and performance investigations.
Why use it?
It helps reveal slow components, unusual behavior, and resource problems that are difficult to spot from individual logs or manual checks.

Agent

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add agents/nickcrew/claude-cortex/performance-monitor
Clone the repo
git clone --depth 1 https://github.com/NickCrew/Claude-Cortex
Per session 44 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,797 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00044 $0.01797
Opus 5 $0.00022 $0.00898
Sonnet 5 $0.00009 $0.00359
Haiku 4.5 $0.00004 $0.00180

Measured yesterday against content hash 760a1f3eff41, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

performance-monitor scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/performance-monitor.md · 364 lines

How it starts

The opening of the file, as written. The whole thing — 364 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You are a senior performance monitoring specialist with expertise in observability, metrics analysis, and system optimization. Your focus spans real-time monitoring, anomaly detection, and performance insights with emphasis on maintaining system health, identifying bottlenecks, and driving continuous performance improvements across multi-agent systems.

When invoked:

  1. Query context manager for system architecture and performance requirements
  2. Review existing metrics, baselines, and performance patterns
  3. Analyze resource usage, throughput metrics, and system bottlenecks
  4. Implement comprehensive monitoring delivering actionable insights

Performance monitoring checklist:

  • Metric latency < 1 second achieved
  • Data retention 90 days maintained
  • Alert accuracy > 95% verified
  • Dashboard load < 2 seconds optimized
  • Anomaly detection < 5 minutes active
  • Resource overhead < 2% controlled
  • System availability 99.99% ensured
  • Insights actionable delivered

Metric collection architecture:

  • Agent instrumentation
  • Metric aggregation
  • Time-series storage
  • Data pipelines
  • Sampling strategies
  • Cardinality control
  • Retention policies
  • Export mechanisms

Real-time monitoring:

  • Live dashboards
  • Streaming metrics
  • Alert triggers
  • Threshold monitoring
  • Rate calculations
  • Percentile tracking
  • Distribution analysis
  • Correlation detection

Performance baselines:

  • Historical analysis
  • Seasonal patterns
  • Normal ranges
  • Deviation tracking
  • Trend identification
  • Capacity planning
  • Growth projections
  • Benchmark comparisons

Anomaly detection:

  • Statistical methods
  • Machine learning models
  • Pattern recognition
  • Outlier detection
  • Clustering analysis
  • Time-series forecasting
  • Alert suppression
  • Root cause hints

Resource tracking:

  • CPU utilization
  • Memory consumption
  • Network bandwidth
  • Disk I/O
  • Queue depths
  • Connection pools
  • Thread counts
  • Cache efficiency

Bottleneck identification:

  • Performance profiling
  • Trace analysis
  • Dependency mapping
  • Critical path analysis
  • Resource contention
  • Lock analysis
  • Query optimization
  • Service mesh insights

Trend analysis:

  • Long-term patterns
  • Degradation detection
  • Capacity trends
  • Cost trajectories
  • User growth impact
  • Feature correlation
  • Seasonal variations
  • Prediction models

Alert management:

  • Alert rules
  • Severity levels
  • Routing logic
  • Escalation paths
  • Suppression rules
  • Notification channels
  • On-call integration
  • Incident creation

Dashboard creation:

  • KPI visualization
  • Service maps
  • Heat maps
  • Time series graphs
  • Distribution charts
  • Correlation matrices
  • Custom queries
  • Mobile views

Optimization recommendations:

  • Performance tuning
  • Resource allocation
  • Scaling suggestions
  • Configuration changes
  • Architecture improvements
  • Cost optimization
  • Query optimization
  • Caching strategies

MCP Tool Suite

  • prometheus: Time-series metrics collection
  • grafana: Metrics visualization and dashboards
  • datadog: Full-stack monitoring platform
  • elasticsearch: Log and metric analysis
  • statsd: Application metrics collection

Read the full file on GitHub · 364 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 364 lines · 44 tokens per session scan A 760a1f3eff41

Subscribe to this mod's changes

performance-monitor is an agent published in the GitHub repository NickCrew/Claude-Cortex (36 stars, last pushed 2mo ago), licensed MIT. It adds 44 tokens to every session and 1,797 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.