@kumwe/studio-protocol 0.1.0-alpha.5 → 0.1.0-rc.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/README.md +59 -4
  2. package/THIRD_PARTY_NOTICES.md +9 -0
  3. package/dist/generated/schema-models.d.ts +1968 -0
  4. package/dist/generated/schema-models.d.ts.map +1 -0
  5. package/dist/generated/schema-models.js +76 -0
  6. package/dist/generated/schema-models.js.map +1 -0
  7. package/dist/guards.d.ts +4 -1
  8. package/dist/guards.d.ts.map +1 -1
  9. package/dist/guards.js +72 -30
  10. package/dist/guards.js.map +1 -1
  11. package/dist/host-failure.d.ts +16 -0
  12. package/dist/host-failure.d.ts.map +1 -0
  13. package/dist/host-failure.js +27 -0
  14. package/dist/host-failure.js.map +1 -0
  15. package/dist/index.d.ts +6 -3
  16. package/dist/index.d.ts.map +1 -1
  17. package/dist/index.js +5 -3
  18. package/dist/index.js.map +1 -1
  19. package/dist/schemas.d.ts +17 -0
  20. package/dist/schemas.d.ts.map +1 -1
  21. package/dist/schemas.js +51 -0
  22. package/dist/schemas.js.map +1 -1
  23. package/dist/types.d.ts +123 -6
  24. package/dist/types.d.ts.map +1 -1
  25. package/dist/types.js +6 -1
  26. package/dist/types.js.map +1 -1
  27. package/package.json +6 -2
  28. package/schemas/authoring-message-catalog.schema.json +45 -0
  29. package/schemas/authoring-web-vector.schema.json +236 -0
  30. package/schemas/binding-projection-vector.schema.json +127 -0
  31. package/schemas/block-definition.schema.json +10 -1
  32. package/schemas/host-sequence-vector.schema.json +342 -0
  33. package/schemas/host-vector.schema.json +2 -0
  34. package/schemas/manifest.json +75 -6
  35. package/schemas/preview-message.schema.json +44 -12
  36. package/schemas/preview-vector.schema.json +52 -0
  37. package/schemas/renderer-web-vector.schema.json +160 -0
  38. package/schemas/rich-text-projection.schema.json +12 -3
  39. package/schemas/rich-text.schema.json +156 -7
  40. package/schemas/schema-profile-vector.schema.json +133 -0
  41. package/schemas/schema-profile.schema.json +47 -7
  42. package/schemas/studio-chart.schema.json +35 -0
  43. package/schemas/studio-drawing.schema.json +44 -0
  44. package/schemas/studio-money.schema.json +16 -0
  45. package/schemas/studio-presentation.schema.json +31 -0
  46. package/schemas/studio-release.schema.json +81 -0
  47. package/schemas/studio-table.schema.json +27 -0
  48. package/studio-release.json +28 -0
