hive-skills 0.1.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.
- package/LICENSE +28 -0
- package/README.md +235 -0
- package/assets/LICENSE +32 -0
- package/assets/THIRD_PARTY_NOTICES.md +72 -0
- package/assets/manifest.json +1290 -0
- package/assets/skills/authored/code-review/composable/BUNDLE.md +192 -0
- package/assets/skills/authored/code-review/composable/INDEX.md +13 -0
- package/assets/skills/authored/code-review/composable/VERSION +1 -0
- package/assets/skills/authored/code-review/composable/mini/01-review-method.md +34 -0
- package/assets/skills/authored/code-review/composable/mini/02-security-review.md +20 -0
- package/assets/skills/authored/code-review/composable/mini/03-correctness-bugs.md +19 -0
- package/assets/skills/authored/code-review/composable/mini/04-concurrency.md +16 -0
- package/assets/skills/authored/code-review/composable/mini/05-error-handling.md +12 -0
- package/assets/skills/authored/code-review/composable/mini/06-performance.md +11 -0
- package/assets/skills/authored/code-review/composable/mini/07-api-design.md +20 -0
- package/assets/skills/authored/code-review/composable/mini/08-missing-tests.md +25 -0
- package/assets/skills/authored/code-review/composable/mini/09-refactoring-and-communication.md +32 -0
- package/assets/skills/authored/data-analysis/composable/BUNDLE.md +186 -0
- package/assets/skills/authored/data-analysis/composable/INDEX.md +13 -0
- package/assets/skills/authored/data-analysis/composable/VERSION +1 -0
- package/assets/skills/authored/data-analysis/composable/mini/01-data-quality-profiling.md +26 -0
- package/assets/skills/authored/data-analysis/composable/mini/02-aggregation-pitfalls.md +21 -0
- package/assets/skills/authored/data-analysis/composable/mini/03-time-series.md +19 -0
- package/assets/skills/authored/data-analysis/composable/mini/04-segmentation.md +23 -0
- package/assets/skills/authored/data-analysis/composable/mini/05-discount-pricing.md +17 -0
- package/assets/skills/authored/data-analysis/composable/mini/06-insight-generation.md +25 -0
- package/assets/skills/authored/data-analysis/composable/mini/07-executive-writing.md +26 -0
- package/assets/skills/authored/data-analysis/composable/mini/08-recommendations.md +20 -0
- package/assets/skills/authored/data-analysis/composable/mini/09-reproducibility-assumptions.md +20 -0
- package/assets/skills/authored/financial-analysis/composable/BUNDLE.md +1293 -0
- package/assets/skills/authored/financial-analysis/composable/INDEX.md +17 -0
- package/assets/skills/authored/financial-analysis/composable/VERSION +1 -0
- package/assets/skills/authored/financial-analysis/composable/mini/00-core.md +69 -0
- package/assets/skills/authored/financial-analysis/composable/mini/01-profitability-efficiency-ratios.md +173 -0
- package/assets/skills/authored/financial-analysis/composable/mini/02-liquidity-leverage-ratios.md +120 -0
- package/assets/skills/authored/financial-analysis/composable/mini/03-valuation-ratios-interpretation.md +107 -0
- package/assets/skills/authored/financial-analysis/composable/mini/04-dcf-projection-wacc.md +122 -0
- package/assets/skills/authored/financial-analysis/composable/mini/05-dcf-terminal-value-sensitivity.md +75 -0
- package/assets/skills/authored/financial-analysis/composable/mini/06-comparables-precedents.md +78 -0
- package/assets/skills/authored/financial-analysis/composable/mini/07-budget-variance-analysis.md +47 -0
- package/assets/skills/authored/financial-analysis/composable/mini/08-driver-based-forecasting-scenarios.md +111 -0
- package/assets/skills/authored/financial-analysis/composable/mini/09-rolling-forecasts-accuracy.md +114 -0
- package/assets/skills/authored/financial-analysis/composable/mini/10-reporting-exec-summary.md +58 -0
- package/assets/skills/authored/financial-analysis/composable/mini/11-industry-adaptations.md +130 -0
- package/assets/skills/authored/financial-analysis/composable/mini/12-toolkit-scripts-io.md +102 -0
- package/assets/skills/authored/python-api/composable/BUNDLE.md +389 -0
- package/assets/skills/authored/python-api/composable/INDEX.md +13 -0
- package/assets/skills/authored/python-api/composable/VERSION +1 -0
- package/assets/skills/authored/python-api/composable/mini/01-project-structure.md +44 -0
- package/assets/skills/authored/python-api/composable/mini/02-routing-and-app.md +38 -0
- package/assets/skills/authored/python-api/composable/mini/03-pydantic-models.md +45 -0
- package/assets/skills/authored/python-api/composable/mini/04-validation-and-errors.md +59 -0
- package/assets/skills/authored/python-api/composable/mini/05-dependencies-and-auth.md +60 -0
- package/assets/skills/authored/python-api/composable/mini/06-pagination-filtering.md +44 -0
- package/assets/skills/authored/python-api/composable/mini/07-async-performance.md +30 -0
- package/assets/skills/authored/python-api/composable/mini/08-testing.md +45 -0
- package/assets/skills/authored/python-api/composable/mini/09-middleware-observability.md +29 -0
- package/assets/skills/authored/tech-writing/composable/BUNDLE.md +220 -0
- package/assets/skills/authored/tech-writing/composable/INDEX.md +12 -0
- package/assets/skills/authored/tech-writing/composable/VERSION +1 -0
- package/assets/skills/authored/tech-writing/composable/mini/01-audience-analysis.md +26 -0
- package/assets/skills/authored/tech-writing/composable/mini/02-document-types.md +27 -0
- package/assets/skills/authored/tech-writing/composable/mini/03-readme-quickstart-changelog.md +22 -0
- package/assets/skills/authored/tech-writing/composable/mini/04-information-architecture.md +21 -0
- package/assets/skills/authored/tech-writing/composable/mini/05-style-clarity.md +29 -0
- package/assets/skills/authored/tech-writing/composable/mini/06-breaking-changes-migrations.md +33 -0
- package/assets/skills/authored/tech-writing/composable/mini/07-troubleshooting-security.md +30 -0
- package/assets/skills/authored/tech-writing/composable/mini/08-faq-voice-tone.md +32 -0
- package/assets/skills/converted/claude-api/composable/BUNDLE.md +14996 -0
- package/assets/skills/converted/claude-api/composable/INDEX.md +98 -0
- package/assets/skills/converted/claude-api/composable/VERSION +1 -0
- package/assets/skills/converted/claude-api/composable/mini/00-core.md +235 -0
- package/assets/skills/converted/claude-api/composable/mini/01-model-api-quick-reference.md +258 -0
- package/assets/skills/converted/claude-api/composable/mini/02-common-pitfalls.md +42 -0
- package/assets/skills/converted/claude-api/composable/mini/10-models.md +135 -0
- package/assets/skills/converted/claude-api/composable/mini/11-platform-availability.md +96 -0
- package/assets/skills/converted/claude-api/composable/mini/12-claude-platform-on-aws.md +59 -0
- package/assets/skills/converted/claude-api/composable/mini/13-live-sources.md +143 -0
- package/assets/skills/converted/claude-api/composable/mini/14-error-codes.md +256 -0
- package/assets/skills/converted/claude-api/composable/mini/15-prompt-caching.md +223 -0
- package/assets/skills/converted/claude-api/composable/mini/16-token-counting.md +56 -0
- package/assets/skills/converted/claude-api/composable/mini/17-tool-use-concepts.md +444 -0
- package/assets/skills/converted/claude-api/composable/mini/18-agent-design.md +101 -0
- package/assets/skills/converted/claude-api/composable/mini/19-anthropic-cli.md +246 -0
- package/assets/skills/converted/claude-api/composable/mini/20-model-migration.md +1301 -0
- package/assets/skills/converted/claude-api/composable/mini/30-managed-agents-overview.md +71 -0
- package/assets/skills/converted/claude-api/composable/mini/31-managed-agents-core.md +278 -0
- package/assets/skills/converted/claude-api/composable/mini/32-managed-agents-environments.md +219 -0
- package/assets/skills/converted/claude-api/composable/mini/33-managed-agents-tools.md +366 -0
- package/assets/skills/converted/claude-api/composable/mini/34-managed-agents-events.md +252 -0
- package/assets/skills/converted/claude-api/composable/mini/35-managed-agents-outcomes.md +106 -0
- package/assets/skills/converted/claude-api/composable/mini/36-managed-agents-multiagent.md +101 -0
- package/assets/skills/converted/claude-api/composable/mini/37-managed-agents-webhooks.md +123 -0
- package/assets/skills/converted/claude-api/composable/mini/38-managed-agents-memory.md +197 -0
- package/assets/skills/converted/claude-api/composable/mini/39-managed-agents-scheduled-deployments.md +146 -0
- package/assets/skills/converted/claude-api/composable/mini/40-managed-agents-client-patterns.md +211 -0
- package/assets/skills/converted/claude-api/composable/mini/41-managed-agents-onboarding.md +82 -0
- package/assets/skills/converted/claude-api/composable/mini/42-managed-agents-api-reference.md +441 -0
- package/assets/skills/converted/claude-api/composable/mini/43-managed-agents-self-hosted-sandboxes.md +174 -0
- package/assets/skills/converted/claude-api/composable/mini/50-python-readme.md +564 -0
- package/assets/skills/converted/claude-api/composable/mini/51-python-tool-use.md +590 -0
- package/assets/skills/converted/claude-api/composable/mini/52-python-streaming-batches-files.md +549 -0
- package/assets/skills/converted/claude-api/composable/mini/53-python-managed-agents.md +335 -0
- package/assets/skills/converted/claude-api/composable/mini/55-typescript-readme.md +404 -0
- package/assets/skills/converted/claude-api/composable/mini/56-typescript-tool-use.md +548 -0
- package/assets/skills/converted/claude-api/composable/mini/57-typescript-streaming-batches-files.md +384 -0
- package/assets/skills/converted/claude-api/composable/mini/58-typescript-managed-agents.md +358 -0
- package/assets/skills/converted/claude-api/composable/mini/60-csharp-readme.md +361 -0
- package/assets/skills/converted/claude-api/composable/mini/61-csharp-tool-use.md +163 -0
- package/assets/skills/converted/claude-api/composable/mini/62-csharp-streaming-batches-files.md +64 -0
- package/assets/skills/converted/claude-api/composable/mini/65-go-readme.md +185 -0
- package/assets/skills/converted/claude-api/composable/mini/66-go-tool-use.md +219 -0
- package/assets/skills/converted/claude-api/composable/mini/67-go-streaming-files.md +63 -0
- package/assets/skills/converted/claude-api/composable/mini/68-go-managed-agents.md +564 -0
- package/assets/skills/converted/claude-api/composable/mini/70-java-readme.md +237 -0
- package/assets/skills/converted/claude-api/composable/mini/71-java-tool-use.md +227 -0
- package/assets/skills/converted/claude-api/composable/mini/72-java-streaming-files.md +49 -0
- package/assets/skills/converted/claude-api/composable/mini/73-java-managed-agents.md +443 -0
- package/assets/skills/converted/claude-api/composable/mini/75-php-readme.md +173 -0
- package/assets/skills/converted/claude-api/composable/mini/76-php-tool-use.md +252 -0
- package/assets/skills/converted/claude-api/composable/mini/77-php-streaming-batches-files.md +53 -0
- package/assets/skills/converted/claude-api/composable/mini/78-php-managed-agents.md +443 -0
- package/assets/skills/converted/claude-api/composable/mini/80-ruby-readme.md +133 -0
- package/assets/skills/converted/claude-api/composable/mini/81-ruby-tool-use-streaming.md +56 -0
- package/assets/skills/converted/claude-api/composable/mini/82-ruby-managed-agents.md +394 -0
- package/assets/skills/converted/claude-api/composable/mini/85-curl-examples.md +255 -0
- package/assets/skills/converted/claude-api/composable/mini/86-curl-managed-agents.md +340 -0
- package/assets/skills/converted/claude-api/composable/presets/csharp.md +1151 -0
- package/assets/skills/converted/claude-api/composable/presets/curl.md +1154 -0
- package/assets/skills/converted/claude-api/composable/presets/go.md +1598 -0
- package/assets/skills/converted/claude-api/composable/presets/java.md +1523 -0
- package/assets/skills/converted/claude-api/composable/presets/php.md +1488 -0
- package/assets/skills/converted/claude-api/composable/presets/python.md +2605 -0
- package/assets/skills/converted/claude-api/composable/presets/ruby.md +1146 -0
- package/assets/skills/converted/claude-api/composable/presets/shared.md +6478 -0
- package/assets/skills/converted/claude-api/composable/presets/typescript.md +2261 -0
- package/assets/skills/converted/docx/composable/BUNDLE.md +617 -0
- package/assets/skills/converted/docx/composable/INDEX.md +12 -0
- package/assets/skills/converted/docx/composable/VERSION +1 -0
- package/assets/skills/converted/docx/composable/mini/00-core.md +26 -0
- package/assets/skills/converted/docx/composable/mini/01-reading-converting.md +36 -0
- package/assets/skills/converted/docx/composable/mini/02-creating-setup-layout.md +85 -0
- package/assets/skills/converted/docx/composable/mini/03-creating-elements.md +257 -0
- package/assets/skills/converted/docx/composable/mini/04-editing-existing.md +57 -0
- package/assets/skills/converted/docx/composable/mini/05-xml-reference.md +128 -0
- package/assets/skills/converted/internal-comms/composable/BUNDLE.md +220 -0
- package/assets/skills/converted/internal-comms/composable/INDEX.md +11 -0
- package/assets/skills/converted/internal-comms/composable/VERSION +1 -0
- package/assets/skills/converted/internal-comms/composable/mini/00-core.md +30 -0
- package/assets/skills/converted/internal-comms/composable/mini/01-3p-updates.md +49 -0
- package/assets/skills/converted/internal-comms/composable/mini/02-company-newsletter.md +67 -0
- package/assets/skills/converted/internal-comms/composable/mini/03-faq-answers.md +32 -0
- package/assets/skills/converted/internal-comms/composable/mini/04-general-comms.md +18 -0
- package/assets/skills/converted/mcp-builder/composable/BUNDLE.md +2460 -0
- package/assets/skills/converted/mcp-builder/composable/INDEX.md +23 -0
- package/assets/skills/converted/mcp-builder/composable/VERSION +1 -0
- package/assets/skills/converted/mcp-builder/composable/mini/00-core.md +43 -0
- package/assets/skills/converted/mcp-builder/composable/mini/01-workflow-research-planning.md +54 -0
- package/assets/skills/converted/mcp-builder/composable/mini/02-implementation-process.md +78 -0
- package/assets/skills/converted/mcp-builder/composable/mini/03-naming-conventions.md +33 -0
- package/assets/skills/converted/mcp-builder/composable/mini/04-response-formats.md +21 -0
- package/assets/skills/converted/mcp-builder/composable/mini/05-pagination.md +24 -0
- package/assets/skills/converted/mcp-builder/composable/mini/06-transport.md +47 -0
- package/assets/skills/converted/mcp-builder/composable/mini/07-annotations.md +20 -0
- package/assets/skills/converted/mcp-builder/composable/mini/08-security.md +35 -0
- package/assets/skills/converted/mcp-builder/composable/mini/09-error-handling.md +32 -0
- package/assets/skills/converted/mcp-builder/composable/mini/10-testing-and-documentation.md +21 -0
- package/assets/skills/converted/mcp-builder/composable/mini/11-python-implementation.md +432 -0
- package/assets/skills/converted/mcp-builder/composable/mini/12-python-advanced-and-checklist.md +233 -0
- package/assets/skills/converted/mcp-builder/composable/mini/13-node-implementation.md +717 -0
- package/assets/skills/converted/mcp-builder/composable/mini/14-node-advanced-and-checklist.md +200 -0
- package/assets/skills/converted/mcp-builder/composable/mini/15-evaluation-design.md +200 -0
- package/assets/skills/converted/mcp-builder/composable/mini/16-evaluation-running.md +198 -0
- package/assets/skills/converted/mcp-builder/composable/presets/node-server.md +1381 -0
- package/assets/skills/converted/mcp-builder/composable/presets/python-server.md +1129 -0
- package/assets/skills/converted/pdf/composable/BUNDLE.md +1284 -0
- package/assets/skills/converted/pdf/composable/INDEX.md +14 -0
- package/assets/skills/converted/pdf/composable/VERSION +1 -0
- package/assets/skills/converted/pdf/composable/mini/00-core.md +46 -0
- package/assets/skills/converted/pdf/composable/mini/01-creation.md +176 -0
- package/assets/skills/converted/pdf/composable/mini/02-extraction.md +178 -0
- package/assets/skills/converted/pdf/composable/mini/03-merge-split-manipulate.md +240 -0
- package/assets/skills/converted/pdf/composable/mini/04-images-ocr.md +168 -0
- package/assets/skills/converted/pdf/composable/mini/05-encryption.md +51 -0
- package/assets/skills/converted/pdf/composable/mini/06-forms.md +300 -0
- package/assets/skills/converted/pdf/composable/mini/07-libraries-reference.md +89 -0
- package/assets/skills/converted/pptx/composable/BUNDLE.md +911 -0
- package/assets/skills/converted/pptx/composable/INDEX.md +12 -0
- package/assets/skills/converted/pptx/composable/VERSION +1 -0
- package/assets/skills/converted/pptx/composable/mini/00-core.md +37 -0
- package/assets/skills/converted/pptx/composable/mini/01-reading.md +37 -0
- package/assets/skills/converted/pptx/composable/mini/02-creating-from-scratch.md +422 -0
- package/assets/skills/converted/pptx/composable/mini/03-editing-templates.md +207 -0
- package/assets/skills/converted/pptx/composable/mini/04-design.md +89 -0
- package/assets/skills/converted/pptx/composable/mini/05-qa-and-rendering.md +91 -0
- package/assets/skills/converted/pptx/composable/presets/creating.md +659 -0
- package/assets/skills/converted/pptx/composable/presets/editing.md +485 -0
- package/assets/skills/converted/skill-creator/composable/BUNDLE.md +1681 -0
- package/assets/skills/converted/skill-creator/composable/INDEX.md +21 -0
- package/assets/skills/converted/skill-creator/composable/VERSION +1 -0
- package/assets/skills/converted/skill-creator/composable/mini/00-core.md +59 -0
- package/assets/skills/converted/skill-creator/composable/mini/01-creating-a-skill.md +27 -0
- package/assets/skills/converted/skill-creator/composable/mini/02-skill-writing-guide.md +71 -0
- package/assets/skills/converted/skill-creator/composable/mini/03-test-cases.md +21 -0
- package/assets/skills/converted/skill-creator/composable/mini/04-running-and-evaluating.md +128 -0
- package/assets/skills/converted/skill-creator/composable/mini/05-improving-the-skill.md +30 -0
- package/assets/skills/converted/skill-creator/composable/mini/06-blind-comparison.md +5 -0
- package/assets/skills/converted/skill-creator/composable/mini/07-description-optimization.md +74 -0
- package/assets/skills/converted/skill-creator/composable/mini/08-packaging.md +11 -0
- package/assets/skills/converted/skill-creator/composable/mini/09-environment-specific.md +38 -0
- package/assets/skills/converted/skill-creator/composable/mini/10-scripts-and-references.md +34 -0
- package/assets/skills/converted/skill-creator/composable/mini/11-json-schemas.md +414 -0
- package/assets/skills/converted/skill-creator/composable/mini/12-agent-grader.md +225 -0
- package/assets/skills/converted/skill-creator/composable/mini/13-agent-comparator.md +204 -0
- package/assets/skills/converted/skill-creator/composable/mini/14-agent-analyzer.md +276 -0
- package/assets/skills/converted/skill-creator/composable/presets/authoring.md +198 -0
- package/assets/skills/converted/skill-creator/composable/presets/evaluating.md +1334 -0
- package/assets/skills/converted/skill-creator/composable/presets/optimizing.md +160 -0
- package/assets/skills/converted/skill-creator/composable/presets.json +5 -0
- package/assets/skills/meta/ccs-skill-creator/composable/BUNDLE.md +465 -0
- package/assets/skills/meta/ccs-skill-creator/composable/INDEX.md +8 -0
- package/assets/skills/meta/ccs-skill-creator/composable/VERSION +1 -0
- package/assets/skills/meta/ccs-skill-creator/composable/mini/00-core.md +46 -0
- package/assets/skills/meta/ccs-skill-creator/composable/mini/01-create-new-skill.md +167 -0
- package/assets/skills/meta/ccs-skill-creator/composable/mini/02-convert-existing-skill.md +120 -0
- package/assets/skills/meta/ccs-skill-creator/composable/mini/03-review-and-maintain.md +112 -0
- package/assets/skills/sources/anthropic/PROVENANCE.md +3 -0
- package/assets/skills/sources/anthropic/claude-api/LICENSE.txt +202 -0
- package/assets/skills/sources/anthropic/docx/LICENSE.txt +30 -0
- package/assets/skills/sources/anthropic/internal-comms/LICENSE.txt +202 -0
- package/assets/skills/sources/anthropic/mcp-builder/LICENSE.txt +202 -0
- package/assets/skills/sources/anthropic/pdf/LICENSE.txt +30 -0
- package/assets/skills/sources/anthropic/pptx/LICENSE.txt +30 -0
- package/assets/skills/sources/anthropic/skill-creator/LICENSE.txt +202 -0
- package/assets/skills/sources/financial-analyst/PROVENANCE.md +1 -0
- package/assets/tools/hive.py +728 -0
- package/dist/cli.js +7494 -0
- package/package.json +40 -0
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
<!-- GENERATED by tools/hive.py compile. Do not hand-edit. -->
|
|
2
|
+
# skill-creator: Compiled Skill Bundle (preset: optimizing) (v1.0.0)
|
|
3
|
+
|
|
4
|
+
All composable mini-skills for `skill-creator` concatenated in index order, frontmatter stripped. Regenerate with `tools/hive.py compile <skill-dir>`. Do not edit by hand.
|
|
5
|
+
|
|
6
|
+
---
|
|
7
|
+
<!-- module: 00-core.md -->
|
|
8
|
+
|
|
9
|
+
# Core: Skill Creator — the loop and mindset
|
|
10
|
+
|
|
11
|
+
Cross-cutting foundation for creating new skills, modifying and improving existing skills, and measuring skill performance. Load the focused minis (see INDEX) for each stage: creating, writing, test cases, running evals, improving, blind comparison, description optimization, packaging, environment-specific mechanics, the vendored scripts, JSON schemas, and the subagent instruction files.
|
|
12
|
+
|
|
13
|
+
The original skill's frontmatter description (the primary triggering mechanism): "Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an existing skill, run evals to test a skill, benchmark skill performance with variance analysis, or optimize a skill's description for better triggering accuracy."
|
|
14
|
+
|
|
15
|
+
## Skill Creator
|
|
16
|
+
|
|
17
|
+
A skill for creating new skills and iteratively improving them.
|
|
18
|
+
|
|
19
|
+
At a high level, the process of creating a skill goes like this:
|
|
20
|
+
|
|
21
|
+
- Decide what you want the skill to do and roughly how it should do it
|
|
22
|
+
- Write a draft of the skill
|
|
23
|
+
- Create a few test prompts and run claude-with-access-to-the-skill on them
|
|
24
|
+
- Help the user evaluate the results both qualitatively and quantitatively
|
|
25
|
+
- While the runs happen in the background, draft some quantitative evals if there aren't any (if there are some, you can either use as is or modify if you feel something needs to change about them). Then explain them to the user (or if they already existed, explain the ones that already exist)
|
|
26
|
+
- Use the `eval-viewer/generate_review.py` script to show the user the results for them to look at, and also let them look at the quantitative metrics
|
|
27
|
+
- Rewrite the skill based on feedback from the user's evaluation of the results (and also if there are any glaring flaws that become apparent from the quantitative benchmarks)
|
|
28
|
+
- Repeat until you're satisfied
|
|
29
|
+
- Expand the test set and try again at larger scale
|
|
30
|
+
|
|
31
|
+
Your job when using this skill is to figure out where the user is in this process and then jump in and help them progress through these stages. So for instance, maybe they're like "I want to make a skill for X". You can help narrow down what they mean, write a draft, write the test cases, figure out how they want to evaluate, run all the prompts, and repeat.
|
|
32
|
+
|
|
33
|
+
On the other hand, maybe they already have a draft of the skill. In this case you can go straight to the eval/iterate part of the loop.
|
|
34
|
+
|
|
35
|
+
Of course, you should always be flexible and if the user is like "I don't need to run a bunch of evaluations, just vibe with me", you can do that instead.
|
|
36
|
+
|
|
37
|
+
Then after the skill is done (but again, the order is flexible), you can also run the skill description improver, which we have a whole separate script for, to optimize the triggering of the skill.
|
|
38
|
+
|
|
39
|
+
Cool? Cool.
|
|
40
|
+
|
|
41
|
+
## Communicating with the user
|
|
42
|
+
|
|
43
|
+
The skill creator is liable to be used by people across a wide range of familiarity with coding jargon. If you haven't heard (and how could you, it's only very recently that it started), there's a trend now where the power of Claude is inspiring plumbers to open up their terminals, parents and grandparents to google "how to install npm". On the other hand, the bulk of users are probably fairly computer-literate.
|
|
44
|
+
|
|
45
|
+
So please pay attention to context cues to understand how to phrase your communication! In the default case, just to give you some idea:
|
|
46
|
+
|
|
47
|
+
- "evaluation" and "benchmark" are borderline, but OK
|
|
48
|
+
- for "JSON" and "assertion" you want to see serious cues from the user that they know what those things are before using them without explaining them
|
|
49
|
+
|
|
50
|
+
It's OK to briefly explain terms if you're in doubt, and feel free to clarify terms with a short definition if you're unsure if the user will get it.
|
|
51
|
+
|
|
52
|
+
## The core loop (for emphasis)
|
|
53
|
+
|
|
54
|
+
Repeating the core loop here for emphasis:
|
|
55
|
+
|
|
56
|
+
- Figure out what the skill is about
|
|
57
|
+
- Draft or edit the skill
|
|
58
|
+
- Run claude-with-access-to-the-skill on test prompts
|
|
59
|
+
- With the user, evaluate the outputs:
|
|
60
|
+
- Create benchmark.json and run `eval-viewer/generate_review.py` to help the user review them
|
|
61
|
+
- Run quantitative evals
|
|
62
|
+
- Repeat until you and the user are satisfied
|
|
63
|
+
- Package the final skill and return it to the user.
|
|
64
|
+
|
|
65
|
+
Please add steps to your TodoList, if you have such a thing, to make sure you don't forget. If you're in Cowork, please specifically put "Create evals JSON and run `eval-viewer/generate_review.py` so human can review test cases" in your TodoList to make sure it happens.
|
|
66
|
+
|
|
67
|
+
Good luck!
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
<!-- module: 07-description-optimization.md -->
|
|
71
|
+
|
|
72
|
+
# Description Optimization
|
|
73
|
+
|
|
74
|
+
The description field in SKILL.md frontmatter is the primary mechanism that determines whether Claude invokes a skill. After creating or improving a skill, offer to optimize the description for better triggering accuracy.
|
|
75
|
+
|
|
76
|
+
> Note on script paths: the `scripts.run_loop` / `scripts.run_eval` module paths and `assets/eval_review.html` below refer to the vendored source at `skills/sources/anthropic/skill-creator/`. Run them from that directory. See the `scripts-and-references` mini for the full inventory.
|
|
77
|
+
|
|
78
|
+
## Step 1: Generate trigger eval queries
|
|
79
|
+
|
|
80
|
+
Create 20 eval queries — a mix of should-trigger and should-not-trigger. Save as JSON:
|
|
81
|
+
|
|
82
|
+
```json
|
|
83
|
+
[
|
|
84
|
+
{"query": "the user prompt", "should_trigger": true},
|
|
85
|
+
{"query": "another prompt", "should_trigger": false}
|
|
86
|
+
]
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
The queries must be realistic and something a Claude Code or Claude.ai user would actually type. Not abstract requests, but requests that are concrete and specific and have a good amount of detail. For instance, file paths, personal context about the user's job or situation, column names and values, company names, URLs. A little bit of backstory. Some might be in lowercase or contain abbreviations or typos or casual speech. Use a mix of different lengths, and focus on edge cases rather than making them clear-cut (the user will get a chance to sign off on them).
|
|
90
|
+
|
|
91
|
+
Bad: `"Format this data"`, `"Extract text from PDF"`, `"Create a chart"`
|
|
92
|
+
|
|
93
|
+
Good: `"ok so my boss just sent me this xlsx file (its in my downloads, called something like 'Q4 sales final FINAL v2.xlsx') and she wants me to add a column that shows the profit margin as a percentage. The revenue is in column C and costs are in column D i think"`
|
|
94
|
+
|
|
95
|
+
For the **should-trigger** queries (8-10), think about coverage. You want different phrasings of the same intent — some formal, some casual. Include cases where the user doesn't explicitly name the skill or file type but clearly needs it. Throw in some uncommon use cases and cases where this skill competes with another but should win.
|
|
96
|
+
|
|
97
|
+
For the **should-not-trigger** queries (8-10), the most valuable ones are the near-misses — queries that share keywords or concepts with the skill but actually need something different. Think adjacent domains, ambiguous phrasing where a naive keyword match would trigger but shouldn't, and cases where the query touches on something the skill does but in a context where another tool is more appropriate.
|
|
98
|
+
|
|
99
|
+
The key thing to avoid: don't make should-not-trigger queries obviously irrelevant. "Write a fibonacci function" as a negative test for a PDF skill is too easy — it doesn't test anything. The negative cases should be genuinely tricky.
|
|
100
|
+
|
|
101
|
+
## Step 2: Review with user
|
|
102
|
+
|
|
103
|
+
Present the eval set to the user for review using the HTML template:
|
|
104
|
+
|
|
105
|
+
1. Read the template from `assets/eval_review.html`
|
|
106
|
+
2. Replace the placeholders:
|
|
107
|
+
- `__EVAL_DATA_PLACEHOLDER__` → the JSON array of eval items (no quotes around it — it's a JS variable assignment)
|
|
108
|
+
- `__SKILL_NAME_PLACEHOLDER__` → the skill's name
|
|
109
|
+
- `__SKILL_DESCRIPTION_PLACEHOLDER__` → the skill's current description
|
|
110
|
+
3. Write to a temp file (e.g., `/tmp/eval_review_<skill-name>.html`) and open it: `open /tmp/eval_review_<skill-name>.html`
|
|
111
|
+
4. The user can edit queries, toggle should-trigger, add/remove entries, then click "Export Eval Set"
|
|
112
|
+
5. The file downloads to `~/Downloads/eval_set.json` — check the Downloads folder for the most recent version in case there are multiple (e.g., `eval_set (1).json`)
|
|
113
|
+
|
|
114
|
+
This step matters — bad eval queries lead to bad descriptions.
|
|
115
|
+
|
|
116
|
+
## Step 3: Run the optimization loop
|
|
117
|
+
|
|
118
|
+
Tell the user: "This will take some time — I'll run the optimization loop in the background and check on it periodically."
|
|
119
|
+
|
|
120
|
+
Save the eval set to the workspace, then run in the background:
|
|
121
|
+
|
|
122
|
+
```bash
|
|
123
|
+
python -m scripts.run_loop \
|
|
124
|
+
--eval-set <path-to-trigger-eval.json> \
|
|
125
|
+
--skill-path <path-to-skill> \
|
|
126
|
+
--model <model-id-powering-this-session> \
|
|
127
|
+
--max-iterations 5 \
|
|
128
|
+
--verbose
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
Use the model ID from your system prompt (the one powering the current session) so the triggering test matches what the user actually experiences.
|
|
132
|
+
|
|
133
|
+
While it runs, periodically tail the output to give the user updates on which iteration it's on and what the scores look like.
|
|
134
|
+
|
|
135
|
+
This handles the full optimization loop automatically. It splits the eval set into 60% train and 40% held-out test, evaluates the current description (running each query 3 times to get a reliable trigger rate), then calls Claude to propose improvements based on what failed. It re-evaluates each new description on both train and test, iterating up to 5 times. When it's done, it opens an HTML report in the browser showing the results per iteration and returns JSON with `best_description` — selected by test score rather than train score to avoid overfitting.
|
|
136
|
+
|
|
137
|
+
## How skill triggering works
|
|
138
|
+
|
|
139
|
+
Understanding the triggering mechanism helps design better eval queries. Skills appear in Claude's `available_skills` list with their name + description, and Claude decides whether to consult a skill based on that description. The important thing to know is that Claude only consults skills for tasks it can't easily handle on its own — simple, one-step queries like "read this PDF" may not trigger a skill even if the description matches perfectly, because Claude can handle them directly with basic tools. Complex, multi-step, or specialized queries reliably trigger skills when the description matches.
|
|
140
|
+
|
|
141
|
+
This means your eval queries should be substantive enough that Claude would actually benefit from consulting a skill. Simple queries like "read file X" are poor test cases — they won't trigger skills regardless of description quality.
|
|
142
|
+
|
|
143
|
+
## Step 4: Apply the result
|
|
144
|
+
|
|
145
|
+
Take `best_description` from the JSON output and update the skill's SKILL.md frontmatter. Show the user before/after and report the scores.
|
|
146
|
+
|
|
147
|
+
---
|
|
148
|
+
<!-- module: 08-packaging.md -->
|
|
149
|
+
|
|
150
|
+
# Package and Present (only if `present_files` tool is available)
|
|
151
|
+
|
|
152
|
+
Check whether you have access to the `present_files` tool. If you don't, skip this step. If you do, package the skill and present the .skill file to the user:
|
|
153
|
+
|
|
154
|
+
```bash
|
|
155
|
+
python -m scripts.package_skill <path/to/skill-folder>
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
After packaging, direct the user to the resulting `.skill` file path so they can install it.
|
|
159
|
+
|
|
160
|
+
> Note on script paths: `scripts.package_skill` refers to the vendored source at `skills/sources/anthropic/skill-creator/scripts/package_skill.py`. See the `scripts-and-references` mini for the full inventory. The `package_skill.py` script works anywhere with Python and a filesystem.
|
|
@@ -0,0 +1,465 @@
|
|
|
1
|
+
<!-- GENERATED by tools/hive.py compile. Do not hand-edit. -->
|
|
2
|
+
# ccs-skill-creator: Compiled Skill Bundle (v1.0.0)
|
|
3
|
+
|
|
4
|
+
All composable mini-skills for `ccs-skill-creator` concatenated in index order, frontmatter stripped. Regenerate with `tools/hive.py compile <skill-dir>`. Do not edit by hand.
|
|
5
|
+
|
|
6
|
+
---
|
|
7
|
+
<!-- module: 00-core.md -->
|
|
8
|
+
|
|
9
|
+
# CCS Skill Creator: Core
|
|
10
|
+
|
|
11
|
+
## What CCS is
|
|
12
|
+
|
|
13
|
+
Compiled Composable Skills (CCS) packages an agent skill as small
|
|
14
|
+
authored markdown **minis** (one subtopic each), a knowledge-free **INDEX** that
|
|
15
|
+
lists them with "load when" hints, an optional always-loaded **00-core** holding
|
|
16
|
+
cross-cutting traps, and a tool-compiled **BUNDLE.md** (the deterministic
|
|
17
|
+
concatenation of every mini) plus optional named **presets/**. The minis are the
|
|
18
|
+
only source of truth; INDEX, BUNDLE, and presets are derived artifacts. The
|
|
19
|
+
payoff: a task loads only the slice it needs, quality stays at least as high as a
|
|
20
|
+
monolith, and every packaging choice is auditable. You build and check skills
|
|
21
|
+
with one stdlib CLI, `tools/hive.py` (subcommands `compile`, `lint`, `parity`,
|
|
22
|
+
`report`). This skill is itself authored in CCS format: the layout you are
|
|
23
|
+
reading is the layout you produce.
|
|
24
|
+
|
|
25
|
+
## Loading policy (how you consume any CCS skill, including this one)
|
|
26
|
+
|
|
27
|
+
Read the INDEX first. Load `00-core` if the index marks one. Estimate coverage
|
|
28
|
+
`k/N` = (minis relevant to the task) / (total minis). If `k/N` < ~0.6, load the
|
|
29
|
+
`k` relevant minis individually. If `k/N` ≥ ~0.6, load `BUNDLE.md` (or a matching
|
|
30
|
+
`presets/*.md`) in one read. Never both fan out to subagents and load the whole
|
|
31
|
+
bundle for the same task.
|
|
32
|
+
|
|
33
|
+
## The two iron rules
|
|
34
|
+
|
|
35
|
+
1. **The index is a menu, not a meal.** `INDEX.md` carries none of the
|
|
36
|
+
skill's content, only mini filenames, terse descriptors, and "load when"
|
|
37
|
+
conditions. Any knowledge a mini needs in order to be applied lives *in the
|
|
38
|
+
mini*, never in the index.
|
|
39
|
+
2. **Conversion is repackaging, never summarization.** Moving a skill into CCS
|
|
40
|
+
moves content between containers; it must not shrink it. Every fact,
|
|
41
|
+
threshold, table, and worked example survives verbatim-equivalent in some
|
|
42
|
+
mini. Runtime tokens are saved only by *selection* (load fewer minis) and
|
|
43
|
+
*dedup* (preamble shared across minis factored once into `00-core`), never by
|
|
44
|
+
cutting content.
|
|
45
|
+
|
|
46
|
+
## When NOT to use CCS
|
|
47
|
+
|
|
48
|
+
- **Under ~5k tokens of knowledge** → ship a single `SKILL.md`. The INDEX +
|
|
49
|
+
00-core scaffolding costs more than selective loading can save.
|
|
50
|
+
- **Knowledge a frontier model already applies well** → write no skill at all.
|
|
51
|
+
Generic guidance adds tokens and steps without adding quality; a no-skill
|
|
52
|
+
baseline repeatedly tied or beat skills on tasks inside model competence.
|
|
53
|
+
- **Every task needs the entire skill** → it is one document; just ship the
|
|
54
|
+
bundle, no selective loading to do.
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
<!-- module: 01-create-new-skill.md -->
|
|
58
|
+
|
|
59
|
+
# Create a New CCS Skill From Scratch
|
|
60
|
+
|
|
61
|
+
Use this when authoring a brand-new skill (no existing source to convert; for
|
|
62
|
+
that see `02-convert-existing-skill.md`). Follow the steps in order. Each step
|
|
63
|
+
lists exact commands and an **Acceptance** bar you must clear before moving on.
|
|
64
|
+
|
|
65
|
+
## Step 0: Decide whether to write a skill at all
|
|
66
|
+
|
|
67
|
+
Apply the "When NOT to use CCS" test from `00-core`: skip the skill if it would
|
|
68
|
+
carry under ~5k tokens of content (ship a single `SKILL.md` instead), or if a
|
|
69
|
+
frontier model already handles it well (write nothing). For each candidate piece
|
|
70
|
+
of guidance ask: *"would a strong model reliably do this unprompted?"* If yes,
|
|
71
|
+
cut it. What remains (the traps and non-obvious calls) is your skill.
|
|
72
|
+
|
|
73
|
+
**Acceptance:** you can name at least a few trap-dense, non-inferable pieces of
|
|
74
|
+
knowledge, and tasks that use it vary in which subtopics they need.
|
|
75
|
+
|
|
76
|
+
## Step 1: Scope the domain
|
|
77
|
+
|
|
78
|
+
Define one coherent domain a practitioner would recognize ("code review",
|
|
79
|
+
"financial analysis"), broad enough to have several subtopics but narrow enough
|
|
80
|
+
that any single task touches only some of them. Write down, before slicing:
|
|
81
|
+
|
|
82
|
+
- the **subtopics** a practitioner distinguishes;
|
|
83
|
+
- the **cross-cutting traps** that apply regardless of subtopic (these become
|
|
84
|
+
`00-core`);
|
|
85
|
+
- a few **representative tasks** spanning narrow (one subtopic) to broad (most
|
|
86
|
+
subtopics), to sanity-check your slicing.
|
|
87
|
+
|
|
88
|
+
**Acceptance:** a written list of subtopics, cross-cutting traps, and 3–5
|
|
89
|
+
representative tasks.
|
|
90
|
+
|
|
91
|
+
## Step 2: Create the directory layout
|
|
92
|
+
|
|
93
|
+
A CCS skill lives under `skills/<category>/<domain>/composable/` with exactly this shape:
|
|
94
|
+
|
|
95
|
+
```
|
|
96
|
+
skills/<category>/<domain>/
|
|
97
|
+
└── composable/
|
|
98
|
+
├── INDEX.md # the menu (you author this)
|
|
99
|
+
├── mini/
|
|
100
|
+
│ ├── 00-core.md # optional always-load cross-cutting mini
|
|
101
|
+
│ └── NN-topic.md # the authored modules (source of truth)
|
|
102
|
+
├── BUNDLE.md # generated by hive.py compile — never hand-write
|
|
103
|
+
└── presets/ # optional, generated named subsets
|
|
104
|
+
└── <name>.md
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
Pick `<category>` by provenance: `authored/` for a skill written directly in CCS
|
|
108
|
+
form, `converted/` for one ported from an existing upstream skill, `meta/` for a
|
|
109
|
+
skill about the CCS framework itself. Create
|
|
110
|
+
`skills/<category>/<domain>/composable/mini/`. Name minis `NN-topic.md` with a
|
|
111
|
+
two-digit ordinal; the ordinal fixes index and bundle order. `00-core.md` MUST
|
|
112
|
+
use ordinal `00`.
|
|
113
|
+
|
|
114
|
+
**Acceptance:** `mini/` exists; planned filenames chosen.
|
|
115
|
+
|
|
116
|
+
## Step 3: Slice the minis (one subtopic each)
|
|
117
|
+
|
|
118
|
+
Aim for roughly 6–12 minis. Rules:
|
|
119
|
+
|
|
120
|
+
- **One focused subtopic per mini.** If a mini covers two things a task might
|
|
121
|
+
want separately, split it. If two minis are never useful apart, merge them.
|
|
122
|
+
- **Order for loading.** Put the "start here" method mini first; group related
|
|
123
|
+
subtopics adjacently.
|
|
124
|
+
|
|
125
|
+
**Acceptance:** for each representative task from Step 1, you can list which minis
|
|
126
|
+
it should load. If a needed rule falls cleanly into no single mini, re-slice.
|
|
127
|
+
|
|
128
|
+
## Step 4: Write each mini, self-contained and uncompressed
|
|
129
|
+
|
|
130
|
+
Every mini MUST be applicable from *its own text plus `00-core`*, never
|
|
131
|
+
"as covered in the performance mini…". Restate the little that is needed; this
|
|
132
|
+
deliberate redundancy is what makes selective loading safe. Each mini MUST start
|
|
133
|
+
with an H1 (`# Title`). Size follows content: typical minis run ~300–700 words,
|
|
134
|
+
longer when the subtopic demands it. **Never thin content to hit a size**: you
|
|
135
|
+
save tokens by *selection*, never by summarizing.
|
|
136
|
+
|
|
137
|
+
**Acceptance:** every mini has an H1 and reads correctly with only itself +
|
|
138
|
+
`00-core` in context.
|
|
139
|
+
|
|
140
|
+
## Step 5: Write `00-core.md` (traps only, if warranted)
|
|
141
|
+
|
|
142
|
+
`00-core` carries *only* cross-cutting traps: guidance relevant more often than
|
|
143
|
+
a task-scoped reader would guess (data-quality/input-validation discipline,
|
|
144
|
+
"prove it before you claim it", "present ranges not points"). Keep it small. It
|
|
145
|
+
is paid on every load, like the index. It states the cross-cutting rule and
|
|
146
|
+
points to the focused mini for depth; it MUST NOT reproduce a subtopic's full
|
|
147
|
+
treatment. If the skill has no genuinely cross-cutting traps, omit `00-core` and
|
|
148
|
+
instead mark the "start here" method mini always-load in the index.
|
|
149
|
+
|
|
150
|
+
**Acceptance:** `00-core` (if present) is small and holds only cross-cutting
|
|
151
|
+
material, not a subtopic's depth.
|
|
152
|
+
|
|
153
|
+
## Step 6: Write the INDEX (a knowledge-free menu)
|
|
154
|
+
|
|
155
|
+
`INDEX.md` is a menu, not a meal (iron rule 1). Under ~200 words. Structure:
|
|
156
|
+
|
|
157
|
+
1. An H1 title.
|
|
158
|
+
2. The standard loading-policy header (see below), verbatim, right after the H1.
|
|
159
|
+
3. Exactly **one line per mini**, each carrying (a) the mini filename, (b) a
|
|
160
|
+
terse content descriptor (the nouns a task matches on), and (c) a **"load
|
|
161
|
+
when"** hint phrased as an *observable task condition*, not a topic
|
|
162
|
+
restatement.
|
|
163
|
+
|
|
164
|
+
If `00-core.md` exists, its line MUST be marked **always load** and the header
|
|
165
|
+
tells the reader to load it first.
|
|
166
|
+
|
|
167
|
+
Standard header (paste verbatim after the H1):
|
|
168
|
+
|
|
169
|
+
```
|
|
170
|
+
Loading policy: read this menu, then load 00-core (if present) plus the minis relevant to your task. If you judge most of this skill relevant, load BUNDLE.md (or a matching presets/*.md) in one read instead.
|
|
171
|
+
```
|
|
172
|
+
|
|
173
|
+
Good line: `` - `04-concurrency.md` — Races, shared state, deadlocks, async,
|
|
174
|
+
TOCTOU. Load when code is threaded, async, or shares state.``. Weak (avoid):
|
|
175
|
+
`` - `04-concurrency.md` — About concurrency.`` (no trigger).
|
|
176
|
+
|
|
177
|
+
**Acceptance:** one index line per mini and one mini per index line (no drift);
|
|
178
|
+
no line carries knowledge; `00-core` marked always-load if present.
|
|
179
|
+
|
|
180
|
+
## Step 7: Compile and lint, then fix findings
|
|
181
|
+
|
|
182
|
+
Generate the bundle (and any presets) and check the structure. Run from the repo
|
|
183
|
+
root:
|
|
184
|
+
|
|
185
|
+
```bash
|
|
186
|
+
python3 tools/hive.py compile skills/<category>/<domain>
|
|
187
|
+
python3 tools/hive.py lint skills/<category>/<domain>
|
|
188
|
+
```
|
|
189
|
+
|
|
190
|
+
`compile` writes `BUNDLE.md`: the deterministic concatenation of every mini in
|
|
191
|
+
ordinal order, `00-core` first, each preceded by a `<!-- module: NN-name.md -->`
|
|
192
|
+
marker. Never hand-edit `BUNDLE.md`. Add a preset only for a real recurring
|
|
193
|
+
configuration: `--presets security-audit=00-core,02 quick=00-core,01`. Do not
|
|
194
|
+
generate a combinatorial family of presets speculatively.
|
|
195
|
+
|
|
196
|
+
`lint` checks: INDEX exists and references each mini exactly once; index word
|
|
197
|
+
budget; no index line reads like knowledge; `00-core` marked always-load; every
|
|
198
|
+
mini nonempty with an H1; frontmatter (if any) valid; `BUNDLE.md` not stale. Fix
|
|
199
|
+
every **FAIL**; resolve **WARN**s or justify them. Re-run `compile` after any
|
|
200
|
+
mini edit so `BUNDLE.md` is never stale.
|
|
201
|
+
|
|
202
|
+
**Acceptance:** `lint` exits 0 (`… 0 fail`).
|
|
203
|
+
|
|
204
|
+
## Worked micro-example: a `sql-migrations` skill
|
|
205
|
+
|
|
206
|
+
1. **Scope.** Domain = writing safe database schema migrations. Subtopics:
|
|
207
|
+
backward-compatible changes, destructive changes, index/lock behavior,
|
|
208
|
+
data backfills. Cross-cutting trap: "a migration runs against production data
|
|
209
|
+
under live traffic, never assume an empty table or a maintenance window."
|
|
210
|
+
2. **Slice.** Four minis: `01-backward-compatible.md`,
|
|
211
|
+
`02-destructive-changes.md`, `03-locks-and-indexes.md`, `04-backfills.md`,
|
|
212
|
+
plus `00-core.md` for the live-traffic trap.
|
|
213
|
+
3. **Minis.** `03-locks-and-indexes.md` restates the "add index concurrently to
|
|
214
|
+
avoid a table lock" rule even though `01` mentions locks in passing, because
|
|
215
|
+
a task that loads only `03` must not miss it (self-containment).
|
|
216
|
+
4. **Core.** `00-core.md` (~120 words): live-traffic assumption, "expand then
|
|
217
|
+
contract" pattern, always ship a tested rollback; points to `02` for the
|
|
218
|
+
destructive-change detail. Marked always-load.
|
|
219
|
+
5. **Index.** Five lines. `` - `03-locks-and-indexes.md` — CONCURRENTLY, lock
|
|
220
|
+
modes, long-held locks. Load when adding/dropping indexes or altering large
|
|
221
|
+
tables.``
|
|
222
|
+
6. **Compile & lint.** `python3 tools/hive.py compile skills/sql-migrations`
|
|
223
|
+
then `lint` → 0 fail. Narrow task "add a nullable column" loads {00-core, 01}
|
|
224
|
+
(k/N = 0.4 < 0.6, load minis). Broad "review this whole migration set" →
|
|
225
|
+
k/N ≥ 0.6 → load `BUNDLE.md` in one read.
|
|
226
|
+
|
|
227
|
+
---
|
|
228
|
+
<!-- module: 02-convert-existing-skill.md -->
|
|
229
|
+
|
|
230
|
+
# Convert an Existing Skill to CCS
|
|
231
|
+
|
|
232
|
+
Use this to repackage an existing skill (a monolithic `SKILL.md`, a `SKILL.md`
|
|
233
|
+
plus a `reference/` tree, or a prompt library) into CCS. For a brand-new skill
|
|
234
|
+
with no source, see `01-create-new-skill.md`. The governing rule is iron rule 2:
|
|
235
|
+
**conversion is repackaging, never summarization** (see `00-core`).
|
|
236
|
+
|
|
237
|
+
## The failure you are avoiding
|
|
238
|
+
|
|
239
|
+
The `financial-analyst` conversion once decomposed a ~7,000-word source against
|
|
240
|
+
word budgets (250–450 words × ≤11 minis), forcing ~30% compression; token savings
|
|
241
|
+
transferred as predicted but the compressed tail held the judges' deciding
|
|
242
|
+
details and the converted skill *measurably lost quality on both eval tasks*: a
|
|
243
|
+
content loss, not a packaging flaw. That is why the parity gate below is
|
|
244
|
+
mandatory, and why you carry content at **full fidelity with no size caps**.
|
|
245
|
+
|
|
246
|
+
## Step 1: Inventory the source
|
|
247
|
+
|
|
248
|
+
Enumerate the source's substantive units: every section/heading, table,
|
|
249
|
+
threshold, worked example, and always-loaded preamble. This list is your parity
|
|
250
|
+
checklist: nothing on it may vanish. Note where the source keeps its knowledge
|
|
251
|
+
(monolith body, reference files, prompt entries) and any always-loaded preamble
|
|
252
|
+
that repeats across files (that repetition is your one legitimate dedup target).
|
|
253
|
+
|
|
254
|
+
**Acceptance:** a written list of every substantive unit in the source.
|
|
255
|
+
|
|
256
|
+
## Step 2: Map source structure to CCS elements
|
|
257
|
+
|
|
258
|
+
| Source structure | Maps to |
|
|
259
|
+
|---|---|
|
|
260
|
+
| Monolith top matter / always-loaded preamble | `00-core` (cross-cutting only) + INDEX framing |
|
|
261
|
+
| Monolith section / heading | one mini (`NN-topic.md`) |
|
|
262
|
+
| `SKILL.md` router / purpose table | `INDEX.md` (add a "load when" hint per entry) |
|
|
263
|
+
| `SKILL.md` always-loaded body | split: cross-cutting → `00-core`; subtopic prose → its mini |
|
|
264
|
+
| `reference/<topic>.md` file | one or more minis (split if coarse) |
|
|
265
|
+
| Prompt-library entry / template | one mini per coherent procedure |
|
|
266
|
+
| Repeated preamble across references | factored once into `00-core` (dedup) |
|
|
267
|
+
| Scripts, fixtures, templates, data | left as-is; referenced from a mini by path |
|
|
268
|
+
| The whole source, recompiled | `BUNDLE.md` (the parity target) |
|
|
269
|
+
|
|
270
|
+
Two rules of thumb: a coarse reference file (say 2,500 tokens) usually becomes
|
|
271
|
+
**several** minis: one mini reproduces the lost-in-the-middle problem inside a
|
|
272
|
+
single file. And the source's purpose table becomes the INDEX, but you must
|
|
273
|
+
**add** the "load when" hints if the source lacked them; triggers drive expert
|
|
274
|
+
selection.
|
|
275
|
+
|
|
276
|
+
**Acceptance:** every inventory unit from Step 1 is assigned to a specific mini.
|
|
277
|
+
|
|
278
|
+
## Step 3: Create the layout and carry content at full fidelity
|
|
279
|
+
|
|
280
|
+
Create `skills/<category>/<domain>/composable/mini/` (layout identical to a from-scratch
|
|
281
|
+
skill: `INDEX.md`, `mini/00-core.md` + `mini/NN-topic.md`, generated `BUNDLE.md`,
|
|
282
|
+
optional `presets/`). Copy each source unit into its assigned mini **verbatim or
|
|
283
|
+
verbatim-equivalent**. Split coarse references into focused minis (e.g. a DCF
|
|
284
|
+
reference → `04-dcf-projection.md` + `05-terminal-value-sensitivity.md`). Factor
|
|
285
|
+
preamble repeated across three or more source files once into `00-core`. Make
|
|
286
|
+
each mini self-contained (applicable from its own text + `00-core`) and give it
|
|
287
|
+
an H1.
|
|
288
|
+
|
|
289
|
+
**There are no size caps.** If faithful fidelity needs more room, add minis or
|
|
290
|
+
enlarge them: the fix for "too much content" is *more or larger minis*, never
|
|
291
|
+
tighter prose. Do not compress "to tidy up." Leave scripts/assets untouched and
|
|
292
|
+
reference them from a mini by path.
|
|
293
|
+
|
|
294
|
+
**Acceptance:** every mini has an H1; every inventory unit is present at full
|
|
295
|
+
fidelity in some mini; only genuine cross-file duplication was removed (and now
|
|
296
|
+
lives once in `00-core`).
|
|
297
|
+
|
|
298
|
+
## Step 4: Write the INDEX
|
|
299
|
+
|
|
300
|
+
Turn the source's purpose table into `INDEX.md`: an H1, the standard
|
|
301
|
+
loading-policy header verbatim after it, then one knowledge-free line per mini
|
|
302
|
+
with a filename, terse descriptor, and a **"load when"** observable-condition
|
|
303
|
+
hint. Mark `00-core` **always load** if present. Keep under ~200 words (~300 if
|
|
304
|
+
more than 12 minis). Standard header, pasted verbatim after the H1:
|
|
305
|
+
|
|
306
|
+
```
|
|
307
|
+
Loading policy: read this menu, then load 00-core (if present) plus the minis relevant to your task. If you judge most of this skill relevant, load BUNDLE.md (or a matching presets/*.md) in one read instead.
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
## Step 5: Compile, then run the parity gate and lint
|
|
311
|
+
|
|
312
|
+
Run from the repo root:
|
|
313
|
+
|
|
314
|
+
```bash
|
|
315
|
+
python3 tools/hive.py compile skills/<category>/<domain>
|
|
316
|
+
python3 tools/hive.py parity skills/<category>/<domain> <source-dir>
|
|
317
|
+
python3 tools/hive.py lint skills/<category>/<domain>
|
|
318
|
+
```
|
|
319
|
+
|
|
320
|
+
`parity` compares the union of your minis against the original source. It reports
|
|
321
|
+
a **token ratio** (mini tokens ÷ source tokens) and lists any source `##`/`###`
|
|
322
|
+
heading with no fuzzy match in the minis (possibly dropped). Acceptance bar:
|
|
323
|
+
|
|
324
|
+
- Ratio **≥ 85%** is the hard floor (below it, `parity` FAILs and summarization
|
|
325
|
+
is suspected). **Aim for 95%+**: a faithful conversion loses tokens only to
|
|
326
|
+
genuine dedup, so the union of minis should be nearly the whole source.
|
|
327
|
+
- The dropped-heading list must be **empty**, or every entry on it explained as
|
|
328
|
+
genuine duplication now living once in `00-core`. Treat each listed heading as
|
|
329
|
+
a real gap: open the source section, find where it should live, and restore it
|
|
330
|
+
into the right mini. Re-run `compile` then `parity` until clean.
|
|
331
|
+
|
|
332
|
+
`lint` must exit 0 (INDEX/mini/core structural rules, `00-core` marked
|
|
333
|
+
always-load, `BUNDLE.md` not stale). A conversion that cannot pass parity within
|
|
334
|
+
your current mini count needs **more or larger minis, not tighter prose**.
|
|
335
|
+
|
|
336
|
+
**Acceptance:** `parity` ratio ≥ 85% (target 95%+) with no unexplained dropped
|
|
337
|
+
heading, **and** `lint` exits 0. Only then is the conversion done.
|
|
338
|
+
|
|
339
|
+
## Edge cases
|
|
340
|
+
|
|
341
|
+
- **No cross-cutting content in the source** → omit `00-core`; mark the "start
|
|
342
|
+
here" mini always-load instead. Don't invent core material.
|
|
343
|
+
- **Script-heavy skill** → convert only the knowledge markdown; leave
|
|
344
|
+
`scripts/`, `assets/`, fixtures exactly as they are and reference them by path.
|
|
345
|
+
- **Source already close to CCS** (fine-grained references with triggers) →
|
|
346
|
+
conversion is mostly mechanical: rename to `NN-topic.md`, write the INDEX with
|
|
347
|
+
"load when" hints, compile, parity-check. Still do not compress.
|
|
348
|
+
- **Very large source** that overflows your intended mini count at full
|
|
349
|
+
fidelity → raise the mini count. Parity outranks any target mini count.
|
|
350
|
+
|
|
351
|
+
---
|
|
352
|
+
<!-- module: 03-review-and-maintain.md -->
|
|
353
|
+
|
|
354
|
+
# Review and Maintain a CCS Skill
|
|
355
|
+
|
|
356
|
+
Use this when changing a skill that already exists in CCS format: editing its
|
|
357
|
+
knowledge, adding a preset, or checking it still conforms. The governing
|
|
358
|
+
discipline is the source/artifact split: `mini/*.md` is the only source of
|
|
359
|
+
truth; `INDEX.md`, `BUNDLE.md`, and `presets/*.md` are derived.
|
|
360
|
+
|
|
361
|
+
## The maintenance loop (edit minis, recompile, relint)
|
|
362
|
+
|
|
363
|
+
To change any knowledge:
|
|
364
|
+
|
|
365
|
+
1. **Edit the mini**, never `BUNDLE.md` or `presets/*.md`. Those are generated;
|
|
366
|
+
hand-edits are overwritten on the next compile and break the parity guarantee.
|
|
367
|
+
2. **Recompile** so the bundle (and presets) match the minis again:
|
|
368
|
+
|
|
369
|
+
```bash
|
|
370
|
+
python3 tools/hive.py compile skills/<category>/<domain>
|
|
371
|
+
```
|
|
372
|
+
|
|
373
|
+
3. **Relint** and fix every FAIL:
|
|
374
|
+
|
|
375
|
+
```bash
|
|
376
|
+
python3 tools/hive.py lint skills/<category>/<domain>
|
|
377
|
+
```
|
|
378
|
+
|
|
379
|
+
`lint` flags a **stale BUNDLE.md** (`does not match mini/*.md — re-run
|
|
380
|
+
compile`) whenever a mini changed but the bundle was not regenerated. Note the
|
|
381
|
+
asymmetry: editing only `INDEX.md` does *not* stale the bundle (the bundle is
|
|
382
|
+
built from minis, not the index), but it can still break other lint rules
|
|
383
|
+
(drift, word budget, always-load marking), so relint after any edit.
|
|
384
|
+
|
|
385
|
+
**Acceptance:** `lint` exits 0 after every change.
|
|
386
|
+
|
|
387
|
+
## Keep the INDEX in sync
|
|
388
|
+
|
|
389
|
+
Every mini file MUST have exactly one index line, and every index line exactly
|
|
390
|
+
one mini file: `lint` fails on drift. So:
|
|
391
|
+
|
|
392
|
+
- **Add a mini** → add its one knowledge-free index line (descriptor + "load
|
|
393
|
+
when" hint), keep it under the word budget, then recompile.
|
|
394
|
+
- **Remove a mini** → delete its file *and* its index line, then recompile.
|
|
395
|
+
- **Rename a mini** → rename the file and update the index line's filename, then
|
|
396
|
+
recompile (the bundle's `<!-- module: … -->` marker tracks the new name).
|
|
397
|
+
|
|
398
|
+
Keep edits within the "index is a menu, not a meal" rule: never migrate
|
|
399
|
+
knowledge into the index to "clarify" it. If a mini's trigger is unclear, sharpen
|
|
400
|
+
the "load when" condition, not by adding skill content.
|
|
401
|
+
|
|
402
|
+
**Acceptance:** one index line per mini and one mini per index line; index still
|
|
403
|
+
under ~200 words (~300 for >12 minis); no line reads like knowledge.
|
|
404
|
+
|
|
405
|
+
## Editing content without regressing fidelity
|
|
406
|
+
|
|
407
|
+
When the skill was produced by *conversion*, re-run the parity gate after
|
|
408
|
+
substantive edits so you don't silently drop content:
|
|
409
|
+
|
|
410
|
+
```bash
|
|
411
|
+
python3 tools/hive.py parity skills/<category>/<domain> <source-dir>
|
|
412
|
+
```
|
|
413
|
+
|
|
414
|
+
Keep the ratio ≥ 85% (aim 95%+) with no unexplained dropped heading. When adding
|
|
415
|
+
new original knowledge (no external source), there is nothing to parity against:
|
|
416
|
+
just ensure the new mini is self-contained and the bundle recompiles clean.
|
|
417
|
+
|
|
418
|
+
## Adding presets, especially for variant-split skills
|
|
419
|
+
|
|
420
|
+
A **preset** is a named compiled subset of minis for a recurring configuration,
|
|
421
|
+
built by the same concatenation rules as the bundle. Generate presets with the
|
|
422
|
+
`--presets NAME=IDS` flag on `compile` (ids may be ordinals like `01`, stems, or
|
|
423
|
+
filenames; comma-separated; order preserved):
|
|
424
|
+
|
|
425
|
+
```bash
|
|
426
|
+
python3 tools/hive.py compile skills/<category>/<domain> \
|
|
427
|
+
--presets security-audit=00-core,02 python-server=00-core,01,02,11,12
|
|
428
|
+
```
|
|
429
|
+
|
|
430
|
+
This writes `presets/security-audit.md` and `presets/python-server.md`. Presets
|
|
431
|
+
SHOULD be few and named for real recurring tasks. Do not generate a
|
|
432
|
+
combinatorial family speculatively.
|
|
433
|
+
|
|
434
|
+
**The variant-split case is where presets earn their keep.** When a skill
|
|
435
|
+
contains mutually-exclusive tracks, such as language variants (Python *vs* Node)
|
|
436
|
+
or platform variants (iOS *vs* Android), a broad task should never load the whole
|
|
437
|
+
bundle, because half of it is irrelevant to the chosen variant. Ship one preset
|
|
438
|
+
per variant: each is `00-core` + the shared minis + only that variant's minis, so
|
|
439
|
+
a "build the whole Python server" task loads `presets/python-server.md` in one
|
|
440
|
+
read with zero cross-variant waste. Reference these presets in the INDEX's
|
|
441
|
+
loading header or a note so the loader knows to prefer them for broad
|
|
442
|
+
variant-specific work.
|
|
443
|
+
|
|
444
|
+
**Acceptance:** each preset covers exactly one real recurring configuration;
|
|
445
|
+
`presets/*.md` are tool-generated (never hand-edited); `lint` exits 0.
|
|
446
|
+
|
|
447
|
+
## Conformance re-check
|
|
448
|
+
|
|
449
|
+
Before considering maintenance done, confirm the skill still satisfies the spec:
|
|
450
|
+
knowledge-free INDEX under budget with one "load when" line per mini; focused,
|
|
451
|
+
self-contained, uncompressed minis each with an H1; a small `00-core` where
|
|
452
|
+
warranted, marked always-load; a tool-generated, boundary-marked, never-
|
|
453
|
+
hand-edited `BUNDLE.md` and any presets; passing parity (for converted skills);
|
|
454
|
+
untouched non-knowledge assets. A single command reports lint status across every
|
|
455
|
+
skill in the repo:
|
|
456
|
+
|
|
457
|
+
```bash
|
|
458
|
+
python3 tools/hive.py report skills
|
|
459
|
+
```
|
|
460
|
+
|
|
461
|
+
`report` prints a per-skill token/size table with a `lint (P/W/F)` column and
|
|
462
|
+
exits nonzero if any skill has a lint FAIL. Use it as the final green light.
|
|
463
|
+
|
|
464
|
+
**Acceptance:** `report skills` shows the maintained skill with `0F` (zero
|
|
465
|
+
fails).
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
# CCS Skill Creator: Loading Menu
|
|
2
|
+
|
|
3
|
+
Loading policy: read this menu, then load 00-core (if present) plus the minis relevant to your task. If most of this skill is relevant, load BUNDLE.md (or a matching presets/*.md) in one read instead.
|
|
4
|
+
|
|
5
|
+
- `mini/00-core.md` - what CCS is, the loading policy, the two iron rules, when NOT to use CCS - **always load**
|
|
6
|
+
- `mini/01-create-new-skill.md` - author a new skill from scratch: scope, slice, write minis/core/index, compile, lint; worked example. Load when creating a new CCS skill with no source.
|
|
7
|
+
- `mini/02-convert-existing-skill.md` - repackage any source (monolith, SKILL.md+references, prompt library): inventory, map, full-fidelity carry, parity-gate, lint. Load when converting an existing skill.
|
|
8
|
+
- `mini/03-review-and-maintain.md` - editing minis and recompiling, keeping the index in sync, adding presets for variant-split skills, conformance re-check. Load when updating or maintaining a skill already in CCS format.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
1.0.0
|