Files
Anthropic-Cybersecurity-Skills/tools
Julio César Suástegui 31f745385b fix(validator): address all review feedback from @mukul975
Required changes:
- Error handling: IOError and UnicodeDecodeError already wrapped in
  try/except from previous commit — still present and correct.
- ALLOWED_SUBDOMAINS: synced with actual repo usage (audited all 754
  skills). identity-access-management (34 skills) added; identity-security
  was the placeholder in its place.

New in this commit:
1. Description minimum: raised from 20 → 50 chars to align with other
   repo tooling as requested.
2. Folded scalar support: parse_frontmatter now handles YAML `>-` and `>`
   folded scalars, preventing incorrect parse of multi-line descriptions.
   Added a comment documenting the one remaining edge case (value-less key
   followed by non-list content — treated as no-value, acceptable for
   well-formed SKILL.md files).
3. Canonical subdomain warnings: alias subdomain values (e.g.
   security-operations vs soc-operations) now print a WARN line pointing
   to the canonical form, but are non-blocking. A _SUBDOMAIN_ALIASES dict
   documents canonical/alias pairs explicitly.
4. Description upper limit: removed hard cap — folded scalars legitimately
   produce long strings in existing skills.
5. PR description: removed false mention of type hints (there are none
   in this file).

Validator now passes 754/754 skills in the repo with 0 errors.
2026-04-03 09:51:27 -06:00
..

Skill Validation Tools

validate-skill.py

Validate SKILL.md metadata before submitting a PR.

Usage

# Validate a single skill
python tools/validate-skill.py skills/my-new-skill/

# Validate all skills
python tools/validate-skill.py --all

What it checks

  • SKILL.md exists in the skill directory
  • Valid YAML frontmatter (between --- markers)
  • Required fields present: name, description, domain, subdomain, tags
  • Name is kebab-case, 164 characters
  • Description is 20500 characters
  • Domain is cybersecurity
  • Subdomain is from the allowed list
  • Tags is a list with at least 2 items

Requirements

Python 3.8+ (stdlib only, no external dependencies)