@openwop/spec-artifacts 2.0.0-rc.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (229) hide show
  1. package/CORPUS-STAMP.json +234 -0
  2. package/LICENSE +201 -0
  3. package/README.md +7 -0
  4. package/api/.redocly.lint-ignore.yaml +22 -0
  5. package/api/asyncapi.yaml +834 -0
  6. package/api/grpc/openwop.proto +251 -0
  7. package/api/openapi.yaml +2693 -0
  8. package/api/redocly.yaml +23 -0
  9. package/api/seams-v2.yaml +680 -0
  10. package/api/v2/asyncapi.yaml +528 -0
  11. package/api/v2/openapi.yaml +3139 -0
  12. package/api/v2/redocly.yaml +16 -0
  13. package/package.json +10 -0
  14. package/schemas/README.md +144 -0
  15. package/schemas/a2a-task-state.schema.json +78 -0
  16. package/schemas/a2ui-surface-delta-frame.schema.json +48 -0
  17. package/schemas/agent-deployment-transition.schema.json +49 -0
  18. package/schemas/agent-deployment.schema.json +54 -0
  19. package/schemas/agent-eval-suite.schema.json +140 -0
  20. package/schemas/agent-inventory-response.schema.json +115 -0
  21. package/schemas/agent-manifest.schema.json +156 -0
  22. package/schemas/agent-org-chart.schema.json +82 -0
  23. package/schemas/agent-ref.schema.json +63 -0
  24. package/schemas/agent-roster-entry.schema.json +81 -0
  25. package/schemas/agent-roster-response.schema.json +21 -0
  26. package/schemas/ai-envelope.schema.json +134 -0
  27. package/schemas/annotation-create.schema.json +37 -0
  28. package/schemas/annotation.schema.json +56 -0
  29. package/schemas/artifact-type-pack-manifest.schema.json +244 -0
  30. package/schemas/audit-verify-result.schema.json +90 -0
  31. package/schemas/budget-policy.schema.json +18 -0
  32. package/schemas/capabilities.schema.json +4160 -0
  33. package/schemas/certification-bundle-v2.schema.json +118 -0
  34. package/schemas/channel-presence-payload.schema.json +41 -0
  35. package/schemas/channel-written-payload.schema.json +55 -0
  36. package/schemas/chat-card-pack-manifest.schema.json +253 -0
  37. package/schemas/compact-tool-descriptor.schema.json +51 -0
  38. package/schemas/compensation-policy.schema.json +64 -0
  39. package/schemas/conformance-certification-bundle.schema.json +86 -0
  40. package/schemas/connection-pack-manifest.schema.json +353 -0
  41. package/schemas/conversation-event.schema.json +168 -0
  42. package/schemas/conversation-turn.schema.json +117 -0
  43. package/schemas/core-conformance-mock-agent-config.schema.json +152 -0
  44. package/schemas/credential-provenance.schema.json +18 -0
  45. package/schemas/credential-reference.schema.json +21 -0
  46. package/schemas/debug-bundle.schema.json +196 -0
  47. package/schemas/dispatch-config.schema.json +112 -0
  48. package/schemas/envelopes/clarification.request.schema.json +52 -0
  49. package/schemas/envelopes/error.schema.json +30 -0
  50. package/schemas/envelopes/media.audio.schema.json +38 -0
  51. package/schemas/envelopes/media.file.schema.json +37 -0
  52. package/schemas/envelopes/media.image.schema.json +33 -0
  53. package/schemas/envelopes/schema.request.schema.json +26 -0
  54. package/schemas/envelopes/schema.response.schema.json +22 -0
  55. package/schemas/envelopes/ui.a2ui-surface.schema.json +154 -0
  56. package/schemas/error-envelope.schema.json +25 -0
  57. package/schemas/eval-summary.schema.json +92 -0
  58. package/schemas/export-bundle.schema.json +66 -0
  59. package/schemas/form-content-pack-manifest.schema.json +243 -0
  60. package/schemas/frontend-plugin-manifest.schema.json +109 -0
  61. package/schemas/goal.schema.json +104 -0
  62. package/schemas/heartbeat-evaluated.schema.json +14 -0
  63. package/schemas/heartbeat-state-changed.schema.json +14 -0
  64. package/schemas/localized-content-language-settings.schema.json +26 -0
  65. package/schemas/localized-content-page-response.schema.json +60 -0
  66. package/schemas/localized-content-page.schema.json +62 -0
  67. package/schemas/localized-content-section.schema.json +51 -0
  68. package/schemas/memory-entry.schema.json +36 -0
  69. package/schemas/memory-list-options.schema.json +37 -0
  70. package/schemas/node-pack-manifest.schema.json +654 -0
  71. package/schemas/orchestrator-decision.schema.json +90 -0
  72. package/schemas/org-chart-responsibility-view.schema.json +26 -0
  73. package/schemas/pack-lockfile.schema.json +108 -0
  74. package/schemas/prompt-kind.schema.json +8 -0
  75. package/schemas/prompt-pack-manifest.schema.json +117 -0
  76. package/schemas/prompt-ref.schema.json +40 -0
  77. package/schemas/prompt-template.schema.json +149 -0
  78. package/schemas/proposal.schema.json +84 -0
  79. package/schemas/registry-version-manifest.schema.json +208 -0
  80. package/schemas/residency.schema.json +16 -0
  81. package/schemas/run-ancestry-response.schema.json +54 -0
  82. package/schemas/run-diff-response.schema.json +64 -0
  83. package/schemas/run-event-payloads.schema.json +4452 -0
  84. package/schemas/run-event.schema.json +211 -0
  85. package/schemas/run-options.schema.json +80 -0
  86. package/schemas/run-orchestrator-decided-event.schema.json +20 -0
  87. package/schemas/run-snapshot.schema.json +148 -0
  88. package/schemas/security-advisory.schema.json +109 -0
  89. package/schemas/self-hosted-runner-dispatch-frame.schema.json +79 -0
  90. package/schemas/self-hosted-runner-registration.schema.json +53 -0
  91. package/schemas/self-hosted-runner-result-frame.schema.json +38 -0
  92. package/schemas/subject.schema.json +56 -0
  93. package/schemas/suspend-request.schema.json +207 -0
  94. package/schemas/tool-descriptor.schema.json +63 -0
  95. package/schemas/trigger-event.schema.json +222 -0
  96. package/schemas/trigger-subscription-registration.schema.json +67 -0
  97. package/schemas/trigger-subscription.schema.json +26 -0
  98. package/schemas/ui-plugin-message.schema.json +90 -0
  99. package/schemas/v2/a2a-task-state.schema.json +102 -0
  100. package/schemas/v2/a2ui-surface-delta-frame.schema.json +62 -0
  101. package/schemas/v2/agent-deployment-transition.schema.json +67 -0
  102. package/schemas/v2/agent-deployment.schema.json +68 -0
  103. package/schemas/v2/agent-eval-suite.schema.json +214 -0
  104. package/schemas/v2/agent-inventory-response.schema.json +172 -0
  105. package/schemas/v2/agent-manifest.schema.json +218 -0
  106. package/schemas/v2/agent-org-chart.schema.json +149 -0
  107. package/schemas/v2/agent-ref.schema.json +67 -0
  108. package/schemas/v2/agent-roster-entry.schema.json +104 -0
  109. package/schemas/v2/agent-roster-response.schema.json +27 -0
  110. package/schemas/v2/ai-envelope.schema.json +167 -0
  111. package/schemas/v2/annotation-create.schema.json +109 -0
  112. package/schemas/v2/annotation.schema.json +142 -0
  113. package/schemas/v2/artifact-type-pack-manifest.schema.json +245 -0
  114. package/schemas/v2/audit-verify-result.schema.json +110 -0
  115. package/schemas/v2/budget-policy.schema.json +61 -0
  116. package/schemas/v2/capabilities.schema.json +7644 -0
  117. package/schemas/v2/certification-bundle.schema.json +401 -0
  118. package/schemas/v2/channel-presence-payload.schema.json +60 -0
  119. package/schemas/v2/channel-written-payload.schema.json +64 -0
  120. package/schemas/v2/chat-card-pack-manifest.schema.json +254 -0
  121. package/schemas/v2/compact-tool-descriptor.schema.json +108 -0
  122. package/schemas/v2/compensation-policy.schema.json +91 -0
  123. package/schemas/v2/compensation-projection.schema.json +95 -0
  124. package/schemas/v2/configurable.schema.json +110 -0
  125. package/schemas/v2/connection-pack-manifest.schema.json +354 -0
  126. package/schemas/v2/conversation-event.schema.json +281 -0
  127. package/schemas/v2/conversation-turn.schema.json +165 -0
  128. package/schemas/v2/credential-provenance.schema.json +62 -0
  129. package/schemas/v2/credential-reference.schema.json +28 -0
  130. package/schemas/v2/debug-bundle.schema.json +312 -0
  131. package/schemas/v2/dispatch-config.schema.json +147 -0
  132. package/schemas/v2/effect-ledger-projection.schema.json +71 -0
  133. package/schemas/v2/effect-seam-manifest.schema.json +98 -0
  134. package/schemas/v2/envelopes/clarification.request.schema.json +59 -0
  135. package/schemas/v2/envelopes/error.schema.json +35 -0
  136. package/schemas/v2/envelopes/media.audio.schema.json +41 -0
  137. package/schemas/v2/envelopes/media.file.schema.json +40 -0
  138. package/schemas/v2/envelopes/media.image.schema.json +36 -0
  139. package/schemas/v2/envelopes/schema.request.schema.json +29 -0
  140. package/schemas/v2/envelopes/schema.response.schema.json +26 -0
  141. package/schemas/v2/envelopes/ui.a2ui-surface.schema.json +292 -0
  142. package/schemas/v2/error-envelope.schema.json +229 -0
  143. package/schemas/v2/eval-summary.schema.json +166 -0
  144. package/schemas/v2/export-bundle.schema.json +94 -0
  145. package/schemas/v2/form-content-pack-manifest.schema.json +241 -0
  146. package/schemas/v2/frontend-plugin-manifest.schema.json +152 -0
  147. package/schemas/v2/goal.schema.json +188 -0
  148. package/schemas/v2/heartbeat-evaluated.schema.json +34 -0
  149. package/schemas/v2/heartbeat-state-changed.schema.json +31 -0
  150. package/schemas/v2/ids.schema.json +31 -0
  151. package/schemas/v2/localized-content-language-settings.schema.json +34 -0
  152. package/schemas/v2/localized-content-page-response.schema.json +94 -0
  153. package/schemas/v2/localized-content-page.schema.json +87 -0
  154. package/schemas/v2/localized-content-section.schema.json +63 -0
  155. package/schemas/v2/memory-entry.schema.json +45 -0
  156. package/schemas/v2/memory-list-options.schema.json +41 -0
  157. package/schemas/v2/node-pack-manifest.schema.json +657 -0
  158. package/schemas/v2/orchestrator-decision.schema.json +120 -0
  159. package/schemas/v2/org-chart-responsibility-view.schema.json +36 -0
  160. package/schemas/v2/pack-lockfile.schema.json +139 -0
  161. package/schemas/v2/prompt-kind.schema.json +14 -0
  162. package/schemas/v2/prompt-pack-manifest.schema.json +118 -0
  163. package/schemas/v2/prompt-ref.schema.json +42 -0
  164. package/schemas/v2/prompt-template.schema.json +209 -0
  165. package/schemas/v2/proposal.schema.json +145 -0
  166. package/schemas/v2/registry-version-manifest.schema.json +292 -0
  167. package/schemas/v2/residency.schema.json +19 -0
  168. package/schemas/v2/run-ancestry-response.schema.json +68 -0
  169. package/schemas/v2/run-diff-response.schema.json +80 -0
  170. package/schemas/v2/run-event-payloads.schema.json +4588 -0
  171. package/schemas/v2/run-event.schema.json +324 -0
  172. package/schemas/v2/run-options.schema.json +90 -0
  173. package/schemas/v2/run-orchestrator-decided-event.schema.json +22 -0
  174. package/schemas/v2/run-snapshot.schema.json +207 -0
  175. package/schemas/v2/security-advisory.schema.json +138 -0
  176. package/schemas/v2/self-hosted-runner-dispatch-frame.schema.json +119 -0
  177. package/schemas/v2/self-hosted-runner-registration.schema.json +74 -0
  178. package/schemas/v2/self-hosted-runner-result-frame.schema.json +47 -0
  179. package/schemas/v2/subject-link.schema.json +69 -0
  180. package/schemas/v2/subject.schema.json +597 -0
  181. package/schemas/v2/suspend-request.schema.json +370 -0
  182. package/schemas/v2/tool-descriptor.schema.json +150 -0
  183. package/schemas/v2/trigger-event.schema.json +508 -0
  184. package/schemas/v2/trigger-subscription-registration.schema.json +99 -0
  185. package/schemas/v2/trigger-subscription.schema.json +79 -0
  186. package/schemas/v2/ui-plugin-message.schema.json +149 -0
  187. package/schemas/v2/workflow-chain-pack-manifest.schema.json +610 -0
  188. package/schemas/v2/workflow-definition.schema.json +864 -0
  189. package/schemas/v2/workload-identity.schema.json +115 -0
  190. package/schemas/v2/workspace-file-create.schema.json +23 -0
  191. package/schemas/v2/workspace-file.schema.json +45 -0
  192. package/schemas/workflow-chain-pack-manifest.schema.json +615 -0
  193. package/schemas/workflow-definition.schema.json +850 -0
  194. package/schemas/workload-identity.schema.json +79 -0
  195. package/schemas/workspace-file-create.schema.json +20 -0
  196. package/schemas/workspace-file.schema.json +39 -0
  197. package/spec/v1/alias-detectors.json +283 -0
  198. package/spec/v1/capability-declaration-classes.json +176 -0
  199. package/spec/v1/core-standard-manifest.json +423 -0
  200. package/spec/v1/deprecations.json +854 -0
  201. package/spec/v1/deprecations.schema.json +187 -0
  202. package/spec/v1/event-codemap.json +1089 -0
  203. package/spec/v1/event-codemap.schema.json +41 -0
  204. package/spec/v1/extensions.json +1273 -0
  205. package/spec/v1/gaps.json +14581 -0
  206. package/spec/v1/gaps.schema.json +55 -0
  207. package/spec/v1/migrations.json +1822 -0
  208. package/spec/v1/migrations.schema.json +44 -0
  209. package/spec/v1/operation-path-manifest.json +462 -0
  210. package/spec/v1/spec-gaps.json +4823 -0
  211. package/spec/v2/declaration.json +1862 -0
  212. package/spec/v2/declaration.schema.json +305 -0
  213. package/spec/v2/errors.json +837 -0
  214. package/spec/v2/event-codemap.json +1099 -0
  215. package/spec/v2/event-codemap.schema.json +114 -0
  216. package/spec/v2/ext/provider-idempotency/registry.json +6 -0
  217. package/spec/v2/facets/a2a.schema.json +51 -0
  218. package/spec/v2/facets/aiProviders.schema.json +56 -0
  219. package/spec/v2/facets/auth.schema.json +91 -0
  220. package/spec/v2/facets/heartbeat.schema.json +20 -0
  221. package/spec/v2/facets/interrupt.schema.json +29 -0
  222. package/spec/v2/facets/mcp.schema.json +81 -0
  223. package/spec/v2/facets/replay.schema.json +34 -0
  224. package/spec/v2/facets/sandbox.schema.json +31 -0
  225. package/spec/v2/facets/webhooks.schema.json +18 -0
  226. package/spec/v2/path-manifest.json +279 -0
  227. package/spec/v2/peer-dependency-aliases.json +165 -0
  228. package/spec/v2/profiles.json +45 -0
  229. package/spec/v2/release.json +6 -0
