Docs
Write a skill once. Load it into any agent.
A skill is one Markdown file. The package reads it and hands each runtime exactly what it expects: a system prompt, an assistant config, a prompt template, a rule file.
npm install universal-agent-skills01 — Adapters
One file in, the right shape out.
Pick a target to see what its adapter returns for this example skill. Every adapter reads the same file, so there's nothing to keep in sync.
---
name: release-notes
description: Turn merged pull requests into release notes grouped by what users notice.
version: 0.1.0
tags: [writing, engineering]
inputs:
- name: changes
description: Merged PR titles and descriptions.
required: true
---
# release-notes
Group changes under New, Improved and Fixed.
Write one line per change, in plain words, present tense.
Leave out internal refactors unless they change behavior.forClaude("release-notes")Pass system to anthropic.messages.create()
{
"system": "# release-notes\n\nGroup changes under New, Improved and Fixed.\nWrite one line per change, in plain words, present tense.\nLeave out internal refactors unless they change behavior.",
"metadata": {
"skill_name": "release-notes",
"skill_version": "0.1.0",
"related_skills": []
}
}02 — Usage
Drop it into the code you already have.
Each adapter is one function call. Python frameworks read the same Markdown files straight from node_modules.
import Anthropic from "@anthropic-ai/sdk";
import { forClaude } from "universal-agent-skills";
const anthropic = new Anthropic();
const { system } = forClaude("super-ui");
const msg = await anthropic.messages.create({
model: "claude-opus-5-5",
max_tokens: 4096,
system,
messages: [{ role: "user", content: "Review this dashboard screen." }],
});import OpenAI from "openai";
import { forOpenAI } from "universal-agent-skills";
const openai = new OpenAI();
const assistant = await openai.beta.assistants.create({
model: "gpt-4o",
...forOpenAI("super-ui"), // { name, description, instructions }
});import { PromptTemplate } from "@langchain/core/prompts";
import { forLangChain } from "universal-agent-skills";
// Each declared input becomes a {placeholder} in the template.
const { template, inputVariables } = forLangChain("super-ui");
const prompt = PromptTemplate.fromTemplate(template);# Build a catalog once from Node:
# node -e "import('universal-agent-skills').then(m =>
# console.log(JSON.stringify(m.loadAllSkills())))" > skills.json
import json
from crewai import Agent
from autogen import AssistantAgent
skills = {s["name"]: s for s in json.load(open("skills.json"))}
skill = skills["super-ui"]
crew_agent = Agent(role=skill["name"], goal=skill["description"],
backstory=skill["instructions"])
autogen_agent = AssistantAgent(name=skill["name"],
system_message=skill["instructions"])# Write Cursor, AGENTS.md and Stitch versions to skills/<name>/exports/
node scripts/export-skill.js super-ui
node scripts/export-skill.js --all
# Or from code: forCursor(name), forAgentsMd(name), forStitchPrompt(name)
# Copy a skill's references/ folder alongside the file so its links resolve.03 — API
Fourteen functions. That's the whole API.
Everything takes a skill name and returns plain data. Types ship in src/index.d.ts.
Load
- loadAllSkills()
- Skill[]
- getSkill(name)
- Skill
- listSkills()
- SkillSummary[]
- getRelatedSkills(name)
- RelatedSkillSummary[]
- asSystemPrompt(name)
- string
Adapt
- forClaude(name)
- { system, metadata }
- forOpenAI(name)
- { name, description, instructions }
- forLangChain(name)
- { template, inputVariables }
- forCrewAI(name)
- { role, goal, backstory }
- forAutoGen(name)
- { name, system_message }
- forCursor(name)
- { filename, content }
- forAgentsMd(name)
- { filename, content }
- forStitchPrompt(name)
- { content }
- forGeneric(name)
- { name, description, version, … }
04 — Write a skill
A folder and a Markdown file.
Put a SKILL.md in skills/<name>/. There's no registry and no build step. Add a references/ folder for longer material the skill points to.
---
name: my-skill
description: When to use this skill and what it produces.
version: 0.1.0
tags: [domain, capability]
inputs:
- name: input_name
description: What this input is.
required: true
related: [other-skill] # optional
author: your-name # optional, only if you wrote it
---
# my-skill
The instructions the agent follows: the process,
the output shape, and what to avoid.- Lead with intent. The first paragraph says when the skill applies.
- Process before output. Describe how to think, not only what to emit.
- Specify the output shape. Models drift without a target format.
- Name the failure modes. A "what to avoid" section prevents the common mistakes.
- Be concrete. One real example teaches more than a paragraph of advice.