performance-optimization
Skill4 starsChanged 3 months agoMITView on GitHub
Measure, profile, and fix performance bottlenecks — Core Web Vitals, backend latency, bundle size, and database queries. Load when performance requirements exist, users report slowness, profiling reveals bottlenecks, or the user asks to optimize load time, LCP, INP, CLS, or response time. Not for premature optimization without evidence. Pairs with browser-testing-with-devtools and ci-cd-and-automation for regression guards.
130 other projects use a version of this.
Adopted by
Most recently taken up by
- Alter-ai/skill-labtheir own version, first seen Nov 15, 2026
- tkbk-online/skillstheir own version, first seen Nov 15, 2026
- adymire/CraftLayertheir own version, first seen Nov 15, 2026
- tayyebi/skillstheir own version, first seen Nov 15, 2026
- valentinesamuel/claude-skillstheir own version, first seen Nov 8, 2026
- ishandutta2007/Awesome-Claude-Skillstheir own version, first seen Nov 8, 2026
Used with
Projects with it also use constraint-driven-development, using-agent-skills and 5 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
MrCipherSmithSkillconstraint-driven-development
Use when a project needs a persistent, measurable quality bar — starting a project without documented standards, 'set up constraints', or when coverage/perf/a11y thresholds get re-debated per-PR. Produces CONSTRAINTS.md with enforceable numbers, ratchets, and a guard against silent weakening. NOT for throwaway prototypes or a one-off CI setup.
Also in 15 projects that use this
LLl0k0laDSkillusing-agent-skills
Use when starting a session or when you need to discover which skill applies to the current task. This is the meta-skill that governs how all other skills are discovered and invoked.
Also in 33 projects that use this
LLl0k0laDSkillidea-refine
Refine ideas through structured divergent and convergent thinking. Use "idea-refine" or "ideate" to trigger.
Also in 41 projects that use this
HK-hubSkilldeprecation-and-migration
Manages deprecation and migration. Use when removing old systems, APIs, or features. Use when migrating users from one implementation to another. Use when deciding whether to maintain or sunset existing code.
Also in 39 projects that use this
ukanwatSkillinput-systems
Architect game input — action mapping (abstracting keys into named actions), rebinding with conflict detection and persistence, multi-device support (keyboard, gamepad, touch), analog deadzones, and feel features like input buffering and coyote time, plus accessibility. Engine-neutral. Use when the user mentions input mapping, rebind controls, gamepad support, deadzone, input buffering, coyote time, or accessible controls.
Also in 4 projects that use this
HK-hubSkillobservability-and-instrumentation
Instruments code so production behavior is visible and diagnosable. Use when adding logging, metrics, tracing, or alerting. Use when shipping any feature that runs in production and you need evidence it works. Use when production issues are reported but you can't tell what happened from the available data.
Also in 31 projects that use this
- +1 more from LLl0k0laD
Other versions130 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 130
- addyosmani/agent-skills★ 114ksame name
- sanity-io/sanity★ 6.4ksame name
- gamedev-skills/awesome-gamedev-agent-skills★ 6.4ksame name
- compozy/compozy★ 2.9ksame name
- ollaya-dev/ollaya★ 1.4ksame name
- buddy-compiler/buddy-mlir★ 773same name
- ThibautBaissac/rails_ai_agents★ 665same name
- derHaken/SuperAntigravity★ 439same name
- ukanwat/aaabench★ 399same name
- ukanwat/overtime★ 399same name
120 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository125 other files it gives its agents.
- AGENTS.mdAGENTS.md
- .cursor/rules/agent-loom-routing.mdcCursor rule
- .cursor/rules/agent-loom-skills-index.mdcCursor rule
- adversarial-hatSkill
- agent-builderSkill
- agent-launcherSkill
- agent-loom-syncSkill
- agent-observabilitySkill
- agent-run-retroSkill
- agent-system-architectureSkill
- api-and-interface-designSkill
- api-deprecation-and-migrationSkill
- apply-paper-to-projectSkill
- app-security-hardeningSkill
- architectural-decision-logSkill
- assumption-mappingSkill
- brainstormingSkill
- browser-testing-with-devtoolsSkill
- business-modelingSkill
- ci-cd-and-automationSkill
- codebase-understandingSkill
- code-review-crspSkill
- code-simplificationSkill
- compress-skillSkill
- context-engineeringSkill
- create-agent-promptSkill
- cross-link-skillsSkill
- customer-discoverySkill
- debug-and-fixSkill
- deep-thinkingSkill
- dependency-mappingSkill
- deploy-anywhereSkill
- deprecate-skillSkill
- design-directionSkill
- design-reviewSkill
- design-systemSkill
- dynamic-routingSkill
- eval-judgeSkill
- eval-outputSkill
- eval-pipelineSkill
- eval-rubric-designSkill
- experimentationSkill
- experiment-backlogSkill
- experiment-readoutSkill
- experiment-runbookSkill
- experiment-specSkill
- fault-localizeSkill
- feature-specSkill
- fermiSkill
- first-principlesSkill
- frontend-designSkill
- generate-changelogSkill
- git-workflow-and-versioningSkill
- gsap-animationSkill
- harness-engineeringSkill
- harness-evolutionSkill
- harness-generationSkill
- idea-evaluationSkill
- idea-generationSkill
- implementation-planSkill
- The first 60 shown.
The file
We split this skill into the rules it gives an agent
7 rules. 0 are common, 7 are distinctive, and 0 are very specific to this project.
0
Common
Most of the 115 edited versions we read keep these.
7
Distinctive
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 27
Never optimize without a baseline measurement (synthetic + real-user when possible).
- Distinctive: line 31
Document what you measured, what you changed, and the delta.
- Distinctive: line 55
Use symptom → probe map:
- Distinctive: line 66
Prefer highest-impact, lowest-risk fixes: indexes, caching, code-split, image sizing, defer non-critical JS.
- Distinctive: line 74
Add Lighthouse CI budget, bundle-size check, or perf test on the hot path.
- Distinctive: line 80
No evidence of a problem and no stated budget
- Distinctive: line 151
No changes — citation audit passed.
“Common” is measured: kept by at least 6 in 10 of the 115 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Performance Optimization
Measure before optimizing. Profile first, fix the proven bottleneck, measure again, then guard against regression.
Hard Rules
- Never optimize without a baseline measurement (synthetic + real-user when possible).
- Fix the actual bottleneck — not the most interesting code.
- One change at a time when validating; otherwise you cannot attribute wins.
- Set budgets (LCP, bundle KB, p95 latency) and fail CI when exceeded.
- Document what you measured, what you changed, and the delta.
Core Web Vitals Targets
| Metric | Good | Needs work | Poor |
| LCP | ≤ 2.5s | ≤ 4.0s | > 4.0s |
| INP | ≤ 200ms | ≤ 500ms | > 500ms |
| CLS | ≤ 0.1 | ≤ 0.25 | > 0.25 |
Workflow
Step 1 — Measure baseline
- Frontend: Lighthouse (synthetic), DevTools Performance,
web-vitalsRUM. - Backend: APM, query logs with timing, p50/p95/p99 on critical endpoints.
- Record environment, device, and data volume.
Step 2 — Identify bottleneck
Use symptom → probe map:
Slow first load → bundle size, render-blocking, LCP element
Slow interaction → INP, main-thread long tasks, layout thrash
Slow API → N+1 queries, missing indexes, cold starts
Memory growth → leaks, unbounded caches, retained DOMStep 3 — Fix narrowly
Prefer highest-impact, lowest-risk fixes: indexes, caching, code-split, image sizing, defer non-critical JS.
Step 4 — Verify
Re-run the same measurement as Step 1. Report before/after numbers.
Step 5 — Guard
Add Lighthouse CI budget, bundle-size check, or perf test on the hot path.
When NOT to use
- No evidence of a problem and no stated budget
- Micro-optimizing cold paths while hot paths are unmeasured
- Replacing architecture before profiling
Gotchas
- Synthetic scores ≠ real-user experience — use both.
- Optimizing the wrong layer (CSS when the DB is the bottleneck).
- Caching without invalidation creates subtle bugs.
- Bundle "tree-shaking" claims without measuring shipped bytes.
Common Rationalizations
| Excuse | Reality |
| "It feels fast on my machine" | Your machine is not production traffic or network. |
| "We'll add monitoring later" | Without baselines you cannot prove improvement. |
| "Let's rewrite in Rust" | Profile first — often the query or algorithm is the issue. |
| "Lighthouse is enough" | Lab scores miss real devices and cache states. |
| "Ship now, optimize later" | Regressions are cheaper to block in CI than fix in prod. |
Output Format
## Performance report — [area]
Baseline: [metrics + how measured]
Bottleneck: [evidence]
Change: [what]
After: [metrics]
Guard: [CI/monitoring added]Examples
<examples>
<example>
<input>"Homepage LCP is 5s in CrUX."</input>
<output>Measure LCP element (hero image). Compress, preload, fix CLS from font swap. Re-run Lighthouse + verify CrUX trend.</output>
</example>
</examples>Verification
- Baseline captured with method and environment noted
- Bottleneck identified with evidence (not assumption)
- After metrics show improvement on the same probe
- Regression guard added or explicitly deferred with reason
- No premature micro-opts on unmeasured paths
Red Flags
- Optimization started without baseline measurement
- CSS or frontend tuned while DB is actual bottleneck
- Multiple changes shipped — win cannot be attributed
- Synthetic score improved but real-user metrics flat
Prune Log
Last pruned: 2026-07-04
- No changes — citation audit passed; content current (improve-skills full pass 2026-07-04)
Impact Report
Area: [frontend/backend] | Baseline: [key metric]
Bottleneck: [one line] | Delta: [before → after]
Guard: [added/deferred]Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

