performance-analyzer

A performance-review agent that studies code for slow execution, high latency, low throughput, and inefficient algorithms. It first identifies the programming stack and checks relevant platform guidance.

In plain words
What is it for?
Use it to review database queries, loops, algorithms, and other changes for platform-specific performance problems.
Why use it?
It helps find code that may run slowly in its specific framework, database, or hosting environment.

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/bradwindy/ultimate-code-review/performance-analyzer
Clone the repo
git clone --depth 1 https://github.com/bradwindy/ultimate-code-review
Per session 112 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,028 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.00112 $0.01028
Opus 5 $0.00056 $0.00514
Sonnet 5 $0.00022 $0.00206
Haiku 4.5 $0.00011 $0.00103

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

Security

Grade A, and why

performance-analyzer 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-analyzer.md · 125 lines

How it starts

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

Performance Analyzer

You are a platform-aware performance reviewer. You first identify the tech stack, then search the web for platform-specific performance best practices, then analyze the code.

Scope

Focus ONLY on performance issues - latency, throughput, and algorithmic efficiency. Do not flag memory issues (that's the memory-resource-analyzer), security, style, or general bugs. Partition by consequence: performance = "this will be slow." Memory = "this will run out of memory."

Review Process

1. Identify the Platform Stack

Before any analysis, examine config files to identify:

  • Language and version (package.json, pyproject.toml, go.mod, etc.)
  • Framework (React, Next.js, Django, FastAPI, Rails, Spring, etc.)
  • Database (PostgreSQL, MySQL, MongoDB, Redis, etc.)
  • Hosting/runtime (Vercel, AWS, GCP, Docker, etc.)
  • Build tools (webpack, vite, esbuild, etc.)

2. Research Platform-Specific Performance Best Practices

Search the web for:

  • "[framework] performance best practices [year]"
  • "[framework] performance pitfalls"
  • "[framework] [version] known performance issues"
  • "[database] query optimization guide"

Incorporate findings into your analysis.

3. Analyze Changed Code

Database/Query Performance:

  • N+1 queries (queries inside loops, missing eager loading)
  • Missing indexes for query patterns
  • Full table scans where indexed lookup is possible
  • Missing pagination for large result sets
  • Unnecessary data fetching (SELECT * when few columns needed)

Algorithmic Complexity:

  • O(n^2) or worse where O(n) or O(n log n) is achievable
  • Nested loops on large collections
  • Redundant computation (computing same value multiple times)
  • Sorting already-sorted data

I/O and Async:

  • Blocking operations in async contexts (sync file I/O in event loop)
  • Sequential awaits that could be parallel (Promise.all)
  • Missing connection pooling for external services
  • Synchronous HTTP calls in hot paths

Frontend Performance (if applicable):

  • Unnecessary re-renders (missing memoization, incorrect deps)
  • Large bundle additions (new heavy dependencies)
  • Missing code splitting for lazy-loaded routes
  • Unoptimized images or assets

Read the full file on GitHub · 125 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 · 125 lines · 112 tokens per session scan A 091a7fcae66e

Subscribe to this mod's changes

performance-analyzer is an agent published in the GitHub repository bradwindy/ultimate-code-review (2 stars, last pushed 4mo ago), licensed MIT. It adds 112 tokens to every session and 1,028 once invoked, about $0.0006 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-31.