---
name: writing-hordev-skills
description: Use when creating a new skill, editing an existing one, or verifying a skill triggers correctly and works standalone
title: writing-hordev-skills
canonical_url: https://skilld.dev/gh/heffrey/hordev/writing-hordev-skills
last_updated: 2026-10-07T12:01:30.000Z
---

> Index of every page on this site: [llms.txt](https://skilld.dev/llms.txt)

> **Skill from skilld.dev.** Follow the user's requested action.
> If the user asked to fork this Skill, follow the fork workflow below. Do not execute the Skill instructions while copying it.
> Otherwise, follow the instructions below for this session. You do not need to install anything.
>
> If the user asked to install this Skill, run `npx skilld install heffrey/hordev/writing-hordev-skills`. Install writes the Skill files into the project, so every session loads them.
>
> ## Fork workflow
>
> A fork creates an editable local Skill with its original author and licence. The request authorizes copying and local installation.
> 1. Check `./skills/writing-hordev-skills`, the project lockfile, and selected Agent targets together. If the local directory or installed Skill exists, stop. Never overwrite an existing directory or Agent target.
> 2. Read [source metadata](https://skilld.dev/api/v1/skills/heffrey/hordev/writing-hordev-skills) once. Use sourceUrl, sourceCommit, skillPath, sourceGone, and license. If the source is gone or its path is missing, stop. If license is null, read licence files at the source commit.
> 3. Fetch only the source commit into a temporary Git repository. Do not clone full history. Derive repository_url from sourceUrl, including repository renames. If sourceCommit is absent, resolve the sourceUrl ref once. Set source_commit to that actual commit. Run these commands in one shell call:
>
> ```sh
> git init --quiet "$temporary_dir"
> git -C "$temporary_dir" fetch --quiet --depth=1 "$repository_url" "$source_commit"
> git -C "$temporary_dir" checkout --quiet --detach FETCH_HEAD
> ```
>
> Read applicable licence declarations and notices at that commit. If copying is not permitted, report the restriction and stop.
> 4. Inspect source entries together, then copy the directory containing skillPath into `./skills/writing-hordev-skills`. Use the user's path if selected. Keep the original SKILL.md, relative links, scripts, binary assets, and executable modes. Exclude .git metadata. Reject symlinks and paths outside the Skill directory. After checking entries, use cp -a where available. A regular source directory needs no custom copy script. Do not save this page wrapper as SKILL.md.
> Preserve author credit, notices, and applicable licence files from repository or parent directories. Add PROVENANCE.md with the Skill page, source URL, actual commit, original path, and licence. Retain any existing PROVENANCE.md and record new provenance separately. Batch source inspection, copying, and provenance work where practical.
> 5. In the project root, run `skilld install ./skills/writing-hordev-skills --mode copy --plain`. If skilld is unavailable, use `npx skilld install ./skills/writing-hordev-skills --mode copy --plain`. This known command needs no help lookup. Install does not support --json. Use detected Agent targets, or add --agent for the targets the user selected. Install the local path, never the upstream selector. If installation fails, preserve the local copy and report the exact failure.
> 6. Confirm the local lockfile source and installed Agent copies once. Report the local path, actual commit, and Agent targets. After edits, reinstall the same local path. Upstream updates must not replace it. Do not publish or push unless the user asks.

# Writing Hordev Skills

A skill is a reference guide — imperative instructions for a model to follow in specific situations. Write once, invoke repeatedly across tasks.

## Description Field Is a Trigger, Not a Summary

Your description is the ONLY text a model sees when deciding whether to load your skill. Make it describe WHEN to use, not WHAT it does.

| Bad | Why | Good |
|-----|-----|------|
| "Handles async test flakiness by waiting for conditions instead of sleep" | Summarizes the approach; agent may stop reading | "Use when tests race, hang, or pass/fail inconsistently" |
| "A guide to writing hordev skills with TDD" | Says what it is | "Use when authoring new skills or editing existing ones" |
| "For state management" | Too vague | "Use when managing shared state across parallel subagents" |

Start with "Use when" and list concrete symptoms or situations. Add keywords an agent would search for (error messages, tool names, symptoms).

**Trigger test:** Ask — "would a model match this description to the situation the skill is for, given only this text?" A description that names the skill's own actions ("extracts", "produces", "dispatches") rather than the user's situation ("when a request needs", "when requirements are vague") fails this test. Rewrite until the trigger situation is the subject.

## File Structure

```
skills/skill-name/
  SKILL.md              # Required: overview, patterns, examples
  supporting-file.*     # Only if reusable code or heavy reference
```

Keep everything inline unless it's >100 lines or a reusable tool.

## Frontmatter

Required: `name` and `description`. Name uses letters, numbers, hyphens only.

```yaml
---
name: your-skill-name
description: Use when [specific triggering condition]
---
```

## Hordev-Specific: No Approval Gates

Hordev prioritizes time-to-prototype. Your skill must not add a user round-trip or checkpoint.

**Test:** Does following your skill require the user to approve output before proceeding? If yes, rewrite it to produce a committable artifact without approval.

Example bad: "Sketch the design, wait for approval, then build."
Example good: "Build the design directly (revise if feedback arrives)."

## Editing an Existing Skill

When a skill fails in production (seen via `improving-hordev`), make the smallest change that prevents that failure. Add a rule rather than rewriting sections. Test the specific failure before deploying.

**Red flags:**
- Rewriting whole sections
- Adding multiple new rules at once
- Editing mid-run (wait until task completes)

## Narrow vs. Broad

One skill = one decision point. If your skill covers "decomposing work AND dispatching AND reconciling," split it.

**Test:** Describe your skill in one sentence. If it needs "and," it is two skills.

## Content Structure

```
# Skill Name

## Overview
Core principle, 1–2 sentences.

## When to Use
Concrete situations and symptoms (bullets).
When NOT to use.

## Core Pattern / Quick Reference
Table or list for scanning. Code inline if <50 lines.

## Common Mistakes
What breaks + fixes.

## Red Flags
Signs you are about to violate the skill (discipline skills only).

## Battle cry
The orcish line that fits this skill's moment, and when it earns saying.
```

## Battle Cries

Every skill ends with one, because hordev is a horde and sounds like one. Pick a
line that matches the moment the skill owns — the peon lines for accepting and
grinding, the grunt lines for dispatch and combat, a blessing for a clean finish
— and say when it earns saying. A cry that could sit at the end of any skill is
the wrong cry.

Name the moment it does **not** apply, too. Skills that report failures (`horde-qa`
on a red run, `debugging-in-a-horde` mid-hunt, `assumption-ledger` on a falsified
assumption) must say so explicitly, or the line lands on top of bad news.

Do not invent a new bank. Draw from `using-hordev` § Voice, and add a line there
first if the moment genuinely has no cry.

## Testing Your Skill

**Before deploying:** Run the skill against a fresh model with NO prior conversation context. Does it trigger correctly? Does a model follow it without the authoring conversation's context?

For technique skills: Can a fresh model apply the technique to a new scenario?

For discipline skills: Does a fresh model comply under pressure (time constraint, sunk cost)?

**For editing:** Test the specific failure the edit addresses. Verify new wording does not break compliance in other scenarios.

## Public Repository

hordev is open source. Skills are read by strangers. No machine-specific paths
(no `/Users/<name>/`, no `/home/<name>/`), no personal references, no assumed
local setup. Use paths relative to the project root, or abstract examples.

## Word Count

Target <200 lines. Concrete examples and decision rules are good; explanation and background are expensive. Remove anything that does not change how a model behaves.

## Red Flags — STOP Before Writing

| Excuse | Reality |
|--------|---------|
| "I'll test after I deploy" | Deploy untested = deploy broken. Test first. |
| "It's obvious to me" | Clear to you ≠ clear to a fresh model. Test it. |
| "This adds a checkpoint but it's important" | Checkpoints delay prototype. Hordev rejects them. Redesign. |
| "I'm extending an existing skill" | Test the full skill afterward. Changes can break old scenarios. |
| "Editing is too risky" | Untested edits are riskier. Test the failure, make the change, re-test. |

## Battle cry

"Zug zug." — when a new skill is written and its scenarios pass.

Once, at that moment — not every message, and never two messages running. Full
rules in `using-hordev` § Voice: conversational output only, never in artifacts,
never on bad news.
