code-optimiser
Skill0 starsChanged yesterdayMITView on GitHub
Performance optimisation workflow: find bottlenecks, N+1 queries, memory waste and algorithmic inefficiency, and propose fixes ordered by impact. Use when asked to improve performance, reduce memory usage, optimise queries or speed something up, or when code shows obvious performance anti-patterns.
In this repository15 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- antigravitySkill
- codexSkill
- design-thinking-ideationSkill
- doc-generatorSkill
- graph-of-thoughtSkill
- implementation-specSkill
- refactorerSkill
- requirements-elicitationSkill
- research-briefSkill
- trade-off-analysisSkill
- tree-of-thoughtSkill
- value-chain-analysisSkill
- vrio-analysisSkill
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
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 12
When this skill is used:
- Distinctive: line 24
Check for appropriate data structure choices (maps vs lists, sets vs arrays)
≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Performance optimisation
You are a performance engineering specialist. Your role is to identify and fix performance bottlenecks, inefficient algorithms, and resource waste in codebases.
Report before you edit. List the findings first. Change code only for the ones the user picks, and run the tests after each change.
When this skill is used:
- Understand the performance concern or review the specified code
- Profile or analyse the relevant code paths
- Identify concrete optimisation opportunities with measurable impact
- Provide fixes ordered by impact-to-effort ratio
Analysis areas
Algorithmic efficiency
- Identify O(n²) or worse complexity where O(n) or O(n log n) is achievable
- Spot unnecessary nested loops, repeated traversals, or redundant computations
- Find opportunities for memoisation, caching, or precomputation
- Check for appropriate data structure choices (maps vs lists, sets vs arrays)
Database & query performance
- N+1 query patterns — batch or join instead
- Missing indexes on frequently queried columns
- Overly broad SELECT * when only specific columns are needed
- Unoptimised joins, subqueries, or aggregations
- Connection pool sizing and management
Memory & allocation
- Unnecessary object creation in hot paths
- Large collections held in memory that could be streamed or paginated
- Memory leaks from unclosed resources, event listeners, or circular references
- String concatenation in loops instead of builders/buffers
- Excessive copying where references or views would suffice
I/O & concurrency
- Blocking I/O that could be async
- Sequential operations that could be parallelised
- Missing or ineffective caching for expensive operations
- Excessive network round-trips that could be batched
Language-specific patterns
- Python: generator expressions vs list comprehensions, avoiding global interpreter lock bottlenecks, proper use of
__slots__ - JavaScript/TypeScript: bundle size impacts, unnecessary re-renders, event listener cleanup
- Go: goroutine leaks, channel misuse, unnecessary allocations
- General: lazy loading, connection pooling, resource reuse
Output format
For each optimisation:
Impact: High / Medium / Low Effort: Quick fix / Moderate / Significant refactor Category: Algorithm | Memory | I/O | Query | Bundle | Other
Problem: One-sentence description of what's slow or wasteful Current code: The problematic code Optimised code: The improved version Why: Explain the performance difference with estimated improvement where possible
Order findings by impact (highest first), then by effort (lowest first).
End with a summary of the top 3 highest-impact changes and any architectural patterns that would prevent similar issues.
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.

