Skill Quality Analyzer
Comprehensive quality analysis system for Codex skills using a 6-dimension scoring framework inspired by CodeDNA. Identifies quality issues, provides improvement recommendations, and generates detailed quality reports.
Agent Workflow
To perform a high-quality analysis, follow this Hybrid Workflow:
- Run Static Analysis: Execute
python3 analyzer.py --skill-path [TARGET_SKILL_PATH] to get objective metrics for the target skill.
- Read Target Skill Content: Use
view_file to read the SKILL.md and HOW_TO_USE.md of the skill you are analyzing (the target skill). Do not read this analyzer skill's own files.
- Synthesize Report: Combine the script's findings (hard metrics) with your manual review of the target skill's content (soft metrics) to generate the final report.
- Script says: "Description too short." -> You check: "Is it just short, or is it actual nonsense?"
- Script says: "100/100 score." -> You check: "Format is perfect, but does the logic make sense?"
Capabilities
- 6-Dimension Quality Scoring: Evaluates skills across Clarity, Structure, Examples, Trigger Detection, Best Practices, and Maintainability (0-100 scale)
- Automated Issue Detection: Identifies common problems like missing examples, unclear descriptions, poor structure, and missing trigger words
- Improvement Recommendations: Provides specific, actionable suggestions for each quality dimension
- Comparative Analysis: Compares skills against best practices from official Antigravity examples
- Quality Report Generation: Creates detailed markdown reports with scores, issues, and recommendations
- Batch Analysis: Analyzes multiple skills at once for consistency checking
Input Requirements
Single Skill Analysis:
- Skill folder path (e.g.,
~/.codex/skills/my-skill/)
- Or SKILL.md file path directly
Batch Analysis:
- Directory containing multiple skills
- Or list of skill paths
Data Requirements:
- Valid SKILL.md file with YAML frontmatter
- Optional: Python files, README.md, HOW_TO_USE.md
Output Formats
Quality Score Card (JSON):
{
"overall_score": 85,
"dimensions": {
"clarity": {"score": 90, "weight": 20},
"structure": {"score": 85, "weight": 20},
"examples": {"score": 80, "weight": 15},
"trigger_detection": {"score": 90, "weight": 15},
"best_practices": {"score": 80, "weight": 15},
"maintainability": {"score": 85, "weight": 15}
},
"issues": ["Missing usage examples", "No sample inputs"],
"recommendations": ["Add 3-5 concrete usage examples", "Include sample_input.json"]
}
Quality Report (Markdown):
- Executive summary with overall score
- Dimension-by-dimension breakdown
- Critical issues list (severity-ranked)
- Improvement recommendations (prioritized)
- Comparison with best practices
- Before/After improvement potential
Six Quality Dimensions
1. Clarity (20%)
- What it measures: How clearly the skill's purpose, capabilities, and usage are communicated
- Key indicators:
- Description specificity (not vague)
- Clear capability statements
- Unambiguous usage instructions
- No jargon without explanation
- Scoring:
- 90-100: Crystal clear, no ambiguity
- 70-89: Mostly clear, minor improvements needed
- 50-69: Some confusion possible
- <50: Unclear purpose or usage
2. Structure (20%)
- What it measures: Organizational quality and consistency with Anthropic standards
- Key indicators:
- Valid YAML frontmatter (name in kebab-case, concise description)
- Required sections present (Capabilities, Input/Output, How to Use)
- Logical section ordering
- Proper markdown formatting
- Scoring:
- 90-100: Perfect structure, all sections present
- 70-89: Minor structural issues
- 50-69: Missing key sections
- <50: Severely malformed
3. Examples (15%)
- What it measures: Quality and quantity of usage examples
- Key indicators:
- 3-5 concrete usage examples
- sample_input.json present
- expected_output.json present
- Examples cover major use cases
- Scoring:
- 90-100: Rich examples with sample data
- 70-89: Good examples, missing sample files
- 50-69: Minimal examples
- <50: No examples or sample data
4. Trigger Detection (15%)
- What it measures: How easily Codex can determine when to invoke this skill
- Key indicators:
- Clear "When to use" section
- Specific trigger keywords identified
- Description mentions use cases
- No overlap with existing skills
- Scoring:
- 90-100: Crystal clear triggers
- 70-89: Mostly clear when to use
- 50-69: Ambiguous triggering conditions
- <50: No clear triggers
5. Best Practices (15%)
- What it measures: Adherence to Codex skill development standards
- Key indicators:
- Follows Codex naming conventions
- Proper Python structure (if applicable)
- README.md and HOW_TO_USE.md present
- No backup files or pycache
- Proper file organization
- Scoring:
- 90-100: Exemplary adherence
- 70-89: Minor deviations
- 50-69: Several best practice violations
- <50: Major violations
6. Maintainability (15%)
- What it measures: How easy it is to update and maintain the skill
- Key indicators:
- Clear code comments (if Python files)
- Modular design
- No hard-coded values
- Version information present
- Clean file structure (no clutter)
- Scoring:
- 90-100: Highly maintainable
- 70-89: Generally maintainable
- 50-69: Some maintenance challenges
- <50: Difficult to maintain
How to Use
Basic Analysis:
"Analyze the quality of my skill-creator skill"
"What's the quality score for ~/.codex/skills/code-review/"
"Run quality analysis on the aws-solution-architect skill"
Detailed Report:
"Generate a detailed quality report for skill-debugger"
"Analyze ~/.codex/skills/prompt-factory/ and create improvement recommendations"
Batch Analysis:
"Analyze all skills in ~/.codex/skills/ and rank them by quality"
"Compare quality scores across all my custom skills"
Comparative Analysis:
"Compare my code-review skill against Antigravity's best practices"
"How does skill-tester compare to official skills in quality?"
Scripts
analyzer.py: Core 6-dimension quality analysis engine
- Usage:
python3 analyzer.py --skill-path /path/to/skill
validator.py: YAML frontmatter and structure validation (merged into analyzer.py)
best_practices_checker.py: Checks adherence to Codex standards (merged into analyzer.py)
Best Practices
- Run Before Distribution: Always analyze skills before sharing or installing
- Target 80+ Score: Aim for overall scores of 80 or higher for production skills
- Fix Critical Issues First: Address issues flagged as "Critical" or "High" severity
- Iterate: Re-analyze after improvements to track progress
- Batch Analysis for Consistency: Use batch mode to ensure consistent quality across all your skills
- Compare Against Examples: Use comparative analysis to learn from official skills
Integration with Quality Systems
Agent-KB Integration:
- Automatically records quality patterns from high-scoring skills
- Learns common issues from low-scoring skills
- Suggests improvements based on historical data
CodeDNA Alignment:
- Uses similar 6-dimension framework
- Consistent scoring methodology
- Shares best practices database
CI/CD Integration:
- Can be used in pre-commit hooks
- Quality gates for skill deployment
- Automated quality regression testing
Limitations
- Static Analysis Only: Does not test skill execution or effectiveness
- No Runtime Testing: Cannot verify if Python code works correctly
- Pattern-Based: Relies on known patterns and best practices
- English-Focused: May not handle non-English skills as effectively
- No Context Understanding: Cannot judge if a skill's purpose is valuable
- File-Based: Requires access to skill files (cannot analyze from description alone)
When NOT to Use This Skill
- Testing Functional Correctness: Use skill-tester instead
- Runtime Debugging: Use skill-debugger for execution issues
- Documentation Generation: Use skill-doc-generator for creating docs
- Initial Skill Creation: Use skill-creator or templates first, then analyze
Quality Thresholds
| Score Range |
Quality Level |
Action |
| 90-100 |
Excellent |
Ready for production, share as example |
| 80-89 |
Good |
Minor improvements, safe to deploy |
| 70-79 |
Acceptable |
Address key issues before wide distribution |
| 60-69 |
Needs Work |
Significant improvements required |
| <60 |
Poor |
Major refactoring needed |
Comparison with CodeDNA
| Dimension |
CodeDNA (Code) |
Skill Quality Analyzer (Skills) |
| Clarity |
Comments & naming |
Description & documentation |
| Structure |
Code organization |
Section organization & YAML |
| Examples |
Test coverage |
Usage examples & sample data |
| Patterns |
Design patterns |
Trigger detection |
| Standards |
Coding standards |
Codex best practices |
| Maintenance |
Cyclomatic complexity |
File cleanliness & modularity |
1---2name: skill-quality-analyzer3description: Analyzes Codex skill quality with 6-dimension scoring system similar to CodeDNA, providing actionable improvement recommendations4---567# Skill Quality Analyzer89Comprehensive quality analysis system for Codex skills using a 6-dimension scoring framework inspired by CodeDNA. Identifies quality issues, provides improvement recommendations, and generates detailed quality reports.1011## Agent Workflow1213To perform a high-quality analysis, follow this **Hybrid Workflow**:14151. **Run Static Analysis**: Execute `python3 analyzer.py --skill-path [TARGET_SKILL_PATH]` to get objective metrics for the **target skill**.162. **Read Target Skill Content**: Use `view_file` to read the `SKILL.md` and `HOW_TO_USE.md` of the **skill you are analyzing** (the target skill). *Do not read this analyzer skill's own files.*173. **Synthesize Report**: Combine the script's findings (hard metrics) with your manual review of the **target skill's content** (soft metrics) to generate the final report.18 * *Script says*: "Description too short." -> *You check*: "Is it just short, or is it actual nonsense?"19 * *Script says*: "100/100 score." -> *You check*: "Format is perfect, but does the logic make sense?"2021## Capabilities2223- **6-Dimension Quality Scoring**: Evaluates skills across Clarity, Structure, Examples, Trigger Detection, Best Practices, and Maintainability (0-100 scale)24- **Automated Issue Detection**: Identifies common problems like missing examples, unclear descriptions, poor structure, and missing trigger words25- **Improvement Recommendations**: Provides specific, actionable suggestions for each quality dimension26- **Comparative Analysis**: Compares skills against best practices from official Antigravity examples27- **Quality Report Generation**: Creates detailed markdown reports with scores, issues, and recommendations28- **Batch Analysis**: Analyzes multiple skills at once for consistency checking2930## Input Requirements3132**Single Skill Analysis**:33- Skill folder path (e.g., `~/.codex/skills/my-skill/`)34- Or SKILL.md file path directly3536**Batch Analysis**:37- Directory containing multiple skills38- Or list of skill paths3940**Data Requirements**:41- Valid SKILL.md file with YAML frontmatter42- Optional: Python files, README.md, HOW_TO_USE.md4344## Output Formats4546**Quality Score Card** (JSON):47```json48{49 "overall_score": 85,50 "dimensions": {51 "clarity": {"score": 90, "weight": 20},52 "structure": {"score": 85, "weight": 20},53 "examples": {"score": 80, "weight": 15},54 "trigger_detection": {"score": 90, "weight": 15},55 "best_practices": {"score": 80, "weight": 15},56 "maintainability": {"score": 85, "weight": 15}57 },58 "issues": ["Missing usage examples", "No sample inputs"],59 "recommendations": ["Add 3-5 concrete usage examples", "Include sample_input.json"]60}61```6263**Quality Report** (Markdown):64- Executive summary with overall score65- Dimension-by-dimension breakdown66- Critical issues list (severity-ranked)67- Improvement recommendations (prioritized)68- Comparison with best practices69- Before/After improvement potential7071## Six Quality Dimensions7273### 1. Clarity (20%)74- **What it measures**: How clearly the skill's purpose, capabilities, and usage are communicated75- **Key indicators**:76 - Description specificity (not vague)77 - Clear capability statements78 - Unambiguous usage instructions79 - No jargon without explanation80- **Scoring**:81 - 90-100: Crystal clear, no ambiguity82 - 70-89: Mostly clear, minor improvements needed83 - 50-69: Some confusion possible84 - <50: Unclear purpose or usage8586### 2. Structure (20%)87- **What it measures**: Organizational quality and consistency with Anthropic standards88- **Key indicators**:89 - Valid YAML frontmatter (name in kebab-case, concise description)90 - Required sections present (Capabilities, Input/Output, How to Use)91 - Logical section ordering92 - Proper markdown formatting93- **Scoring**:94 - 90-100: Perfect structure, all sections present95 - 70-89: Minor structural issues96 - 50-69: Missing key sections97 - <50: Severely malformed9899### 3. Examples (15%)100- **What it measures**: Quality and quantity of usage examples101- **Key indicators**:102 - 3-5 concrete usage examples103 - sample_input.json present104 - expected_output.json present105 - Examples cover major use cases106- **Scoring**:107 - 90-100: Rich examples with sample data108 - 70-89: Good examples, missing sample files109 - 50-69: Minimal examples110 - <50: No examples or sample data111112### 4. Trigger Detection (15%)113- **What it measures**: How easily Codex can determine when to invoke this skill114- **Key indicators**:115 - Clear "When to use" section116 - Specific trigger keywords identified117 - Description mentions use cases118 - No overlap with existing skills119- **Scoring**:120 - 90-100: Crystal clear triggers121 - 70-89: Mostly clear when to use122 - 50-69: Ambiguous triggering conditions123 - <50: No clear triggers124125### 5. Best Practices (15%)126- **What it measures**: Adherence to Codex skill development standards127- **Key indicators**:128 - Follows Codex naming conventions129 - Proper Python structure (if applicable)130 - README.md and HOW_TO_USE.md present131 - No backup files or __pycache__132 - Proper file organization133- **Scoring**:134 - 90-100: Exemplary adherence135 - 70-89: Minor deviations136 - 50-69: Several best practice violations137 - <50: Major violations138139### 6. Maintainability (15%)140- **What it measures**: How easy it is to update and maintain the skill141- **Key indicators**:142 - Clear code comments (if Python files)143 - Modular design144 - No hard-coded values145 - Version information present146 - Clean file structure (no clutter)147- **Scoring**:148 - 90-100: Highly maintainable149 - 70-89: Generally maintainable150 - 50-69: Some maintenance challenges151 - <50: Difficult to maintain152153## How to Use154155**Basic Analysis**:156```157"Analyze the quality of my skill-creator skill"158"What's the quality score for ~/.codex/skills/code-review/"159"Run quality analysis on the aws-solution-architect skill"160```161162**Detailed Report**:163```164"Generate a detailed quality report for skill-debugger"165"Analyze ~/.codex/skills/prompt-factory/ and create improvement recommendations"166```167168**Batch Analysis**:169```170"Analyze all skills in ~/.codex/skills/ and rank them by quality"171"Compare quality scores across all my custom skills"172```173174**Comparative Analysis**:175```176"Compare my code-review skill against Antigravity's best practices"177"How does skill-tester compare to official skills in quality?"178```179180## Scripts181182- `analyzer.py`: Core 6-dimension quality analysis engine183 - Usage: `python3 analyzer.py --skill-path /path/to/skill`184- `validator.py`: YAML frontmatter and structure validation (merged into analyzer.py)185- `best_practices_checker.py`: Checks adherence to Codex standards (merged into analyzer.py)186187## Best Practices1881891. **Run Before Distribution**: Always analyze skills before sharing or installing1902. **Target 80+ Score**: Aim for overall scores of 80 or higher for production skills1913. **Fix Critical Issues First**: Address issues flagged as "Critical" or "High" severity1924. **Iterate**: Re-analyze after improvements to track progress1935. **Batch Analysis for Consistency**: Use batch mode to ensure consistent quality across all your skills1946. **Compare Against Examples**: Use comparative analysis to learn from official skills195196## Integration with Quality Systems197198**Agent-KB Integration**:199- Automatically records quality patterns from high-scoring skills200- Learns common issues from low-scoring skills201- Suggests improvements based on historical data202203**CodeDNA Alignment**:204- Uses similar 6-dimension framework205- Consistent scoring methodology206- Shares best practices database207208**CI/CD Integration**:209- Can be used in pre-commit hooks210- Quality gates for skill deployment211- Automated quality regression testing212213## Limitations214215- **Static Analysis Only**: Does not test skill execution or effectiveness216- **No Runtime Testing**: Cannot verify if Python code works correctly217- **Pattern-Based**: Relies on known patterns and best practices218- **English-Focused**: May not handle non-English skills as effectively219- **No Context Understanding**: Cannot judge if a skill's purpose is valuable220- **File-Based**: Requires access to skill files (cannot analyze from description alone)221222## When NOT to Use This Skill223224- **Testing Functional Correctness**: Use skill-tester instead225- **Runtime Debugging**: Use skill-debugger for execution issues226- **Documentation Generation**: Use skill-doc-generator for creating docs227- **Initial Skill Creation**: Use skill-creator or templates first, then analyze228229## Quality Thresholds230231| Score Range | Quality Level | Action |232|-------------|---------------|--------|233| 90-100 | Excellent | Ready for production, share as example |234| 80-89 | Good | Minor improvements, safe to deploy |235| 70-79 | Acceptable | Address key issues before wide distribution |236| 60-69 | Needs Work | Significant improvements required |237| <60 | Poor | Major refactoring needed |238239## Comparison with CodeDNA240241| Dimension | CodeDNA (Code) | Skill Quality Analyzer (Skills) |242|-----------|----------------|----------------------------------|243| Clarity | Comments & naming | Description & documentation |244| Structure | Code organization | Section organization & YAML |245| Examples | Test coverage | Usage examples & sample data |246| Patterns | Design patterns | Trigger detection |247| Standards | Coding standards | Codex best practices |248| Maintenance | Cyclomatic complexity | File cleanliness & modularity |