/harvest:harvestfrom harvest
This skill should be used at the end of a task that produced something worth repeating — the user says "save this as a skill", "remember how to do this", "make this reusable", "turn this into an agent/workflow", "harvest this session", or a capability-broker run found a procedure, site flow or tool combination that should not be rediscovered next time. Decides the right artifact type, strips anything machine- or secret-specific, writes it in the standard format, and lands it through the operator's content repo — not as a loose file in ~/.claude.
Ships in harvest. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
A session that figured something out (how a site's flow works, which CLI flags matter, the
order that avoids a footgun) should leave that knowledge somewhere the next session loads it.
The failure this prevents is not forgetting — it is saving into the wrong place: a
loose file in ~/.claude that no repo, pin or review ever sees, and that a declarative
harness may delete on the next activation.
┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐ ┌──────────┐
│ 1. Worth │-->│ 2. Type │-->│ 3. Clean │-->│ 4. Write │-->│ 5. Land │
│ keeping? │ │ artifact │ │ portable │ │ standard │ │ PR + pin │
└──────────┘ └──────────┘ └──────────┘ └──────────┘ └──────────┘
Extract first, in this order (from Letta Code's reflection-v2, Apache-2.0): what a
session teaches is usually not the procedure it set out to do.
Drop anything ephemeral before judging it: line numbers, exact error strings, temp paths,
ports, commit hashes, one-off values. Distil the pattern, not the event ("merges armed by
GITHUB_TOKEN start no workflows", not "PR #7's push run was missing"); the event can go in
as the evidence for the pattern. Write relative dates as absolute ones. Across several
sessions, prefer patterns that recur, and let the latest evidence win a contradiction.
Then, for each candidate:
Repeats: will this come up again (a yearly filing, a recurring migration, a tool used monthly)? One-off answers are not skills.
Hard-won: did it take measurement, failed attempts or reading that the next
session would repeat? Common knowledge is not worth the context it costs. The
counterfactual test (from EveryInc's ce-compound): if this were never written down,
would the next session make the same mistake or redo the same digging? No → drop it.
One learning per harvest; a session with three gets three decisions.
Not already covered: search where this knowledge may already be written, not just where skills live:
find-skills;gh search code --owner <owner> '<key term>', or grep -ril over a checkout's
docs/ and .github/);Found it written down? Cite and adapt it; don't rediscover it. (Missed 2026-09-23: a
harvested skill armed auto-merge with GITHUB_TOKEN while the harness repo's
docs/auto-merge-and-merge-queue.md already recorded why an App token is required,
so it needed a follow-up PR.) Found it partly covered? That is an update or extend
of the existing skill (§ 2), not a new one.
If any answer is no, say so and stop. Declining to harvest is a valid outcome.
Skills are not the default. A fact, a preference or a correction is memory (or a hook rule); a one-off task state belongs nowhere. Reach for a skill only for a repeatable, multi-step procedure that clearly generalizes beyond this session.
| Knowledge is… | Artifact | Lives in |
|---|---|---|
| A procedure with steps, checks and pitfalls | Skill (SKILL.md + optional references/, scripts/, tests/) | Content repo, as a one-skill plugin — see § Adapter. There is no top-level skills/ tree |
| A role with a restricted tool set | Subagent (agents/<name>.md) | Content repo, or a plugin |
| A fan-out orchestration that worked | Workflow — save from /workflows with s | Project or ~/.claude/workflows/, then the content repo |
| Hooks, commands and skills that ship together | Plugin | Content repo plugins/<name>/ + marketplace entry |
| A fact about the user or a project | Memory, not an artifact | The memory system / project CLAUDE.md (claude-md-management's /revise-claude-md drafts that diff, if installed) |
| A correction that should block an action next time | Hook rule | hookify (if installed) writes it from the conversation; else a plugin hook |
| Specific to one repo | Project config | That repo's .claude/, never the global set |
Choose a plugin only when there is a hook or command that must travel with the skill.
For a procedure, pick exactly one operation, preferring to modify over creating:
| Operation | When |
|---|---|
update | An existing skill covers it, but a step is wrong, dangerous or outdated. Fix that step in place; keep the rest. |
extend | An existing skill covers a similar workflow; this is a new variant or edge case. Add a section, don't duplicate. |
deprecate | An existing skill is obsolete, harmful or replaced. Add deprecated: true (and replaced_by: <name>) to its frontmatter with a note at the top; skill-curator retires it from the harness. |
split | One skill has drifted into two distinct procedures and that hurt this session. Rarely. |
create | Genuinely novel, with concrete commands and values, and nothing covers it even partly. |
none | One-off, trivial, informational, already covered, or better as memory. |
Tie-breakers: unsure between create and none → none. Unsure between create and a
modify operation → the modify operation.
Contradictions are fixed at the source. When a learning contradicts a skill or memory, correct the stale text where it lives; never append the new version alongside the old.
Remove or generalise, in this order:
/Users/<name>/… becomes $HOME/XDG or a placeholder.Frontmatter: name (kebab-case, matches the directory), description (third person,
quoting the phrases a user would actually say, so the skill triggers on them), version.
Body, kept under ~500 lines with detail pushed into references/:
Re-read the description against the original request: would this session have triggered it?
Before landing, check:
create, scan the skill list once more; a partial overlap
you missed means extend instead.scripts/, references/ or assets/ path the
SKILL.md names is really there.deprecate or split, nothing (other skills,
index/routes.json) still points at the old name or path.Drafting and testing — hand off to skill-creator (claude-plugins-official) when it is
installed, rather than hand-rolling the checks. Harvest decides whether, what type,
what to strip and where it lands; skill-creator owns does it work:
quick_validate.py checks the frontmatter.Its evals and optimization loop call claude -p repeatedly and cost tokens: worth it for a
new skill, skip for a one-paragraph pitfall added to an existing one.
Detect the harness first (as in capability-broker): if ~/.claude/settings.json
resolves into a store, skills are declared, not dropped into ~/.claude/skills.
With a declarative harness — three steps, and only the last one delivers:
skills/ tree to drop one into.enabledPlugins entry keyed <plugin>@<marketplace> in the client's settings, and
nothing else. Where the harness cannot write that key, /plugin is the only lane and the
write is machine-local. A change to an artifact that is ALREADY enabled needs none of
this — the marketplace's auto-update delivers it.VERIFY BY NAME — not by the merge, and not by the harness's list. The plugin must appear
in enabledPlugins AND in a live session's skill listing; "declared" and "loaded" are
different facts. The cost is not cosmetic: prior-art-recon merged green, was enabled
nowhere, and a later session went to use it and could not load it.
For immediate use in the current project only, a copy under that project's
.claude/skills/ is acceptable if it is deleted once the plugin is enabled (two copies of
one skill shadow each other).
Without a harness: a personal skill goes to ~/.claude/skills/<name>/, ideally a
symlink into a version-controlled directory so it is not the only copy.
| Piece | Value |
|---|---|
| Content repo | github:kattakath/skills (plugins/<name>/, .claude-plugin/marketplace.json) |
| Harness repo | github:kattakath/nix-config |
| Prior art to search | nix-config docs/ (ADRs, runbooks), .github/workflows/ comments, .claude/rules/; gh search code --owner kattakath |
| Delivery | git marketplace kattakath with auto-update: a merge to main ships the CONTENT of an already-enabled plugin, no pin. It does not enable one — see Enable. |
| New skill | a one-skill plugin: plugins/<name>/.claude-plugin/plugin.json + plugins/<name>/skills/<name>/SKILL.md, plus a marketplace entry with "source": "./plugins/<name>" (never "./" + strict/skills — that shim is for foreign repos; see its CLAUDE.md). Keep the list alpha-sorted by name. |
| Index | a route in index/routes.json (goal → steps; gap: true if no outside source covers it), then python3 scripts/build-index.py. CI fails if a skill has no route. An outside source that did the job goes in index/sources.json instead of a new skill. |
| Enable | Not the Nix plugins list — that is a catalogue and enables nothing (claude-plugins.nix feeds it to an id set plus one assertion; extraKnownMarketplaces reads only source/autoUpdate). Measured 2026-10-02: nix-config #751 added a name there expecting it to go live, nothing happened, reverted in #754. Two lanes actually enable: local.claudePlugins.declared (an attrsOf bool of <plugin>@<marketplace> ids — ADR-008's declarative lane, landed in nix-config #758) and /plugin at runtime, which overrides per machine. The always-on floor is a small hardcoded set — read the names in claude-plugins.nix, do not copy them into prose (see the note below). |
| Harness checks | git add -A && nix flake check; PR title per its pr-title rule |
| MCP servers | never harvested here — adopted through nix-config's mcp-scout, which declares them in the owning plugin's .mcp.json |
Do not name sibling plugins in prose. skill-curator's reference detector counts a
backticked plugin name anywhere in another plugin's markdown as a dependency, so citing one as
an example silently reclassifies it from stale to exempt and exempts it from curation. An
earlier revision of this file named the three always-on plugins in the Enable row; the only signal
was a want stale, got exempt failure naming one of them, in a test whose name mentions neither prose nor
harvest. Cite a count and a file, not a name.
Harvested: <name> (<artifact type>)
Operation: <create | update | extend | deprecate | split | none>
Why: <repeats / hard-won / not covered — one line each>
Skipped: <candidates considered and dropped, and why>
Cleaned: <what was removed or generalised>
PR 1: <content repo branch or URL>
PR 2: <harness branch or URL, or "after PR 1 merges">
Loaded: <enabledPlugins entry + skill listing confirmed | project copy only | NOT yet enabled>
What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub kattakath/skills --plugin harvest