@rfxlamia/skillkit 1.0.0 → 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 (269) hide show
  1. package/agents/agents/creative-copywriter.md +212 -0
  2. package/agents/agents/dario-amodei.md +135 -0
  3. package/agents/agents/doc-simplifier.md +63 -0
  4. package/agents/agents/kotlin-pro.md +433 -0
  5. package/agents/agents/red-team.md +136 -0
  6. package/agents/agents/sam-altman.md +121 -0
  7. package/agents/agents/seo-manager.md +184 -0
  8. package/package.json +7 -2
  9. package/skills/quick-spec/tests/__pycache__/test_skill.cpython-314-pytest-9.0.2.pyc +0 -0
  10. package/skills/skillkit/.claude/settings.local.json +7 -0
  11. package/skills/skillkit/scripts/__pycache__/decision_helper.cpython-314.pyc +0 -0
  12. package/skills/skillkit/scripts/__pycache__/quick_validate.cpython-312.pyc +0 -0
  13. package/skills/skillkit/scripts/__pycache__/quick_validate.cpython-314.pyc +0 -0
  14. package/skills/skillkit/scripts/__pycache__/test_generator.cpython-314-pytest-9.0.2.pyc +0 -0
  15. package/skills/skillkit/scripts/utils/__pycache__/__init__.cpython-312.pyc +0 -0
  16. package/skills/skillkit/scripts/utils/__pycache__/__init__.cpython-314.pyc +0 -0
  17. package/skills/skillkit/scripts/utils/__pycache__/budget_tracker.cpython-312.pyc +0 -0
  18. package/skills/skillkit/scripts/utils/__pycache__/budget_tracker.cpython-314.pyc +0 -0
  19. package/skills/skillkit/scripts/utils/__pycache__/output_formatter.cpython-312.pyc +0 -0
  20. package/skills/skillkit/scripts/utils/__pycache__/output_formatter.cpython-314.pyc +0 -0
  21. package/skills/skillkit/scripts/utils/__pycache__/reference_validator.cpython-312.pyc +0 -0
  22. package/skills/skillkit/scripts/utils/__pycache__/reference_validator.cpython-314.pyc +0 -0
  23. package/skills/skillkit-help/SKILL.md +81 -0
  24. package/skills/skillkit-help/knowledge/application/09-case-studies.md +257 -0
  25. package/skills/skillkit-help/knowledge/application/12-testing-and-validation.md +276 -0
  26. package/skills/skillkit-help/knowledge/foundation/01-why-skills-exist.md +246 -0
  27. package/skills/skillkit-help/knowledge/foundation/02-skills-vs-subagents-comparison.md +312 -0
  28. package/skills/skillkit-help/knowledge/foundation/03-skills-vs-subagents-decision-tree.md +346 -0
  29. package/skills/skillkit-help/knowledge/foundation/06-platform-constraints.md +237 -0
  30. package/skills/skillkit-help/knowledge/foundation/08-when-not-to-use-skills.md +270 -0
  31. package/skills/skillkit-help/template/SKILL.md +52 -0
  32. package/skills/skills/adversarial-review/SKILL.md +219 -0
  33. package/skills/skills/baby-education/SKILL.md +260 -0
  34. package/skills/skills/baby-education/references/advanced-techniques.md +323 -0
  35. package/skills/skills/baby-education/references/transformations.md +345 -0
  36. package/skills/skills/been-there-done-that/SKILL.md +455 -0
  37. package/skills/skills/been-there-done-that/references/analysis-patterns.md +162 -0
  38. package/skills/skills/been-there-done-that/references/git-commands.md +132 -0
  39. package/skills/skills/been-there-done-that/references/tree-insertion-logic.md +145 -0
  40. package/skills/skills/coolhunter/SKILL.md +270 -0
  41. package/skills/skills/coolhunter/assets/elicitation-methods.csv +51 -0
  42. package/skills/skills/coolhunter/knowledge/elicitation-methods.md +312 -0
  43. package/skills/skills/coolhunter/references/workflow-execution.md +238 -0
  44. package/skills/skills/coolhunter/workflow-plan-coolhunter.md +232 -0
  45. package/skills/skills/creative-copywriting/SKILL.md +324 -0
  46. package/skills/skills/creative-copywriting/databases/README.md +60 -0
  47. package/skills/skills/creative-copywriting/databases/carousel-structures.csv +16 -0
  48. package/skills/skills/creative-copywriting/databases/emotional-arcs.csv +11 -0
  49. package/skills/skills/creative-copywriting/databases/hook-formulas.csv +51 -0
  50. package/skills/skills/creative-copywriting/databases/power-words.csv +201 -0
  51. package/skills/skills/creative-copywriting/databases/psychological-triggers.csv +21 -0
  52. package/skills/skills/creative-copywriting/databases/read-more-patterns.csv +26 -0
  53. package/skills/skills/creative-copywriting/databases/swipe-triggers.csv +31 -0
  54. package/skills/skills/creative-copywriting/references/carousel-psychology.md +223 -0
  55. package/skills/skills/creative-copywriting/references/hook-anatomy.md +169 -0
  56. package/skills/skills/creative-copywriting/references/power-word-science.md +134 -0
  57. package/skills/skills/creative-copywriting/references/storytelling-frameworks.md +157 -0
  58. package/skills/skills/diverse-content-gen/SKILL.md +201 -0
  59. package/skills/skills/diverse-content-gen/references/advanced-techniques.md +320 -0
  60. package/skills/skills/diverse-content-gen/references/research-findings.md +379 -0
  61. package/skills/skills/diverse-content-gen/references/task-workflows.md +241 -0
  62. package/skills/skills/diverse-content-gen/references/tool-integration.md +419 -0
  63. package/skills/skills/diverse-content-gen/references/troubleshooting.md +426 -0
  64. package/skills/skills/diverse-content-gen/references/vs-core-technique.md +240 -0
  65. package/skills/skills/framework-critical-thinking/SKILL.md +220 -0
  66. package/skills/skills/framework-critical-thinking/references/bias_detector.md +375 -0
  67. package/skills/skills/framework-critical-thinking/references/fallback_handler.md +239 -0
  68. package/skills/skills/framework-critical-thinking/references/memory_curator.md +161 -0
  69. package/skills/skills/framework-critical-thinking/references/metacognitive_monitor.md +297 -0
  70. package/skills/skills/framework-critical-thinking/references/producer_critic_orchestrator.md +333 -0
  71. package/skills/skills/framework-critical-thinking/references/reasoning_router.md +235 -0
  72. package/skills/skills/framework-critical-thinking/references/reasoning_validator.md +97 -0
  73. package/skills/skills/framework-critical-thinking/references/reflection_trigger.md +78 -0
  74. package/skills/skills/framework-critical-thinking/references/self_verification.md +388 -0
  75. package/skills/skills/framework-critical-thinking/references/uncertainty_quantifier.md +207 -0
  76. package/skills/skills/framework-initiative/SKILL.md +231 -0
  77. package/skills/skills/framework-initiative/references/examples.md +150 -0
  78. package/skills/skills/framework-initiative/references/impact-analysis.md +157 -0
  79. package/skills/skills/framework-initiative/references/intent-patterns.md +145 -0
  80. package/skills/skills/framework-initiative/references/star-framework.md +165 -0
  81. package/skills/skills/humanize-docs/SKILL.md +203 -0
  82. package/skills/skills/humanize-docs/references/advanced-techniques.md +13 -0
  83. package/skills/skills/humanize-docs/references/core-transformations.md +368 -0
  84. package/skills/skills/humanize-docs/references/detection-patterns.md +400 -0
  85. package/skills/skills/humanize-docs/references/examples-gallery.md +374 -0
  86. package/skills/skills/imagine/SKILL.md +190 -0
  87. package/skills/skills/imagine/references/artstyle-corporate-memphis.md +625 -0
  88. package/skills/skills/imagine/references/artstyle-crewdson-hyperrealism.md +295 -0
  89. package/skills/skills/imagine/references/artstyle-iphone-social-media.md +426 -0
  90. package/skills/skills/imagine/references/artstyle-sciencesaru.md +276 -0
  91. package/skills/skills/pre-deploy-checklist/README.md +26 -0
  92. package/skills/skills/pre-deploy-checklist/SKILL.md +153 -0
  93. package/skills/skills/pre-deploy-checklist/references/checklist-categories.md +174 -0
  94. package/skills/skills/pre-deploy-checklist/references/domain-prompts.md +216 -0
  95. package/skills/skills/prompt-engineering/SKILL.md +209 -0
  96. package/skills/skills/prompt-engineering/references/advanced-combinations.md +444 -0
  97. package/skills/skills/prompt-engineering/references/chain-of-thought.md +140 -0
  98. package/skills/skills/prompt-engineering/references/decision_matrix.md +220 -0
  99. package/skills/skills/prompt-engineering/references/few-shot.md +346 -0
  100. package/skills/skills/prompt-engineering/references/json-format.md +270 -0
  101. package/skills/skills/prompt-engineering/references/natural-language.md +420 -0
  102. package/skills/skills/prompt-engineering/references/pitfalls.md +365 -0
  103. package/skills/skills/prompt-engineering/references/prompt-chaining.md +498 -0
  104. package/skills/skills/prompt-engineering/references/react.md +108 -0
  105. package/skills/skills/prompt-engineering/references/self-consistency.md +322 -0
  106. package/skills/skills/prompt-engineering/references/tree-of-thoughts.md +386 -0
  107. package/skills/skills/prompt-engineering/references/xml-format.md +220 -0
  108. package/skills/skills/prompt-engineering/references/yaml-format.md +488 -0
  109. package/skills/skills/prompt-engineering/references/zero-shot.md +74 -0
  110. package/skills/skills/quick-spec/SKILL.md +280 -0
  111. package/skills/skills/quick-spec/assets/tech-spec-template.md +74 -0
  112. package/skills/skills/quick-spec/references/step-01-understand.md +189 -0
  113. package/skills/skills/quick-spec/references/step-02-investigate.md +144 -0
  114. package/skills/skills/quick-spec/references/step-03-generate.md +128 -0
  115. package/skills/skills/quick-spec/references/step-04-review.md +173 -0
  116. package/skills/skills/quick-spec/tests/__pycache__/test_skill.cpython-314-pytest-9.0.2.pyc +0 -0
  117. package/skills/skills/quick-spec/tests/test_scenarios.md +83 -0
  118. package/skills/skills/quick-spec/tests/test_skill.py +136 -0
  119. package/skills/skills/readme-expert/SKILL.md +538 -0
  120. package/skills/skills/readme-expert/knowledge/INDEX.md +192 -0
  121. package/skills/skills/readme-expert/knowledge/application/quality-standards.md +470 -0
  122. package/skills/skills/readme-expert/knowledge/application/script-executor.md +604 -0
  123. package/skills/skills/readme-expert/knowledge/application/template-library.md +822 -0
  124. package/skills/skills/readme-expert/knowledge/foundation/codebase-scanner.md +361 -0
  125. package/skills/skills/readme-expert/knowledge/foundation/validation-checklist.md +481 -0
  126. package/skills/skills/red-teaming/SKILL.md +321 -0
  127. package/skills/skills/red-teaming/references/ai-llm-redteam.md +517 -0
  128. package/skills/skills/red-teaming/references/attack-techniques.md +410 -0
  129. package/skills/skills/red-teaming/references/cybersecurity-redteam.md +383 -0
  130. package/skills/skills/red-teaming/references/tools-frameworks.md +446 -0
  131. package/skills/skills/releasing/.skillkit-mode +1 -0
  132. package/skills/skills/releasing/SKILL.md +225 -0
  133. package/skills/skills/releasing/references/version-detection.md +108 -0
  134. package/skills/skills/screenwriter/SKILL.md +273 -0
  135. package/skills/skills/screenwriter/references/advanced-techniques.md +216 -0
  136. package/skills/skills/screenwriter/references/pipeline-integration.md +266 -0
  137. package/skills/skills/skillkit/.claude/settings.local.json +7 -0
  138. package/skills/skills/skillkit/.claude-plugin/plugin.json +27 -0
  139. package/skills/skills/skillkit/CHANGELOG.md +484 -0
  140. package/skills/skills/skillkit/SKILL.md +511 -0
  141. package/skills/skills/skillkit/commands/skillkit.md +6 -0
  142. package/skills/skills/skillkit/commands/validate-plan.md +6 -0
  143. package/skills/skills/skillkit/commands/verify.md +6 -0
  144. package/skills/skills/skillkit/knowledge/INDEX.md +352 -0
  145. package/skills/skills/skillkit/knowledge/application/09-case-studies.md +257 -0
  146. package/skills/skills/skillkit/knowledge/application/10-technical-architecture.md +324 -0
  147. package/skills/skills/skillkit/knowledge/application/11-adoption-strategy.md +267 -0
  148. package/skills/skills/skillkit/knowledge/application/12-testing-and-validation.md +276 -0
  149. package/skills/skills/skillkit/knowledge/application/13-competitive-landscape.md +198 -0
  150. package/skills/skills/skillkit/knowledge/foundation/01-why-skills-exist.md +246 -0
  151. package/skills/skills/skillkit/knowledge/foundation/02-skills-vs-subagents-comparison.md +312 -0
  152. package/skills/skills/skillkit/knowledge/foundation/03-skills-vs-subagents-decision-tree.md +346 -0
  153. package/skills/skills/skillkit/knowledge/foundation/04-hybrid-patterns.md +308 -0
  154. package/skills/skills/skillkit/knowledge/foundation/05-token-economics.md +275 -0
  155. package/skills/skills/skillkit/knowledge/foundation/06-platform-constraints.md +237 -0
  156. package/skills/skills/skillkit/knowledge/foundation/07-security-concerns.md +322 -0
  157. package/skills/skills/skillkit/knowledge/foundation/08-when-not-to-use-skills.md +270 -0
  158. package/skills/skills/skillkit/knowledge/plugin-guide.md +614 -0
  159. package/skills/skills/skillkit/knowledge/tools/14-validation-tools-guide.md +150 -0
  160. package/skills/skills/skillkit/knowledge/tools/15-cost-tools-guide.md +157 -0
  161. package/skills/skills/skillkit/knowledge/tools/16-security-tools-guide.md +122 -0
  162. package/skills/skills/skillkit/knowledge/tools/17-pattern-tools-guide.md +161 -0
  163. package/skills/skills/skillkit/knowledge/tools/18-decision-helper-guide.md +243 -0
  164. package/skills/skills/skillkit/knowledge/tools/19-test-generator-guide.md +275 -0
  165. package/skills/skills/skillkit/knowledge/tools/20-split-skill-guide.md +149 -0
  166. package/skills/skills/skillkit/knowledge/tools/21-quality-scorer-guide.md +226 -0
  167. package/skills/skills/skillkit/knowledge/tools/22-migration-helper-guide.md +356 -0
  168. package/skills/skills/skillkit/knowledge/tools/23-subagent-creation-guide.md +448 -0
  169. package/skills/skills/skillkit/knowledge/tools/24-behavioral-testing-guide.md +122 -0
  170. package/skills/skills/skillkit/references/proposal-generation.md +982 -0
  171. package/skills/skills/skillkit/references/rationalization-catalog.md +75 -0
  172. package/skills/skills/skillkit/references/research-methodology.md +661 -0
  173. package/skills/skills/skillkit/references/section-2-full-creation-workflow.md +452 -0
  174. package/skills/skills/skillkit/references/section-3-validation-workflow-existing-skill.md +63 -0
  175. package/skills/skills/skillkit/references/section-4-decision-workflow-skills-vs-subagents.md +64 -0
  176. package/skills/skills/skillkit/references/section-5-migration-workflow-doc-to-skill.md +58 -0
  177. package/skills/skills/skillkit/references/section-6-subagent-creation-workflow.md +499 -0
  178. package/skills/skills/skillkit/references/section-7-knowledge-reference-map.md +72 -0
  179. package/skills/skills/skillkit/scripts/__pycache__/decision_helper.cpython-314.pyc +0 -0
  180. package/skills/skills/skillkit/scripts/__pycache__/quick_validate.cpython-312.pyc +0 -0
  181. package/skills/skills/skillkit/scripts/__pycache__/quick_validate.cpython-314.pyc +0 -0
  182. package/skills/skills/skillkit/scripts/__pycache__/test_generator.cpython-314-pytest-9.0.2.pyc +0 -0
  183. package/skills/skills/skillkit/scripts/decision_helper.py +799 -0
  184. package/skills/skills/skillkit/scripts/init_skill.py +400 -0
  185. package/skills/skills/skillkit/scripts/init_subagent.py +231 -0
  186. package/skills/skills/skillkit/scripts/migration_helper.py +669 -0
  187. package/skills/skills/skillkit/scripts/package_skill.py +211 -0
  188. package/skills/skills/skillkit/scripts/pattern_detector.py +381 -0
  189. package/skills/skills/skillkit/scripts/pattern_detector_new.py +382 -0
  190. package/skills/skills/skillkit/scripts/pressure_tester.py +157 -0
  191. package/skills/skills/skillkit/scripts/quality_scorer.py +999 -0
  192. package/skills/skills/skillkit/scripts/quick_validate.py +100 -0
  193. package/skills/skills/skillkit/scripts/security_scanner.py +474 -0
  194. package/skills/skills/skillkit/scripts/split_skill.py +540 -0
  195. package/skills/skills/skillkit/scripts/test_generator.py +695 -0
  196. package/skills/skills/skillkit/scripts/token_estimator.py +493 -0
  197. package/skills/skills/skillkit/scripts/utils/__init__.py +49 -0
  198. package/skills/skills/skillkit/scripts/utils/__pycache__/__init__.cpython-312.pyc +0 -0
  199. package/skills/skills/skillkit/scripts/utils/__pycache__/__init__.cpython-314.pyc +0 -0
  200. package/skills/skills/skillkit/scripts/utils/__pycache__/budget_tracker.cpython-312.pyc +0 -0
  201. package/skills/skills/skillkit/scripts/utils/__pycache__/budget_tracker.cpython-314.pyc +0 -0
  202. package/skills/skills/skillkit/scripts/utils/__pycache__/output_formatter.cpython-312.pyc +0 -0
  203. package/skills/skills/skillkit/scripts/utils/__pycache__/output_formatter.cpython-314.pyc +0 -0
  204. package/skills/skills/skillkit/scripts/utils/__pycache__/reference_validator.cpython-312.pyc +0 -0
  205. package/skills/skills/skillkit/scripts/utils/__pycache__/reference_validator.cpython-314.pyc +0 -0
  206. package/skills/skills/skillkit/scripts/utils/budget_tracker.py +388 -0
  207. package/skills/skills/skillkit/scripts/utils/output_formatter.py +263 -0
  208. package/skills/skills/skillkit/scripts/utils/reference_validator.py +401 -0
  209. package/skills/skills/skillkit/scripts/validate_skill.py +594 -0
  210. package/skills/skills/skillkit/tests/test_behavioral.py +39 -0
  211. package/skills/skills/skillkit/tests/test_scenarios.md +83 -0
  212. package/skills/skills/skillkit/tests/test_skill.py +136 -0
  213. package/skills/skills/skillkit-help/SKILL.md +81 -0
  214. package/skills/skills/skillkit-help/knowledge/application/09-case-studies.md +257 -0
  215. package/skills/skills/skillkit-help/knowledge/application/12-testing-and-validation.md +276 -0
  216. package/skills/skills/skillkit-help/knowledge/foundation/01-why-skills-exist.md +246 -0
  217. package/skills/skills/skillkit-help/knowledge/foundation/02-skills-vs-subagents-comparison.md +312 -0
  218. package/skills/skills/skillkit-help/knowledge/foundation/03-skills-vs-subagents-decision-tree.md +346 -0
  219. package/skills/skills/skillkit-help/knowledge/foundation/06-platform-constraints.md +237 -0
  220. package/skills/skills/skillkit-help/knowledge/foundation/08-when-not-to-use-skills.md +270 -0
  221. package/skills/skills/skillkit-help/template/SKILL.md +52 -0
  222. package/skills/skills/social-media-seo/SKILL.md +278 -0
  223. package/skills/skills/social-media-seo/databases/caption-styles.csv +31 -0
  224. package/skills/skills/social-media-seo/databases/engagement-tactics.csv +16 -0
  225. package/skills/skills/social-media-seo/databases/hashtag-strategies.csv +21 -0
  226. package/skills/skills/social-media-seo/databases/hook-formulas.csv +26 -0
  227. package/skills/skills/social-media-seo/databases/keyword-clusters.csv +11 -0
  228. package/skills/skills/social-media-seo/databases/thread-structures.csv +26 -0
  229. package/skills/skills/social-media-seo/databases/viral-patterns.csv +21 -0
  230. package/skills/skills/social-media-seo/references/analytics-guide.md +321 -0
  231. package/skills/skills/social-media-seo/references/instagram-seo.md +235 -0
  232. package/skills/skills/social-media-seo/references/threads-seo.md +305 -0
  233. package/skills/skills/social-media-seo/references/x-twitter-seo.md +337 -0
  234. package/skills/skills/social-media-seo/scripts/query_database.py +191 -0
  235. package/skills/skills/storyteller/SKILL.md +241 -0
  236. package/skills/skills/storyteller/references/transformation-methodology.md +293 -0
  237. package/skills/skills/storyteller/references/visual-vocabulary.md +177 -0
  238. package/skills/skills/thread-pro/SKILL.md +162 -0
  239. package/skills/skills/thread-pro/anti-ai-patterns.md +120 -0
  240. package/skills/skills/thread-pro/hook-formulas.md +138 -0
  241. package/skills/skills/thread-pro/references/anti-ai-patterns.md +120 -0
  242. package/skills/skills/thread-pro/references/hook-formulas.md +138 -0
  243. package/skills/skills/thread-pro/references/thread-structures.md +240 -0
  244. package/skills/skills/thread-pro/references/voice-injection.md +130 -0
  245. package/skills/skills/thread-pro/thread-structures.md +240 -0
  246. package/skills/skills/thread-pro/voice-injection.md +130 -0
  247. package/skills/skills/tinkering/SKILL.md +251 -0
  248. package/skills/skills/tinkering/references/graduation-checklist.md +100 -0
  249. package/skills/skills/validate-plan/.skillkit-mode +1 -0
  250. package/skills/skills/validate-plan/SKILL.md +406 -0
  251. package/skills/skills/validate-plan/references/dry-principles.md +251 -0
  252. package/skills/skills/validate-plan/references/gap-analysis-guide.md +320 -0
  253. package/skills/skills/validate-plan/references/tdd-patterns.md +413 -0
  254. package/skills/skills/validate-plan/references/yagni-checklist.md +330 -0
  255. package/skills/skills/verify-before-ship/.skillkit-mode +1 -0
  256. package/skills/skills/verify-before-ship/SKILL.md +116 -0
  257. package/skills/skills/verify-before-ship/references/anti-rationalization.md +212 -0
  258. package/skills/skills/verify-before-ship/references/verification-gates.md +305 -0
  259. package/skills-manifest.json +8 -2
  260. package/src/banner.js +1 -1
  261. package/src/cli.js +15 -4
  262. package/src/install.js +45 -29
  263. package/src/install.test.js +75 -7
  264. package/src/picker.js +15 -4
  265. package/src/picker.test.js +36 -1
  266. package/src/scope.js +8 -39
  267. package/src/scope.test.js +9 -13
  268. package/src/tools.js +76 -0
  269. package/src/tools.test.js +80 -0
