agentleFS
Yco-0314Yco-0314/strata/skills/l5-meta/writing-skills/SKILL.md

writing-skills

Skill0 starsChanged 5 months agoMITView on GitHub

Use when authoring a new Architect skill or editing an existing one — when the user wants to write, draft, revise, refactor, or split a SKILL.md, fix a skill that fires unreliably or gets skipped, prune a bloated skill, or decide a skill's layer/role/invocation. Trigger phrases: "write a skill", "author a skill", "edit this skill", "this skill isn't working", "make a skill". Not for running the eval harness itself (that is skill-eval).

154 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use diagnosing-superpowers, chinese-code-review and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • obraSkill

    diagnosing-superpowers

    Use when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness.

    Also in 6 projects that use this

  • shibit-netSkill

    chinese-code-review

    中文 review 沟通参考——话术模板、分级标注(必须修复/建议修改/仅供参考)、国内团队常见反模式应对。仅在用户显式 /chinese-code-review 时调用,不要根据上下文自动触发。

    Also in 3 projects that use this

  • shibit-netSkill

    chinese-commit-conventions

    中文 commit 与 changelog 配置参考——Conventional Commits 中文适配、commitlint/husky/commitizen 中文模板、conventional-changelog 中文配置。仅在用户显式 /chinese-commit-conventions 时调用,不要根据上下文自动触发。

    Also in 3 projects that use this

  • pedronauckSkill

    writing-agents-md

    Write or audit AGENTS.md/CLAUDE.md instructions. Use writing-skills for on-demand skills; excludes human-facing docs and READMEs.

    Also in 3 projects that use this

  • MorningStar0709Skill

    chinese-git-workflow

    Configure Git for domestic platforms and manage branching strategies suitable for Chinese teams. Use when the user asks to configure remotes, set up SSH, or manage Git workflows for Gitee, Coding, Jihu GitLab, or CNB, including requests like "配置国内 Git", "设置 Gitee 远程仓库", "推荐适合小团队的 Git 流程".

    Also in 3 projects that use this

  • MorningStar0709Skill

    workflow-runner

    Run an agency-orchestrator style YAML workflow inside the current Trae conversation by simulating or coordinating multiple roles. Use when the user provides a `.yaml` or `.yml` workflow, asks for multi-role collaboration, says things like “用多个角色一起评审这个 PRD”“多角色协作”“先生成工作流再执行”“让产品经理、架构师、QA 一起看一下”, or wants roles such as product manager, architect, reviewer, or QA to work together. Supports layered execution, role prompting, variable interpolation, document-backed inputs, and parallel steps only when the current environment has a clear subagent mapping. Do not use for ordinary implementation plans, simple code changes, or tasks already covered by `writing-plans`, `executing-plans`, `subagent-driven-development`, or single-purpose review/debug skills.

    Also in 3 projects that use this

  • +1 more from shibit-net

The file

We split this skill into the rules it gives an agent

5 rules. 0 are common, 5 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 144 edited versions we read keep these.

  • 5

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Every skill's frontmatter is fixed by ADR 0001's invocation taxonomy.

    line 47
  2. Distinctive:

    No exceptions: not for "just a section", not for "obvious" additions, not for "docs only".

    line 72
  3. Distinctive:

    RED — watch it fail: Write a pressure scenario (combine pressures for discipline skills: time + sunk cost + authority + exhaustion).

    line 78
  4. Distinctive:

    Write an eval set whose assertions target *the behaviour the skill mandates that baseline won't show* — not facts a good baseline already …

    line 166
  5. Distinctive:

    No Architect skill — and no ecosystem borrow — ships until it clears a Δ here.

    line 172

“Common” is measured: kept by at least 6 in 10 of the 144 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

writing-skills — the L5 authoring method

