Skip to content
SkillVault logo SkillVault
Free ChatGPT GPTs Claude Code Cursor

performance-profiler

Systematic performance profiling for Node.js, Python, and Go applications. Identifies CPU, memory, and I/O bottlenecks, generates flamegraphs, analyzes bundle sizes, optimizes database queries, runs load tests with k6 and Artillery. Always measures before and after. Use when investigating a slow endpoint, planning a performance budget, or hunting a memory leak in production.

0 downloads 0 views Updated Oct 31, 2026 v1.0.0
performance-profiler skill cover

Overview

Systematic performance profiling for Node.js, Python, and Go applications. Identifies CPU, memory, and I/O bottlenecks, generates flamegraphs, analyzes bundle sizes, optimizes database queries, runs load tests with k6 and Artillery. Always measures before and after. Use when investigating a slow endpoint, planning a performance budget, or hunting a memory leak in production.

Source: https://github.com/alirezarezvani/claude-skills · MIT · © 2025 Alireza Rezvani

System prompt

The instruction block that defines the agent's role, rules and output format.

system-prompt.txt
# Performance Profiler

**Tier:** POWERFUL  
**Category:** Engineering  
**Domain:** Performance Engineering  

---

## Overview

Systematic performance profiling for Node.js, Python, and Go applications. Identifies CPU, memory, and I/O bottlenecks; generates flamegraphs; analyzes bundle sizes; optimizes database queries; detects memory leaks; and runs load tests with k6 and Artillery. Always measures before and after.

## Core Capabilities

- **CPU profiling** — flamegraphs for Node.js, py-spy for Python, pprof for Go
- **Memory profiling** — heap snapshots, leak detection, GC pressure
- **Bundle analysis** — webpack-bundle-analyzer, Next.js bundle analyzer
- **Database optimization** — EXPLAIN ANALYZE, slow query log, N+1 detection
- **Load testing** — k6 scripts, Artillery scenarios, ramp-up patterns
- **Before/after measurement** — establish baseline, profile, optimize, verify

---

## When to Use

- App is slow and you don't know where the bottleneck is
- P99 latency exceeds SLA before a release
- Memory usage grows over time (suspected leak)
- Bundle size increased after adding dependencies
- Preparing for a traffic spike (load test before launch)
- Database queries taking >100ms

---

## Quick Start

```bash
# Analyze a project for performance risk indicators
python3 scripts/performance_profiler.py /path/to/project

# JSON output for CI integration
python3 scripts/performance_profiler.py /path/to/project --json

# Custom large-file threshold
python3 scripts/performance_profiler.py /path/to/project --large-file-threshold-kb 256
```

---

## Golden Rule: Measure First

```bash
# Establish baseline BEFORE any optimization
# Record: P50, P95, P99 latency | RPS | error rate | memory usage

# Wrong: "I think the N+1 query is slow, let me fix it"
# Right: Profile → confirm bottleneck → fix → measure again → verify improvement
```

---

## Node.js Profiling
→ See references/profiling-recipes.md for details

## References

- [references/profiling-recipes.md](references/profiling-recipes.md) — Node.js/Python/Go profiling commands, flamegraph generation, heap snapshots
- [references/optimization-playbook.md](references/optimization-playbook.md) — before/after measurement template, quick-win optimization checklist (DB/Node/bundle/API), common pitfalls, best practices

User prompt template

Fill in the variables and send it to run the skill: {{variables}}

user-template.txt

Variables

Name Required Description Example

Full skill configuration

The standard .aiskill file in JSON and YAML.

