SKILL.md file with frontmatter metadata and detailed instructions.
Unlike tools, skills are not callable directly. The agent uses the auto-registered Skill viewer tool to read a skill’s instructions, then follows those instructions using its existing tools.
Register Skill
Pass skill sources to theToolkit constructor through skills_or_loaders. Each entry can be a directory path string, a Skill object, or a SkillLoaderBase subclass:
How Skill Works
When aToolkit is constructed with skills, the registration and lookup flow runs in two phases.
At initialization:
- The toolkit scans every registered skill source and collects each skill’s name, description, and directory.
- It auto-registers the built-in
Skillviewer tool. - It composes a system-prompt fragment listing the available skills (name and description only) and instructing the agent to invoke the
Skillviewer to read the full content.
- The agent picks a skill by name and calls the
Skillviewer. - The viewer reads the corresponding
SKILL.mdand returns its full markdown. - The agent follows those instructions using its already-equipped tools.
Skills are not tools: the agent cannot call a skill directly. It must first use the
Skill viewer to read the instructions, then execute the steps described within using its other tools.