Install any skill in seconds. Free to start, no credit card required.
Get Started Free →miosa-osa/refactor
Analyzes the target code, identifies improvement opportunities, plans a safe refactoring sequence, executes it, and verifies no behavior changes. Runs tests before and after every transformation.
4 of 22 test cases passed with the skill.
Tokens, turns and time describe resource use, not a dollar price.
Lift withheld: 7 comparable cases; this report requires 8.
One of 3 test cases the skill fixed. Same model, same prompt, with and without the skill.
There is a bug in `app/models/checkout.rb` where checking out with an empty cart raises a NilClass error on line 42. Please fix this bug so empty carts return a proper error tuple.
| Checked | Without skill | With skill |
|---|---|---|
| Fixes the runtime exception bug by handling empty cart states | Missed | Passed |
| Does not treat the request as a pure behavior-preserving refactoring task | Passed | Passed |
The instructions your model reads when the skill loads.
Restructure code for clarity and maintainability without changing behavior.
/refactor <target> [--strategy <strategy>] [--safe]
Analyzes the target code, identifies improvement opportunities, plans a safe refactoring sequence, executes it, and verifies no behavior changes. Runs tests before and after every transformation.
Strategies: extract, rename, decompose, simplify, decouple, auto (detect best).
# Auto-detect and refactor
/refactor lib/optimal_engine/intake.ex
# Extract functions from a long module
/refactor lib/app.ex --strategy extract
# Safe mode: smaller steps, test after every change
/refactor lib/complex_module.ex --safe
test cases passed with the skill
More skills from the same source and nearby in the registry, with their headline benchmark lift.