From magician
Profiles and optimizes performance with a mandatory baseline-first gate. Use when something is slow or you need to hit a latency/throughput target.
How this skill is triggered — by the user, by Claude, or both
Slash command
/magician:accelerateThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Profile and optimize performance systematically. No optimization without measurement.
Profile and optimize performance systematically. No optimization without measurement.
Scale /effort to the optimization scope: low for a single hot path, high for cross-cutting work.
Establish a baseline measurement BEFORE making any changes. Optimization without a baseline is guesswork.Ask both questions in one message:
"Before I start profiling, two quick questions:
- What specifically is slow? (page load, API response, query, computation — be as specific as possible)
- What's the acceptable performance target? (e.g., 'under 200ms', 'p99 < 500ms')"
End your turn. Wait for both answers before proceeding to Phase 2. Do not run any benchmarks until you have a defined target.
Measure current performance using the appropriate tool:
API:
wrk -t4 -c100 -d30s http://localhost:8080/api/endpoint
# or: hey -n 1000 -c 50 http://localhost:8080/api/endpoint
Web (browser):
npx lighthouse http://localhost:3000 --output json --output-path baseline.json
Python:
import cProfile, pstats
profiler = cProfile.Profile()
profiler.enable()
# ... run the slow code ...
profiler.disable()
stats = pstats.Stats(profiler).sort_stats('cumulative')
stats.print_stats(20)
Go:
import _ "net/http/pprof"
// Then: go tool pprof http://localhost:6060/debug/pprof/profile
Record baseline numbers.
Use the profiler to identify the actual bottleneck. The bottleneck is where the most time is spent — not the most obvious place.
Fix ONLY the identified bottleneck. Common fixes:
Run the same benchmark as Phase 2. Compare: baseline vs. optimized. If target not met: return to Phase 3.
"Accelerate complete. Baseline: . Optimized: . Improvement: %. Target <met/not met>."
npx claudepluginhub alexander-tyagunov/magician --plugin magicianOptimizes backend, API, database, and system performance via baseline measurement, profiling, strategy, implementation, and validation. For slow responses, query tuning, caching.
Measures and optimizes performance with data-driven profiling, identifying bottlenecks like N+1 queries, missing indexes, and synchronous I/O. Triggers on performance, speed, latency, profiling, or benchmark keywords.