The deliberate, human-driven method for writing an Architect skill that earns its context budget. It fuses three disciplines into one division of labor:

  • Theory — why a skill works (mattpocock's glossary vocabulary).
  • Method — how to author one (superpowers' TDD-for-process loop).
  • Gate — whether it ships (ponytail's "must move a measured number" via skill-eval).

This skill is user-invoked: authoring is a deliberate act. It hands the finished skill to skill-eval (L5) — the only judge of whether the skill ships.

The root virtue: predictability

A skill exists to wrangle determinism out of a stochastic system. Predictability — the agent taking the same process every run (not producing the same output) — is the root virtue. Cost and brevity are symptoms of it, not rivals. Every rule below is a lever on predictability. The per-line test that governs the whole document:

Does this line change behaviour versus the model's default? If not, it is a no-op — you are paying context load to say nothing. Delete it.

Step 0 — Classify before you write (the law)

Every skill's frontmatter is fixed by ADR 0001's invocation taxonomy. Decide three fields first; they are not stylistic:

FieldValuesThe rule
layerL0–L6Where it sits on the altitude map (see CONTEXT-MAP.md).
rolediscipline · primitive · orchestratorWhat it is.
invocationmodel-invoked-discipline · model-invoked-primitive · user-invokedDerived from role.

Invocation is derived, not chosen freely:

  • discipline & primitive → model-invoked. Keep a rich description; no disable flag. The agent (or another skill) must reach it autonomously.
  • orchestrator → user-invoked. Set disable-model-invocation: true; the description becomes human-facing. Zero context load, but the human is the index that must remember it.
  • A user-invoked skill cannot reach another user-invoked skill (no description to fire). If two orchestrators need a shared engine, that engine must be a primitive (model-invoked), or external reference.

The Iron Law — no skill without a failing test first

NO SKILL WITHOUT A FAILING PRESSURE-TEST FIRST.

Applies to new skills AND edits. If you didn't watch an agent fail without the skill, you don't know what the skill needs to teach. Writing the skill first means you are guessing at rationalizations instead of capturing them.

No exceptions: not for "just a section", not for "obvious" additions, not for "docs only". Wrote the skill before the test? Delete it; start from RED. Violating the letter is violating the spirit.

RED → GREEN → REFACTOR (TDD for process)

  1. RED — watch it fail. Write a pressure scenario (combine pressures for discipline skills: time + sunk cost + authority + exhaustion). Run a subagent against it without the skill. Record the baseline behaviour and the exact rationalizations, verbatim — those quotes become your rationalization table.
  2. GREEN — write the minimal skill. Address those specific failures. No content for hypothetical cases. Re-run the scenario with the skill; the agent should comply.
  3. REFACTOR — close loopholes. New rationalization surfaces? Add an explicit counter. Re-test until bulletproof. Capture every excuse in a | Excuse | Reality | table and a "Red Flags — STOP" list so the agent can self-check under pressure.

Authoring standards (enforced)

The description is WHEN-only — never WHAT

The description states when to fire, in third person, ≤1024 chars. Do NOT summarize the workflow body. A WHAT-summary is a documented failure: the agent follows the summary and skips the body — e.g. a description saying "review between tasks" caused one review where the body's flowchart mandated two. Triggers, not process:

# BAD — summarizes workflow; the agent follows this and skips the body
description: Use when executing plans — dispatch a subagent per task with review between
# GOOD — pure triggering conditions
description: Use when executing implementation plans with independent tasks

One trigger per branch; synonyms that rename one branch are duplication — collapse them. Front-load the leading word that does the invocation work.

Tag each section with its degrees of freedom

Match specificity to fragility (Anthropic best-practices). State it where it isn't obvious:

  • High freedom — prose, "use judgement". Many valid paths, context decides (an open field). E.g. a review heuristic.
  • Medium freedom — a preferred pattern / parameterized template, variation allowed.
  • Low freedom — an exact command, "run this, do not modify" (a narrow bridge with cliffs). Fragile, sequence-critical, irreversible. E.g. a migration.

Over-constraining an open field wastes tokens and rigidifies good judgement; under-constraining a narrow bridge invites the agent off the cliff.

Steer with leading words, completion criteria, legwork

  • Leading word — a compact concept already in the model's pretraining (lesson, tracer bullets, red) repeated as a token, never a sentence. It anchors a region of behaviour in the fewest tokens. A leading word too weak to beat the default is a no-op; the fix is a stronger word (relentless over be thorough), not more prose.
  • Completion criterion — end every step on a checkable condition ("every modified model accounted for", not "produce a change list"). A vague bound invites premature completion — the agent's attention slips to being done.
  • Legwork — the digging the agent does inside a step. A demanding completion criterion drives it; a leading word (comprehensive) raises it.

Information hierarchy — push reference down the ladder

Three rungs, ranked by how immediately the agent needs the material:

  1. In-skill steps — ordered actions, the primary tier.
  2. In-skill reference — rules/facts consulted on demand (often a legitimately flat peer-set; not a smell).
  3. External reference — disclosed behind a context pointer to a sibling file (GLOSSARY.md-style), loaded only when the pointer fires.

Progressive disclosure is the move down the ladder. The test is branching: inline what every branch needs; disclose what only some reach. A context pointer's wording, not its target, decides how reliably the agent reaches the material — sharpen the wording before pulling material back inline. Keep a concept's definition, rules, and caveats co-located under one heading.

When to split

Each cut spends one of two loads — split only when the cut earns it:

  • By invocation — split off a model-invoked skill when a distinct leading word should trigger it independently, or another skill must reach it. You pay permanent context load for its always-loaded description.
  • By sequence — split a run of steps when the steps still ahead (post-completion steps) tempt the agent to rush the one in front (premature completion). Hiding them only works across a real context boundary (a user-invoked hand-off or subagent dispatch) — an inline call clears nothing.

Prune: the five failure modes

Diagnose a misbehaving skill against these. Each pairs with its cure:

Failure modeSymptomCure
Premature completionstep ends before truly donesharpen the completion criterion first; only then hide post-completion steps by splitting
Duplicationone meaning in two placesone single source of truth; collapse to a leading word
Sedimentstale layers nobody dares deletea pruning discipline; check every line for relevance
Sprawltoo long even when all-live, all-uniquepush reference down the ladder; split by branch/sequence
No-opa line the model already obeys by defaultthe per-line test — delete, or upgrade a weak leading word

Hunt no-ops sentence by sentence, not just line by line: when one fails the test, delete the whole sentence rather than trim words. Be aggressive.

The ship gate — must move a measured number

ponytail, superpowers, and mattpocock all author by taste, with no measurement loop. A skill ships only if it moves a measured number. After GREEN/REFACTOR, route the skill through skill-eval (L5):

  • Write an eval set whose assertions target the behaviour the skill mandates that baseline won't show — not facts a good baseline already produces.
  • Δ > 0 → the skill changes behaviour in the measured direction. Ship it.
  • Δ = 0 → either the trap is too easy (try a weaker EVAL_MODEL), or the skill isn't pulling its weight. Either way, ask: does this skill earn its context budget?

No Architect skill — and no ecosystem borrow — ships until it clears a Δ here.

Flow

classify (Step 0)  →  RED (baseline fail)  →  GREEN (minimal skill)
  →  REFACTOR (close loopholes)  →  skill-eval (Δ>0?)  →  ship

Upstream: this skill is reached deliberately by the human. Downstream gate: skill-eval (L5) — the only judge of whether the skill ships. Cross-ref CONTEXT-MAP.md for the layer map and ADR 0001 for the invocation law.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.