Makepad Skills Evolution
This skill enables makepad-skills to self-improve continuously during development.
When to Use
- You are maintaining
makepad-skills and want the skill library to improve itself during development.
- You need the workflow for deciding when a new pattern should become a skill update or hook-driven evolution.
- You are working on self-correction, self-validation, or version adaptation for the skill set.
Quick Navigation
Hooks-Based Auto-Triggering
For reliable automatic triggering, use Claude Code hooks. Install with --with-hooks:
# Install makepad-skills with hooks enabled
tmpdir="$(mktemp -d)"
trap 'rm -rf "$tmpdir"' EXIT
curl -fsSLo "$tmpdir/makepad-skills-install.sh" https://raw.githubusercontent.com/ZhangHanDong/makepad-skills/main/install.sh
cat "$tmpdir/makepad-skills-install.sh" # review the full installer before executing
bash "$tmpdir/makepad-skills-install.sh" --with-hooks
This will install hooks to .claude/hooks/ and configure .claude/settings.json:
{
"hooks": {
"UserPromptSubmit": [
{
"matcher": "",
"hooks": [
{
"type": "command",
"command": "bash .claude/hooks/makepad-skill-router.sh"
}
]
}
],
"PreToolUse": [
{
"matcher": "Bash|Write|Edit",
"hooks": [
{
"type": "command",
"command": "bash .claude/hooks/pre-tool.sh"
}
]
}
],
"PostToolUse": [
{
"matcher": "Bash",
"hooks": [
{
"type": "command",
"command": "bash .claude/hooks/post-bash.sh"
}
]
}
]
}
}
What Hooks Do
| Hook |
Trigger Event |
Action |
makepad-skill-router.sh |
UserPromptSubmit |
Auto-route to relevant skills |
pre-tool.sh |
Before Bash/Write/Edit |
Detect Makepad version from Cargo.toml |
post-bash.sh |
After Bash command fails |
Detect Makepad errors, suggest fixes |
session-end.sh |
Session ends |
Prompt to capture learnings |
Skill Routing and Bundling
The makepad-skill-router.sh hook automatically loads relevant skills based on user queries.
Context Detection
| Context |
Trigger Keywords |
Skills Loaded |
| Full App |
"build app", "从零", "完整应用" |
basics, dsl, layout, widgets, event-action, app-architecture |
| UI Design |
"ui design", "界面设计" |
dsl, layout, widgets, animation, shaders |
| Widget Creation |
"create widget", "创建组件", "自定义组件" |
widgets, dsl, layout, animation, shaders, font, event-action |
| Production |
"best practice", "robrix pattern", "实际项目" |
app-architecture, widget-patterns, state-management, event-action |
Skill Dependencies
When loading certain skills, related skills are auto-loaded:
| Primary Skill |
Auto-loads |
| robius-app-architecture |
makepad-basics, makepad-event-action |
| robius-widget-patterns |
makepad-widgets, makepad-layout |
| makepad-widgets |
makepad-layout, makepad-dsl |
| makepad-animation |
makepad-shaders |
| makepad-shaders |
makepad-widgets |
| makepad-font |
makepad-widgets |
| robius-event-action |
makepad-event-action |
Example
User: "我想从零开发一个 Makepad 应用"
[makepad-skills] Detected Makepad/Robius query
[makepad-skills] App development context detected - loading skill bundle
[makepad-skills] Routing to: makepad-basics makepad-dsl makepad-event-action
makepad-layout makepad-widgets robius-app-architecture
When to Evolve
Trigger skill evolution when any of these occur during development:
| Trigger |
Target Skill |
Priority |
| New widget pattern discovered |
robius-widget-patterns/_base |
High |
| Shader technique learned |
makepad-shaders |
High |
| Compilation error solved |
makepad-reference/troubleshooting |
High |
| Layout solution found |
makepad-reference/adaptive-layout |
Medium |
| Build/packaging issue resolved |
makepad-deployment |
Medium |
| New project structure insight |
makepad-basics |
Low |
| Core concept clarified |
makepad-dsl/makepad-widgets |
Low |
Evolution Process
Step 1: Identify Knowledge Worth Capturing
Ask yourself:
- Is this a reusable pattern? (not project-specific)
- Did it take significant effort to figure out?
- Would
1---2name: evolution3description: This skill enables makepad-skills to self-improve continuously during development.4---567# Makepad Skills Evolution89This skill enables makepad-skills to self-improve continuously during development.1011## When to Use12- You are maintaining `makepad-skills` and want the skill library to improve itself during development.13- You need the workflow for deciding when a new pattern should become a skill update or hook-driven evolution.14- You are working on self-correction, self-validation, or version adaptation for the skill set.1516## Quick Navigation1718| Topic | Description |19|-------|-------------|20| Collaboration Guidelines | **Contributing to makepad-skills** |21| [Hooks Setup](#hooks-based-auto-triggering) | Auto-trigger evolution with hooks |22| [When to Evolve](#when-to-evolve) | Triggers and classification |23| [Evolution Process](#evolution-process) | Step-by-step guide |24| [Self-Correction](#self-correction) | Auto-fix skill errors |25| [Self-Validation](#self-validation) | Verify skill accuracy |26| [Version Adaptation](#version-adaptation) | Multi-branch support |2728---2930## Hooks-Based Auto-Triggering3132For reliable automatic triggering, use Claude Code hooks. Install with `--with-hooks`:3334```bash35# Install makepad-skills with hooks enabled36tmpdir="$(mktemp -d)"37trap 'rm -rf "$tmpdir"' EXIT38curl -fsSLo "$tmpdir/makepad-skills-install.sh" https://raw.githubusercontent.com/ZhangHanDong/makepad-skills/main/install.sh39cat "$tmpdir/makepad-skills-install.sh" # review the full installer before executing40bash "$tmpdir/makepad-skills-install.sh" --with-hooks41```4243This will install hooks to `.claude/hooks/` and configure `.claude/settings.json`:4445```json46{47 "hooks": {48 "UserPromptSubmit": [49 {50 "matcher": "",51 "hooks": [52 {53 "type": "command",54 "command": "bash .claude/hooks/makepad-skill-router.sh"55 }56 ]57 }58 ],59 "PreToolUse": [60 {61 "matcher": "Bash|Write|Edit",62 "hooks": [63 {64 "type": "command",65 "command": "bash .claude/hooks/pre-tool.sh"66 }67 ]68 }69 ],70 "PostToolUse": [71 {72 "matcher": "Bash",73 "hooks": [74 {75 "type": "command",76 "command": "bash .claude/hooks/post-bash.sh"77 }78 ]79 }80 ]81 }82}83```8485### What Hooks Do8687| Hook | Trigger Event | Action |88|------|---------------|--------|89| `makepad-skill-router.sh` | UserPromptSubmit | Auto-route to relevant skills |90| `pre-tool.sh` | Before Bash/Write/Edit | Detect Makepad version from Cargo.toml |91| `post-bash.sh` | After Bash command fails | Detect Makepad errors, suggest fixes |92| `session-end.sh` | Session ends | Prompt to capture learnings |9394---9596## Skill Routing and Bundling9798The `makepad-skill-router.sh` hook automatically loads relevant skills based on user queries.99100### Context Detection101102| Context | Trigger Keywords | Skills Loaded |103|---------|------------------|---------------|104| **Full App** | "build app", "从零", "完整应用" | basics, dsl, layout, widgets, event-action, app-architecture |105| **UI Design** | "ui design", "界面设计" | dsl, layout, widgets, animation, shaders |106| **Widget Creation** | "create widget", "创建组件", "自定义组件" | widgets, dsl, layout, animation, shaders, font, event-action |107| **Production** | "best practice", "robrix pattern", "实际项目" | app-architecture, widget-patterns, state-management, event-action |108109### Skill Dependencies110111When loading certain skills, related skills are auto-loaded:112113| Primary Skill | Auto-loads |114|---------------|------------|115| robius-app-architecture | makepad-basics, makepad-event-action |116| robius-widget-patterns | makepad-widgets, makepad-layout |117| makepad-widgets | makepad-layout, makepad-dsl |118| makepad-animation | makepad-shaders |119| makepad-shaders | makepad-widgets |120| makepad-font | makepad-widgets |121| robius-event-action | makepad-event-action |122123### Example124125```126User: "我想从零开发一个 Makepad 应用"127128[makepad-skills] Detected Makepad/Robius query129[makepad-skills] App development context detected - loading skill bundle130[makepad-skills] Routing to: makepad-basics makepad-dsl makepad-event-action131 makepad-layout makepad-widgets robius-app-architecture132```133134---135136## When to Evolve137138Trigger skill evolution when any of these occur during development:139140| Trigger | Target Skill | Priority |141|---------|--------------|----------|142| New widget pattern discovered | robius-widget-patterns/_base | High |143| Shader technique learned | makepad-shaders | High |144| Compilation error solved | makepad-reference/troubleshooting | High |145| Layout solution found | makepad-reference/adaptive-layout | Medium |146| Build/packaging issue resolved | makepad-deployment | Medium |147| New project structure insight | makepad-basics | Low |148| Core concept clarified | makepad-dsl/makepad-widgets | Low |149150---151152## Evolution Process153154### Step 1: Identify Knowledge Worth Capturing155156Ask yourself:157- Is this a reusable pattern? (not project-specific)158- Did it take significant effort to figure out?159- Would