@cleocode/core 2026.6.8 → 2026.6.10

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 (41) hide show
  1. package/dist/docs/display-alias.d.ts +97 -0
  2. package/dist/docs/display-alias.d.ts.map +1 -0
  3. package/dist/docs/display-alias.js +136 -0
  4. package/dist/docs/display-alias.js.map +1 -0
  5. package/dist/docs/docs-read-model.d.ts +7 -0
  6. package/dist/docs/docs-read-model.d.ts.map +1 -1
  7. package/dist/docs/docs-read-model.js +11 -2
  8. package/dist/docs/docs-read-model.js.map +1 -1
  9. package/dist/docs/export-document.js +259 -131
  10. package/dist/docs/export-document.js.map +2 -2
  11. package/dist/docs/index.d.ts +2 -0
  12. package/dist/docs/index.d.ts.map +1 -1
  13. package/dist/docs/index.js +1 -0
  14. package/dist/docs/index.js.map +1 -1
  15. package/dist/docs/numbering.d.ts +29 -0
  16. package/dist/docs/numbering.d.ts.map +1 -1
  17. package/dist/docs/numbering.js +41 -0
  18. package/dist/docs/numbering.js.map +1 -1
  19. package/dist/internal.d.ts +3 -1
  20. package/dist/internal.d.ts.map +1 -1
  21. package/dist/internal.js +2 -1
  22. package/dist/internal.js.map +1 -1
  23. package/dist/llm/plugin-facade.js +372 -243
  24. package/dist/llm/plugin-facade.js.map +2 -2
  25. package/dist/store/attachment-store.d.ts +5 -0
  26. package/dist/store/attachment-store.d.ts.map +1 -1
  27. package/dist/store/attachment-store.js +7 -1
  28. package/dist/store/attachment-store.js.map +1 -1
  29. package/dist/store/dual-scope-db.d.ts.map +1 -1
  30. package/dist/store/dual-scope-db.js +15 -0
  31. package/dist/store/dual-scope-db.js.map +1 -1
  32. package/dist/store/migration-manager.d.ts +99 -0
  33. package/dist/store/migration-manager.d.ts.map +1 -1
  34. package/dist/store/migration-manager.js +323 -23
  35. package/dist/store/migration-manager.js.map +1 -1
  36. package/dist/store/schema/attachments.d.ts +16 -0
  37. package/dist/store/schema/attachments.d.ts.map +1 -1
  38. package/dist/store/schema/attachments.js +30 -0
  39. package/dist/store/schema/attachments.js.map +1 -1
  40. package/migrations/drizzle-tasks/20260606000001_t11875-attachments-display-alias/migration.sql +46 -0
  41. package/package.json +12 -12
@@ -168,10 +168,40 @@ export const attachments = sqliteTable('attachments', {
168
168
  * @task T11181 (Epic T10518 / Saga T10516)
169
169
  */
170
170
  docVersion: integer('doc_version').notNull().default(1),
171
+ /**
172
+ * Optional explicit display-alias NUMBER for the doc, DECOUPLED from the
173
+ * slug string.
174
+ *
175
+ * Background (T11875 · ADR reconcile T11676): under the ratified
176
+ * slug-primary model the kebab `slug` is the canonical handle and the
177
+ * displayed number (e.g. ADR "051") is a DISPLAY ALIAS only. Previously
178
+ * that number was DERIVED by parsing the digits out of the slug
179
+ * (`adr-051-*` → 051), so three distinct ADRs that all slug as `adr-051-*`
180
+ * collided on the rendered number with no way to disambiguate.
181
+ *
182
+ * When non-null, this column is the authoritative display number and is
183
+ * PREFERRED over the slug-derived number by
184
+ * {@link import('../../docs/numbering.js').resolveDisplayNumber}. When null,
185
+ * rendering falls back to the slug-derived number unchanged — so docs that
186
+ * never had an alias assigned keep their historical behaviour.
187
+ *
188
+ * Uniqueness among `type='adr'` docs is enforced at the dispatch layer (not
189
+ * via a SQL UNIQUE constraint) by
190
+ * {@link import('../../docs/display-alias.js').setDisplayAlias}, mirroring
191
+ * the dispatch-validated discipline used for `lifecycle_status` /
192
+ * `relation` so future taxonomy changes never require a schema migration.
193
+ *
194
+ * @task T11875 (Epic T11781 / Saga T11778)
195
+ */
196
+ displayAlias: integer('display_alias'),
171
197
  }, (table) => [
172
198
  index('idx_attachments_sha256').on(table.sha256),
173
199
  index('idx_attachments_lifecycle_status').on(table.lifecycleStatus),
174
200
  index('idx_attachments_supersedes').on(table.supersedes),
201
+ // Speeds the per-type uniqueness scan in `setDisplayAlias` (T11875). Not a
202
+ // UNIQUE index — uniqueness is scoped to `type='adr'` and enforced at the
203
+ // dispatch layer so non-adr kinds may reuse numbers freely.
204
+ index('idx_attachments_display_alias').on(table.displayAlias),
175
205
  ]);
