ac-framework 1.0.1 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (39) hide show
  1. package/LICENSE +14 -0
  2. package/README.md +275 -24
  3. package/framework/.agent/skills/skill-writer/SKILL.md +385 -0
  4. package/framework/.amazonq/skills/skill-writer/SKILL.md +385 -0
  5. package/framework/.augment/skills/skill-writer/SKILL.md +385 -0
  6. package/framework/.claude/skills/skill-writer/SKILL.md +385 -0
  7. package/framework/.cline/skills/skill-writer/SKILL.md +385 -0
  8. package/framework/.codebuddy/skills/skill-writer/SKILL.md +385 -0
  9. package/framework/.codex/skills/skill-writer/SKILL.md +385 -0
  10. package/framework/.continue/skills/skill-writer/SKILL.md +385 -0
  11. package/framework/.cospec/skills/skill-writer/SKILL.md +385 -0
  12. package/framework/.crush/skills/skill-writer/SKILL.md +385 -0
  13. package/framework/.cursor/skills/skill-writer/SKILL.md +385 -0
  14. package/framework/.factory/skills/skill-writer/SKILL.md +385 -0
  15. package/framework/.gemini/skills/skill-writer/SKILL.md +385 -0
  16. package/framework/.github/skills/skill-writer/SKILL.md +385 -0
  17. package/framework/.iflow/skills/skill-writer/SKILL.md +385 -0
  18. package/framework/.kilocode/skills/skill-writer/SKILL.md +385 -0
  19. package/framework/.opencode/skills/skill-writer/SKILL.md +385 -0
  20. package/framework/.qoder/skills/skill-writer/SKILL.md +385 -0
  21. package/framework/.qwen/skills/skill-writer/SKILL.md +385 -0
  22. package/framework/.roo/skills/skill-writer/SKILL.md +385 -0
  23. package/framework/.trae/skills/skill-writer/SKILL.md +385 -0
  24. package/framework/.windsurf/skills/skill-writer/SKILL.md +385 -0
  25. package/framework/AGENTS.md +0 -0
  26. package/framework/CLAUDE.md +0 -0
  27. package/framework/GEMINI.md +0 -0
  28. package/framework/QWEN.md +0 -0
  29. package/framework/copilot-instructions.md +0 -0
  30. package/package.json +25 -6
  31. package/src/commands/init.js +236 -126
  32. package/src/config/constants.js +64 -0
  33. package/src/config/ide-mapping.js +47 -0
  34. package/src/index.js +4 -0
  35. package/src/services/detector.js +30 -0
  36. package/src/services/installer.js +77 -0
  37. package/src/ui/animations.js +281 -34
  38. package/src/ui/banner.js +78 -21
  39. package/src/utils/helpers.js +0 -28
