Build new agent skills. Use when creating diagnostic frameworks, CLI tools, or data-driven generators that follow the established skill patterns.
npx claudepluginhub joshuarweaver/cascade-content-creation-misc-1 --plugin jwynia-agent-skills-1This skill uses the workspace's default tool permissions.
You help create new agent skills that follow established patterns. Your role is to guide skill design, generate scaffolding, and validate completeness.
Guides Next.js Cache Components and Partial Prerendering (PPR) with cacheComponents enabled. Implements 'use cache', cacheLife(), cacheTag(), revalidateTag(), static/dynamic optimization, and cache debugging.
Guides building MCP servers enabling LLMs to interact with external services via tools. Covers best practices, TypeScript/Node (MCP SDK), Python (FastMCP).
Generates original PNG/PDF visual art via design philosophy manifestos for posters, graphics, and static designs on user request.
You help create new agent skills that follow established patterns. Your role is to guide skill design, generate scaffolding, and validate completeness.
Skills are diagnostic frameworks with tools, not feature checklists.
A skill diagnoses a problem space, identifies states, and provides interventions. Scripts provide randomization and structure; the LLM provides judgment. Each does what it's best at.
Every skill has these components:
skill-name/
├── SKILL.md # Diagnostic framework + documentation
├── scripts/ # Deno TypeScript tools
│ └── *.ts
├── data/ # JSON datasets (if needed)
│ └── *.json
└── references/ # Supporting documentation (optional)
└── *.md
---
name: skill-name
description: One sentence starting with action verb
license: MIT
metadata:
author: your-name
version: "1.0"
maturity_score: [0-20] # Optional
---
# Skill Name: Subtitle
You [role description]. Your role is to [specific function].
## Core Principle
**Bold statement capturing diagnostic essence.**
## The States
### State X1: Name
**Symptoms:** What the user notices
**Key Questions:** What to ask
**Interventions:** What framework/tool to apply
[Repeat for each state]
## Diagnostic Process
1. Step one
2. Step two
...
## Key Questions
### For Category A
- Question?
- Question?
## Anti-Patterns
### The [Problem Name]
**Problem:** Description
**Fix:** Solution
## Available Tools
### script.ts
Description of what it does.
\`\`\`bash
deno run --allow-read scripts/script.ts [args]
\`\`\`
## Example Interaction
**User:** "Problem description"
**Your approach:**
1. Action
2. Action
## What You Do NOT Do
- List of boundaries
- Things the skill never does
## Integration Graph
### Inbound (From Other Skills)
| Source Skill | Source State | Leads to State |
|--------------|--------------|----------------|
| [skill] | [state] | [state] |
### Outbound (To Other Skills)
| This State | Leads to Skill | Target State |
|------------|----------------|--------------|
| [state] | [skill] | [state] |
### Complementary Skills
| Skill | Relationship |
|-------|--------------|
| [skill] | [how they relate] |
Purpose: Identify problems, recommend interventions Pattern: States → Questions → Interventions Examples: story-sense, worldbuilding, conlang
Key characteristics:
Purpose: Produce structured output from parameters Pattern: Parameters → Generation → Output Examples: Functions in story-sense, phonology in conlang
Key characteristics:
Purpose: Support other skills, build infrastructure Pattern: Input → Analysis/Transformation → Report Examples: list-builder, skill-builder
Key characteristics:
Purpose: Coordinate multiple skills into autonomous workflows Pattern: Input → Multi-Pass Evaluation Loop → Polished Output Examples: chapter-drafter
Key characteristics:
Required frontmatter:
metadata:
orchestrates: # Sub-skills to coordinate
- skill-one
- skill-two
pass_order: # Evaluation sequence
- skill-one
- skill-two
pass_weights: # Weight per skill (sum to 100)
skill-one: 50
skill-two: 50
max_iterations: 3 # Per-pass iteration limit
global_max_iterations: 50 # Total cap
See skills/fiction/orchestrators/README.md for architectural details.
Skills are evaluated on a 24-point scale parallel to the framework 24-point system.
| Check | Points | Criteria |
|---|---|---|
| Core Principle | 1 | Bold statement capturing diagnostic essence |
| States | 2 | 3-7 states for diagnostic skills (N/A for generator/utility) |
| State Components | 2 | Symptoms, Key Questions, Interventions for each state |
| Diagnostic Process | 1 | Step-by-step process documented |
| Anti-Patterns | 2 | 3+ anti-patterns with Problem/Fix structure |
| Examples | 2 | 2+ worked examples showing skill application |
| Boundaries | 1 | "What You Do NOT Do" section |
| Check | Points | Criteria |
|---|---|---|
| Self-Contained | 1 | Can be used without reading other skills |
| Type+Mode Declared | 1 | Required frontmatter fields present |
| State Naming | 1 | Consistent state prefix matching skill abbreviation |
| Integration Map | 1 | Documents connections to other skills |
| Tools Documented | 1 | All scripts have usage documentation |
| Check | Points | Criteria |
|---|---|---|
| Output Persistence | 1 | Customized (not boilerplate) persistence section |
| Progressive Disclosure | 1 | Quick reference section for at-a-glance use |
| Decision Tree | 1 | Routing logic for common scenarios |
| Actionability | 1 | Clear next steps for each diagnosis |
| Check | Points | Criteria |
|---|---|---|
| Reasoning Requirements | 1 | Specifies when extended thinking benefits the task |
| Execution Strategy | 1 | Documents sequential vs. parallelizable work |
| Subagent Guidance | 1 | Identifies when to spawn specialized subagents |
| Context Management | 1 | Documents token footprint and optimization strategies |
| Level | Score | Description |
|---|---|---|
| Draft | 0-8 | Missing core elements |
| Developing | 9-14 | Functional but incomplete |
| Stable | 15-20 | Production-ready |
| Battle-Tested | 21-24 | Has case studies + full execution intelligence |
Every skill must declare its type in frontmatter:
metadata:
| Type | Definition | Required Sections |
|---|---|---|
| diagnostic | Identifies problems, recommends interventions | States, Diagnostic Process, Anti-Patterns |
| generator | Produces structured output from parameters | Parameters, Generation Logic, Output Formats |
| utility | Supports other skills, builds infrastructure | Process, Templates, Validation |
| orchestrator | Coordinates multiple skills into autonomous workflows | Orchestration Loop, Pass Criteria, Iteration Limits |
Every skill must declare its mode in frontmatter:
metadata:
| Mode | Definition | User Relationship |
|---|---|---|
| diagnostic | Identifies problem states and recommends | Agent diagnoses, user decides |
| assistive | Guides without producing content | Agent asks questions, user creates |
| collaborative | Works alongside user | Agent produces, user guides |
| evaluative | Assesses existing work | Agent reviews, user responds |
| application | Operates in real-time context | Agent runs, user participates |
| generative | Creates output from parameters | Agent produces, user selects |
Compound modes (e.g., diagnostic+generative) are allowed when skills perform multiple functions.
metadata:
maturity_score: 15
States must follow a consistent naming pattern:
Convention: {ABBREV}{NUMBER}: {State Name}
Rules:
Standard Abbreviations:
| Skill | Abbreviation | Example |
|---|---|---|
| story-sense | SS | State SS1: Concept Without Foundation |
| dialogue | D | State D1: Identical Voices |
| conlang | L | State L1: No Language |
| worldbuilding | W | State W1: Backdrop World |
| revision | R | State R1: Overwhelmed |
| endings | E | State E1: Arbitrary Ending |
| character-arc | CA | State CA1: Static Character |
| scene-sequencing | SQ | State SQ1: Scene-Only Pacing |
| brainstorming | B | State B1: Convergent Ideas |
| research | RS | State RS1: No Research |
| requirements-analysis | RA | State RA1: Vague Requirements |
| system-design | SD | State SD1: No Architecture |
| chapter-drafter | CD | (Orchestrator - uses pass scores, not states) |
New skills should claim an unused abbreviation and document it here.
Every skill must document its connections to other skills.
Required Format:
## Integration Graph
### Inbound (From Other Skills)
| Source Skill | Source State | Leads to State |
|--------------|--------------|----------------|
| story-sense | SS5: Plot Without Purpose | D4: No Subtext |
### Outbound (To Other Skills)
| This State | Leads to Skill | Target State |
|------------|----------------|--------------|
| D6: Pacing Mismatch | scene-sequencing | SQ2: Sequel Missing |
### Complementary Skills
| Skill | Relationship |
|-------|--------------|
| character-arc | Voice reflects transformation |
| worldbuilding | Speech reflects culture |
Requirements:
Skills should document how they're best executed by Claude Code.
Document when extended thinking (ultrathink) benefits the skill:
## Reasoning Requirements
### Standard Reasoning
- Initial diagnosis and symptom matching
- Simple state identification
- Script execution and output interpretation
### Extended Reasoning (ultrathink)
Use extended thinking for:
- Multi-framework synthesis - [Why: requires holding multiple models simultaneously]
- Complex worldbuilding systems - [Why: many interdependent variables]
- Cascade analysis across states - [Why: second-order effects compound]
**Trigger phrases:** "deep analysis", "comprehensive review", "multi-framework synthesis"
Why this matters: LLMs have a completion reward bias—they rush toward visible goals. Extended thinking allocates reasoning time before output, improving quality on complex tasks. This aligns with the LLM Process Design Framework principle.
Document sequential vs. parallel work:
## Execution Strategy
### Sequential (Default)
- Diagnosis must complete before intervention
- State identification before framework selection
### Parallelizable
- Multiple script runs (entropy + functions) can run concurrently
- Research across multiple frameworks can parallelize
- Use when: Tasks are independent and can merge results
### Subagent Candidates
| Task | Agent Type | When to Spawn |
|------|------------|---------------|
| Codebase exploration | Explore | When skill needs project context |
| Framework research | general-purpose | When synthesizing across 3+ frameworks |
Document token usage and optimization:
## Context Management
### Approximate Token Footprint
- **Skill base:** ~2k tokens
- **With full state definitions:** ~4k tokens
- **With scripts inline:** ~8k tokens (avoid unless debugging)
### Context Optimization
- Load scripts on-demand rather than including inline
- Reference framework documentation by name rather than embedding
- Use Quick Reference section for common cases
### When Context Gets Tight
- Prioritize: Current state diagnosis and immediate intervention
- Defer: Integration graph, full anti-patterns list
- Drop: Script source code, historical examples
Every skill must document common mistakes.
Minimum Requirements:
Required Structure:
### The {Anti-Pattern Name}
**Pattern:** What the problematic behavior looks like
**Problem:** Why this causes harm
**Fix:** How to resolve it
**Detection:** [Optional] How to recognize this happening
Common Anti-Pattern Categories:
| Category | Example Names |
|---|---|
| Scope Creep | The Kitchen Sink, The Mission Creep |
| Missing Depth | The Surface Treatment, The Checklist |
| Wrong Level | The Bottom-Up Edit, The Premature Optimization |
| User Relationship | The Puppet Master, The Passive Recipient |
| Integration | The Orphan Skill, The Boundary Ignorer |
#!/usr/bin/env -S deno run --allow-read
/**
* Script Name
*
* Description of what it does.
*
* Usage:
* deno run --allow-read script.ts [args]
*/
// === INTERFACES ===
interface ResultType {
field: string;
// ...
}
// === DATA ===
const DATA: Record<string, string[]> = {
category: ["item1", "item2"],
};
// === UTILITIES ===
function randomFrom<T>(arr: T[], count: number = 1): T[] {
const shuffled = [...arr].sort(() => Math.random() - 0.5);
return shuffled.slice(0, Math.min(count, arr.length));
}
// === CORE LOGIC ===
function generate(/* params */): ResultType {
// Generation logic
}
// === FORMATTING ===
function formatResult(result: ResultType): string {
const lines: string[] = [];
// Format output
return lines.join("\n");
}
// === MAIN ===
function main(): void {
const args = Deno.args;
// Help
if (args.includes("--help") || args.includes("-h")) {
console.log(`Script Name
Usage:
deno run --allow-read script.ts [options]
Options:
--flag Description
--json Output as JSON
`);
Deno.exit(0);
}
// Parse arguments
const flagIndex = args.indexOf("--flag");
const flagValue = flagIndex !== -1 ? args[flagIndex + 1] : null;
const jsonOutput = args.includes("--json");
// Skip indices for positional arg detection
const skipIndices = new Set<number>();
if (flagIndex !== -1) {
skipIndices.add(flagIndex);
skipIndices.add(flagIndex + 1);
}
// Find positional argument
let positionalArg: string | null = null;
for (let i = 0; i < args.length; i++) {
if (!args[i].startsWith("--") && !skipIndices.has(i)) {
positionalArg = args[i];
break;
}
}
// Generate
const result = generate(/* params */);
// Output
if (jsonOutput) {
console.log(JSON.stringify(result, null, 2));
} else {
console.log(formatResult(result));
}
}
main();
// 1. Help check first
if (args.includes("--help") || args.includes("-h")) { ... }
// 2. Parse --flag value pairs
const flagIndex = args.indexOf("--flag");
const flagValue = flagIndex !== -1 ? args[flagIndex + 1] : defaultValue;
// 3. Boolean flags
const boolFlag = args.includes("--bool");
// 4. Track consumed indices
const skipIndices = new Set<number>();
if (flagIndex !== -1) {
skipIndices.add(flagIndex);
skipIndices.add(flagIndex + 1);
}
// 5. Find positional args
for (let i = 0; i < args.length; i++) {
if (!args[i].startsWith("--") && !skipIndices.has(i)) {
positionalArg = args[i];
break;
}
}
// For external JSON files
async function loadData<T>(path: string): Promise<T> {
try {
const text = await Deno.readTextFile(path);
return JSON.parse(text);
} catch (e) {
console.error(`Error loading ${path}: ${e}`);
Deno.exit(1);
}
}
// Relative path from script
const scriptDir = new URL(".", import.meta.url).pathname;
const dataPath = `${scriptDir}../data/file.json`;
// Always support multiple formats
if (jsonOutput) {
console.log(JSON.stringify(result, null, 2));
} else if (briefOutput) {
console.log(formatBrief(result));
} else {
console.log(formatFull(result));
}
{
"list_name": [
"Specific item with enough detail to spark ideas",
"Another item that's 20-60 characters ideally",
"Items should be concrete not vague"
]
}
Quality thresholds:
{
"_meta": {
"description": "What this data is for",
"usage": "How to use it",
"source": "Where it came from (optional)"
},
"category": {
"item_name": {
"property": "value",
"frequency": 0.85,
"tags": ["tag1", "tag2"]
}
}
}
{
"tier_universal": {
"description": "Found in nearly all cases",
"items": { "a": { "frequency": 0.95 }, "b": { "frequency": 0.90 } }
},
"tier_common": {
"description": "Found in most cases",
"items": { "c": { "frequency": 0.70 } }
},
"tier_rare": {
"description": "Unusual but attested",
"items": { "d": { "frequency": 0.15 } }
}
}
When creating a new skill:
Run validate-skill.ts to check:
Generates skill directory structure and template files.
# Create new skill scaffolding
deno run --allow-read --allow-write scripts/scaffold.ts skill-name
# With type specification
deno run --allow-read --allow-write scripts/scaffold.ts skill-name --type diagnostic
# Preview without writing
deno run --allow-read scripts/scaffold.ts skill-name --dry-run
Checks skill completeness and pattern conformance.
# Validate a skill
deno run --allow-read scripts/validate-skill.ts ../worldbuilding
# Validate all skills in fiction cluster
deno run --allow-read scripts/validate-skill.ts --all
# JSON output for CI
deno run --allow-read scripts/validate-skill.ts ../conlang --json
Problem: Skill is a list of things it can do, not a diagnostic framework. Fix: Restructure around problem states. What are users stuck on?
Problem: Skill tries to do too much, covers multiple problem domains. Fix: Split into focused skills. One skill = one diagnostic space.
Problem: Script exists but no SKILL.md explains when to use it. Fix: Every script belongs to a skill with documented purpose.
Problem: Skill doesn't reference or get referenced by other skills. Fix: Add integration section. Map state transitions to/from other skills.
Problem: Skill duplicates another skill's states with different names. Fix: Merge or clearly differentiate the problem spaces.
This section documents what this skill can reliably verify vs. what requires human judgment.
See organization/architecture/context-packet-architecture.md for background on oracles.
{ABBREV}{N}: Name pattern (High confidence)| Script | Verifies | Confidence |
|---|---|---|
| validate-skill.ts | 20-point maturity scoring across Completeness/Quality/Usability | High for structure, Low for semantics |
| scaffold.ts | Generated files match expected structure | High |
The validate-skill.ts script:
This section documents how outputs persist and inform future sessions.
See organization/architecture/context-packet-architecture.md for background on feedback loops.
skills/{cluster}/{skill-name}/ (directory structure)This section documents preconditions and boundaries.
See organization/architecture/context-packet-architecture.md for background on constraints.
Signs this skill is being misapplied:
Request: "Create a skill for diagnosing dialogue problems"
Dialogue problems are distinct from scene-sequencing (structure) and character-arc (transformation). This is about how characters speak.
Script: voice-check.ts - generates voice differentiation questionnaire
Data: speech-patterns.json - regional, class, personality markers
deno run --allow-read --allow-write scripts/scaffold.ts dialogue --type diagnostic
This skill writes primary output to files so work persists across sessions.
Before doing any other work:
context/output-config.md in the projectskills/{cluster}/{skill-name}/ as the standard skill locationcontext/output-config.md if context network exists.skill-builder-output.md at project root otherwiseFor this skill, persist:
| Goes to File | Stays in Conversation |
|---|---|
| Generated SKILL.md | Discussion of problem space |
| Script templates | State definition iteration |
| Data file stubs | Integration planning |
| Validation results | Real-time feedback |
Pattern: skills/{cluster}/{skill-name}/ (directory structure)
Example: skills/fiction/dialogue/
Use list-builder quality criteria for any data files:
Skills can reference skills in other clusters:
When building skills within a cluster:
cluster in frontmatter to the parent skill