@gregiteen/ssss-cli 0.8.0 → 0.9.1

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 (48) hide show
  1. package/CHANGELOG.md +55 -4
  2. package/README.md +42 -84
  3. package/VERSION +1 -1
  4. package/conformance/README.md +1 -1
  5. package/conformance/fixtures.json +4 -48
  6. package/conformance/reference-bundle.ucw.json +22 -21
  7. package/docs/help/bundle.md +2 -2
  8. package/docs/help/overview.md +9 -6
  9. package/docs/help/semantic.md +5 -4
  10. package/docs/ssss-spec.md +42 -86
  11. package/package.json +22 -3
  12. package/registry/core.json +22 -29
  13. package/scripts/build-reference-bundle.mjs +0 -20
  14. package/scripts/cmd-adapter.mjs +29 -0
  15. package/scripts/cmd-import.mjs +1 -1
  16. package/scripts/cmd-migrate.mjs +26 -0
  17. package/scripts/cmd-new.mjs +5 -5
  18. package/scripts/cmd-primitive.mjs +48 -0
  19. package/scripts/cmd-registry.mjs +25 -0
  20. package/scripts/cmd-semantic.mjs +6 -8
  21. package/scripts/conformance-09.mjs +331 -0
  22. package/scripts/conformance.mjs +153 -186
  23. package/scripts/generate-sbom.mjs +96 -0
  24. package/scripts/phase9-cross-host-corpus.mjs +223 -0
  25. package/scripts/ssss.mjs +8 -2
  26. package/skills/ssss/SKILL.md +32 -208
  27. package/skills/ssss/evals/evals.json +3 -3
  28. package/skills/ssss/references/contract-reference.md +7 -8
  29. package/skills/ssss/scripts/validate-schema.mjs +1 -44
  30. package/src/authorization.mjs +62 -0
  31. package/src/bundle.mjs +41 -5
  32. package/src/engine.mjs +101 -503
  33. package/src/events.mjs +155 -0
  34. package/src/guard.mjs +32 -0
  35. package/src/http.mjs +26 -0
  36. package/src/idempotency.mjs +55 -0
  37. package/src/kernel.mjs +260 -0
  38. package/src/leases.mjs +173 -0
  39. package/src/primitive.mjs +227 -0
  40. package/src/projections.mjs +133 -0
  41. package/src/registry.mjs +190 -39
  42. package/src/semantic.mjs +124 -316
  43. package/src/ui.mjs +100 -0
  44. package/src/validator.mjs +87 -0
  45. package/src/vfs.mjs +203 -0
  46. package/types/kernel.d.ts +48 -0
  47. package/docs/help/localization.md +0 -43
  48. package/scripts/cmd-localize.mjs +0 -44
package/CHANGELOG.md CHANGED
@@ -7,6 +7,57 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [0.9.1] - 2026-09-24
11
+ ### Fixed
12
+ - `JsonlEventStore.append` no longer re-reads and re-parses the whole
13
+ `<workspace>.jsonl` log on every append to reject a duplicate `event_id`.
14
+ Each store instance reads a log once on its first append, keeps a set of the
15
+ event ids it has seen, and re-reads only when the log's stat (size, mtime,
16
+ ctime, inode) shows another instance or process has changed it. A batch of N
17
+ appends is now one log read instead of N. Replaying 3,250 appends in fresh
18
+ instances of 400 against a 7,915-event, 9.6 MB log dropped from ~280 s to
19
+ ~1.7 s. Duplicate rejection, symlink refusal (now also enforced with
20
+ `O_NOFOLLOW` where the platform has it), 0600 log mode, and replay order are
21
+ unchanged.
22
+ - `MemoryEventStore.append` checks for duplicates against a set of ids instead
23
+ of scanning every stored event.
24
+ - The SBOM generator derives the package tarball URL from `package.json`
25
+ instead of a hardcoded 0.9.0 URL.
26
+
27
+ ### Added
28
+ - 0.9 conformance checks for the JSONL event store: duplicates rejected from
29
+ the same instance, another instance, and another process; one log read for
30
+ 200 appends; rebuild after a foreign append; replay order and cursor resume;
31
+ 0600 mode; symlink refusal.
32
+
33
+ ## [0.9.0] - 2026-07-10
34
+ ### Added
35
+ - Shared application kernel (`kernel.execute`) with verified-principal injection,
36
+ canonical request hashing, idempotent replay/conflict, resource prepare/finalize/
37
+ reconcile hooks, and TypeScript command contracts under `@gregiteen/ssss-cli/kernel`.
38
+ - Host adapter contracts and dual reference implementations for VFS, identity/
39
+ capability authorization, leases, idempotency, events, projections, semantic
40
+ retrieval/rendering, and generative UI manifests.
41
+ - Runtime primitive authoring (`ssss:primitive` meta-schema), layered registry
42
+ composition, aliases, dependency ranges, policy floors, and registry integrity locks.
43
+ - CLI surfaces: `ssss primitive`, `ssss registry`, `ssss adapter conformance`, and
44
+ `ssss migrate 0.8-to-0.9` dry-run diagnostics with backup manifests.
45
+ - Bundle `manifest.dependencies` for primitives, extensions, migrations, and
46
+ integrity digests aligned with provenance.
47
+ - Dedicated 0.9 conformance suite covering adapters, kernel leases, projection
48
+ rebuild/drift isolation, UI adversarial cases, and CLI smoke paths.
49
+
50
+ ### Changed
51
+ - Core registry/spec version is now `0.9`. Canonical documents are authored once;
52
+ multilingual presentation uses embedding/render adapters instead of stored
53
+ translation trees.
54
+ - The reference engine is a compatibility façade over the shared kernel; hosts must
55
+ inject adapters rather than re-implement mutation stages.
56
+
57
+ ### Removed
58
+ - The `translation` document primitive and required localized-vault materialization
59
+ workflow from the 0.9 core surface.
60
+
10
61
  ## [0.8.0] - 2026-07-10
