pumuki 6.3.71 → 6.3.72

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 (33) hide show
  1. package/AGENTS.md +269 -0
  2. package/CHANGELOG.md +666 -0
  3. package/README.md +32 -0
  4. package/docs/README.md +7 -2
  5. package/docs/operations/RELEASE_NOTES.md +7 -0
  6. package/docs/product/USAGE.md +15 -2
  7. package/docs/tracking/plan-curso-pumuki-stack-my-architecture.md +111 -0
  8. package/integrations/git/GitService.ts +25 -0
  9. package/integrations/git/runPlatformGateFacts.ts +7 -0
  10. package/integrations/mcp/preFlightCheck.ts +2 -1
  11. package/integrations/sdd/openSpecCli.ts +12 -3
  12. package/package.json +4 -1
  13. package/scripts/consumer-menu-matrix-baseline-report-lib.ts +13 -38
  14. package/scripts/framework-menu-consumer-actions-lib.ts +28 -4
  15. package/scripts/framework-menu-consumer-preflight-hints.ts +5 -2
  16. package/scripts/framework-menu-consumer-runtime-actions.ts +86 -6
  17. package/scripts/framework-menu-consumer-runtime-audit.ts +36 -2
  18. package/scripts/framework-menu-consumer-runtime-evidence-classic.ts +140 -0
  19. package/scripts/framework-menu-consumer-runtime-lib.ts +2 -0
  20. package/scripts/framework-menu-consumer-runtime-types.ts +3 -1
  21. package/scripts/framework-menu-evidence-summary-lib.ts +1 -0
  22. package/scripts/framework-menu-evidence-summary-read.ts +57 -5
  23. package/scripts/framework-menu-evidence-summary-severity.ts +3 -1
  24. package/scripts/framework-menu-evidence-summary-types.ts +7 -0
  25. package/scripts/framework-menu-gate-lib.ts +9 -0
  26. package/scripts/framework-menu-layout-data.ts +5 -0
  27. package/scripts/framework-menu-matrix-baseline-lib.ts +15 -14
  28. package/scripts/framework-menu-matrix-canary-lib.ts +22 -1
  29. package/scripts/framework-menu-matrix-evidence-lib.ts +1 -0
  30. package/scripts/framework-menu-matrix-evidence-types.ts +13 -1
  31. package/scripts/framework-menu-matrix-runner-lib.ts +35 -0
  32. package/scripts/framework-menu-system-notifications-macos.ts +4 -0
  33. package/scripts/framework-menu.ts +3 -0