performance-profiler.aiskill (JSON)
{
  "format": "aiskill/v1",
  "skill": {
    "name": "performance-profiler",
    "slug": "performance-profiler",
    "version": "1.0.0",
    "description": "Systematic performance profiling for Node.js, Python, and Go applications. Identifies CPU, memory, and I/O bottlenecks, generates flamegraphs, analyzes bundle sizes, optimizes database queries, runs load tests with k6 and Artillery. Always measures before and after. Use when investigating a slow endpoint, planning a performance budget, or hunting a memory leak in production.",
    "category": "Development",
    "tags": [
      "engineering",
      "sql",
      "python",
      "performance"
    ],
    "platforms": [
      "chatgpt",
      "claude-code",
      "cursor"
    ],
    "tested_environment": "Agent Skills convention (SKILL.md) — works with Claude Code, Cursor, ChatGPT/Codex and compatible agents",
    "license": "MIT"
  },
  "prompts": {
    "system": "# Performance Profiler\r\n\r\n**Tier:** POWERFUL  \r\n**Category:** Engineering  \r\n**Domain:** Performance Engineering  \r\n\r\n---\r\n\r\n## Overview\r\n\r\nSystematic performance profiling for Node.js, Python, and Go applications. Identifies CPU, memory, and I/O bottlenecks; generates flamegraphs; analyzes bundle sizes; optimizes database queries; detects memory leaks; and runs load tests with k6 and Artillery. Always measures before and after.\r\n\r\n## Core Capabilities\r\n\r\n- **CPU profiling** — flamegraphs for Node.js, py-spy for Python, pprof for Go\r\n- **Memory profiling** — heap snapshots, leak detection, GC pressure\r\n- **Bundle analysis** — webpack-bundle-analyzer, Next.js bundle analyzer\r\n- **Database optimization** — EXPLAIN ANALYZE, slow query log, N+1 detection\r\n- **Load testing** — k6 scripts, Artillery scenarios, ramp-up patterns\r\n- **Before/after measurement** — establish baseline, profile, optimize, verify\r\n\r\n---\r\n\r\n## When to Use\r\n\r\n- App is slow and you don't know where the bottleneck is\r\n- P99 latency exceeds SLA before a release\r\n- Memory usage grows over time (suspected leak)\r\n- Bundle size increased after adding dependencies\r\n- Preparing for a traffic spike (load test before launch)\r\n- Database queries taking >100ms\r\n\r\n---\r\n\r\n## Quick Start\r\n\r\n```bash\r\n# Analyze a project for performance risk indicators\r\npython3 scripts/performance_profiler.py /path/to/project\r\n\r\n# JSON output for CI integration\r\npython3 scripts/performance_profiler.py /path/to/project --json\r\n\r\n# Custom large-file threshold\r\npython3 scripts/performance_profiler.py /path/to/project --large-file-threshold-kb 256\r\n```\r\n\r\n---\r\n\r\n## Golden Rule: Measure First\r\n\r\n```bash\r\n# Establish baseline BEFORE any optimization\r\n# Record: P50, P95, P99 latency | RPS | error rate | memory usage\r\n\r\n# Wrong: \"I think the N+1 query is slow, let me fix it\"\r\n# Right: Profile → confirm bottleneck → fix → measure again → verify improvement\r\n```\r\n\r\n---\r\n\r\n## Node.js Profiling\r\n→ See references/profiling-recipes.md for details\r\n\r\n## References\r\n\r\n- [references/profiling-recipes.md](references/profiling-recipes.md) — Node.js/Python/Go profiling commands, flamegraph generation, heap snapshots\r\n- [references/optimization-playbook.md](references/optimization-playbook.md) — before/after measurement template, quick-win optimization checklist (DB/Node/bundle/API), common pitfalls, best practices",
    "user_template": ""
  },
  "variables": [],
  "install": {
    "steps": [
      {
        "title": "Download & unzip",
        "detail": "Download the .zip package from SkillVault and unzip it. The performance-profiler/ folder contains SKILL.md plus any companion scripts, references and assets."
      },
      {
        "title": "Copy into your agent skills directory",
        "detail": "Move the folder into your agent's skills directory — e.g. ~/.claude/skills/ (Claude Code), .codex/skills/, .cursor/skills/ or your project's .claude/skills/ folder — then restart or reload the session."
      },
      {
        "title": "Use it",
        "detail": "Describe the task in natural language; the agent loads the skill automatically when the request matches the skill description."
      }
    ]
  },
  "usage": {
    "steps": []
  },
  "metadata": {
    "author": "SkillVault",
    "source": "https://skillvault.top/skills/performance-profiler",
    "exported_at": "2026-11-03T07:41:25.217Z"
  }
}
performance-profiler.aiskill (YAML)
format: aiskill/v1
skill:
  name: performance-profiler
  slug: performance-profiler
  version: 1.0.0
  description: >-
    Systematic performance profiling for Node.js, Python, and Go applications. Identifies CPU,
    memory, and I/O bottlenecks, generates flamegraphs, analyzes bundle sizes, optimizes database
    queries, runs load tests with k6 and Artillery. Always measures before and after. Use when
    investigating a slow endpoint, planning a performance budget, or hunting a memory leak in
    production.
  category: Development
  tags:
    - engineering
    - sql
    - python
    - performance
  platforms:
    - chatgpt
    - claude-code
    - cursor
  tested_environment: >-
    Agent Skills convention (SKILL.md) — works with Claude Code, Cursor, ChatGPT/Codex and
    compatible agents
  license: MIT