package/LICENSE ADDED
@@ -0,0 +1,14 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2024 OpenSpec Contributors
4
+ Copyright © 2026 AF-Framework Contributors
5
+
6
+ This project includes modifications and extensions
7
+ based on the OpenSpec framework.
8
+
9
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
10
+
11
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
12
+
13
+ THE SOFTWARE IS PROVIDED “AS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
14
+
package/README.md CHANGED
@@ -1,24 +1,275 @@
1
- # AC-framework
2
- Agentic coding framework, including skills, workflow and more
3
-
4
- This framework use OpenSpec as base: MIT License
5
-
6
- Copyright (c) 2024 OpenSpec Contributors
7
-
8
- Permission is hereby granted, free of charge, to any person obtaining a copy
9
- of this software and associated documentation files (the "Software"), to deal
10
- in the Software without restriction, including without limitation the rights
11
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
12
- copies of the Software, and to permit persons to whom the Software is
13
- furnished to do so, subject to the following conditions:
14
-
15
- The above copyright notice and this permission notice shall be included in all
16
- copies or substantial portions of the Software.
17
-
18
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
21
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
23
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
24
- SOFTWARE.
1
+ # AC-Framework 🚀
2
+
3
+ <p align="center">
4
+ <img src="https://img.shields.io/badge/OpenSpec-Based-blue?style=for-the-badge&logo=data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjAiIGhlaWdodD0iMjAiIHZpZXdCb3g9IjAgMCAyMCAyMCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48cGF0aCBkPSJNMTAgMkM1LjU4IDIgMiA1LjU4IDIgMTBzMy41OCA4IDggOCA4LTMuNTggOC04LTMuNTgtOC04LTh6bTMuNSA5LjVhMS41IDEuNSAwIDAxLTIgMEwxMCAxMGwxLjUtMS41YTEuNSAxLjUgMCAwMTIgMEwxNCAxMGwtMS41IDEuNXoiIGZpbGw9IndoaXRlIi8+PC9zdmc+" />
5
+ <img src="https://img.shields.io/badge/Node.js-18+-green?style=for-the-badge&logo=node.js" />
6
+ <img src="https://img.shields.io/badge/License-MIT-yellow?style=for-the-badge" />
7
+ <img src="https://img.shields.io/badge/23+-Assistants-purple?style=for-the-badge" />
8
+ </p>
9
+
10
+ <p align="center">
11
+ <strong>🤖 Agentic Coding Framework</strong><br>
12
+ <em>Framework basado en OpenSpec con sistema de Skills mejorado y Skill Routing inteligente para IA</em>
13
+ </p>
14
+
15
+ ---
16
+
17
+ ## 📖 ¿Qué es AC-Framework?
18
+
19
+ **AC-Framework** (Agentic Coding Framework) es un framework de desarrollo avanzado basado en **OpenSpec** que implementa la metodología **Spec-Driven Development** con mejoras significativas para el contexto y enrutamiento de IA.
20
+
21
+ ### 🎯 Filosofía OpenSpec
22
+
23
+ AC-Framework adopta y potencia los principios fundamentales de OpenSpec:
24
+
25
+ - **📋 Todo cambio es un artefacto** - Cada modificación se documenta antes de implementarse
26
+ - **🔄 Desarrollo basado en especificaciones** - El "qué" (specs), "cómo" (design) y "por qué" (proposal) están separados
27
+ - **✅ Trazabilidad total** - Historial completo de decisiones y cambios
28
+ - **🎯 Contexto preservado** - La IA siempre tiene el contexto correcto para cada tarea
29
+
30
+
31
+ ---
32
+
33
+ ## 🚀 Características Principales
34
+
35
+ ### 🎭 10 Skills Especializadas
36
+
37
+ Cada skill está diseñada para un propósito específico del ciclo de desarrollo:
38
+
39
+ | Comando | Skill | Descripción |
40
+ |---------|-------|-------------|
41
+ | `/opsx:onboard` | **Onboarding** | Tutorial guiado para nuevos usuarios |
42
+ | `/opsx:new` | **New Change** | Crear cambio completo con proposal, specs, design y tasks |
43
+ | `/opsx:continue` | **Continue Change** | Retomar un cambio existente |
44
+ | `/opsx:ff` | **Fast Forward** | Crear todos los artefactos rápidamente |
45
+ | `/opsx:apply` | **Apply Change** | Implementar tareas del cambio actual |
46
+ | `/opsx:verify` | **Verify Change** | Verificar completitud y calidad |
47
+ | `/opsx:archive` | **Archive Change** | Archivar cambio completado |
48
+ | `/opsx:bulk-archive` | **Bulk Archive** | Archivar múltiples cambios |
49
+ | `/opsx:sync` | **Sync Specs** | Sincronizar specs delta a principales |
50
+ | `/opsx:explore` | **Explore** | Modo exploración (pensar antes de actuar) |
51
+
52
+ ### 🧠 Sistema de Skill Routing
53
+
54
+ El **Skill Routing** es una innovación clave de AC-Framework que proporciona:
55
+
56
+ - **🎯 Contexto Contextualizado**: Cada skill recibe solo el contexto relevante para su función
57
+ - **🔄 Enrutamiento Automático**: La IA sabe qué skill usar según el estado del proyecto
58
+ - **📊 Preservación de Estado**: El contexto se mantiene coherente entre skills
59
+ - **⚡ Optimización**: Menor consumo de tokens al enviar solo contexto necesario
60
+
61
+ ### 🌐 Multi-Asistente Sincronizado
62
+
63
+ **23+ Asistentes de IA soportados** con el mismo conjunto de skills:
64
+
65
+ #### IDEs y Editores
66
+ - 📝 **Cursor** - IDE con IA integrada
67
+ - 🌊 **Windsurf** - Editor AI-first
68
+ - 🎯 **Trae** - IDE con asistente IA
69
+ - 💎 **Gemini** - Google AI Studio
70
+
71
+ #### Herramientas CLI
72
+ - 🎩 **Claude Code** - CLI de Anthropic
73
+ - 🤖 **Codex** - OpenAI Codex CLI
74
+ - 👤 **CodeBuddy** - Asistente CLI
75
+
76
+ #### Extensiones VS Code
77
+ - 🔌 **Continue.dev** - Extensión de código abierto
78
+ - 🦅 **Cline** - Asistente de codificación
79
+ - 🦘 **Roo Code** - Fork de Cline
80
+ - 🐙 **GitHub Copilot** - Asistente de GitHub
81
+
82
+ #### Cloud y Otros
83
+ - ☁️ **Amazon Q** - AWS AI Assistant
84
+ - 🐉 **Qwen** - Alibaba Cloud
85
+ - ⚡ **Augment** - Augment Code
86
+ - 🔧 **OpenCode** - Framework de código abierto
87
+ - Y **13 asistentes más...**
88
+
89
+ ---
90
+
91
+ ## 📦 Instalación
92
+
93
+ ### Instalación Global
94
+
95
+ ```bash
96
+ # Instalar el CLI de AC-Framework
97
+ npm install -g ac-framework
98
+
99
+ # Inicializar en tu proyecto
100
+ acfm init
101
+ ```
102
+
103
+ ### Instalación Local
104
+
105
+ ```bash
106
+ # Instalar como dependencia de desarrollo
107
+ npm install --save-dev ac-framework
108
+
109
+ # Ejecutar el inicializador
110
+ npx acfm init
111
+ ```
112
+
113
+ ### Uso del CLI
114
+
115
+ ```bash
116
+ acfm [opciones] [comando]
117
+
118
+ Comandos:
119
+ init [options] Inicializar AC-Framework en el proyecto
120
+ help [command] Mostrar ayuda de un comando
121
+
122
+ Opciones:
123
+ -V, --version Mostrar versión
124
+ -h, --help Mostrar ayuda
125
+ ```
126
+
127
+ ---
128
+
129
+ ## 🏗️ Estructura de Proyecto OpenSpec
130
+
131
+ Cuando inicializas AC-Framework, se crea la siguiente estructura:
132
+
133
+ ```
134
+ openspec/
135
+ ├── config.yaml # Configuración global
136
+ ├── changes/ # Cambios activos
137
+ │ ├── {nombre-cambio}/
138
+ │ │ ├── proposal.md # 📝 Por QUÉ hacer el cambio
139
+ │ │ ├── design.md # 🎨 CÓMO se implementará
140
+ │ │ ├── tasks.md # ✅ Lista de tareas
141
+ │ │ └── specs/
142
+ │ │ └── {capability}/
143
+ │ │ └── spec.md # 📋 QUÉ cambia
144
+ │ └── archive/ # 📦 Cambios completados
145
+ │ └── YYYY-MM-DD-{nombre}/
146
+ └── specs/ # Especificaciones principales
147
+ └── {capability}/
148
+ └── spec.md
149
+ ```
150
+
151
+ ### Artefactos de un Cambio
152
+
153
+ Cada cambio OpenSpec incluye 4 artefactos fundamentales:
154
+
155
+ 1. **📄 proposal.md** - Justificación y contexto del cambio
156
+ 2. **🎨 design.md** - Arquitectura y enfoque de implementación
157
+ 3. **✅ tasks.md** - Checklist de tareas ejecutables
158
+ 4. **📋 specs/** - Especificaciones técnicas detalladas
159
+
160
+ ---
161
+
162
+ ## 🔄 Flujo de Trabajo
163
+
164
+ ```
165
+ ┌─────────────────────────────────────────────────────────────┐
166
+ │ 🧭 EXPLORAR (/opsx:explore) │
167
+ │ Investigar, entender, planificar │
168
+ └─────────────────────────────────────────────────────────────┘
169
+
170
+
171
+ ┌─────────────────────────────────────────────────────────────┐
172
+ │ 🆕 NUEVO (/opsx:new) o (/opsx:ff) │
173
+ │ • proposal.md ← Justificación │
174
+ │ • specs/ ← Requisitos │
175
+ │ • design.md ← Arquitectura │
176
+ │ • tasks.md ← Plan de trabajo │
177
+ └─────────────────────────────────────────────────────────────┘
178
+
179
+
180
+ ┌─────────────────────────────────────────────────────────────┐
181
+ │ 🔨 APLICAR (/opsx:apply) │
182
+ │ Implementar y marcar tareas completadas │
183
+ └─────────────────────────────────────────────────────────────┘
184
+
185
+
186
+ ┌─────────────────────────────────────────────────────────────┐
187
+ │ ✔️ VERIFICAR (/opsx:verify) │
188
+ │ Revisar calidad y completitud │
189
+ └─────────────────────────────────────────────────────────────┘
190
+
191
+ ▼ (opcional)
192
+ ┌─────────────────────────────────────────────────────────────┐
193
+ │ 🔄 SINCRONIZAR (/opsx:sync) │
194
+ │ Actualizar documentación principal │
195
+ └─────────────────────────────────────────────────────────────┘
196
+
197
+
198
+ ┌─────────────────────────────────────────────────────────────┐
199
+ │ 📦 ARCHIVAR (/opsx:archive) │
200
+ │ Mover a archivo con fecha │
201
+ └─────────────────────────────────────────────────────────────┘
202
+ ```
203
+
204
+ ---
205
+
206
+ ## 🛠️ Uso Rápido
207
+
208
+ ### 1. Inicializar Proyecto
209
+
210
+ ```bash
211
+ acfm init
212
+ ```
213
+
214
+ Selecciona los asistentes que usarás (puedes elegir múltiples):
215
+
216
+ ```
217
+ ? ¿Qué módulos deseas instalar? (Selecciona con espacio)
218
+ ❯◉ Cursor IDE
219
+ ◯ Claude Code
220
+ ◯ Continue.dev
221
+ ◉ GitHub Copilot
222
+ ◯ ...
223
+ ```
224
+
225
+ ### 2. Crear un Cambio
226
+
227
+ ```
228
+ /opsx:new feature-user-authentication
229
+ ```
230
+
231
+ Esto crea:
232
+ - `openspec/changes/feature-user-authentication/proposal.md`
233
+ - `openspec/changes/feature-user-authentication/design.md`
234
+ - `openspec/changes/feature-user-authentication/tasks.md`
235
+ - `openspec/changes/feature-user-authentication/specs/auth/spec.md`
236
+
237
+ ### 3. Implementar
238
+
239
+ ```
240
+ /opsx:apply
241
+ ```
242
+
243
+ La IA implementará las tareas del archivo `tasks.md`, marcándolas como completadas.
244
+
245
+ ### 4. Verificar y Archivar
246
+
247
+ ```
248
+ /opsx:verify
249
+ /opsx:archive
250
+ ```
251
+
252
+ ---
253
+
254
+ ```bash
255
+ # Las skills están en:
256
+ framework/.{asistente}/skills/openspec-{nombre}/SKILL.md
257
+
258
+ # Ejemplo:
259
+ framework/.cursor/skills/openspec-new-change/SKILL.md
260
+ framework/.claude/skills/openspec-new-change/SKILL.md
261
+ framework/.opencode/skills/openspec-new-change/SKILL.md
262
+ ```
263
+
264
+ ---
265
+
266
+ ## 📝 Licencia
267
+
268
+ MIT © AC-Framework Team
269
+
270
+ ---
271
+
272
+ <p align="center">
273
+ <strong>🚀 Desarrollo asistido por IA, estandarizado y potenciado</strong><br>
274
+ <em>Trabaja con cualquier asistente, mantén el mismo flujo de trabajo</em>
275
+ </p>
@@ -0,0 +1,385 @@
1
+ ---
2
+ name: skill-writer
3
+ description: Guide users through creating Agent Skills for Claude Code. Use when the user wants to create, write, author, or design a new Skill, or needs help with SKILL.md files, frontmatter, or skill structure.
4
+ ---
5
+
6
+ # Skill Writer
7
+
8
+ This Skill helps you create well-structured Agent Skills for Claude Code that follow best practices and validation requirements.
9
+
10
+ ## When to use this Skill
11
+
12
+ Use this Skill when:
13
+ - Creating a new Agent Skill
14
+ - Writing or updating SKILL.md files
15
+ - Designing skill structure and frontmatter
16
+ - Troubleshooting skill discovery issues
17
+ - Converting existing prompts or workflows into Skills
18
+
19
+ ## Instructions
20
+
21
+ ### Step 1: Determine Skill scope
22
+
23
+ First, understand what the Skill should do:
24
+
25
+ 1. **Ask clarifying questions**:
26
+ - What specific capability should this Skill provide?
27
+ - When should Claude use this Skill?
28
+ - What tools or resources does it need?
29
+ - Is this for personal use or team sharing?
30
+
31
+ 2. **Keep it focused**: One Skill = one capability
32
+ - Good: "PDF form filling", "Excel data analysis"
33
+ - Too broad: "Document processing", "Data tools"
34
+
35
+ ### Step 2: Choose Skill location
36
+
37
+ Determine where to create the Skill:
38
+
39
+ **Personal Skills** (`~/.claude/skills/`):
40
+ - Individual workflows and preferences
41
+ - Experimental Skills
42
+ - Personal productivity tools
43
+
44
+ **Project Skills** (`.claude/skills/`):
45
+ - Team workflows and conventions
46
+ - Project-specific expertise
47
+ - Shared utilities (committed to git)
48
+
49
+ ### Step 3: Create Skill structure
50
+
51
+ Create the directory and files:
52
+
53
+ ```bash
54
+ # Personal
55
+ mkdir -p ~/.claude/skills/skill-name
56
+
57
+ # Project
58
+ mkdir -p .claude/skills/skill-name
59
+ ```
60
+
61
+ For multi-file Skills:
62
+ ```
63
+ skill-name/
64
+ ├── SKILL.md (required)
65
+ ├── reference.md (optional)
66
+ ├── examples.md (optional)
67
+ ├── scripts/
68
+ │ └── helper.py (optional)
69
+ └── templates/
70
+ └── template.txt (optional)
71
+ ```
72
+
73
+ ### Step 4: Write SKILL.md frontmatter
74
+
75
+ Create YAML frontmatter with required fields:
76
+
77
+ ```yaml
78
+ ---
79
+ name: skill-name
80
+ description: Brief description of what this does and when to use it
81
+ ---
82
+ ```
83
+
84
+ **Field requirements**:
85
+
86
+ - **name**:
87
+ - Lowercase letters, numbers, hyphens only
88
+ - Max 64 characters
89
+ - Must match directory name
90
+ - Good: `pdf-processor`, `git-commit-helper`
91
+ - Bad: `PDF_Processor`, `Git Commits!`
92
+
93
+ - **description**:
94
+ - Max 1024 characters
95
+ - Include BOTH what it does AND when to use it
96
+ - Use specific trigger words users would say
97
+ - Mention file types, operations, and context
98
+
99
+ **Optional frontmatter fields**:
100
+
101
+ - **allowed-tools**: Restrict tool access (comma-separated list)
102
+ ```yaml
103
+ allowed-tools: Read, Grep, Glob
104
+ ```
105
+ Use for:
106
+ - Read-only Skills
107
+ - Security-sensitive workflows
108
+ - Limited-scope operations
109
+
110
+ ### Step 5: Write effective descriptions
111
+
112
+ The description is critical for Claude to discover your Skill.
113
+
114
+ **Formula**: `[What it does] + [When to use it] + [Key triggers]`
115
+
116
+ **Examples**:
117
+
118
+ ✅ **Good**:
119
+ ```yaml
120
+ description: Extract text and tables from PDF files, fill forms, merge documents. Use when working with PDF files or when the user mentions PDFs, forms, or document extraction.
121
+ ```
122
+
123
+ ✅ **Good**:
124
+ ```yaml
125
+ description: Analyze Excel spreadsheets, create pivot tables, and generate charts. Use when working with Excel files, spreadsheets, or analyzing tabular data in .xlsx format.
126
+ ```
127
+
128
+ ❌ **Too vague**:
129
+ ```yaml
130
+ description: Helps with documents
131
+ description: For data analysis
132
+ ```
133
+
134
+ **Tips**:
135
+ - Include specific file extensions (.pdf, .xlsx, .json)
136
+ - Mention common user phrases ("analyze", "extract", "generate")
137
+ - List concrete operations (not generic verbs)
138
+ - Add context clues ("Use when...", "For...")
139
+
140
+ ### Step 6: Structure the Skill content
141
+
142
+ Use clear Markdown sections:
143
+
144
+ ```markdown
145
+ # Skill Name
146
+
147
+ Brief overview of what this Skill does.
148
+
149
+ ## Quick start
150
+
151
+ Provide a simple example to get started immediately.
152
+
153
+ ## Instructions
154
+
155
+ Step-by-step guidance for Claude:
156
+ 1. First step with clear action
157
+ 2. Second step with expected outcome
158
+ 3. Handle edge cases
159
+
160
+ ## Examples
161
+
162
+ Show concrete usage examples with code or commands.
163
+
164
+ ## Best practices
165
+
166
+ - Key conventions to follow
167
+ - Common pitfalls to avoid
168
+ - When to use vs. not use
169
+
170
+ ## Requirements
171
+
172
+ List any dependencies or prerequisites:
173
+ ```bash
174
+ pip install package-name
175
+ ```
176
+
177
+ ## Advanced usage
178
+
179
+ For complex scenarios, see [reference.md](reference.md).
180
+ ```
181
+
182
+ ### Step 7: Add supporting files (optional)
183
+
184
+ Create additional files for progressive disclosure:
185
+
186
+ **reference.md**: Detailed API docs, advanced options
187
+ **examples.md**: Extended examples and use cases
188
+ **scripts/**: Helper scripts and utilities
189
+ **templates/**: File templates or boilerplate
190
+
191
+ Reference them from SKILL.md:
192
+ ```markdown
193
+ For advanced usage, see [reference.md](reference.md).
194
+
195
+ Run the helper script:
196
+ \`\`\`bash
197
+ python scripts/helper.py input.txt
198
+ \`\`\`
199
+ ```
200
+
201
+ ### Step 8: Validate the Skill
202
+
203
+ Check these requirements:
204
+
205
+ ✅ **File structure**:
206
+ - [ ] SKILL.md exists in correct location
207
+ - [ ] Directory name matches frontmatter `name`
208
+
209
+ ✅ **YAML frontmatter**:
210
+ - [ ] Opening `---` on line 1
211
+ - [ ] Closing `---` before content
212
+ - [ ] Valid YAML (no tabs, correct indentation)
213
+ - [ ] `name` follows naming rules
214
+ - [ ] `description` is specific and < 1024 chars
215
+
216
+ ✅ **Content quality**:
217
+ - [ ] Clear instructions for Claude
218
+ - [ ] Concrete examples provided
219
+ - [ ] Edge cases handled
220
+ - [ ] Dependencies listed (if any)
221
+
222
+ ✅ **Testing**:
223
+ - [ ] Description matches user questions
224
+ - [ ] Skill activates on relevant queries
225
+ - [ ] Instructions are clear and actionable
226
+
227
+ ### Step 9: Test the Skill
228
+
229
+ 1. **Restart Claude Code** (if running) to load the Skill
230
+
231
+ 2. **Ask relevant questions** that match the description:
232
+ ```
233
+ Can you help me extract text from this PDF?
234
+ ```
235
+
236
+ 3. **Verify activation**: Claude should use the Skill automatically
237
+
238
+ 4. **Check behavior**: Confirm Claude follows the instructions correctly
239
+
240
+ ### Step 10: Debug if needed
241
+
242
+ If Claude doesn't use the Skill:
243
+
244
+ 1. **Make description more specific**:
245
+ - Add trigger words
246
+ - Include file types
247
+ - Mention common user phrases
248
+
249
+ 2. **Check file location**:
250
+ ```bash
251
+ ls ~/.claude/skills/skill-name/SKILL.md
252
+ ls .claude/skills/skill-name/SKILL.md
253
+ ```
254
+
255
+ 3. **Validate YAML**:
256
+ ```bash
257
+ cat SKILL.md | head -n 10
258
+ ```
259
+
260
+ 4. **Run debug mode**:
261
+ ```bash
262
+ claude --debug
263
+ ```
264
+
265
+ ## Common patterns
266
+
267
+ ### Read-only Skill
268
+
269
+ ```yaml
270
+ ---
271
+ name: code-reader
272
+ description: Read and analyze code without making changes. Use for code review, understanding codebases, or documentation.
273
+ allowed-tools: Read, Grep, Glob
274
+ ---
275
+ ```
276
+
277
+ ### Script-based Skill
278
+
279
+ ```yaml
280
+ ---
281
+ name: data-processor
282
+ description: Process CSV and JSON data files with Python scripts. Use when analyzing data files or transforming datasets.
283
+ ---
284
+
285
+ # Data Processor
286
+
287
+ ## Instructions
288
+
289
+ 1. Use the processing script:
290
+ \`\`\`bash
291
+ python scripts/process.py input.csv --output results.json
292
+ \`\`\`
293
+
294
+ 2. Validate output with:
295
+ \`\`\`bash
296
+ python scripts/validate.py results.json
297
+ \`\`\`
298
+ ```
299
+
300
+ ### Multi-file Skill with progressive disclosure
301
+
302
+ ```yaml
303
+ ---
304
+ name: api-designer
305
+ description: Design REST APIs following best practices. Use when creating API endpoints, designing routes, or planning API architecture.
306
+ ---
307
+
308
+ # API Designer
309
+
310
+ Quick start: See [examples.md](examples.md)
311
+
312
+ Detailed reference: See [reference.md](reference.md)
313
+
314
+ ## Instructions
315
+
316
+ 1. Gather requirements
317
+ 2. Design endpoints (see examples.md)
318
+ 3. Document with OpenAPI spec
319
+ 4. Review against best practices (see reference.md)
320
+ ```
321
+
322
+ ## Best practices for Skill authors
323
+
324
+ 1. **One Skill, one purpose**: Don't create mega-Skills
325
+ 2. **Specific descriptions**: Include trigger words users will say
326
+ 3. **Clear instructions**: Write for Claude, not humans
327
+ 4. **Concrete examples**: Show real code, not pseudocode
328
+ 5. **List dependencies**: Mention required packages in description
329
+ 6. **Test with teammates**: Verify activation and clarity
330
+ 7. **Version your Skills**: Document changes in content
331
+ 8. **Use progressive disclosure**: Put advanced details in separate files
332
+
333
+ ## Validation checklist
334
+
335
+ Before finalizing a Skill, verify:
336
+
337
+ - [ ] Name is lowercase, hyphens only, max 64 chars
338
+ - [ ] Description is specific and < 1024 chars
339
+ - [ ] Description includes "what" and "when"
340
+ - [ ] YAML frontmatter is valid
341
+ - [ ] Instructions are step-by-step
342
+ - [ ] Examples are concrete and realistic
343
+ - [ ] Dependencies are documented
344
+ - [ ] File paths use forward slashes
345
+ - [ ] Skill activates on relevant queries
346
+ - [ ] Claude follows instructions correctly
347
+
348
+ ## Troubleshooting
349
+
350
+ **Skill doesn't activate**:
351
+ - Make description more specific with trigger words
352
+ - Include file types and operations in description
353
+ - Add "Use when..." clause with user phrases
354
+
355
+ **Multiple Skills conflict**:
356
+ - Make descriptions more distinct
357
+ - Use different trigger words
358
+ - Narrow the scope of each Skill
359
+
360
+ **Skill has errors**:
361
+ - Check YAML syntax (no tabs, proper indentation)
362
+ - Verify file paths (use forward slashes)
363
+ - Ensure scripts have execute permissions
364
+ - List all dependencies
365
+
366
+ ## Examples
367
+
368
+ See the documentation for complete examples:
369
+ - Simple single-file Skill (commit-helper)
370
+ - Skill with tool permissions (code-reviewer)
371
+ - Multi-file Skill (pdf-processing)
372
+
373
+ ## Output format
374
+
375
+ When creating a Skill, I will:
376
+
377
+ 1. Ask clarifying questions about scope and requirements
378
+ 2. Suggest a Skill name and location
379
+ 3. Create the SKILL.md file with proper frontmatter
380
+ 4. Include clear instructions and examples
381
+ 5. Add supporting files if needed
382
+ 6. Provide testing instructions
383
+ 7. Validate against all requirements
384
+
385
+ The result will be a complete, working Skill that follows all best practices and validation rules.