Skip to content

Agents and LLMsHarness and toolingreference

A skills system for coding agents

A skill is an on-demand instruction file. Each skill carries a name and a one-line description that the model sees on every turn, and the body loads only when the description matches the task. This page covers how the pi harness keeps its skill corpus useful at scale: what a skill file holds, how the description works as a trigger, what the lint checks, how a subset reaches a second harness, and how two extensions push the model to open the matching file.

The worked example is the pi harness skill tree, the subject of the hub at The pi harness journey. Counts and thresholds were read from the harness source on 2026-10-20, except where a line says otherwise. The lint’s checks and config come from the linter and its JSON (JavaScript Object Notation) config file, and the extension behaviour from their headers and source. The last section lists what applies to any skill corpus.

TL;DR:

  • Name and description are in context on every turn. Across the 84 top-level skills, descriptions total 37,323 characters (mean 444, longest 499) and names 1,079, measured 2026-10-31. The 7 work skills under skills/work/ bring it to 91 skills and 40,543 characters, longest 610.
  • The description lists triggers (“Use when…”) and no workflow. A description that summarises the process gets followed instead of the body.
  • A lint runs at commit time and the pre-commit hook blocks on errors. It covers description length, body size, smart punctuation, retired terms, stale verified dates, unreferenced sibling files, dead paths and references to skills that do not exist.
  • 74 of the 84 skills reach Claude Code through per-skill symlinks. The directory listing is the allowlist.
  • skill-guard blocks a matching tool call once with a nudge. skill-first re-injects a reminder for up to 3 injections per session until a skill file is read.
  • After a milestone, a stocktake pass updates every skill whose system changed, in the same commit as the system change.

one skill directory (84 in the corpus)description(trigger text)modelevery turnSKILL.md body(<= 500 lines)sibling fileslinks to.claude/skills74 symlinkspromoted per skillreads on a matchskill-guard,skill-firstnudge if skippedskills-lint(pre-commit)checks at commit

Each skill is a directory under .pi/agent/skills/<name>/ with a SKILL.md and optional sibling files. Only the description reaches the system prompt. The body and siblings are read on demand.


PartWhen it is loadedContext costCap
nameEvery turn, every sessionAbout 13 characters per skill on average (1,079 across the 84 top-level skills, 2026-10-31)Must equal the directory name
descriptionEvery turn, every session37,323 characters across the 84 top-level skills, 40,543 with the 7 work skills (2026-10-31)Warn past 500 characters, error past 1024
Body (SKILL.md)When the description matches the taskOn demandWarn past 500 lines. Reference over about 100 lines goes in a sibling file
Sibling filesWhen the body points at themOn demand, one level deepNo cap. Linked by plain filename, never @
metadata.verifiedLint onlyNone per turnWarn past 90 days

Every request pays for every description, so the 500-character cap is a cost ceiling. At the cap, each added skill adds up to 500 characters to every request for as long as the skill exists.

The description answers one question: should the model read this file for the task it is about to do? The authoring rules, from the writing-skills skill1:

  • Start with “Use when…” (or “Use ONLY when the user explicitly asks” for a skill that should not auto-fire). The lint warns on anything else.
  • List concrete triggers: symptoms, error text, tool names, file names, user phrases. They are the terms the model matches against the prompt.
  • Leave out the workflow. A description that says “covers the X workflow, providing Y and handling Z” is followed instead of the body. In the case recorded in writing-skills, a description that said “code review between tasks” produced one review where the body specified two.
  • End with a “NOT for <sibling>” clause where two skills can be confused.
  • Write in the third person, under 500 characters. The lint errors past 1024, where pi refuses to load the skill.

The writing-skills description1 follows these rules:

Use when creating a new SKILL.md, making substantial structural edits to an existing one, or deciding whether a technique deserves a skill at all - frontmatter format, description-trigger calibration, body length, sibling reference files, pressure-testing a skill with subagents, running skills-lint. Do not auto-fire on minor description tweaks. NOT for the prose voice of a doc (erfi-voice) or the loop harness a skill might describe (self-correcting-loop).