11
62
  ### Changed
12
63
  - Core registry/spec version is now `0.7`. Registry `patterns`,
@@ -128,14 +179,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
128
179
  - **The `.ucw` bundle format (spec §16, registry `bundle`)** — the canonical transportable
129
180
  package of a vault: a manifest plus path-sorted files, content-hashed for integrity. The
130
181
  manifest declares `ssss_core_version`, `required_extensions`, `export_profile`,
131
- `primitive_inventory` (registry-driven, replacing ultrachat's closed `categories` enum),
182
+ `primitive_inventory` (registry-driven, replacing the legacy closed `categories` enum),
132
183
  `provisioning[]`, `parameters[]`, and `provenance{content_hash, exporter, signature?}`.
133
- Harvested from ultrachat's `WorkspaceVfsPackageService` and generalized to be portability-
184
+ Harvested from the legacy `WorkspaceVfsPackageService` and generalized to be portability-
134
185
  and registry-driven.
135
186
  - **The provisioning contract (spec §17, registry `provisioning`)** — three deterministic,
136
187
  idempotent verbs: `export` (pure, profile-filtered), `provision` (params + link-integrity
137
188
  + id-remap → replayable envelope plan), `import` (engine replay, idempotent via
138
- idempotency_key). Adopts ultrachat's `WorkspaceProvisioningStep.mode`/`system` and
189
+ idempotency_key). Adopts the legacy `WorkspaceProvisioningStep.mode`/`system` and
139
190
  `WorkspaceGraphEdge.relation` as the canonical binding/dependency vocabularies, plus
140
191
  `installMode` composition and structural-only `migration`+`patch` upgrades.
141
192
  - **Reference engine for bundles (`src/bundle.mjs`)** — dependency-free `exportBundle`,
@@ -166,7 +217,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
166
217
  real resource bound at provision). Export profiles `backup | template | sale` are filters
167
218
  over these classes; `template`/`sale` exports MUST drop all `tenant_private` primitives.
168
219
  Files MAY override their type default with `x_portability`. Lifted and generalized from
169
- ultrachat's ad-hoc export filter in `WorkspaceVfsPackageService`.
220
+ the legacy ad-hoc export filter in `WorkspaceVfsPackageService`.
170
221
  - **`delete` envelope (spec §6.2)** — promoted from festech's `SsssOperationService` into
171
222
  the canonical Operation Contract as the fourth envelope type. Removes a replace-type file,
172
223
  rejects append-type targets, and emits a deletion event for audit. Idempotent.
package/README.md CHANGED
@@ -1,31 +1,22 @@
1
1
  # SSSS — Structured Semantic Syntax System
2
2
 
3
3
  > A database-free, Markdown-first schema and mutation contract for AI-agent state.
4
- > Turn a running business into a single tradeable file — *a festival in a box.*
4
+ > Turn an autonomous agent ecosystem into a single portable, tradeable bundle.
5
5
 
