fix: validate skill names and duplicate frontmatter keys - #277
conorbronsdon merged 7 commits into
Conversation
Generated SKILL.full.md and the OpenAI bundled skill copy no longer repeat the top-level name field when the parent directory already defines the skill id. Root SKILL.md keeps an explicit name for single-file installs. Add frontmatter duplicate-key checks in the OpenAI plugin validator. Fixes conorbronsdon#259
PR Summary by QodoRemove redundant names from generated skill copies
AI Description
Diagram
High-Level Assessment
Files changed (9)
|
Code Review by Qodo
1.
|
conorbronsdon
left a comment
There was a problem hiding this comment.
Codex review, with a GPT-5.6 Sol reviewer, at Conor's request.
Thanks, @sharadvc, for investigating the duplicate-identity report and adding validation. The proposed removal of name breaks an installation contract, so this needs a different approach before merge.
The Agent Skills specification requires name and requires it to match the skill directory. OpenAI's skill documentation also requires name and description; its submission errors distinguish skill_name_missing from duplicate identity within one plugin. Repeated required metadata in separate distribution artifacts is not itself duplicate skill identity.
An extracted 44-file package passes this PR's weakened local validator but fails the official skills-ref validator with a missing-name error. The quoted-key bypass reported by Qodo also reproduces.
Please retain one explicit name in each installable SKILL manifest, require and compare it to the directory, and focus duplicate-identity checks on sibling skills in the same plugin. Normalize quoted and unquoted YAML keys consistently so mixed-key duplicates cannot pass. Tests should reject a missing name, mismatched quoted names, and quoted/unquoted duplicates, and verify the extracted package against the external contract. The additional validation is useful work to preserve in that revision.
conorbronsdon
left a comment
There was a problem hiding this comment.
Verified b3ff769: required names are retained, directory mismatches and duplicate identities are rejected, and unsupported key syntax fails validation. Local tests and CI pass. Independent Claude Sonnet 5, Muse Spark 1.3, and MiMo v2.5 reviews completed with no outstanding verified findings. The external reference-validator version-field limitation is reproduced on unchanged main and documented in the PR.
This change retains the required name in every installable and generated skill manifest. The validator now rejects names that differ from their skill directory and detects duplicate top-level frontmatter keys, including equivalent plain, quoted, and Unicode-escaped keys. Duplicate sibling skill identities remain rejected within each plugin.
The contributor history is preserved and current main is incorporated. Generated distributions keep their original required names; metadata stripping remains byte-exact for the remaining content.
Validation:
Fixes #259.