一键导入
creating-skills
Guide for creating Claude Code skill documents with YAML frontmatter, instructions, examples, and reference implementations
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Guide for creating Claude Code skill documents with YAML frontmatter, instructions, examples, and reference implementations
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Protocol fuzzer script development using boofuzz framework. Use when creating network protocol fuzzers, defining protocol PDUs (Protocol Data Units), writing mutation-based fuzzing scripts, or contributing to the boofuzz project. Covers binary protocol definitions, session management, crash detection, and reporting findings.
Real-time browser debugging and interaction via WebSocket bridge server on localhost:3141
C# static analysis tool for call graphs, unused code detection, impact analysis, HTML documentation generation, and Graphviz diagram export
JavaScript/TypeScript static analysis tool for call graphs, unused code detection (tree shaking), dependency analysis, and circular dependency detection
UTF-8 JSON file I/O utilities to avoid Windows encoding issues (CP-1252 vs UTF-8)
Rust development patterns, project setup, CLI/TUI applications, error handling, and system integration
| name | Creating Skills |
| description | Guide for creating Claude Code skill documents with YAML frontmatter, instructions, examples, and reference implementations |
This guide explains how to create effective skill documents for Claude Code. Skills are domain-specific knowledge files that teach Claude how to perform specialized tasks consistently.
Skills must be placed in the .claude/skills/ directory with the following structure:
.claude/
�� skills/
�� My Skill Name/
�� SKILL.md # Main skill document (required)
�� reference-file.cs # Supporting reference files (optional)
Every skill document must begin with YAML frontmatter between --- delimiters:
---
name: Skill Name
description: Brief description of what this skill enables (appears in skill list)
---
Frontmatter Fields:
| Field | Required | Description |
|---|---|---|
name | Yes | Display name for the skill (used in /skill command) |
description | Yes | One-line summary shown when listing available skills |
license | No | License information if applicable |
Example:
---
name: Elasticsearch
description: Elasticsearch 5.2 operations using HTTP API - searching, indexing, bulk operations, scroll API, and alias management
---
A well-structured skill document follows this pattern:
# Skill Name
Brief introduction explaining what this skill covers and when Claude should use it.
Numbered guidelines for Claude to follow when applying this skill:
## Instructions
When helping users with [topic], follow these guidelines:
1. **Guideline One**: Explanation of the first principle
2. **Guideline Two**: Second important consideration
3. **Guideline Three**: Third rule to follow
...
Conversational examples showing how Claude should respond to common requests:
## Examples
### Example 1: Descriptive Title
User: Example user request
Claude: How Claude should approach this:
[Provides implementation using the Pattern Name from reference material below]
### Example 2: Another Common Scenario
User: Different user request
Claude: Alternative approach explanation...
Example Pattern:
### Example 3: Search with Range Filters
User: Help me search Elasticsearch for pricing periods active today
Claude: I'll use the ServiceLib.Elasticsearch wrapper with a bool query and range filters:
[Provides implementation using the Search pattern from reference material below]
Divider followed by detailed, production-proven code:
---
# Reference Implementation Details
The sections below contain proven working code from production systems that the examples above reference.
**Reference Files in This Folder**:
- `HelperClass.cs` - Description of what it contains
- `ExampleService.cs` - Another supporting file
## Pattern Name
**Location**: `Source/Path.cs`
**Purpose**: What this pattern accomplishes
### Code Example
```csharp
// Production-tested code with comments explaining key decisions
public class ExampleClass
{
// Implementation details...
}
Key Points:
## Best Practices
### 1. Be Specific and Prescriptive
**Good:**
```markdown
1. **Version Constraint**: Always use Elasticsearch 5.2 API patterns. This version will not change.
Avoid:
1. Use the appropriate Elasticsearch version for your project.
When Claude needs to execute commands, provide exact syntax:
**ALWAYS use this exact command format:**
```bash
"Y:/CSharpDLLs/Tool/Tool.exe" <command> --solution "<path>" --format console
### 3. Document Parameter Styles and Patterns
For database or API work, clearly document parameter conventions:
```markdown
## Parameter Styles by Database
| Database | Parameter Style | Example |
|----------|----------------|---------|
| DuckDB | `?` placeholders | `WHERE id = ?` |
| PostgreSQL | `$1, $2, $3` | `WHERE id = $1` |
| MySQL | `@parameter` | `WHERE id = @id` |
## Troubleshooting
### "Connection Refused" Error
**Cause:** Server not running
**Solution:**
```bash
cd server-directory
dotnet run
### 5. Reference Supporting Files
If your skill folder contains additional files, reference them explicitly:
```markdown
**Reference Files in This Folder**:
- `Utf8LoggingExtensions.cs` - Complete UTF-8 logger implementation (copy to Services/)
- `ODBC.cs` - ServiceLib ODBC wrapper with ExecuteAndMap pattern
## Quick Reference
| Action | Command | Notes |
|--------|---------|-------|
| Find unused | `unused --solution X` | High confidence = safe |
| Check impact | `impact --method Y` | Shows what would break |
| Find callers | `callers --method Z` | Direct dependencies |
## Real-World Examples
### PriceExtractor
```bash
dotnet run -- --pqdir "R:\Outputs\Parquets\poller" --log-dir "C:\Logs\PriceExtractor"
Creates: C:\Logs\PriceExtractor\PriceExtractor_2025_10_16.log
## Complete Skill Template
```markdown
---
name: My Skill Name
description: One-line description of skill capabilities and use cases
---
# My Skill Name
Brief introduction explaining the skill's purpose and when to use it.
## Instructions
When helping users with [topic], follow these guidelines:
1. **First Principle**: Explanation
2. **Second Principle**: Explanation
3. **Third Principle**: Explanation
## Examples
### Example 1: Common Task
User: Typical user request
Claude: How to approach this:
[Provides implementation using Pattern from reference material below]
### Example 2: Another Task
User: Different request
Claude: Alternative approach...
---
# Reference Implementation Details
The sections below contain proven working code that the examples above reference.
**Reference Files in This Folder**:
- `file1.cs` - Description
- `file2.cs` - Description
## Pattern Name
**Location**: `Path/To/Source.cs`
**Purpose**: What this accomplishes
```csharp
// Production code example
public class Example
{
// Implementation
}
Key Points:
Additional implementation details...
Cause: Why this happens
Solution: How to fix it
## Common Mistakes to Avoid
1. **Missing YAML frontmatter** - Skill won't be recognized without `---` delimiters and required fields
2. **Vague instructions** - "Use appropriate methods" vs "Use HttpClient with POST to /_bulk endpoint"
3. **No examples** - Abstract instructions without concrete user/Claude dialogues
4. **Untested code** - Reference implementations should be production-proven, not theoretical
5. **Missing context** - Not explaining why certain patterns are preferred
6. **No error handling** - Users will hit errors; document common issues and solutions
7. **Outdated references** - Keep file paths and version numbers current
## Testing Your Skill
After creating a skill:
1. Verify the skill appears in the available skills list
2. Test with a request that should trigger the skill
3. Confirm Claude follows the documented patterns
4. Check that example scenarios produce expected outputs
5. Validate reference code still works with current dependencies