Harness Engineering
The harness is what separates "generic AI output" from "code that fits your project."
π‘
Without harness: "Here's a React component" (generic)
With harness: "Here's a functional component using your design tokens, following your naming convention, tested against your business rules"
Setup
Harness is generated automatically during npx buildcrew:
npx buildcrew
# Step 3: Generate project harness? (Y/n) β scans your codebase
# Step 4: Pick additional templatesOr generate separately:
npx buildcrew initOpen Directory
.claude/harness/ is an open directory. Not limited to templates.
.claude/harness/
βββ project.md β core (auto by init)
βββ rules.md β core (auto by init)
βββ erd.md β template
βββ architecture.md β template
βββ design-system.md β template
βββ my-custom-notes.md β your own file
βββ anything.md β agents read it allAgent Routing
The orchestrator routes the right harness files to the right agents:
| File | Routed to |
|---|---|
project.md, rules.md | All agents |
erd.md, architecture.md, api-spec.md | developer, reviewer, security-auditor, investigator |
design-system.md | designer, design-reviewer |
glossary.md, user-flow.md | planner, designer, browser-qa, canary-monitor |
env-vars.md | developer, security-auditor |
| ALL files | reviewer, security-auditor, thinker, architect, qa-auditor |
Managing
npx buildcrew harness # Show status
npx buildcrew add # List templates
npx buildcrew add erd # Add template
npx buildcrew init --force # Regenerate core files (backs up existing)When to Update
- Stack changes β
architecture.md - New DB table β
erd.md - New business rule β
project.mdorglossary.md - Bad pattern found β
rules.md"What to avoid" - New API β
api-spec.md