Skills Repair Worker
NOTE: Startup and cleanup are handled by worker-base. This skill defines the WORK PROCEDURE.
When to Use This Skill
Features involving:
- Creating missing skill scripts (scripts/main.cjs)
- Adding missing SKILL.md sections
- Fixing catalog/index agent assignment mismatches
- Restoring missing workflow artifacts
- Improving skill ecosystem gate scores to >= 80
Work Procedure
Read the feature description. Identify which skills need fixing and what specific changes are needed.
For missing scripts/main.cjs files:
- Read the existing SKILL.md to understand what the script should do
- Look at similar skills' scripts/main.cjs for patterns (e.g.,
.claude/skills/context-compressor/scripts/main.cjs)
- The script typically: parses input, validates parameters, returns execution plan or result
- Must be requireable without error
- Write the test first, then create the script
For missing SKILL.md sections:
- Read the test file to understand exactly what content is expected
- Read similar skills that have the expected sections
- Add the section with substantive content (not stubs)
For catalog/index mismatches:
- Run
pnpm validate:skills to get the full mismatch list
- Read
.claude/config/skill-index.json to understand structure
- Update either the catalog metadata in SKILL.md or the index entry to match
- Prefer updating the index to match SKILL.md (source of truth)
For workflow restoration:
- Check
.claude/workflows/_archive/ for the file
- If it exists in archive, restore it to active directory
- If it doesn't exist, create it following existing workflow patterns
For ecosystem gate score improvement:
- Run
pnpm skills:ecosystem:gate to see which skills score < 80
- For each low-scoring skill, check what's missing (the gate checks: scripts, hooks, schemas, rules, commands, templates, references, companion tools, workflow)
- Add the minimum required artifacts to reach score 80
- Follow existing patterns from high-scoring skills
- NEVER create empty stub files -- all artifacts must have real content
Run skill tests after each batch of changes:
node --test tests/skills/<skill-name>.test.cjs
pnpm validate:skills
pnpm validate:workflow-skill-contracts
pnpm skills:ecosystem:gate
Commit with descriptive message per batch.
Example Handoff
{
"salientSummary": "Created scripts/main.cjs for token-saver-context-compression, token-saver-adaptive-ratio, and token-saver-memory-dedup. All 3 skill tests now pass. Added Router Gap Detection section to skill-creator SKILL.md. Added Activation section with compression-reminder.txt reference to token-saver SKILL.md. Fixed 20 of 79 catalog/index mismatches.",
"whatWasImplemented": "3 new scripts/main.cjs files following context-compressor pattern. 2 SKILL.md section additions. 20 skill-index.json agent assignment corrections.",
"whatWasLeftUndone": "59 remaining catalog/index mismatches (separate feature).",
"verification": {
"commandsRun": [
{
"command": "node --test tests/skills/token-saver-context-compression.test.cjs",
"exitCode": 0,
"observation": "All tests pass"
},
{ "command": "pnpm validate:skills", "exitCode": 0, "observation": "20 fewer mismatches" }
],
"interactiveChecks": []
},
"tests": { "added": [], "coverage": "Existing test suites now pass" },
"discoveredIssues": []
}
When to Return to Orchestrator
- A skill requires domain knowledge not available in codebase
- Ecosystem gate scoring criteria are unclear
- A workflow artifact requires complex cross-skill dependencies
- More than 20 skills need improvement in a single feature (too large scope)
1---2name: skills-repair-worker3description: Fixes skill tests, catalog mismatches, missing workflows, and improves ecosystem gate scores4metadata:5 source: https://skillmd.com/skills/oimiragieo/skills-repair-worker6---78# Skills Repair Worker910NOTE: Startup and cleanup are handled by `worker-base`. This skill defines the WORK PROCEDURE.1112## When to Use This Skill1314Features involving:1516- Creating missing skill scripts (scripts/main.cjs)17- Adding missing SKILL.md sections18- Fixing catalog/index agent assignment mismatches19- Restoring missing workflow artifacts20- Improving skill ecosystem gate scores to >= 802122## Work Procedure23241. **Read the feature description.** Identify which skills need fixing and what specific changes are needed.25262. **For missing scripts/main.cjs files:**27 - Read the existing SKILL.md to understand what the script should do28 - Look at similar skills' scripts/main.cjs for patterns (e.g., `.claude/skills/context-compressor/scripts/main.cjs`)29 - The script typically: parses input, validates parameters, returns execution plan or result30 - Must be requireable without error31 - Write the test first, then create the script32333. **For missing SKILL.md sections:**34 - Read the test file to understand exactly what content is expected35 - Read similar skills that have the expected sections36 - Add the section with substantive content (not stubs)37384. **For catalog/index mismatches:**39 - Run `pnpm validate:skills` to get the full mismatch list40 - Read `.claude/config/skill-index.json` to understand structure41 - Update either the catalog metadata in SKILL.md or the index entry to match42 - Prefer updating the index to match SKILL.md (source of truth)43445. **For workflow restoration:**45 - Check `.claude/workflows/_archive/` for the file46 - If it exists in archive, restore it to active directory47 - If it doesn't exist, create it following existing workflow patterns48496. **For ecosystem gate score improvement:**50 - Run `pnpm skills:ecosystem:gate` to see which skills score < 8051 - For each low-scoring skill, check what's missing (the gate checks: scripts, hooks, schemas, rules, commands, templates, references, companion tools, workflow)52 - Add the minimum required artifacts to reach score 8053 - Follow existing patterns from high-scoring skills54 - NEVER create empty stub files -- all artifacts must have real content55567. **Run skill tests after each batch of changes:**5758 ```59 node --test tests/skills/<skill-name>.test.cjs60 pnpm validate:skills61 pnpm validate:workflow-skill-contracts62 pnpm skills:ecosystem:gate63 ```64658. **Commit** with descriptive message per batch.6667## Example Handoff6869```json70{71 "salientSummary": "Created scripts/main.cjs for token-saver-context-compression, token-saver-adaptive-ratio, and token-saver-memory-dedup. All 3 skill tests now pass. Added Router Gap Detection section to skill-creator SKILL.md. Added Activation section with compression-reminder.txt reference to token-saver SKILL.md. Fixed 20 of 79 catalog/index mismatches.",72 "whatWasImplemented": "3 new scripts/main.cjs files following context-compressor pattern. 2 SKILL.md section additions. 20 skill-index.json agent assignment corrections.",73 "whatWasLeftUndone": "59 remaining catalog/index mismatches (separate feature).",74 "verification": {75 "commandsRun": [76 {77 "command": "node --test tests/skills/token-saver-context-compression.test.cjs",78 "exitCode": 0,79 "observation": "All tests pass"80 },81 { "command": "pnpm validate:skills", "exitCode": 0, "observation": "20 fewer mismatches" }82 ],83 "interactiveChecks": []84 },85 "tests": { "added": [], "coverage": "Existing test suites now pass" },86 "discoveredIssues": []87}88```8990## When to Return to Orchestrator9192- A skill requires domain knowledge not available in codebase93- Ecosystem gate scoring criteria are unclear94- A workflow artifact requires complex cross-skill dependencies95- More than 20 skills need improvement in a single feature (too large scope)