derhaken/superantigravity/performance-optimization

Claude Code and agent skill by derhaken/superantigravity

Trust tier 3
  • community
Source check pending

Checking that the SKILL.md file is still in the repository.

Use when code is slow, resource-heavy, or needs optimization — before making any changes, after profiling reveals bottlenecks, or when designing performance-sensitive systems

Install

npx vskill@latest install derhaken/superantigravity/performance-optimization

SKILL.md

Performance Optimization

Overview

Measure first, optimize second. Never optimize without data. The bottleneck is almost never where you think it is.

When to Use

  • Code is measurably slow or resource-heavy
  • Profiling has revealed specific bottlenecks
  • Designing a system with known performance requirements
  • Reviewing code for performance before production

When NOT to Use

  • You "feel like" code might be slow but haven't measured
  • Premature optimization during initial implementation
  • Micro-optimizations that don't move the needle

The Process

1. Measure baseline Before touching anything, establish a benchmark.

  • Record current performance numbers (time, memory, CPU)
  • Document the test conditions (data size, concurrency, hardware)
  • Save results as your baseline

2. Profile to find the bottleneck Use profiling tools appropriate to your stack:

  • Python: cProfile, py-spy, memory_profiler
  • Node.js: --prof, clinic.js, Chrome DevTools
  • Go: pprof
  • Generic: timing instrumentation, APM tools

The bottleneck is the one place where optimization actually matters.

3. Form hypothesis State explicitly: "I believe X is slow because Y." Don't optimize something you can't explain.

4. Apply targeted fix Change ONE thing at a time. Common high-impact areas:

  • Database: N+1 queries, missing indexes, over-fetching
  • Network: unnecessary round trips, large payloads, no caching
  • Memory: leaks, excessive allocation, large objects in hot paths
  • Algorithms: O(n²) where O(n log n) is possible
  • I/O: synchronous blocking, missing batching

5. Measure again Compare to baseline. Did it improve? If not, revert and try something else.

6. Document the change Record what you changed, why, and the before/after numbers.

Common High-Impact Wins

AreaLook For
DatabaseN+1 queries, full table scans, missing indexes
CachingRepeated expensive computations with same inputs
NetworkChatty APIs, large payloads, synchronous chains
AlgorithmsNested loops over large collections
MemoryObjects created in tight loops, large in-memory datasets

Red Flags

ThoughtReality
"This looks slow"Measure it. Looks are deceiving.
"I'll optimize as I go"Premature optimization obscures intent. Measure first.
"I fixed the bottleneck"Did you measure? Fix without measurement isn't a fix.
"This is the obvious bottleneck"Profile anyway. You're probably wrong.

Security

  • Security scanPassed, 95 of 100Pattern checks on the skill's files.
  • Model reviewPassed

Quality evaluation

  • Task evaluationFailed, 70 of 100Degrading. 1 run. Evaluated 8 months ago.

Source

Popularity

Repository stars
419
Repository forks
10
7-day trend score
30

Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 28 Mar 2026, 7 months ago.

Works with

Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.

  • Claude Code
  • Cursor
  • GitHub Copilot
  • Windsurf
  • Codex
  • Gemini CLI
  • Cline
  • Amp
  • Roo Code
  • Goose
  • Continue
  • Kilo Code
  • Junie
  • Trae
  • OpenHands
  • Qwen Code
  • AI Agent
  • Tabnine Chat
  • Sourcegraph Cody
  • Amazon Q
  • Firebase Genkit
  • Sweep
  • Devin
  • Phind
  • Mentat
  • Claude Desktop
  • Aider
  • GPT Pilot
  • Plandex
  • bolt.new
  • v0
  • Replit Agent
  • Anse
  • TypingMind
  • BetterChatGPT
  • LibreChat
  • Warp AI
  • Pieces
  • Fig AI
Embed badge
vskill VERIFIED badge
[![vskill VERIFIED](https://verified-skill.com/api/v1/skills/derhaken/superantigravity/performance-optimization/badge)](https://verified-skill.com/skills/derhaken/superantigravity/performance-optimization)

Something wrong with this skill or its page? Tell us.