ワンクリックで
audit-performance
Run a single-session performance audit on the codebase
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Run a single-session performance audit on the codebase
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Run a single-session AI optimization audit on the codebase
Run a single-session code review audit on the codebase
Run a single-session engineering productivity audit on the codebase
Run a comprehensive enhancement audit across the entire project - code, product, UX, content, workflows, infrastructure, external services, and meta-tooling.
Run a comprehensive multi-stage automation audit with parallel agents
Run a single-session refactoring audit on the codebase
| name | audit-performance |
| description | Run a single-session performance audit on the codebase |
| supports_parallel | true |
| fallback_available | true |
| estimated_time_parallel | 20 min |
| estimated_time_sequential | 50 min |
/audit-performance| Condition | Mode | Time |
|---|---|---|
| Task tool available + no context pressure | Parallel | ~20 min |
| Task tool unavailable | Sequential | ~50 min |
| Context running low (<20% remaining) | Sequential | ~50 min |
| User requests sequential | Sequential | ~50 min |
When to use: Task tool available, sufficient context budget
Focus Areas:
Files:
src/**/*.tsx (pages, layouts)components/**/*.tsxpackage.json (dependencies)Focus Areas:
Files:
lib/**/*.ts (services, utilities)hooks/**/*.ts (custom hooks)useEffectInvoke both agents in a SINGLE Task message:
Task 1: bundle-and-rendering agent - audit bundle size, rendering, Core Web
Vitals Task 2: data-and-memory agent - audit data fetching, memory, offline
support
Each agent prompt MUST end with:
CRITICAL RETURN PROTOCOL:
- Write findings to the specified output file using Write tool or Bash
- Return ONLY: `COMPLETE: [agent-id] wrote N findings to [output-path]`
- Do NOT return full findings content — orchestrator checks completion via file
Dependency constraints: Both agents are independent -- no ordering required. Each writes to a separate JSONL section. Results are merged after both complete.
Before running performance audit, search for context from past sessions:
mcp__plugin_episodic_memory_episodic_memory__search({
query: ['performance audit', 'bundle size', 'rendering'],
limit: 5,
});
mcp__plugin_episodic_memory_episodic_memory__search({
query: ['Core Web Vitals', 'LCP', 'memory leak'],
limit: 5,
});
Why this matters:
When to use: Task tool unavailable, context limits, or user preference
Execution Order:
Total: ~50 min (vs ~20 min parallel)
{
"started_at": "ISO timestamp",
"categories_completed": ["Bundle", "Rendering"],
"current_category": "DataFetch",
"findings_count": 12,
"last_file_written": "stage-2-findings.jsonl"
}
Step 1: Check Thresholds
Run npm run review:check and report results.
Step 2: Gather Current Baselines
Collect these metrics by running commands:
# Build output (bundle sizes)
npm run build 2>&1 | tail -30
# Count client vs server components (if applicable)
grep -rn "use client" src/ components/ --include="*.tsx" 2>/dev/null | wc -l
grep -rn "use server" src/ components/ --include="*.tsx" 2>/dev/null | wc -l
# Count useEffect hooks (potential performance issues)
grep -rn "useEffect" --include="*.tsx" --include="*.ts" 2>/dev/null | wc -l
# Image optimization check
grep -rn "<img" --include="*.tsx" 2>/dev/null | wc -l
Step 3: Load False Positives Database
Read docs/technical-debt/FALSE_POSITIVES.jsonl and filter findings matching:
performanceexpires date passed)Note patterns to exclude from final findings. If file doesn't exist, proceed with no exclusions.
Focus Areas (7 Categories):
For each category:
Performance Patterns to Find:
Scope:
src/, components/, lib/, hooks/node_modules/, dist/, build/, docs/, tests/1. Markdown Summary (display to user):
## Performance Audit - [DATE]
### Baselines
- Build time: Xs
- Bundle size: X KB (gzipped)
- Client components: X
- useEffect hooks: X
### Findings Summary
| Severity | Count | Affected Metric | Confidence |
| -------- | ----- | --------------- | ----------- |
| S0 | X | ... | HIGH/MEDIUM |
| S1 | X | ... | HIGH/MEDIUM |
| S2 | X | ... | ... |
| S3 | X | ... | ... |
### Top 5 Optimization Opportunities
1. [file:line] - Description (S1/E1) - Est. X% improvement - DUAL_PASS_CONFIRMED
2. ...
### False Positives Filtered
- X findings excluded (matched FALSE_POSITIVES.jsonl patterns)
### Quick Wins (E0-E1)
- ...
### Recommendations
- ...
2. JSONL Findings (save to file):
Create file: docs/audits/single-session/performance/audit-[YYYY-MM-DD].jsonl
Category field: category MUST be performance. Also include
performance_details with affected_metric, current_metric, and
expected_improvement.
3. Markdown Report (save to file):
Create file: docs/audits/single-session/performance/audit-[YYYY-MM-DD].md
Full markdown report with all findings, baselines, and optimization plan.
Read
CANON/templates/AUDIT_TEMPLATE.mdfor: Evidence Requirements, Dual-Pass Verification, Cross-Reference Validation, JSONL Output Format, Context Recovery, Post-Audit Validation, MASTER_DEBT Cross-Reference, Interactive Review, TDMS Intake & Commit, Documentation References, Agent Return Protocol, and Honesty Guardrails.
Skill-specific TDMS intake:
node scripts/debt/intake-audit.js <output.jsonl> --source "audit-performance-<date>"
Performance audit triggers (check AUDIT_TRACKER.md):
| Version | Date | Description |
|---|---|---|
| 1.0 | 2026-02-25 | Initial implementation |