It names concrete actions (“creating a new SKILL.md”, “running skills-lint”), an anti-trigger (“do not auto-fire on minor description tweaks”) and the siblings to use instead.

A body that loads competes with the conversation for context, so it stays under 500 lines (the lint warns past that). Reference over about 100 lines moves into a sibling file, linked from SKILL.md by plain filename with a “read when…” cue. The self-correcting-loop skill is the case in point: the body holds the overview, the manifest reference and a file table, and the governor, models, sensors and lessons each live in their own file under docs/.

Siblings sit one level deep (SKILL.md -> sibling.md), never chained, so no rule is reachable only through a second link.

The @path/file.md syntax force-loads a file immediately, before the agent needs it. The lint warns on every @-link, and the authoring skill says to use a plain filename with a read-when cue.

skills-lint.py runs on every skill. The pre-commit hook blocks on errors and prints warnings. The run on 2026-10-20: 84 skills, 0 errors, 1 warning, 10 waived.

CheckLevelWhy
Frontmatter parses and name equals the directoryERRORA broken frontmatter cannot be loaded
Description over 1024 charactersERRORpi refuses to load the skill
Description over 500 charactersWARNPaid on every turn
Description starts with “Use when” or “Use ONLY when”WARNNames its triggers
Description has no workflow or coverage verbsWARNA process summary gets followed in place of the body
Body over 500 linesWARNCompetes with the conversation for context
No smart punctuation (em/en dash, curly quotes, ellipsis, nbsp)ERRORMis-decodes when pasted into non-UTF-8 (Unicode Transformation Format) composers
No @-force-load linksWARNLoads the file before it is needed
Every supporting file referenced from SKILL.mdWARNAn unreferenced sibling is never found
Every ~/path exists on diskWARNA dead path leads nowhere
No retired terms (from .lint.json)ERRORA retired term is a stale fact the agent will act on
Every skill reference resolvesERRORA reference to a missing skill is a broken link
Dated entries under max_dates (default 8)WARNFold lessons that became defaults into plain rules
metadata.verified under verified_max_days (default 90)WARNSignals a skill not re-read since its system changed
Claude Code symlinks not danglingERRORA promoted skill whose source was deleted breaks the second harness
docs source names are real docs-mirror topicsWARNA nonexistent source sends the agent on a dead search

When a system is retired or renamed, its old name goes into the retired map of .lint.json with a hint naming the replacement:

{
"retired": {
"opencode": "harness retired 2026-08-15; say pi / Claude Code",
"Unraid": "servarr is NixOS + ZFS since 2026-08-26 (say 'servarr NAS'; Unraid only as dated history)",
"Vaultwarden": "no longer the canonical secret store; SOPS-encrypted .env in git is (2026-09-04)"
}
}

A skill that contains a retired term fails the lint unless it has a per-skill allow entry. The allow list is for historical mentions: the writing-skills skill mentions “superpowers”, a retired skill set, in its anti-patterns section, so it has an allow entry for it. The pre-commit hook blocks the commit until the term is gone or allowed.

metadata.verified is optional frontmatter:

metadata:
verified: 2026-09-30

The date means a human re-read the skill and confirmed it matches the system it documents. The lint warns when it is older than 90 days.

.config/git/hooks/pre-commit runs skills-lint.py when a commit stages files under .pi/agent/skills/ in a repo that ships the linter. It prints warnings and fails the commit on errors, naming the offending skills and offering --no-verify as the bypass.

A model skips skills it should read, most often where its trained behaviour overlaps the skill: git, Docker, Terraform, Fly. The skill-guard.ts header cites anthropics/claude-code#30387, which reports about a 50% miss rate on trained-overlap skills while novel-tool skills fire reliably2. Two extensions respond, and they complement each other.

skill-guard.ts works at action time and blocks. On before_agent_start it matches the user’s prompt against a static rule table and injects a message pointing at the matching skill. On tool_call, when the model is about to write, edit or run a command in a domain a skill covers, it blocks the call once with a nudge to read the skill file, and the retry passes. Each rule fires at most 3 times per session, and the same command never blocks twice.

