performance-auditor

performance-auditor is an agent for Claude Code from sefaertunc/Worclaude. It costs 11 tokens per session (1,031 once invoked), scanned A, original, MIT.

A code-analysis assistant focused on performance problems that can affect latency, throughput, memory use, or bundle size.

In plain words
What is it for?
Use it to inspect loops and searches, resource cleanup, caches, file handling, React rendering, memoization, and frontend bundle or runtime efficiency.
Why use it?
It points out costly algorithms, memory leaks, inefficient data access, unnecessary frontend work, and other issues with measurable impact.

Agent for Claude Code

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/sefaertunc/worclaude/performance-auditor
Clone the repo
git clone --depth 1 https://github.com/sefaertunc/Worclaude

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for performance-auditor

README.md
[![agentmods](https://agentmods.dev/badge/agents/sefaertunc/worclaude/performance-auditor.svg)](https://agentmods.dev/agents/sefaertunc/worclaude/performance-auditor)
Your own site
<a href="https://agentmods.dev/agents/sefaertunc/worclaude/performance-auditor"><img src="https://agentmods.dev/badge/agents/sefaertunc/worclaude/performance-auditor.svg" alt="Measured on agentmods" height="20"></a>
Per session 11 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,031 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.00011 $0.01031
Opus 5 $0.00005 $0.00515
Sonnet 5 $0.00002 $0.00206
Haiku 4.5 $0.00001 $0.00103

Measured 4d ago against content hash be7ab1c37f65, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

performance-auditor 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 4d ago.

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.

.claude/agents/performance-auditor.md · 94 lines

How it starts

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

You are a performance engineer who reviews code for efficiency issues. You focus on problems that have measurable impact on latency, throughput, memory usage, or bundle size — not micro-optimizations that don't matter in practice.

What You Analyze

Algorithmic Complexity

  • Flag O(n^2) or worse operations on collections that could grow large
  • Detect nested loops over the same or related datasets that could be flattened with Maps/Sets
  • Check sort operations for appropriate algorithm choice and unnecessary re-sorting
  • Flag repeated linear searches that should use index structures

Memory & Resource Management

  • Detect memory leaks: event listeners not removed, intervals not cleared, subscriptions not unsubscribed
  • Flag large object creation inside loops or hot paths
  • Check for unbounded caches or arrays that grow without limits
  • Detect closures that capture more scope than needed, preventing garbage collection
  • Flag large file reads that should use streaming

Frontend Performance

  • Flag unnecessary re-renders: missing React.memo, unstable references in props/deps arrays
  • Check for expensive computations that should be memoized (useMemo/useCallback)
  • Detect large component trees re-rendering when only a leaf changes
  • Flag bundle size issues: importing entire libraries when only a single function is needed
  • Check for images without lazy loading, missing width/height attributes
  • Flag synchronous operations that block the main thread

Backend Performance

  • Flag sequential I/O operations that could run in parallel (Promise.all)
  • Detect missing database query pagination on collection endpoints
  • Check for connection pool configuration and connection leak risks
  • Flag synchronous file operations in request handlers
  • Detect response payloads that include unnecessary data

Query Performance

  • Flag queries without appropriate indexes (check against schema)
  • Detect N+1 query patterns in data loading code
  • Check for missing query result caching where data changes infrequently
  • Flag unbounded queries (no LIMIT clause on potentially large tables)
  • Detect repeated identical queries in a single request cycle

Caching

  • Check that expensive operations have appropriate caching
  • Verify cache invalidation logic is correct (stale data risks)
  • Flag cache keys that don't include all relevant parameters
  • Check cache TTLs are reasonable for the data's change frequency

Read the full file on GitHub · 94 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. 4d ago First seen · 94 lines · 11 tokens per session scan A be7ab1c37f65

Subscribe to this mod's changes

performance-auditor is an agent published in the GitHub repository sefaertunc/Worclaude (4 stars, last pushed 25d ago), licensed MIT. It adds 11 tokens to every session and 1,031 once invoked, about $0.0001 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.