mirror of
https://github.com/addyosmani/agent-skills.git
synced 2026-11-07 13:16:07 +00:00
One clause on the description: the skill applies when asked to simplify, clean up or reduce the nesting of a function that already works, even when the code is pasted inline. Two Tier 2 positives for the clause, a fires and stays-quiet pair under evals/plugin/, and a paragraph in evals/README.md with the measurements. claude-opus-5-5 pinned, Claude Code 2.1.296, three runs per prompt per description: the three simplification phrasings went from 0 of 9 to 8 of 9, five adjacent must-not-fire prompts stayed at 0 of 15 both ways. On the graded pair the judge passed 3 of 3 with the plugin and 0 of 3 without.
54 lines
1.6 KiB
JSON
54 lines
1.6 KiB
JSON
{
|
|
"skill_name": "code-simplification",
|
|
"trigger": {
|
|
"positive": [
|
|
{
|
|
"prompt": "This function works but it is way too clever, simplify it without changing behavior",
|
|
"top_k": 3
|
|
},
|
|
{
|
|
"prompt": "Reduce the complexity of this module so juniors can maintain it",
|
|
"top_k": 3
|
|
},
|
|
{
|
|
"prompt": "Clean up this working code, it has grown hard to follow",
|
|
"top_k": 3
|
|
},
|
|
{
|
|
"prompt": "Simplify this function, it works but it is hard to read.",
|
|
"top_k": 3
|
|
},
|
|
{
|
|
"prompt": "Clean this up, it works but it has grown hard to follow. Here is the function.",
|
|
"top_k": 3
|
|
}
|
|
],
|
|
"negative": [
|
|
{
|
|
"prompt": "Add a feature flag system to the app",
|
|
"owner": "incremental-implementation"
|
|
},
|
|
{
|
|
"prompt": "Diagnose why the build broke overnight",
|
|
"owner": "debugging-and-error-recovery"
|
|
}
|
|
]
|
|
},
|
|
"evals": [
|
|
{
|
|
"id": 1,
|
|
"prompt": "Simplify the provided 80-line function that parses config files, preserving exact behavior.",
|
|
"expected_output": "A simpler implementation with identical behavior and a summary of what was removed and why",
|
|
"files": [
|
|
"code-simplification"
|
|
],
|
|
"expectations": [
|
|
"Behavior is preserved (tests unchanged and passing, or equivalence argued concretely)",
|
|
"Complexity is reduced rather than relocated",
|
|
"The response explains what was removed and why it was safe",
|
|
"No new features are added during the simplification"
|
|
]
|
|
}
|
|
]
|
|
}
|