skill-first.ts works at intent time and never blocks. The skill-guard nudge fires once at the start of a turn, so a model that ignores it hears nothing more. skill-first re-injects a context reminder on later turns until the model reads a skill file, up to 3 injections per session. It uses pi’s anchor mechanism so each copy keeps its position across requests, which keeps the local engine’s single-checkpoint prompt cache stable. Reading any skill file disarms it.

A discipline skill, one that constrains agent behaviour under pressure, gets a baseline test before it ships. The method, from writing-skills1:

  1. Run the scenario with a subagent that does not have the skill. Record the exact rationalisations and failures.
  2. Write the skill against those failures.
  3. Re-run with the skill and close the loopholes that appear.
  4. Build a rationalisation table from all iterations and a red-flags list the agent can check itself against.

The rationalisations the skill lists for skipping the baseline:

ExcuseReply
“Skill is obviously clear”Clear to you is not clear to other agents. Test it.
“It’s just a reference”References can have gaps. A retrieval check takes five minutes.
“I’ll test if problems emerge”Problems mean agents cannot use the skill. Test before deploying.
“Academic review is enough”Reading is not using. Test application scenarios.

The testing-skills-with-subagents.md sibling file in the writing-skills directory has the full method and worked iterations.

Skills live in .pi/agent/skills/<name>/, since pi is the primary harness. A skill reaches Claude Code only through a per-skill symlink in .claude/skills/. The directory listing is the allowlist: 74 of the 84 skills are promoted, plus a real lsp-servers/ plugin directory that is not a skill symlink.

The promotion rules, from the dotfiles AGENTS.md “Agent-surface routing” section3:

  • Methodology, infrastructure and operations skills are eligible when they are useful from the second harness.
  • Private-corpus tools (anything touching personal session data) are never promoted.
  • Media and GPU (graphics processing unit) generation and personal operations stay pi-only by default.

There is no config file, registry or sync pipeline. A skill for both harnesses gets one ln -s plus a stow run. A pi-only skill gets no symlink. The lint errors on a dangling symlink, which a deleted source directory leaves behind.

After a milestone ships (plan tasks checked off, a feature merged, a phase closed), the stocktake pass reconciles the harness’s records with the systems they describe. The rule, from the stocktake skill4:

Skills track the system they document. Any skill in the record set whose system changed gets its update in this pass, and skills-lint runs on it.

The dotfiles AGENTS.md adds that the skill is updated in the same commit as the system change3. The method, from the stocktake skill4:

  1. Define the record set by searching, not from memory: in-repo docs, cross-repo mentions, standing instructions, memory, the board, session findings and local scratch.
  2. Inventory the facts: what the code is now, what shipped since the last stocktake, what is deployed.
  3. Diff and record every item: stale task status, missing command, deviation shipped without a note, wrong path or number.
  4. Fix the records, not the code. Move every open item found outside the board onto it.
  5. Reconcile the board: review every open card, move or comment on stale ones, create new ones.
  6. Commit with a docs: prefix before the next feature commit.

A skill needs no update when only a system it reads from changes. The router-operations skill documents the router CLI (command-line interface), so a router config change that the CLI merely observes leaves the skill alone (stocktake/SKILL.md).


The skill counts, lint thresholds, retired-term list and symlink counts are specific to this setup. These properties are not:

  1. Descriptions are paid for on every request, so cap them. The cap is a budget of context characters per skill.
  2. Descriptions list triggers and no workflow. A process summary is read in place of the body.
  3. Lint at commit time, and let errors block. A lint that only prints warnings is not read.
  4. Enforce retired terms mechanically. A blocklist entry fails the lint until the text changes or an explicit exception is added, where a prose rule is forgotten.
  5. Date each skill’s last human check and warn past a maximum age. The date records a re-read against the system, not the last edit.
  6. Give a second harness a subset, one symlink per skill, so each promotion is an explicit decision and no config file can drift.
  7. Pair the passive description with nudges: one that blocks a tool call once, and one that re-injects a reminder until a skill is read.
  8. Update the skill in the same commit as the system, and run a stocktake after each milestone to catch what slipped.