@@ -0,0 +1,342 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://schemas.kumwe.org/studio/v1/host-sequence-vector.schema.json",
4
+ "title": "Studio canonical host sequence conformance vector",
5
+ "description": "A deterministic sequence of host-port invocations, settlements, logical-clock advances and renderer completions. Every stateful precondition is bounded JSON so another runtime can reproduce retries, rate-limit windows and in-flight cancellation without wall-clock sleeps or executable fixture callbacks.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": [
9
+ "contractVersion",
10
+ "kind",
11
+ "id",
12
+ "description",
13
+ "profile",
14
+ "assertions",
15
+ "idempotencyPolicy",
16
+ "given",
17
+ "steps",
18
+ "expectFinal"
19
+ ],
20
+ "properties": {
21
+ "contractVersion": { "$ref": "common.schema.json#/$defs/contractVersion" },
22
+ "kind": { "const": "host-sequence-vector" },
23
+ "id": { "$ref": "common.schema.json#/$defs/stableId" },
24
+ "description": { "type": "string", "minLength": 1, "maxLength": 500 },
25
+ "profile": { "const": "studio.profile/host-baseline-v2" },
26
+ "assertions": {
27
+ "type": "array",
28
+ "minItems": 1,
29
+ "maxItems": 12,
30
+ "uniqueItems": true,
31
+ "items": { "$ref": "#/$defs/assertion" }
32
+ },
33
+ "idempotencyPolicy": { "$ref": "#/$defs/idempotencyPolicy" },
34
+ "given": { "$ref": "#/$defs/given" },
35
+ "steps": {
36
+ "type": "array",
37
+ "minItems": 2,
38
+ "maxItems": 24,
39
+ "items": {
40
+ "oneOf": [
41
+ { "$ref": "#/$defs/invokeStep" },
42
+ { "$ref": "#/$defs/settleStep" },
43
+ { "$ref": "#/$defs/advanceClockStep" },
44
+ { "$ref": "#/$defs/releasePreviewRenderStep" }
45
+ ]
46
+ }
47
+ },
48
+ "expectFinal": { "$ref": "#/$defs/finalState" }
49
+ },
50
+ "$defs": {
51
+ "assertion": {
52
+ "enum": [
53
+ "operation-id-mismatch-refusal",
54
+ "idempotent-in-flight-coalescing",
55
+ "idempotent-completed-replay",
56
+ "idempotency-changed-argument-refusal",
57
+ "idempotency-changed-context-refusal",
58
+ "idempotency-resource-scope-separation",
59
+ "canonical-number-equivalence",
60
+ "failed-attempt-retry",
61
+ "fixed-window-rate-limit",
62
+ "fixed-window-reset",
63
+ "in-flight-preview-cancellation",
64
+ "cross-context-cancellation-isolation",
65
+ "late-preview-result-discard"
66
+ ]
67
+ },
68
+ "idempotencyPolicy": {
69
+ "description": "The exact map key and canonical intent preimage used by this profile. Scope fields select an accepted record; the argument and listed semantic context fields form its canonical JSON fingerprint. Optional semantic fields that are absent are omitted, not serialized as null. Canonical JSON applies its number grammar, including normalization of negative zero to zero. Per-attempt request and trace correlation never affect intent.",
70
+ "type": "object",
71
+ "additionalProperties": false,
72
+ "required": [
73
+ "scopeFields",
74
+ "argumentCanonicalization",
75
+ "intentContextFields",
76
+ "absentOptionalFields",
77
+ "numberNormalization",
78
+ "excludedContextFields"
79
+ ],
80
+ "properties": {
81
+ "scopeFields": {
82
+ "const": ["idempotencyKey", "operationId", "resourceContextKey", "sessionGeneration"]
83
+ },
84
+ "argumentCanonicalization": { "const": "canonical-json" },
85
+ "intentContextFields": {
86
+ "const": ["expectedRevision", "locale", "protocolVersion"]
87
+ },
88
+ "absentOptionalFields": { "const": "omit" },
89
+ "numberNormalization": { "const": "canonical-json" },
90
+ "excludedContextFields": { "const": ["requestId", "traceContext"] }
91
+ }
92
+ },
93
+ "port": {
94
+ "enum": [
95
+ "artifact",
96
+ "localization",
97
+ "media",
98
+ "model",
99
+ "permission",
100
+ "preview",
101
+ "recovery",
102
+ "resource",
103
+ "telemetry"
104
+ ]
105
+ },
106
+ "artifactSeed": {
107
+ "type": "object",
108
+ "additionalProperties": false,
109
+ "required": ["id", "kind", "revision", "status"],
110
+ "properties": {
111
+ "id": { "$ref": "common.schema.json#/$defs/stableId" },
112
+ "kind": { "enum": ["blueprint", "content-model", "entry"] },
113
+ "revision": { "$ref": "common.schema.json#/$defs/revision" },
114
+ "status": { "enum": ["archived", "draft", "in-review", "published", "retired"] }
115
+ },
116
+ "allOf": [
117
+ {
118
+ "if": { "properties": { "kind": { "const": "entry" } }, "required": ["kind"] },
119
+ "then": {
120
+ "properties": {
121
+ "status": { "enum": ["archived", "draft", "in-review", "published"] }
122
+ }
123
+ },
124
+ "else": {
125
+ "properties": { "status": { "enum": ["draft", "published", "retired"] } }
126
+ }
127
+ }
128
+ ]
129
+ },
130
+ "rateLimit": {
131
+ "type": "object",
132
+ "additionalProperties": false,
133
+ "required": [
134
+ "operationId",
135
+ "maximumRequests",
136
+ "windowMilliseconds",
137
+ "retryAfterMilliseconds"
138
+ ],
139
+ "properties": {
140
+ "operationId": { "$ref": "host-operations.schema.json#/$defs/operationCapability" },
141
+ "maximumRequests": { "type": "integer", "minimum": 1, "maximum": 1000 },
142
+ "windowMilliseconds": { "type": "integer", "minimum": 1, "maximum": 86400000 },
143
+ "retryAfterMilliseconds": {
144
+ "description": "The retry delay at logical time zero after the fixed-window bound is reached. It equals the initial window duration.",
145
+ "type": "integer",
146
+ "minimum": 1,
147
+ "maximum": 86400000
148
+ }
149
+ }
150
+ },
151
+ "given": {
152
+ "type": "object",
153
+ "additionalProperties": false,
154
+ "required": ["artifacts", "permissions", "sessionGeneration"],
155
+ "properties": {
156
+ "artifacts": {
157
+ "type": "array",
158
+ "maxItems": 20,
159
+ "items": { "$ref": "#/$defs/artifactSeed" }
160
+ },
161
+ "permissions": {
162
+ "type": "array",
163
+ "maxItems": 50,
164
+ "uniqueItems": true,
165
+ "items": { "$ref": "common.schema.json#/$defs/qualifiedName" }
166
+ },
167
+ "rateLimits": {
168
+ "type": "array",
169
+ "maxItems": 20,
170
+ "items": { "$ref": "#/$defs/rateLimit" }
171
+ },
172
+ "sessionGeneration": { "$ref": "common.schema.json#/$defs/revision" }
173
+ }
174
+ },
175
+ "requestContext": {
176
+ "description": "The canonical host request envelope. Malformed single exchanges remain in the original host corpus; an intentional registered-capability mismatch is an executable invalid-request assertion here.",
177
+ "$ref": "host-request.schema.json#/$defs/requestContext"
178
+ },
179
+ "resultExpectation": {
180
+ "type": "object",
181
+ "additionalProperties": false,
182
+ "required": ["outcome"],
183
+ "properties": {
184
+ "outcome": { "const": "result" },
185
+ "revisionAdvancesFrom": { "$ref": "common.schema.json#/$defs/revision" },
186
+ "sameAs": { "$ref": "common.schema.json#/$defs/stableId" },
187
+ "value": { "enum": ["null", "rendered"] }
188
+ }
189
+ },
190
+ "errorExpectation": {
191
+ "type": "object",
192
+ "additionalProperties": false,
193
+ "required": ["outcome", "category", "retryable"],
194
+ "properties": {
195
+ "outcome": { "const": "error" },
196
+ "category": {
197
+ "enum": [
198
+ "cancelled",
199
+ "conflict",
200
+ "forbidden",
201
+ "incompatible",
202
+ "internal",
203
+ "invalid-request",
204
+ "limit-exceeded",
205
+ "not-found",
206
+ "rate-limited",
207
+ "unauthenticated",
208
+ "unavailable",
209
+ "validation-failed"
210
+ ]
211
+ },
212
+ "retryable": { "type": "boolean" },
213
+ "retryAfterMilliseconds": {
214
+ "type": "integer",
215
+ "minimum": 0,
216
+ "maximum": 86400000
217
+ }
218
+ }
219
+ },
220
+ "expectation": {
221
+ "oneOf": [{ "$ref": "#/$defs/resultExpectation" }, { "$ref": "#/$defs/errorExpectation" }]
222
+ },
223
+ "invokeStep": {
224
+ "type": "object",
225
+ "additionalProperties": false,
226
+ "required": ["action", "id", "port", "operation", "context", "completion"],
227
+ "properties": {
228
+ "action": { "const": "invoke" },
229
+ "id": { "$ref": "common.schema.json#/$defs/stableId" },
230
+ "port": { "$ref": "#/$defs/port" },
231
+ "operation": { "$ref": "common.schema.json#/$defs/localName" },
232
+ "context": { "$ref": "#/$defs/requestContext" },
233
+ "argument": { "$ref": "common.schema.json#/$defs/jsonValue" },
234
+ "completion": { "enum": ["pending", "settled"] },
235
+ "expect": { "$ref": "#/$defs/expectation" }
236
+ },
237
+ "allOf": [
238
+ {
239
+ "if": {
240
+ "properties": { "completion": { "const": "settled" } },
241
+ "required": ["completion"]
242
+ },
243
+ "then": {
244
+ "properties": { "expect": { "$ref": "#/$defs/expectation" } },
245
+ "required": ["expect"]
246
+ },
247
+ "else": { "not": { "required": ["expect"] } }
248
+ },
249
+ {
250
+ "if": {
251
+ "properties": {
252
+ "port": { "const": "preview" },
253
+ "operation": { "const": "render" }
254
+ },
255
+ "required": ["port", "operation"]
256
+ },
257
+ "then": {
258
+ "properties": {
259
+ "argument": { "$ref": "preview-message.schema.json#/$defs/render" }
260
+ },
261
+ "required": ["argument"]
262
+ }
263
+ }
264
+ ]
265
+ },
266
+ "settleStep": {
267
+ "type": "object",
268
+ "additionalProperties": false,
269
+ "required": ["action", "id", "invocation", "expect"],
270
+ "properties": {
271
+ "action": { "const": "settle" },
272
+ "id": { "$ref": "common.schema.json#/$defs/stableId" },
273
+ "invocation": { "$ref": "common.schema.json#/$defs/stableId" },
274
+ "expect": { "$ref": "#/$defs/expectation" }
275
+ }
276
+ },
277
+ "advanceClockStep": {
278
+ "type": "object",
279
+ "additionalProperties": false,
280
+ "required": ["action", "id", "milliseconds"],
281
+ "properties": {
282
+ "action": { "const": "advance-clock" },
283
+ "id": { "$ref": "common.schema.json#/$defs/stableId" },
284
+ "milliseconds": { "type": "integer", "minimum": 1, "maximum": 86400000 }
285
+ }
286
+ },
287
+ "releasePreviewRenderStep": {
288
+ "description": "A deterministic renderer completion injected after a prior preview.render invocation. It is a harness precondition, not a host port or transport operation.",
289
+ "type": "object",
290
+ "additionalProperties": false,
291
+ "required": ["action", "id", "invocation", "value"],
292
+ "properties": {
293
+ "action": { "const": "release-preview-render" },
294
+ "id": { "$ref": "common.schema.json#/$defs/stableId" },
295
+ "invocation": { "$ref": "common.schema.json#/$defs/stableId" },
296
+ "value": { "$ref": "preview-message.schema.json#/$defs/rendered" }
297
+ }
298
+ },
299
+ "artifactFinalState": {
300
+ "type": "object",
301
+ "additionalProperties": false,
302
+ "required": ["id", "status", "revisionFrom"],
303
+ "properties": {
304
+ "id": { "$ref": "common.schema.json#/$defs/stableId" },
305
+ "status": { "enum": ["archived", "draft", "in-review", "published", "retired"] },
306
+ "revisionFrom": { "$ref": "common.schema.json#/$defs/stableId" }
307
+ }
308
+ },
309
+ "recoveryFinalState": {
310
+ "type": "object",
311
+ "additionalProperties": false,
312
+ "required": ["resourceContextKey", "value"],
313
+ "properties": {
314
+ "resourceContextKey": { "$ref": "common.schema.json#/$defs/stableId" },
315
+ "value": { "$ref": "common.schema.json#/$defs/jsonValue" }
316
+ }
317
+ },
318
+ "finalState": {
319
+ "type": "object",
320
+ "additionalProperties": false,
321
+ "required": ["pendingPreviewRenders", "previewDeliveries"],
322
+ "properties": {
323
+ "artifacts": {
324
+ "type": "array",
325
+ "maxItems": 20,
326
+ "items": { "$ref": "#/$defs/artifactFinalState" }
327
+ },
328
+ "recovery": {
329
+ "type": "array",
330
+ "maxItems": 20,
331
+ "items": { "$ref": "#/$defs/recoveryFinalState" }
332
+ },
333
+ "pendingPreviewRenders": { "const": 0 },
334
+ "previewDeliveries": {
335
+ "type": "array",
336
+ "maxItems": 20,
337
+ "items": { "type": "string", "pattern": "^[a-f0-9]{64}(?![\\s\\S])" }
338
+ }
339
+ }
340
+ }
341
+ }
342
+ }
@@ -133,6 +133,8 @@
133
133
  "enum": [
134
134
  "artifact",
135
135
  "artifact-references",
136
+ "content-model",
137
+ "content-models",
136
138
  "media-asset",
137
139
  "media-page",
138
140
  "message-bundle",
@@ -1,10 +1,29 @@
1
1
  {
2
2
  "contractVersion": "0.1-draft",
3
3
  "epoch": "https://schemas.kumwe.org/studio/v1/",
4
+ "generator": {
5
+ "name": "@kumwe/studio/schema-manifest",
6
+ "version": "1.0.0"
7
+ },
4
8
  "kind": "schema-manifest",
5
9
  "schemas": [
6
10
  {
7
- "digest": "sha256-sx4nxAo1fq7Mjp2J3gfsIWRq9vD6nkDDrc1PtWLzfNE=",
11
+ "digest": "sha256-WvSNMOQ3OZWs7ZKBCCRRwLtw5byZBtn6Rwvxz74vfAY=",
12
+ "file": "authoring-message-catalog.schema.json",
13
+ "id": "https://schemas.kumwe.org/studio/v1/authoring-message-catalog.schema.json"
14
+ },
15
+ {
16
+ "digest": "sha256-hZBNrpwHkLuUu/mPeU2UWtuOXfvZgrd8MO7vB9fJWog=",
17
+ "file": "authoring-web-vector.schema.json",
18
+ "id": "https://schemas.kumwe.org/studio/v1/authoring-web-vector.schema.json"
19
+ },
20
+ {
21
+ "digest": "sha256-GCk2z8XalwUUKM6R146c7WeCj3CY00kTMRKtPjaeehs=",
22
+ "file": "binding-projection-vector.schema.json",
23
+ "id": "https://schemas.kumwe.org/studio/v1/binding-projection-vector.schema.json"
24
+ },
25
+ {
26
+ "digest": "sha256-S3sx0m9PQs2vMFNvYIapBXc8W184cEng5MFF54C6RwQ=",
8
27
  "file": "block-definition.schema.json",
9
28
  "id": "https://schemas.kumwe.org/studio/v1/block-definition.schema.json"
10
29
  },
@@ -84,7 +103,12 @@
84
103
  "id": "https://schemas.kumwe.org/studio/v1/host-result.schema.json"
85
104
  },
86
105
  {
87
- "digest": "sha256-KETVqPMNQCSN8faoNW7fHuSWc6rT/Jkp4+Lh31gQuQM=",
106
+ "digest": "sha256-pYvWThxhigEI7S1XeKyUkkN1KMZZPeRj/d5HV3ke+kQ=",
107
+ "file": "host-sequence-vector.schema.json",
108
+ "id": "https://schemas.kumwe.org/studio/v1/host-sequence-vector.schema.json"
109
+ },
110
+ {
111
+ "digest": "sha256-v2LFWwqpa0hS9XnYaVP9xC7Ohyw+Dl7ZG4e038+LqtI=",
88
112
  "file": "host-vector.schema.json",
89
113
  "id": "https://schemas.kumwe.org/studio/v1/host-vector.schema.json"
90
114
  },
@@ -134,35 +158,80 @@
134
158
  "id": "https://schemas.kumwe.org/studio/v1/plugin-manifest.schema.json"
135
159
  },
136
160
  {
137
- "digest": "sha256-wg6mVwubXmfpzfOZzlSamDJtyhdpD9/7vtqjb22SYB8=",
161
+ "digest": "sha256-7yQWc2+cZ+LoVmq2nZ5h4NsTO8tRjpODN7vIyJnbDKU=",
138
162
  "file": "preview-message.schema.json",
139
163
  "id": "https://schemas.kumwe.org/studio/v1/preview-message.schema.json"
140
164
  },
165
+ {
166
+ "digest": "sha256-h4au/6iI71X7lArbz5moSOxk29g+I+W/1Ewkeh7MqoI=",
167
+ "file": "preview-vector.schema.json",
168
+ "id": "https://schemas.kumwe.org/studio/v1/preview-vector.schema.json"
169
+ },
141
170
  {
142
171
  "digest": "sha256-QURE0s0zSfvGXEvy3meE4rQeofecsUVZksqQKfKv4ys=",
143
172
  "file": "provenance.schema.json",
144
173
  "id": "https://schemas.kumwe.org/studio/v1/provenance.schema.json"
145
174
  },
146
175
  {
147
- "digest": "sha256-PKyCGI95WZ6Uojq9u5HvS2wwWU97+V+nmsY4l/Vc040=",
176
+ "digest": "sha256-oi//2JX617h+s50otcRWB4/ZTnv4iVo+gngpr73i+EA=",
177
+ "file": "renderer-web-vector.schema.json",
178
+ "id": "https://schemas.kumwe.org/studio/v1/renderer-web-vector.schema.json"
179
+ },
180
+ {
181
+ "digest": "sha256-74OcoS9iGzRnDOjo/opHhlXZdxMLcCUkw0Ol4ipzkws=",
148
182
  "file": "rich-text-projection.schema.json",
149
183
  "id": "https://schemas.kumwe.org/studio/v1/rich-text-projection.schema.json"
150
184
  },
151
185
  {
152
- "digest": "sha256-PgFfnylfsJzq7B0wQq1gAxYA0r6gMx+xiKeT3NiDVqc=",
186
+ "digest": "sha256-r+wYEvy3tvMdQhmU0272K1cklAiYcEiD7nICWDdFFPs=",
153
187
  "file": "rich-text.schema.json",
154
188
  "id": "https://schemas.kumwe.org/studio/v1/rich-text.schema.json"
155
189
  },
156
190
  {
157
- "digest": "sha256-yX+70kh/aPaBZiOlNon3R0B4W9ZWCnvOMKDF3ItxkqU=",
191
+ "digest": "sha256-200BYrY2bR/TvZGo852CHKtkxFn+7Yf2ULiVirg1R/o=",
192
+ "file": "schema-profile-vector.schema.json",
193
+ "id": "https://schemas.kumwe.org/studio/v1/schema-profile-vector.schema.json"
194
+ },
195
+ {
196
+ "digest": "sha256-DbxBTu984mB1oo3O1kcDuqkxbmPJjtTXq65GptM8Xkw=",
158
197
  "file": "schema-profile.schema.json",
159
198
  "id": "https://schemas.kumwe.org/studio/v1/schema-profile.schema.json"
160
199
  },
200
+ {
201
+ "digest": "sha256-3jvAa7VGd6F7uAOR82AcTOSMGXWvgaMVmGsG1UzSXiI=",
202
+ "file": "studio-chart.schema.json",
203
+ "id": "https://schemas.kumwe.org/studio/v1/studio-chart.schema.json"
204
+ },
161
205
  {
162
206
  "digest": "sha256-FC0lGnAqTIdHLvlwbGyYGdXEK5mwtyhdyrCwt7WzVhY=",
163
207
  "file": "studio-config.schema.json",
164
208
  "id": "https://schemas.kumwe.org/studio/v1/studio-config.schema.json"
165
209
  },
210
+ {
211
+ "digest": "sha256-SAP1i3VfZS51FRsqnN2frFxE/UmI9xEUsSREUp/cA+E=",
212
+ "file": "studio-drawing.schema.json",
213
+ "id": "https://schemas.kumwe.org/studio/v1/studio-drawing.schema.json"
214
+ },
215
+ {
216
+ "digest": "sha256-6jp6QkIqqUrNSVAQJHOlK8BCb8vdAZF5QRZmyRUqfgM=",
217
+ "file": "studio-money.schema.json",
218
+ "id": "https://schemas.kumwe.org/studio/v1/studio-money.schema.json"
219
+ },
220
+ {
221
+ "digest": "sha256-+dyYyHfQcUz4n5BUNMmGODJ6J7n2ysm9/+rWpSrbODA=",
222
+ "file": "studio-presentation.schema.json",
223
+ "id": "https://schemas.kumwe.org/studio/v1/studio-presentation.schema.json"
224
+ },
225
+ {
226
+ "digest": "sha256-8U3Im000ka2Zdfeo9J/ixmPLnMaLj3JE8vo8DrA6HMI=",
227
+ "file": "studio-release.schema.json",
228
+ "id": "https://schemas.kumwe.org/studio/v1/studio-release.schema.json"
229
+ },
230
+ {
231
+ "digest": "sha256-txf6OXjSyFvOcoepU01qNY2WWlTyDA3iquMVXrFC2tQ=",
232
+ "file": "studio-table.schema.json",
233
+ "id": "https://schemas.kumwe.org/studio/v1/studio-table.schema.json"
234
+ },
166
235
  {
167
236
  "digest": "sha256-xzhCb8J2nx+K6kBMciFj1glB4Q6jT8+KUdbUBsNM4h8=",
168
237
  "file": "theme.schema.json",
@@ -31,7 +31,20 @@
31
31
  "minimum": 0
32
32
  },
33
33
  "type": {
34
- "$ref": "common.schema.json#/$defs/qualifiedName"
34
+ "enum": [
35
+ "studio.preview/activated",
36
+ "studio.preview/dispose",
37
+ "studio.preview/error",
38
+ "studio.preview/measure",
39
+ "studio.preview/measurements",
40
+ "studio.preview/ready",
41
+ "studio.preview/reload",
42
+ "studio.preview/render",
43
+ "studio.preview/rendered",
44
+ "studio.preview/select",
45
+ "studio.preview/teardown",
46
+ "studio.preview/viewport"
47
+ ]
35
48
  },
36
49
  "payload": {
37
50
  "type": "object",
@@ -239,6 +252,12 @@
239
252
  }
240
253
  ],