@@ -0,0 +1,400 @@
1
+ #!/usr/bin/env python3
2
+ """
3
+ Skill Initializer - Creates a new skill from template
4
+
5
+ Usage:
6
+ init_skill.py <skill-name> --path <path>
7
+
8
+ Examples:
9
+ init_skill.py my-new-skill --path skills/public
10
+ init_skill.py my-api-helper --path skills/private
11
+ init_skill.py custom-skill --path /custom/location
12
+ """
13
+
14
+ import argparse
15
+ import sys
16
+ from enum import Enum
17
+ from pathlib import Path
18
+
19
+
20
+ SKILL_TEMPLATE = """---
21
+ name: {skill_name}
22
+ description: [TODO: Complete and informative explanation of what the skill does and when to use it. Include WHEN to use this skill - specific scenarios, file types, or tasks that trigger it.]
23
+ ---
24
+
25
+ # {skill_title}
26
+
27
+ ## Overview
28
+
29
+ [TODO: 1-2 sentences explaining what this skill enables]
30
+
31
+ ## Structuring This Skill
32
+
33
+ [TODO: Choose the structure that best fits this skill's purpose. Common patterns:
34
+
35
+ **1. Workflow-Based** (best for sequential processes)
36
+ - Works well when there are clear step-by-step procedures
37
+ - Example: DOCX skill with "Workflow Decision Tree" → "Reading" → "Creating" → "Editing"
38
+ - Structure: ## Overview → ## Workflow Decision Tree → ## Step 1 → ## Step 2...
39
+
40
+ **2. Task-Based** (best for tool collections)
41
+ - Works well when the skill offers different operations/capabilities
42
+ - Example: PDF skill with "Quick Start" → "Merge PDFs" → "Split PDFs" → "Extract Text"
43
+ - Structure: ## Overview → ## Quick Start → ## Task Category 1 → ## Task Category 2...
44
+
45
+ **3. Reference/Guidelines** (best for standards or specifications)
46
+ - Works well for brand guidelines, coding standards, or requirements
47
+ - Example: Brand styling with "Brand Guidelines" → "Colors" → "Typography" → "Features"
48
+ - Structure: ## Overview → ## Guidelines → ## Specifications → ## Usage...
49
+
50
+ **4. Capabilities-Based** (best for integrated systems)
51
+ - Works well when the skill provides multiple interrelated features
52
+ - Example: Product Management with "Core Capabilities" → numbered capability list
53
+ - Structure: ## Overview → ## Core Capabilities → ### 1. Feature → ### 2. Feature...
54
+
55
+ Patterns can be mixed and matched as needed. Most skills combine patterns (e.g., start with task-based, add workflow for complex operations).
56
+
57
+ Delete this entire "Structuring This Skill" section when done - it's just guidance.]
58
+
59
+ ## [TODO: Replace with the first main section based on chosen structure]
60
+
61
+ [TODO: Add content here. See examples in existing skills:
62
+ - Code samples for technical skills
63
+ - Decision trees for complex workflows
64
+ - Concrete examples with realistic user requests
65
+ - References to scripts/templates/references as needed]
66
+
67
+ ## Resources
68
+
69
+ This skill includes example resource directories that demonstrate how to organize different types of bundled resources:
70
+
71
+ ### scripts/
72
+ Executable code (Python/Bash/etc.) that can be run directly to perform specific operations.
73
+
74
+ **Examples from other skills:**
75
+ - PDF skill: `fill_fillable_fields.py`, `extract_form_field_info.py` - utilities for PDF manipulation
76
+ - DOCX skill: `document.py`, `utilities.py` - Python modules for document processing
77
+
78
+ **Appropriate for:** Python scripts, shell scripts, or any executable code that performs automation, data processing, or specific operations.
79
+
80
+ **Note:** Scripts may be executed without loading into context, but can still be read by Claude for patching or environment adjustments.
81
+
82
+ ### references/
83
+ Documentation and reference material intended to be loaded into context to inform Claude's process and thinking.
84
+
85
+ **Examples from other skills:**
86
+ - Product management: `communication.md`, `context_building.md` - detailed workflow guides
87
+ - BigQuery: API reference documentation and query examples
88
+ - Finance: Schema documentation, company policies
89
+
90
+ **Appropriate for:** In-depth documentation, API references, database schemas, comprehensive guides, or any detailed information that Claude should reference while working.
91
+
92
+ ### assets/
93
+ Files not intended to be loaded into context, but rather used within the output Claude produces.
94
+
95
+ **Examples from other skills:**
96
+ - Brand styling: PowerPoint template files (.pptx), logo files
97
+ - Frontend builder: HTML/React boilerplate project directories
98
+ - Typography: Font files (.ttf, .woff2)
99
+
100
+ **Appropriate for:** Templates, boilerplate code, document templates, images, icons, fonts, or any files meant to be copied or used in the final output.
101
+
102
+ ---
103
+
104
+ **Any unneeded directories can be deleted.** Not every skill requires all three types of resources.
105
+ """
106
+
107
+ EXAMPLE_SCRIPT = '''#!/usr/bin/env python3
108
+ """
109
+ Example helper script for {skill_name}
110
+
111
+ This is a placeholder script that can be executed directly.
112
+ Replace with actual implementation or delete if not needed.
113
+
114
+ Example real scripts from other skills:
115
+ - pdf/scripts/fill_fillable_fields.py - Fills PDF form fields
116
+ - pdf/scripts/convert_pdf_to_images.py - Converts PDF pages to images
117
+ """
118
+
119
+ def main():
120
+ print("This is an example script for {skill_name}")
121
+ # TODO: Add actual script logic here
122
+ # This could be data processing, file conversion, API calls, etc.
123
+
124
+ if __name__ == "__main__":
125
+ main()
126
+ '''
127
+
128
+ EXAMPLE_REFERENCE = """# Reference Documentation for {skill_title}
129
+
130
+ This is a placeholder for detailed reference documentation.
131
+ Replace with actual reference content or delete if not needed.
132
+
133
+ Example real reference docs from other skills:
134
+ - product-management/references/communication.md - Comprehensive guide for status updates
135
+ - product-management/references/context_building.md - Deep-dive on gathering context
136
+ - bigquery/references/ - API references and query examples
137
+
138
+ ## When Reference Docs Are Useful
139
+
140
+ Reference docs are ideal for:
141
+ - Comprehensive API documentation
142
+ - Detailed workflow guides
143
+ - Complex multi-step processes
144
+ - Information too lengthy for main SKILL.md
145
+ - Content that's only needed for specific use cases
146
+
147
+ ## Structure Suggestions
148
+
149
+ ### API Reference Example
150
+ - Overview
151
+ - Authentication
152
+ - Endpoints with examples
153
+ - Error codes
154
+ - Rate limits
155
+
156
+ ### Workflow Guide Example
157
+ - Prerequisites
158
+ - Step-by-step instructions
159
+ - Common patterns
160
+ - Troubleshooting
161
+ - Best practices
162
+ """
163
+
164
+ EXAMPLE_ASSET = """# Example Asset File
165
+
166
+ This placeholder represents where asset files would be stored.
167
+ Replace with actual asset files (templates, images, fonts, etc.) or delete if not needed.
168
+
169
+ Asset files are NOT intended to be loaded into context, but rather used within
170
+ the output Claude produces.
171
+
172
+ Example asset files from other skills:
173
+ - Brand guidelines: logo.png, slides_template.pptx
174
+ - Frontend builder: hello-world/ directory with HTML/React boilerplate
175
+ - Typography: custom-font.ttf, font-family.woff2
176
+ - Data: sample_data.csv, test_dataset.json
177
+
178
+ ## Common Asset Types
179
+
180
+ - Templates: .pptx, .docx, boilerplate directories
181
+ - Images: .png, .jpg, .svg, .gif
182
+ - Fonts: .ttf, .otf, .woff, .woff2
183
+ - Boilerplate code: Project directories, starter files
184
+ - Icons: .ico, .svg
185
+ - Data files: .csv, .json, .xml, .yaml
186
+
187
+ Note: This is a text placeholder. Actual assets can be any file type.
188
+ """
189
+
190
+
191
+ class WorkflowMode(Enum):
192
+ FAST = "fast" # 12-step, structural only
193
+ FULL = "full" # 15-step, structural + behavioral
194
+
195
+
196
+ def title_case_skill_name(skill_name):
197
+ """Convert hyphenated skill name to Title Case for display."""
198
+ return ' '.join(word.capitalize() for word in skill_name.split('-'))
199
+
200
+
201
+ def prompt_for_mode():
202
+ """Ask user for workflow mode during skill creation."""
203
+ print("\n" + "=" * 60)
204
+ print("WORKFLOW MODE SELECTION")
205
+ print("=" * 60)
206
+ print("\nFAST Mode (12 steps)")
207
+ print(" - Structural validation only")
208
+ print(" - Quick iteration")
209
+ print(" - Best for: simple utilities, prototypes")
210
+ print("\nFULL Mode (15 steps)")
211
+ print(" - Structural + behavioral validation")
212
+ print(" - TDD pressure testing")
213
+ print(" - Best for: discipline skills, production quality")
214
+ print("\n" + "-" * 60)
215
+
216
+ while True:
217
+ choice = input("\nSelect mode (1=fast, 2=full) [1]: ").strip() or "1"
218
+ if choice == "1":
219
+ return WorkflowMode.FAST
220
+ if choice == "2":
221
+ return WorkflowMode.FULL
222
+ print("Invalid choice. Enter 1 or 2.")
223
+
224
+
225
+ def get_skill_template(skill_name, mode=WorkflowMode.FAST):
226
+ """Get SKILL.md template based on workflow mode."""
227
+ skill_title = title_case_skill_name(skill_name)
228
+ template = SKILL_TEMPLATE
229
+
230
+ if mode == WorkflowMode.FULL:
231
+ template += """
232
+
233
+ ## Behavioral Validation
234
+
235
+ ### RED Phase - Baseline Failures
236
+ <!-- Document rationalizations found WITHOUT skill -->
237
+
238
+ ### GREEN Phase - Verification
239
+ <!-- Confirm compliance WITH skill -->
240
+
241
+ ### Rationalization Table
242
+ | Excuse | Reality |
243
+ |--------|---------|
244
+ | "Too simple to test" | Simple code breaks |
245
+ | "I'll test after" | Tests-after proves nothing |
246
+
247
+ ## Pressure Test Results
248
+ - [ ] Time pressure: __
249
+ - [ ] Sunk cost pressure: __
250
+ - [ ] Authority pressure: __
251
+ - [ ] Exhaustion pressure: __
252
+ - [ ] Combined pressure: __
253
+
254
+ **Final Behavioral Score:** __/10
255
+ """
256
+
257
+ return template.format(
258
+ skill_name=skill_name,
259
+ skill_title=skill_title
260
+ )
261
+
262
+
263
+ def create_skill_structure(skill_name, path, mode):
264
+ """Create skill directory and mode-specific SKILL.md."""
265
+ skill_dir = Path(path).resolve() / skill_name
266
+
267
+ # Check if directory already exists
268
+ if skill_dir.exists():
269
+ print(f"❌ Error: Skill directory already exists: {skill_dir}")
270
+ return None
271
+
272
+ # Create skill directory
273
+ try:
274
+ skill_dir.mkdir(parents=True, exist_ok=False)
275
+ print(f"✅ Created skill directory: {skill_dir}")
276
+ except Exception as e:
277
+ print(f"❌ Error creating directory: {e}")
278
+ return None
279
+
280
+ # Create mode marker file
281
+ mode_file = skill_dir / '.skillkit-mode'
282
+ mode_file.write_text(mode.value)
283
+ print(f"✅ Created .skillkit-mode ({mode.value})")
284
+
285
+ # Create SKILL.md from template
286
+ skill_content = get_skill_template(skill_name, mode)
287
+ skill_md_path = skill_dir / 'SKILL.md'
288
+ try:
289
+ skill_md_path.write_text(skill_content)
290
+ print("✅ Created SKILL.md")
291
+ except Exception as e:
292
+ print(f"❌ Error creating SKILL.md: {e}")
293
+ return None
294
+
295
+ return skill_dir
296
+
297
+
298
+ def init_skill(skill_name, path, mode=WorkflowMode.FAST):
299
+ """
300
+ Initialize a new skill directory with template SKILL.md.
301
+
302
+ Args:
303
+ skill_name: Name of the skill
304
+ path: Path where the skill directory should be created
305
+
306
+ Returns:
307
+ Path to created skill directory, or None if error
308
+ """
309
+ skill_dir = create_skill_structure(skill_name, path, mode)
310
+ if not skill_dir:
311
+ return None
312
+
313
+ # Create resource directories with example files
314
+ skill_title = title_case_skill_name(skill_name)
315
+ try:
316
+ # Create scripts/ directory with example script
317
+ scripts_dir = skill_dir / 'scripts'
318
+ scripts_dir.mkdir(exist_ok=True)
319
+ example_script = scripts_dir / 'example.py'
320
+ example_script.write_text(EXAMPLE_SCRIPT.format(skill_name=skill_name))
321
+ example_script.chmod(0o755)
322
+ print("✅ Created scripts/example.py")
323
+
324
+ # Create references/ directory with example reference doc
325
+ references_dir = skill_dir / 'references'
326
+ references_dir.mkdir(exist_ok=True)
327
+ example_reference = references_dir / 'api_reference.md'
328
+ example_reference.write_text(EXAMPLE_REFERENCE.format(skill_title=skill_title))
329
+ print("✅ Created references/api_reference.md")
330
+
331
+ # Create assets/ directory with example asset placeholder
332
+ assets_dir = skill_dir / 'assets'
333
+ assets_dir.mkdir(exist_ok=True)
334
+ example_asset = assets_dir / 'example_asset.txt'
335
+ example_asset.write_text(EXAMPLE_ASSET)
336
+ print("✅ Created assets/example_asset.txt")
337
+ except Exception as e:
338
+ print(f"❌ Error creating resource directories: {e}")
339
+ return None
340
+
341
+ # Print next steps
342
+ print(f"\n✅ Skill '{skill_name}' initialized successfully at {skill_dir}")
343
+ print("\nNext steps:")
344
+ print("1. Edit SKILL.md to complete the TODO items and update the description")
345
+ print("2. Customize or delete the example files in scripts/, references/, and assets/")
346
+ print("3. Run the validator when ready to check the skill structure")
347
+
348
+ return skill_dir
349
+
350
+
351
+ def main():
352
+ parser = argparse.ArgumentParser(
353
+ description='Create a new skill from template',
354
+ epilog='''Examples:
355
+ init_skill.py my-new-skill --path skills/public
356
+ init_skill.py my-api-helper --path skills/private
357
+ init_skill.py custom-skill --path /custom/location
358
+
359
+ Skill name requirements:
360
+ - Hyphen-case identifier (e.g., 'data-analyzer')
361
+ - Lowercase letters, digits, and hyphens only
362
+ - Max 40 characters
363
+ - Must match directory name exactly''',
364
+ formatter_class=argparse.RawDescriptionHelpFormatter
365
+ )
366
+ parser.add_argument('skill_name', help='Name of the skill to create')
367
+ parser.add_argument(
368
+ '--path',
369
+ default='.',
370
+ help='Path where the skill directory should be created (default: current directory)'
371
+ )
372
+ parser.add_argument(
373
+ '--mode',
374
+ choices=['fast', 'full'],
375
+ default=None,
376
+ help='Workflow mode: fast (12-step) or full (15-step with TDD). Default: fast'
377
+ )
378
+
379
+ args = parser.parse_args()
380
+ selected_mode = (
381
+ WorkflowMode(args.mode)
382
+ if args.mode
383
+ else (prompt_for_mode() if sys.stdin.isatty() else WorkflowMode.FAST)
384
+ )
385
+
386
+ print(f"🚀 Initializing skill: {args.skill_name}")
387
+ print(f" Location: {args.path}")
388
+ print(f" Mode: {selected_mode.value}")
389
+ print()
390
+
391
+ result = init_skill(args.skill_name, args.path, selected_mode)
392
+
393
+ if result:
394
+ sys.exit(0)
395
+ else:
396
+ sys.exit(1)
397
+
398
+
399
+ if __name__ == "__main__":
400
+ main()
@@ -0,0 +1,231 @@
1
+ #!/usr/bin/env python3
2
+ """
3
+ Subagent Initializer - Creates a new subagent file from template
4
+
5
+ Usage:
6
+ init_subagent.py <subagent-name> --path <path>
7
+
8
+ Examples:
9
+ init_subagent.py code-reviewer --path ~/.claude/agents
10
+ init_subagent.py security-auditor --path ~/.claude/agents
11
+
12
+ Note: Subagents are individual .md files in ~/.claude/agents/
13
+ """
14
+
15
+ import argparse
16
+ import re
17
+ import sys
18
+ from pathlib import Path
19
+
20
+
21
+ SUBAGENT_TEMPLATE = """---
22
+ name: {subagent_name}
23
+ description: "[TODO: Clear description of what this subagent does and when to use it. Include specific scenarios that trigger delegation. See code-simplifier.md for example format with <example> tags.]"
24
+ subagent_type: [TODO: Choose one]
25
+ # Options: general-purpose, code-reviewer, typescript-pro, flutter-expert,
26
+ # red-team, qa-expert, seo-manager, creative-copywriter,
27
+ # decision-maker, research, custom
28
+
29
+ tools:
30
+ - Read # Always recommended
31
+ - Write # Enable if subagent needs to create files
32
+ - Edit # Enable if subagent needs to modify files
33
+ - Bash # Enable if subagent needs command execution
34
+ - Glob # Enable for file pattern matching
35
+ - Grep # Enable for content search
36
+ - Skill # Enable to invoke other skills
37
+ # - Task # Enable if spawning nested subagents
38
+
39
+ # Optional: Skills this subagent can invoke
40
+ # skills:
41
+ # - skill-name # Description of when to use this skill
42
+
43
+ # Optional: Model preference (defaults to parent's model)
44
+ # model: sonnet # Options: sonnet, opus, haiku
45
+ ---
46
+
47
+ You are a specialist in [TODO: domain expertise]. Your purpose is to [TODO: main purpose].
48
+
49
+ ## Your Capabilities
50
+
51
+ **Core Expertise:**
52
+ - [TODO: Capability 1]
53
+ - [TODO: Capability 2]
54
+ - [TODO: Capability 3]
55
+
56
+ **When to Invoke You:**
57
+ - [TODO: Trigger condition 1]
58
+ - [TODO: Trigger condition 2]
59
+ - [TODO: Trigger condition 3]
60
+
61
+ ## Your Approach
62
+
63
+ 1. **Analysis Phase:**
64
+ - [TODO: Step 1]
65
+ - [TODO: Step 2]
66
+
67
+ 2. **Implementation Phase:**
68
+ - [TODO: Step 3]
69
+ - [TODO: Step 4]
70
+
71
+ 3. **Review Phase:**
72
+ - [TODO: Step 5]
73
+ - [TODO: Step 6]
74
+
75
+ ## Guidelines
76
+
77
+ - [TODO: Guideline 1]
78
+ - [TODO: Guideline 2]
79
+ - [TODO: Guideline 3]
80
+
81
+ ## Output Format
82
+
83
+ Always structure your response as:
84
+
85
+ ```
86
+ ## Summary
87
+ [Brief overview of what was done]
88
+
89
+ ## Details
90
+ [Detailed explanation/implementation]
91
+
92
+ ## Recommendations
93
+ [Actionable next steps or improvements]
94
+ ```
95
+
96
+ ---
97
+
98
+ **IMPORTANT:** This is a template with [TODO] placeholders. Before using this subagent, you MUST:
99
+ 1. Research actual best practices for this domain (don't use generic personas)
100
+ 2. Replace all [TODO] sections with specific, research-based content
101
+ 3. Add concrete examples with <example> tags in description
102
+ 4. Test the subagent with sample tasks
103
+ """
104
+
105
+
106
+ def validate_subagent_name(name: str) -> tuple[bool, str]:
107
+ """Validate subagent name format.
108
+
109
+ Returns:
110
+ Tuple of (is_valid, error_message)
111
+ """
112
+ if len(name) > 40:
113
+ return False, "Name must be 40 characters or less"
114
+
115
+ if not re.match(r'^[a-z0-9-]+$', name):
116
+ return False, "Name must contain only lowercase letters, digits, and hyphens"
117
+
118
+ if name.startswith('-') or name.endswith('-'):
119
+ return False, "Name cannot start or end with a hyphen"
120
+
121
+ if '--' in name:
122
+ return False, "Name cannot contain consecutive hyphens"
123
+
124
+ return True, ""
125
+
126
+
127
+ def init_subagent(subagent_name: str, path: str) -> Path | None:
128
+ """Initialize a new subagent file with template content.
129
+
130
+ Args:
131
+ subagent_name: Name of the subagent (hyphen-case)
132
+ path: Directory path where the subagent file should be created
133
+
134
+ Returns:
135
+ Path to created subagent file, or None if error occurred
136
+ """
137
+ # Validate inputs
138
+ is_valid, error_msg = validate_subagent_name(subagent_name)
139
+ if not is_valid:
140
+ print(f"❌ Error: Invalid subagent name '{subagent_name}': {error_msg}")
141
+ return None
142
+
143
+ target_dir = Path(path).expanduser().resolve()
144
+ subagent_file = target_dir / f"{subagent_name}.md"
145
+
146
+ # Check if file already exists
147
+ if subagent_file.exists():
148
+ print(f"❌ Error: Subagent file already exists: {subagent_file}")
149
+ return None
150
+
151
+ # Ensure target is a directory
152
+ if target_dir.exists() and not target_dir.is_dir():
153
+ print(f"❌ Error: Target path exists but is not a directory: {target_dir}")
154
+ return None
155
+
156
+ # Create parent directory
157
+ try:
158
+ target_dir.mkdir(parents=True, exist_ok=True)
159
+ except PermissionError:
160
+ print(f"❌ Error: Permission denied creating directory: {target_dir}")
161
+ return None
162
+ except OSError as e:
163
+ print(f"❌ Error creating directory: {e}")
164
+ return None
165
+
166
+ # Create subagent file
167
+ try:
168
+ subagent_file.write_text(SUBAGENT_TEMPLATE.format(subagent_name=subagent_name))
169
+ print(f"✅ Created subagent file: {subagent_file}")
170
+ except PermissionError:
171
+ print(f"❌ Error: Permission denied writing file: {subagent_file}")
172
+ return None
173
+ except OSError as e:
174
+ print(f"❌ Error creating subagent file: {e}")
175
+ return None
176
+
177
+ return subagent_file
178
+
179
+
180
+ def print_next_steps(subagent_name: str, subagent_file: Path) -> None:
181
+ """Print follow-up instructions after successful creation."""
182
+ print(f"\n✅ Subagent '{subagent_name}' initialized successfully")
183
+ print("\n⚠️ IMPORTANT: This is a template with [TODO] placeholders.")
184
+ print(" Before using this subagent, you MUST:")
185
+ print(" 1. Research actual best practices for this domain (don't use generic personas)")
186
+ print(" 2. Replace all [TODO] sections with specific, research-based content")
187
+ print(" 3. Add concrete examples with <example> tags in description")
188
+ print(" 4. Test the subagent with sample tasks")
189
+ print(f"\n Edit the file: {subagent_file}")
190
+
191
+
192
+ def main() -> int:
193
+ """Main entry point."""
194
+ parser = argparse.ArgumentParser(
195
+ description='Create a new subagent file from template',
196
+ formatter_class=argparse.RawDescriptionHelpFormatter,
197
+ epilog="""
198
+ Examples:
199
+ init_subagent.py code-reviewer --path ~/.claude/agents
200
+ init_subagent.py security-auditor --path ~/.claude/agents
201
+ init_subagent.py data-analyzer --path ~/.claude/agents
202
+
203
+ Subagent name requirements:
204
+ - Hyphen-case identifier (e.g., 'code-reviewer')
205
+ - Lowercase letters, digits, and hyphens only
206
+ - Max 40 characters
207
+ - Will create: <name>.md file
208
+
209
+ Note: Subagents are stored as individual .md files in ~/.claude/agents/
210
+ """
211
+ )
212
+ parser.add_argument('subagent_name', help='Name of the subagent to create')
213
+ parser.add_argument('--path', required=True,
214
+ help='Directory path where the subagent file should be created')
215
+
216
+ args = parser.parse_args()
217
+
218
+ print(f"🚀 Initializing subagent: {args.subagent_name}")
219
+ print(f" Location: {args.path}\n")
220
+
221
+ result = init_subagent(args.subagent_name, args.path)
222
+
223
+ if result:
224
+ print_next_steps(args.subagent_name, result)
225
+ return 0
226
+ else:
227
+ return 1
228
+
229
+
230
+ if __name__ == "__main__":
231
+ sys.exit(main())