Analyzes and optimizes code for better performance, memory usage, and efficiency. Use when code is slow, memory-intensive, or inefficient. Supports Python and Java optimization including execution speed improvements, memory reduction, database query optimization, and I/O efficiency. Provides before/after examples with detailed explanations of why optimizations work, complexity analysis, and measurable performance improvements.
89
88%
Does it follow best practices?
Impact
87%
1.06xAverage score across 3 eval scenarios
Passed
No known issues
Python optimization report with before/after template
Before section present
100%
100%
After section present
100%
100%
Issues listed
100%
100%
Complexity annotated
100%
100%
Gain quantified
100%
100%
Why This Works explanation
100%
100%
Trade-offs documented
100%
100%
List comprehension used
100%
100%
Set for membership testing
100%
100%
Built-in function used
100%
100%
Generator used
0%
0%
time.time() measurement
0%
0%
timeit comparison
0%
100%
Validation checklist present
0%
0%
Java optimization with categorization and measurement
Optimization type labeled
100%
100%
Before code shown
100%
100%
After code shown
100%
100%
Complexity notation
100%
100%
Why This Works section
100%
100%
Trade-offs section
100%
100%
StringBuilder used
100%
100%
HashSet for lookup
100%
100%
Primitive array used
100%
100%
System.nanoTime() measurement
100%
100%
Numeric improvement shown
100%
100%
Validation checklist
50%
0%
Database query optimization and profiling workflow
N+1 fix with joinedload
100%
100%
Batch insert used
100%
100%
Single commit after batch
100%
100%
Index recommendation
100%
100%
Buffered I/O applied
0%
100%
cProfile guidance
100%
100%
line_profiler guidance
100%
100%
memory_profiler guidance
0%
100%
Before section in report
100%
100%
Gain estimate in report
100%
100%
Why This Works explanation
100%
100%
Validation checklist
100%
91%
0f00a4f
Table of Contents
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.