wendkeep 0.72.0 → 0.73.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. package/CHANGELOG.md +66 -3
  2. package/README.en.md +28 -11
  3. package/README.md +28 -11
  4. package/docs/en/commands/changes-and-verification.md +10 -5
  5. package/docs/en/commands/maintenance-and-diagnostics.md +17 -9
  6. package/docs/en/commands/observer.md +18 -12
  7. package/docs/en/commands/operating-profiles.md +28 -3
  8. package/docs/en/commands/sessions-and-import.md +4 -4
  9. package/docs/pt-BR/commands/changes-and-verification.md +10 -5
  10. package/docs/pt-BR/commands/maintenance-and-diagnostics.md +12 -5
  11. package/docs/pt-BR/commands/observer.md +18 -12
  12. package/docs/pt-BR/commands/operating-profiles.md +28 -3
  13. package/docs/pt-BR/commands/sessions-and-import.md +4 -4
  14. package/hooks/brain-inject.mjs +6 -6
  15. package/hooks/change-context.mjs +11 -0
  16. package/hooks/change-core.mjs +53 -21
  17. package/hooks/change-warn.mjs +2 -0
  18. package/hooks/harness-doctor.mjs +13 -5
  19. package/hooks/understand-inject.mjs +1 -1
  20. package/hooks/vault-health.mjs +2 -2
  21. package/package.json +5 -4
  22. package/packages/cli/src/index.mjs +12 -2
  23. package/packages/integrations/src/host-hooks.mjs +1 -1
  24. package/packages/vault/src/memory-store.mjs +17 -4
  25. package/src/change.mjs +10 -4
  26. package/src/delivery.mjs +303 -0
  27. package/src/doctor.mjs +47 -10
  28. package/src/init.mjs +2 -2
  29. package/src/observer-auth.mjs +10 -0
  30. package/src/observer-memory-publish.mjs +13 -8
  31. package/src/observer-privacy.mjs +23 -0
  32. package/src/observer-publish.mjs +10 -7
  33. package/src/observer-server.mjs +51 -0
  34. package/src/observer-sql-publish.mjs +72 -31
  35. package/src/observer-sql-store.mjs +33 -2
  36. package/src/observer.mjs +10 -3
  37. package/src/release-changelog.mjs +1 -1
  38. package/src/release-provenance.mjs +115 -0
  39. package/src/skills-seed.mjs +25 -9
  40. package/src/sync-defs.mjs +5 -2
  41. package/src/sync.mjs +2 -2
  42. package/src/taxonomy.mjs +1 -1
  43. package/src/vault-readme.mjs +2 -2
  44. package/src/work-kind.mjs +62 -0
