
Analyzing Component Quality
- 1 installs
- 404 repo stars
- Updated August 5, 2026
- aiskillstore/marketplace
analyzing-component-quality is a Claude Code skill that scores the quality of agents, skills, commands, and hooks across clarity, permissions, triggers, security, and usability.
About
analyzing-component-quality is a skill that evaluates the quality of Claude Code components such as agents, skills, commands, and hooks. A developer uses it to score description clarity, tool permissions, auto-invoke triggers, security, and usability, assuming the component is already technically valid. It outputs quality scores, categorized issues, and concrete improvement suggestions.
- Scores Claude Code agents, skills, commands, and hooks across five quality dimensions
- Evaluates description clarity, tool permissions, triggers, security, and usability (1-5 each)
- Read-only tooling (Read, Grep, Glob, Bash) with a bundled quality-scorer script
Analyzing Component Quality by the numbers
- 1 all-time installs (skills.sh)
- Ranked #984 of 1,352 Code Review & Quality skills by installs in the Skillselion catalog
- Data as of Aug 5, 2026 (Skillselion catalog sync)
analyzing-component-quality capabilities & compatibility
Free; uses read-only local tools (Read, Grep, Glob, Bash) with no external service.
- Capabilities
- quality scoring · component review · security review · permission audit
- Use cases
- code review · security audit · documentation
- Pricing
- Free
What analyzing-component-quality says it does
This skill focuses on QUALITY, not correctness.
Whether tool access follows principle of least privilege
npx skills add https://github.com/aiskillstore/marketplace --skill analyzing-component-qualityAdd your badge
Show developers this skill is listed on Skillselion. Paste this into your README.
| Installs | 1 |
|---|---|
| repo stars | ★ 404 |
| Last updated | August 5, 2026 |
| Repository | aiskillstore/marketplace ↗ |
What it does
Score a Claude Code agent or skill on clarity, permissions, triggers, security, and usability and suggest fixes.
Who is it for?
Reviewing Claude Code components before publishing to a marketplace or during component audits.
Skip if: Technical validation of frontmatter or file structure, which it assumes has already passed.
When should I use this skill?
A component is created or enhanced, or the user asks whether an agent or skill is good quality.
What you get
Each component gets per-dimension quality scores, prioritized issues, and concrete before/after fixes.
- Per-dimension quality scores
- Prioritized issue list (Critical/Important/Minor)
- Concrete before/after improvement suggestions
By the numbers
- Five quality dimensions each scored 1-5
- Issues bucketed into Critical, Important, and Minor
Files
Analyzing Component Quality
You are an expert at analyzing the quality and effectiveness of Claude Code plugin components. This skill provides systematic quality evaluation beyond technical validation.
Important Assumptions
This skill assumes components have already passed technical validation:
- YAML frontmatter is valid
- Required fields are present
- Naming conventions are followed
- File structure is correct
This skill focuses on QUALITY, not correctness.
Your Expertise
You specialize in:
- Evaluating description clarity and specificity
- Analyzing tool permission appropriateness
- Assessing auto-invoke trigger effectiveness
- Reviewing security implications
- Measuring usability and developer experience
- Identifying optimization opportunities
When to Use This Skill
Claude should automatically invoke this skill when:
- Agent-builder creates or enhances a component
- User asks "is this agent/skill good quality?"
- Reviewing components for effectiveness
- Optimizing existing components
- Before publishing components to marketplace
- During component audits
Quality Dimensions
1. Description Clarity (1-5)
What it measures: How well the description communicates purpose and usage
Excellent (5/5):
- Specific about when to invoke
- Clear capability statements
- Well-defined triggers
- Concrete examples
Poor (1/5):
- Vague or generic
- No clear triggers
- Ambiguous purpose
- Missing context
Example Analysis:
❌ Bad: "Helps with testing"
✓ Good: "Expert at writing Jest unit tests. Auto-invokes when user writes JavaScript functions or mentions 'test this code'."2. Tool Permissions (1-5)
What it measures: Whether tool access follows principle of least privilege
Excellent (5/5):
- Minimal necessary tools
- Each tool justified
- No dangerous combinations
- Read-only when possible
Poor (1/5):
- Excessive permissions
- Unjustified Write/Bash access
- Security risks
- Overly broad access
Example Analysis:
❌ Bad: allowed-tools: Read, Write, Edit, Bash, Grep, Glob, Task
(Why does a research skill need Write and Bash?)
✓ Good: allowed-tools: Read, Grep, Glob
(Research only needs to read and search)Special Case - Task Tool in Agents:
❌ Critical: Agent with Task tool
(Subagents cannot spawn other subagents - Task won't work)
Fix: Remove Task from agents, or convert to skill if orchestration needed3. Auto-Invoke Triggers (1-5)
What it measures: How effectively the component will activate when needed
Excellent (5/5):
- Specific, unambiguous triggers
- Low false positive rate
- Catches all relevant cases
- Clear boundary conditions
Poor (1/5):
- Too vague to match
- Will trigger incorrectly
- Misses obvious cases
- Conflicting with other components
Example Analysis:
❌ Bad: "Use when user needs help"
(Too vague, when don't they need help?)
✓ Good: "Auto-invokes when user asks 'how does X work?', 'where is Y implemented?', or 'explain the Z component'"
(Specific phrases that clearly indicate intent)4. Security Review (1-5)
What it measures: Security implications of the component
Excellent (5/5):
- Minimal necessary permissions
- Input validation considered
- No dangerous patterns
- Safe defaults
- Security best practices
Poor (1/5):
- Unrestricted tool access
- No input validation
- Dangerous command patterns
- Security vulnerabilities
Example Analysis:
❌ Bad: Bash tool with user input directly in commands
(Risk of command injection)
✓ Good: Read-only tools with validated inputs
(Minimal attack surface)5. Usability (1-5)
What it measures: Developer experience when using the component
Excellent (5/5):
- Clear documentation
- Usage examples
- Helpful error messages
- Good variable naming
- Intuitive behavior
Poor (1/5):
- Confusing documentation
- No examples
- Unclear behavior
- Poor naming
- Unexpected side effects
Example Analysis:
❌ Bad: No examples, unclear parameters
✓ Good: Multiple usage examples, clear parameter descriptionsQuality Analysis Framework
Step 1: Read Component
# Read the component file
Read agent/skill/command file
# Identify component type
- Agent: *.md in agents/
- Skill: SKILL.md in skills/*/
- Command: *.md in commands/
- Hook: hooks.jsonStep 2: Score Each Dimension
Rate 1-5 for each quality dimension:
## Quality Scores
- **Description Clarity**: X/5 - [Specific reason]
- **Tool Permissions**: X/5 - [Specific reason]
- **Auto-Invoke Triggers**: X/5 - [Specific reason] (if applicable)
- **Security**: X/5 - [Specific reason]
- **Usability**: X/5 - [Specific reason]
**Overall Quality**: X.X/5 (average)Step 3: Identify Specific Issues
## Issues Identified
### 🔴 Critical (Must Fix)
- [Issue 1: Description and impact]
- [Issue 2: Description and impact]
### 🟡 Important (Should Fix)
- [Issue 1: Description and impact]
- [Issue 2: Description and impact]
### 🟢 Minor (Nice to Have)
- [Issue 1: Description and impact]Step 4: Provide Concrete Improvements
## Improvement Suggestions
### 1. [Improvement Title]
**Priority**: Critical/Important/Minor
**Current**: [What exists now]
**Suggested**: [What should be instead]
**Why**: [Rationale]
**Impact**: [How this improves quality]
Before:description: Helps with code
After:description: Expert at analyzing code quality using ESLint, Prettier, and static analysis. Auto-invokes when user finishes writing code or asks 'is this code good?'
Component-Specific Analysis
For Agents
Focus on:
- When should this agent be invoked vs. doing inline?
- Are tools appropriate for the agent's mission?
- Does agent have Task tool? (Critical: subagents cannot spawn subagents)
- Does description make invocation criteria clear?
- Is the agent focused enough (single responsibility)?
- If orchestration is needed, should this be a skill instead?
For Skills
Focus on:
- Are auto-invoke triggers specific and unambiguous?
- Will this activate at the right times?
- Is the skill documentation clear about when it activates?
- Does it have appropriate
{baseDir}usage for resources?
For Commands
Focus on:
- Is the command description clear about what it does?
- Are arguments well-documented?
- Is the prompt specific and actionable?
- Does it have clear success criteria?
For Hooks
Focus on:
- Are matchers specific enough?
- Will the hook trigger appropriately?
- Is the hook type (prompt/command) appropriate?
- Are there security implications?
Quality Scoring Guidelines
Overall Quality Interpretation
- 4.5-5.0: Excellent - Ready for marketplace
- 4.0-4.4: Good - Minor improvements recommended
- 3.0-3.9: Adequate - Important improvements needed
- 2.0-2.9: Poor - Significant issues to address
- 1.0-1.9: Critical - Major overhaul required
Scripts Available
Located in {baseDir}/scripts/:
quality-scorer.py
Automated quality scoring based on heuristics:
python {baseDir}/scripts/quality-scorer.py path/to/component.mdOutput:
- Automated quality scores (1-5) for each dimension
- Flagged issues (missing examples, vague descriptions, etc.)
- Comparison to quality standards
effectiveness-analyzer.py
Analyzes how effective the component will be:
python {baseDir}/scripts/effectiveness-analyzer.py path/to/SKILL.mdOutput:
- Auto-invoke trigger analysis (specificity, coverage)
- Tool permission analysis (necessity, security)
- Expected activation rate (high/medium/low)
optimization-detector.py
Identifies optimization opportunities:
python {baseDir}/scripts/optimization-detector.py path/to/componentOutput:
- Suggested simplifications
- Performance considerations
- Resource usage optimization
References Available
Located in {baseDir}/references/:
- quality-standards.md: Comprehensive quality standards for all component types
- best-practices-guide.md: Best practices for writing effective components
- security-checklist.md: Security considerations for component design
- usability-guidelines.md: Guidelines for developer experience
Quality Report Template
# Component Quality Analysis
**Component**: [Name]
**Type**: [Agent/Skill/Command/Hook]
**Location**: [File path]
**Date**: [Analysis date]
## Executive Summary
[1-2 sentence overall assessment]
**Overall Quality Score**: X.X/5 ([Excellent/Good/Adequate/Poor/Critical])
## Quality Scores
| Dimension | Score | Assessment |
|-----------|-------|------------|
| Description Clarity | X/5 | [Brief note] |
| Tool Permissions | X/5 | [Brief note] |
| Auto-Invoke Triggers | X/5 | [Brief note] |
| Security | X/5 | [Brief note] |
| Usability | X/5 | [Brief note] |
## Detailed Analysis
### Description Clarity (X/5)
**Strengths**:
- [What's good]
**Issues**:
- [What needs improvement]
**Recommendation**:
[Specific improvement]
### Tool Permissions (X/5)
**Current Tools**: [List]
**Analysis**:
- [Tool 1]: [Justified/Unnecessary]
- [Tool 2]: [Justified/Unnecessary]
**Recommendation**:
[Suggested tool list with rationale]
### Auto-Invoke Triggers (X/5)
**Current Triggers**:
> [Quote from description]
**Analysis**:
- Specificity: [High/Medium/Low]
- Coverage: [Complete/Partial/Missing]
- False Positive Risk: [Low/Medium/High]
**Recommendation**:
[Improved trigger description]
### Security (X/5)
**Risk Assessment**: [Low/Medium/High]
**Concerns**:
- [Concern 1]
- [Concern 2]
**Recommendation**:
[Security improvements]
### Usability (X/5)
**Developer Experience**:
- Documentation: [Clear/Unclear]
- Examples: [Present/Missing]
- Intuitiveness: [High/Low]
**Recommendation**:
[Usability improvements]
## Issues Summary
### 🔴 Critical Issues
1. [Issue with specific location and fix]
2. [Issue with specific location and fix]
### 🟡 Important Issues
1. [Issue with suggestion]
2. [Issue with suggestion]
### 🟢 Minor Issues
1. [Issue with suggestion]
## Improvement Suggestions
### Priority 1: [Title]
**Current**:[Current content]
**Suggested**:[Improved content]
**Rationale**: [Why this improves quality]
**Impact**: [Expected improvement in score]
### Priority 2: [Title]
[Same format]
## Strengths
- [What this component does well]
- [Good design decisions]
## Recommended Actions
1. [Highest priority action]
2. [Next priority action]
3. [Additional improvements]
## Predicted Impact
If all critical and important issues are addressed:
- **Current Quality**: X.X/5
- **Projected Quality**: X.X/5
- **Improvement**: +X.X points
## Conclusion
[Final assessment and recommendation: approve as-is, improve before use, or significant rework needed]Examples
Example 1: Analyzing a Skill
Input: skills/researching-best-practices/SKILL.md
Analysis:
# Quality Analysis: researching-best-practices
**Overall Quality**: 4.2/5 (Good)
## Quality Scores
- Description Clarity: 5/5 - Excellent, specific triggers
- Tool Permissions: 4/5 - Good, but includes Task unnecessarily
- Auto-Invoke Triggers: 5/5 - Very specific phrases
- Security: 5/5 - Read-only tools, safe
- Usability: 4/5 - Good docs, could use more examples
## Issues Identified
### 🟡 Important
- Includes Task tool but doesn't explain why
- Could benefit from usage examples in description
## Improvement Suggestions
### Remove Task Tool
**Current**: `allowed-tools: Read, Grep, Glob, WebSearch, WebFetch, Task`
**Suggested**: `allowed-tools: Read, Grep, Glob, WebSearch, WebFetch`
**Why**: Skill doesn't need to delegate to agents; it is the expert
**Impact**: Improves security score from 4/5 to 5/5
### Add Usage Example
**Add to description**:Example usage: When user asks "What's the best way to handle errors in React 2025?", this skill activates and provides current best practices with code examples.
**Why**: Helps users understand when and how skill activates
**Impact**: Improves usability from 4/5 to 5/5Example 2: Analyzing an Agent
Input: agents/investigator.md
Analysis:
# Quality Analysis: investigator
**Overall Quality**: 3.8/5 (Adequate)
## Quality Scores
- Description Clarity: 3/5 - Somewhat vague
- Tool Permissions: 3/5 - Includes Task (circular)
- Security: 5/5 - No security concerns
- Usability: 4/5 - Well-documented
## Issues Identified
### 🟡 Important
- Description doesn't clearly state when to invoke agent vs. using skills directly
- Includes Task tool creating potential circular delegation
- Mission statement could be more specific
## Improvement Suggestions
### Clarify Invocation Criteria
**Current**: "Use when you need deep investigation..."
**Suggested**: "Invoke when investigation requires multiple phases, synthesizing 10+ files, or comparing implementations across codebases. For simple 'how does X work' questions, use skills directly."
**Why**: Prevents over-delegation to agent
**Impact**: Improves clarity from 3/5 to 5/5
### Remove Task Tool
**Current**: `tools: Read, Grep, Glob, WebSearch, WebFetch, Task`
**Suggested**: `tools: Read, Grep, Glob, WebSearch, WebFetch`
**Why**: Agents shouldn't delegate to other agents (circular)
**Impact**: Improves tool permissions from 3/5 to 5/5Your Role
When analyzing component quality:
1. Assume validity: Component has passed technical validation 2. Focus on effectiveness: Will this component work well in practice? 3. Be specific: Quote exact issues and provide exact improvements 4. Score objectively: Use the 1-5 scale consistently 5. Prioritize issues: Critical > Important > Minor 6. Provide examples: Show before/after for each suggestion 7. Consider context: Marketplace components need higher standards 8. Think holistically: How does this fit in the ecosystem?
Important Reminders
- Quality ≠ Correctness: Valid components can still be low quality
- Subjective but principled: Use framework consistently
- Constructive feedback: Focus on improvement, not criticism
- Actionable suggestions: Every issue needs a concrete fix
- Context matters: Standards vary by use case (internal vs. marketplace)
- User perspective: Analyze from component user's viewpoint
Your analysis helps create more effective, secure, and usable Claude Code components.
Quality Standards for Claude Code Components
Comprehensive quality standards for agents, skills, commands, and hooks.
General Principles
1. Clarity over Cleverness: Components should be immediately understandable 2. Security by Default: Minimal permissions, validate inputs 3. Single Responsibility: Each component does one thing well 4. User-Centric: Design from the user's perspective 5. Well-Documented: Examples and clear explanations
Quality Dimensions
1. Description Clarity
Excellent (5/5):
- 100+ characters, specific and detailed
- Clear statement of purpose
- Specific auto-invoke triggers (for skills)
- Concrete examples included
- No vague words (helps, manages, handles)
Example:
description: Expert at writing Jest unit tests for JavaScript/TypeScript. Auto-invokes when user writes new functions or classes, or asks "test this code". Generates comprehensive test suites with mocks, assertions, and edge cases following AAA pattern.Poor (1/5):
description: Helps with testingChecklist:
- [ ] Description is 100+ characters
- [ ] Purpose is specific and clear
- [ ] Auto-invoke triggers are explicit (skills only)
- [ ] Includes example use case
- [ ] Avoids vague words
2. Tool Permissions
Excellent (5/5):
- Minimal necessary tools
- Read-only when possible
- Each tool justified
- No dangerous combinations
Tool Guidelines:
| Tool | When Justified | Red Flags |
|---|---|---|
| Read | Almost always needed | - |
| Grep | Searching codebases | Using with Write |
| Glob | Finding files | Using alone without Read |
| Write | Creating new files | Used for editing existing |
| Edit | Modifying files | Used with Bash unsafely |
| Bash | Running commands | With user input, with Write |
| Task | Delegating to agents | In agents (circular), overused |
| WebSearch | Current information | For local codebase |
| WebFetch | Fetching docs | Without WebSearch |
Safe Combinations:
Read, Grep, Glob- Research/analysisRead, Write- File creationRead, Edit- File modificationRead, Grep, Glob, WebSearch, WebFetch- Research with web
Dangerous Combinations:
Bash, Write, Edit- Command injection + file accessBash, Task- Complex delegation chains- All tools - Almost never justified
Checklist:
- [ ] Uses minimal necessary tools
- [ ] No unjustified Bash access
- [ ] No dangerous combinations
- [ ] Each tool has clear purpose
- [ ] Prefers Read over Bash for reading
3. Auto-Invoke Triggers (Skills Only)
Excellent (5/5):
- Specific quoted phrases
- Clear activation criteria
- Low false positive rate
- Comprehensive coverage
Effective Triggers:
Auto-invokes when user asks "how does X work?", "where is Y implemented?",
or "explain the Z component". Also activates when exploring unfamiliar code.Ineffective Triggers:
Use when user needs help understanding codeChecklist:
- [ ] Includes specific quoted phrases
- [ ] Activation criteria are unambiguous
- [ ] Won't trigger on irrelevant queries
- [ ] Covers all intended use cases
- [ ] No overlap with other skills
4. Security
Excellent (5/5):
- Minimal permissions
- Input validation mentioned (if Bash)
- No security vulnerabilities
- Safe defaults
- Follows principle of least privilege
Security Checklist:
- [ ] No unnecessary Bash access
- [ ] Input validation if Bash used
- [ ] No command injection risks
- [ ] No hardcoded secrets
- [ ] Safe file operations
- [ ] No dangerous combinations
Red Flags:
- ❌ Bash with user input without validation
- ❌ Write + Bash combination
- ❌ All tools allowed
- ❌ No mention of input validation with Bash
5. Usability
Excellent (5/5):
- Clear documentation
- Multiple usage examples
- Code examples with explanations
- Helpful error messages
- Intuitive behavior
Documentation Standards:
- Overview section
- Capabilities list
- Usage examples (3+)
- When to use / when not to use
- Integration examples
Checklist:
- [ ] Has overview/introduction
- [ ] Lists capabilities
- [ ] Includes 3+ usage examples
- [ ] Has code examples
- [ ] Explains when to use
- [ ] Clear section structure
- [ ] Uses markdown formatting effectively
Component-Specific Standards
Agents
Required Elements:
---
name: component-name
description: [100+ chars with clear invocation criteria]
tools: [minimal list]
model: sonnet # or haiku for simple tasks
---
# Agent Name
Clear mission statement and capabilities.
## When to Invoke This Agent
[Specific criteria - when to use agent vs. skills directly]
## Capabilities
- [Capability 1]
- [Capability 2]
## Examples
### Example 1: [Scenario]
[Usage example]Quality Standards:
- Description clarifies when to invoke vs. using skills
- Tools list excludes Task (no circular delegation)
- Model choice is appropriate (haiku for simple, sonnet for complex)
- Examples show clear value proposition
Skills
Required Elements:
---
name: skill-name
description: [150+ chars with specific auto-invoke triggers]
version: 1.0.0
allowed-tools: [minimal list]
---
# Skill Name
Detailed explanation of skill's expertise.
## When to Use This Skill
[Auto-invoke triggers - must be specific]
## Capabilities
[Detailed list]
## Resources Available
Scripts in {baseDir}/scripts/:
- script-name.py: [description]
References in {baseDir}/references/:
- reference.md: [description]
## Examples
[Multiple usage examples]Quality Standards:
- Auto-invoke triggers are specific and quoted
- Uses
{baseDir}for resource references - Has scripts/references/assets directories if needed
- Examples demonstrate auto-activation
- Version follows semver
Commands
Required Elements:
---
description: [Clear one-line description of what command does]
allowed-tools: [minimal list]
argument-hint: "[arg1] [arg2]" # optional
model: haiku # or sonnet if complex
---
# Command Documentation
What this command does and why to use it.
## Usage
/command-name arg1 arg2
## Examples
### Example 1: [Scenario]/command-name example-arg
[What happens]
## Arguments
- $1: [description]
- $2: [description]Quality Standards:
- Description is clear and action-oriented
- Argument hint matches actual arguments used
- Model choice is appropriate
- Examples show real-world usage
- Explains output/result
Hooks
Required Elements:
{
"hooks": [
{
"name": "descriptive-name",
"event": "PreToolUse|PostToolUse|UserPromptSubmit",
"matchers": {
"toolName": "ToolName",
"toolParameters": { "param": "pattern" }
},
"type": "prompt|command",
"prompt": "Clear instruction" // or "command": "script.sh"
}
]
}Quality Standards:
- Matchers are specific (not overly broad)
- Hook name clearly indicates purpose
- Type choice is appropriate (prompt for guidance, command for validation)
- No security risks in commands
- Clear purpose and benefit
Quality Scoring
Overall Quality Levels
5.0 - Excellent: Marketplace-ready, best practices throughout 4.5 - Very Good: Minor improvements would help 4.0 - Good: Solid component, some enhancements recommended 3.5 - Adequate: Works but important improvements needed 3.0 - Fair: Significant issues to address 2.5 - Poor: Major problems, not recommended for use 2.0 - Very Poor: Substantial rework required 1.0 - Critical: Unusable in current state
Dimension Scoring
Each dimension (Description, Tools, Triggers, Security, Usability) scored 1-5:
5/5: Exemplary, no improvements needed 4/5: Good, minor improvements possible 3/5: Adequate, important improvements recommended 2/5: Poor, significant issues 1/5: Critical problems
Common Issues and Fixes
Issue: Vague Description
Bad:
description: Helps with code qualityGood:
description: Expert at analyzing code quality using ESLint, Prettier, and static analysis. Auto-invokes when user finishes writing code or asks "is this code good?" Provides actionable improvement suggestions.Issue: Excessive Tools
Bad:
allowed-tools: Read, Write, Edit, Bash, Grep, Glob, Task, WebSearch, WebFetchGood:
allowed-tools: Read, Grep, Glob # Research skill only needs to read and searchIssue: Vague Triggers
Bad:
description: Use when user needs testing helpGood:
description: Auto-invokes when user writes new functions or asks "test this code", "write tests", or "add unit tests"Issue: Security Risk
Bad:
allowed-tools: Bash, Write
# No input validation mentionedGood:
allowed-tools: Read, Grep
# Or if Bash needed:
# Validates all user input before execution. Never directly interpolates user input into bash commands.Issue: Poor Documentation
Bad:
# My Skill
This skill does things.Good:
# My Skill
Expert at analyzing code patterns and identifying design patterns.
## Capabilities
- Gang of Four pattern recognition
- Architectural pattern analysis
- Anti-pattern detection
- Code duplication analysis
## When to Use This Skill
Auto-invokes when user asks "what patterns are used?", "find repeated code",
or "analyze the architecture"
## Examples
### Example 1: Finding Design PatternsUser: "What design patterns are in this codebase?" Skill activates → Searches for Factory, Singleton, Observer patterns → Reports findings
[More examples...]Review Checklist
Before publishing or using a component:
All Components
- [ ] Name follows lowercase-hyphen convention
- [ ] Description is 100+ characters
- [ ] Description is specific, not vague
- [ ] Tools are minimal and justified
- [ ] No security vulnerabilities
- [ ] Documentation is comprehensive
- [ ] Examples are included
- [ ] Version follows semver (skills/agents)
Skills Specifically
- [ ] Auto-invoke triggers are specific
- [ ] Triggers include quoted phrases
- [ ] Uses {baseDir} for resources
- [ ] Has appropriate directories (scripts/references/assets)
Agents Specifically
- [ ] Clarifies when to invoke vs. using skills
- [ ] No Task tool (no circular delegation)
- [ ] Model choice is appropriate
- [ ] Clear value proposition
Commands Specifically
- [ ] argument-hint matches usage
- [ ] Uses $ARGUMENTS or $1, $2 correctly
- [ ] Clear examples provided
- [ ] Model choice is appropriate
Hooks Specifically
- [ ] Matchers are specific, not overly broad
- [ ] No security risks in commands
- [ ] Clear purpose documented
- [ ] Event type is appropriate
Marketplace Standards
Components intended for marketplace should meet higher standards:
Minimum Requirements:
- Overall quality score: 4.0+
- No critical security issues
- Comprehensive documentation
- Multiple examples
- Clear use cases
Recommended:
- Overall quality score: 4.5+
- All dimensions score 4+
- README with screenshots/demos
- Test coverage for scripts
- Contribution guidelines
References
- Claude Code Plugin Documentation
- Security Best Practices
- Usability Guidelines
#!/usr/bin/env python3
"""
Quality Scorer for Claude Code Components
Provides automated quality scoring based on heuristics.
Analyzes description clarity, tool permissions, security, and usability.
"""
import sys
import re
import yaml
from pathlib import Path
from typing import Dict, List, Tuple
# Orchestrator agents are permitted to have the Task tool for delegation
# These agents coordinate work across other specialized agents
ORCHESTRATOR_AGENTS = ['project-coordinator', 'investigator', 'workflow-orchestrator']
def extract_frontmatter(file_path: Path) -> Dict:
"""Extract YAML frontmatter from markdown file."""
with open(file_path, 'r', encoding='utf-8') as f:
content = f.read()
# Extract frontmatter between --- markers
match = re.match(r'^---\s*\n(.*?)\n---\s*\n', content, re.DOTALL)
if not match:
return {}
try:
return yaml.safe_load(match.group(1))
except yaml.YAMLError as e:
print(f"Error parsing YAML: {e}", file=sys.stderr)
return {}
def score_description_clarity(frontmatter: Dict, content: str, component_type: str) -> Tuple[int, List[str]]:
"""Score description clarity (1-5)."""
score = 5
issues = []
description = frontmatter.get('description', '')
# Check description length
if len(description) < 50:
score -= 2
issues.append("Description too short (< 50 chars)")
elif len(description) < 100:
score -= 1
issues.append("Description could be more detailed (< 100 chars)")
# Check for vague words
vague_words = ['helps', 'manages', 'handles', 'does', 'works with']
if any(word in description.lower() for word in vague_words):
score -= 1
issues.append("Description contains vague words (helps, manages, etc.)")
# For skills, check for auto-invoke triggers
if component_type == 'skill':
trigger_phrases = ['auto-invokes when', 'automatically activated when', 'use when']
if not any(phrase in description.lower() for phrase in trigger_phrases):
score -= 1
issues.append("Skill description missing auto-invoke trigger specification")
# Check for specific examples or use cases
if 'e.g.' not in description and 'example' not in description.lower():
score -= 1
issues.append("No examples in description")
return max(1, score), issues
def score_tool_permissions(frontmatter: Dict, component_type: str) -> Tuple[int, List[str]]:
"""Score tool permissions (1-5)."""
score = 5
issues = []
allowed_tools = frontmatter.get('allowed-tools', frontmatter.get('tools', []))
# Convert to list if string
if isinstance(allowed_tools, str):
allowed_tools = [t.strip() for t in allowed_tools.split(',')]
if not allowed_tools:
return 5, [] # No tools specified (acceptable for some components)
# Count dangerous tools
dangerous_tools = ['Bash', 'Write', 'Edit']
has_dangerous = [t for t in allowed_tools if t in dangerous_tools]
if has_dangerous:
score -= 1
issues.append(f"Has elevated permissions: {', '.join(has_dangerous)} (ensure justified)")
# Check for overly permissive (too many tools)
if len(allowed_tools) > 6:
score -= 1
issues.append(f"Many tools specified ({len(allowed_tools)}), ensure all are necessary")
# Check for Task tool in agents (circular delegation risk)
# Orchestrator agents are exempt - they need Task tool for delegation
if component_type == 'agent' and 'Task' in allowed_tools:
agent_name = frontmatter.get('name', '')
if agent_name not in ORCHESTRATOR_AGENTS:
score -= 1
issues.append("Agent has Task tool (potential circular delegation)")
else:
issues.append("✓ Orchestrator agent: Task tool permitted for delegation")
# Check for unnecessary Write with no Edit
if 'Write' in allowed_tools and 'Edit' not in allowed_tools:
issues.append("Has Write but not Edit (intentional? Edit is often better)")
return max(1, score), issues
def score_auto_invoke_triggers(frontmatter: Dict, content: str) -> Tuple[int, List[str]]:
"""Score auto-invoke trigger quality (1-5) for skills."""
score = 5
issues = []
description = frontmatter.get('description', '')
# Check if triggers are specified
trigger_phrases = ['auto-invokes when', 'automatically activated when']
has_triggers = any(phrase in description.lower() for phrase in trigger_phrases)
if not has_triggers:
score -= 2
issues.append("No clear auto-invoke triggers specified in description")
return max(1, score), issues
# Check for specific quoted examples
if '"' not in description and "'" not in description:
score -= 1
issues.append("No specific trigger phrases quoted (e.g., 'how does X work?')")
# Check for vague triggers
vague_triggers = ['when user needs help', 'when appropriate', 'when necessary']
if any(vague in description.lower() for vague in vague_triggers):
score -= 2
issues.append("Triggers are too vague")
return max(1, score), issues
def score_security(frontmatter: Dict, content: str) -> Tuple[int, List[str]]:
"""Score security considerations (1-5)."""
score = 5
issues = []
allowed_tools = frontmatter.get('allowed-tools', frontmatter.get('tools', []))
if isinstance(allowed_tools, str):
allowed_tools = [t.strip() for t in allowed_tools.split(',')]
# High risk: Bash with Write/Edit
if 'Bash' in allowed_tools and ('Write' in allowed_tools or 'Edit' in allowed_tools):
score -= 2
issues.append("SECURITY RISK: Bash + Write/Edit combination (command injection risk)")
# Medium risk: Bash alone
elif 'Bash' in allowed_tools:
score -= 1
issues.append("Bash tool present (ensure input validation)")
# Check for input validation mentions in content
if 'Bash' in allowed_tools:
if 'validate' not in content.lower() and 'sanitize' not in content.lower():
score -= 1
issues.append("Bash tool used but no mention of input validation")
# Check for security best practices mention
if 'security' in content.lower() or 'validate' in content.lower():
issues.append("✓ Security considerations mentioned")
return max(1, score), issues
def score_usability(frontmatter: Dict, content: str) -> Tuple[int, List[str]]:
"""Score usability and developer experience (1-5)."""
score = 5
issues = []
# Check for examples in content
if '```' not in content:
score -= 1
issues.append("No code examples in documentation")
# Check for usage section
if '## usage' not in content.lower() and '## example' not in content.lower():
score -= 1
issues.append("No usage or examples section")
# Check for explanation of capabilities
if '## capabilities' not in content.lower() and '## features' not in content.lower():
issues.append("Consider adding capabilities/features section")
# Check content length (documentation quality)
lines = content.split('\n')
doc_lines = [l for l in lines if l.strip() and not l.strip().startswith('#')]
if len(doc_lines) < 20:
score -= 1
issues.append("Sparse documentation (< 20 lines of content)")
return max(1, score), issues
def determine_component_type(file_path: Path) -> str:
"""Determine component type from file path."""
# Normalize path separators for cross-platform compatibility
path_str = str(file_path).replace('\\', '/')
if '/agents/' in path_str:
return 'agent'
elif '/skills/' in path_str and file_path.name == 'SKILL.md':
return 'skill'
elif '/commands/' in path_str:
return 'command'
elif file_path.name == 'hooks.json':
return 'hook'
else:
return 'unknown'
def analyze_component(file_path: Path) -> Dict:
"""Analyze component and return quality scores."""
component_type = determine_component_type(file_path)
if component_type == 'hook':
print("Hook analysis not yet implemented", file=sys.stderr)
return {}
frontmatter = extract_frontmatter(file_path)
with open(file_path, 'r', encoding='utf-8') as f:
content = f.read()
# Score each dimension
desc_score, desc_issues = score_description_clarity(frontmatter, content, component_type)
tool_score, tool_issues = score_tool_permissions(frontmatter, component_type)
security_score, security_issues = score_security(frontmatter, content)
usability_score, usability_issues = score_usability(frontmatter, content)
# Auto-invoke only for skills
if component_type == 'skill':
trigger_score, trigger_issues = score_auto_invoke_triggers(frontmatter, content)
else:
trigger_score, trigger_issues = None, []
# Calculate overall score
scores = [desc_score, tool_score, security_score, usability_score]
if trigger_score is not None:
scores.append(trigger_score)
overall_score = sum(scores) / len(scores)
return {
'component_type': component_type,
'component_name': frontmatter.get('name', file_path.stem),
'overall_score': overall_score,
'scores': {
'description_clarity': desc_score,
'tool_permissions': tool_score,
'auto_invoke_triggers': trigger_score,
'security': security_score,
'usability': usability_score
},
'issues': {
'description_clarity': desc_issues,
'tool_permissions': tool_issues,
'auto_invoke_triggers': trigger_issues,
'security': security_issues,
'usability': usability_issues
}
}
def format_report(analysis: Dict) -> str:
"""Format analysis results as a readable report."""
report = []
report.append("=" * 60)
report.append(f"Component Quality Analysis")
report.append("=" * 60)
report.append(f"Component: {analysis['component_name']}")
report.append(f"Type: {analysis['component_type']}")
report.append(f"Overall Quality: {analysis['overall_score']:.1f}/5.0")
report.append("")
# Determine quality level
score = analysis['overall_score']
if score >= 4.5:
quality_level = "Excellent ✅"
elif score >= 4.0:
quality_level = "Good ✓"
elif score >= 3.0:
quality_level = "Adequate ⚠"
elif score >= 2.0:
quality_level = "Poor ⚠⚠"
else:
quality_level = "Critical ❌"
report.append(f"Quality Level: {quality_level}")
report.append("")
report.append("-" * 60)
report.append("Quality Scores")
report.append("-" * 60)
scores = analysis['scores']
for dimension, score in scores.items():
if score is not None:
dimension_name = dimension.replace('_', ' ').title()
report.append(f"{dimension_name:.<40} {score}/5")
report.append("")
report.append("-" * 60)
report.append("Issues Identified")
report.append("-" * 60)
issues = analysis['issues']
has_issues = False
for dimension, issue_list in issues.items():
if issue_list:
has_issues = True
dimension_name = dimension.replace('_', ' ').title()
report.append(f"\n{dimension_name}:")
for issue in issue_list:
if issue.startswith('✓'):
report.append(f" {issue}")
elif issue.startswith('SECURITY'):
report.append(f" 🔴 {issue}")
else:
report.append(f" • {issue}")
if not has_issues:
report.append("\nNo issues identified! ✅")
report.append("")
report.append("=" * 60)
return '\n'.join(report)
def main():
if len(sys.argv) < 2:
print("Usage: python quality-scorer.py <component-file>", file=sys.stderr)
print(" component-file: Path to agent, skill, or command markdown file", file=sys.stderr)
sys.exit(1)
file_path = Path(sys.argv[1])
if not file_path.exists():
print(f"Error: File not found: {file_path}", file=sys.stderr)
sys.exit(1)
try:
analysis = analyze_component(file_path)
report = format_report(analysis)
print(report)
# Exit code based on quality
if analysis['overall_score'] < 3.0:
sys.exit(2) # Quality too low
elif analysis['overall_score'] < 4.0:
sys.exit(1) # Quality adequate but has issues
else:
sys.exit(0) # Quality good
except Exception as e:
print(f"Error analyzing component: {e}", file=sys.stderr)
import traceback
traceback.print_exc()
sys.exit(3)
if __name__ == '__main__':
main()
{
"schema_version": "2.0",
"meta": {
"generated_at": "2026-01-16T19:29:21.310Z",
"slug": "c0ntr0lledcha0s-analyzing-component-quality",
"source_url": "https://github.com/C0ntr0lledCha0s/claude-code-plugin-automations/tree/main/self-improvement/skills/analyzing-component-quality",
"source_ref": "main",
"model": "claude",
"analysis_version": "3.0.0",
"source_type": "community",
"content_hash": "9e7b5c2dfc3a7cea6e7fb78131f960fb9aa6ee3ff5c705e66620332dccb0865c",
"tree_hash": "dbdab96da8334272f3484ae40c29e2b49dbfa0036e45b2fd0565c0b9ceb4bd5f"
},
"skill": {
"name": "analyzing-component-quality",
"description": "Expert at analyzing the quality and effectiveness of Claude Code components (agents, skills, commands, hooks). Assumes component is already technically valid. Evaluates description clarity, tool permissions, auto-invoke triggers, security, and usability to provide quality scores and improvement suggestions.",
"summary": "Expert at analyzing the quality and effectiveness of Claude Code components (agents, skills, command...",
"icon": "📊",
"version": "1.0.0",
"author": "C0ntr0lledCha0s",
"license": "MIT",
"category": "development",
"tags": [
"quality",
"analysis",
"plugin",
"audit",
"components"
],
"supported_tools": [
"claude",
"codex",
"claude-code"
],
"risk_factors": [
"filesystem",
"scripts"
]
},
"security_audit": {
"risk_level": "low",
"is_blocked": false,
"safe_to_publish": true,
"summary": "All 234 static findings are FALSE POSITIVES. The scanner incorrectly flagged documentation examples (YAML frontmatter with allowed-tools including Bash), educational security discussions, and security warning strings as actual security threats. The skill is a pure quality analysis tool with Read-only tool access. The quality-scorer.py script only reads local files for heuristic analysis and outputs text reports. No network operations, no external command execution, no credential access.",
"risk_factor_evidence": [
{
"factor": "filesystem",
"evidence": [
{
"file": "scripts/quality-scorer.py",
"line_start": 21,
"line_end": 33
},
{
"file": "scripts/quality-scorer.py",
"line_start": 228,
"line_end": 229
}
]
},
{
"factor": "scripts",
"evidence": [
{
"file": "scripts/quality-scorer.py",
"line_start": 1,
"line_end": 368
}
]
}
],
"critical_findings": [],
"high_findings": [],
"medium_findings": [],
"low_findings": [],
"dangerous_patterns": [],
"files_scanned": 4,
"total_lines": 1665,
"audit_model": "claude",
"audited_at": "2026-01-16T19:29:21.310Z"
},
"content": {
"user_title": "Analyze Claude Code component quality",
"value_statement": "Claude Code components can have technical issues or poor design that impacts effectiveness. This skill provides systematic quality evaluation including description clarity, tool permissions, security posture, and usability to help developers improve their plugins before publishing.",
"seo_keywords": [
"Claude Code component quality",
"skill analysis",
"Claude Code plugin audit",
"component quality scoring",
"Claude Code best practices",
"plugin quality assessment",
"Claude Codex skill evaluation",
"analyze agent quality",
"skill review automation",
"plugin marketplace quality"
],
"actual_capabilities": [
"Scores description clarity on 1-5 scale with specific examples",
"Evaluates tool permission appropriateness and security risks",
"Analyzes auto-invoke trigger specificity for skills",
"Measures documentation quality and developer experience",
"Provides concrete improvement suggestions with before/after examples",
"Runs automated quality scoring via quality-scorer.py script"
],
"limitations": [
"Does not perform technical validation (assumes component already validates)",
"Does not modify components automatically",
"Does not test components in actual Claude Code sessions",
"Does not evaluate runtime performance or memory usage"
],
"use_cases": [
{
"target_user": "Plugin developers",
"title": "Pre-publish quality check",
"description": "Review components for marketplace readiness before publishing"
},
{
"target_user": "Quality auditors",
"title": "Component quality audits",
"description": "Systematically evaluate existing components against quality standards"
},
{
"target_user": "Plugin maintainers",
"title": "Identify improvement areas",
"description": "Find specific issues and get concrete suggestions for improving components"
}
],
"prompt_templates": [
{
"title": "Quick quality check",
"scenario": "Analyze a single component",
"prompt": "Analyze the quality of the component at self-improvement/skills/analyzing-response-quality/SKILL.md and provide overall score and improvement suggestions"
},
{
"title": "Security review",
"scenario": "Check security posture",
"prompt": "Review this agent for security issues: read agents/investigator.md and score its security dimension, flagging any risky tool combinations or vulnerabilities"
},
{
"title": "Full audit",
"scenario": "Comprehensive component review",
"prompt": "Perform a complete quality audit of the testing-expert plugin. Analyze all agents, skills, and commands against the quality standards and provide priority-ordered improvement list"
},
{
"title": "Tool permissions",
"scenario": "Evaluate permissions",
"prompt": "Analyze tool permissions across all components in github-workflows/. Are permissions minimal and justified? Flag any dangerous combinations like Bash+Write+Edit"
}
],
"output_examples": [
{
"input": "Analyze the quality of agents/code-reviewer.md",
"output": [
"Overall Quality: 4.2/5 (Good)",
"Description Clarity: 5/5 - Excellent, specific triggers",
"Tool Permissions: 4/5 - Good, but includes Task unnecessarily",
"Security: 5/5 - Read-only tools, safe",
"Usability: 3/5 - Could use more examples",
"Priority Fix: Remove Task tool from agent to prevent circular delegation"
]
},
{
"input": "Is this skill ready for marketplace?",
"output": [
"Scores below 4.0 should be improved before publication",
"Key issues found: description under 100 chars, no auto-invoke triggers, no code examples",
"Suggested fixes provided in the improvement section"
]
}
],
"best_practices": [
"Review quality scores before publishing components to marketplace",
"Focus on specific auto-invoke triggers for skills rather than vague descriptions",
"Use minimal necessary tools and avoid dangerous combinations like Bash+Write",
"Include concrete examples in component documentation for better usability"
],
"anti_patterns": [
"Using vague descriptions like helps with code without specific triggers",
"Including Task tool in non-orchestrator agents (causes circular delegation)",
"Having Bash tool without mentioning input validation",
"Publishing components without testing auto-invoke trigger specificity"
],
"faq": [
{
"question": "Does this skill modify my components?",
"answer": "No. This skill only analyzes and reports quality scores. All modifications are manual."
},
{
"question": "What quality dimensions does it analyze?",
"answer": "Five dimensions: description clarity, tool permissions, auto-invoke triggers, security, and usability."
},
{
"question": "Can I use this for marketplace components?",
"answer": "Yes. Components scoring below 4.0 should be improved before marketplace publication."
},
{
"question": "Is my data safe with this skill?",
"answer": "Yes. The skill only reads files for analysis. No data is transmitted externally."
},
{
"question": "What is the minimum passing score?",
"answer": "Components should score 4.0+ for marketplace. Below 3.0 indicates significant issues needing attention."
},
{
"question": "How does this differ from the validation skill?",
"answer": "Validation checks technical correctness (YAML, naming, structure). This skill evaluates quality (clarity, usability, effectiveness)."
}
]
},
"file_structure": [
{
"name": "references",
"type": "dir",
"path": "references",
"children": [
{
"name": "quality-standards.md",
"type": "file",
"path": "references/quality-standards.md",
"lines": 481
}
]
},
{
"name": "scripts",
"type": "dir",
"path": "scripts",
"children": [
{
"name": "quality-scorer.py",
"type": "file",
"path": "scripts/quality-scorer.py",
"lines": 368
}
]
},
{
"name": "SKILL.md",
"type": "file",
"path": "SKILL.md",
"lines": 582
}
]
}
Related skills
FAQ
What does it score?
Five dimensions rated 1-5: description clarity, tool permissions, auto-invoke triggers, security, and usability.
Does it check if the component is valid?
No, it assumes technical validation already passed and focuses only on quality.