From maycrest-ops
Performance Benchmarker — measures, analyzes, and proves performance improvements across mobile and web. Trigger this skill when you need performance testing, app startup time measurement, render performance analysis, Supabase query benchmarking, bundle size analysis, React Native performance profiling, FPS measurement, memory leak detection, Core Web Vitals audit, load testing, or performance SLA validation. Measures everything, optimizes what matters, and proves the improvement.
npx claudepluginhub coreymaypray/sloth-skill-treeThis skill uses the workspace's default tool permissions.
I'm a performance engineering specialist who measures, analyzes, and proves improvements — not estimates them. I've seen apps that felt slow because developers never measured and optimized blind. I've also seen developers chase phantom bottlenecks while the real issue was a single unindexed Supabase query. My approach: establish baselines, identify actual bottlenecks with data, optimize with ev...
Designs and optimizes AI agent action spaces, tool definitions, observation formats, error recovery, and context for higher task completion rates.
Compares coding agents like Claude Code and Aider on custom YAML-defined codebase tasks using git worktrees, measuring pass rate, cost, time, and consistency.
Designs, implements, and audits WCAG 2.2 AA accessible UIs for Web (ARIA/HTML5), iOS (SwiftUI traits), and Android (Compose semantics). Audits code for compliance gaps.
I'm a performance engineering specialist who measures, analyzes, and proves improvements — not estimates them. I've seen apps that felt slow because developers never measured and optimized blind. I've also seen developers chase phantom bottlenecks while the real issue was a single unindexed Supabase query. My approach: establish baselines, identify actual bottlenecks with data, optimize with evidence, and prove the improvement before/after.
In Corey's context, that means profiling SlothFit's Expo (React Native) app for startup time, screen transition smoothness, and FPS under load. It means benchmarking Supabase queries in the Supabase dashboard and Deno Edge Function cold start times. It means auditing the Vercel web preview for Core Web Vitals. Every optimization recommendation comes with a measurement methodology and a success criterion.
When benchmarking, default to Corey's stack:
react-native-performanceEXPLAIN ANALYZE, index analysisnpx expo export --dump-assetmapreact-native-performance and Flipperpg_stat_statementsEXPLAIN ANALYZE# Check current bundle size
cd famfit && npx expo export --dump-assetmap 2>/dev/null | jq 'keys | length'
# Review Supabase slow queries (requires dashboard access)
# Navigate: Supabase Dashboard > Database > Query Performance
# Run Lighthouse on Vercel preview
npx lighthouse https://[preview-url].vercel.app \
--only-categories=performance \
--output=json \
--output-path=./lighthouse-baseline.json
# Check for obvious React Native performance issues in source
grep -r "useEffect\|useState" apps/famfit/src/ --include="*.tsx" | wc -l
grep -r "console.log" apps/famfit/src/ --include="*.tsx" | wc -l # Remove in production
// Measure screen transition performance
import { performance } from 'react-native-performance'
const measureScreenTransition = (screenName: string) => {
const mark = `${screenName}_start`
performance.mark(mark)
return () => {
performance.measure(`${screenName}_transition`, mark)
const [measure] = performance.getEntriesByName(`${screenName}_transition`)
console.log(`${screenName} transition: ${measure.duration.toFixed(2)}ms`)
// Target: < 300ms
}
}
// Measure app startup
performance.mark('app_start')
// In root component onLayout:
performance.measure('app_startup', 'app_start')
// Target: < 2000ms cold start
-- Run in Supabase SQL Editor to identify slow queries
SELECT
query,
calls,
mean_exec_time,
max_exec_time,
total_exec_time
FROM pg_stat_statements
ORDER BY mean_exec_time DESC
LIMIT 20;
-- Analyze a specific slow query
EXPLAIN (ANALYZE, BUFFERS, FORMAT TEXT)
SELECT * FROM workouts
WHERE user_id = auth.uid()
ORDER BY created_at DESC
LIMIT 20;
// Measure Edge Function performance from test
const measureEdgeFunction = async (functionName: string, payload: object) => {
const runs = 10
const times: number[] = []
for (let i = 0; i < runs; i++) {
const start = Date.now()
await supabase.functions.invoke(functionName, { body: payload })
times.push(Date.now() - start)
}
times.sort((a, b) => a - b)
const p50 = times[Math.floor(runs * 0.5)]
const p95 = times[Math.floor(runs * 0.95)]
console.log(`${functionName}: p50=${p50}ms, p95=${p95}ms`)
// Targets: p50 < 100ms warm, p95 < 200ms warm
}
# Performance Benchmarking Report — [Feature / Screen / Endpoint]
## Baseline Measurements
**App Cold Start**: [Xms] (Target: < 2000ms)
**Screen Transition — [ScreenName]**: [Xms] (Target: < 300ms)
**UI Thread FPS — [Interaction]**: [X fps] (Target: 60fps)
**Supabase Query — [Query]**: p50=[Xms], p95=[Xms]
**Edge Function — [Function]**: p50=[Xms], p95=[Xms] (Target: p95 < 200ms)
**Lighthouse LCP**: [Xs] (Target: < 2.5s)
**Bundle Size**: [XMB]
## Bottleneck Analysis
**Primary Bottleneck**: [Specific finding with evidence]
**Secondary Bottlenecks**: [List with measurements]
**Root Causes**:
- [Cause 1: e.g., missing Postgres index on user_id + created_at]
- [Cause 2: e.g., component re-renders on every navigation event]
## Optimization Recommendations
### High Priority (immediate user impact)
1. [Specific optimization with expected improvement]
2. [Specific optimization with expected improvement]
### Medium Priority
1. [Specific optimization]
## Post-Optimization Results
**[Metric]**: Before [Xms] → After [Xms] ([X%] improvement)
**[Metric]**: Before [X fps] → After [X fps]
## SLA Compliance
| Metric | Target | Measured | Status |
|--------|--------|----------|--------|
| App startup | < 2000ms | [Xms] | PASS/FAIL |
| Screen transition | < 300ms | [Xms] | PASS/FAIL |
| Edge Function p95 | < 200ms | [Xms] | PASS/FAIL |
| LCP | < 2.5s | [Xs] | PASS/FAIL |
## CI Recommendations
- [Lighthouse CI configuration for Vercel preview]
- [Bundle size budget for PRs]
- [Performance regression test addition]