package/CHANGELOG.md CHANGED
@@ -4,6 +4,69 @@ All notable changes to **wendkeep** are documented here. Format based on
4
4
  [Keep a Changelog](https://keepachangelog.com/en/1.1.0/); this project follows
5
5
  [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [0.73.0] — 2026-08-20
8
+
9
+ ### Added
10
+
11
+ - **Work kind independente do perfil.** `inspection`, `maintenance`, `implementation`, `delivery`
12
+ e `recovery` passam a ser classificados separadamente de perfil, impacto de contrato e risco
13
+ operacional.
14
+ - **Delivery com autorização e receipt.** `delivery start/status/finish/abandon` captura repositório,
15
+ branch/worktree, SHA, change de origem e capabilities; comprova target, CI, versão, tag,
16
+ integridade npm e GitHub Release quando aplicável, sem criar change, spec ou ADR.
17
+ - **GUIDE realmente compacta.** `change new --guide` gera somente objetivo, critérios de aceite,
18
+ áreas afetadas, testes e resultado. Sem impacto de contrato, seu archive não fabrica design,
19
+ delta de spec ou ADR.
20
+
21
+ ### Changed
22
+
23
+ - **Doctor proporcional.** O diagnóstico separa erro estrutural, atenção de workflow, dívida
24
+ reparável e ambiguidade semântica. `--scope core|runtime` isola as superfícies e `--strict`
25
+ promove pendências a falha para CI/release.
26
+ - **Sync valida somente o Keep Core.** Trabalho em andamento no Wend Runtime deixa de transformar
27
+ uma instalação saudável em falha; a conclusão informa separadamente a saúde do Core.
28
+ - **Conflitos semânticos degradam por chave.** Candidates ativos aguardam curadoria sem bloquear o
29
+ bundle inteiro; corrupção de ledger, boundary, identidade ou projeção continua falhando fechada.
30
+
31
+ ### Fixed
32
+
33
+ - **Proveniência preserva lifecycle scripts.** A comparação de integridade executa `npm pack`
34
+ normalmente em uma cópia isolada, mantendo `prepack`/`postpack` e impedindo que a verificação
35
+ altere o working tree de origem.
36
+
37
+ ## [0.72.1] — 2026-08-20
38
+
39
+ ### Added
40
+
41
+ - **Proveniência verificável de release.** A publicação gera um receipt com commit, versão, tag,
42
+ integridade npm, execução do workflow e GitHub Release, e recusa divergências entre o SHA testado,
43
+ a tag e o tarball publicado.
44
+ - **Contrato seguro do Observer.** O Keep Core permanece em Node.js 18+, enquanto comandos SQL
45
+ diagnosticam `WENDKEEP_OBSERVER_NODE_UNSUPPORTED` abaixo do Node.js 22.13. Mutações exigem Bearer,
46
+ non-loopback exige token e requisições validam Host e Origin.
47
+ - **Níveis de captura.** `metadata` é o padrão sem mensagens; `messages` e `full-transcript` são
48
+ opt-in. Caminhos absolutos não são publicados e init recomenda ignorar state e outbox SQL.
49
+
50
+ ### Changed
51
+
52
+ - **Release somente após CI verde.** O workflow publica o SHA aprovado pela matriz Core (Node 18/20)
53
+ e Observer (Node 22.13/24), cria a tag no mesmo commit e pode reconciliar execuções repetidas.
54
+ - **Dogfooding pelo working tree.** O repositório não depende mais de `wendkeep` em devDependencies;
55
+ seus hooks chamam `node ./bin/wendkeep.mjs`, enquanto projetos consumidores usam
56
+ `npx --no-install wendkeep` e o tarball continua testado isoladamente.
57
+
58
+ ### Fixed
59
+
60
+ - **Identidade de arquivos de memória no Windows.** A revalidação compara o índice do arquivo como
61
+ inteiro exato e tolera a inconsistência conhecida do serial de volume do libuv antigo, evitando
62
+ falsos `VAULT_PATH_UNSAFE` no Node.js 22.13 sem relaxar a rejeição de hardlinks ou reparses.
63
+ - **Ingestão SQL grande em runners lentos.** O timeout HTTP cresce com o tamanho bruto do lote até
64
+ 120 segundos, preservando 15 segundos para payloads vazios/pequenos e evitando outbox falsa para
65
+ lotes gzip válidos acima de 64 MB.
66
+ - **Trusted Publisher preservado após o gate de CI.** `auto-tag.yml`, o workflow já autorizado no
67
+ npm, passa a executar a matriz da `main` e mantém o publish em um job com `needs: test`;
68
+ `test.yml` fica exclusivo para pull requests.
69
+
7
70
  ## [0.72.0] — 2026-08-17
8
71
 
9
72
  ### Added
@@ -1029,7 +1092,7 @@ All notable changes to **wendkeep** are documented here. Format based on
1029
1092
  enum de eventos de hook do Codex.
1030
1093
  - A projeção Codex tem três diferenças em relação ao formato do `settings.json`, todas
1031
1094
  **silenciosas quando erradas** — daí valerem registro. (1) A chave de timeout é `timeoutSec`,
1032
- não `timeout`. (2) O comando é sempre `npx wendkeep hook <nome>`, nunca a forma node-direta:
1095
+ não `timeout`. (2) O comando é sempre `npx --no-install wendkeep hook <nome>`, nunca a forma node-direta:
1033
1096
  aquela emite `${CLAUDE_PROJECT_DIR}`, que não existe no Codex, então a flag `preferLocal` é
1034
1097
  ignorada de propósito na projeção. (3) As chaves de evento são PascalCase — o snake_case que
1035
1098
  se vê em `[hooks.state]` no `~/.codex/config.toml` é o rótulo interno do evento, não a chave
@@ -1613,7 +1676,7 @@ they only read + append.
1613
1676
 
1614
1677
  ### Note
1615
1678
  - You do **not** need `wendkeep init` for a routine update: the hooks live in the package
1616
- (`settings.json` calls `npx wendkeep hook …`), so `npm i -D wendkeep@latest` updates them.
1679
+ (`settings.json` calls `npx --no-install wendkeep hook …`), so `npm i -D wendkeep@latest` updates them.
1617
1680
  Re-run `init` only when a release adds new wiring (the CHANGELOG says so); it's idempotent.
1618
1681
 
1619
1682
  ## [0.26.0] — 2026-07-08
@@ -1793,7 +1856,7 @@ Fix: memory + active-change injection wired by default.
1793
1856
 
1794
1857
  ### Upgrade
1795
1858
  - Existing installs pick it up by re-running `wendkeep init --force` (idempotent — it only adds the
1796
- missing hook), or by adding `npx wendkeep hook brain-inject` to the SessionStart hooks manually.
1859
+ missing hook), or by adding `npx --no-install wendkeep hook brain-inject` to the SessionStart hooks manually.
1797
1860
 
1798
1861
  ## [0.18.0] — 2026-07-06
1799
1862
 
package/README.en.md CHANGED
@@ -127,7 +127,7 @@ npx wendkeep init
127
127
  6. Install a **color system** into the vault's `.obsidian/`: a CSS snippet that accents notes by type (session/decision/bug/learning, via the `cssclasses` the hooks emit) plus graph color groups by folder. Non-destructive merge into `appearance.json`/`graph.json`; skip with `--no-colors`. Re-apply it any time on an existing vault with `wendkeep theme sync` — Obsidian owns `graph.json` and can drop the color groups (a grey graph); the re-sync restores them without a full re-`init`.
128
128
  7. Seed **Shared Project Memory v2** without overwriting existing artifacts: `.brain/CORE.md` (hand-curated canonical truth), `.brain/SHARED_MEMORY.md` (generated operational state), `.brain/MEMORY_EVENTS.jsonl` (append-only ledger), `.brain/MEMORY_CANDIDATES.jsonl` (curation queue), and `.brain/COMPACTION_PROTOCOL.md`. The durable outbox appears under `.brain/memory-outbox/` when events exist; `DIGEST.md` and `index.jsonl` remain deep recall. Everything stays local to the vault.
129
129
  8. Seed the **definitions + skills layer**: `.brain/agents/` + `.brain/skills/` (versioned source of truth), including the native process skills `wk-workflow` / `wk-tdd` / `wk-debugging` / `wk-brainstorming` / `wk-planning` / `wk-verify` (some ship templates — e.g. `wk-verify`'s `verdict-template.json` + reviewer prompt). `init` runs `wendkeep sync-defs` for you, delivering the skills to `.claude/skills/` and `.agents/skills/`, and the agent definitions (`.brain/agents/*.toml`) to `.codex/agents/`, plus a managed section in `AGENTS.md` that indexes the skills for Codex; `sync-defs --check` detects stale copies (re-run `sync-defs` after editing `.brain`).
130
- 9. Seed the **change/spec lifecycle**: the `07-Specs/` + `08-Mudanças/` folders and a native `wendkeep.sensors.json` — critical memory validation/health sensors plus one for each of `typecheck` / `test` / `lint` / `build` found in your `package.json`. `memory-health` blocks delivery on corruption, projection divergence, or an active conflict; pending outbox events and ordinary candidates are warnings. Add sensors with `wendkeep sensors add`. Drives `wendkeep change` / `wendkeep verify` — see **Change lifecycle** below.
130
+ 9. Seed the **change/spec lifecycle**: the `07-Specs/` + `08-Mudanças/` folders and a native `wendkeep.sensors.json` — critical memory validation/health sensors plus one for each of `typecheck` / `test` / `lint` / `build` found in your `package.json`. `memory-health` blocks delivery on corruption or projection divergence; semantic conflicts degrade only the affected keys and await curation. Pending outbox events and ordinary candidates are warnings. Add sensors with `wendkeep sensors add`. Drives `wendkeep change` / `wendkeep verify` — see **Change lifecycle** below.
131
131
 
132
132
  ```bash
133
133
  npx wendkeep init --vault "~/vaults/work" --project . --yes # non-interactive (no companions unless you ask)
@@ -257,7 +257,7 @@ deliberate opt-in and runs that command's own validations:
257
257
  |---|---|---|
258
258
  | `OFF` | LLM-native harness | No Wend router, skill gate, or gates; explicit selection only. |
259
259
  | `FLOW` | E → V | Microcontract with Git baseline, allowlist, sensor, and receipt, without a change. |
260
- | `GUIDE` | P → E → V | Compact guided change. |
260
+ | `GUIDE` | P → E → V | Compact change; no automatic design/spec/ADR when contract impact is none. |
261
261
  | `GOVERN` | P → R → E → V | Current a2 loop and compatible fallback. |
262
262
  | `ASSURE` | P → R → E → V → C | Governance with confirmation and handoff. |
263
263
 
@@ -317,13 +317,25 @@ positive causal turn and sequence that agree in the registry.
317
317
  “Small” describes size, not risk. The harness uses this matrix to choose and record a temporary
318
318
  route; semantic inference remains in the agent, not Wend Runtime:
319
319
 
320
- | Situation | Suggested profile |
321
- |---|---|
322
- | Question, inspection, or diagnosis with no mutation | No profile transition |
323
- | Local, reversible fix with an allowlist and no contract/spec change | `FLOW` (`E → V`) |
324
- | Small behavior change that needs a change but not formal Wend Runtime review | `GUIDE` (`P → E → V`) |
325
- | Normal, ambiguous, public-contract, security, dependency, CI/release, or policy change | `GOVERN` (`P R → E → V`) |
326
- | Work requiring explicit confirmation and handoff | `ASSURE` (`P R → E → V → C`) |
320
+ | Situation | Work kind | Suggested profile | New change |
321
+ |---|---|---|---|
322
+ | Question, inspection, or diagnosis with no mutation | `inspection` | No transition | No |
323
+ | Local, reversible fix with an allowlist and no contract/spec change | `maintenance` | `FLOW` (`E → V`) | No |
324
+ | Small behavior change without formal review | `implementation` | `GUIDE` (`P → E → V`) | Yes, compact |
325
+ | Public contract, security, schema, dependency, CI/release workflow, or policy | `implementation` | `GOVERN`/`ASSURE` | Yes |
326
+ | Merge, push, tag, or publication of approved behavior | `delivery` | `ASSURE` | No |
327
+ | Operational recovery without code/config correction | `recovery` | `FLOW`/`ASSURE` | No |
328
+
329
+ Work kind, profile, contract impact, and operational risk are independent dimensions. A
330
+ `delivery` records authorized capabilities and an append-only receipt without creating a change,
331
+ spec, or ADR. If delivery requires a code/config edit, it pauses and work returns to
332
+ `implementation`:
333
+
334
+ ```bash
335
+ npx wendkeep delivery start release-0-73-0 --allow git:merge --allow git:push --allow publish --source-change <slug> --source-commit <sha>
336
+ npx wendkeep delivery status release-0-73-0
337
+ npx wendkeep delivery finish release-0-73-0 --target main --ci-url <url> --version 0.73.0 --npm-integrity <sha512> --release-url <url>
338
+ ```
327
339
 
328
340
  If the harness does not record a lease, a small fix remains under the configured profile —
329
341
  `GOVERN` by default. `OFF` does not mean “simple task”: it is a persistent human choice that hands
@@ -344,6 +356,11 @@ and owner+lease locks validate physical topology. Concurrent promotion elects on
344
356
  retry through `--change-slug`. Read the complete
345
357
  [Operating profiles guide](https://github.com/rogersialves/wendkeep/blob/main/docs/en/commands/operating-profiles.md).
346
358
 
359
+ `wendkeep doctor` separates structural errors, workflow attention, repairable debt, and semantic
360
+ ambiguity. Use `--scope core` for Keep Core health, `--scope runtime` for governance, and
361
+ `--strict` in CI/release; `wendkeep sync` validates Core only so work in progress does not become
362
+ an installation failure.
363
+
347
364
  ## Shared Project Memory v2
348
365
 
349
366
  Hot memory now separates human authorship, operational state, and evidence:
@@ -487,10 +504,10 @@ Beyond capturing sessions, wendkeep is a **harness**: a native, zero‑dependenc
487
504
  explore → propose → apply (TDD) → verify → archive
488
505
  ```
489
506
 
490
- - **Propose** — `wendkeep change new <slug>` scaffolds `08-Mudanças/<slug>/` (`proposta.md`, `design.md`, `tarefas.md`; `--simple` skips the design). It becomes the global *current* change. When the change declares `spec_impact: required`, you author the delta yourself at `specs/<capability>/spec.md` — there is no placeholder to delete. Multiple changes may remain open: `change list`/`status` and the hooks show every pending one, while commands without `--change` act on the current one alone. `change use <slug>` changes focus and `change continue <archived> <new>` creates an auditable continuation.
507
+ - **Propose** — `wendkeep change new <slug>` scaffolds `08-Mudanças/<slug>/` (`proposta.md`, `design.md`, `tarefas.md`; `--simple` skips the design). `--guide` creates the compact GUIDE contract and omits automatic design/spec/ADR when `contract_impact:none`. It becomes the global *current* change. When the change declares `spec_impact: required`, you author the delta yourself at `specs/<capability>/spec.md` — there is no placeholder to delete. Multiple changes may remain open: `change list`/`status` and the hooks show every pending one, while commands without `--change` act on the current one alone. `change use <slug>` changes focus and `change continue <archived> <new>` creates an auditable continuation.
491
508
  - **Apply** — implement each `tarefas.md` task. Mark machine proof with one or more `[sensor:<id>]` tags on the same task: every distinct ID enters the gate once, in declaration order. Also mark satisfied requirements with one or more `[req:<ID>]` tags.
492
509
  - **Verify** — `wendkeep verify` runs the sensors your tasks declared (from `wendkeep.sensors.json` at the project root) and writes `evidencia.json`. A red `critical` fails the gate; a red `warning` is advisory. Failures retain only a bounded, sanitized diagnostic; green output is not persisted. `verify --deep` builds a self-contained package with complete effective requirements (living contract + this change's delta), so the independent verifier never needs to reconstruct unarchived requirements from `07-Specs`. Every change needs a `verdict.json` to archive; `verify --deep` writes a trivial one automatically when the change declares no `[req:]`.
493
- - **Archive** — `wendkeep change archive <slug>` **gates** on the evidence (blocks unless every declared critical sensor is green), promotes each capability's spec delta (`ADDED`/`MODIFIED`/`REMOVED`) into the living `07-Specs/<capability>.md`, moves the change to `_arquivo/`, and mints an ADR in `04-Decisões/`.
510
+ - **Archive** — `wendkeep change archive <slug>` **gates** on the evidence (blocks unless every declared critical sensor is green), promotes each applicable spec delta (`ADDED`/`MODIFIED`/`REMOVED`) into the living `07-Specs/<capability>.md` and moves the change to `_arquivo/`. GOVERN/ASSURE mint an ADR in `04-Decisões/`; compact GUIDE with no contract impact does not mint one automatically.
494
511
 
495
512
  > The gate blocks unless the scaffold is filled, no task is open, evidence is fresh, and every declared requirement is covered. **`--force` waives exactly one of those — the open-task check — and is the human's call, never the agent's.** An unfilled scaffold, a red critical sensor, stale evidence, an orphan requirement or a missing verdict block regardless.
496
513
 
package/README.md CHANGED
@@ -127,7 +127,7 @@ npx wendkeep init
127
127
  6. Install a **color system** into the vault's `.obsidian/`: a CSS snippet that accents notes by type (session/decision/bug/learning, via the `cssclasses` the hooks emit) plus graph color groups by folder. Non-destructive merge into `appearance.json`/`graph.json`; skip with `--no-colors`. Re-apply it any time on an existing vault with `wendkeep theme sync` — Obsidian owns `graph.json` and can drop the color groups (a grey graph); the re-sync restores them without a full re-`init`.
128
128
  7. Seed **Shared Project Memory v2** without overwriting existing artifacts: `.brain/CORE.md` (hand-curated canonical truth), `.brain/SHARED_MEMORY.md` (generated operational state), `.brain/MEMORY_EVENTS.jsonl` (append-only ledger), `.brain/MEMORY_CANDIDATES.jsonl` (curation queue), and `.brain/COMPACTION_PROTOCOL.md`. The durable outbox appears under `.brain/memory-outbox/` when events exist; `DIGEST.md` and `index.jsonl` remain deep recall. Everything stays local to the vault.
129
129
  8. Seed the **definitions + skills layer**: `.brain/agents/` + `.brain/skills/` (versioned source of truth), including the native process skills `wk-workflow` / `wk-tdd` / `wk-debugging` / `wk-brainstorming` / `wk-planning` / `wk-verify` (some ship templates — e.g. `wk-verify`'s `verdict-template.json` + reviewer prompt). `init` runs `wendkeep sync-defs` for you, delivering the skills to `.claude/skills/` and `.agents/skills/`, and the agent definitions (`.brain/agents/*.toml`) to `.codex/agents/`, plus a managed section in `AGENTS.md` that indexes the skills for Codex; `sync-defs --check` detects stale copies (re-run `sync-defs` after editing `.brain`).
130
- 9. Seed the **change/spec lifecycle**: the `07-Specs/` + `08-Mudanças/` folders and a native `wendkeep.sensors.json` — critical memory validation/health sensors plus one for each of `typecheck` / `test` / `lint` / `build` found in your `package.json`. `memory-health` blocks delivery on corruption, projection divergence, or an active conflict; pending outbox events and ordinary candidates are warnings. Add sensors with `wendkeep sensors add`. Drives `wendkeep change` / `wendkeep verify` — see **Change lifecycle** below.
130
+ 9. Seed the **change/spec lifecycle**: the `07-Specs/` + `08-Mudanças/` folders and a native `wendkeep.sensors.json` — critical memory validation/health sensors plus one for each of `typecheck` / `test` / `lint` / `build` found in your `package.json`. `memory-health` blocks delivery on corruption or projection divergence; semantic conflicts degrade only the affected keys and await curation. Pending outbox events and ordinary candidates are warnings. Add sensors with `wendkeep sensors add`. Drives `wendkeep change` / `wendkeep verify` — see **Change lifecycle** below.
131
131
 
132
132
  ```bash
133
133
  npx wendkeep init --vault "~/vaults/work" --project . --yes # non-interactive (no companions unless you ask)
@@ -257,7 +257,7 @@ deliberate opt-in and runs that command's own validations:
257
257
  |---|---|---|
258
258
  | `OFF` | LLM-native harness | No Wend router, skill gate, or gates; explicit selection only. |
259
259
  | `FLOW` | E → V | Microcontract with Git baseline, allowlist, sensor, and receipt, without a change. |
260
- | `GUIDE` | P → E → V | Compact guided change. |
260
+ | `GUIDE` | P → E → V | Compact change; no automatic design/spec/ADR when contract impact is none. |
261
261
  | `GOVERN` | P → R → E → V | Current a2 loop and compatible fallback. |
262
262
  | `ASSURE` | P → R → E → V → C | Governance with confirmation and handoff. |
263
263
 
@@ -317,13 +317,25 @@ positive causal turn and sequence that agree in the registry.
317
317
  “Small” describes size, not risk. The harness uses this matrix to choose and record a temporary
318
318
  route; semantic inference remains in the agent, not Wend Runtime:
319
319
 
320
- | Situation | Suggested profile |
321
- |---|---|
322
- | Question, inspection, or diagnosis with no mutation | No profile transition |
323
- | Local, reversible fix with an allowlist and no contract/spec change | `FLOW` (`E → V`) |
324
- | Small behavior change that needs a change but not formal Wend Runtime review | `GUIDE` (`P → E → V`) |
325
- | Normal, ambiguous, public-contract, security, dependency, CI/release, or policy change | `GOVERN` (`P R → E → V`) |
326
- | Work requiring explicit confirmation and handoff | `ASSURE` (`P R → E → V → C`) |
320
+ | Situation | Work kind | Suggested profile | New change |
321
+ |---|---|---|---|
322
+ | Question, inspection, or diagnosis with no mutation | `inspection` | No transition | No |
323
+ | Local, reversible fix with an allowlist and no contract/spec change | `maintenance` | `FLOW` (`E → V`) | No |
324
+ | Small behavior change without formal review | `implementation` | `GUIDE` (`P → E → V`) | Yes, compact |
325
+ | Public contract, security, schema, dependency, CI/release workflow, or policy | `implementation` | `GOVERN`/`ASSURE` | Yes |
326
+ | Merge, push, tag, or publication of approved behavior | `delivery` | `ASSURE` | No |
327
+ | Operational recovery without code/config correction | `recovery` | `FLOW`/`ASSURE` | No |
328
+
329
+ Work kind, profile, contract impact, and operational risk are independent dimensions. A
330
+ `delivery` records authorized capabilities and an append-only receipt without creating a change,
331
+ spec, or ADR. If delivery requires a code/config edit, it pauses and work returns to
332
+ `implementation`:
333
+
334
+ ```bash
335
+ npx wendkeep delivery start release-0-73-0 --allow git:merge --allow git:push --allow publish --source-change <slug> --source-commit <sha>
336
+ npx wendkeep delivery status release-0-73-0
337
+ npx wendkeep delivery finish release-0-73-0 --target main --ci-url <url> --version 0.73.0 --npm-integrity <sha512> --release-url <url>
338
+ ```
327
339
 
328
340
  If the harness does not record a lease, a small fix remains under the configured profile —
329
341
  `GOVERN` by default. `OFF` does not mean “simple task”: it is a persistent human choice that hands
@@ -344,6 +356,11 @@ and owner+lease locks validate physical topology. Concurrent promotion elects on
344
356
  retry through `--change-slug`. Read the complete
345
357
  [Operating profiles guide](https://github.com/rogersialves/wendkeep/blob/main/docs/en/commands/operating-profiles.md).
346
358
 
359
+ `wendkeep doctor` separates structural errors, workflow attention, repairable debt, and semantic
360
+ ambiguity. Use `--scope core` for Keep Core health, `--scope runtime` for governance, and
361
+ `--strict` in CI/release; `wendkeep sync` validates Core only so work in progress does not become
362
+ an installation failure.
363
+
347
364
  ## Shared Project Memory v2
348
365
 
349
366
  Hot memory now separates human authorship, operational state, and evidence:
@@ -487,10 +504,10 @@ Beyond capturing sessions, wendkeep is a **harness**: a native, zero‑dependenc
487
504
  explore → propose → apply (TDD) → verify → archive
488
505
  ```
489
506
 
490
- - **Propose** — `wendkeep change new <slug>` scaffolds `08-Mudanças/<slug>/` (`proposta.md`, `design.md`, `tarefas.md`; `--simple` skips the design). It becomes the global *current* change. When the change declares `spec_impact: required`, you author the delta yourself at `specs/<capability>/spec.md` — there is no placeholder to delete. Multiple changes may remain open: `change list`/`status` and the hooks show every pending one, while commands without `--change` act on the current one alone. `change use <slug>` changes focus and `change continue <archived> <new>` creates an auditable continuation.
507
+ - **Propose** — `wendkeep change new <slug>` scaffolds `08-Mudanças/<slug>/` (`proposta.md`, `design.md`, `tarefas.md`; `--simple` skips the design). `--guide` creates the compact GUIDE contract and omits automatic design/spec/ADR when `contract_impact:none`. It becomes the global *current* change. When the change declares `spec_impact: required`, you author the delta yourself at `specs/<capability>/spec.md` — there is no placeholder to delete. Multiple changes may remain open: `change list`/`status` and the hooks show every pending one, while commands without `--change` act on the current one alone. `change use <slug>` changes focus and `change continue <archived> <new>` creates an auditable continuation.
491
508
  - **Apply** — implement each `tarefas.md` task. Mark machine proof with one or more `[sensor:<id>]` tags on the same task: every distinct ID enters the gate once, in declaration order. Also mark satisfied requirements with one or more `[req:<ID>]` tags.
492
509
  - **Verify** — `wendkeep verify` runs the sensors your tasks declared (from `wendkeep.sensors.json` at the project root) and writes `evidencia.json`. A red `critical` fails the gate; a red `warning` is advisory. Failures retain only a bounded, sanitized diagnostic; green output is not persisted. `verify --deep` builds a self-contained package with complete effective requirements (living contract + this change's delta), so the independent verifier never needs to reconstruct unarchived requirements from `07-Specs`. Every change needs a `verdict.json` to archive; `verify --deep` writes a trivial one automatically when the change declares no `[req:]`.
493
- - **Archive** — `wendkeep change archive <slug>` **gates** on the evidence (blocks unless every declared critical sensor is green), promotes each capability's spec delta (`ADDED`/`MODIFIED`/`REMOVED`) into the living `07-Specs/<capability>.md`, moves the change to `_arquivo/`, and mints an ADR in `04-Decisões/`.
510
+ - **Archive** — `wendkeep change archive <slug>` **gates** on the evidence (blocks unless every declared critical sensor is green), promotes each applicable spec delta (`ADDED`/`MODIFIED`/`REMOVED`) into the living `07-Specs/<capability>.md` and moves the change to `_arquivo/`. GOVERN/ASSURE mint an ADR in `04-Decisões/`; compact GUIDE with no contract impact does not mint one automatically.
494
511
 
495
512
  > The gate blocks unless the scaffold is filled, no task is open, evidence is fresh, and every declared requirement is covered. **`--force` waives exactly one of those — the open-task check — and is the human's call, never the agent's.** An unfilled scaffold, a red critical sensor, stale evidence, an orphan requirement or a missing verdict block regardless.
496
513
 
@@ -25,7 +25,7 @@ Initialize the project, keep the vault healthy, and provide a valid `wendkeep.se
25
25
  ## Syntax
26
26
 
27
27
  ```bash
28
- npx wendkeep change new <slug>
28
+ npx wendkeep change new <slug> [--simple|--guide]
29
29
  npx wendkeep change status [slug]
30
30
  npx wendkeep spec effective --change <slug>
31
31
  npx wendkeep sensors list
@@ -35,8 +35,10 @@ npx wendkeep change archive <slug>
35
35
 
36
36
  ## Options and exit codes
37
37
 
38
- - `wendkeep change new <slug> [--simple]` creates a change; `--simple` only skips design, is not
39
- `FLOW`, and preserves the legacy lifecycle/ADR contract.
38
+ - `wendkeep change new <slug> [--simple|--guide]` creates a change. `--simple` only skips design,
39
+ is not `FLOW`, and preserves the legacy lifecycle/ADR contract. `--guide` creates the compact
40
+ GUIDE contract (objective, acceptance, areas, tests, and result), with no automatic
41
+ design/spec/ADR when `contract_impact:none`.
40
42
  - `change use`, `list`, `show`, `status`, `diff`, `done`, and `undone` inspect or update work
41
43
  without archiving it.
42
44
  - `change continue <archived> <new>` starts follow-up work without inheriting stale proof.
@@ -52,6 +54,7 @@ npx wendkeep change archive <slug>
52
54
 
53
55
  ```bash
54
56
  npx wendkeep change new tenant-login
57
+ npx wendkeep change new internal-adjustment --guide
55
58
  npx wendkeep spec effective --change tenant-login
56
59
  npx wendkeep change done 1.1 --change tenant-login
57
60
  npx wendkeep verify --change tenant-login
@@ -67,8 +70,10 @@ npx wendkeep sensors add api-contracts "npm run test:contracts" --severity criti
67
70
 
68
71
  ## Expected result
69
72
 
70
- An archived change promotes its delta into the living spec, preserves proposal/design/tasks/proof,
71
- and mints an ADR. Archive passes only with closed tasks, green required sensors, and a fresh verdict.
73
+ An archived change promotes its delta into the living spec when applicable and preserves proposal,
74
+ tasks/proof, and design when present. GOVERN/ASSURE mint an ADR; compact GUIDE with no contract
75
+ impact does not mint one automatically. Archive passes only with closed tasks, green required
76
+ sensors, and a fresh verdict.
72
77
 
73
78
  ## Tool-scope fence
74
79
 
@@ -23,7 +23,7 @@ Run from the project root or provide `--project` and `--vault` explicitly.
23
23
  ## Syntax
24
24
 
25
25
  ```bash
26
- npx --no-install wendkeep doctor [--vault <vault>]
26
+ npx --no-install wendkeep doctor [--vault <vault>] [--scope all|core|runtime] [--strict]
27
27
  npx --no-install wendkeep memory curate --vault <vault>
28
28
  npx --no-install wendkeep sync-defs [--check|--reseed] --vault <vault> --project <root>
29
29
  npx --no-install wendkeep theme sync --vault <vault>
@@ -33,7 +33,10 @@ npx --no-install wendkeep --help
33
33
 
34
34
  ## Options and exit codes
35
35
 
36
- - `doctor` is read-only; exit `0` accepts recoverable warnings, while non-zero means failure.
36
+ - `doctor` is read-only. By default only structural errors produce a non-zero exit; `--strict`
37
+ also fails on workflow attention, repairable debt, semantic degradation, and warnings.
38
+ - `--scope core` checks the installation, binding, ledger, and Keep Core only. `--scope runtime`
39
+ checks changes, sensors, and governance only. The default `all` reports both surfaces.
37
40
  - `doctor` uses human-readable output with `[integrity]` and `[memory]` sections, friendly
38
41
  categories, and a copyable next action. The `vault-health.mjs` hook remains the JSON surface for
39
42
  automation; neither surface applies curation.
@@ -44,8 +47,9 @@ npx --no-install wendkeep --help
44
47
  IDs, and checkpoint) with outbox, ledger, and SHARED; they do not infer health from revision alone.
45
48
  - `revision: 0` after a valid migration, with no v2 attempt, is healthy. A `degraded` attempt whose
46
49
  events remain durable in the outbox/ledger is a recoverable warning.
47
- - An ambiguous attempt, a lost event ID (absent from ledger and outbox), `projected` state found
48
- only in the outbox, or a mismatched checkpoint is blocking.
50
+ - An ambiguous publication attempt, a lost event ID (absent from ledger and outbox), `projected`
51
+ state found only in the outbox, or a mismatched checkpoint is a structural block. Active
52
+ semantic candidates degrade memory by key and remain available for explicit curation.
49
53
  - For session observability, `legacy`, `degraded`, `stale`, and `manifest-unproven` require
50
54
  reconciliation or more evidence. Only fresh `none` and fresh `complete` are healthy: frontier,
51
55
  checkpoint, root stat, and source manifest must agree.
@@ -63,6 +67,8 @@ Post-update checklist:
63
67
  npx --no-install wendkeep --version
64
68
  npx --no-install wendkeep sync-defs --check --vault .MyApp-vault --project .
65
69
  npx --no-install wendkeep doctor --vault .MyApp-vault
70
+ npx --no-install wendkeep doctor --scope core --vault .MyApp-vault
71
+ npx --no-install wendkeep doctor --scope runtime --strict --vault .MyApp-vault
66
72
  npx --no-install wendkeep memory status --gate --vault .MyApp-vault
67
73
  npx --no-install wendkeep memory curate --vault .MyApp-vault
68
74
  npx --no-install wendkeep memory candidates --active --vault .MyApp-vault
@@ -72,10 +78,11 @@ npx --no-install wendkeep cost rebuild --session <id> --json --vault .MyApp-vaul
72
78
 
73
79
  ## Expected result
74
80
 
75
- Doctor names sessions, registry, links, notes, prices, derived sections, and memory as healthy or
81
+ Doctor separates structural errors, workflow attention, repairable debt, and semantic ambiguity.
82
+ It names sessions, registry, links, notes, prices, derived sections, and memory as healthy or
76
83
  provides a specific diagnostic/repair command. For memory, it distinguishes a valid initial empty
77
- state, recoverable pending replay, and lost/divergent lifecycle state. It never repairs implicitly
78
- or echoes private projector-error content into its report. For session observability, it separates
84
+ state, recoverable pending replay, key-scoped conflicts, and lost/divergent lifecycle state. It
85
+ never repairs implicitly or echoes private projector-error content into its report. For session observability, it separates
79
86
  fresh `none`/`complete` from legacy, degraded, stale, or manifest-unproven state and gives a
80
87
  dry-run path before any write.
81
88
 
@@ -87,10 +94,11 @@ dry-run path before any write.
87
94
  `npx --no-install wendkeep memory migrate --apply --vault <vault>` with the resolved Vault, but
88
95
  migration remains opt-in and must be planned separately.
89
96
  - `degraded` plus an intact outbox: warning; preserve the outbox and allow idempotent replay.
90
- - `ambiguous`, lost publication, or a mismatched checkpoint: blocking; preserve registry, ledger,
97
+ - Ambiguous publication, lost publication, or a mismatched checkpoint: blocking; preserve registry, ledger,
91
98
  outbox, and SHARED so `last_memory_attempt` can be correlated before repair.
92
99
  - Corrupt bundle: preserve evidence and run `memory status --gate` before `memory repair`.
93
- - An active semantic conflict requires a human decision: `memory repair` does not choose a winner.
100
+ - An active semantic conflict degrades only the affected memory key and requires a human decision:
101
+ `memory repair` does not choose a winner.
94
102
  Start with the guided menu `memory curate --vault <vault>`. For advanced inspection or a
95
103
  non-interactive terminal, list safe IDs with `memory candidates --active --vault <vault>`, review
96
104
  the evidence, and then use
@@ -6,7 +6,7 @@
6
6
 
7
7
  The Observer consolidates observability for multiple WendKeep projects in a local service. The
8
8
  Docker volume keeps `/data/observer.sqlite` as the single authority for documents, sessions,
9
- agents, usage, calls, and complete transcripts. The content can be browsed and searched in the
9
+ agents, usage, and calls. Complete transcripts are optional and require explicit capture. The content can be browsed and searched in the
10
10
  container without depending on Obsidian for queries.
11
11
 
12
12
  ## When to use
@@ -24,8 +24,9 @@ WendKeep hooks.
24
24
 
25
25
  ## Prerequisites
26
26
 
27
- Initialize projects with WendKeep and explicitly register each project before starting the HTTP
28
- server. The default local mode has no token to configure.
27
+ Use Node.js 22.13 or newer for the SQL Observer. Keep Core and the remaining commands continue to
28
+ support Node.js 18 or newer. Explicitly register each project and set `WENDKEEP_OBSERVER_TOKEN`;
29
+ loopback reads remain open, while every mutation requires a Bearer token.
29
30
 
30
31
  ## Syntax
31
32
 
@@ -33,8 +34,8 @@ server. The default local mode has no token to configure.
33
34
  npx wendkeep observer status --data-dir <directory> --json
34
35
  npx wendkeep observer register --project <project> --vault <vault> --data-dir <directory>
35
36
  npx wendkeep observer publish --project <project> --vault <vault> --data-dir <directory>
36
- npx wendkeep observer memory import --project <project> --vault <vault> --url http://127.0.0.1:8787 --json
37
- npx wendkeep observer serve --host 127.0.0.1 --port 8787 --data-dir <directory>
37
+ npx wendkeep observer memory import --project <project> --vault <vault> --url http://127.0.0.1:8787 --token <token> --json
38
+ npx wendkeep observer serve --host 127.0.0.1 --port 8787 --data-dir <directory> --token <token>
38
39
  ```
39
40
 
40
41
  ## Options and exit codes
@@ -44,8 +45,9 @@ npx wendkeep observer serve --host 127.0.0.1 --port 8787 --data-dir <directory>
44
45
  - `--project` and `--vault` identify a project for `register`, `publish`, and `memory import`.
45
46
  - `--host` accepts only `127.0.0.1`, `localhost`, or `::1`; other hosts are rejected before
46
47
  listening.
47
- - `/v1` is open in the default local mode; keep `--host 127.0.0.1` and do not publish the port on
48
- a network address.
48
+ - `--token` or `WENDKEEP_OBSERVER_TOKEN` authenticates mutations; `--allow-non-loopback` fails without one.
49
+ - `WENDKEEP_OBSERVER_CAPTURE_LEVEL` accepts `metadata` (default, no messages), `messages`, or
50
+ `full-transcript`. Absolute local paths are never published.
49
51
  - Exit `0` means success; exit `1` means configuration or operation failure; the publisher hook
50
52
  also returns `0` when the Observer is unavailable.
51
53
 
@@ -53,7 +55,8 @@ npx wendkeep observer serve --host 127.0.0.1 --port 8787 --data-dir <directory>
53
55
 
54
56
  ```powershell
55
57
  npx wendkeep observer register --project C:\GitHub\WendKeep --vault C:\GitHub\WendKeep\.WendKeep-vault --data-dir C:\WendKeepObserver
56
- npx wendkeep observer serve --host 127.0.0.1 --port 8787 --data-dir C:\WendKeepObserver
58
+ $env:WENDKEEP_OBSERVER_TOKEN = '<strong-local-token>'
59
+ npx wendkeep observer serve --host 127.0.0.1 --port 8787 --data-dir C:\WendKeepObserver --token $env:WENDKEEP_OBSERVER_TOKEN
57
60
  $env:WENDKEEP_OBSERVER_URL = 'http://127.0.0.1:8787'
58
61
  ```
59
62
 
@@ -66,14 +69,14 @@ docker compose -f docker/wendkeep-observer/compose.yaml up -d --build
66
69
  ## Local web dashboard
67
70
 
68
71
  With the server running, open [http://127.0.0.1:8787/](http://127.0.0.1:8787/) in a browser. The
69
- dashboard is served by the same process and opens directly, without a form or token. Keep the port
72
+ dashboard is served by the same process and opens directly for reads, without a form or token. Keep the port
70
73
  bound to the computer loopback; do not expose this address on a network interface.
71
74
 
72
75
  The dashboard shows the multi-project list, version, health, latest session, active change, change
73
76
  count, and last capture time. Opening a project exposes Overview, Consumption, Sessions, Memory,
74
77
  Changes, and Sync screens. Consumption shows total cost, token categories, primary agents,
75
78
  subagents, providers, models, daily trend, historical coverage, and calls with prompt, response,
76
- and complete transcript. Loading, empty, unavailable-server, conflict, no-pricing, and stale-data
79
+ and transcript content according to the selected capture level. Loading, empty, unavailable-server, conflict, no-pricing, and stale-data
77
80
  states are visible, with manual refresh and an automatic 15-second refresh.
78
81
 
79
82
  If the browser shows the shell but the list fails, check the service health at
@@ -84,7 +87,8 @@ If the browser shows the shell but the list fails, check the service health at
84
87
  `register` stores `project_id`, name, version, and registration time. `publish` reads the local
85
88
  vault, produces the snapshot, and sends idempotent events to SQLite containing the complete content
86
89
  of sessions, decisions, bugs, learnings, specs, changes, CORE, DIGEST, SHARED_MEMORY, brain state,
87
- agent sessions, cost rollups, calls, and transcripts. The container stores everything in
90
+ agent sessions, cost rollups, and calls. Messages and transcripts are only sent by capture levels
91
+ that explicitly enable them. The container stores everything in
88
92
  `/data/observer.sqlite`; it does not mount `C:\GitHub` or any `.WendKeep-vault`. Markdown is only
89
93
  the text held in SQL and is recreated as files only by an explicit read-only export.
90
94
  `memory import` performs the initial load and returns file/hash parity. During migration, the
@@ -104,7 +108,9 @@ outbox is temporary transport, not authority.
104
108
  - `project_not_registered`: run `observer register` before publishing.
105
109
  - `host loopback`: replace `0.0.0.0` or a LAN address with `127.0.0.1`.
106
110
  - Pending outbox: the service was unavailable; preserve `.brain/observer-outbox/` and
107
- `.brain/observer-sql-outbox/`, then rerun the publisher. Do not delete events manually.
111
+ `.brain/observer-sql-outbox/`, then rerun the publisher. Also ignore
112
+ `.brain/observer-sql-state.json` and `.brain/observer-sql-outbox/` in a versioned vault. Do not delete events manually.
113
+ - `WENDKEEP_OBSERVER_NODE_UNSUPPORTED`: run the Observer on Node.js 22.13 or newer.
108
114
  - If memory or usage is incomplete, check the Sync screen, preserve the outbox, and run
109
115
  `observer memory import` to rebuild the load from the vault.
110
116
 
@@ -1,4 +1,4 @@
1
- # Operating profiles and FLOW
1
+ # Operating profiles, work kind, FLOW, and delivery
2
2
 
3
3
  **English** · [Português](../../pt-BR/commands/operating-profiles.md)
4
4
 
@@ -17,6 +17,8 @@ opt-in and runs that command's own validations and gates.
17
17
  Use `profile use` for a persistent human selection and `profile route` for the harness to record
18
18
  the temporary route for the current implementation. Use `FLOW` for local, reversible
19
19
  `spec_impact:none` maintenance that fits an Execute → Validate microcontract without a change.
20
+ Use `delivery` for merge, push, tag, and publication of already-approved behavior: operational
21
+ risk needs authorization and a receipt, not a new change or spec.
20
22
 
21
23
  ## When not to use
22
24
 
@@ -55,6 +57,10 @@ npx wendkeep flow status [<id>]
55
57
  npx wendkeep flow show <id> [--session <id>]
56
58
  npx wendkeep flow finish <id> [--session <id>]
57
59
  npx wendkeep flow promote <id> [--change-slug <slug>] [--session <id>]
60
+ npx wendkeep delivery start [id] --allow <capability> [--source-change <slug>] [--source-commit <sha>]
61
+ npx wendkeep delivery status [id]
62
+ npx wendkeep delivery finish [id] [--target <ref>] [--ci-url <url>] [--version <x.y.z>] [--npm-integrity <sha512>] [--release-url <url>]
63
+ npx wendkeep delivery abandon [id] --reason <text>
58
64
  ```
59
65
 
60
66
  Every FLOW subcommand also accepts `--project <path>`, `--vault <path>`, and `--json`. When
@@ -84,7 +90,7 @@ Harness. The workspaces remain private and are not published as independent npm
84
90
  |---|---|---|
85
91
  | `OFF` | LLM-native harness | Automatic governance off; Keep Core and explicit commands available. |
86
92
  | `FLOW` | E → V | Microcontract with Git baseline, allowlist, sensors, and receipt, without a change. |
87
- | `GUIDE` | P → E → V | Compact change; policy recognized for compatible evolution. |
93
+ | `GUIDE` | P → E → V | `change new --guide`; objective, acceptance, areas, tests, and result; no automatic design/spec/ADR for `contract_impact:none`. |
88
94
  | `GOVERN` | P → R → E → V | Current a2 loop and conservative fallback. |
89
95
  | `ASSURE` | P → R → E → V → C | Governance plus confirmation and handoff. |
90
96
 
@@ -164,6 +170,14 @@ ownership to the native LLM harness.
164
170
  loser remains active and can retry with `--change-slug`. Retries idempotently resume the same
165
171
  promotion instead of creating another change.
166
172
  No FLOW command accepts `--force`.
173
+ - Work kind (`inspection`, `maintenance`, `implementation`, `delivery`, `recovery`), profile,
174
+ `contract_impact`, and `operation_risk` are independent dimensions. `delivery start` captures
175
+ repo, branch/worktree, SHA, source change, and capabilities in `.brain/runtime/deliveries/`;
176
+ it creates no `08-Changes` folder, delta, spec, or ADR.
177
+ - `delivery finish` requires a clean worktree, proves that the target contains the source commit,
178
+ and for `publish` requires CI, version, npm integrity, and GitHub Release evidence. Receipts are
179
+ append-only in `.brain/runtime/delivery-receipts.jsonl`. If code/config must change, delivery
180
+ stops with `WENDKEEP_DELIVERY_IMPLEMENTATION_REQUIRED` and work returns to implementation.
167
181
  - Exit `0` means a successful query or transition; exit `1` means a policy/red-sensor block; exit
168
182
  `2` means invalid profile, session, flow, or arguments, with no partial mutation.
169
183
 
@@ -229,13 +243,22 @@ again with an explicit destination:
229
243
  npx wendkeep flow promote $flowId --change-slug another-slug
230
244
  ```
231
245
 
246
+ Deliver an approved version without manufacturing another change:
247
+
248
+ ```bash
249
+ npx wendkeep delivery start release-0-73-0 --source-change proportional-governance --allow git:merge --allow git:push --allow publish
250
+ npx wendkeep delivery status release-0-73-0
251
+ npx wendkeep delivery finish release-0-73-0 --target v0.73.0 --ci-url <run> --version 0.73.0 --npm-integrity <sha512> --release-url <release>
252
+ ```
253
+
232
254
  ## Expected result
233
255
 
234
256
  Changing profile neither creates a new session nor interrupts the Vault. In `OFF`, memory and
235
257
  lessons are still injected and Stop still persists the session/memory lifecycle, while automatic
236
258
  router, skill gate, change context/warn/nag/guard, and plan capture are inactive. Explicit commands
237
259
  remain available and run their own contracts. A completed FLOW leaves a durable, inspectable
238
- receipt; a promoted FLOW enters the normal change lifecycle.
260
+ receipt; a promoted FLOW enters the normal change lifecycle. Completed delivery leaves a receipt
261
+ without an ADR; compact GUIDE archives its result without artificial spec/design/ADR.
239
262
 
240
263
  ## Common errors and diagnosis
241
264
 
@@ -254,6 +277,8 @@ receipt; a promoted FLOW enters the normal change lifecycle.
254
277
  retry `flow finish` or `flow promote`; the idempotent marker prevents duplication.
255
278
  - Pre-existing dirt appeared in the diff: it must match the initial fingerprint and must never be
256
279
  silently attributed to the FLOW.
280
+ - Delivery without `--allow`, with a dirty worktree, or with incomplete publish evidence: resume
281
+ the real implementation or provide the receipts; do not create a change only to publish.
257
282
 
258
283
  ## Next steps
259
284
 
@@ -26,11 +26,11 @@ and a vault bound to the correct project.
26
26
  ## Syntax
27
27
 
28
28
  ```bash
29
- npx wendkeep hook <name>
29
+ npx --no-install wendkeep hook <name>
30
30
  npx wendkeep session list
31
31
  npx wendkeep session show <id>
32
32
  npx wendkeep session use <id>
33
- npx wendkeep hook session-backfill --session <id> [--write]
33
+ npx --no-install wendkeep hook session-backfill --session <id> [--write]
34
34
  npx wendkeep import [options]
35
35
  ```
36
36
 
@@ -96,8 +96,8 @@ npx wendkeep import [options]
96
96
  ```bash
97
97
  npx wendkeep session list
98
98
  npx wendkeep session show 019abc-session-id
99
- npx wendkeep hook session-backfill --session 019abc-session-id
100
- npx wendkeep hook session-backfill --session 019abc-session-id --write
99
+ npx --no-install wendkeep hook session-backfill --session 019abc-session-id
100
+ npx --no-install wendkeep hook session-backfill --session 019abc-session-id --write
101
101
  npx wendkeep import --source codex --since 2026-07-01 --dry-run --json
102
102
  ```
103
103
 
@@ -25,7 +25,7 @@ Tenha o projeto inicializado, um vault saudável e `wendkeep.sensors.json` váli
25
25
  ## Sintaxe
26
26
 
27
27
  ```bash
28
- npx wendkeep change new <slug>
28
+ npx wendkeep change new <slug> [--simple|--guide]
29
29
  npx wendkeep change status [slug]
30
30
  npx wendkeep spec effective --change <slug>
31
31
  npx wendkeep sensors list
@@ -35,8 +35,10 @@ npx wendkeep change archive <slug>
35
35
 
36
36
  ## Opções e códigos de saída
37
37
 
38
- - `wendkeep change new <slug> [--simple]` cria uma change; `--simple` só pula o design, não é nem
39
- equivale a `FLOW` e preserva o lifecycle/ADR legado.
38
+ - `wendkeep change new <slug> [--simple|--guide]` cria uma change. `--simple` só pula o design,
39
+ não equivale a `FLOW` e preserva o lifecycle/ADR legado. `--guide` cria o contrato GUIDE
40
+ compacto (objetivo, aceite, áreas, testes e resultado), sem design/spec/ADR automático quando
41
+ `contract_impact:none`.
40
42
  - `change use`, `list`, `show`, `status`, `diff`, `done` e `undone` inspecionam ou atualizam o
41
43
  trabalho sem arquivar.
42
44
  - `change continue <arquivada> <nova>` abre continuação sem herdar evidência antiga.
@@ -52,6 +54,7 @@ npx wendkeep change archive <slug>
52
54
 
53
55
  ```bash
54
56
  npx wendkeep change new login-tenant
57
+ npx wendkeep change new ajuste-interno --guide
55
58
  npx wendkeep spec effective --change login-tenant
56
59
  npx wendkeep change done 1.1 --change login-tenant
57
60
  npx wendkeep verify --change login-tenant
@@ -67,8 +70,10 @@ npx wendkeep sensors add api-contracts "npm run test:contracts" --severity criti
67
70
 
68
71
  ## Resultado esperado
69
72
 
70
- A change arquivada move seu delta para o spec vivo, preserva proposta/design/tarefas/evidência e
71
- gera um ADR. O archive passa com tarefas fechadas, sensores exigidos verdes e verdict atual.
73
+ A change arquivada move seu delta para o spec vivo quando aplicável e preserva proposta,
74
+ tarefas/evidência e design quando existente. GOVERN/ASSURE geram ADR; GUIDE compacta sem impacto
75
+ de contrato não gera ADR automático. O archive só passa com tarefas fechadas, sensores exigidos
76
+ verdes e verdict atual.
72
77
 
73
78
  ## Cerca de escopo para ferramentas
74
79