Plugin-namespaced skills
What plugin skills are
Skills are markdown files (SKILL.md) that teach the agent how to do something — a workflow recipe, a domain template, a checklist. The agent loads them via the built-in skill_view tool when it decides the instructions are relevant to the current task.
Plugin skills differ from regular skills in two ways:
- Namespaced — addressed as
<plugin>:<name>. Somy-plugin'sonboardskill becomesmy-plugin:onboard. - Explicit-load only — they don't appear in the system prompt's
<available_skills>index. The agent has to either know the qualified name (e.g. from your plugin's tool description) or list plugin skills to discover them.
Tool vs. skill — when to use which
Both tools and skills extend the agent's capabilities. Picking the right one matters for UX, cost, and reliability.
| Use a tool when… | Use a skill when… |
|---|---|
| The action has a deterministic outcome (read DB, call API, spawn process) | The output is a generated artifact whose form depends on context (a draft email, a code review, a meeting summary) |
| You want fast, cheap, deterministic behavior — slash command level | You want the LLM to reason and adapt the template to the current input |
| The work happens outside the model — file IO, network, shell | The work happens inside the model — phrasing, structuring, applying a style guide |
Many plugins ship both: a tool that fetches structured data, and a skill that templates how to present it.
Authoring SKILL.md
A skill is a single markdown file with optional YAML frontmatter. The frontmatter declares metadata; the body is the prompt-grade instructions the agent will read.
---
name: customer-onboarding
description: Welcome a new customer based on their plan tier
---
# Customer onboarding flow
When a customer signs up, send them a welcome message that:
1. References their **plan tier** (Starter / Pro / Business)
2. Highlights the top 3 features they get
3. Links to the relevant Quickstart guide
4. Suggests a 15-minute onboarding call for Business+ tiers
## Tone
Warm but professional. Avoid emojis. Sign as "The Acme Team."
## Tier-specific content
### Starter
- Self-serve quickstart link
- Link to community Slack
- No onboarding call offer
### Pro
- Self-serve quickstart link
- Mention email support
- Optional onboarding call offer
### Business
- Personalized onboarding call ask
- Slack channel for direct support
- Dedicated CSM introFrontmatter fields:
name— short identifier. Falls back to the directory name if omitted.description— one-liner. Used by theskill_viewtool when the user runsflowly skills list.
Registering the skill
Inside register(ctx), point at the SKILL.md file shipped with your plugin:
from pathlib import Path
def register(ctx):
ctx.register_skill(
name="customer-onboarding",
path=Path(__file__).parent / "skills" / "customer-onboarding" / "SKILL.md",
description="Welcome a new customer based on their plan tier",
)Recommended directory layout:
my-plugin/
├── plugin.yaml
├── __init__.py
└── skills/
├── customer-onboarding/
│ └── SKILL.md
├── churn-recovery/
│ └── SKILL.md
└── upsell-script/
└── SKILL.mdOne SKILL.md per directory keeps room for asset files (images, examples, sub-templates) alongside it. The directory name doesn't have to match the registered name — the registered name is what shows up in the qualified address.
register_skill checks the path at registration time. If SKILL.md is missing, your register(ctx) raises FileNotFoundError, which fails the entire plugin load. Wrap optional skills in a try/except, or guarantee they ship with the plugin.How the agent loads it
The agent loads a plugin skill the same way it loads any skill — via the skill_view built-in tool — but with the qualified namespace:
# In an agent turn
skill_view(name="my-plugin:customer-onboarding")
→ returns the SKILL.md body, which the agent then reads as instructionsFor the agent to know your skill exists, you have two options:
- Mention it in a tool description. If your plugin also registers a tool, include something like "After successfully running this tool, consider loading
my-plugin:customer-onboardingfor the response template." The agent picks up the cue. - The agent lists plugin skills. The
skills_listbuilt-in tool can include plugin skills when called withinclude_plugin_skills=true. The agent uses this when explicitly asked "what plugin skills do I have?".
Common patterns
- Tool + skill pair. Tool fetches data; skill templates the output. Example:
crm_fetch_accounttool returns raw JSON;crm:account-summaryskill says how to present it for QBR slides. - Workflow checklist. The skill is a sequenced list the agent walks through in order. Useful for compliance work ("before sending an email externally, check…").
- Style guide. The skill describes voice, tone, and forbidden phrases. The agent reads it before drafting any user-facing copy in your plugin's domain.
- Domain glossary. Internal terminology, product names, customer code-names. The agent loads it to ground responses in your team's vocabulary.