用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/HezaoHezao/poirot --skill skill-authoring命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
基于 SOC 职业分类
正在显示 SKILL.md
| name | skill-authoring |
| description | Author SKILL.md: frontmatter, structure, writing principles. |
| allowed-tools | ["write_file","str_replace","read_file","list_dir"] |
| enabled | true |
| related-skills | ["skill-creator","plan"] |
| license | MIT |
| author | Adapted from hermes-agent (Nous Research, MIT) |
A SKILL.md can live in two places:
poirot/backend/agents/skill/builtin_skills/<category>/<name>/SKILL.md
— committed, shipped with the package. Use write_file + git add.skills/<name>/SKILL.md — personal, gitignored. Created via
/skill install <path> or by writing directly.This skill covers authoring for both, with emphasis on builtin skills.
builtin_skills/Source of truth: poirot/backend/agents/skill/parser.py::parse_skill_file.
Hard requirements:
--- as the first bytes (no leading blank line).\n---\n before the body.name field present (lowercase, hyphens).description field present.Peer-matched shape:
---
name: my-skill-name # lowercase, hyphens
description: Use when <trigger>. <one-line behavior>.
allowed-tools: # Poirot tools this skill may invoke
- bash
- read_file
- write_file
- list_dir
- str_replace
- web_search
- browse_page
- present_files
- read_snapshot
enabled: true
related-skills: [other-skill] # optional cross-references
license: MIT # recommended for contributed skills
author: <human contributor or source attribution>
---
allowed-tools / enabled / related-skills / license / author are NOT
enforced by the parser (it reads name/description/allowed-tools/enabled), but
every peer has them — omit and your skill sticks out.
description ≤ 60 characters, one sentence, ends with a period. State the
capability, not the implementation. No marketing words ("powerful",
"comprehensive", "seamless"). Don't repeat the skill name.
Verify:
import re, pathlib
m = re.search(r'^description: (.*)$',
pathlib.Path('builtin_skills/<cat>/<name>/SKILL.md').read_text(),
re.MULTILINE)
assert len(m.group(1)) <= 60, len(m.group(1))
references/*.md and reference them from
SKILL.md.A skill exists to make the agent's process more predictable. Predictability does not mean identical output every run; it means the agent reliably follows the same useful discipline.
SKILL.md; put
branch-specific or bulky reference material in references/, templates/,
or scripts/ and point to it only when needed.Common quality failures:
Tools referenced in SKILL.md prose must be native Poirot tools (listed in
allowed-tools) or MCP servers the skill explicitly expects. Do NOT name shell
utilities the agent already has wrapped:
grep → bash (run grep via bash)cat/head/tail → read_filesed/awk → str_replacefind/ls → list_dir# <Title>
## Overview
One or two paragraphs: what and why.
## When to Use
- Bulleted triggers
- "Don't use for:" counter-triggers
## <Topic sections specific to the skill>
- Quick-reference tables are common
- Code blocks with exact commands
## Common Pitfalls
Numbered list of mistakes and their fixes.
## Verification Checklist
- [ ] Checkbox list of post-action verifications
Not every section is mandatory, but Overview + When to Use + actionable
body + pitfalls are the minimum.
builtin_skills/<category>/<skill-name>/SKILL.md # builtin
skills/<skill-name>/SKILL.md # user-local
Builtin categories: core, research, software-development, creative,
productivity. Pick the closest existing category. Don't invent new top-level
categories casually.
list_dir("poirot/backend/agents/skill/builtin_skills/<category>/")
Read 2-3 peer SKILL.md files to match tone and structure.write_file to builtin_skills/<category>/<name>/SKILL.md.import yaml, re, pathlib
content = pathlib.Path("builtin_skills/<category>/<name>/SKILL.md").read_text()
assert content.startswith("---")
m = re.search(r'\n---\s*\n', content[3:])
fm = yaml.safe_load(content[3:m.start()+3])
assert "name" in fm and "description" in fm
assert len(fm["description"]) <= 60
/skill list will
not see the new skill until restart. This is expected.related-skills is documentation-only (parser ignores it). You can reference
any skill, but prefer referencing only builtin skills from builtin skills —
user-local skills won't resolve for other users.
str_replace on the SKILL.md.write_file the whole SKILL.md.write_file to
builtin_skills/<category>/<name>/references/<file>.md,
templates/<file>, or scripts/<file>.Leading whitespace before ---. Parser requires content.startswith("---");
any leading blank line or BOM fails.
Description too generic. Peer descriptions start with the trigger class, not the one task. "Use when debugging X" > "Debug X".
Description too long. >60 chars bloats skill listings and dilutes model attention. Trim ruthlessly.
Naming shell utilities. grep/cat/sed/find → use Poirot tool
names (bash/read_file/str_replace/list_dir). Otherwise the model
hallucinates calls to non-existent tools.
Writing a skill that duplicates a peer. Before creating, list_dir the
category and open 2-3 peers. Prefer extending an existing skill to creating
a narrow sibling.
Expecting the current session to see the new skill. It won't. The skill loader initializes at startup. Verify in a fresh session.
Letting skills accumulate sediment. A skill should get shorter or sharper over time. When adding a rule, remove the old wording it replaces.
Writing no-op prose. "Be careful," "be thorough," "use best practices" rarely change model behavior. Replace with a checkable completion criterion.
builtin_skills/<category>/<name>/SKILL.md (or skills/<name>/)---, closes with \n---\nname, description, allowed-tools, enabled presentlicense, author present (attribution)# Title → ## Overview → ## When to Use → body → ## Pitfalls → ## Verificationgit add && git commit completed