fix(skills): init-octobot — substitute <project> everywhere, dedupe simplicity block

Dry run surfaced two bugs: the Knowledge block's <project> placeholder
was never substituted outside the OKF templates, and the new Simplicity
& rigor section restated three of Behavioral guardrails' bullets instead
of adding only their delta — real duplication, not essence-merging.
Rewrote simplicity-block.md as a union-minus-overlap of CLAUDE.md §1-4
against agents-md-hook.md, verified no information lost by checking
every CLAUDE.md §1-4 claim resolves in one of the two sections.

Claude-Session: https://claude.ai/code/session_01VZH57yueT8apHdFXffmffE
This commit is contained in:
Łukasz Boryń 2026-09-23 11:26:22 +02:00
parent e216fcc7ca
commit f20f05eb38
2 changed files with 20 additions and 11 deletions

View File

@ -44,12 +44,15 @@ that a silent sub-step would bypass.
migration/hook-wiring steps are permanently skipped, not full migration/hook-wiring steps are permanently skipped, not full
population. population.
3. **AGENTS.md** — create, assembling in order (never duplicate the 3. **AGENTS.md** — create, assembling in order (never duplicate the
source prose into this repo's copy — insert each block verbatim): source prose into this repo's copy — insert each block verbatim,
substituting `<project>` with the repo's directory name in every
block, not just the OKF templates):
1. Knowledge + Behavioral guardrails, from write-OKF's 1. Knowledge + Behavioral guardrails, from write-OKF's
[`agents-md-hook.md`](../../loop/write-OKF/agents-md-hook.md). [`agents-md-hook.md`](../../loop/write-OKF/agents-md-hook.md).
2. Simplicity & rigor, from 2. Simplicity & rigor, from
[`simplicity-block.md`](simplicity-block.md) (CLAUDE.md §1–4, [`simplicity-block.md`](simplicity-block.md) — CLAUDE.md §1–4's
distilled). union-minus-overlap with the hook block above; no information
lost, nothing restated.
3. `## Repo conventions — <dir-name>`, from 3. `## Repo conventions — <dir-name>`, from
[`AGENTS.md.tpl`](AGENTS.md.tpl) — empty repo: leave the [`AGENTS.md.tpl`](AGENTS.md.tpl) — empty repo: leave the
fill-in-later placeholder. Non-empty: turn each confirmed fill-in-later placeholder. Non-empty: turn each confirmed

View File

@ -3,22 +3,28 @@
Insert verbatim into the target `AGENTS.md`, after the Knowledge and Insert verbatim into the target `AGENTS.md`, after the Knowledge and
Behavioral guardrails sections from Behavioral guardrails sections from
[write-OKF's `agents-md-hook.md`](../../loop/write-OKF/agents-md-hook.md). [write-OKF's `agents-md-hook.md`](../../loop/write-OKF/agents-md-hook.md).
Distills CLAUDE.md sections 1–4 to the same terse, always-loaded register Each bullet below carries only what that hook block does **not** already
as the guardrails block above it — the full essay stays in CLAUDE.md for say — CLAUDE.md §1–4 in full still holds every claim; this is the
projects that opt into it. union minus the overlap, not a restatement, so nothing is lost even for
a repo that never opts into CLAUDE.md.
```markdown ```markdown
## Simplicity & rigor ## Simplicity & rigor
- **Think before coding** — state assumptions, name the simpler approach - **Think before coding** — when multiple interpretations exist, present
you're rejecting, ask when unclear rather than guessing. them; don't pick silently.
- **Three sieves before a line stays**: real (not speculative), good - **Three sieves before a line stays**: real (not speculative), good
(nameably better for the next reader), minimal (leanest form — (nameably better for the next reader), minimal (leanest form —
stdlib/existing code before new). Burden is on keeping, not cutting. stdlib/existing code before new). Burden is on keeping, not cutting.
- **Surgical changes** — touch only what the task requires; don't Exceptions that always pass *good*: input validation, error handling
refactor, reformat, or "improve" adjacent code; match existing style. that prevents data loss, security, accessibility, explicitly requested
behaviour.
- **Surgical changes** — match existing style; clean up only your own
mess (remove orphans your change created, not pre-existing dead code);
every changed line should trace to the request.
- **Goal-driven execution** — turn the task into a verifiable check - **Goal-driven execution** — turn the task into a verifiable check
before starting, then loop against that check instead of "looks done". before starting; for multi-step work, state a brief plan, each step
naming its own verify.
``` ```
## Rules ## Rules