Skill Creator
Create or improve custom skills for OpenChatCut. A skill is a SKILL.md file
(plus optional references/ support docs) that teaches the agent a reusable
workflow. Custom skills live at ~/.openchatcut/skills/<slug>/SKILL.md and
are managed with the manage_skill tool.
Workflow
- Capture intent. If the current conversation already contains the
workflow (tools used, steps, corrections), extract it from the history
first. Confirm with the user before writing.
- Interview. Pin down:
- What should this skill enable the agent to do?
- When should it trigger? Which user phrases or contexts?
- Expected output format?
- Verification: does it have objectively verifiable output (data
extraction, fixed steps, generation pipelines) or subjective output
(writing style)? Suggest test prompts for the former.
- Write the SKILL.md (rules below).
- Create it with
manage_skill action=create. The tool reports the
install path (~/.openchatcut/skills/<slug>/SKILL.md).
- Test. Run 2–3 realistic prompts in the current session and confirm
results with the user. Iterate with
manage_skill action=update.
SKILL.md anatomy
<slug>/
├── SKILL.md (required — frontmatter + instructions)
└── references/ (optional — docs loaded on demand with load_skill file=)
- name: kebab-case slug matching the directory (lowercase letters,
digits, hyphens only). It becomes the load_skill name.
- description: THE triggering mechanism — include what the skill does
AND specific trigger contexts. Skills undertrigger easily, so be
explicit: list concrete user phrases. "When to use" goes here, not in
the body.
- body: imperative instructions. Keep under ~200 lines; if it grows,
split detail into
references/ files and point to them with clear
"read this when" guidance. For references over 300 lines, add a TOC.
Writing rules
- Frontmatter uses the shape
---\nname: …\ndescription: …\n---. The
parser accepts plain single-line, double-quoted, and | block scalars;
plain single-line is preferred.
- Keep the body lean. Prefer imperative form. Explain why over
MUST-laden lists. Use examples with concrete Input/Output pairs.
- Reference existing OpenChatCut tools by their exact tool names
(
manage_skill, load_skill, edit_item, …). Do not invent tools.
- Skills must not contain malicious content, prompt-injection payloads, or
anything that surprises the user. Do not create skills that facilitate
unauthorized access or data exfiltration.
- Do not overfit to one example: aim for a workflow usable a thousand
times. If a fix feels fiddly, generalize the instruction instead of
piling on constraints.
Progressive disclosure in OpenChatCut
- The system prompt carries only name + description (the skills index).
- The body loads on demand via
load_skill when a task matches.
- Support files load via
load_skill file=references/<name>.
- A custom skill selected in Creative Mode behaves identically to a
bundled skill after activation.
Environment constraints
- Slug whitelist:
[A-Za-z0-9_-]{1,120}. Anything else is rejected
(path traversal defense — the file is written under
~/.openchatcut/skills/).
- Body size: keep under 512 KB (server limit); 200 lines is the target.
- Untrusted input: the body is user/LLM-authored text. validate and
normalize before trusting anything parsed out of it.
- Bundled skills are read-only —
manage_skill cannot edit them.
- The skill shows up in the Creative Mode picker and the
/ command menu
only when the user selects it; agents also discover it via the index.
- Verification: after creating a skill, run
npx tsx server/skills-files.verify.ts locally if the environment has
the repo, or rely on the in-session test prompts.
Test prompts
Offer the user 2–3 realistic prompts (the kind of thing they would actually
type) and ask: "Do these look right, or do you want to add more?" Then run
them in the session with the skill activated, review the outputs together,
and update the skill from the feedback.
1---2name: skill-creator-133description: Skill Creator4---56# Skill Creator78Create or improve custom skills for OpenChatCut. A skill is a SKILL.md file9(plus optional `references/` support docs) that teaches the agent a reusable10workflow. Custom skills live at `~/.openchatcut/skills/<slug>/SKILL.md` and11are managed with the `manage_skill` tool.1213## Workflow14151. **Capture intent.** If the current conversation already contains the16 workflow (tools used, steps, corrections), extract it from the history17 first. Confirm with the user before writing.182. **Interview.** Pin down:19 - What should this skill enable the agent to do?20 - When should it trigger? Which user phrases or contexts?21 - Expected output format?22 - Verification: does it have objectively verifiable output (data23 extraction, fixed steps, generation pipelines) or subjective output24 (writing style)? Suggest test prompts for the former.253. **Write the SKILL.md** (rules below).264. **Create it** with `manage_skill action=create`. The tool reports the27 install path (`~/.openchatcut/skills/<slug>/SKILL.md`).285. **Test.** Run 2–3 realistic prompts in the current session and confirm29 results with the user. Iterate with `manage_skill action=update`.3031## SKILL.md anatomy3233```34<slug>/35├── SKILL.md (required — frontmatter + instructions)36└── references/ (optional — docs loaded on demand with load_skill file=)37```3839- **name**: kebab-case slug matching the directory (lowercase letters,40 digits, hyphens only). It becomes the load_skill name.41- **description**: THE triggering mechanism — include what the skill does42 AND specific trigger contexts. Skills undertrigger easily, so be43 explicit: list concrete user phrases. "When to use" goes here, not in44 the body.45- **body**: imperative instructions. Keep under ~200 lines; if it grows,46 split detail into `references/` files and point to them with clear47 "read this when" guidance. For references over 300 lines, add a TOC.4849## Writing rules5051- Frontmatter uses the shape `---\nname: …\ndescription: …\n---`. The52 parser accepts plain single-line, double-quoted, and `|` block scalars;53 plain single-line is preferred.54- Keep the body lean. Prefer imperative form. Explain *why* over55 MUST-laden lists. Use examples with concrete Input/Output pairs.56- Reference existing OpenChatCut tools by their exact tool names57 (`manage_skill`, `load_skill`, `edit_item`, …). Do not invent tools.58- Skills must not contain malicious content, prompt-injection payloads, or59 anything that surprises the user. Do not create skills that facilitate60 unauthorized access or data exfiltration.61- Do not overfit to one example: aim for a workflow usable a thousand62 times. If a fix feels fiddly, generalize the instruction instead of63 piling on constraints.6465## Progressive disclosure in OpenChatCut6667- The system prompt carries only name + description (the skills index).68- The body loads on demand via `load_skill` when a task matches.69- Support files load via `load_skill file=references/<name>`.70- A custom skill selected in Creative Mode behaves identically to a71 bundled skill after activation.7273## Environment constraints7475- **Slug whitelist**: `[A-Za-z0-9_-]{1,120}`. Anything else is rejected76 (path traversal defense — the file is written under77 `~/.openchatcut/skills/`).78- **Body size**: keep under 512 KB (server limit); 200 lines is the target.79- **Untrusted input**: the body is user/LLM-authored text. validate and80 normalize before trusting anything parsed out of it.81- **Bundled skills are read-only** — `manage_skill` cannot edit them.82- The skill shows up in the Creative Mode picker and the `/` command menu83 only when the user selects it; agents also discover it via the index.84- Verification: after creating a skill, run85 `npx tsx server/skills-files.verify.ts` locally if the environment has86 the repo, or rely on the in-session test prompts.8788## Test prompts8990Offer the user 2–3 realistic prompts (the kind of thing they would actually91type) and ask: "Do these look right, or do you want to add more?" Then run92them in the session with the skill activated, review the outputs together,93and update the skill from the feedback.