package/CHANGELOG.md ADDED
@@ -0,0 +1,666 @@
1
+ # Changelog
2
+
3
+ All notable changes to `pumuki` are documented here.
4
+
5
+ This project follows [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
+
7
+ ## [Unreleased]
8
+
9
+ ## [6.3.72] - 2026-04-11
10
+
11
+ ### Fixed
12
+
13
+ - **macOS notificaciones en `gate.blocked`**: por defecto vuelve a mostrarse el **banner** de Notification Center además del modal interactivo cuando el modal está activo. Antes, si el modal (Swift/AppleScript) no llegaba a mostrarse desde un hook en un repo consumidor, podía no verse **ninguna** notificación. Opt-in al comportamiento previo (solo modal, sin banner duplicado): `PUMUKI_MACOS_GATE_BLOCKED_BANNER_DEDUPE=1`.
14
+
15
+ ### Added
16
+
17
+ - **Tarball npm**: el paquete publicado incluye también `AGENTS.md`, `CHANGELOG.md` y `docs/tracking/plan-curso-pumuki-stack-my-architecture.md` (listados en `package.json` → `files`), de modo que la misma versión en **npm** / **jsDelivr** / `node_modules` expone contrato de agentes, historial de release y el plan formativo del curso Pumuki sin depender solo de GitHub.
18
+ - **Menú consumer (`npm run framework:menu`)**: opciones `11` (solo **staged**), `12` (solo **unstaged**: `git diff` + untracked), `13` (**staged + unstaged** con política **PRE_COMMIT** sobre el working tree), `14` (**todo el repo trackeado** sin preflight). Ejecutan el motor de gate **sin preflight** consumer. Nuevo alcance de hechos `unstaged` y `GitService.getUnstagedFacts`.
19
+ - **Vista “classic” en consola**: segundo panel tras el resumen consumer con severidades coloreadas (enterprise + legacy), hasta 45 hallazgos ordenados, filas **platform** si existen en la evidencia, y nota sobre heurística `Other`. Variable `PUMUKI_MENU_VINTAGE_REPORT=0` para desactivar.
20
+ - **Transparencia PRE_PUSH**: tras opciones `2` y `4` con outcome **PASS/WARN**, mensaje sobre posible **no escritura** en disco de `.ai_evidence.json` trackeado y variable `PUMUKI_PRE_PUSH_ALWAYS_WRITE_TRACKED_EVIDENCE`.
21
+ - **Etiquetas consumer** para opciones `1–4` y hints de evidencia/preflight alineados con alcance real (preflight vs motor, riesgo de skip en disco).
22
+
23
+ ### Changed
24
+
25
+ - **`runConsumerMenuMatrix` / baseline / summary**: la matriz consumer incluye también las opciones `11–14` (misma semántica que el menú: staged, unstaged, working tree **PRE_COMMIT**, repo completo, sin preflight), junto a `1–4` y `9`. Se exporta `MATRIX_MENU_OPTION_IDS` como lista canónica de ids.
26
+ - **OpenSpec / SDD**: detección y ejecución del CLI OpenSpec solo usan `node_modules/.bin/openspec` **del repositorio** (ya no se resuelve un `openspec` genérico del `PATH`). Instala `@fission-ai/openspec` en el consumidor para SDD estricto; evita resultados distintos entre máquinas con CLI global y CI limpio. Documentado en `docs/product/USAGE.md` (flujo SDD obligatorio, integración OpenSpec y troubleshooting).
27
+
28
+ ### Security
29
+
30
+ - Dependencias transitivas al día vía `npm audit fix` (p. ej. `ajv`, `brace-expansion`, `flatted`, `picomatch`).
31
+
32
+ ## [6.3.71] - 2026-04-06
33
+
34
+ ### Added
35
+
36
+ - **`operational_hints` en `.ai_evidence.json` (v2.1)**: `requires_second_pass`, `second_pass_reason`, `human_summary_lines` (resumen corto) y `rule_execution_breakdown` (evaluadas / bloqueo / warn / info / fuera de alcance). Tras PRE_COMMIT con índice solo documentación y evidencia trackeada, si no se auto-stagea el fichero, se reescribe la evidencia con `requires_second_pass=true` y motivo estable.
37
+ - **`PUMUKI_GATE_SCOPE_PATH_PREFIXES`**: lista separada por comas o `;` con prefijos de ruta; el gate filtra hechos de archivo del **primer** alcance (staged/range/worktree) para reducir ruido en monorepos (los heurísticos sin `filePath` y dependencias siguen pasando).
38
+ - **`pumuki doctor --parity`**: emite `parity_profile` (versión instalada + bundle/hash/signature de policy PRE_COMMIT). Si existe `.pumuki/ci-parity-expected.json` con `pumuki_package_version` / `pre_commit_policy_hash` / `pre_commit_policy_bundle`, añade `parity_comparison`; discrepancias hacen fallar el comando (exit 1) además del veredicto doctor habitual.
39
+
40
+ ### Changed
41
+
42
+ - **Remediaciones compartidas**: `integrations/gate/remediationCatalog.ts` unifica textos de remediación usados por hooks y por `ai_gate_check` (MCP) para los mismos códigos de violación.
43
+ - **PRE_COMMIT + `.ai_evidence.json` trackeado** (PUMUKI-INC-069): si el índice solo contiene documentación (`*.md` / `*.mdx`, aparte de la evidencia), el hook no hace `git add` automático tras un gate no bloqueante; opt-in: `PUMUKI_PRE_COMMIT_ALWAYS_RESTAGE_TRACKED_EVIDENCE=1`.
44
+
45
+ ## [6.3.70] - 2026-04-06
46
+
47
+ ### Fixed
48
+
49
+ - **PRE_PUSH + `.ai_evidence.json` trackeado**: si el fichero está en el índice de git y el outcome del gate **no** es `BLOCK` (`PASS`/`WARN`), Pumuki **ya no reescribe** `.ai_evidence.json` en disco. Evita que integraciones que ejecutan **pre-commit** dentro de **pre-push** fallen con *files were modified by this hook* pese a `decision=ALLOW`. La telemetría del gate sigue generándose; el snapshot versionado sigue siendo el último producido en **PRE_COMMIT** hasta el siguiente commit. Opt-in al comportamiento anterior: `PUMUKI_PRE_PUSH_ALWAYS_WRITE_TRACKED_EVIDENCE=1`.
50
+ - **macOS `gate.blocked` con modal activo**: no se envía el banner `osascript` duplicado cuando ya se muestra el diálogo interactivo (menos confusión con el Centro de notificaciones). Panel Swift: `KeyableFloatingPanel` + `becomesKeyOnlyIfNeeded = false` para que los botones **Desactivar / Silenciar 30 min / Mantener activas** reciban clics de forma fiable.
51
+
52
+ ## [6.3.69] - 2026-04-05
53
+
54
+ ### Changed
55
+
56
+ - **`gate.blocked` (macOS)**: además del banner/`osascript`, el mismo payload se escribe en **stderr** por defecto para que un bloqueo PRE_COMMIT/PRE_PUSH/CI sea visible aunque macOS no muestre la notificación (Focus, permisos del terminal, etc.). Silenciar solo ese duplicado: `PUMUKI_DISABLE_GATE_BLOCKED_STDERR_MIRROR=1`. Sigue aplicando `PUMUKI_DISABLE_STDERR_NOTIFICATIONS=1` para cortar cualquier vía stderr.
57
+ - **Modal de bloqueo (macOS)**: con notificaciones activas, el diálogo flotante/AppleScript con **Desactivar / Silenciar 30 min / Mantener activas** vuelve a estar **habilitado por defecto** (antes `blockedDialogEnabled` caía en `false` si no venía en JSON). Para desactivar solo el modal sin cortar banners: `"blockedDialogEnabled": false` en `.pumuki/system-notifications.json` o `PUMUKI_MACOS_BLOCKED_DIALOG=0`. Los clics se normalizan mejor (mayúsculas/espacios y salida ruidosa de `osascript`) para que mute/disable persistan en disco.
58
+ - **Hooks Git (`runPlatformGate`)**: se fusionan violaciones de política de repo desde `evaluateAiGate` que antes solo impactaban MCP/menú: **`GITFLOW_PROTECTED_BRANCH`** y **higiene de worktree** (`EVIDENCE_PREWRITE_WORKTREE_*`, mismos umbrales `PUMUKI_PREWRITE_WORKTREE_*`) ahora aplican también en **PRE_COMMIT**, **PRE_PUSH** y **CI** cuando la evidencia es válida (git-flow y pending_changes siguen activos aunque falte evidencia vía `evaluateAiGate`).
59
+
60
+ ### Migration
61
+
62
+ - Si tenías `.pumuki/system-notifications.json` con `"enabled": true` y **omitías** `blockedDialogEnabled` asumiendo que el modal estaba apagado, ahora el modal queda **encendido**. Fija explícitamente `"blockedDialogEnabled": false` para recuperar el comportamiento anterior.
63
+
64
+ ## [6.3.68] - 2026-04-06
65
+
66
+ ### Added
67
+
68
+ - **PRE_WRITE en la cadena Git (sin IDE)**: los hooks gestionados **`pre-commit`** y **`pre-push`** ejecutan **`pumuki-pre-write`** antes del binario principal. Así el stage **PRE_WRITE** forma parte del flujo real de cualquier repo con Git. Desactivar solo esa parte: `PUMUKI_SKIP_CHAINED_PRE_WRITE=1`.
69
+ - **`.pumuki/adapter.json` por defecto**: en **`pumuki install`**, si el fichero no existe, se genera con plantilla **`repo`** (comandos de hooks + MCP enterprise/evidence) para que los procesos stdio y la documentación del repo no dependan de Cursor/Codex.
70
+
71
+ ## [6.3.67] - 2026-04-06
72
+
73
+ ### Fixed
74
+
75
+ - **Línea base agnóstica al IDE**: el `postinstall` de npm **no** debe acoplar Pumuki a Cursor, Codex ni ningún IDE. Se revierte el experimento **6.3.66** que ejecutaba `pumuki install --with-mcp --agent=cursor` por defecto. El postinstall vuelve a ser solo **`pumuki install`** (hooks Git, estado de lifecycle, evidencia cuando aplica; OpenSpec sigue **omitido** por defecto en ese camino, como en **6.3.63+**).
76
+ - **Adaptadores opcionales**: MCP, `.cursor/`, `.claude/`, etc. siguen disponibles con **`pumuki install --with-mcp --agent=<nombre>`** o **`pumuki bootstrap --enterprise`**, explícitos por repo/equipo.
77
+
78
+ ### Changed
79
+
80
+ - Plantilla **Cursor** del adaptador: se mantienen **fusión JSON** en `.cursor/mcp.json` y **`.pumuki/adapter.json`** cuando el usuario elige `--agent=cursor` (no en postinstall).
81
+
82
+ ## [6.3.65] - 2026-04-06
83
+
84
+ ### Fixed
85
+
86
+ - **Integración con pre-commit.com**: si el hook `pre-commit` termina en `exec … pre_commit`, el bloque gestionado por Pumuki se insertaba **después** y nunca se ejecutaba. Ahora se detecta esa plantilla y el bloque Pumuki se coloca **justo después del shebang**, antes del `exec`. Tras actualizar, ejecutar `pumuki install` en el consumer para reescribir `.git/hooks/pre-commit`.
87
+
88
+ ## [6.3.64] - 2026-04-05
89
+
90
+ ### Fixed
91
+
92
+ - **System notifications fuera de macOS**: el gate ya no bloquea por plataforma; en Linux/Windows/WSL (y similares) el payload se escribe en **stderr** por defecto (`reason: stderr-fallback`). Silenciar con `PUMUKI_DISABLE_STDERR_NOTIFICATIONS=1` (vuelve `unsupported-platform` sin escribir).
93
+ - **macOS**: si el banner falla (`command-failed`), se aplica el mismo fallback a stderr salvo que el fallback esté desactivado. `PUMUKI_NOTIFICATION_STDERR_MIRROR=1` duplica el texto en stderr además del banner nativo.
94
+
95
+ ## [6.3.63] - 2026-04-05
96
+
97
+ ### Added
98
+
99
+ - **`npm` postinstall (consumer)**: tras `npm install` en un repo Git, Pumuki ejecuta `pumuki install` de forma automática (`INIT_CWD`), sin OpenSpec bootstrap por defecto en ese camino. Desactivar con `PUMUKI_SKIP_POSTINSTALL=1` o en CI (`CI=true`). No sustituye la configuración manual de MCP en el IDE.
100
+ - **Best-effort install**: si `doctor` bloquea el baseline pero `PUMUKI_AUTO_POSTINSTALL=1` (postinstall), se cablean igualmente hooks + estado + evidencia bootstrap con aviso de modo degradado.
101
+
102
+ ## [6.3.62] - 2026-04-05
103
+
104
+ ### Fixed
105
+
106
+ - macOS system notifications: anti-spam **blocked** dialog is now **opt-in** (`PUMUKI_MACOS_BLOCKED_DIALOG=1` or `"blockedDialogEnabled": true` in `.pumuki/system-notifications.json`); default path stays banner-only. Swift panel wiring hardened (focus, window lifecycle).
107
+
108
+ ### Changed
109
+
110
+ - CLI / lifecycle test fixtures aligned with `PRE_WRITE` in policy payloads (`source` fields, doctor/status JSON shape).
111
+ - Gate / git hook / framework-menu tests refreshed (stage policies, hook summaries, consumer menu layout group titles).
112
+ - File-size guardrail overrides updated for current `cli` / gate sources; install smoke fixture version aligned with package semver.
113
+
114
+ ## [6.3.61] - 2026-03-31
115
+
116
+ ### Fixed
117
+
118
+ - `PRE_WRITE` and `PRE_COMMIT` now block brownfield hotspots before structural debt accumulates.
119
+ - `BrownfieldHotspotGuard` enforces file-size thresholds plus required refactor plans and ADRs for flagged hotspots.
120
+ - Gate policy/profile wiring now treats `PRE_WRITE` as a first-class stage across skills and policy packs.
121
+
122
+ ### Changed
123
+
124
+ - iOS enforcement now vendors `swift-testing-expert` and `core-data-expert` and adds a versioned SwiftUI modernization snapshot.
125
+ - New auditable rules detect legacy `foregroundColor`, `cornerRadius`, `tabItem`, and `ScrollView(..., showsIndicators: false)` usage.
126
+ - Skills compilation, evidence mapping, and iOS rule-pack docs stay aligned with the new enforcement bundle.
127
+
128
+ ## [6.3.57] - 2026-03-11
129
+
130
+ ### Changed
131
+
132
+ - Semantic findings now carry richer AST-driven payloads across the gate/evidence pipeline.
133
+ - TypeScript, iOS and Android heuristic extraction adds structured context such as semantic node coverage and platform-specific signal enrichment.
134
+ - Evidence/gate evaluation now preserves that richer traceability for downstream consumers and diagnostics.
135
+ - The vendored enterprise skill chain is now canonical in the published package.
136
+ - `vendor/skills/*` and `docs/codex-skills/*-enterprise-rules.md` stay aligned with the runtime package manifest and release tooling.
137
+ - Package validation and sync scripts now follow the canonical `*-enterprise-rules` naming instead of legacy `windsurf-rules-*` paths.
138
+
139
+ ## [6.3.56] - 2026-03-11
140
+
141
+ ### Fixed
142
+
143
+ - `PRE_COMMIT` no longer reintroduces `.ai_evidence.json` into the index when that file is tracked in the repo but was not staged before the gate started.
144
+ - Successful commit flows now restore tracked evidence deterministically instead of contaminating unrelated commits with refreshed evidence.
145
+
146
+ ## [6.3.55] - 2026-03-06
147
+
148
+ ### Fixed
149
+
150
+ - `status` and `doctor` now detect when the consumer repository path contains the system `PATH` delimiter and `npx/npm exec` can therefore fail to resolve `pumuki`.
151
+ - They now expose:
152
+ - `version.pathExecutionHazard`
153
+ - `version.pathExecutionWarning`
154
+ - `version.pathExecutionWorkaroundCommand`
155
+ - `version.alignmentCommand` now switches automatically to a safe local invocation when the repo path makes `PATH`-based execution unsafe.
156
+ - On POSIX consumers such as `SAAS:APP_SUPERMERCADOS`, remediation now points to `node ./node_modules/pumuki/bin/pumuki.js install` instead of an `npx --package ... pumuki install` command that can fail with `sh: pumuki: command not found`.
157
+ - Human-readable `pumuki status` and `pumuki doctor` now print both:
158
+ - `execution warning`
159
+ - `execution workaround`
160
+ when this path hazard is detected.
161
+
162
+ ## [6.3.54] - 2026-03-06
163
+
164
+ ### Fixed
165
+
166
+ - The published npm package now includes `docs/codex-skills/*.md`.
167
+ - Consumers can compile the core skills lock from `skills.sources.json` inside `node_modules/pumuki` instead of silently losing `backend-guidelines`, `frontend-guidelines`, `ios-guidelines`, `swift-concurrency`, `swiftui-expert-skill`, and `android-guidelines`.
168
+ - Package manifest validation now treats the vendored codex skill markdown files as required runtime package assets.
169
+ - This prevents future releases from shipping a tarball where skills coverage gates fail in consumers because the package is missing its own core skill sources.
170
+
171
+ ## [6.3.53] - 2026-03-06
172
+
173
+ ### Fixed
174
+
175
+ - `pumuki watch` now respects the requested `repoRoot` when collecting facts and running the gate in cross-repo mode.
176
+ - Prevents false findings and notifications coming from the current working directory instead of the target checkout.
177
+ - `PRE_WRITE` worktree hygiene now uses deduplicated pending file count when repo state provides it.
178
+ - Avoids overcounting partially staged files such as `MM foo.ts`.
179
+ - Custom skills bundle hashes now include `ast_node_ids`.
180
+ - Policy/evidence drift detection now changes when AST coverage of `AUTO` rules changes.
181
+ - `auto_execute_ai_start` now treats `EVIDENCE_CHAIN_INVALID` as an actionable evidence failure.
182
+ - The next action now tells the user to regenerate or refresh evidence instead of falling back to a generic message.
183
+
184
+ ## [6.3.52] - 2026-03-06
185
+
186
+ ### Fixed
187
+
188
+ - `pumuki status` and `pumuki doctor` now expose version semantics explicitly instead of mixing runtime, consumer-installed and lifecycle-installed versions under an ambiguous single label.
189
+ - Both commands now include a structured `version` block with:
190
+ - `effective`
191
+ - `runtime`
192
+ - `consumerInstalled`
193
+ - `lifecycleInstalled`
194
+ - `source`
195
+ - `driftFromRuntime`
196
+ - `driftFromLifecycleInstalled`
197
+ - `driftWarning`
198
+ - Human-readable output now reports:
199
+ - effective version,
200
+ - runtime version,
201
+ - consumer installed version,
202
+ - lifecycle installed version,
203
+ - and an explicit drift warning when those values diverge.
204
+
205
+ ## [6.3.51] - 2026-03-06
206
+
207
+ ### Fixed
208
+
209
+ - `PRE_COMMIT` no longer leaves `.ai_evidence.json` dirty after a successful commit when that file was already tracked.
210
+ - The hook now re-stages the refreshed evidence only when the file is already part of the index.
211
+ - `PRE_PUSH` now respects the exact hook refspec range (`remoteOid..localOid`) when publishing a specific commit instead of always evaluating `upstream..HEAD`.
212
+ - `PRE_PUSH` now suspends SDD session enforcement for historical publishes that target an exact commit different from current `HEAD`.
213
+ - Prevents false `SDD_SESSION_*` / `SDD_CHANGE_*` blocks when replaying already closed commits.
214
+ - `pumuki sdd evidence` keeps the repo-bound safety check for `--test-output`, but now suggests an immediate valid ephemeral path inside the repo, such as `.pumuki/runtime/<file>.log`.
215
+
216
+ ## [6.3.50] - 2026-03-05
217
+
218
+ ### Improved
219
+
220
+ - `GIT_ATOMICITY_TOO_MANY_SCOPES` now includes actionable scope/file breakdown in the blocking payload.
221
+ - Adds `scope_files=...` with per-scope count and sample files.
222
+ - Improves deterministic split guidance in remediation (`Sugerencia split`).
223
+ - Gate block summary `next_action` for this code now points explicitly to the `scope_files` breakdown before splitting staging.
224
+
225
+ ## [6.3.49] - 2026-03-05
226
+
227
+ ### Fixed
228
+
229
+ - `pumuki watch --json` now aligns `lastTick.changed` with real file delta of the evaluated scope.
230
+ - For `scope=staged`, when no staged files are present (`changedFiles=[]`, `evaluatedFiles=[]`), `changed=false`.
231
+ - Avoids ambiguous interpretation where `changed=true` previously represented tick execution instead of actual scoped changes.
232
+
233
+ ## [6.3.48] - 2026-03-05
234
+
235
+ ### Fixed
236
+
237
+ - `pumuki watch` now enforces manifest integrity guard during gate evaluation:
238
+ - snapshots/restores `package.json`, `package-lock.json`, `pnpm-lock.yaml`, and `yarn.lock`,
239
+ - blocks the tick with `MANIFEST_MUTATION_DETECTED` when unexpected mutation is detected and reverted.
240
+ - Hook-stage manifest guard (`PRE_COMMIT` / `PRE_PUSH`) now also covers `pnpm-lock.yaml` and `yarn.lock` in addition to npm manifests.
241
+ - Prevents silent dependency drift in consumer repos during validation flows when no explicit upgrade command is requested.
242
+
243
+ ## [6.3.47] - 2026-03-05
244
+
245
+ ### Fixed
246
+
247
+ - Hooks/gates now enforce manifest integrity in `PRE_COMMIT` and `PRE_PUSH`:
248
+ - snapshot + automatic restore for `package.json` and `package-lock.json`,
249
+ - explicit block code `MANIFEST_MUTATION_DETECTED` when unexpected mutation is detected.
250
+ - Prevents unintended consumer manifest drift during normal hook/gate execution unless upgrade is explicitly requested by the developer.
251
+
252
+ ## [6.3.46] - 2026-03-05
253
+
254
+ ### Added
255
+
256
+ - `pumuki watch --json` ahora expone metadata de versión efectiva/runtime:
257
+ - `version.effective`
258
+ - `version.runtime`
259
+ - `version.consumerInstalled`
260
+ - `version.source`
261
+ - `version.driftFromRuntime`
262
+ - `version.driftWarning` (cuando hay desalineación).
263
+
264
+ ### Fixed
265
+
266
+ - Hooks (`pre-commit`/`pre-push`) ahora auto-reconcilian policy (`--strict --apply`) y reintentan una vez cuando el bloqueo corresponde a códigos de skills coverage:
267
+ - `SKILLS_PLATFORM_COVERAGE_INCOMPLETE_HIGH`
268
+ - `SKILLS_SCOPE_COMPLIANCE_INCOMPLETE_HIGH`
269
+ - `EVIDENCE_PLATFORM_SKILLS_SCOPE_INCOMPLETE`
270
+ - `EVIDENCE_PLATFORM_SKILLS_BUNDLES_MISSING`
271
+ - `EVIDENCE_CROSS_PLATFORM_CRITICAL_ENFORCEMENT_INCOMPLETE`
272
+ - Se reduce fricción de bootstrap manual repetitivo entre iteraciones al unificar comportamiento de hook con `watch`.
273
+
274
+ ## [6.3.45] - 2026-03-05
275
+
276
+ ### Added
277
+
278
+ - `pumuki sdd sync-docs` sincroniza por defecto los tres documentos canónicos del consumer cuando existen:
279
+ - `docs/strategy/ruralgo-tracking-hub.md`
280
+ - `docs/technical/08-validation/refactor/operational-summary.md`
281
+ - `docs/validation/refactor/last-run.json`
282
+ - `pumuki sdd auto-sync` incluye por defecto artefactos OpenSpec por cambio:
283
+ - `openspec/changes/<change>/tasks.md`
284
+ - `openspec/changes/<change>/design.md`
285
+ - `openspec/changes/<change>/retrospective.md`
286
+
287
+ ### Changed
288
+
289
+ - MCP tools (`ai_gate_check`, `pre_flight_check`, `auto_execute_ai_start`) ahora incorporan `learning_context` automáticamente desde `openspec/changes/<change>/learning.json` cuando existe cambio activo.
290
+
291
+ ### Fixed
292
+
293
+ - `sync-docs` crea secciones managed faltantes de forma idempotente y evita conflictos falsos al inicializar documentación canónica nueva.
294
+
295
+ ## [6.3.43] - 2026-03-05
296
+
297
+ ### Changed
298
+
299
+ - `pumuki sdd evidence` now emits TDD/BDD-compatible contract by default:
300
+ - `version` normalized to `"1"`,
301
+ - includes required `slices[]` payload (`red/green/refactor`) for gate validation.
302
+ - Legacy compatibility is preserved in the scaffold payload:
303
+ - keeps `scenario_id`, `test_run`, and `ai_evidence` fields used by existing consumers.
304
+
305
+ ### Fixed
306
+
307
+ - Resolved consumer regression where scaffolded evidence was rejected as invalid (`TDD_BDD_EVIDENCE_INVALID`):
308
+ - previous payload used `version: "1.0"` without `slices[]`.
309
+ - `sdd state-sync` now accepts source evidence versions `1` and `1.0` for backward compatibility during rollout.
310
+
311
+ ## [6.3.42] - 2026-03-05
312
+
313
+ ### Changed
314
+
315
+ - Blocked modal (macOS Swift helper) now prioritizes readable vertical layout:
316
+ - narrower width range (`360..620`) to avoid oversized horizontal dialogs,
317
+ - dynamic height growth from content fitting size,
318
+ - compact typography for cause/remediation blocks.
319
+ - Blocked remediation text is now more actionable by default:
320
+ - richer guidance for `EVIDENCE_*`, `PRE_PUSH_UPSTREAM_MISSING`, `SDD_SESSION_*`,
321
+ - remediation truncation budget increased to preserve useful resolution steps.
322
+
323
+ ### Fixed
324
+
325
+ - Improved multiline wrapping behavior in floating blocked dialog:
326
+ - explicit word wrapping and multiline cell configuration for title/cause/remediation,
327
+ - avoids aggressive truncation in long real-world messages.
328
+ - Bottom-right pinning remains stable after dynamic relayout on real displays.
329
+
330
+ ## [6.3.41] - 2026-03-05
331
+
332
+ ### Changed
333
+
334
+ - macOS blocked notifications now include project context in subtitle:
335
+ - format: `<project> · <stage> · <cause-summary>`,
336
+ - improves differentiation when multiple repos are active.
337
+ - Blocked dialog is now enabled by default on macOS for `gate.blocked`:
338
+ - explicit override remains available via `PUMUKI_MACOS_BLOCKED_DIALOG=0|1`,
339
+ - existing anti-spam controls (`mute/disable`) are preserved.
340
+
341
+ ### Fixed
342
+
343
+ - Notification config parser and persistence now carry `blockedDialogEnabled` deterministically.
344
+ - Added regression coverage for:
345
+ - project label rendering in blocked subtitle,
346
+ - default blocked-dialog activation without explicit env flag.
347
+
348
+ ## [6.3.40] - 2026-03-05
349
+
350
+ ### Added
351
+
352
+ - AST Intelligence dual validation PoC (`#616`) with compatibility-first rollout:
353
+ - new dual mode runtime: `PUMUKI_AST_INTELLIGENCE_DUAL_MODE=off|shadow|strict`,
354
+ - new guard findings:
355
+ - `governance.ast-intelligence.dual-validation.shadow` (`INFO`, non-blocking),
356
+ - `governance.ast-intelligence.dual-validation.mismatch` (`ERROR`, blocking in `strict`),
357
+ - deterministic runtime summary in gate logs:
358
+ - mapped rules, divergences, `false_positives`, `false_negatives`, `latency_ms`, languages.
359
+ - RFC + roadmap for AST Intelligence by nodes:
360
+ - `docs/validation/ast-intelligence-validation-roadmap.md`,
361
+ - includes architecture target, 30/60/90 plan, rollout and rollback contract.
362
+ - Backlog watcher/reconcile JSON now includes `next_commands[].probe_kind`:
363
+ - `json_contract` for dry-run probe validation.
364
+ - `state_recheck` for apply probe validation.
365
+
366
+ ### Fixed
367
+
368
+ - Stage gates now block deterministically when code changes are detected but rules coverage has no active rules:
369
+ - new finding `governance.rules.active-rule-coverage.empty`,
370
+ - code `ACTIVE_RULE_IDS_EMPTY_FOR_CODE_CHANGES_HIGH`,
371
+ - prevents false-green `PASS/ALLOW` with `active_rule_ids=[]` on code surfaces.
372
+ - iOS XCTest quality enforcement for enterprise gates (`PRE_COMMIT/PRE_PUSH/CI`):
373
+ - new finding `governance.skills.ios-test-quality.incomplete`,
374
+ - code `IOS_TEST_QUALITY_PATTERN_MISSING_HIGH`,
375
+ - blocks when XCTest sources in `apps/ios/**/Tests/**.swift` miss `makeSUT()` and/or `trackForMemoryLeaks()`.
376
+ - Fixed findings trace consistency in stage gates:
377
+ - guard-driven blocking conditions are now always propagated to `effectiveFindings`,
378
+ - avoiding opaque `BLOCK` outcomes without explicit finding payload.
379
+ - PRE_PUSH scope false positives caused by upstream misalignment now fail fast with deterministic signal:
380
+ - upstream drift is detected earlier (`PRE_PUSH_UPSTREAM_MISALIGNED`) before scope coverage evaluation.
381
+ - Local smoke for consumer install now falls back deterministically when `npx --no-install` crashes with runtime import errors (`MODULE_NOT_FOUND`).
382
+ - `ai_gate_check` consistency hints now cover legacy `EVIDENCE_*` codes (including `EVIDENCE_INTEGRITY_MISSING`) to reduce hook-vs-MCP diagnosis drift.
383
+
384
+ ## [6.3.39] - 2026-03-04
385
+
386
+ ### Added
387
+
388
+ - Cross-platform critical skills enforcement in platform gate evaluation:
389
+ - new blocking finding `governance.skills.cross-platform-critical.incomplete` when a detected platform has no critical (`CRITICAL/ERROR`) skills rules active/evaluated.
390
+
391
+ ### Changed
392
+
393
+ - Adapter-generated hook/CI commands now resolve robustly through:
394
+ - `npx --yes --package pumuki@latest ...`
395
+ - eliminating fragile dependency on local `./node_modules/.bin` availability in consumer repos.
396
+ - Git atomicity enforcement is now enabled by default:
397
+ - base guard is active out-of-the-box for `PRE_COMMIT/PRE_PUSH/CI`,
398
+ - existing env/config overrides are preserved for controlled opt-out or threshold tuning.
399
+ - Lifecycle hook diagnostics now expose effective hooks path resolution:
400
+ - `status`/`doctor` include `hooksDirectory` and `hooksDirectoryResolution`,
401
+ - console output now prints the effective hook path used for evaluation.
402
+
403
+ ### Fixed
404
+
405
+ - Commit-range facts resolution no longer crashes or degrades ambiguously when refs are not resolvable (for example repos without `HEAD` yet):
406
+ - guarded `rev-parse --verify` + safe fallback behavior in git-range facts collection.
407
+ - `core.hooksPath` hardening for versioned hooks:
408
+ - hook path resolution now falls back to local `.git/config` (`core.hooksPath`) when `git rev-parse --git-path hooks` is unavailable,
409
+ - non-regression coverage added for both versioned hooks and fallback resolution.
410
+ - Stage-gates non-regression suite stabilization:
411
+ - updated lifecycle ingestion and preflight fixtures to the current evidence v2.1 contract (`evidence_chain` and `evidence.source`),
412
+ - aligned architecture guardrail overrides for the current orchestrator module size/import profile (`integrations/lifecycle/cli.ts`).
413
+
414
+ ## [6.3.38] - 2026-03-04
415
+
416
+ ### Added
417
+
418
+ - Optional macOS blocked dialog flow for gate failures (`PUMUKI_MACOS_BLOCKED_DIALOG=1`):
419
+ - full cause + remediation detail in modal dialog,
420
+ - anti-spam user controls in dialog:
421
+ - `Mantener activas`
422
+ - `Silenciar 30 min`
423
+ - `Desactivar`
424
+ - auto-timeout (`15s`) to avoid hanging local execution when no user interaction happens.
425
+
426
+ ### Changed
427
+
428
+ - Blocked macOS notification UX is now short and human-readable by default:
429
+ - title in Spanish (`🔴 Pumuki bloqueado`),
430
+ - compact subtitle with stage + summarized cause,
431
+ - message starts with `Solución: ...` so remediation is visible in banner-limited space.
432
+ - Added mute-aware notification delivery:
433
+ - support for `muteUntil` in `.pumuki/system-notifications.json`,
434
+ - suppressed delivery while mute window is active (`reason=muted`).
435
+
436
+ ### Fixed
437
+
438
+ - Stabilized `stageRunners` test baseline against current core-skills contract:
439
+ - test harness now keeps core skills enabled (`PUMUKI_DISABLE_CORE_SKILLS=0`) to avoid false gate blocks from scope/platform compliance rules,
440
+ - restored passing regression set for affected suite.
441
+
442
+ ## [6.3.24] - 2026-02-27
443
+
444
+ ### Added
445
+
446
+ - New deterministic local loop runner workflow in lifecycle CLI:
447
+ - `pumuki loop run --objective=<text> [--max-attempts=<n>]`
448
+ - `pumuki loop status --session=<id>`
449
+ - `pumuki loop stop --session=<id>`
450
+ - `pumuki loop resume --session=<id>`
451
+ - `pumuki loop list`
452
+ - `pumuki loop export --session=<id> --output-json=<path>`
453
+ - Session contract and local deterministic store for loop execution:
454
+ - `integrations/lifecycle/loopSessionContract.ts`
455
+ - `integrations/lifecycle/loopSessionStore.ts`
456
+ - Per-attempt loop evidence snapshots:
457
+ - `.pumuki/loop-sessions/<session-id>.attempt-<n>.json`
458
+
459
+ ### Changed
460
+
461
+ - `pumuki loop run` now executes one strict fail-fast gate attempt (`workingTree` scope) and persists outcome/evidence atomically.
462
+ - Documentation updated with loop commands and runtime semantics:
463
+ - `README.md`
464
+ - `docs/product/USAGE.md`
465
+
466
+ ### Fixed
467
+
468
+ - Stabilized waiver test against clock drift by using a future deterministic expiry in:
469
+ - `integrations/git/__tests__/tddBddEnforcement.test.ts`
470
+ - Aligned `VERSION` file with active package line (`v6.3.24`).
471
+
472
+ ## [6.3.23] - 2026-02-27
473
+
474
+ ### Changed
475
+
476
+ - Restored README hero behavior to the prior full-width classic brand rendering:
477
+ - `<img src="assets/logo.png" alt="Pumuki" width="100%" />`
478
+ - Keeps a deterministic, simple image path for npm and GitHub renderers.
479
+
480
+ ## [6.3.22] - 2026-02-27
481
+
482
+ ### Changed
483
+
484
+ - Final README hero render fix for npm/GitHub consistency:
485
+ - switched hero asset reference from SVG to raster banner PNG:
486
+ - `![Pumuki](assets/logo_banner.png)`
487
+ - added generated `assets/logo_banner.png` (2400x720) to avoid npm SVG rendering differences.
488
+
489
+ ## [6.3.21] - 2026-02-27
490
+
491
+ ### Changed
492
+
493
+ - Forced root `README.md` hero banner to explicit full-width rendering using HTML:
494
+ - `<img src=\"assets/logo_banner.svg\" alt=\"Pumuki\" width=\"100%\" />`
495
+
496
+ ## [6.3.20] - 2026-02-27
497
+
498
+ ### Changed
499
+
500
+ - Restored root `README.md` hero image to full-width banner rendering (`assets/logo_banner.svg`).
501
+
502
+ ## [6.3.19] - 2026-02-27
503
+
504
+ ### Changed
505
+
506
+ - Restored root `README.md` hero image to classic `assets/logo.png` rendering.
507
+
508
+ ### Added
509
+
510
+ - Added a friendly GitHub star reminder section at the end of root `README.md`.
511
+
512
+ ## [6.3.18] - 2026-02-27
513
+
514
+ ### Added
515
+
516
+ - Added production operations policy document at `docs/operations/production-operations-policy.md` with:
517
+ - SaaS operation scope
518
+ - minimum SLO/SLA targets
519
+ - incident severity and response expectations
520
+ - alerting baseline and go-live checklist
521
+ - Added dedicated README walkthrough document at `docs/operations/framework-menu-consumer-walkthrough.md` for menu Option 1 captures.
522
+ - Added explicit collaboration section in root `README.md` with contributor expectations and minimum validation commands.
523
+
524
+ ### Changed
525
+
526
+ - Root `README.md` was rebuilt with enterprise-first structure:
527
+ - audience split (consumer, maintainers, platform owners)
528
+ - 5-minute consumer quick start moved to top
529
+ - framework-only commands separated from consumer commands
530
+ - troubleshooting expanded with validated failure modes and required flags
531
+ - documentation index expanded and normalized
532
+ - Updated docs index and usage/install guides to include operations policy and walkthrough references:
533
+ - `docs/README.md`
534
+ - `docs/product/USAGE.md`
535
+ - `docs/product/INSTALLATION.md`
536
+ - Validation command documentation now reflects real prerequisites and execution semantics:
537
+ - required flags for `validation:*` scripts (`--repo`, `--repo-path`, `--skip-workflow-lint`)
538
+ - non-zero diagnostic verdict behavior documented (`BLOCKED`, `PENDING`, `MISSING_INPUTS`).
539
+
540
+ ### Fixed
541
+
542
+ - Corrected legacy parity report command syntax in docs to required `--legacy=<path>` and `--enterprise=<path>` argument format.
543
+ - Corrected custom skills import documentation to use real absolute `SKILL.md` source paths instead of placeholder pseudo-paths.
544
+
545
+ ## [6.3.17] - 2026-02-20
546
+
547
+ ### Added
548
+
549
+ - Introduced deterministic `repo_state.lifecycle.hard_mode` capture in evidence generation (`.pumuki/hard-mode.json` persisted and normalized into `.ai_evidence.json`).
550
+ - Added lifecycle adapter scaffolding command surface:
551
+ - `pumuki adapter install --agent=<codex|claude|cursor|windsurf|opencode> [--dry-run]`
552
+ - `npm run adapter:install -- --agent=<name>`
553
+ - Added framework menu hard-mode configuration action for enterprise operation (`Configure hard mode enforcement (enterprise)`).
554
+
555
+ ### Changed
556
+
557
+ - Unified AI Gate contract now carries resolved policy trace for all stages, including `PRE_WRITE` mapped deterministically to `PRE_COMMIT` policy resolution.
558
+ - Enterprise MCP tool `ai_gate_check` now returns resolved policy metadata (`policy.stage`, `policy.resolved_stage`, `policy.trace`) in the tool result envelope.
559
+ - Refreshed `README.md` with enterprise-first onboarding structure (quickstart, hard mode, PRE_WRITE chain contract, lifecycle/adapters, MCP map).
560
+
561
+ ### Fixed
562
+
563
+ - Closed PRE_WRITE/MCP policy drift by propagating the same hard-mode persisted policy trace used in `PRE_COMMIT/PRE_PUSH/CI`.
564
+
565
+ ## [6.3.16] - 2026-02-20
566
+
567
+ ### Fixed
568
+
569
+ - MCP evidence `/status` now guarantees `evidence.exists` as a strict boolean across `missing`, `invalid`, and `valid` evidence states (no `null` ambiguity), while preserving `evidence.present` as compatibility alias.
570
+ - Evidence runtime consolidation now deduplicates base/skills overlaps with deterministic semantic collision keys (`stage+platform+file+anchor+family`), preserving suppressed traceability metadata (`replacedByRuleId`, `replacementRuleId`, `platform`, `reason`).
571
+ - Runtime dependency `ts-morph` minimum version is now `>=27.0.2`, removing the high-severity production chain `ts-morph -> @ts-morph/common -> minimatch<10.2.1`; `npm audit --omit=dev` is now clean (`0` vulnerabilities).
572
+ - Fixed strict TypeScript typing in `integrations/evidence/buildEvidence.ts` (`normalizeAnchorLine`) to avoid union narrowing errors during `tsc --noEmit`.
573
+
574
+ ### Changed
575
+
576
+ - Consolidated official documentation index and references to the active enterprise set only.
577
+ - Updated governance references from `CLAUDE.md` to `PUMUKI.md` across active docs.
578
+
579
+ ### Removed
580
+
581
+ - Deprecated documentation artifacts and duplicated image mirrors under `docs/images/*`.
582
+ - Legacy docs-hygiene command path from package scripts and framework menu maintenance actions.
583
+ - Docs-hygiene-only guardrail tests and helper scripts that were not part of runtime enforcement.
584
+
585
+ ## [6.3.15] - 2026-02-19
586
+
587
+ ### Fixed
588
+
589
+ - Removed unused runtime dependency `glob` from `dependencies` to eliminate the vulnerable consumer chain `pumuki -> glob -> minimatch` without changing the Node.js support baseline (`>=18`).
590
+ - Regenerated lockfile after dependency cleanup to keep published manifest deterministic.
591
+
592
+ ## [6.3.14] - 2026-02-18
593
+
594
+ ### Added
595
+
596
+ - New lifecycle command `pumuki remove` to perform enterprise cleanup and dependency removal in one step:
597
+ - removes managed hooks and lifecycle local state,
598
+ - purges untracked evidence artifacts,
599
+ - uninstalls `pumuki` from the consumer `package.json`,
600
+ - package canonical name migrated from `pumuki-ast-hooks` to `pumuki` for enterprise UX (`npm install pumuki`),
601
+ - prunes orphan `node_modules/.package-lock.json` residue when `node_modules` has no other content.
602
+ - OpenSpec+SDD enterprise baseline:
603
+ - new SDD integration module at `integrations/sdd/*` (policy, session store, OpenSpec CLI adapter),
604
+ - new commands `pumuki sdd status`, `pumuki sdd session`, `pumuki sdd validate`,
605
+ - new pre-write gate command `pumuki-pre-write` / `pumuki:sdd:pre-write`,
606
+ - SDD enforcement integrated across `PRE_WRITE`, `PRE_COMMIT`, `PRE_PUSH`, and `CI`,
607
+ - emergency bypass support `PUMUKI_SDD_BYPASS=1` with explicit evidence traceability.
608
+ - New enterprise MCP server `pumuki-mcp-enterprise`:
609
+ - resources: `evidence://status`, `gitflow://state`, `context://active`, `sdd://status`, `sdd://active-change`,
610
+ - tools: `ai_gate_check`, `check_sdd_status`, `validate_and_fix`, `sync_branches`, `cleanup_stale_branches`,
611
+ - fail-safe response envelope for `/tool` executions with deterministic JSON.
612
+
613
+ ### Changed
614
+
615
+ - Stage-gates test execution now uses glob-based test targets for easier maintenance.
616
+ - Lifecycle bootstrap/update now manage OpenSpec compatibility automatically:
617
+ - `pumuki install` bootstraps OpenSpec when missing,
618
+ - `pumuki update --latest` migrates legacy `openspec` package to `@fission-ai/openspec` when needed.
619
+ - Evidence v2.1 payload now includes SDD observability:
620
+ - `sdd_metrics` section in snapshot payload,
621
+ - SDD blocking findings emitted with `source: "sdd-policy"`.
622
+ - Active documentation guardrails now enforce:
623
+ - English-only baseline for active enterprise docs.
624
+ - Local markdown reference integrity for active docs.
625
+ - Interactive framework menu now defaults to `Consumer` mode and separates the full surface behind `Advanced` mode (`A` to switch, `C` to return), with short inline help per option.
626
+
627
+ ### Fixed
628
+
629
+ - Package smoke runner export wiring was restored for staged payload setup (`validation:package-smoke` / `validation:package-smoke:minimal`).
630
+ - `pumuki remove` now prunes only directories traceable to the Pumuki dependency tree, guaranteeing third-party dependency folders are never removed.
631
+ - `pumuki-pre-push` now fails safe when the branch has no upstream configured, returning `exit 1` with an explicit guidance message instead of silently evaluating `HEAD..HEAD`.
632
+ - Lifecycle git command execution now suppresses expected git stderr in fail-safe paths to avoid noisy output during deterministic tests.
633
+ - Framework menu report actions now resolve runner scripts from both consumer repo root and installed package root, enabling report generation from `npx pumuki-framework` in consumer repositories.
634
+ - Evidence traceability is now attached deterministically at evaluation time:
635
+ - findings include `filePath`/`lines` when traceable from matched facts,
636
+ - evidence v2.1 persists `matchedBy` and `source` for snapshot + compatibility violations,
637
+ - baseline/skills findings no longer collapse to `file: "unknown"` when matching facts are available.
638
+
639
+ ### Refactored
640
+
641
+ - Script-level SRP split for Phase 5 closure/status builders and adapter real-session evaluation/parsing helpers.
642
+
643
+ ## [6.3.5] - 2026-02-10
644
+
645
+ ### Added
646
+
647
+ - Deterministic guardrails for active documentation quality:
648
+ - IDE/provider-agnostic language in active docs.
649
+ - English-only baseline in active docs.
650
+ - Index coverage and markdown-reference integrity checks.
651
+
652
+ ### Changed
653
+
654
+ - Stage-gates suite expanded to include docs quality and package smoke export-contract guardrails.
655
+
656
+ ### Fixed
657
+
658
+ - Package smoke staged payload export contract regression in repo setup helpers.
659
+
660
+ ## Notes
661
+
662
+ - Canonical v2.x release narrative and operational detail live in:
663
+ - `docs/operations/RELEASE_NOTES.md`
664
+ - Historical commit-level trace remains available via:
665
+ - `git log`
666
+ - `git show`