Load Metadata • AI Agent SDK

load_metadata: Load skill metadata only (Level 1).

load_metadata

Method

</div>

This is a method of the SkillLoader class in the loader module.

Load skill metadata only (Level 1).

This is the minimal load for system prompt injection. Only reads the YAML frontmatter, not the full SKILL.md body.

Signature

python
def load_metadata(skill_path: str) -> Optional[LoadedSkill]

Parameters

ParamField str

Path to skill directory

Returns

ResponseField Optional[LoadedSkill]

LoadedSkill with metadata only, or None if invalid

Uses

  • resolve
  • expanduser
  • Path
  • path.exists
  • path.is_dir
  • read_properties
  • LoadedSkill

Used By

Source

View on GitHub

praisonaiagents/skills/loader.py at line 69