WEEK 5 OF 21

Skills: Claude's Auto-Powers

Learning Progress: Week 5 of 21

Welcome to Week 5! This week you'll master Skills - special abilities that Claude automatically decides to use. Unlike commands or agents, you don't invoke skills - Claude does it for you!

LESSON 1

What Are Skills?

A Skill is a special capability that Claude autonomously activates when needed. You describe what you want, and Claude thinks: "I should use this skill for that!"

šŸ§™ā€ā™‚ļø Think of it like this:
You're a wizard, and skills are spells in your spellbook. You don't say "cast fireball spell" - you say "I need to light this campfire" and your magic automatically knows which spell to use. Skills work the same way for Claude!

šŸ”‘ The Key Difference

Skills are MODEL-INVOKED, not user-invoked!

  • Commands: You type /command to run
  • Sub-agents: You (or Claude) explicitly call them
  • Skills: Claude automatically decides to use them
Sub-agents

Separate context window

You can explicitly invoke

Good for complex, multi-step tasks

VS
Skills

Same conversation context

Claude auto-activates

Good for focused capabilities

LESSON 2

Anatomy of a Skill

Every skill needs one required file: SKILL.md. Let's break it down:

Where Skills Live

Folder Structure

# A skill can be simple or complex: # Simple skill (just the required file) my-skill/ └── SKILL.md # Complex skill (with supporting files) advanced-skill/ ā”œā”€ā”€ SKILL.md # Required! ā”œā”€ā”€ reference.md # Extra documentation ā”œā”€ā”€ examples.md # Example usage ā”œā”€ā”€ scripts/ # Utility scripts └── templates/ # Template files

SKILL.md File Format

# Example: .claude/skills/excel-analyzer/SKILL.md --- name: excel-analyzer description: Analyzes Excel spreadsheets, creates pivot tables, generates charts, and provides data insights. Use when working with .xlsx files, spreadsheets, or Excel data analysis tasks. --- You are an Excel data analysis expert. When analyzing spreadsheets: 1. Examine the data structure and types 2. Identify patterns and anomalies 3. Suggest appropriate visualizations 4. Create summary statistics 5. Generate actionable insights Always explain your analysis in plain language.
Field Required? Rules
name Yes Lowercase, hyphens only, max 64 characters
description Yes Max 1024 characters. CRITICAL for discovery!
allowed-tools No Restricts which tools Claude can use
LESSON 3

The Description: Your Secret Weapon

āš ļø SUPER IMPORTANT: The description field is the MOST critical part of your skill! It determines when Claude will automatically activate your skill.

Claude reads the description to decide: "Should I use this skill for what the user wants?" If your description is vague, Claude won't know when to use it!

Bad vs Good Descriptions

āŒ BAD Description
description: Helps with data stuff

Problems:
• Too vague - what is "data stuff"?
• No trigger keywords
• Claude doesn't know when to use it

āœ… GOOD Description
description: Analyzes Excel spreadsheets, creates pivot tables, generates charts, and provides data insights. Use when working with .xlsx files, spreadsheets, Excel data analysis, or CSV data manipulation tasks.

Why it works:
• Lists specific actions (analyze, pivot tables, charts)
• Mentions trigger keywords (Excel, .xlsx, spreadsheets, CSV)
• Clear about when to use it
• Claude knows EXACTLY when to activate

šŸ’” Pro Tip: Think About Trigger Words
What words would someone use when they need your skill?
  • For Excel skill: "spreadsheet", "xlsx", "pivot table", "Excel"
  • For API skill: "REST", "endpoint", "HTTP", "API call"
  • For design skill: "website", "UI", "beautiful", "landing page"
Include these in your description!
LESSON 4

Create Your First Skill!

šŸŽÆ Mission: Create a Git Helper Skill

Let's create a skill that helps write good Git commit messages. Follow along!

Step 1: Create the Folder

# For personal use: $ mkdir -p ~/.claude/skills/commit-helper # OR for project/team use: $ mkdir -p .claude/skills/commit-helper

Step 2: Create SKILL.md

Create the file ~/.claude/skills/commit-helper/SKILL.md:

--- name: commit-helper description: Writes clear, conventional Git commit messages following best practices. Use when committing code, writing commit messages, or following conventional commits format. --- You are a Git commit message expert following Conventional Commits. ## Commit Message Format: ``` type(scope): subject body (optional) footer (optional) ``` ## Types: - **feat**: New feature - **fix**: Bug fix - **docs**: Documentation only - **style**: Code style (formatting, semicolons) - **refactor**: Code refactoring - **test**: Adding tests - **chore**: Maintenance tasks ## Rules: 1. Subject line max 50 characters 2. Use imperative mood ("add" not "added") 3. No period at end of subject 4. Body explains WHY, not just what 5. Reference issues when applicable ## Examples: - feat(auth): add OAuth2 login support - fix(cart): resolve quantity calculation error - docs(readme): update installation instructions

