Skill-powered AI agents implementing the Agent Skills specification with pydantic-ai.
SkillToolset is a pydantic-ai FunctionToolset that you attach to your own agent. It exposes a single execute_skill tool. When the agent calls it, a focused sub-agent spins up with only that skill's instructions and tools — then returns the result. The main agent never sees the skill's internal tools, so its tool space stays clean no matter how many skills you load.
- Sub-agent execution — Each skill runs in its own agent with dedicated instructions and tools
- Filesystem skills — Load SKILL.md directories with scripts in Python, JavaScript, TypeScript, or shell
- Entrypoint skills — Install skill packages with typed in-process tools, per-skill state, and zero-config discovery
- Per-skill state — Pydantic state models tracked per namespace; state changes emit
StateDeltaEvent(JSON Patch) for the AG-UI protocol - MCP integration — Wrap any MCP server (stdio, SSE, streamable HTTP) as a skill
- Signing and verification — Identity-based skill signing via sigstore
uv add haiku.skillsfrom pathlib import Path
from pydantic_ai import Agent
from haiku.skills import SkillToolset, build_system_prompt
toolset = SkillToolset(skill_paths=[Path("./skills")])
agent = Agent(
"anthropic:claude-sonnet-4-5-20250929",
instructions=build_system_prompt(toolset.skill_catalog),
toolsets=[toolset],
)
result = await agent.run("Analyze this dataset.")
print(result.output)Full documentation at ggozad.github.io/haiku.skills.
MIT