cookbook/90_models/anthropic/skills/README.md
Claude Agent Skills enable Claude to improve how it performs specific tasks:
These skills use a progressive disclosure architecture - Claude first discovers which skills are relevant, then loads full instructions only when needed.
Before you can use Claude Agent Skills, you'll need:
anthropic (for direct API access)agno (for agent framework)python-pptx (optional, for PowerPoint manipulation)openpyxl (optional, for Excel file handling)python-docx (optional, for Word document handling)PyPDF2 or pdfplumber (optional, for PDF processing)uv pip install anthropic agno
# Optional: Install document manipulation libraries
uv pip install python-pptx openpyxl python-docx PyPDF2 pdfplumber
export ANTHROPIC_API_KEY="your_api_key_here"
Or create a .env file:
ANTHROPIC_API_KEY=your_api_key_here
import anthropic
client = anthropic.Anthropic()
response = client.messages.create(
model="claude-sonnet-4-5-20250929",
max_tokens=4096,
betas=["skills-2025-10-02"], # Enable skills beta
container={
"skills": [
{"type": "anthropic", "skill_id": "pptx", "version": "latest"},
{"type": "anthropic", "skill_id": "xlsx", "version": "latest"},
{"type": "anthropic", "skill_id": "docx", "version": "latest"},
{"type": "anthropic", "skill_id": "pdf", "version": "latest"},
] # Enable all skills
},
messages=[
{
"role": "user",
"content": "Create a 3-slide PowerPoint about AI trends"
}
]
)
Agno now has native support for Claude Agent Skills! Simply pass the skills parameter to the Claude model:
from agno.agent import Agent
from agno.models.anthropic import Claude
# Enable PowerPoint skill
agent = Agent(
model=Claude(
id="claude-sonnet-4-5-20250929",
skills=[{"type": "anthropic", "skill_id": "pptx", "version": "latest"}] # Enable PowerPoint skill
),
instructions=[
"You are a presentation specialist.",
"Create professional PowerPoint presentations."
],
markdown=True
)
agent.print_response("Create a sales presentation with 5 slides")
Available Skills: pptx, xlsx, docx, pdf
You can enable multiple skills at once:
model=Claude(
id="claude-sonnet-4-5-20250929",
skills=[
{"type": "anthropic", "skill_id": "pptx", "version": "latest"},
{"type": "anthropic", "skill_id": "xlsx", "version": "latest"},
{"type": "anthropic", "skill_id": "docx", "version": "latest"},
]
)
The framework automatically:
code-execution-2025-08-25, skills-2025-10-02)agent_with_powerpoint.pyShows how to create an Agno agent specialized in PowerPoint presentations:
agent_with_excel.pyDemonstrates Excel/spreadsheet capabilities:
agent_with_documents.pyExamples for Word and PDF processing:
multi_skill_agent.pyAdvanced example combining multiple skills:
Files created by Agent Skills are NOT automatically saved to your local filesystem.
When Claude creates a document (e.g., .pptx, .xlsx) using Agent Skills, it:
import anthropic
client = anthropic.Anthropic()
# 1. Create document with skills
response = client.beta.messages.create(
model="claude-sonnet-4-5-20250929",
max_tokens=4096,
betas=["code-execution-2025-08-25", "skills-2025-10-02"],
container={"skills": [{"type": "anthropic", "skill_id": "pptx", "version": "latest"}]},
messages=[{"role": "user", "content": "Create a presentation..."}],
tools=[{"type": "code_execution_20250825", "name": "code_execution"}]
)
# 2. Extract file ID from tool results
file_id = None
for block in response.content:
if block.type == "tool_use" and hasattr(block, "result"):
# File ID is in the tool result
file_id = block.result.get("file_id")
# 3. Download the file
if file_id:
file_content = client.beta.files.download(file_id=file_id)
with open("presentation.pptx", "wb") as f:
f.write(file_content)
See test_with_file_download.py for a complete example.
claude-sonnet-4-5-20250929 or laterclaude-3-5-sonnet-20241022Skills require the beta parameter:
betas=["skills-2025-10-02"]
Specify skills in the container parameter:
container={
"skills": ["pptx"] # Enable only PowerPoint
# or
"skills": ["pptx", "xlsx", "docx", "pdf"] # Enable all skills
}
betas=["skills-2025-10-02"]If you encounter any issues or have questions, please:
This integration follows the same license as the Agno framework.