176
206
  /**
177
207
  * Ref-counted junction table linking attachments to owner entities.
@@ -1 +1 @@
1
- {"version":3,"file":"attachments.js","sourceRoot":"","sources":["../../../src/store/schema/attachments.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,aAAa,CAAC;AAClC,OAAO,EAEL,KAAK,EACL,OAAO,EACP,UAAU,EACV,WAAW,EACX,IAAI,GACL,MAAM,yBAAyB,CAAC;AAEjC;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,sBAAsB,GAAG;IACpC,MAAM;IACN,aAAa;IACb,SAAS;IACT,UAAU;IACV,UAAU;IACV,SAAS;CACD,CAAC;AAEX;;;;;;;;;;;GAWG;AACH,MAAM,CAAC,MAAM,6BAA6B,GAAG;IAC3C,OAAO;IACP,UAAU;IACV,UAAU;IACV,YAAY;IACZ,UAAU;IACV,YAAY;CACJ,CAAC;AAKX;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,WAAW,GAAG,WAAW,CACpC,aAAa,EACb;IACE,8CAA8C;IAC9C,EAAE,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE;IAC3B,kFAAkF;IAClF,MAAM,EAAE,IAAI,CAAC,QAAQ,CAAC,CAAC,OAAO,EAAE,CAAC,MAAM,EAAE;IACzC,8EAA8E;IAC9E,cAAc,EAAE,IAAI,CAAC,iBAAiB,CAAC,CAAC,OAAO,EAAE;IACjD,oEAAoE;IACpE,SAAS,EAAE,IAAI,CAAC,YAAY,CAAC,CAAC,OAAO,EAAE;IACvC;;;;;OAKG;IACH,QAAQ,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC,OAAO,EAAE,CAAC,OAAO,CAAC,CAAC,CAAC;IACnD;;;;OAIG;IACH,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC;IAClB;;;;OAIG;IACH,IAAI,EAAE,IAAI,CAAC,MAAM,CAAC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KAAK,CAAC,MAAM,CAAC;IAC/C,KAAK,CAAC,6BAA6B,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,QAAQ,CAAC;CACxD,CACF,CAAC"}
@@ -0,0 +1,46 @@
1
+ -- T11875 — give ADR display-aliases real storage DECOUPLED from the slug.
2
+ --
3
+ -- Background (ADR reconcile T11676 · ratified slug-primary model, saga T11778):
4
+ -- Under the slug-primary model the kebab `slug` is the canonical handle and
5
+ -- the displayed number (e.g. ADR "051") is a DISPLAY ALIAS only. Until now
6
+ -- that number was DERIVED by parsing the digits out of the slug string
7
+ -- (`adr-051-*` → 051), so three DISTINCT ADRs that all slug as `adr-051-*`
8
+ -- (override-patterns ≠ programmatic-gate-integrity ≠ worktree-extension)
9
+ -- rendered the same "051" with no way to disambiguate. The collision cannot
10
+ -- be resolved by renumbering a slug (that would break the canonical handle).
11
+ --
12
+ -- This migration adds a real, nullable `display_alias` INTEGER column to
13
+ -- `attachments` so a doc can carry an explicit display number independent of
14
+ -- its slug. `numbering.ts::resolveDisplayNumber` PREFERS the stored alias
15
+ -- when present and falls back to the slug-derived number when null — so docs
16
+ -- that never get an alias keep their historical rendering byte-for-byte.
17
+ --
18
+ -- Uniqueness among `type='adr'` docs is enforced at the DISPATCH layer
19
+ -- (`display-alias.ts::setDisplayAlias`), NOT via a SQL UNIQUE constraint:
20
+ -- the constraint is scoped to one kind, and dispatch-validation matches the
21
+ -- discipline already used for `lifecycle_status` / `docs_wikilinks.relation`
22
+ -- so future taxonomy changes never require another schema migration.
23
+ --
24
+ -- Additive + forward-only: the new column is nullable, so SQLite ALTER TABLE
25
+ -- ADD COLUMN does NOT rewrite the table and existing rows pass through with
26
+ -- NULL (i.e. "no alias — derive from slug"). No data migration of legacy rows
27
+ -- is required; the `cleo docs set-alias` verb populates aliases going forward.
28
+ --
29
+ -- Changes (idempotent — safe to re-run):
30
+ -- 1. ALTER TABLE attachments ADD COLUMN display_alias integer (nullable).
31
+ -- 2. CREATE INDEX idx_attachments_display_alias — speeds the per-type
32
+ -- uniqueness scan performed by setDisplayAlias.
33
+ --
34
+ -- DEPENDS ON: 20260416000000_t796-attachments (creates `attachments`)
35
+ -- SAFE FOR: SQLite 3.35+ (ALTER TABLE ADD COLUMN nullable is atomic)
36
+ --
37
+ -- @task T11875
38
+ -- @epic T11781 (E3-OBSIDIAN-INTEGRATION)
39
+ -- @saga T11778 (SG-DOCS-SSOT-VAULT)
40
+ -- @closes (display-alias half of) T11676 ADR reconcile plan
41
+
42
+ ALTER TABLE `attachments` ADD COLUMN `display_alias` integer;
43
+ --> statement-breakpoint
44
+
45
+ CREATE INDEX IF NOT EXISTS `idx_attachments_display_alias`
46
+ ON `attachments` (`display_alias`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cleocode/core",
3
- "version": "2026.6.8",
3
+ "version": "2026.6.10",
4
4
  "description": "CLEO core business logic kernel — tasks, sessions, memory, orchestration, lifecycle, with bundled SQLite store",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -429,16 +429,16 @@
429
429
  "write-file-atomic": "^7.0.1",
430
430
  "yaml": "^2.8.3",
431
431
  "zod": "^4.3.6",
432
- "@cleocode/adapters": "2026.6.8",
433
- "@cleocode/agents": "2026.6.8",
434
- "@cleocode/caamp": "2026.6.8",
435
- "@cleocode/git-shim": "2026.6.8",
436
- "@cleocode/contracts": "2026.6.8",
437
- "@cleocode/lafs": "2026.6.8",
438
- "@cleocode/paths": "2026.6.8",
439
- "@cleocode/nexus": "2026.6.8",
440
- "@cleocode/worktree": "2026.6.8",
441
- "@cleocode/skills": "2026.6.8"
432
+ "@cleocode/adapters": "2026.6.10",
433
+ "@cleocode/agents": "2026.6.10",
434
+ "@cleocode/contracts": "2026.6.10",
435
+ "@cleocode/git-shim": "2026.6.10",
436
+ "@cleocode/caamp": "2026.6.10",
437
+ "@cleocode/lafs": "2026.6.10",
438
+ "@cleocode/nexus": "2026.6.10",
439
+ "@cleocode/paths": "2026.6.10",
440
+ "@cleocode/skills": "2026.6.10",
441
+ "@cleocode/worktree": "2026.6.10"
442
442
  },
443
443
  "engines": {
444
444
  "node": ">=24.16.0"
@@ -472,7 +472,7 @@
472
472
  },
473
473
  "optionalDependencies": {
474
474
  "llmtxt": "^2026.5.15",
475
- "@cleocode/studio": "^2026.6.8"
475
+ "@cleocode/studio": "^2026.6.10"
476
476
  },
477
477
  "scripts": {
478
478
  "build": "tsc",