Extensible capability modules with progressive loading
Skills are structured capability modules that extend the agent’s knowledge and workflows. They’re loaded progressively — only when needed — keeping the context window lean.
Skills use YAML frontmatter for metadata and Markdown for instructions:
---name: data-analysisdescription: Analyze datasets with pandas, create visualizations, and generate reports. Use when working with CSV/Excel files, statistical analysis, or data visualization tasks.license: MITallowed-tools: - bash - read_file - write_file---# Data Analysis Skill## OverviewThis skill provides comprehensive data analysis capabilities...## Quick StartLoad a CSV file:```pythonimport pandas as pddf = pd.read_csv('/mnt/user-data/uploads/data.csv')print(df.describe())
### Frontmatter Fields<ParamField path="name" type="string" required> Unique skill identifier (kebab-case)</ParamField><ParamField path="description" type="string" required> When to use this skill. Include specific triggers and use cases.</ParamField><ParamField path="license" type="string"> License for the skill (e.g., MIT, Apache-2.0)</ParamField><ParamField path="allowed-tools" type="array"> Tools the skill is allowed to use. Leave empty for all tools.</ParamField>## Progressive LoadingSkills are loaded in two stages:### Stage 1: Skill List (Always Loaded)The agent receives a list of available skills with their descriptions:
Available Skills:
deep-research: Comprehensive multi-source research with citations
data-analysis: Analyze datasets and create visualizations
web-design: Create responsive HTML/CSS websites
This helps the agent decide which skill to load.### Stage 2: Full Skill Content (On-Demand)When the agent decides to use a skill, it loads the full `SKILL.md` content:```python# Agent decision"I need to analyze this CSV file. Let me load the data-analysis skill."# System loads SKILL.md contentfull_skill = load_skill("data-analysis")# Agent now has detailed instructions"Now I know how to use pandas for this analysis..."
Progressive loading keeps the initial prompt small while providing deep knowledge when needed.
The system discovers skills by scanning directories:
def load_skills() -> list[Skill]: skills = [] # Scan public and custom directories for base_dir in ["skills/public", "skills/custom"]: for skill_dir in os.listdir(base_dir): skill_md = f"{base_dir}/{skill_dir}/SKILL.md" if os.path.exists(skill_md): # Parse frontmatter and body skill = parse_skill(skill_md) # Check enabled status skill.enabled = get_enabled_status(skill.name) skills.append(skill) return skills
The description determines when your skill is loaded. Be specific:✅ Good: “Analyze datasets with pandas, create visualizations, and generate statistical reports. Use when working with CSV/Excel files.”❌ Bad: “Data analysis skill”
Keep SKILL.md under 500 lines
Long skills slow down the agent. Split content into reference files:
SKILL.md
# BigQuery Skill## Quick StartBasic usage...## Advanced- Finance queries: See references/finance.md- Sales queries: See references/sales.md
Include real examples
Show actual code that works in the sandbox:
import pandas as pddf = pd.read_csv('/mnt/user-data/uploads/data.csv')print(df.describe())