6
6
  [![conformance](https://img.shields.io/badge/conformance-fixtures%20%2B%20runtime%20%2B%20bundle-brightgreen)](conformance/)
7
- [![spec](https://img.shields.io/badge/spec-v0.7%20draft-blue)](docs/ssss-spec.md)
7
+ [![spec](https://img.shields.io/badge/spec-v0.9-blue)](docs/ssss-spec.md)
8
8
  [![OKF](https://img.shields.io/badge/OKF-v0.1%20compatible-blue)](docs/ssss-spec.md)
9
9
 
10
- SSSS is the vendor-neutral standard and reference implementation shared by
11
- [festech.live](https://festech.live), **ultrachat**, and **total-recall**. It defines:
12
-
13
- - **Document primitives** — typed Markdown files with YAML frontmatter (`workflow`,
14
- `rule`, `page`, `assistant`, …), validated against a registry, not hand-written code.
15
- - **The Operation Contract** (§6) — four envelope types (`operation` / `patch` /
16
- `event` / `delete`) for mutating a vault, with idempotency replay and audit.
17
- - **The Workflow Runtime Contract** (§11.8) — workflows own triggers; daemons,
18
- crons, and webhooks derive idempotent event/task/run envelopes from the vault.
19
- - **Semantic projection and localization** (§11.9) — deterministic graph/search
20
- records and hash-bound translation overlays, with private data excluded by default.
21
- - **Portability classification** (§5.5) — the keystone: every primitive is
22
- `structural`, `tenant_private`, or `resource_bound`, so a vault can be *sold*
23
- without leaking the operator's private data.
24
- - **The `.ucw` bundle format** (§16) and **provisioning contract** (§17) — package a
25
- vault, then `export → provision → import` it into a fresh tenant, deterministically.
26
-
27
- This package, `@gregiteen/ssss-cli`, is **dependency-free**: a host needs neither Zod nor a YAML
28
- library to be conformant. The reference engine *is* the validator.
10
+ SSSS is a vendor-neutral standard and reference implementation for portable AI memory and state. It defines:
11
+
12
+ - **Document primitives** — typed Markdown files with YAML frontmatter (`workflow`, `rule`, `page`, `assistant`, …), validated against a registry, not hand-written code.
13
+ - **The Operation Contract** (§6) — four envelope types (`operation` / `patch` / `event` / `delete`) for mutating a vault, with idempotency replay and audit.
14
+ - **The Workflow Runtime Contract** (§11.8) — workflows own triggers; daemons, crons, and webhooks derive idempotent event/task/run envelopes from the vault.
15
+ - **Multilingual semantic runtime** (§11.9) — deterministic lexical evidence, injected multilingual embeddings, and runtime rendering with symbolic controls fixed.
16
+ - **Portability classification** (§5.5) — the keystone: every primitive is `structural`, `tenant_private`, or `resource_bound`, so a vault can be *sold* or *shared* without leaking private data.
17
+ - **The `.ucw` bundle format** (§16) and **provisioning contract** (§17) — package a vault, then `export → provision → import` it into a fresh environment, deterministically.
18
+
19
+ This package, `@gregiteen/ssss-cli`, is **dependency-free**: a host needs neither Zod nor a YAML library to be conformant. The reference engine *is* the validator.
29
20
 
30
21
  ## Install
31
22
 
@@ -41,10 +32,9 @@ Requires Node 18+. No runtime dependencies.
41
32
 
42
33
  ```bash
43
34
  ssss new my-app --install # scaffold + install + run the conformance test
44
- ssss new my-app --with-total-recall # also wire the Total Recall memory OS
45
35
  ```
46
36
 
47
- Scaffolds a starter `vault/`, a dependency-free conformance test, and a `CLAUDE.md`.
37
+ Scaffolds a starter `vault/`, a dependency-free conformance test, and instructions.
48
38
  See `ssss help scaffold`.
49
39
 
50
40
  ## Quick start — the lifecycle
@@ -56,83 +46,53 @@ vault ──export──▶ .ucw bundle ──provision──▶ envelope plan
56
46
 
57
47
  ```bash
58
48
  # 1. Package a vault as a sellable bundle (drops tenant-private data)
59
- ssss export ./my-vault --profile sale --out festival.ucw.json
49
+ ssss export ./my-vault --profile sale --out bundle.ucw.json
60
50
 
61
51
  # 2. Inspect / verify it
62
- ssss inspect festival.ucw.json --files
63
- ssss validate festival.ucw.json
52
+ ssss inspect bundle.ucw.json --files
53
+ ssss validate bundle.ucw.json
64
54
 
65
55
  # 3. Stand up a fresh tenant from it
66
- ssss import festival.ucw.json --vault ./new-tenant \
67
- --param business_name="Acme Fest" --param domain=acme.live
56
+ ssss import bundle.ucw.json --vault ./new-tenant \
57
+ --param company_name="Acme Corp" --param domain=acme.com
68
58
 
69
59
  # Re-running import commits nothing — it is idempotent.
70
60
  ```
71
61
 
62
+ ## 0.9 application kernel
63
+
64
+ SSSS 0.9 provides a shared mutation kernel and host adapter contracts for any system using SSSS:
65
+
66
+ ```bash
67
+ ssss primitive create --namespace acme --name "New Item" --language en
68
+ ssss registry compose --extension ./acme-extension.json
69
+ ssss adapter conformance
70
+ ssss migrate 0.8-to-0.9 ./vault
71
+ ```
72
+
73
+ Library subpaths: `@gregiteen/ssss-cli/kernel`, `/vfs`, `/identity`, `/leases`, `/events`, `/projections`, `/semantic`, `/ui`.
74
+
72
75
  ## Commands
73
76
 
74
77
  | Command | Purpose |
75
78
  |---------|---------|
76
- | `ssss new <dir>` | Scaffold a new SSSS project (`--with-total-recall`, `--install`). |
79
+ | `ssss new <dir>` | Scaffold a new SSSS project (`--install`). |
80
+ | `ssss primitive <verb>` | Create, validate, inspect, or migrate primitive definitions. |
81
+ | `ssss registry <verb>` | Compose, lock, or verify an effective registry. |
82
+ | `ssss adapter conformance` | Run machine-readable VFS/lease/idempotency contract suites. |
83
+ | `ssss migrate 0.8-to-0.9` | Dry-run migration diagnostics with backup manifest. |
77
84
  | `ssss export <vault>` | Package a vault into a `.ucw` bundle (§16). Pure & deterministic. |
78
85
  | `ssss validate <bundle>` | Check a bundle against the schema + portability rules. |
79
86
  | `ssss inspect <bundle>` | Human-readable summary (manifest, inventory, params, steps). |
80
87
  | `ssss provision <bundle>` | Plan an install: params + link integrity → envelopes (§17). |
81
88
  | `ssss import <bundle>` | Replay a bundle/plan into a vault via the engine (idempotent). |
82
89
  | `ssss semantic <vault>` | Build or query a deterministic, privacy-safe semantic index (§11.9). |
83
- | `ssss localize <vault>` | Materialize approved translations as a derived projection outside the vault. |
84
90
  | `ssss autolink [dir]` | Generate OKF wiki-links across a vault. |
85
91
  | `ssss conformance` | Run the canonical conformance suite (§12). |
86
92
  | `ssss help [topic]` | Local docs: `runtime`, `portability`, `bundle`, `provisioning`, `leases`, … |
87
93
 
88
94
  Run `ssss <command> --help` for flags, or `ssss help <topic>` for concepts.
89
95
 
90
- ## Use as a library
91
-
92
- ```js
93
- import { createEngine } from '@gregiteen/ssss-cli/engine';
94
- import { exportBundle, validateBundle, provisionBundle, importBundle } from '@gregiteen/ssss-cli/bundle';
95
- import { planWorkflowTrigger } from '@gregiteen/ssss-cli/runtime';
96
- import { buildSemanticIndex, searchSemanticIndex, materializeLocale } from '@gregiteen/ssss-cli/semantic';
97
-
98
- const bundle = exportBundle('./my-vault', { profile: 'sale', name: 'Festival in a Box' });
99
- const { valid, errors } = validateBundle(bundle);
100
-
101
- const engine = createEngine();
102
- const plan = provisionBundle(bundle, { parameters: { domain: 'acme.live' }, workspaceId: 'ws-1' });
103
- importBundle(plan.plan, './new-tenant', engine);
104
-
105
- const workflowContent = `---
106
- type: workflow
107
- name: "Daily Digest"
108
- ---
109
-
110
- 1. Gather messages.
111
- 2. Summarize.
112
- 3. Send digest.
113
- `;
114
- const runtimePlan = planWorkflowTrigger({
115
- workflowPath: 'workflows/daily-digest/WORKFLOW.md',
116
- workflowContent,
117
- workspaceId: 'ws-1',
118
- trigger: { type: 'cron', id: 'daily-0800', cron: '0 8 * * *' },
119
- scheduledFor: '2026-07-02T14:00:00.000Z',
120
- });
121
-
122
- const index = buildSemanticIndex('./my-vault', { locale: 'es' });
123
- const matches = searchSemanticIndex(index, 'política de reembolsos');
124
- materializeLocale('./my-vault', 'es', './derived/es');
125
- ```
126
-
127
- Exports: `@gregiteen/ssss-cli` / `@gregiteen/ssss-cli/engine` (Operation Contract engine),
128
- `@gregiteen/ssss-cli/bundle` (export/provision/import), `@gregiteen/ssss-cli/registry`,
129
- `@gregiteen/ssss-cli/runtime`, `@gregiteen/ssss-cli/semantic`,
130
- `@gregiteen/ssss-cli/frontmatter`.
131
-
132
- Translations are structural overlay documents that target an exact source hash. Only
133
- `title`, `description`, and body are translated; types, ids, permissions, enums,
134
- relations, and other control fields remain sourced from the canonical document.
135
-
136
96
  ## Portability — why a vault is safe to sell
137
97
 
138
98
  | Class | Meaning | In a `sale` export? |
@@ -141,13 +101,11 @@ relations, and other control fields remain sourced from the canonical document.
141
101
  | `resource_bound` | Needs a real resource bound at provision (`domain`, `phone_number`). | ✅ shipped (as a parameter/step) |
142
102
  | `tenant_private` | The operator's private data (`task`, customer records). | ❌ **dropped** |
143
103
 
144
- `template` and `sale` exports MUST drop every `tenant_private` file. The reference
145
- bundle proves it — see `ssss help portability`.
104
+ `template` and `sale` exports MUST drop every `tenant_private` file. The reference bundle proves it — see `ssss help portability`.
146
105
 
147
106
  ## Conformance
148
107
 
149
- A host MUST NOT claim SSSS conformance without passing the suite in
150
- [`conformance/`](conformance/):
108
+ A host MUST NOT claim SSSS conformance without passing the suite in `conformance/`:
151
109
 
152
110
  ```bash
153
111
  ssss conformance # structural + registry validation
@@ -158,13 +116,13 @@ npm test # == ssss conformance --engine
158
116
  ## Repository layout
159
117
 
160
118
  ```
161
- docs/ssss-spec.md The normative specification (v0.7 draft).
119
+ docs/ssss-spec.md The normative specification (v0.9).
162
120
  docs/help/ Topic docs surfaced by `ssss help`.
163
121
  registry/core.json 15 document + 5 contract primitives; semantic, bundle & provisioning schemas.
164
- registry/extensions/ Application extension registries (e.g. festech).
122
+ registry/extensions/ Application extension registries.
165
123
  src/engine.mjs Operation Contract engine (§6).
166
124
  src/runtime.mjs Workflow trigger → event/task/run envelope planning (§11.8).
167
- src/semantic.mjs Deterministic semantic index + localization projection (§11.9).
125
+ src/semantic.mjs Multilingual semantic retrieval + runtime rendering (§11.9).
168
126
  src/bundle.mjs export / validate / provision / import (§16–§17).
169
127
  src/registry.mjs Registry-driven type + portability resolution.
170
128
  src/frontmatter.mjs Zero-dependency YAML frontmatter.
@@ -175,4 +133,4 @@ skills/ssss/ Packaged SSSS system skill and dependency-free valida
175
133
 
176
134
  ## License
177
135
 
178
- ISC © Greg Iteen. See [LICENSE](LICENSE).
136
+ ISC © Greg Iteen. See [LICENSE](./LICENSE).
package/VERSION CHANGED
@@ -1 +1 @@
1
- 0.8.0
1
+ 0.9.1
@@ -33,7 +33,7 @@ The runner validates that the fixture file is well-formed and that every
33
33
  `expected_response` is internally consistent with the envelope rules. With
34
34
  `--engine`, it replays every fixture through the reference engine (`src/engine.mjs`),
35
35
  checks workflow runtime planning (`src/runtime.mjs`, spec §11.8), extension-registry
36
- collision/schema/symlink safety, semantic search and localization (`src/semantic.mjs`,
36
+ collision/schema/symlink safety and multilingual semantic retrieval/rendering (`src/semantic.mjs`,
37
37
  §11.9), runs regression coverage for patch serialization and leases (§6/§7), and
38
38
  round-trips the
39
39
  reference bundle (validate → provision → import → re-import, spec §16/§17)
@@ -747,66 +747,22 @@
747
747
  },
748
748
  {
749
749
  "id": "fixture-024",
750
- "name": "Translation source — valid structural rule",
751
- "description": "Creates the exact structural source used by the translation overlay fixtures.",
750
+ "name": "Multilingual source — valid Spanish structural rule",
751
+ "description": "Natural-language fields may be authored in any language while symbolic controls remain stable.",
752
752
  "request": {
753
753
  "type": "operation",
754
754
  "idempotency_key": "35353535-3535-3535-3535-353535353535",
755
755
  "path": "rules/translatable-refund-rule.md",
756
756
  "workspace_id": "TEST_WORKSPACE_ID",
757
757
  "actor": { "role": "system" },
758
- "content": "---\ntype: rule\ntitle: \"Translatable Refund Rule\"\ndescription: \"Structural source used by the translation conformance fixture.\"\ntimestamp: \"2026-07-10T00:00:00Z\"\nname: \"Translatable Refund Rule\"\n---\nRefunds are available before the deadline.",
759
- "intent": "Conformance fixture: create a structural translation source"
758
+ "content": "---\ntype: rule\ntitle: \"Política de reembolsos\"\ndescription: \"Explica cuándo están disponibles los reembolsos.\"\ntimestamp: \"2026-07-10T00:00:00Z\"\nname: refund-policy\nlanguage: es\n---\nLos reembolsos están disponibles antes de la fecha límite.",
759
+ "intent": "Conformance fixture: create a non-English structural source"
760
760
  },
761
761
  "expected_response": {
762
762
  "success": true,
763
763
  "type": "operation",
764
764
  "validation": { "valid": true, "type": "rule", "errors": [] }
765
765
  }
766
- },
767
- {
768
- "id": "fixture-025",
769
- "name": "Translation overlay — valid hash-bound Spanish projection",
770
- "description": "A translation overlay with a safe source path, exact source hash, valid locale, and approved translatable fields must validate.",
771
- "preconditions": ["fixture-024 must be committed first"],
772
- "request": {
773
- "type": "operation",
774
- "idempotency_key": "36363636-3636-3636-3636-363636363636",
775
- "path": "translations/es/rules/translatable-refund-rule.md",
776
- "workspace_id": "TEST_WORKSPACE_ID",
777
- "actor": { "role": "system" },
778
- "content": "---\ntype: translation\ntitle: \"Spanish Refund Rule Translation\"\ndescription: \"Approved Spanish translation overlay conformance fixture.\"\ntimestamp: \"2026-07-10T00:00:00Z\"\ntranslation_id: translatable-refund-rule-es\nsource_path: rules/translatable-refund-rule.md\nsource_hash: sha256:bc61f36adc3aa1fa2c4da7a48841cb16bc56df0ec052f70d4ee8514a98dc6e62\nlocale: es\nstatus: approved\ntranslated_fields: [title, body]\ntranslated_title: Regla de reembolsos traducible\n---\nLos reembolsos están disponibles antes de la fecha límite.",
779
- "intent": "Conformance fixture: valid translation primitive"
780
- },
781
- "expected_response": {
782
- "success": true,
783
- "type": "operation",
784
- "validation": { "valid": true, "type": "translation", "errors": [] }
785
- }
786
- },
787
- {
788
- "id": "fixture-026",
789
- "name": "Translation overlay — invalid locale is denied",
790
- "description": "Registry pattern enforcement rejects non-BCP47 locale syntax before an invalid overlay can enter the vault.",
791
- "preconditions": ["fixture-024 must be committed first"],
792
- "request": {
793
- "type": "operation",
794
- "idempotency_key": "37373737-3737-3737-3737-373737373737",
795
- "path": "translations/invalid/rules/translatable-refund-rule.md",
796
- "workspace_id": "TEST_WORKSPACE_ID",
797
- "actor": { "role": "system" },
798
- "content": "---\ntype: translation\ntitle: \"Invalid Locale Translation\"\ndescription: \"Translation fixture that must be rejected.\"\ntimestamp: \"2026-07-10T00:00:00Z\"\ntranslation_id: invalid-locale-translation\nsource_path: rules/translatable-refund-rule.md\nsource_hash: sha256:bc61f36adc3aa1fa2c4da7a48841cb16bc56df0ec052f70d4ee8514a98dc6e62\nlocale: not_a_locale\nstatus: approved\ntranslated_fields: [title]\ntranslated_title: Invalid\n---\nInvalid.",
799
- "intent": "Conformance fixture: invalid translation locale"
800
- },
801
- "expected_response": {
802
- "success": false,
803
- "validation": {
804
- "valid": false,
805
- "type": "translation",
806
- "errors": ["Invalid format for field 'locale' on type 'translation'."]
807
- }
808
- },
809
- "expected_http_status": 422
810
766
  }
811
767
  ],
812
768
  "error_codes": {
@@ -4,7 +4,7 @@
4
4
  "description": "A complete music-festival operation as a tradeable SSSS bundle.",
5
5
  "version": "1.0.0",
6
6
  "exported_at": "1970-01-01T00:00:00.000Z",
7
- "ssss_core_version": "0.7",
7
+ "ssss_core_version": "0.9",
8
8
  "required_extensions": [
9
9
  "festech"
10
10
  ],
@@ -15,9 +15,26 @@
15
15
  "page": 1,
16
16
  "security_role": 1,
17
17
  "rule": 1,
18
- "translation": 1,
19
18
  "workflow": 1
20
19
  },
20
+ "dependencies": {
21
+ "primitives": [
22
+ "assistant",
23
+ "domain",
24
+ "page",
25
+ "rule",
26
+ "security_role",
27
+ "workflow"
28
+ ],
29
+ "extensions": [
30
+ "festech"
31
+ ],
32
+ "migrations": [],
33
+ "integrity": {
34
+ "content_hash": "sha256:7febd673938a3dc04c068e0bf08097a9783c09e612606d2df9a4db8dcb8907f5",
35
+ "ssss_core_version": "0.9"
36
+ }
37
+ },
21
38
  "provisioning": [
22
39
  {
23
40
  "id": "ws",
@@ -86,10 +103,10 @@
86
103
  "description": "Satisfies the domain resource requirement field 'registrar'."
87
104
  }
88
105
  ],
89
- "file_count": 18,
106
+ "file_count": 14,
90
107
  "provenance": {
91
- "content_hash": "sha256:27c7c21826552f73dd14a56018454f4c19bda002029d5db42ecb14d77667b699",
92
- "exporter": "@gregiteen/ssss-cli@0.8.0"
108
+ "content_hash": "sha256:7febd673938a3dc04c068e0bf08097a9783c09e612606d2df9a4db8dcb8907f5",
109
+ "exporter": "@gregiteen/ssss-cli@0.9.1"
93
110
  }
94
111
  },
95
112
  "files": [
@@ -141,22 +158,6 @@
141
158
  "path": "tasks/index.md",
142
159
  "content": "# Index — tasks\n\n- [Ticket 4821 Seat Change](./ticket-4821.md)\n"
143
160
  },
144
- {
145
- "path": "translations/es/index.md",
146
- "content": "# Index — translations/es\n\n- [rules/](./rules/index.md)\n"
147
- },
148
- {
149
- "path": "translations/es/rules/index.md",
150
- "content": "# Index — translations/es/rules\n\n- [Spanish Refund Policy Translation](./refund-policy.md)\n"
151
- },
152
- {
153
- "path": "translations/es/rules/refund-policy.md",
154
- "content": "---\ntype: translation\ntitle: Spanish Refund Policy Translation\ndescription: Approved Spanish presentation overlay for the festival refund policy.\ntimestamp: 2026-07-10T00:00:00Z\ntranslation_id: refund-policy-es\nsource_path: rules/refund-policy.md\nsource_hash: sha256:a5f97ef9e2cc143d397f87a96c7fc20f4a3cd0515835c2ab659c9ac6db0d07e3\nlocale: es\nstatus: approved\ntranslated_fields: [title, description, body]\ntranslated_title: Política de reembolsos\ntranslated_description: Explica cuándo están disponibles los reembolsos para asistentes.\n---\nLos reembolsos están disponibles hasta catorce días antes del evento."
155
- },
156
- {
157
- "path": "translations/index.md",
158
- "content": "# Index — translations\n\n- [es/](./es/index.md)\n"
159
- },
160
161
  {
161
162
  "path": "workflows/box-office.md",
162
163
  "content": "---\ntype: workflow\ntitle: Box Office\ndescription: Ticket-sales workflow for a music festival.\ntimestamp: 2026-07-02T00:00:00Z\nname: Box Office\nslug: box-office\n---\nSell tickets, then hand the buyer to [[concierge]] for questions."
@@ -37,8 +37,8 @@ be silently edited. `primitive_inventory` is registry-driven (a count per `type`
37
37
  not a closed category enum.
38
38
 
39
39
  Bundle validation also applies registry patterns and document-reference rules.
40
- For example, a `translation` entry must name an included structural source and
41
- its `source_hash` must match that source's exact bytes.
40
+ Primitive, extension, and migration dependencies must resolve against the effective
41
+ registry before any file is committed.
42
42
 
43
43
  ## Parameters
44
44
 
@@ -5,7 +5,7 @@ and mutation contract for AI-agent state. A vault is a directory of Markdown fil
5
5
  with YAML frontmatter; every file declares a `type` defined in the registry.
6
6
 
7
7
  `@gregiteen/ssss-cli` is the reference implementation: a dependency-free Operation Contract
8
- engine, a registry-driven validator, semantic/localization projections, and the
8
+ kernel, a registry-driven validator, multilingual semantic adapters, and the
9
9
  `.ucw` bundle/provisioning tooling.
10
10
 
11
11
  ## The pieces
@@ -13,10 +13,12 @@ engine, a registry-driven validator, semantic/localization projections, and the
13
13
  | Piece | Where | What it is |
14
14
  |-------|-------|------------|
15
15
  | Spec | `docs/ssss-spec.md` | The normative standard. |
16
- | Core registry | `registry/core.json` | The 15 document primitives + 5 contract primitives, plus semantic (§11.9), bundle (§16), and provisioning (§17) contracts. |
17
- | Engine | `src/engine.mjs` | The §6 Operation Contract pipeline (operation/patch/event/delete). |
16
+ | Core registry | `registry/core.json` | Document primitives + contracts for semantic (§11.9), bundle (§16), and provisioning (§17). |
17
+ | Kernel | `src/kernel.mjs` | Shared 0.9 mutation authority (`kernel.execute`) used by hosts and the reference engine. |
18
+ | Engine | `src/engine.mjs` | Compatibility façade over the kernel for the §6 Operation Contract. |
18
19
  | Runtime | `src/runtime.mjs` | The §11.8 workflow trigger → event/task/run envelope planner. |
19
- | Semantic | `src/semantic.mjs` | Deterministic semantic graph/search projection and translation overlays (§11.9). |
20
+ | Semantic | `src/semantic.mjs` | Lexical evidence, multilingual embeddings, privacy filters, and runtime rendering (§11.9). |
21
+ | Adapters | `src/vfs.mjs`, `leases.mjs`, `events.mjs`, … | Host-injectable storage/security/projection contracts. |
20
22
  | Bundle | `src/bundle.mjs` | export / validate / provision / import (§16–§17). |
21
23
  | Conformance | `conformance/` | Fixtures every host must pass. |
22
24
 
@@ -30,8 +32,9 @@ vault ──export──▶ .ucw bundle ──provision──▶ envelope plan
30
32
  ## Commands
31
33
 
32
34
  Run `ssss help <topic>` for any of:
33
- `runtime`, `semantic`, `localization`, `portability`, `bundle`, `provisioning`,
35
+ `runtime`, `semantic`, `portability`, `bundle`, `provisioning`,
34
36
  `export`, `provision`, `import`, `conformance`, `autolink`.
35
37
 
36
38
  Run `ssss <command> --help` for: `export`, `validate`, `inspect`, `provision`,
37
- `import`, `semantic`, `localize`, `autolink`, `conformance`.
39
+ `import`, `semantic`, `primitive`, `registry`, `adapter`, `migrate`,
40
+ `autolink`, `conformance`.
@@ -6,8 +6,8 @@ Markdown. The projection is disposable: the vault remains the only source of tru
6
6
  ```bash
7
7
  ssss semantic ./vault
8
8
  ssss semantic ./vault --query "refund policy" --limit 5
9
- ssss semantic ./vault --locale es --query "política de reembolsos"
10
- ssss semantic ./vault --locale es --out ./derived/semantic-es.json
9
+ ssss semantic ./vault --query "política de reembolsos"
10
+ ssss semantic ./vault --out ./derived/semantic.json
11
11
  ```
12
12
 
13
13
  Records include stable identity, source path and hash, type, portability, surface
@@ -30,8 +30,9 @@ Symlinked vault entries and unsafe paths fail closed.
30
30
  ```js
31
31
  import { buildSemanticIndex, searchSemanticIndex } from '@gregiteen/ssss-cli/semantic';
32
32
 
33
- const index = buildSemanticIndex('./vault', { locale: 'es' });
33
+ const index = buildSemanticIndex('./vault');
34
34
  const results = searchSemanticIndex(index, 'reembolsos', { limit: 10 });
35
35
  ```
36
36
 
37
- See also: `ssss help localization`.
37
+ Hosts may inject a multilingual embedding adapter and runtime renderer. Presentation
38
+ may change language and formatting, but never symbolic controls or authorization.