Handwritten
Fix a failing function by reproducing the failure, localizing the smallest wrong expression, making the minimal change, and re-verifying — for small bug-fix tasks with a known expected behaviour.From its SKILL.md
npx -y skills add sdsrss/super-skill --skill handwrittenAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 0 stars0 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
1.8 KB, 370 tokens by cl100k_base, as published. Nobody here has run it
Systematic test-fix
A discipline for fixing a function whose behaviour is wrong, when you know what it should do. Optimises for the smallest correct change, not a rewrite.
When to use
A single function returns wrong results for some inputs and you have concrete expected input/output pairs (from a description or a failing check).
Steps
- Restate the contract. Write down the expected output for 2–3 inputs, including the boundaries and the empty/degenerate case. These are your oracle.
- Reproduce. Trace the current code by hand on the input that looks most likely to break (a boundary, an empty input, a negative number). Confirm the wrong output before changing anything — do not fix by guessing.
- Localize. Find the single expression responsible: an off-by-one in a
slice or index, a
>that should be>=, an accumulator initialised to0instead of the first element or negative infinity, a wrong base case. - Minimal fix. Change only that expression. Keep the signature. Resist refactoring unrelated code in the same edit.
- Re-verify against the oracle from step 1, especially the boundary and the degenerate case, since those are where these bugs hide. If any still fails, return to step 3 — the localization was wrong, not the fix.
Common shapes
- Slice/index endpoints (
len(x) - nvslen(x) - n + 1). - Boundary comparisons (inclusive vs exclusive).
- Accumulator seeds (
0breaks all-negative inputs; seed with the first element orfloat("-inf")). - Missing empty-input handling.
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.