Step 3: Test It!

# Restart Claude Code to load the skill $ claude # Now try it: claude> I just added a login button to the homepage. Can you help me write a commit message? [Claude automatically uses commit-helper skill] Here's a commit message following conventional commits: feat(auth): add login button to homepage Adds a prominent login button in the navigation bar...
šŸŽ‰ Success!

You created a skill! Claude automatically detected you were writing a commit message and activated the commit-helper skill. No special command needed!

LESSON 5

Advanced: Restricting Tools

Sometimes you want to limit what tools Claude can use when a skill is active. This is great for security and focus!

The allowed-tools Field

--- name: code-reader description: Reads and explains code without modifying anything. Use for code review, understanding unfamiliar code, or learning how things work. allowed-tools: Read, Grep, Glob --- You are a code explanation expert. When explaining code: - Read the code carefully - Explain what each part does - Use simple analogies - NEVER suggest modifications You can only READ code, not change it.
šŸ”’ Why Restrict Tools?
  • Security: Prevent accidental modifications
  • Focus: Keep the skill doing one thing well
  • Safety: Some skills should be read-only

Example: Safe Database Query Skill

--- name: db-query-analyzer description: Analyzes SQL queries for performance and security issues. Use when reviewing database queries or optimizing SQL. allowed-tools: Read, Grep --- You analyze SQL queries for: 1. Performance bottlenecks 2. SQL injection vulnerabilities 3. Missing indexes 4. Inefficient joins You can ONLY read and analyze - never execute queries!
āš ļø Important: If you don't specify allowed-tools, the skill can use ALL available tools. Be intentional about this!
LESSON 6

Real-World Skill Examples

Example 1: API Documentation Writer

--- name: api-doc-writer description: Writes comprehensive API documentation including endpoints, parameters, responses, and examples. Use when documenting REST APIs, creating API references, or writing developer documentation. allowed-tools: Read, Write, Glob --- You write API documentation that includes: ## For Each Endpoint: - HTTP method and path - Description of purpose - Request parameters (path, query, body) - Response format with examples - Error codes and messages - Authentication requirements - Rate limiting info Use OpenAPI/Swagger format when appropriate.

Example 2: React Component Creator

--- name: react-component description: Creates React components with TypeScript, proper typing, and best practices. Use when building React components, creating UI elements, or setting up component architecture. --- You create React components following best practices: ## Standards: - Functional components with hooks - TypeScript with proper interfaces - Props destructuring - Meaningful component names - Proper file structure ## Include: - Component file (.tsx) - Types/interfaces - Basic styling approach - Usage example - Unit test skeleton

Example 3: Code Performance Analyzer

--- name: performance-analyzer description: Analyzes code for performance issues and suggests optimizations. Use when code is slow, needs optimization, or you want to improve efficiency. allowed-tools: Read, Grep, Glob --- You identify performance issues like: ## Common Problems: - O(n²) or worse algorithms - Memory leaks - Unnecessary re-renders (React) - Inefficient database queries - Missing caching opportunities - Blocking operations ## Always Provide: - Current Big O complexity - Suggested improvement - Expected performance gain - Code example of fix
LESSON 7

Skill Best Practices

āœ… DO These Things

āŒ DON'T Do These

šŸ’” Debugging Skills:
If your skill isn't activating:
1. Check the description for trigger keywords
2. Verify YAML syntax (proper indentation, no tabs)
3. Confirm file path is correct
4. Run claude --debug to see what's happening
5. Restart Claude Code after changes
šŸ“

Week 3 Key Takeaways

āœ… Skills are model-invoked - Claude decides when to use them

āœ… Every skill needs a SKILL.md file with YAML frontmatter

āœ… Stored in ~/.claude/skills/ or .claude/skills/

āœ… The description field is CRITICAL - include trigger keywords!

āœ… Use allowed-tools to restrict what tools the skill can access

āœ… Keep skills focused on single capabilities

āœ… Restart Claude Code after creating/editing skills

āœ… Test to make sure skills activate as expected

🧠 FINAL KNOWLEDGE CHECK!

Last quiz! Show what you've learned about Skills!

Q1: What makes Skills different from Sub-agents?

Q2: What is the required file for every skill?

Q3: Why is the description field so important?

Q4: What does "allowed-tools: Read, Grep" do?

Q5: Where are personal skills stored?

šŸŽ“ CONGRATULATIONS! šŸŽ“

You've completed all 3 weeks of the Claude Code Learning Path!

Certificate of Completion

This certifies that you have successfully learned:

  • Week 1: Marketplace & Plugins
  • Week 2: Sub-agents
  • Week 3: Skills

You are now a Claude Code Power User!

Now go build amazing things! Create your own plugins, design specialized agents, and develop skills that make you unstoppable! šŸš€