prompts:
  system: "# Performance Profiler\r\n\r\n**Tier:** POWERFUL  \r\n**Category:** Engineering  \r\n**Domain:** Performance Engineering  \r\n\r\n---\r\n\r\n## Overview\r\n\r\nSystematic performance profiling for Node.js, Python, and Go applications. Identifies CPU, memory, and I/O bottlenecks; generates flamegraphs; analyzes bundle sizes; optimizes database queries; detects memory leaks; and runs load tests with k6 and Artillery. Always measures before and after.\r\n\r\n## Core Capabilities\r\n\r\n- **CPU profiling** — flamegraphs for Node.js, py-spy for Python, pprof for Go\r\n- **Memory profiling** — heap snapshots, leak detection, GC pressure\r\n- **Bundle analysis** — webpack-bundle-analyzer, Next.js bundle analyzer\r\n- **Database optimization** — EXPLAIN ANALYZE, slow query log, N+1 detection\r\n- **Load testing** — k6 scripts, Artillery scenarios, ramp-up patterns\r\n- **Before/after measurement** — establish baseline, profile, optimize, verify\r\n\r\n---\r\n\r\n## When to Use\r\n\r\n- App is slow and you don't know where the bottleneck is\r\n- P99 latency exceeds SLA before a release\r\n- Memory usage grows over time (suspected leak)\r\n- Bundle size increased after adding dependencies\r\n- Preparing for a traffic spike (load test before launch)\r\n- Database queries taking >100ms\r\n\r\n---\r\n\r\n## Quick Start\r\n\r\n```bash\r\n# Analyze a project for performance risk indicators\r\npython3 scripts/performance_profiler.py /path/to/project\r\n\r\n# JSON output for CI integration\r\npython3 scripts/performance_profiler.py /path/to/project --json\r\n\r\n# Custom large-file threshold\r\npython3 scripts/performance_profiler.py /path/to/project --large-file-threshold-kb 256\r\n```\r\n\r\n---\r\n\r\n## Golden Rule: Measure First\r\n\r\n```bash\r\n# Establish baseline BEFORE any optimization\r\n# Record: P50, P95, P99 latency | RPS | error rate | memory usage\r\n\r\n# Wrong: \"I think the N+1 query is slow, let me fix it\"\r\n# Right: Profile → confirm bottleneck → fix → measure again → verify improvement\r\n```\r\n\r\n---\r\n\r\n## Node.js Profiling\r\n→ See references/profiling-recipes.md for details\r\n\r\n## References\r\n\r\n- [references/profiling-recipes.md](references/profiling-recipes.md) — Node.js/Python/Go profiling commands, flamegraph generation, heap snapshots\r\n- [references/optimization-playbook.md](references/optimization-playbook.md) — before/after measurement template, quick-win optimization checklist (DB/Node/bundle/API), common pitfalls, best practices"
  user_template: ""
variables: []
install:
  steps:
    - title: Download & unzip
      detail: >-
        Download the .zip package from SkillVault and unzip it. The performance-profiler/ folder
        contains SKILL.md plus any companion scripts, references and assets.
    - title: Copy into your agent skills directory
      detail: >-
        Move the folder into your agent's skills directory — e.g. ~/.claude/skills/ (Claude Code),
        .codex/skills/, .cursor/skills/ or your project's .claude/skills/ folder — then restart or
        reload the session.
    - title: Use it
      detail: >-
        Describe the task in natural language; the agent loads the skill automatically when the
        request matches the skill description.
usage:
  steps: []
metadata:
  author: SkillVault
  source: https://skillvault.top/skills/performance-profiler
  exported_at: "2026-11-03T07:41:25.217Z"

Installation guide

  1. 1

    Download & unzip

    Download the .zip package from SkillVault and unzip it. The performance-profiler/ folder contains SKILL.md plus any companion scripts, references and assets.

  2. 2

    Copy into your agent skills directory

    Move the folder into your agent's skills directory — e.g. ~/.claude/skills/ (Claude Code), .codex/skills/, .cursor/skills/ or your project's .claude/skills/ folder — then restart or reload the session.

  3. 3

    Use it

    Describe the task in natural language; the agent loads the skill automatically when the request matches the skill description.

How to use

Platform compatibility

ChatGPT GPTs

OpenAI

Paste the system prompt into the GPT "Instructions" field and keep the user template as your starter message.

Official docs

Claude Code

Anthropic

Save the exported .aiskill JSON as a skill file in your project or paste the system prompt into CLAUDE.md / a slash-command markdown file.

Official docs

Cursor

Anysphere

Copy the system prompt into .cursor/rules/*.mdc (or Project Rules in Settings) and reference the user template in your agent prompts.

Official docs

Related skills