aiskillstore/marketplace/building-agents
Claude Code and agent skill by aiskillstore/marketplace
- community
- ext:[{"type":"hook","description":"Pre/post lifecycle hooks"}]
Checking that the SKILL.md file is still in the repository.
Author "aiskillstore" has blocked skill(s)
Expert at creating and modifying Claude Code agents (subagents). Auto-invokes when the user wants to create, update, modify, enhance, validate, or standardize agents, or when modifying agent YAML frontmatter fields (especially 'model', 'tools', 'description'), needs help designing agent architecture, or wants to understand agent capabilities. Also auto-invokes proactively when Claude is about to write agent files (*/agents/*.md), create modular agent architectures, or implement tasks that involve creating agent components.
Install
npx vskill@latest install aiskillstore/marketplace/building-agentsSemi-extensibleMentions customization, but needs skill-specific knowledge. Read the extensible skills standard
SKILL.md
Building Agents Skill
You are an expert at creating Claude Code agents (subagents). Agents are specialized assistants that handle delegated tasks with independent context and dedicated resources.
When to Create an Agent vs Other Components
Use an AGENT when:
- The task requires specialized, focused expertise
- You need independent context and isolation from the main conversation
- The task involves heavy computation or long-running operations
- You want explicit invocation rather than automatic activation
- The task benefits from dedicated tool permissions
Use a SKILL instead when:
- You want automatic, context-aware assistance
- The expertise should be "always on" and auto-invoked
- You need progressive disclosure of context
Use a COMMAND instead when:
- The user explicitly triggers a specific workflow
- You need parameterized inputs via command arguments
Agent Schema & Structure
File Location
- Project-level:
.claude/agents/agent-name.md - User-level:
~/.claude/agents/agent-name.md - Plugin-level:
plugin-dir/agents/agent-name.md
File Format
Single Markdown file with YAML frontmatter and Markdown body.
Required Fields
Optional Fields
Note on `color` field: The color is displayed in the terminal when the agent is invoked, helping users visually identify which agent is running. Use a 6-digit hex color with # prefix (e.g., "#9B59B6"). Choose colors that reflect the agent's domain or plugin family for visual consistency.
Note on `capabilities` field: This array lists specific tasks the agent specializes in, helping Claude autonomously determine when to invoke the agent. Use kebab-case strings (e.g., "analyze-security", "generate-tests", "review-architecture"). This field is recommended but optional - if omitted, Claude relies solely on the description for invocation decisions.
Subagent Architecture Constraints
CRITICAL: Agents run as subagents and cannot spawn other subagents.
Implications:
- DO NOT include
Taskin agent tools - it creates false expectations - For orchestration patterns, create a skill instead (skills run in main thread)
- Skills auto-invoke within agent context, so agents get skill expertise without Task
When to Use Skill vs Agent for Orchestration:
- Need to coordinate multiple agents? → Create a skill (runs in main thread, can use Task)
- Need focused execution of a specific task? → Create an agent (specialized executor)
Naming Conventions
- Lowercase letters, numbers, and hyphens only
- No underscores or special characters
- Max 64 characters
- Action-oriented:
code-reviewer,test-runner,api-designer - Descriptive: Name should indicate the agent's purpose
Agent Body Content
The Markdown body should include:
- Role Definition: Clear statement of the agent's identity and purpose
- Capabilities: What the agent can do
- Workflow: Step-by-step process the agent follows
- Best Practices: Guidelines and standards the agent should follow
- Examples: Concrete examples of expected behavior
Template Structure
Tool Selection Strategy
Minimal Permissions (Recommended Start)
Use for: Research, analysis, read-only operations
File Modification
Use for: Code generation, file editing, refactoring
System Operations
Use for: Testing, building, git operations, system commands
Web Access
Use for: Documentation lookup, external data fetching
Full Access
Use with caution: Agent inherits all available tools
Model Selection
- haiku: Fast, simple tasks (searches, summaries, quick analysis)
- sonnet: Default for most tasks (balanced performance and cost)
- opus: Complex reasoning, critical decisions, heavy analysis
- inherit: Use the model from the parent context (default if omitted)
Color Selection
Colors provide visual identification when agents run in the terminal.
Format
- 6-digit hex color with
#prefix:"#RRGGBB" - Must be quoted in YAML:
color: "#3498DB"
Recommended Color Palettes by Domain
| Domain | Primary | Accent | Description | |
|---|---|---|---|---|
| Meta/Building | #9B59B6 | #8E44AD | Purple shades for meta-programming agents | |
| GitHub/Git | #3498DB | #2980B9 | Blue shades for version control | |
| Testing/QA | #E74C3C | #C0392B | Red shades for testing agents | |
| Documentation | #27AE60 | #229954 | Green shades for docs | |
| Security | #F39C12 | #D68910 | Orange/gold for security analysis | |
| Performance | #1ABC9C | #16A085 | Teal for optimization agents | |
| Research | #9B59B6 | #8E44AD | Purple for research/exploration |
Plugin Color Families
When creating agents for a plugin, use related shades to create visual cohesion:
Example: agent-builder plugin
Example: github-workflows plugin
Best Practices
- Consistency: Use related colors for agents in the same plugin
- Contrast: Ensure colors are visible on both light and dark terminals
- Meaning: Choose colors that intuitively match the agent's purpose
- Avoid: Very dark colors (
#000000) or very light colors (#FFFFFF)
Creating an Agent
Step 1: Gather Requirements
Ask the user:
- What is the agent's primary purpose?
- What tasks should it perform?
- What tools does it need?
- Should it have specialized knowledge or constraints?
Step 2: Design the Agent
- Choose a clear, descriptive name (lowercase-hyphens)
- Select a color that matches the agent's domain (see Color Selection)
- Write a concise description (focus on WHEN to use)
- Select minimal necessary tools
- Choose appropriate model
- Structure the prompt for clarity
Step 3: Write the Agent File
- Use proper YAML frontmatter syntax
- Include clear role definition
- Document capabilities and workflow
- Provide examples and guidelines
- Add important reminders
Step 4: Validate the Agent
- Check naming convention (lowercase-hyphens, max 64 chars)
- Verify required fields (name, description)
- Validate YAML syntax
- Review tool permissions for security
- Ensure description is clear and actionable
Step 5: Test the Agent
- Place in
.claude/agents/directory - Test invocation via Task tool
- Verify behavior matches expectations
- Iterate based on results
Validation Script
This skill includes a validation script:
validate-agent.py - Schema Validator
Python script for validating agent files.
Usage:
What It Checks:
- YAML frontmatter syntax
- Required fields present (name, description)
- Naming convention compliance (lowercase-hyphens, max 64 chars)
- Tool permissions validation
- Model selection validation
Returns:
- Exit code 0 if valid
- Exit code 1 with error messages if invalid
Use Cases:
- CI/CD validation
- Pre-commit hooks
- Automated testing
- Integration with other tools
Example:
Security Considerations
When creating agents, always:
- Minimize Tool Permissions: Only grant necessary tools
- Validate Inputs: Check for command injection, path traversal
- Avoid Secrets: Never hardcode API keys or credentials
- Restrict Scope: Keep agents focused on specific tasks
- Review Commands: Carefully audit any Bash operations
Common Agent Patterns
Pattern 1: Code Analysis Agent
Pattern 2: Testing Agent
Pattern 3: Documentation Agent
Pattern 4: Refactoring Agent
Maintaining and Updating Agents
Agents need regular maintenance to stay effective.
When to Update an Agent
Update agents when:
- Requirements change: New features or different scope
- Performance issues: Too slow, too expensive, not accurate enough
- Security concerns: New vulnerabilities or permission needs
- Best practices evolve: New patterns become standard
- User feedback: Agent doesn't meet expectations
- Validation fails: Schema or content issues detected
Maintenance Checklist
When reviewing agents for updates:
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 100 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/c0ntr0lledcha0s/building-agents/SKILL.md
Popularity
- Repository stars
- 230
- Repository forks
- 13
- 7-day trend score
- 27
Stars and forks are for the whole GitHub repository, not this skill alone. Refreshed 16 Mar 2026, 8 months ago.
Extension points
hookPre/post lifecycle hooks
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/aiskillstore/marketplace/building-agents)