241
254
  "$defs": {
255
+ "previewMarker": {
256
+ "description": "A deterministic marker for one node in a canonical draft: the draft digest followed by its zero-based Blueprint preorder ordinal.",
257
+ "type": "string",
258
+ "pattern": "^studio\\.preview/node/[0-9a-f]{64}/(?:0|[1-9][0-9]{0,4})(?![\\s\\S])",
259
+ "maxLength": 90
260
+ },
242
261
  "ready": {
243
262
  "type": "object",
244
263
  "additionalProperties": false,
@@ -262,7 +281,7 @@
262
281
  "render": {
263
282
  "type": "object",
264
283
  "additionalProperties": false,
265
- "required": ["artifactId", "draftDigest", "viewport"],
284
+ "required": ["artifactId", "draftDigest", "draftRevision", "requestId", "viewport"],
266
285
  "properties": {
267
286
  "artifactId": {
268
287
  "$ref": "common.schema.json#/$defs/stableId"
@@ -274,6 +293,10 @@
274
293
  "draftRevision": {
275
294
  "$ref": "common.schema.json#/$defs/revision"
276
295
  },
296
+ "requestId": {
297
+ "$ref": "common.schema.json#/$defs/stableId",
298
+ "description": "A session-unique render attempt identifier. Retries use a new identifier even when draft and viewport are unchanged."
299
+ },
277
300
  "viewport": {
278
301
  "$ref": "common.schema.json#/$defs/localName"
279
302
  }
@@ -282,24 +305,29 @@
282
305
  "rendered": {
283
306
  "type": "object",
284
307
  "additionalProperties": false,
285
- "required": ["draftDigest", "markers", "diagnostics"],
308
+ "required": ["requestId", "draftDigest", "markers", "markerMap", "diagnostics"],
286
309
  "properties": {
287
310
  "draftDigest": {
288
311
  "type": "string",
289
312
  "pattern": "^[a-f0-9]{64}(?![\\s\\S])"
290
313
  },
314
+ "requestId": {
315
+ "$ref": "common.schema.json#/$defs/stableId",
316
+ "description": "The exact render attempt this response settles."
317
+ },
291
318
  "markers": {
292
319
  "type": "array",
293
320
  "maxItems": 100000,
321
+ "uniqueItems": true,
294
322
  "items": {
295
- "$ref": "common.schema.json#/$defs/stableId"
323
+ "$ref": "#/$defs/previewMarker"
296
324
  }
297
325
  },
298
326
  "markerMap": {
299
327
  "type": "object",
300
328
  "maxProperties": 100000,
301
329
  "propertyNames": {
302
- "$ref": "common.schema.json#/$defs/stableId"
330
+ "$ref": "#/$defs/previewMarker"
303
331
  },
304
332
  "additionalProperties": {
305
333
  "$ref": "common.schema.json#/$defs/stableId"
@@ -334,13 +362,16 @@
334
362
  "required": ["requestId", "markers"],
335
363
  "properties": {
336
364
  "requestId": {
337
- "$ref": "common.schema.json#/$defs/stableId"
365
+ "$ref": "common.schema.json#/$defs/stableId",
366
+ "description": "A session-unique measurement attempt identifier, never reused for another render or measurement."
338
367
  },
339
368
  "markers": {
340
369
  "type": "array",
370
+ "minItems": 1,
341
371
  "maxItems": 1000,
372
+ "uniqueItems": true,
342
373
  "items": {
343
- "$ref": "common.schema.json#/$defs/stableId"
374
+ "$ref": "#/$defs/previewMarker"
344
375
  }
345
376
  }
346
377
  }
@@ -361,7 +392,7 @@
361
392
  "type": "object",
362
393
  "maxProperties": 1000,
363
394
  "propertyNames": {
364
- "$ref": "common.schema.json#/$defs/stableId"
395
+ "$ref": "#/$defs/previewMarker"
365
396
  },
366
397
  "additionalProperties": {
367
398
  "type": "array",
@@ -375,8 +406,9 @@
375
406
  "unknown": {
376
407
  "type": "array",
377
408
  "maxItems": 1000,
409
+ "uniqueItems": true,
378
410
  "items": {
379
- "$ref": "common.schema.json#/$defs/stableId"
411
+ "$ref": "#/$defs/previewMarker"
380
412
  }
381
413
  },
382
414
  "viewport": {
@@ -492,8 +524,8 @@
492
524
  "enum": ["activate", "context-menu", "focus"]
493
525
  },
494
526
  "marker": {
495
- "description": "The opaque marker the renderer associated with the region. It carries nothing beyond the node identity the render already published.",
496
- "$ref": "common.schema.json#/$defs/stableId"
527
+ "description": "A marker from the renderer's currently accepted inventory. The channel drops invented and stale markers.",
528
+ "$ref": "#/$defs/previewMarker"
497
529
  }
498
530
  }
499
531
  },
@@ -519,7 +551,7 @@
519
551
  "height": {
520
552
  "description": "Bounded CSS-pixel height.",
521
553
  "type": "integer",
522
- "minimum": 120,
554
+ "minimum": 240,
523
555
  "maximum": 10000
524
556
  },
525
557
  "width": {