Install any skill in seconds. Free to start, no credit card required.
Get Started Free →Analyze Elixir/Phoenix performance — N+1 queries, assign bloat, ecto optimization, genserver bottlenecks. Use when slowness, timeouts, or high memory reported.
.claude/skills/oliver-kriska-perf/SKILL.md| Test case | Without → With | Effect | Δ tokens | Δ turns |
|---|---|---|---|---|
| case-10 | ✗→✓ | ▲ Improved | -9% | 0% |
| case-04 | ✗→✓ | ▲ Improved | 2% | 0% |
| case-05 | ✗→✓ | ▲ Improved | -42% | 0% |
| case-06 | ✗→✓ | ▲ Improved | 11% | 0% |
| case-07 | ✗→✓ | ▲ Improved | 43% | 0% |
Analyze code for performance issues across Ecto, LiveView, and OTP layers. Prioritize findings by impact and effort.
/phx:perf # Analyze full project
/phx:perf lib/my_app/accounts.ex # Analyze specific module
/phx:perf --focus ecto # Ecto queries only
/phx:perf --focus liveview # LiveView memory only
/phx:perf --focus otp # OTP bottlenecks only$ARGUMENTS = Optional module/context path and --focus flag.
MIX_ENV=prod for performance measurements; dev mode includes code reloading, debug logging, and unoptimized compilation that invalidate resultsCheck specific file if provided. Otherwise scan full project:
bash# Find hot paths: contexts, LiveViews, workers find lib/ -name "*.ex" | head -50
Spawn analysis agents in parallel based on focus:
Ecto Track (default or --focus ecto):
Spawn phx:elixir-reviewer with prompt: "Analyze for N+1 queries, missing preloads, unindexed queries, and inefficient patterns. Check: Repo.all in loops, Enum.map with Repo calls, missing preload, queries without indexes on WHERE/JOIN columns."
LiveView Track (default or --focus liveview):
Spawn phx:elixir-reviewer with prompt: "Analyze LiveViews for memory issues: large assigns, missing streams for lists, assigns that grow unbounded, heavy handle_info processing, missing assign_async for slow ops."
OTP Track (only with --focus otp):
Spawn phx:otp-advisor with prompt: "Analyze for OTP bottlenecks: GenServer mailbox growth, synchronous calls in hot paths, missing Task.async for parallel work, ETS opportunities for read-heavy state."
Score each finding on a 2x2 matrix:
| | Low Effort | High Effort | |---|---|---| | High Impact | DO FIRST | PLAN | | Low Impact | QUICK WIN | SKIP |
High impact = affects response time, memory per user, or query count. Low effort = single file change, no migration needed.
Present findings sorted by priority:
markdown## Performance Analysis: {scope} ### 1. {Finding} — DO FIRST **Impact**: {what improves} **Location**: {file}:{line} **Current**: {problematic pattern} **Fix**: {optimized pattern} **Estimated gain**: {e.g., "eliminates N+1, reduces queries from O(n) to O(1)"} ### 2. {Finding} — PLAN ...
Always end with actionable next steps — findings without follow-up get lost. Present options based on severity:
How would you like to proceed?
- `/phx:plan` — Create a plan from these findings (recommended for 3+ fixes)
- `/phx:quick` — Apply top priority fix directly (1-2 simple fixes)
- `/phx:investigate` — Deep-dive into a specific findingIf Tidewave MCP is available:
mcp__tidewave__project_eval to run Repo.query!("EXPLAIN ANALYZE ...") on suspicious queriesmcp__tidewave__project_eval to check Process.info(pid, :message_queue_len) for GenServer bottlenecksmcp__tidewave__execute_sql_query to check missing indexes${CLAUDE_SKILL_DIR}/references/benchmarking.md — Benchee patterns, profiling, flame graphs| Case | Status | Duration (ms) | Turns | Tokens | Tool calls | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Without | With | Δ | Without | With | Δ | Without | With | Δ | Without | With | Δ | ||
case-10 | fail→pass | 8,125 | 4,220 | -48% | 1 | 1 | 0% | 1,467 | 1,334 | -9% | 0 | 0 | — |
case-01 | fail→fail | 12,524 | 6,064 | -52% | 1 | 1 | 0% | 2,323 | 1,211 | -48% | 0 | 0 | — |
case-02 | fail→fail | 19,959 | 6,524 | -67% | 1 | 1 | 0% | 3,462 | 1,450 | -58% | 0 | 0 | — |
case-03 | fail→fail | 15,296 | 6,783 | -56% | 1 | 1 | 0% | 2,406 | 1,347 | -44% | 0 | 0 | — |
case-04 | fail→pass | 13,123 | 8,669 | -34% | 1 | 1 | 0% | 2,253 | 2,293 | +2% | 0 | 0 | — |
case-05 | fail→pass | 13,887 | 3,605 | -74% | 1 | 1 | 0% | 2,427 | 1,406 | -42% | 0 | 0 | — |
case-06 | fail→pass | 7,793 | 2,998 | -62% | 1 | 1 | 0% | 1,313 | 1,456 | +11% | 0 | 0 | — |
case-07 | fail→pass | 5,571 | 3,977 | -29% | 1 | 1 | 0% | 948 | 1,353 | +43% | 0 | 0 | — |
case-08 | fail→pass | 7,084 | 2,800 | -60% | 1 | 1 | 0% | 1,095 | 1,467 | +34% | 0 | 0 | — |
case-09 | fail→pass | 6,786 | 2,563 | -62% | 1 | 1 | 0% | 1,062 | 1,430 | +35% | 0 | 0 | — |
case-11 | pass→pass | 3,823 | 1,952 | -49% | 1 | 1 | 0% | 698 | 1,347 | +93% | 0 | 0 | — |
case-12 | fail→pass | 13,403 | 2,736 | -80% | 1 | 1 | 0% | 2,232 | 1,353 | -39% | 0 | 0 | — |
case-13 | pass→pass | 5,553 | 3,636 | -35% | 1 | 1 | 0% | 927 | 1,487 | +60% | 0 | 0 | — |
case-14 | pass→pass | 11,281 | 4,112 | -64% | 1 | 1 | 0% | 1,806 | 1,583 | -12% | 0 | 0 | — |
case-15 | pass→pass | 5,124 | 5,168 | +1% | 1 | 1 | 0% | 797 | 1,847 | +132% | 0 | 0 | — |
case-16 | pass→pass | 7,798 | 4,857 | -38% | 1 | 1 | 0% | 1,339 | 1,817 | +36% | 0 | 0 | — |
case-17 | fail→pass | 12,879 | 9,023 | -30% | 1 | 1 | 0% | 2,319 | 2,597 | +12% | 0 | 0 | — |
case-18 | fail→pass | 19,750 | 2,591 | -87% | 1 | 1 | 0% | 3,478 | 1,330 | -62% | 0 | 0 | — |
case-19 | fail→pass | 17,516 | 7,743 | -56% | 1 | 1 | 0% | 2,693 | 2,320 | -14% | 0 | 0 | — |
case-20 | pass→pass | 14,934 | 14,597 | -2% | 1 | 1 | 0% | 3,230 | 3,934 | +22% | 0 | 0 | — |
case-21 | pass→pass | 20,577 | 16,020 | -22% | 1 | 1 | 0% | 4,262 | 4,392 | +3% | 0 | 0 | — |
case-22 | pass→pass | 18,973 | 14,598 | -23% | 1 | 1 | 0% | 3,764 | 3,829 | +2% | 0 | 0 | — |
DecimalAI ran this skill against gemini-3.6-flash twice over the same eval suite — once with the skill loaded and once without — and compared the two runs case by case. 22 cases were attempted, and 19 counted toward the lift figure. The other 3 produced results that are not comparable between the two arms, so they are excluded from the headline rather than averaged into it. The headline lift of +50 percentage points is the difference between those two pass rates over the 19 comparable cases. 1 case got worse with the skill loaded, and it is included in that figure.
Without the skill loaded, the model failed this case. With it loaded, the same prompt on the same model passed. This is one improved case from the latest verified run; every case, including any that regressed, is in the table above.
Other measured skills in the registry, with their headline benchmark lift.