New technique or ruleReusable, andnot project-specific?Constrains agentbehaviour underpressure?yesRepo AGENTS.md,or automate itnoPressure-test withsubagents firstyesWrite SKILL.md:description = triggers,body <= 500 lines,reference in siblingsnoUseful from thesecond harness?Add a per-skill symlinkin the second harnessyesLeave pi-only,no symlinknoRun skills-lint, commit withthe system change

The same decision as text:

  1. A one-off solution or a project-specific convention goes in the repo’s AGENTS.md or is automated. It does not become a skill.
  2. A discipline skill is pressure-tested with subagents before it is written: run the scenario without the skill, record the rationalisations, write the skill against them.
  3. The description lists triggers and ends with NOT-for siblings, the body stays under 500 lines, and reference over about 100 lines goes in a sibling file.
  4. skills-lint runs, and the skill is committed together with the system change it documents.
  5. A skill that is useful from the second harness gets a per-skill symlink. Any other stays pi-only.

ClaimHow it was checkedStatus
84 skills in the pi corpusls on .pi/agent/skills/, 2026-10-20measured
Description total 37,323 characters, mean 444, longest 499; names 1,079 characters (top level); 40,543 and longest 610 with skills/work/frontmatter of all 91 SKILL.md files parsed as YAML (YAML Ain’t Markup Language), 2026-10-31measured
74 skills promoted to Claude Codels on .claude/skills/ minus the real lsp-servers directory, 2026-10-20; cross-referenced against the hub pagemeasured
Lint: 0 errors, 1 warning, 10 waivedpython3 scripts/skills-lint.py 2>&1 | tail -5, 2026-10-20measured
Description cap: 500 characters warn, 1024 errorskills-lint.py:98-99read from source
Body cap: 500 lines warnskills-lint.py:105read from source
Retired terms: 17 entries in .lint.json.lint.json retired map, counted 2026-10-20 and again 2026-10-31read from source
metadata.verified max age 90 days, max_dates 8.lint.json verified_max_days and max_datesread from source
Pre-commit hook blocks on lint errors.config/git/hooks/pre-commit:47-58read from source
skill-guard blocks once per exact command and rule, at most 3 fires per ruleskill-guard.ts header and MAX_FIRES_PER_RULEread from source
skill-first re-injects at most 3 times per sessionskill-first.ts header and PI_SKILL_FIRST_MAX defaultread from source
About 50% miss rate on trained-overlap skillsanthropics/claude-code#30387, as cited in the skill-guard.ts headerreported upstream, not re-measured
Description-as-shortcut failurewriting-skills/description-writing.md:22read from source
Stocktake rule for skills and the 6-step methodstocktake/SKILL.md:133 and the skill’s checklistread from source
Same-commit rule for skillsdotfiles AGENTS.md, skills lint section (line 569)read from source
Pressure-testing method and excuse tablewriting-skills/SKILL.md:349-353 and testing-skills-with-subagents.mdread from source
Promotion rulesdotfiles AGENTS.md, “Agent-surface routing”read from source

  1. The writing-skills skill, .pi/agent/skills/writing-skills/SKILL.md, in the dotfiles repo. Read as of 2026-10-20. ↩ ↩2 ↩3

  2. anthropics/claude-code#30387, “Custom skills are not reliably auto-triggered by the model” (closed not-planned). Cited in skill-guard.ts header comment. Read 2026-10-20. ↩

  3. AGENTS.md in the dotfiles repo, “Agent-surface routing” section and the skills lint section (“Freshness”, “Skills track the system”). Read as of 2026-10-20. ↩ ↩2

  4. The stocktake skill, .pi/agent/skills/stocktake/SKILL.md, in the dotfiles repo. Read as of 2026-10-20. ↩ ↩2