scaffold-harness
Skill3 starsChanged 3 months agoMITView on GitHub
Audits and upgrades one repository, or a workspace of several repositories with a coordinator, to a reliable, maturity-appropriate Agentic Engineering harness without overwriting local truth. Use when bootstrapping or repairing agent instructions, choosing or switching a repository's operating level, setting up a workspace root, coordinator, context map, and member sync for multi-repository work, designing local/MCP/RAG context routing, controlling token bloat, or defining review and quality gates.
In this repository47 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- api-designSkill
- backend-craftSkill
- meilisearchSkill
- design-coreSkill
- design-datavizSkill
- design-flowsSkill
- design-formsSkill
- design-product-uiSkill
- design-researchSkill
- design-reviewSkill
- design-slidesSkill
- design-systemsSkill
- design-webSkill
- agent-syncSkill
- build-autonomous-agentsSkill
- coding-disciplineSkill
- completion-gateSkill
- deliver-dependency-upgradesSkill
- documentation-and-adrsSkill
- grill-harness-with-docsSkill
- learn-agentic-engineeringSkill
- pnpmSkill
- scaffold-monorepoSkill
- shift-left-securitySkill
- start-gateSkill
- update-harnessSkill
- write-a-skillSkill
- frontend-craftSkill
- ansible-automationSkill
- gitea-actionsSkill
- gitea-teaSkill
- manage-infrastructure-as-codeSkill
- multi-stage-dockerfileSkill
- secure-linux-web-hostingSkill
- integrate-product-complianceSkill
- plain-numbersSkill
- product-craftSkill
- run-product-engineeringSkill
- playwright-best-practicesSkill
- testing-strategiesSkill
- writing-coreSkill
- writing-editorialSkill
- writing-engineeringSkill
- writing-marketingSkill
- writing-productSkill
The file
Show its rules and text
We split this skill into the rules it gives an agent
38 rules. About 0 are common, 30 are distinctive, and 8 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈30
Distinctive · estimate
This author's own choices. Worth a look.
8
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 42
Read REFERENCE.md. Read MATURITY.md when assessing or switching a level or changing human oversight.
- Distinctive: line 58
Default to a reliable repository-level harness.
- Very specific: line 78
Ask once whether review surfaces stay free of agent attribution.
- Very specific: line 117
Use templates only for missing artifacts.
- Distinctive: line 121
Read CONTEXT-ARCHITECTURE.md when deciding which artifact owns a kind of context, when instruction growth or token pressure affects the …
- Distinctive: line 126
Read CAPABILITY-GATES.md on every significant harness stewardship pass: decide whether Graphify-class discovery, Headroom/Context Mode …
- Distinctive: line 129
Do not add them without an observed failure mode.
- Very specific: line 135
Use run-product-engineering when the work spans product signals, delivery, production feedback, incidents, or outcomes.
- Distinctive: line 139
integrate-product-compliance: only for confirmed security, contractual, certification, TISAX, PCI, or other control scope.
- Distinctive: line 141
manage-infrastructure-as-code: when agents create, change, provision, or reconcile infrastructure desired state.
- Distinctive: line 146
Keep root agent instructions concise and reference detailed owners, because every session pays for the entry chain before it starts working.
- Very specific: line 152
Write harness artifacts in US English with plain punctuation unless the human explicitly requests another language for a named artifact.
- Distinctive: line 162
Add a harness operating contract for proactive, evidence-backed evolution.
- Distinctive: line 163
Add domain context only when confirmed language or invariants exist.
- Distinctive: line 165
Add learnings when a durable evidence loop is needed.
- Distinctive: line 166
Keep the human README.md accurate when purpose, operating level, or working rules change, because a new reader learns the system from it, …
- Distinctive: line 172
Add ADRs only for accepted consequential trade-offs.
- Distinctive: line 173
Use Skills for repeated probabilistic procedures.
- Distinctive: line 179
When copied bootstrap Skills are managed, record the exact source, immutable per-Skill tag, and resolved commit in a target-owned manifest.
- Distinctive: line 192
Use Hooks, CI, tests, and platform controls for deterministic enforcement.
- Distinctive: line 203
Keep repeatable infrastructure desired state in version control.
- Very specific: line 208
Keep canonical semantics host-neutral.
- Distinctive: line 223
Add event-triggered self-review, independent review, and autonomy review only where their evidence can change a decision.
- Distinctive: line 232
Keep Later coarse, record Never with rationale and a revisit trigger, and create decision or delivery issues only for sufficiently sharp …
- Distinctive: line 239
Keep frontend and backend craft independently installable and useful.
- Distinctive: line 250
Use when the owner wants several repositories to work as one system.
- Distinctive: line 266
Ask the owner which repositories belong and which one coordinates.
- Distinctive: line 289
Commit each repository separately.
- Very specific: line 291
Keep Repository and Team Topology and the Leases item of the template HARNESS.md in the coordinator's contract.
- Distinctive: line 300
Run the documented Fast Check and relevant Full Gates.
- Distinctive: line 301
Verify every referenced local file and command exists.
- Distinctive: line 311
Verify volatile claims have a source, check date, and re-check trigger.
- Very specific: line 316
Verify the Level: line matches the chosen level and its pending gates, and state the remaining gaps and next evidence trigger.
- Very specific: line 324
every declared host can discover the bootstrap Skills, including write-a-skill wherever agents may maintain Skills,
- Distinctive: line 346
all introduced artifacts have a demonstrated purpose,
- Distinctive: line 374
update-harness: - check, install, update, and clean managed Skills
- Distinctive: line 376
run-product-engineering: - run the signal-to-outcome product loop
- Distinctive: line 382
completion-gate: - verify before claiming completion
≈ “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
Scaffold Harness
Build the smallest harness that makes delegated work reliable. Ideal means fit for the repository and its current maturity, not the largest artifact set.
1. Ground the Repository
Inspect before proposing files:
- instruction entrypoints and bridges:
AGENTS.md,CLAUDE.md,GEMINI.md,.cursor/rules/, or local equivalents - repository and domain sources:
README.md,CONTEXT.md, ADRs, specs, architecture docs, code, and tests - package manager, scripts, CI, infrastructure desired state and state backend, deployment, drift detection, observability, security controls, compliance policy, and evidence
- actual Fast Check and Full Gates
- repository boundaries, public integration contracts, owners, and consumers
- existing Skills, Rules, Hooks, MCP configuration, memory, and evals
- the portable Skill-authoring owner and any host-bundled creator, scaffolder, command, plugin, or validator that may overlap it
- effective project, user, and global Skill roots, host precedence, and collisions
- live agent-host capabilities and the freshness of any model, pricing, feature, or community guidance the design would rely on
Resolve discoverable facts from repository evidence, because a harness built on assumed commands or semantics fails on the first real task. Preserve user-written content and local naming.
Complete grounding when existing sources, commands, boundaries, and gaps are identified without relying on invented product semantics.
2. Assess the Target State
Read REFERENCE.md. Read MATURITY.md when assessing or switching a level or changing human oversight. Evaluate each maturity dimension independently, because one strong dimension does not compensate for a weak one:
- product and domain clarity
- codebase changeability
- feedback and quality
- delivery and operations
- repository context
- agent operation
- governance and security
- learning system
- currentness and economics
- context architecture and economy
Default to a reliable repository-level harness. Add grounded tools only when evidence supports the wider delegated unit; each addition is context and maintenance every later session pays for.
When one repository is not enough. Work that regularly spans several repositories - a contract between a service and its consumers, shared rules, several agent sessions in one workspace - needs a workspace root, a coordinator, and one context map. Build that per Multi-Repository Workspace below, after or alongside each member's own harness. Do not add it for one repository; it is sync work every session pays for.
Choose the operating level with the owner: recommend the highest level whose
prerequisites the repository already has, or less when the goal needs less,
ask once, and record the choice per
Choosing and Switching the Operating Level in MATURITY.md.
Rerunning this Skill with a different target level switches up or down through
the same procedure; it is a no-op when the recorded level already matches.
A granted level also needs the matching declaration in the host's permission
context (template HARNESS.md bullet Autonomy is declared where it is enforced).
Ask once whether review surfaces stay free of agent attribution. The default
and the recommendation are yes: keep template HARNESS.md item
Review-surface attribution with its enforcement. A no removes that item and
its enforcement as a unit; record the choice in the target's HARNESS.md
either way, so a later run does not ask again or add it back.
Complete assessment when the current level, target level, and evidence for each proposed addition are explicit.
3. Resolve Decisions
Establish shared understanding for significant work. Use grill-harness-with-docs for unresolved intent, semantics, ownership, architecture, governance, consequential trade-offs, risk, or oversight transitions in any topic. Route resolved material decisions and changes through fresh-context agent critique.
Research facts first. Put genuine decisions to the human one at a time with options, trade-offs, reversibility, evidence, and a recommendation. Wait before implementing the dependent branch.
Complete decision work when every branch is resolved or explicitly blocked.
4. Plan the Smallest Upgrade
Match the requested mode: audit reports the current state, propose presents the smallest viable options, and apply makes only authorized reversible changes.
Map existing files to the ownership model in REFERENCE.md. Prefer updating
an existing source over creating a parallel preferred name.
For every proposed artifact state:
- the observed problem it solves
- its single owning concern
- its consumers
- the smallest verification
- why a reference or existing control is insufficient
Use templates only for missing artifacts. Create optional artifacts lazily.
Merge .serena/ into the target .gitignore; never commit Serena's local
project state and never overwrite existing ignore rules.
Read CONTEXT-ARCHITECTURE.md when deciding which artifact owns a kind of context, when instruction growth or token pressure affects the design, or when large tool output floods sessions. When auditing token bloat, follow Startup Context Budget there.
Read CAPABILITY-GATES.md on every significant harness stewardship pass: decide whether Graphify-class discovery, Headroom/Context Mode economy tools, or memory systems should enter, stay parked, or be removed. Do not add them without an observed failure mode.
Agents in CI, on a schedule, or as a durable service are L5 work and outside this Skill's scope. Use build-autonomous-agents when one bounded product agent or finite workflow is ready for implementation.
Use run-product-engineering when the work spans product signals, delivery, production feedback, incidents, or outcomes. Use product-craft when the target needs value-defined issues or an honest Now/Next/Later/Never investment view. Use integrate-product-compliance only for confirmed security, contractual, certification, TISAX, PCI, or other control scope. Use manage-infrastructure-as-code when agents create, change, provision, or reconcile infrastructure desired state.
5. Apply
- Keep root agent instructions concise and reference detailed owners, because every session pays for the entry chain before it starts working.
- Resolve the current human's preferred collaboration language from explicit preference or conversation evidence; ask once only when it remains unclear. Store personal preference in user-scoped or untracked state unless it is a shared repository rule. Chat language never changes artifact language.
- Write harness artifacts in US English with plain punctuation unless the
human explicitly requests another language for a named artifact. Character
rules and fixer limits:
REFERENCE.mdLanguage and Punctuation. - Preserve an existing repository voice or style owner. Repository prose should be direct and concrete: lead with the problem or working model, state trade-offs and system effects, and remove generic hype, defensive setup, and text that changes no decision or action.
- Reserve first person for artifacts that explicitly speak for the repository owner. Keep agent instructions and operating procedures neutral and imperative, so an agent never mistakes one person's voice for its own rule.
- Add a harness operating contract for proactive, evidence-backed evolution.
- Add domain context only when confirmed language or invariants exist; invented terms become false authority for every later session.
- Add learnings when a durable evidence loop is needed.
- Keep the human
README.mdaccurate when purpose, operating level, or working rules change, because a new reader learns the system from it, not from the agent control plane. - Design canonical instructions, context, state, contracts, and failures for agent comprehension first. Keep README and reference views legible for humans, but do not reproduce human ceremony in the agent control plane.
- Add ADRs only for accepted consequential trade-offs.
- Use Skills for repeated probabilistic procedures.
- Install
write-a-skillin every host scope where agents may create or change Skills. Treat a platform-bundled creator as a thin adapter for native metadata, scaffolding, or validation; it does not own portable Skill behavior. Do not infer cross-host discovery from a successful session on one host, because hosts load Skills from different roots. - When copied bootstrap Skills are managed, record the exact source, immutable per-Skill tag, and resolved commit in a target-owned manifest. A one-off Skills CLI install is a pilot, not a reproducible dependency.
- Derive the actual stack and major versions from target evidence. Keep core craft methods separate from technology profiles, and use update-harness to reuse an owned profile, pilot a current public candidate, or work directly for a one-off gap. Create a project-local Skill only after repeated need provides examples and checks.
- Compare overlapping public workflow collections before activation. Use
upstream
ponytailonly as an optional, piloted implementation-style guardrail when repeated overengineering justifies it; do not weaken validation, security, accessibility, data integrity, recovery, or necessary error handling. - Use Hooks, CI, tests, and platform controls for deterministic enforcement.
- Match activation to how each host actually selects behavior, because
"installed" is not "used". Where a host reads instruction files as behavior,
a rule in
AGENTS.mdis enough. Where a host selects a Skill as a tool from its name and description - Claude Code does - a rule competes with everything else in the instruction chain and routinely loses: an observed session there loaded no Skill across roughly forty tool calls while writing a Skill and making five commits, with the routing rule in context the whole time. On such a host, put the routing in a Hook at the moment of the decision, keep it silent unless something is off, and commit it to the repository so contributors get it with the clone. - Keep repeatable infrastructure desired state in version control. Route infrastructure changes through manage-infrastructure-as-code for plan, policy checks, protected state, controlled apply, drift, and recovery. Treat emergency console work as an incident action that must be reconciled or reversed, not as a second configuration source.
- Keep canonical semantics host-neutral. Use
AGENTS.mdas the portable owner and install the thin baseline bridges for Claude Code (CLAUDE.mdimport), Gemini CLI (GEMINI.mdimport), and Google Antigravity (.agents/rules/harness.md). Codex, Cursor, and Pi consumeAGENTS.mddirectly. Add other bridges only for hosts the repository actually uses, and reference canonical owners instead of copying policy, so one rule never drifts into several versions. - Classify source authority, freshness, locality, shape, activation, persistence, access, and verification before adding MCP, RAG, memory, or a local projection. Keep stable session-critical routing local and query live systems only for task-relevant current information or actions.
- Retrieve at the lowest sufficient resolution and keep raw bulk output outside the active context when the host supports it. Use one filtering owner per data path; add compression only after a representative baseline exposes a residual problem.
- Add event-triggered self-review, independent review, and autonomy review only where their evidence can change a decision; a review that cannot change the next action is cost without effect.
- Re-evaluate an owner when its evidence expires, a host or tool changes, or representative tasks expose a mismatch, and keep, change, remove, or replace it. Do not preserve incremental structure when replacement is the smaller reliable system.
- For product work that uses shared investment or issue tracking, at any level, treat Now/Next/Later/Never as investment decisions rather than date promises. Keep Later coarse, record Never with rationale and a revisit trigger, and create decision or delivery issues only for sufficiently sharp Now or Next work. Raw intake records may remain without becoming commitments.
- For product engineering, reject specification -> implementation -> testing -> deployment as a handoff pipeline. Use run-product-engineering for evolutionary DDD, bounded spikes, vertical TDD, shift-left security/operability, production feedback, and repeated evolution.
- Keep frontend and backend craft independently installable and useful. Route shared end-to-end discipline through coding-discipline, while each craft Skill retains its own thin-UI, boundary, data, operability, and experience guidance.
- Integrate compliance through target-owned risk, controls, evidence, and release policy. Encode stable enforceable controls as tested policy through integrate-product-compliance; keep interpretation, scope, risk acceptance, and assurance claims with named humans.
Multi-Repository Workspace
Use when the owner wants several repositories to work as one system. The
shape: a workspace directory holds the repositories side by side; its root
AGENTS.md names the coordinator; the coordinator is an ordinary repository
whose Markdown files every session synchronizes through; each member carries a
thin pointer to it.
workspace/
AGENTS.md root instructions every session reads
coordinator/ AGENTS.md, HARNESS.md, CONTEXT-MAP.md, SYNC.md, STATUS.md
service-a/ its own harness + the member snippet in AGENTS.md
web-app/ its own harness + the member snippet in AGENTS.md- Audit. List the repositories in the workspace directory with their
remotes, existing
AGENTS.md, checks, and any existing coordinator or map. Ask the owner which repositories belong and which one coordinates; an existing repository that already holds shared rules is the better coordinator than a new one. - Propose. Show the planned tree, the member rows, the relationships you found evidence for (shared contracts, packages, deploy order), and which existing files each template would merge into. Wait for the owner's yes before creating a repository or remote.
- Apply. Scaffold the coordinator as a repository with the single-repo
templates, then add CONTEXT-MAP.md,
SYNC.md, and
STATUS.md. Write the
workspace root AGENTS.md with the
templates/CLAUDE.md and
templates/GEMINI.md bridges beside it; if the
workspace directory is not under version control, say so, because that
file then has no history. Give every member its own harness (steps 1-5 of
this Skill in that repository) and paste
MEMBER-SNIPPET.md
into its
AGENTS.md. Merge into existing files; never replace a member's local truth with a template. - Verify. From a fresh session in one member, confirm it reaches the
coordinator's
HARNESS.md,SYNC.md, andCONTEXT-MAP.md; every map path exists; every remote is a full URL; every member carries the same snippet. Commit each repository separately.
Keep Repository and Team Topology and the Leases item of the template
HARNESS.md in the coordinator's contract. Keep the coordinator to
relationships, shared rules, and status. When a manual sync check repeats -
snippet drift, unmapped repositories, stale leases - turn it into the
coordinator's Fast Check; this Skill does not ship one, because each workspace
has its own hosts and layout.
6. Verify
- Run the documented Fast Check and relevant Full Gates.
- Verify every referenced local file and command exists.
- Confirm each active host resolves the intended Skill versions without
collisions and agent instructions remain concise. When Skill authoring is
in scope, verify that
write-a-skillis the resolved portable owner and any native creator remains an adapter. The public catalog currently install-tests Codex, Cursor, Claude Code, and Gemini CLI. Treat Pi, CI, and later runtimes as candidate hosts until the target has a native adapter and a representative bootstrap check. - Review the diff for overwritten local truth, speculative layers, and customer or product assumptions.
- Verify volatile claims have a source, check date, and re-check trigger; do not retain copied price tables or assumed model availability.
- For a context-economy change, verify the complete routing path and compare successful-task quality, tokens, latency, retries, and recovery with the baseline.
- Verify the
Level:line matches the chosen level and its pending gates, and state the remaining gaps and next evidence trigger.
The scaffold is complete only when:
- instructions and source routing are discoverable,
- the declared host matrix is backed by verified thin bridges or an explicit
non-interactive adapter that loads
AGENTS.md, - every declared host can discover the bootstrap Skills, including
write-a-skillwherever agents may maintain Skills, - a human README or local equivalent explains where to start, the current operating level, and what would justify the next one,
- domain facts and decisions have explicit owners,
- a real Fast Check and Full Gates are named,
- uncertainty and escalation behavior are defined,
- cross-session learning has one durable owner,
- shared understanding has an explicit entry and exit frame,
- review loops route resolved material work to fresh-agent critique and genuine unresolved decisions to a human, with triggers, stop conditions, and an action when they fail, including evidence-gated dependency-bot PR handling (inspect jump, run checks, merge or comment - never silent-merge or silent-ignore),
- context routing has one owner per data path, visible authority and freshness, and preserves required evidence,
- infrastructure automation has an owned desired state, reviewable plan, protected state, policy gates, drift path, runtime verification, and credible recovery,
- for a multi-repository workspace, every member reaches the coordinator through the same snippet and the context map matches the repositories on disk,
- all introduced artifacts have a demonstrated purpose,
- verification results are reported.
Templates
| Artifact | Template |
| Root instructions | templates/AGENTS.md |
| Claude Code bridge | templates/CLAUDE.md |
| Review-surface attribution check | scripts/verify-agent-attribution.py, tested by tests/test_verify_agent_attribution.py |
| Gemini CLI bridge | templates/GEMINI.md |
| Google Antigravity bridge | templates/.agents/rules/harness.md |
| Harness contract | templates/HARNESS.md |
| Domain language | templates/CONTEXT.md |
| Durable learnings | templates/LEARNINGS.md |
| Tool entrypoints | templates/TOOLS.md |
| Local tool state ignore | templates/.gitignore |
| Workspace root instructions | templates/workspace/AGENTS.md |
| Coordinator context map | templates/workspace/coordinator/CONTEXT-MAP.md |
| Coordinator sync rules | templates/workspace/coordinator/SYNC.md |
| Coordinator status and leases | templates/workspace/coordinator/STATUS.md |
| Member snippet | templates/workspace/coordinator/MEMBER-SNIPPET.md |
| Workspace template checks | tests/test_workspace_templates.py |
Related Skills
- grill-harness-with-docs - ground, critique, and resolve material decisions
- agent-sync - evolve the harness from evidence across sessions
- update-harness - check, install, update, and clean managed Skills
- build-autonomous-agents - implement a bounded product agent or workflow
- run-product-engineering - run the signal-to-outcome product loop
- integrate-product-compliance - integrate confirmed control scope and evidence
- manage-infrastructure-as-code - manage desired state, plans, state, policy checks, apply, drift, and recovery
- coding-discipline - make minimal implementation changes
- completion-gate - verify before claiming completion
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.

