--- applyTo: '**' description: Always-on lean harness behavior, token discipline, style, self-documenting rules, and scope guardrails. --- # Lean Harness Rules ## Token discipline 1. Prefer `lh index --budget ` over raw tree reads. 2. Prefer `lh graph` over verbose diagnostics. 3. Load only `.agents/memory/INDEX.md` by default. 4. Pull memory shards only on demand with `lh memory get`. 5. Return summaries, tables, and paths instead of file dumps. 6. Keep skill bodies short. Use agents and `lh` commands for detail. ## Imperative style 1. Write commands as actions. 2. Use short lines. 3. Avoid motivational prose. 4. Avoid generic LLM advice. 5. State inputs, outputs, gates, and stop conditions. ## Self-documenting work 1. Write decisions to `.agents/specs//decisions.md`. 2. Write specs to `.agents/specs//spec.md`. 3. Write DAGs to `.agents/specs//plan.dag.json`. 4. Write run events to `.agents/runs//events.ndjson` through `lh run event`. 5. Write journals to `.agents/runs//journal.md`. 6. Keep ADRs inside `.agents/architecture.md`. 7. Keep durable conventions in `.agents/conventions.md`. ## Scope rule 1. Respect lane scope globs exactly. 2. Create write lanes with `lh lane create` before editing. 3. Work inside the assigned worktree for write lanes. 4. Never create files outside the lane scope. 5. Stop and escalate when required scope is missing. 6. Run `lh graph` before claiming done. ## Pipeline rule 1. Design before plan. 2. Require user gate after design. 3. Plan before build unless fast track applies. 4. Run Ralph loop for every write lane. 5. Merge lanes sequentially. 6. Run one full verify after integration.