@@ -0,0 +1,209 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openwop.dev/spec/v2/prompt-template.schema.json",
4
+ "title": "PromptTemplate",
5
+ "description": "Canonical wire shape for a named, versioned, variable-bound prompt body referenced by workflow nodes and agent manifests. See spec/v1/prompts.md §\"PromptTemplate\" for the canonical contract, RFC 0027 for the rationale, and prompt-ref.schema.json for the reference type that points at instances of this shape. Variable interpolation MUST use Mustache-compatible `{{varName}}` placeholders; unresolved required variables MUST cause the node to fail with `prompt_variable_unresolved`; unresolved optional variables render as the empty string per RFC 0027 §A.\n\nThe `text` field MAY contain `<UNTRUSTED>...</UNTRUSTED>` markers verbatim — hosts MUST preserve them through composition per SECURITY/threat-model-prompt-injection.md. Variables sourced from `secret` MUST be replaced with `[REDACTED:<secretId>]` markers in any observability output (e.g., `prompt.composed` events) per SECURITY/threat-model-secret-leakage.md §SR-1.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": [
9
+ "templateId",
10
+ "version",
11
+ "kind",
12
+ "text"
13
+ ],
14
+ "properties": {
15
+ "templateId": {
16
+ "$ref": "ids.schema.json#/$defs/templateId",
17
+ "description": "Stable identifier. Convention: vendor-prefixed for portable templates (`vendor.acme.writer.v2`) or unprefixed for host-resident templates (`writer`). Same naming discipline as node-pack typeIds (host-extensions.md §\"Canonical-prefix table\")."
18
+ },
19
+ "version": {
20
+ "type": "string",
21
+ "pattern": "^\\d+\\.\\d+\\.\\d+(?:-[0-9A-Za-z.-]+)?(?:\\+[0-9A-Za-z.-]+)?$",
22
+ "description": "Semantic Versioning 2.0.0. Bumping major implies a breaking variable-schema or text change; consumers MUST pin to a specific version via PromptRef.version if they care about exact bodies."
23
+ },
24
+ "kind": {
25
+ "$ref": "./prompt-kind.schema.json",
26
+ "description": "Role this template plays when composed into an LLM call. A node MAY reference one template of each kind. Relative $ref resolves to the shared enum file for redocly's local-file walker; Ajv resolves it equivalently via the schema registry."
27
+ },
28
+ "text": {
29
+ "type": "string",
30
+ "maxLength": 65536,
31
+ "description": "Template body. Mustache-compatible `{{varName}}` placeholders are substituted at compose time using bindings from PromptVariable.source + variableOverrides. Hosts MAY cap below 65536 via capabilities.prompts.maxTemplateBytes, but MUST NOT exceed it."
32
+ },
33
+ "name": {
34
+ "type": "string",
35
+ "maxLength": 200,
36
+ "description": "Human-readable display name surfaced in authoring UIs and template pickers."
37
+ },
38
+ "description": {
39
+ "type": "string",
40
+ "maxLength": 2000,
41
+ "description": "One-paragraph description of what the template is for. Surfaced in authoring UI hover-text and library-list cards."
42
+ },
43
+ "variables": {
44
+ "type": "array",
45
+ "items": {
46
+ "$ref": "#/$defs/PromptVariable"
47
+ },
48
+ "description": "Typed interpolation slots. Hosts MUST validate runtime bindings against this array before composing. A `{{varName}}` placeholder that has no matching entry in `variables[]` MAY appear (treated as an optional variable with source `input` and no default) — hosts SHOULD warn at install time."
49
+ },
50
+ "modelHints": {
51
+ "type": "object",
52
+ "additionalProperties": false,
53
+ "description": "Non-normative authoring hints. Hosts MAY surface these in editor UI (default temperature, suggested model class). They do NOT override per-node config or per-run RunOptions.configurable values.",
54
+ "properties": {
55
+ "modelClass": {
56
+ "type": "string",
57
+ "description": "Per AgentRef.modelClass enum + vendor extensions (e.g., `reasoning`, `writing`, `vendor.openwop.creative-writing`)."
58
+ },
59
+ "temperature": {
60
+ "type": "number",
61
+ "minimum": 0,
62
+ "maximum": 2,
63
+ "description": "Suggested sampling temperature."
64
+ },
65
+ "maxTokens": {
66
+ "type": "integer",
67
+ "minimum": 1,
68
+ "description": "Suggested max-tokens ceiling."
69
+ },
70
+ "envelopeType": {
71
+ "type": "string",
72
+ "description": "Suggested AI Envelope kind to use with this template, per RFC 0021. Opaque string in v1.x; future RFC MAY cross-validate against capabilities.supportedEnvelopes."
73
+ }
74
+ }
75
+ },
76
+ "tags": {
77
+ "type": "array",
78
+ "items": {
79
+ "type": "string",
80
+ "minLength": 1,
81
+ "maxLength": 64
82
+ },
83
+ "maxItems": 32,
84
+ "description": "Free-form classification labels. Used by authoring UIs to group templates; not normative."
85
+ },
86
+ "meta": {
87
+ "type": "object",
88
+ "additionalProperties": false,
89
+ "description": "Provenance + lifecycle metadata. Optional; hosts SHOULD populate it for any persistent storage. When `source: \"pack\"`, the host MUST populate `packName` + `packVersion` so clients can disambiguate templates that share a `templateId` across multiple installed packs (per RFC 0028 §B \"Conflict resolution\").",
90
+ "properties": {
91
+ "author": {
92
+ "type": "string",
93
+ "description": "Free-form author identifier (handle, email, etc.)."
94
+ },
95
+ "createdAt": {
96
+ "type": "string",
97
+ "format": "date-time",
98
+ "description": "ISO 8601 UTC timestamp of initial creation."
99
+ },
100
+ "updatedAt": {
101
+ "type": "string",
102
+ "format": "date-time",
103
+ "description": "ISO 8601 UTC timestamp of most recent update."
104
+ },
105
+ "source": {
106
+ "type": "string",
107
+ "enum": [
108
+ "host",
109
+ "pack",
110
+ "user"
111
+ ],
112
+ "description": "Provenance discriminator. `host`: ships with the host's built-in library; immutable. `pack`: installed via RFC 0028 prompt pack; immutable; MUST carry `packName` + `packVersion`. `user`: created at run time via mutating endpoints; mutable iff `capabilities.prompts.mutableLibrary: true`."
113
+ },
114
+ "packName": {
115
+ "type": "string",
116
+ "pattern": "^(core|vendor|community|private)\\.[a-z][a-z0-9_-]*(\\.[a-z][a-zA-Z0-9_-]*)+$",
117
+ "description": "RFC 0028 §C. When `source: \"pack\"`, the installed pack's `name` (matches `PromptPackManifest.name`). Required when `source: \"pack\"`; absent otherwise. Lets clients pass a structured `PromptRef` with `libraryId` set to this value to disambiguate templates that share a `templateId` across packs."
118
+ },
119
+ "packVersion": {
120
+ "type": "string",
121
+ "pattern": "^\\d+\\.\\d+\\.\\d+(?:-[0-9A-Za-z.-]+)?(?:\\+[0-9A-Za-z.-]+)?$",
122
+ "description": "RFC 0028 §C. When `source: \"pack\"`, the installed pack's `version`. Required when `source: \"pack\"`; absent otherwise."
123
+ }
124
+ },
125
+ "allOf": [
126
+ {
127
+ "if": {
128
+ "properties": {
129
+ "source": {
130
+ "const": "pack"
131
+ }
132
+ },
133
+ "required": [
134
+ "source"
135
+ ]
136
+ },
137
+ "then": {
138
+ "required": [
139
+ "source",
140
+ "packName",
141
+ "packVersion"
142
+ ]
143
+ }
144
+ }
145
+ ]
146
+ }
147
+ },
148
+ "$defs": {
149
+ "PromptVariable": {
150
+ "type": "object",
151
+ "additionalProperties": false,
152
+ "required": [
153
+ "name",
154
+ "type",
155
+ "required"
156
+ ],
157
+ "description": "Typed interpolation slot. Bindings are validated against this declaration before composition; unresolved required slots MUST fail the node with `prompt_variable_unresolved`. Variables sourced from `secret` MUST be redacted to `[REDACTED:<secretId>]` markers in observability output per SECURITY/threat-model-secret-leakage.md §SR-1.",
158
+ "properties": {
159
+ "name": {
160
+ "type": "string",
161
+ "pattern": "^[a-zA-Z_][a-zA-Z0-9_]{0,63}$",
162
+ "description": "Variable identifier. MUST match the `{{name}}` placeholder pattern in `text`. Pattern aligns with common templating engines (Mustache, Handlebars, Liquid) — no dashes, no dotted paths."
163
+ },
164
+ "type": {
165
+ "type": "string",
166
+ "enum": [
167
+ "string",
168
+ "number",
169
+ "boolean",
170
+ "array",
171
+ "object"
172
+ ],
173
+ "description": "JSON-Schema-style type hint. Hosts SHOULD validate the bound value's type against this declaration; type-mismatch MAY warn or fail per host policy (no normative MUST yet — see RFC 0027 §A)."
174
+ },
175
+ "required": {
176
+ "type": "boolean",
177
+ "description": "When true, an absent binding fails the node with `prompt_variable_unresolved`. When false, the variable renders as `defaultValue` (if present) or the empty string."
178
+ },
179
+ "source": {
180
+ "type": "string",
181
+ "enum": [
182
+ "input",
183
+ "variable",
184
+ "secret",
185
+ "context"
186
+ ],
187
+ "description": "Where the binding comes from. `input`: node input port. `variable`: run-scoped variable (`ctx.variables.get`). `secret`: BYOK secret reference — MUST be redacted in observability events per RFC 0027 §E. `context`: host-provided implicit context (current user id, run id, etc.). Default when omitted: `input`."
188
+ },
189
+ "extractPath": {
190
+ "type": "string",
191
+ "description": "JSONPath into the source. When omitted, the entire source value binds to `name`. Hosts that don't support JSONPath MAY treat this as opaque dotted-path and surface an `unsupported_extract_path` warning."
192
+ },
193
+ "defaultValue": {
194
+ "description": "Used when `required: false` and the source resolves to undefined. Any JSON-serializable value."
195
+ },
196
+ "description": {
197
+ "type": "string",
198
+ "maxLength": 500,
199
+ "description": "Human-readable explanation. Surfaced in authoring UIs."
200
+ }
201
+ }
202
+ }
203
+ },
204
+ "patternProperties": {
205
+ "^(openwop-|x-|vendor\\.)": {
206
+ "description": "Vendor / host extension escape hatch (RFC 0138; extended to this pack-authored document by RFC 0177 §C.2). A consumer that does not recognize one MUST ignore it."
207
+ }
208
+ }
209
+ }
@@ -0,0 +1,145 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openwop.dev/spec/v2/proposal.schema.json",
4
+ "title": "Proposal",
5
+ "description": "RFC 0096 §B. A reviewable-learning proposal — an INERT, draft-state reusable artifact (skill/pack/template/automation) the host synthesized from run/tool traces, that MUST NOT influence the resolution, planning, or execution of any run while in any state other than `applied`. Activation is delegated to RFC 0051 approval-gate or RFC 0049 RBAC (no new authorization path). On `apply` the installed artifact MUST byte-match the last-persisted `artifact` (no silent re-synthesis). `rationale` and `provenance.sourceRunIds` are SR-1 redaction-safe (no secrets/PII). Gated on the `agents.proposals` capability.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": [
9
+ "id",
10
+ "kind",
11
+ "state",
12
+ "artifact",
13
+ "provenance",
14
+ "owner",
15
+ "createdAt"
16
+ ],
17
+ "properties": {
18
+ "id": {
19
+ "type": "string",
20
+ "minLength": 1,
21
+ "description": "Host-assigned identifier, stable across revisions."
22
+ },
23
+ "kind": {
24
+ "type": "string",
25
+ "enum": [
26
+ "agent-pack",
27
+ "workflow-chain-pack",
28
+ "prompt-template",
29
+ "automation"
30
+ ],
31
+ "description": "The reusable artifact kind. `agent-pack` (RFC 0003), `workflow-chain-pack` (RFC 0013), `prompt-template` (RFC 0027), `automation` (RFC 0052 scheduled job)."
32
+ },
33
+ "state": {
34
+ "type": "string",
35
+ "enum": [
36
+ "draft",
37
+ "revised",
38
+ "applied",
39
+ "rejected",
40
+ "archived"
41
+ ],
42
+ "description": "Lifecycle state. Only `applied` may influence a run. `draft`/`revised` are inert; `rejected`/`archived` are terminal-inert."
43
+ },
44
+ "title": {
45
+ "type": "string",
46
+ "description": "Human-facing label. SR-1 redaction-safe."
47
+ },
48
+ "rationale": {
49
+ "type": "string",
50
+ "description": "Plain-language justification. SR-1 redaction-safe — no secrets/PII."
51
+ },
52
+ "artifact": {
53
+ "type": "object",
54
+ "description": "The proposed artifact, shaped by `kind` (an RFC 0003 pack manifest, an RFC 0013 chain pack, an RFC 0027 template, an RFC 0052 job spec). Inert until applied. Deliberately open (`additionalProperties` not constrained here) because the payload conforms to the kind's own existing schema, validated by the host at `apply` (malformed-for-kind ⇒ 422).",
55
+ "$comment": "Intentionally open object — the artifact body is validated against the kind's own schema, not this envelope.",
56
+ "additionalProperties": true
57
+ },
58
+ "provenance": {
59
+ "type": "object",
60
+ "additionalProperties": false,
61
+ "required": [
62
+ "sourceRunIds"
63
+ ],
64
+ "description": "Where the proposal came from.",
65
+ "properties": {
66
+ "sourceRunIds": {
67
+ "type": "array",
68
+ "items": {
69
+ "type": "string",
70
+ "minLength": 1
71
+ },
72
+ "description": "Runs whose traces produced this proposal (RFC 0040 causation-compatible). SR-1 redaction-safe."
73
+ },
74
+ "synthesizerModel": {
75
+ "type": "string",
76
+ "description": "Opaque identifier of the model/process that synthesized the draft."
77
+ }
78
+ }
79
+ },
80
+ "duplicateOf": {
81
+ "type": [
82
+ "string",
83
+ "null"
84
+ ],
85
+ "default": null,
86
+ "description": "Existing artifact ref this proposal restates/overlaps, when `agents.proposals.duplicationDetection` is on. `null` when unknown or detection is off."
87
+ },
88
+ "owner": {
89
+ "type": "object",
90
+ "additionalProperties": false,
91
+ "required": [
92
+ "tenant"
93
+ ],
94
+ "description": "RFC 0048 identity triple that owns this proposal. Redaction-safe — `principal` is an opaque id, never PII or credential material. Single-tenant hosts populate at least `tenant`.",
95
+ "properties": {
96
+ "tenant": {
97
+ "type": "string",
98
+ "minLength": 1,
99
+ "description": "Top-level isolation boundary."
100
+ },
101
+ "workspace": {
102
+ "type": "string",
103
+ "minLength": 1,
104
+ "description": "Optional sub-tenant within the tenant (RFC 0048 workspace)."
105
+ },
106
+ "principal": {
107
+ "type": "string",
108
+ "minLength": 1,
109
+ "description": "Acting identity (user or agent) — opaque id, never PII."
110
+ }
111
+ }
112
+ },
113
+ "activation": {
114
+ "type": [
115
+ "object",
116
+ "null"
117
+ ],
118
+ "default": null,
119
+ "description": "Populated only when `state: applied`: the RFC 0051 approval reference (if `activation = approval-gate`) and the resulting installed artifact ref.",
120
+ "additionalProperties": false,
121
+ "properties": {
122
+ "approvalId": {
123
+ "type": [
124
+ "string",
125
+ "null"
126
+ ],
127
+ "description": "RFC 0051 approval/gate id when activation routed through an approval gate."
128
+ },
129
+ "installedArtifactRef": {
130
+ "type": "string",
131
+ "description": "Ref of the artifact installed on `apply` (RFC 0043 install path)."
132
+ }
133
+ }
134
+ },
135
+ "createdAt": {
136
+ "type": "string",
137
+ "format": "date-time"
138
+ },
139
+ "updatedAt": {
140
+ "type": "string",
141
+ "format": "date-time"
142
+ }
143
+ },
144
+ "x-openwop-seeded-from": "v1"
145
+ }
@@ -0,0 +1,292 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openwop.dev/spec/v2/registry-version-manifest.schema.json",
4
+ "title": "RegistryVersionManifest",
5
+ "description": "Registry-augmented version manifest served at `/v1/packs/{name}/-/{version}.json`. Extends the bare pack manifest (`node-pack-manifest.schema.json`) with registry-side metadata (integrity hash, publishedAt timestamp, signed-blob URLs, lifecycle flags). This is the shape clients receive when they GET a specific pack version; the bare manifest is what publishers commit inside the tarball.\n\n**Why two schemas?** The bare manifest is the authoring contract — what a vendor writes in their pack source tree. The registry-augmented version is the SERVING contract — what `packs.openwop.dev` produces after `build-index.mjs` computes integrity hashes + adds URL templates. Validating both surfaces independently catches drift between authored content and served metadata.",
6
+ "type": "object",
7
+ "required": [
8
+ "engines",
9
+ "integrity",
10
+ "kind",
11
+ "name",
12
+ "version"
13
+ ],
14
+ "allOf": [
15
+ {
16
+ "$comment": "RFC 0107 — runtime is required for EXECUTABLE kinds (node, or kind absent) and MUST be absent for DECLARATIVE kinds (artifact-type, connection, workflow-chain, prompt, card, form-content). NOTE: the chat-card-pack kind string is `card` per RFC 0071 (corrected 2026-06-23; an earlier RFC 0107 draft said `chat-card`). `form-content` added by RFC 0137.",
17
+ "if": {
18
+ "properties": {
19
+ "kind": {
20
+ "enum": [
21
+ "artifact-type",
22
+ "connection",
23
+ "workflow-chain",
24
+ "prompt",
25
+ "card",
26
+ "form-content"
27
+ ]
28
+ }
29
+ },
30
+ "required": [
31
+ "kind"
32
+ ]
33
+ },
34
+ "then": {
35
+ "not": {
36
+ "required": [
37
+ "runtime"
38
+ ]
39
+ }
40
+ },
41
+ "else": {
42
+ "required": [
43
+ "runtime"
44
+ ]
45
+ }
46
+ }
47
+ ],
48
+ "properties": {
49
+ "name": {
50
+ "type": "string",
51
+ "description": "Reverse-DNS pack name. Mirrors `node-pack-manifest.schema.json` §name.",
52
+ "pattern": "^(core|vendor|community|private)\\.[a-z][a-z0-9_-]*(\\.[a-z][a-zA-Z0-9_-]*)+$",
53
+ "minLength": 1,
54
+ "maxLength": 256
55
+ },
56
+ "version": {
57
+ "type": "string",
58
+ "description": "Pack version per SemVer 2.0.0. Must match the URL path the manifest is served at.",
59
+ "pattern": "^\\d+\\.\\d+\\.\\d+(?:-[0-9A-Za-z.-]+)?(?:\\+[0-9A-Za-z.-]+)?$"
60
+ },
61
+ "description": {
62
+ "type": "string",
63
+ "maxLength": 1024
64
+ },
65
+ "author": {
66
+ "type": "string"
67
+ },
68
+ "license": {
69
+ "type": "string"
70
+ },
71
+ "homepage": {
72
+ "type": "string",
73
+ "format": "uri"
74
+ },
75
+ "repository": {
76
+ "type": "string",
77
+ "format": "uri"
78
+ },
79
+ "keywords": {
80
+ "type": "array",
81
+ "items": {
82
+ "type": "string",
83
+ "maxLength": 64
84
+ },
85
+ "maxItems": 50
86
+ },
87
+ "engines": {
88
+ "type": "object",
89
+ "additionalProperties": false,
90
+ "required": [
91
+ "openwop"
92
+ ],
93
+ "properties": {
94
+ "openwop": {
95
+ "type": "string",
96
+ "pattern": "^>=\\d+(\\.\\d+){0,2} <\\d+\\.0\\.0$",
97
+ "description": "RFC 0177 §A.1 — explicit upper bound required; an absent ceiling reads <2.0.0 on a v1 manifest."
98
+ }
99
+ }
100
+ },
101
+ "kind": {
102
+ "type": "string",
103
+ "enum": [
104
+ "node",
105
+ "artifact-type",
106
+ "connection",
107
+ "workflow-chain",
108
+ "prompt",
109
+ "card",
110
+ "form-content"
111
+ ],
112
+ "default": "node",
113
+ "description": "Pack-kind discriminator (RFC 0107). ABSENT ≡ `node` (the original, executable kind — backward compatible). Executable kinds (`node`) carry `runtime` + `nodes[]`/`agents[]`. DECLARATIVE kinds carry their own payload and NO `runtime`: `artifact-type` → `artifactTypes[]` (RFC 0075); `connection` → `provider` (RFC 0095); `workflow-chain` → `chains[]` (RFC 0013); `prompt` → `prompts[]`; `card` → `cards[]` (the chat-card pack, RFC 0071 — kind string is `card`, NOT `chat-card`; an earlier RFC 0107 draft used `chat-card`, corrected 2026-06-23); `form-content` → `templates[]` (RFC 0137). The registry's runtime-support check (registry-operations.md §Validation flow #7) is skipped for declarative kinds."
114
+ },
115
+ "artifactTypes": {
116
+ "type": "array",
117
+ "description": "Present iff `kind == \"artifact-type\"` (RFC 0075). Mirrors `artifact-type-pack-manifest.schema.json` `artifactTypes[]` (each: `artifactTypeId`, `title`, `schema`, `export[]`). Carried loosely here (the source schema is authoritative); the registry denormalizes `artifactTypes[].artifactTypeId` into the per-pack index for discovery.",
118
+ "items": {
119
+ "type": "object",
120
+ "additionalProperties": true
121
+ }
122
+ },
123
+ "provider": {
124
+ "type": "object",
125
+ "description": "Present iff `kind == \"connection\"` (RFC 0095). Mirrors `connection-pack-manifest.schema.json` `provider` (id, category, auth, reach, …). MUST NOT carry credential material (RFC 0095 §B.2 — enforced at source; a registry SHOULD re-scan). The registry denormalizes `provider.id` into the per-pack index.",
126
+ "additionalProperties": true
127
+ },
128
+ "chains": {
129
+ "type": "array",
130
+ "description": "Present iff `kind == \"workflow-chain\"` (RFC 0013). Carried loosely (the source schema is authoritative); the registry denormalizes `chains[].chainId` into the per-pack index.",
131
+ "items": {
132
+ "type": "object",
133
+ "additionalProperties": true
134
+ }
135
+ },
136
+ "prompts": {
137
+ "type": "array",
138
+ "description": "Present iff `kind == \"prompt\"`. Carried loosely; source schema authoritative.",
139
+ "items": {
140
+ "type": "object",
141
+ "additionalProperties": true
142
+ }
143
+ },
144
+ "cards": {
145
+ "type": "array",
146
+ "description": "Present iff `kind == \"card\"` (the chat-card pack, RFC 0071; the registry denormalizes `cards[].cardTypeId` into the per-pack index). Carried loosely; source schema authoritative.",
147
+ "items": {
148
+ "type": "object",
149
+ "additionalProperties": true
150
+ }
151
+ },
152
+ "templates": {
153
+ "type": "array",
154
+ "description": "Present iff `kind == \"form-content\"` (RFC 0137). Form templates the pack contributes (each: `templateId`, `version`, `label`, `title`, `fields[]`). Carried loosely here per the RFC 0107 G1 pattern — `form-content-pack-manifest.schema.json` is the authoritative source contract, and the registry denormalizes `templates[].templateId` into the per-pack index for discovery (`registry-operations.md` §\"Type-ID indexing\").",
155
+ "items": {
156
+ "type": "object",
157
+ "additionalProperties": true
158
+ }
159
+ },
160
+ "runtime": {
161
+ "type": "object",
162
+ "required": [
163
+ "language"
164
+ ],
165
+ "properties": {
166
+ "language": {
167
+ "type": "string",
168
+ "enum": [
169
+ "javascript",
170
+ "typescript",
171
+ "wasm",
172
+ "remote"
173
+ ],
174
+ "description": "Pack runtime. `javascript`/`typescript` for in-process Node executors; `wasm` for sandboxed WASM (RFC 0008 ABI); `remote` for agent-only packs that dispatch via remote LLM providers + don't ship local executor bytecode."
175
+ },
176
+ "entry": {
177
+ "type": "string"
178
+ },
179
+ "abiVersion": {
180
+ "type": "string"
181
+ }
182
+ },
183
+ "additionalProperties": false
184
+ },
185
+ "peerDependencies": {
186
+ "type": "object",
187
+ "description": "Host capabilities the pack consumes. Each key is a host-capability identifier (e.g., `host.canvas`); each value declares the support level the pack expects.",
188
+ "additionalProperties": {
189
+ "type": "string"
190
+ }
191
+ },
192
+ "dependencies": {
193
+ "type": "object",
194
+ "description": "Pack dependencies (other packs). Wire-locked at install time per `pack-lockfile.schema.json`.",
195
+ "additionalProperties": {
196
+ "type": "string"
197
+ }
198
+ },
199
+ "signing": {
200
+ "type": "object",
201
+ "additionalProperties": false,
202
+ "required": [
203
+ "keyId",
204
+ "scheme"
205
+ ],
206
+ "properties": {
207
+ "keyId": {
208
+ "$ref": "ids.schema.json#/$defs/keyId"
209
+ },
210
+ "scheme": {
211
+ "const": "ed25519-canonical-json",
212
+ "description": "RFC 0177 §C.3 — one scheme: a detached 64-byte Ed25519 signature over the canonical-JSON pack.json inside a deterministic tarball. method and publicKeyRef are gone."
213
+ }
214
+ },
215
+ "description": "RFC 0177 §C.3/§C.4."
216
+ },
217
+ "nodes": {
218
+ "type": "array",
219
+ "items": {
220
+ "type": "object",
221
+ "required": [
222
+ "typeId",
223
+ "version",
224
+ "category",
225
+ "role"
226
+ ],
227
+ "additionalProperties": true
228
+ }
229
+ },
230
+ "agents": {
231
+ "type": "array",
232
+ "items": {
233
+ "type": "object",
234
+ "additionalProperties": true
235
+ }
236
+ },
237
+ "integrity": {
238
+ "type": "string",
239
+ "description": "SRI-style integrity hash of the SIGNED tarball (`sha256-<base64(sha256)>`). Computed by `registry/scripts/build-index.mjs` from the on-disk `.tgz`. Consumers MUST verify the fetched tarball's hash matches this field before unpacking.",
240
+ "pattern": "^sha256-[A-Za-z0-9+/=]+$"
241
+ },
242
+ "publishedAt": {
243
+ "type": "string",
244
+ "description": "ISO-8601 UTC timestamp of first publish. Immutable per spec — set at first publish, never re-issued on subsequent index rebuilds.",
245
+ "format": "date-time"
246
+ },
247
+ "tarballUrl": {
248
+ "type": "string",
249
+ "description": "Registry-relative URL for the signed tarball. Always `/v1/packs/{name}/-/{version}.tgz`.",
250
+ "pattern": "^/v1/packs/[^/]+/-/[^/]+\\.tgz$"
251
+ },
252
+ "signatureUrl": {
253
+ "type": "string",
254
+ "description": "Registry-relative URL for the detached Ed25519 signature. Always `/v1/packs/{name}/-/{version}.sig`.",
255
+ "pattern": "^/v1/packs/[^/]+/-/[^/]+\\.sig$"
256
+ },
257
+ "yanked": {
258
+ "type": "boolean",
259
+ "description": "Hard refusal: this version was published in error. Registry MUST refuse to serve the tarball; consumers MUST refuse to dispatch nodes from yanked versions."
260
+ },
261
+ "yankedReason": {
262
+ "type": "string",
263
+ "maxLength": 512,
264
+ "description": "Optional one-line rationale shown by clients when a yanked install is attempted. Conventionally references the advisory id (`OPENWOP-YYYY-NNNN`) when one was issued."
265
+ },
266
+ "deprecationReason": {
267
+ "type": "string",
268
+ "maxLength": 512,
269
+ "description": "Optional one-line rationale shown by clients when an install of a deprecated version is attempted. Typically names the replacement version + migration link."
270
+ },
271
+ "supersededBy": {
272
+ "type": "string",
273
+ "maxLength": 256,
274
+ "description": "Optional pointer to the version (or `<name>@<version>`) that replaces this one. Per spec/v1/registry-operations.md, engine consumers in `open` / `verified` mode MUST surface this value in any deprecation warning when set."
275
+ },
276
+ "advisoryUrl": {
277
+ "type": "string",
278
+ "format": "uri",
279
+ "description": "Optional URL with deprecation / yank rationale + remediation."
280
+ },
281
+ "versionDeprecated": {
282
+ "type": "boolean",
283
+ "description": "Advisory: this version is deprecated. Consumers MAY refuse to install but registry continues to serve. Renamed from deprecated (RFC 0178 row C11.2; openwop.codemod.manifest-version-deprecated)."
284
+ }
285
+ },
286
+ "patternProperties": {
287
+ "^(openwop-|x-|vendor\\.)": {
288
+ "description": "Vendor / host extension escape hatch (RFC 0138). A property matching `^(x-|vendor\\.)` is a HOST EXTENSION: its semantics are unspecified by this protocol, and a consumer that does not recognize one MUST ignore it rather than reject the pack. Resolves the contradiction in `host-extensions.md` §\"Vendor-prefixed namespaces\", which requires a client receiving an unknown vendor-prefixed field to treat it as opaque — a field that `additionalProperties: false` previously made impossible to carry. SECURITY: an extension value is PACK-AUTHORED, therefore untrusted; \"ignore\" means ignore. This is the PUBLICATION contract: without the hatch here a pack carrying a root-level extension would validate against its source manifest and then be rejected at registry `PUT` — the same split-brain RFC 0138 exists to close. Per-item entry objects are already carried loosely (RFC 0107 G1), so this covers the root. See `node-packs.md` §\"Vendor extensions on pack manifests\" and the `pack-manifest-extension-opaque` invariant."
289
+ }
290
+ },
291
+ "additionalProperties": false
292
+ }
@@ -0,0 +1,19 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openwop.dev/spec/v2/residency.schema.json",
4
+ "title": "Residency",
5
+ "description": "RFC 0129 — an OPTIONAL data-residency constraint on a run-creation request (`POST /v1/runs`). A host advertising `capabilities.dataResidency` MUST honor-or-reject: accept iff `region` is in the advertised `dataResidency.regions[]`, else reject `residency_unavailable` (HTTP one-of 400/404/422) and create no run — it MUST NOT silently accept-and-ignore. Absent ⇒ no constraint (host default region). Physical byte-confinement of the accepted run is a declared operator SHOULD (RFC 0129 §4), not a wire guarantee.",
6
+ "type": "object",
7
+ "additionalProperties": false,
8
+ "required": [
9
+ "region"
10
+ ],
11
+ "properties": {
12
+ "region": {
13
+ "type": "string",
14
+ "minLength": 1,
15
+ "description": "Requested processing region — an opaque operator code from the host's own vocabulary (e.g. `\"eu\"`, `\"us\"`, `\"eu-west-1\"`). Honored only if present in the host's advertised `capabilities.dataResidency.regions[]`; otherwise the run is rejected `residency_unavailable`."
16
+ }
17
+ },
18
+ "x-openwop-seeded-from": "v1"
19
+ }