Content Optimization for Skills
Transform input into concise, technical instructions for AI consumption. Audience is AI model with expert-level comprehension. Assume complete familiarity with domain internals.
Core Principles
When transforming text into RULES, CONDITIONS, CONSTRAINTS:
- Write focused, imperative, actionable, scoped rules
- Target under 500 lines per file
- Split large concepts into composable rules or tagged data sets
- Preemptively provide URLs and file links
- Write as clear internal documentation (avoid vague guidance)
- Use declarative phrasing ("The model MUST")
- Produce deterministic flat ASCII (structural markdown only: headings, lists, links, code fences with language specifiers)
- Include sections: identity, intent, task rules, issue handling, triggers, external references
- Preserve/expand structured examples from source
XML Tag Strategy
Tags improve clarity, accuracy, flexibility, parseability when prompts have multiple components (context, instructions, examples).
Use tags to separate prompt parts: <instructions>, <example>, <formatting>, <constraints>
- Prevents mixing instructions with examples/context
- Consistent tag names throughout
- Nest hierarchically:
<outer><inner></inner></outer>
- Combine with multishot (
<examples>) or chain of thought (<thinking>, <answer>)
No canonical "best" tags — use semantic names matching information type.
SOURCE: Anthropic prompt engineering - XML tags
Transformation Checklist
- Open with directive on how to read/apply rules
- Maximize information density (technical jargon, dense terminology, industry terms)
- Rephrase for accuracy and specificity
- Address expert/scientific/academic audience
- Use visible ASCII only
- Write as lookup references for AI (decision triggers, pattern-matching rules)
- Omit greetings and unnecessary prose
- Preserve output structure specifications
- Use precise ACTION→TRIGGER→OUTCOME format in frontmatter descriptions
- Set clear priority levels between rules
- Provide concise positive/negative examples
- Optimize for context window efficiency
- Use standard glob patterns without quotes (
*.js, src/**/*.{ts,js})
- Rich frontmatter descriptions with TRIGGERS
- Limit examples to essential patterns only
1---2name: 2545-skill-content-optimization-12ecadeb3description: Content Optimization for Skills4---56# Content Optimization for Skills78Transform input into concise, technical instructions for AI consumption. Audience is AI model with expert-level comprehension. Assume complete familiarity with domain internals.910## Core Principles1112When transforming text into RULES, CONDITIONS, CONSTRAINTS:1314- Write focused, imperative, actionable, scoped rules15- Target under 500 lines per file16- Split large concepts into composable rules or tagged data sets17- Preemptively provide URLs and file links18- Write as clear internal documentation (avoid vague guidance)19- Use declarative phrasing ("The model MUST")20- Produce deterministic flat ASCII (structural markdown only: headings, lists, links, code fences with language specifiers)21- Include sections: identity, intent, task rules, issue handling, triggers, external references22- Preserve/expand structured examples from source2324## XML Tag Strategy2526Tags improve clarity, accuracy, flexibility, parseability when prompts have multiple components (context, instructions, examples).2728Use tags to separate prompt parts: `<instructions>`, `<example>`, `<formatting>`, `<constraints>`2930- Prevents mixing instructions with examples/context31- Consistent tag names throughout32- Nest hierarchically: `<outer><inner></inner></outer>`33- Combine with multishot (`<examples>`) or chain of thought (`<thinking>`, `<answer>`)3435No canonical "best" tags — use semantic names matching information type.3637SOURCE: [Anthropic prompt engineering - XML tags](https://docs.anthropic.com/prompt-engineering/use-xml-tags)3839## Transformation Checklist40411. Open with directive on how to read/apply rules422. Maximize information density (technical jargon, dense terminology, industry terms)433. Rephrase for accuracy and specificity444. Address expert/scientific/academic audience455. Use visible ASCII only466. Write as lookup references for AI (decision triggers, pattern-matching rules)477. Omit greetings and unnecessary prose488. Preserve output structure specifications499. Use precise ACTION→TRIGGER→OUTCOME format in frontmatter descriptions5010. Set clear priority levels between rules5111. Provide concise positive/negative examples5212. Optimize for context window efficiency5313. Use standard glob patterns without quotes (`*.js`, `src/**/*.{ts,js}`)5414. Rich frontmatter descriptions with TRIGGERS5515. Limit examples to essential patterns only