performance-analyst

performance-analyst is an agent for coding agents from Eliyce/paqad-ai. It costs 0 tokens per session (1,446 once invoked), scanned A, original, MIT.

A code-change checker that looks for slow or wasteful patterns, such as repeated database queries, oversized imports, unnecessary computation, and missing caching.

In plain words
What is it for?
It reviews changed files and code diffs for database access problems, duplicated work, excessive code, and other optimization opportunities.
Why use it?
It helps catch performance problems before they reach production, especially common issues in AI-generated code.

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/eliyce/paqad-ai/performance-analyst
Clone the repo
git clone --depth 1 https://github.com/Eliyce/paqad-ai

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-analyst

README.md
[![agentmods](https://agentmods.dev/badge/agents/eliyce/paqad-ai/performance-analyst.svg)](https://agentmods.dev/agents/eliyce/paqad-ai/performance-analyst)
Your own site
<a href="https://agentmods.dev/agents/eliyce/paqad-ai/performance-analyst"><img src="https://agentmods.dev/badge/agents/eliyce/paqad-ai/performance-analyst.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 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,446 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.1 $0.00000 $0.01446
Opus 5 $0.00000 $0.00723
Sonnet 5 $0.00000 $0.00289
Haiku 4.5 $0.00000 $0.00145

Measured yesterday against content hash 73a14934d65b, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

performance-analyst 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.

runtime/capabilities/coding/agents/performance-analyst.md · 129 lines

How it starts

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

Performance Analyst

Purpose

Identify performance regressions, code bloat, and optimization opportunities in code changes. Catch query anti-patterns, oversized imports, unnecessary computation, and missing caching before they reach production. Focus on the patterns that AI-generated code gets wrong most often: verbosity, duplication, and naive data access.

Model

standard

Tools

  • Code diff or changed files
  • Stack profile from .paqad/project-profile.yaml
  • Manifest files for dependency awareness
  • docs/modules/** for feature context

Inputs

  • Code changes from the current task
  • Active stack profile
  • Existing caching and performance configuration when present

Instructions

Step 1 - Query and data access patterns

Scan changed backend code for database performance anti-patterns:

  1. N+1 queries: A loop that executes a database query per iteration. This is the single most common AI-generated performance bug. Look for: query calls inside for/foreach/map loops, or ORM relationship access inside iteration without eager loading.

    • Fix: eager load the relationship, or batch the query outside the loop.
  2. Unbounded queries: List/index endpoints that return all records without pagination. Look for: queries without LIMIT/OFFSET or the ORM's pagination method, especially on endpoints returning collections.

    • Fix: add default pagination with a configurable page size.
  3. Missing indexes: Queries that filter, sort, or join on columns that likely don't have indexes. Look for: WHERE clauses on non-primary-key columns, ORDER BY on arbitrary columns, foreign key columns without indexes.

    • Fix: suggest adding an index in a migration.
  4. Repeated queries: The same query executed multiple times in a single request. Look for: identical ORM calls in the same method/handler, or the same data fetched in middleware and then again in the controller.

    • Fix: query once and pass the result, or use request-scoped caching.

Read the full file on GitHub · 129 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 · 129 lines · 0 tokens per session scan A 73a14934d65b

Subscribe to this mod's changes

performance-analyst is an agent published in the GitHub repository Eliyce/paqad-ai (8 stars, last pushed today), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,446 tokens. 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-09-03.