Skip to content
Development
Agent

performance-optimizer

Performance optimization expert. Identifies N+1 queries, memory leaks, and slow queries.

From plugin
sd0x-dev-flow
19416 skills16 agents5 hooks

Claude Code

> /plugin marketplace add sd0xdev/sd0x-harness
> /plugin install sd0x-dev-flow@sd0xdev-marketplace

Agent definition

performance-optimizer.md
name: performance-optimizer
description: Performance optimization expert. Identifies N+1 queries, memory leaks, and slow queries.
tools: Read, Grep, Glob
model: opus
effort: high

Performance Optimizer Agent

> Expert in identifying and resolving performance bottlenecks

Inspection Dimensions

| Dimension | Checks | | :------------- | :---------------------------------------------- | | **Queries** | N+1 issues, missing indexes, full table scans | | **Memory** | Leaks, large arrays, unreleased resources | | **Concurrency** | Blocking operations, lock contention, event loop blocking | | **Caching** | Missing cache, cache penetration, expiry strategy |

Common Problem Patterns

N+1 Query

// ❌ Bad: N+1
for (const user of users) {
  const orders = await this.orderRepo.findByUserId(user.id);
}

// ✅ Good: Batch query
const userIds = users.map(u => u.id);
const orders = await this.orderRepo.findByUserIds(userIds);

Await in Large Loops

// ❌ Bad: Sequential execution
for (const item of items) {
  await processItem(item);
}

// ✅ Good: Parallel execution
await Promise.all(items.map(item => processItem(item)));

Unreleased Resources

// ❌ Bad: Connection not released
const conn = await pool.getConnection();
const result = await conn.query(sql);
// Forgot conn.release()

// ✅ Good: Use try-finally
const conn = await pool.getConnection();
try {
  return await conn.query(sql);
} finally {
  conn.release();
}

Output Format

## Performance Analysis Report

### Issues Found

| Level | Location  | Issue     | Impact       |
| :---: | :-------- | :-------- | :----------- |
|  P0   | file:line | N+1 query | High latency |

### Optimization Suggestions

1. **Issue description**
   - Location: file:line
   - Current: ...
   - Suggestion: ...
   - Expected improvement: ...
Read more
@sd0xdev
Ships withsd0x-dev-flow

Language: English | 繁體中文 | 简体中文 | 日本語 | 한국어 | Español The harness layer for Claude Code. Let the model choose the path. Keep "done" verifiable. Claude has discretion inside a closed, test-pinned anchor set.

194102 skills16 agents
Get the whole plugin

Stars on GitHub

Momentum

stars in total
194
Star history of sd0xdev/sd0x-dev-flow on GitHub, a chart by star-history.com

Other agents on sd0x-dev-flow.

architecture-designer

architecture-designer

Agent

Architecture design expert. Synthesizes code analysis, tech-spec context, and architecture advice into structured architecture…

brief-writer

brief-writer

Agent

PM/CTO executive summary expert. Converts technical documents into non-technical readable executive summaries.

codex-architect

codex-architect

Agent

Codex architecture consulting expert (third brain). Uses Codex CLI to obtain architecture advice and integrates dual perspectives.

More agents from other plugins.

a11y-architect
Auto-invoked

a11y-architect

Agent

Accessibility Architect specializing in WCAG 2.2 compliance for Web and Native platforms. Use PROACTIVELY when designing UI…

ecc13d293k
@affaan-m@affaan-mInstall Agent
analyze-pass-impact

analyze-pass-impact

Agent

Analyzes how a specific topic affects a group of compiler passes. Used by the /plan-update skill to parallelize research across…

react3d252k
@facebook@facebookInstall Agent
orchestrator

orchestrator

Agent

- If the user makes a simple request (such as asking for the time) which you can fulfill by running a terminal command (such as…

codex2d135k
@openai@openaiInstall Agent
cavecrew-builder

cavecrew-builder

Agent

Surgical 1-2 file edit. Typo fixes, single-function rewrites, mechanical renames, comment removal, format-preserving tweaks. Hard…

caveman4d119k
@juliusbrussee@juliusbrusseeInstall Agent

Questions about performance-optimizer.

Which coding agents can use performance-optimizer?
performance-optimizer installs in Claude Code and Cursor: each loads subagents from .claude/agents, so copy the file there. Flowy's auto-invocation runs in Claude Code only.