Skip to content
Skill Authoring
Skill

/skill-forge-evolve

Improve and iterate on existing Claude Code skills based on usage feedback, test results, or changing requirements. Handles under/over-triggering fixes, instruction refinement, new sub-skill addition, and architecture evolution. Use when user says "improve skill", "fix skill",

BOOST
From plugin
skill-forge
1858 skills8 agents
Install
$ npx -y skills add AgriciDaniel/skill-forge --skill skill-forge-evolve --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
  • You can call itInvoke it directly when you want it.
  • Slash command/skill-forge-evolve

Context preview

The summary Claude sees to decide when to auto-load this skill.

Improve and iterate on existing Claude Code skills based on usage feedback, test results, or changing requirements. Handles under/over-triggering fixes, instruction refinement, new sub-skill addition, and architecture evolution. Use when user says "improve skill", "fix skill",

SKILL.md

skill-forge-evolve.SKILL.md
name: skill-forge-evolve
description: >
  Improve and iterate on existing Claude Code skills based on usage feedback,
  test results, or changing requirements. Handles under/over-triggering fixes,
  instruction refinement, new sub-skill addition, and architecture evolution.
  Use when user says "improve skill", "fix skill", "skill not triggering",
  "skill triggers too much", "update skill", or "evolve skill".

Skill Evolution & Improvement

Process

Step 1: Diagnose the Issue

Ask the user or analyze logs to identify the problem category:

**Category A: Triggering Issues**

  • Under-triggering: Skill doesn't activate when it should
  • Over-triggering: Skill activates when it shouldn't
  • Mis-triggering: Wrong sub-skill activates

**Category B: Execution Issues**

  • Incomplete workflows: Skill stops before finishing
  • Incorrect output: Results don't match expectations
  • Missing error handling: Failures not handled gracefully
  • Performance: Too slow or too many token used

**Category C: Architecture Issues**

  • Missing capability: New use case not covered
  • Scale issues: Skill too large, needs decomposition
  • Cross-reference problems: Links to non-existent files

**Category D: Quality Issues**

  • Inconsistent results: Different outputs for same input
  • Vague instructions: Claude interprets differently each time
  • Missing examples: No concrete guidance

Step 2: Apply Fix by Category

Fix: Under-Triggering

1. Read current description 2. Identify missing trigger phrases 3. Add domain keywords and paraphrases 4. Add file type mentions if relevant 5. Test with 5 queries that should now trigger

**Common causes:**

  • Description too generic
  • Missing common paraphrases
  • Technical jargon without lay terms

**Fix template:**

# Before (under-triggers)
description: Analyzes code quality

# After (specific triggers)
description: >
  Static code analysis and quality assessment. Checks code style,
  complexity, security vulnerabilities, and test coverage. Use when
  user says "code review", "code quality", "lint", "static analysis",
  "code smell", "code audit", or "check my code".

Fix: Over-Triggering

1. Read current description 2. Identify why unrelated queries trigger it 3. Add negative triggers ("Do NOT use for...") 4. Make description more specific 5. Test with 5 queries that should NOT trigger

**Fix template:**

# Before (over-triggers)
description: Processes documents for review

# After (specific + negative triggers)
description: >
  Processes PDF legal documents for contract clause extraction and
  compliance review. Use for legal contracts, NDAs, terms of service.
  Do NOT use for general document editing, formatting, or non-legal PDFs.

Fix: Execution Issues

1. Identify the failing step in the workflow 2. Add explicit validation gates between steps 3. Add error handling with clear recovery instructions 4. Add "If X fails, then Y" fallback paths 5. Consider adding a script for fragile operations

Fix: Quality Issues

1. Replace vague instructions with specific ones 2. Add concrete examples of expected input/output 3. Add explicit "do this, not that" comparisons 4. Add quality check steps before final output 5. Consider adding a validation script

Step 3: Iteration Workspace Protocol

Use structured workspaces to track improvements across iterations:

eval-workspace/
  iteration-1/          # First version
    eval-0/with_skill/  # Eval results
    eval-0/baseline/
    benchmark.json      # Aggregated metrics
    benchmark.md        # Human-readable report
    feedback.json       # User feedback
  iteration-2/          # After first improvement
    eval-0/with_skill/
    eval-0/baseline/
    benchmark.json
    benchmark.md
    feedback.json

**The iteration loop:** 1. Apply the fix to the skill 2. Run `/skill-forge eval <path>` into `iteration-<N+1>/` 3. Run `/skill-forge benchmark <path>` with `--previous iteration-<N>/` 4. Review benchmark comparison for regressions 5. Collect user feedback into `feedback.json` 6. Read feedback and iterate (back to Step 2)

**Stop iterating when:**

  • User says they're happy
  • All feedback is empty (everything looks good)
  • Benchmark shows no meaningful progress between iterations
  • Pass rate meets the defined thresholds

Step 3b: Self-Annealing Loop

For quick fixes without full eval pipeline:

1. Apply the fix
2. Test with the original failing case
3. Test with 3 other cases (regression check)
4. If fix works:
   -> Update the directive/SKILL.md
   -> Document the learning in references or SKILL.md
5. If fix fails:
   -> Diagnose why
   -> Try alternative approach
   -> Repeat

Step 3c: Description Optimization Loop

For triggering issues (Category A), use the automated optimization loop:

1. Generate trigger eval set: `python scripts/generate_eval_set.py <path>` 2. Review and refine the eval set with the user 3. Run optimization: `python scripts/optimize_description.py <path> --eval-set evals.json` 4. Review the train/test split scores and improvement suggestions 5. Apply suggested description changes 6. Re-run optimization to measure improvement 7. Select the description with the highest **test score** (not train — avoids overfitting) 8. Iterate up to 5 times or until test score plateaus

Step 4: Architecture Evolution

When a skill outgrows its tier:

**Tier 1 -> Tier 2** (needs scripts): 1. Identify the fragile/deterministic operation 2. Create script in `scripts/` 3. Update SKILL.md to reference the script 4. Test script independently

**Tier 2 -> Tier 3** (needs sub-skills): 1. Identify distinct workflows that can be separated 2. Extract each into its own `skills/{parent}-{child}/SKILL.md` 3. Update main SKILL.md with routing table 4. Move shared knowledge to `references/` 5. Update install.sh

**Tier 3 -> Tier 4** (needs agents): 1. Identify workflows that can run in parallel 2. Create agent definitions in `agents/` 3. Update the audit/full-analysis sub-ski

Read more
Ships withskill-forge

Blog: Learn how to build Claude Code skills Design, scaffold, build, review, evolve, and publish production-grade Claude Code skills following the Agent Skills open standard.

Get the whole plugin

Other skills on skill-forge.