plugins/specweave/skills/skill-gen/SKILL.md
Generate project-specific skills from detected patterns in living docs. Use when saying 'skill-gen', 'generate skills', 'create project skills', 'codify patterns', 'skill generation', 'project-specific skills', or 'detected patterns'. Also use when the user responds to a skill suggestion printed during increment closure.
npx skillsauth add anton-abyzov/specweave plugins/specweave/skills/skill-genInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Skill Memories: If .specweave/skill-memories/skill-gen.md exists, read and apply its learnings.
Generate project-local skills from recurring patterns detected across increment closures.
This skill reads .specweave/state/skill-signals.json, displays qualifying patterns (observed in 3+ increments), and generates SKILL.md files in .claude/skills/ using Anthropic's official skill-creator plugin.
Key principle: Skills are generated on-demand only. The signal detection and suggestion system runs passively — this skill is where the user actively decides what to codify.
SIGNALS_FILE=".specweave/state/skill-signals.json"
if [ ! -f "$SIGNALS_FILE" ]; then
echo "No signals detected yet. Run a few increments with living docs enabled, then try again."
exit 0
fi
Read skill-signals.json and load config for minSignalCount (default: 3).
Filter signals where incrementIds.length >= minSignalCount. Display ALL qualifying patterns regardless of declined status (the user may reconsider).
For each qualifying signal, show:
[suggested], [declined], [generated], or [new]If no signals qualify: Print "No qualifying patterns found. Patterns need to be observed in at least {minSignalCount} increments."
Wait for the user to select a pattern by name or number. The user responds in natural language.
Verify Anthropic's official skill-creator is available (local-first, then global fallback):
# Check local project copy first (auto-installed by specweave init)
SKILL_CREATOR_PATH=".claude/skills/skill-creator/SKILL.md"
if [ ! -f "$SKILL_CREATOR_PATH" ]; then
# Fall back to global plugin cache
SKILL_CREATOR_PATH=$(find ~/.claude/plugins/cache/claude-plugins-official/skill-creator -name "SKILL.md" -maxdepth 3 2>/dev/null | head -1)
fi
if [ -z "$SKILL_CREATOR_PATH" ]; then
echo "ERROR: Anthropic's skill-creator plugin is not installed."
echo "Install it via: claude install-skill https://github.com/anthropics/claude-code/tree/main/skill-creator"
echo ""
echo "The skill-creator is required to build tested, benchmarked skills."
exit 1
fi
Slug dedup guard — before delegating, check if a skill with this slug already exists:
SKILL_SLUG="$SELECTED_PATTERN_SLUG" # e.g. "error-handling"
SKILL_DIR=".claude/skills/$SKILL_SLUG"
if [ -d "$SKILL_DIR" ] && [ -f "$SKILL_DIR/SKILL.md" ]; then
echo "Skill '$SKILL_SLUG' already exists at $SKILL_DIR/SKILL.md -- skipping generation."
# Mark signal as generated in skill-signals.json and continue to next pattern
exit 0
fi
Invoke the skill-creator with the selected pattern context:
Provide context to skill-creator:
project-error-handling)Skill-creator workflow handles:
Output location: .claude/skills/{pattern-slug}/SKILL.md (project-local)
After successful generation:
signal.generated = true;
// Save updated store
Print:
Generated project skill: .claude/skills/{pattern-slug}/SKILL.md
This skill will be active in future conversations for this project.
To test: start a new conversation and try a task related to {pattern-name}.
To remove: delete .claude/skills/{pattern-slug}/
| Flag | Description |
|------|-------------|
| --refresh | Re-check all existing .claude/skills/ against current living docs for drift |
When --refresh is passed:
.claude/skills/*.md filesControlled via .specweave/config.json:
{
"skillGen": {
"detection": "on-close",
"suggest": true,
"minSignalCount": 3,
"declinedSuggestions": [],
"maxSignals": 100
}
}
| Field | Default | Description |
|-------|---------|-------------|
| detection | "on-close" | When to detect patterns: "on-close" or "off" |
| suggest | true | Print suggestions on increment closure |
| minSignalCount | 3 | Minimum increments for a pattern to qualify |
| declinedSuggestions | [] | Pattern IDs permanently excluded from suggestions |
| maxSignals | 100 | Maximum signals to retain |
This skill activates when the user:
sw:skill-gen explicitlytools
Generate AI videos from text prompts or images. Supports Google Veo 3.1 and Pollinations.ai (free). Use when generating video, creating animations, text-to-video, AI video, video generation, make clip, animate.
tools
Validate increment with rule-based checks and AI quality assessment. Use when saying "validate", "check quality", or "verify increment".
tools
Create and manage umbrella workspaces for multi-repo projects. Activate when the user wants to: create umbrella, umbrella init, wrap in umbrella, create workspace, setup multi-repo, migrate repos to umbrella, umbrella create, new workspace, restructure into umbrella, "wrap this repo", "create umbrella for these repos", "setup workspace with repos", "move repos into umbrella". Do NOT activate for: add a repo to existing umbrella (use sw:get), add a feature, add an increment, clone a repo (use sw:get).
tools
--- description: Merge completed parallel agent work and trigger GitHub sync per increment. Activates for: team merge, merge agents, combine work, team finish. --- # Team Merge **Verify all teammates completed, run quality gates, close increments, and trigger sync.** ## Usage ```bash sw:team-merge sw:team-merge --dry-run # Preview merge plan sw:team-merge --skip-sync # Merge without GitHub/JIRA sync ``` ## What This Skill Does 1. **Verify all teammates completed** -- bl