harness-authoring
Skill10 starsChanged 31 days agoApache-2.0View on GitHub
Use when authoring or filling AI-harness .md components for a host project — skills, agents, rules, CLAUDE.md, or technical docs. Invoked by /harness-init.
In this repository21 other files it gives its agents.
- .claude/CLAUDE.mdCLAUDE.md
- commitSkill
- design-apiSkill
- design-architectureSkill
- design-erdSkill
- design-sdsSkill
- design-srsSkill
- design-tableSkill
- doc-syncSkill
- flow-initSkill
- flowSkill
- flow-uninstallSkill
- harness-deploymentsSkill
- harness-initSkill
- harness-insightSkill
- integrationSkill
- performanceSkill
- playwright-scaffoldSkill
- prose-reviewSkill
- release-commitSkill
- wiki-initSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 1 is distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 36
If needed, a skill / agent (authoring guide enforced, with companion folders references/examples) — command excluded
- Very specific: line 48
Read the 5 mandatory rule blocks from references/ and merge them into the CLAUDE.md block (preserve anchors).
- Very specific: line 49
not: put the harness:baseline BEGIN/END lines into the marker_upsert content — body only (apply wraps it).
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
harness-authoring
The generation engine of /harness-init. It fills templates/ (skeletons) with references/
(authoring guides and mandatory rules) plus research results to produce the host harness.
Principles
- Concise and lean — keep generated .md short. State a fact in one SSOT, link the rest.
Comments, docstrings,
.md, and rule files carry only what the artifact cannot say itself (rules/harness-rules.md5-2). - Always inject the 5 mandatory rules — put
references/karpathy-principles.md,rule-dry-constants.md,rule-version-pinning.md,security-rule.md, andrule-reuse-first.mdinto the CLAUDE.mdharness:baselineblock. Preserve each rule's anchor (<!-- rule:<key> -->) (guarantees the load path — do not place them standalone in.claude/rules/). - Authoring quality — load and follow
references/skill-writing-guide.md(pushy desc, Why-first, generalization),agent-design-guide.md(separation, reuse, team protocol), andtech-doc-guide.md(technical docs). For official frontmatter, followreferences/authoring-spec.md(official-docs SSOT). - SSOT separation — structural conventions go in a rule (
<framework>-conventions.md); behavioral style, best practices, and anti-patterns go in a doc (docs/code-style/<stack>.md). Do not duplicate the same fact in two places. - No library assertions — outputs (skills, agents, docs) must not hardcode a specific library/tool without evidence
from research or code-analyzer. For greenfield, generalize to a category or ask (reuse candidates go in the reuse
section of
docs/code-style/<stack>.md). Example: "Zod schema" → "the project's validation library (pick one from the candidates if none exists)". - No command generation — never create any output under
.claude/commands/. - No duplicate generation — if a feature overlaps by name+description from detect, skip or ask.
- When flow is detected, defer process discipline to risk-tiers; the harness covers only code style + conventions.
Outputs
CLAUDE.md(baseline marker block + framework conventions summary) · rules (the 5 baseline +<framework>-conventions.md— inside it, put operational directives 1-3 lines each under the<!-- ops-conventions -->anchor section, with the flesh linked to docs/code-style. Do not create new marker blocks)- If needed, a skill / agent (authoring guide enforced, with companion folders references/examples) — command excluded
- Technical docs (folders by category,
tech-doc-guide.mddiscipline):docs/README.md·docs/srs/README.md·docs/srs/<area>.md·docs/sds/README.md(Mermaid) ·docs/code-style/README.md+docs/code-style/<stack>.md·docs/research/(incorporated) ·docs/onboarding/README.md·docs/verification/performance.md(performance SSOT per confirmed stack — stack section + shared API load section, no empty stack sections) ·docs/verification/integration.md(integration-verification SSOT per confirmed stack — stack section + shared E2E section, no empty stack sections) ·docs/operations/commit-versioning-guide.md(Conventional Commits + SemVer + release-tool setup for the detected stack · 0.x policy — always generated regardless of whether flow is detected; authoring guidance:tech-doc-guide.mdoperations section)
Generation Procedure
- Take the detect results + research results (
.harness/research/*.md) + user choices. - For each output, clone the corresponding
templates/*.template.mdand fill placeholders. - Read the 5 mandatory rule blocks from
references/and merge them into the CLAUDE.md block (preserve anchors). Do not put theharness:baselineBEGIN/END lines into the marker_upsert content — body only (apply wraps it). - Fill the technical docs following the folder structure and authoring order of
tech-doc-guide.md(SRS → research incorporation → SDS → code-style → onboarding → docs/README). Source links are mandatory; no speculation. The code-style docs consume the researcher's best-practices-by-lens output as per-lens sub-sections (tech-doc-guide code-style · harness-rules 9-7 · 9-8), not one flat list. If you generate a skill, add companion folders (references/examples) per theskill-writing-guide.mddiscipline. Generatecommit-versioning-guideunderdocs/operations/using thetech-doc-guide.mdoperations section (harness-rules 13-1 · 13-2 — regardless of whether flow is detected; defer tier to risk-tiers, commit message discipline to commit-discipline.md). - Operational directive/standard separation (9-3 · 9-4): take the research operational-axes section, place a
<!-- ops-conventions -->anchor in the rule<framework>-conventions.md, and under it write per-axis directives at ≤ 3 lines each (a category instruction + adocs/code-style/<stack>.md#<axis>link). Concrete standard names, details, sources, and alternatives go in the operational-concerns section of docs/code-style, not in the rule. For greenfield, the rule carries only the category. - Collect everything into a
plan(files[]), validate withharness_scaffold.py validate, then pass it toapply(after preview).
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
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.

