Skip to content

fix(skills): add agentskills.io spec compliance for tags/platforms frontmatter#33968

Closed
alaamohanad169-ship-it wants to merge 2 commits into
NousResearch:mainfrom
alaamohanad169-ship-it:fix/skills-spec-compliance
Closed

fix(skills): add agentskills.io spec compliance for tags/platforms frontmatter#33968
alaamohanad169-ship-it wants to merge 2 commits into
NousResearch:mainfrom
alaamohanad169-ship-it:fix/skills-spec-compliance

Conversation

@alaamohanad169-ship-it

Copy link
Copy Markdown
Contributor

Summary

Adds agentskills.io spec compliance so skills can place platforms/tags under a metadata key, with full backward compatibility.

Changes

  • agent/prompt_builder.py: metadata.platforms fallback
  • agent/skill_utils.py: metadata.platforms fallback in skill_matches_platform
  • tools/skills_tool.py: metadata.tags/related_skills fallback + bugfix for non-dict metadata
  • tests/agent/test_skill_utils.py: 11 new tests for metadata fallback

Bugfix

Original commit crashed when frontmatter metadata was non-dict — metadata.get() raised AttributeError. Fixed with isinstance guard.

Testing

All 178 skill-related tests pass. Zero failures.

…view

When frontmatter 'metadata' is not a dict (e.g. string or None from
YAML), calling metadata.get() raises AttributeError. This broke
skill_view and cascaded into all build_skill_invocation_message callers.

Fix: extract metadata tags/related_skills with isinstance guard before
use, matching the existing pattern for hermes_meta.
@alt-glitch alt-glitch added type/bug Something isn't working tool/skills Skills system (list, view, manage) comp/agent Core agent loop, run_agent.py, prompt builder P3 Low — cosmetic, nice to have duplicate This issue or pull request already exists labels May 28, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

Duplicate of #31579 (4th attempt, open) by the same author — same agentskills.io spec compliance fix for #30080. Prior attempts: #30105, #30978, #31241, #31352 (all closed). #31579 is the current canonical PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/agent Core agent loop, run_agent.py, prompt builder duplicate This issue or pull request already exists P3 Low — cosmetic, nice to have tool/skills Skills system (list, view, manage) type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants