@openplanr/protocol 0.2.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 (334) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +82 -0
  3. package/lib/dashboard/closed-json-contract.mjs +141 -0
  4. package/lib/dashboard/generated/operate-experience-surface-schema-data.mjs +67 -0
  5. package/lib/dashboard/generated/operate-review-schema-data.mjs +35 -0
  6. package/lib/dashboard/generated/operate-schema-token-codec.mjs +127 -0
  7. package/lib/dashboard/operate-experience-audit-display-contract.d.mts +196 -0
  8. package/lib/dashboard/operate-experience-audit-display-contract.mjs +700 -0
  9. package/lib/dashboard/operate-experience-display-contract.d.mts +572 -0
  10. package/lib/dashboard/operate-experience-display-contract.mjs +1007 -0
  11. package/lib/dashboard/operate-experience-surface-contract.d.mts +157 -0
  12. package/lib/dashboard/operate-experience-surface-contract.mjs +91 -0
  13. package/lib/dashboard/operate-review-contract.d.mts +34 -0
  14. package/lib/dashboard/operate-review-contract.mjs +175 -0
  15. package/lib/dashboard/operate-review-display-workspace-contract.d.mts +54 -0
  16. package/lib/dashboard/operate-review-display-workspace-contract.mjs +258 -0
  17. package/lib/dashboard/operate-review-payload-safety.d.mts +7 -0
  18. package/lib/dashboard/operate-review-payload-safety.mjs +42 -0
  19. package/lib/dashboard/operate-review-workspace-projection-v2.d.mts +218 -0
  20. package/lib/protocol/index.d.ts +2638 -0
  21. package/package.json +115 -0
  22. package/registries/commands.json +1952 -0
  23. package/registries/diagram-grammars.json +2407 -0
  24. package/registries/diagram-semantic-patterns.json +111 -0
  25. package/registries/output-paths.json +40 -0
  26. package/registries/outputs.json +864 -0
  27. package/registries/roles.json +661 -0
  28. package/registries/rules.json +261 -0
  29. package/registries/skill-host-profiles.json +247 -0
  30. package/registries/skill-modules.json +1112 -0
  31. package/registries/skill-routing.json +389 -0
  32. package/registries/skills.json +1545 -0
  33. package/registries/task-kinds.json +220 -0
  34. package/registry/adapters.json +110 -0
  35. package/registry/artifact-theme.json +60 -0
  36. package/registry/evaluation-graders.json +303 -0
  37. package/registry/evaluation-host-profiles.json +131 -0
  38. package/registry/frozen-commands.json +15 -0
  39. package/registry/landing-operations.json +20 -0
  40. package/registry/landing-workflows.json +70 -0
  41. package/registry/live-evidence-providers.json +1 -0
  42. package/registry/operate-v2-contracts.json +5965 -0
  43. package/registry/professional-skills.json +115 -0
  44. package/registry/roles.json +14 -0
  45. package/registry/ship-review-specialists.json +42 -0
  46. package/schemas/v1.0.0/design-approved.schema.json +35 -0
  47. package/schemas/v1.0.0/design-feedback.schema.json +169 -0
  48. package/schemas/v1.0.0/design-manifest.schema.json +90 -0
  49. package/schemas/v1.0.0/design-session.schema.json +73 -0
  50. package/schemas/v1.0.0/graph.schema.json +100 -0
  51. package/schemas/v1.0.0/pipeline-shipped.schema.json +154 -0
  52. package/schemas/v1.0.0/run-manifest.schema.json +81 -0
  53. package/schemas/v1.0.0/spec.schema.json +120 -0
  54. package/schemas/v1.0.0/stack.schema.json +184 -0
  55. package/schemas/v1.0.0/story.schema.json +95 -0
  56. package/schemas/v1.0.0/task.schema.json +171 -0
  57. package/schemas/v1.0.0/taste-profile.schema.json +96 -0
  58. package/schemas/v1.1.0/adapter-registry.schema.json +72 -0
  59. package/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
  60. package/schemas/v1.1.0/artifact-paste.schema.json +49 -0
  61. package/schemas/v1.1.0/artifact-review.schema.json +97 -0
  62. package/schemas/v1.1.0/artifact-room-descriptor.schema.json +39 -0
  63. package/schemas/v1.1.0/artifact-room-event.schema.json +184 -0
  64. package/schemas/v1.1.0/artifact-room-signed-event.schema.json +58 -0
  65. package/schemas/v1.1.0/artifact-theme.schema.json +139 -0
  66. package/schemas/v1.1.0/browser-qa-gate.schema.json +21 -0
  67. package/schemas/v1.1.0/browser-qa-result.schema.json +24 -0
  68. package/schemas/v1.1.0/browser-qa-session.schema.json +12 -0
  69. package/schemas/v1.1.0/ecosystem-manifest.schema.json +46 -0
  70. package/schemas/v1.1.0/investigation-diagnosis.schema.json +12 -0
  71. package/schemas/v1.1.0/investigation-event.schema.json +15 -0
  72. package/schemas/v1.1.0/investigation-experiment.schema.json +17 -0
  73. package/schemas/v1.1.0/investigation-fix.schema.json +11 -0
  74. package/schemas/v1.1.0/investigation-hypothesis.schema.json +6 -0
  75. package/schemas/v1.1.0/investigation-observation.schema.json +10 -0
  76. package/schemas/v1.1.0/investigation-receipt.schema.json +7 -0
  77. package/schemas/v1.1.0/investigation-record.schema.json +7 -0
  78. package/schemas/v1.1.0/investigation-request.schema.json +34 -0
  79. package/schemas/v1.1.0/planning-review-event.schema.json +64 -0
  80. package/schemas/v1.1.0/planning-review-receipt.schema.json +19 -0
  81. package/schemas/v1.1.0/planning-review-record.schema.json +176 -0
  82. package/schemas/v1.1.0/planning-review-state.schema.json +19 -0
  83. package/schemas/v1.1.0/professional-skills.schema.json +105 -0
  84. package/schemas/v1.1.0/professional-specification.schema.json +111 -0
  85. package/schemas/v1.1.0/provenance-event.schema.json +82 -0
  86. package/schemas/v1.1.0/role-registry.schema.json +28 -0
  87. package/schemas/v1.1.0/runtime-lock.schema.json +39 -0
  88. package/schemas/v1.1.0/ship-closure.schema.json +353 -0
  89. package/schemas/v1.1.0/ship-review-specialist-registry.schema.json +29 -0
  90. package/schemas/v1.1.0/ship-risk-classification.schema.json +48 -0
  91. package/schemas/v1.1.0/specialist-review-result.schema.json +19 -0
  92. package/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
  93. package/schemas/v1.10.0/design-review-context.schema.json +191 -0
  94. package/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
  95. package/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
  96. package/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
  97. package/schemas/v1.12.0/enterprise-access-context.schema.json +217 -0
  98. package/schemas/v1.12.0/enterprise-agent-handoff.schema.json +508 -0
  99. package/schemas/v1.12.0/enterprise-artifact-revision.schema.json +87 -0
  100. package/schemas/v1.12.0/enterprise-change-proposal.schema.json +359 -0
  101. package/schemas/v1.12.0/enterprise-evidence-reference.schema.json +147 -0
  102. package/schemas/v1.12.0/enterprise-review-thread.schema.json +278 -0
  103. package/schemas/v1.12.0/enterprise-sync-state.schema.json +169 -0
  104. package/schemas/v1.2.0/adapter-registry.schema.json +83 -0
  105. package/schemas/v1.2.0/dashboard-bootstrap.schema.json +219 -0
  106. package/schemas/v1.2.0/ecosystem-release-operation.schema.json +90 -0
  107. package/schemas/v1.2.0/ecosystem-saga.schema.json +54 -0
  108. package/schemas/v1.2.0/evidence-diagnostic.schema.json +77 -0
  109. package/schemas/v1.2.0/guided-answer-envelope.schema.json +73 -0
  110. package/schemas/v1.2.0/guided-confirmation.schema.json +128 -0
  111. package/schemas/v1.2.0/guided-question.schema.json +242 -0
  112. package/schemas/v1.2.0/guided-questionnaire.schema.json +278 -0
  113. package/schemas/v1.2.0/guided-session.schema.json +141 -0
  114. package/schemas/v1.2.0/landing-confirmation.schema.json +17 -0
  115. package/schemas/v1.2.0/landing-event.schema.json +12 -0
  116. package/schemas/v1.2.0/landing-operation-registry.schema.json +16 -0
  117. package/schemas/v1.2.0/landing-phase-receipt.schema.json +19 -0
  118. package/schemas/v1.2.0/landing-plan.schema.json +36 -0
  119. package/schemas/v1.2.0/landing-receipt.schema.json +12 -0
  120. package/schemas/v1.2.0/landing-workflow-catalog.schema.json +143 -0
  121. package/schemas/v1.2.0/operate-action-display-workspace.schema.json +119 -0
  122. package/schemas/v1.2.0/operate-cycle-display-workspace.schema.json +109 -0
  123. package/schemas/v1.2.0/operate-executive-board-display-surface.schema.json +72 -0
  124. package/schemas/v1.2.0/operate-experience-audit-display-surface.schema.json +328 -0
  125. package/schemas/v1.2.0/operate-experience-display-surface.schema.json +46 -0
  126. package/schemas/v1.2.0/operate-experience-surface.schema.json +590 -0
  127. package/schemas/v1.2.0/operate-recovery-display-surface.schema.json +85 -0
  128. package/schemas/v1.2.0/structured-action.schema.json +91 -0
  129. package/schemas/v1.3.0/adapter-registry.schema.json +84 -0
  130. package/schemas/v1.3.0/ecosystem-manifest.schema.json +120 -0
  131. package/schemas/v1.3.0/release-compatibility-claim.schema.json +46 -0
  132. package/schemas/v1.3.0/release-ledger-receipt.schema.json +45 -0
  133. package/schemas/v1.3.0/release-ledger.schema.json +60 -0
  134. package/schemas/v1.4.0/adapter-registry.schema.json +62 -0
  135. package/schemas/v1.4.0/evaluation-aggregate-report.schema.json +166 -0
  136. package/schemas/v1.4.0/evaluation-budget.schema.json +49 -0
  137. package/schemas/v1.4.0/evaluation-corpus.schema.json +93 -0
  138. package/schemas/v1.4.0/evaluation-fixture.schema.json +64 -0
  139. package/schemas/v1.4.0/evaluation-gate-policy.schema.json +33 -0
  140. package/schemas/v1.4.0/evaluation-grader-registration.schema.json +141 -0
  141. package/schemas/v1.4.0/evaluation-grader-registry.schema.json +20 -0
  142. package/schemas/v1.4.0/evaluation-host-profile-registry.schema.json +20 -0
  143. package/schemas/v1.4.0/evaluation-host-profile.schema.json +73 -0
  144. package/schemas/v1.4.0/evaluation-observation.schema.json +76 -0
  145. package/schemas/v1.4.0/evaluation-run-result.schema.json +84 -0
  146. package/schemas/v1.4.0/evaluation-scenario.schema.json +231 -0
  147. package/schemas/v1.4.0/evaluation-waiver.schema.json +65 -0
  148. package/schemas/v1.4.0/skill-certification-receipt.schema.json +103 -0
  149. package/schemas/v1.5.0/command-catalog.schema.json +296 -0
  150. package/schemas/v1.5.0/common.schema.json +261 -0
  151. package/schemas/v1.5.0/generated-asset-manifest.schema.json +313 -0
  152. package/schemas/v1.5.0/implementation-result.schema.json +152 -0
  153. package/schemas/v1.5.0/migration-preservation-manifest.schema.json +749 -0
  154. package/schemas/v1.5.0/output-catalog.schema.json +210 -0
  155. package/schemas/v1.5.0/output-path-catalog.schema.json +81 -0
  156. package/schemas/v1.5.0/role-registry.schema.json +261 -0
  157. package/schemas/v1.5.0/rule-catalog.schema.json +130 -0
  158. package/schemas/v1.5.0/skill-catalog.schema.json +303 -0
  159. package/schemas/v1.5.0/task-kind-registry.schema.json +167 -0
  160. package/schemas/v1.5.0/task-manifest.schema.json +373 -0
  161. package/schemas/v1.5.0/task-output-manifest.schema.json +462 -0
  162. package/schemas/v1.6.0/common.schema.json +462 -0
  163. package/schemas/v1.6.0/diagram-consumer-reference.schema.json +167 -0
  164. package/schemas/v1.6.0/diagram-document.schema.json +699 -0
  165. package/schemas/v1.6.0/diagram-fidelity-report.schema.json +137 -0
  166. package/schemas/v1.6.0/diagram-manifest.schema.json +162 -0
  167. package/schemas/v1.6.0/diagram-quality-report.schema.json +148 -0
  168. package/schemas/v1.6.0/diagram-review-binding.schema.json +132 -0
  169. package/schemas/v1.6.0/diagram-semantic-pattern-registry.schema.json +90 -0
  170. package/schemas/v1.6.0/diagram-type-registry.schema.json +373 -0
  171. package/schemas/v1.6.0/generated-asset-manifest.schema.json +103 -0
  172. package/schemas/v1.6.0/skill-catalog.schema.json +84 -0
  173. package/schemas/v1.6.0/skill-completion-receipt.schema.json +72 -0
  174. package/schemas/v1.6.0/skill-consent-record.schema.json +74 -0
  175. package/schemas/v1.6.0/skill-host-profile-registry.schema.json +526 -0
  176. package/schemas/v1.6.0/skill-learning-record.schema.json +116 -0
  177. package/schemas/v1.6.0/skill-module-registry.schema.json +108 -0
  178. package/schemas/v1.6.0/skill-routing-registry.schema.json +93 -0
  179. package/schemas/v1.6.0/skill-session.schema.json +73 -0
  180. package/schemas/v1.6.0/skill-source.schema.json +169 -0
  181. package/schemas/v1.7.0/common.schema.json +464 -0
  182. package/schemas/v1.7.0/generated-asset-manifest.schema.json +103 -0
  183. package/schemas/v1.7.0/planning-id-sequence.schema.json +50 -0
  184. package/schemas/v1.7.0/request-authority.schema.json +71 -0
  185. package/schemas/v1.7.0/skill-catalog.schema.json +84 -0
  186. package/schemas/v1.7.0/skill-completion-receipt.schema.json +72 -0
  187. package/schemas/v1.7.0/skill-consent-record.schema.json +74 -0
  188. package/schemas/v1.7.0/skill-host-profile-registry.schema.json +526 -0
  189. package/schemas/v1.7.0/skill-learning-record.schema.json +116 -0
  190. package/schemas/v1.7.0/skill-module-registry.schema.json +108 -0
  191. package/schemas/v1.7.0/skill-routing-registry.schema.json +93 -0
  192. package/schemas/v1.7.0/skill-session.schema.json +73 -0
  193. package/schemas/v1.7.0/skill-source.schema.json +169 -0
  194. package/schemas/v1.7.0/spec.schema.json +117 -0
  195. package/schemas/v1.7.0/story.schema.json +107 -0
  196. package/schemas/v1.7.0/task.schema.json +217 -0
  197. package/schemas/v1.8.0/common.schema.json +96 -0
  198. package/schemas/v1.8.0/skill-package.schema.json +63 -0
  199. package/schemas/v1.8.0/utility-command-catalog.schema.json +82 -0
  200. package/schemas/v1.9.0/design-document.schema.json +306 -0
  201. package/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
  202. package/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
  203. package/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
  204. package/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
  205. package/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
  206. package/schemas/v2.0.0/agent-runtime-manifest.schema.json +59 -0
  207. package/schemas/v2.0.0/business-operating-snapshot-projection.schema.json +14 -0
  208. package/schemas/v2.0.0/operate-allowed-action.schema.json +181 -0
  209. package/schemas/v2.0.0/operate-api-envelope.schema.json +225 -0
  210. package/schemas/v2.0.0/operate-capability-provider-registration.schema.json +30 -0
  211. package/schemas/v2.0.0/operate-domain-registration.schema.json +284 -0
  212. package/schemas/v2.0.0/operate-evidence-provider-registration.schema.json +55 -0
  213. package/schemas/v2.0.0/operate-evidence-resolver-registration.schema.json +46 -0
  214. package/schemas/v2.0.0/operate-executor-registration.schema.json +27 -0
  215. package/schemas/v2.0.0/operate-experience-live-patch.schema.json +47 -0
  216. package/schemas/v2.0.0/operate-experience-preview.schema.json +51 -0
  217. package/schemas/v2.0.0/operate-experience-view.schema.json +281 -0
  218. package/schemas/v2.0.0/operate-live-evidence-provider-registration.schema.json +48 -0
  219. package/schemas/v2.0.0/operate-live-evidence-provider-registry.schema.json +17 -0
  220. package/schemas/v2.0.0/operate-metric-provider-registration.schema.json +12 -0
  221. package/schemas/v2.0.0/operate-policy-provider-registration.schema.json +33 -0
  222. package/schemas/v2.0.0/operate-review-bound-submission.schema.json +29 -0
  223. package/schemas/v2.0.0/operate-review-display-workspace.schema.json +390 -0
  224. package/schemas/v2.0.0/operate-snapshot-provider-registration.schema.json +16 -0
  225. package/schemas/v2.0.0/operate-tool-call.schema.json +172 -0
  226. package/schemas/v2.0.0/operate-verification-provider-registration.schema.json +12 -0
  227. package/schemas/v2.0.0/operating-action-policy.schema.json +31 -0
  228. package/schemas/v2.0.0/operating-action-verification-plan.schema.json +13 -0
  229. package/schemas/v2.0.0/operating-action.schema.json +86 -0
  230. package/schemas/v2.0.0/operating-advisor-result.schema.json +394 -0
  231. package/schemas/v2.0.0/operating-approval-record.schema.json +23 -0
  232. package/schemas/v2.0.0/operating-approval-requirement.schema.json +31 -0
  233. package/schemas/v2.0.0/operating-artifact.schema.json +52 -0
  234. package/schemas/v2.0.0/operating-assignment.schema.json +437 -0
  235. package/schemas/v2.0.0/operating-assumption.schema.json +16 -0
  236. package/schemas/v2.0.0/operating-capability-availability.schema.json +15 -0
  237. package/schemas/v2.0.0/operating-capability-grant.schema.json +14 -0
  238. package/schemas/v2.0.0/operating-challenger-review.schema.json +204 -0
  239. package/schemas/v2.0.0/operating-checkpoint.schema.json +43 -0
  240. package/schemas/v2.0.0/operating-claim.schema.json +17 -0
  241. package/schemas/v2.0.0/operating-connector-checkpoint.schema.json +28 -0
  242. package/schemas/v2.0.0/operating-context-capture.schema.json +74 -0
  243. package/schemas/v2.0.0/operating-cycle-input-binding.schema.json +30 -0
  244. package/schemas/v2.0.0/operating-cycle.schema.json +42 -0
  245. package/schemas/v2.0.0/operating-decision-ledger.schema.json +237 -0
  246. package/schemas/v2.0.0/operating-decision.schema.json +137 -0
  247. package/schemas/v2.0.0/operating-delivery-evidence.schema.json +46 -0
  248. package/schemas/v2.0.0/operating-delivery-route.schema.json +43 -0
  249. package/schemas/v2.0.0/operating-delta.schema.json +13 -0
  250. package/schemas/v2.0.0/operating-domain-projection.schema.json +15 -0
  251. package/schemas/v2.0.0/operating-event-trigger.schema.json +11 -0
  252. package/schemas/v2.0.0/operating-event.schema.json +505 -0
  253. package/schemas/v2.0.0/operating-evidence-candidate.schema.json +88 -0
  254. package/schemas/v2.0.0/operating-evidence-edge.schema.json +39 -0
  255. package/schemas/v2.0.0/operating-evidence-graph.schema.json +25 -0
  256. package/schemas/v2.0.0/operating-evidence-observation.schema.json +48 -0
  257. package/schemas/v2.0.0/operating-evidence-ref.schema.json +51 -0
  258. package/schemas/v2.0.0/operating-evidence-resolution.schema.json +54 -0
  259. package/schemas/v2.0.0/operating-execution-result.schema.json +23 -0
  260. package/schemas/v2.0.0/operating-executive-board.schema.json +78 -0
  261. package/schemas/v2.0.0/operating-finding.schema.json +116 -0
  262. package/schemas/v2.0.0/operating-governed-operation.schema.json +54 -0
  263. package/schemas/v2.0.0/operating-intelligence-input-bundle.schema.json +128 -0
  264. package/schemas/v2.0.0/operating-intelligence-plan.schema.json +302 -0
  265. package/schemas/v2.0.0/operating-learning-receipt.schema.json +31 -0
  266. package/schemas/v2.0.0/operating-learning.schema.json +13 -0
  267. package/schemas/v2.0.0/operating-live-evidence-consent-record.schema.json +42 -0
  268. package/schemas/v2.0.0/operating-live-evidence-ingestion.schema.json +31 -0
  269. package/schemas/v2.0.0/operating-measurement-plan.schema.json +18 -0
  270. package/schemas/v2.0.0/operating-measurement-schedule-receipt.schema.json +7 -0
  271. package/schemas/v2.0.0/operating-measurement-schedule.schema.json +16 -0
  272. package/schemas/v2.0.0/operating-metric-observation.schema.json +15 -0
  273. package/schemas/v2.0.0/operating-metric.schema.json +18 -0
  274. package/schemas/v2.0.0/operating-model-state.schema.json +36 -0
  275. package/schemas/v2.0.0/operating-objective.schema.json +21 -0
  276. package/schemas/v2.0.0/operating-origin.schema.json +31 -0
  277. package/schemas/v2.0.0/operating-outcome-evaluation.schema.json +46 -0
  278. package/schemas/v2.0.0/operating-outcome.schema.json +13 -0
  279. package/schemas/v2.0.0/operating-planning-proposal.schema.json +45 -0
  280. package/schemas/v2.0.0/operating-policy-evaluation.schema.json +28 -0
  281. package/schemas/v2.0.0/operating-review-read.schema.json +217 -0
  282. package/schemas/v2.0.0/operating-review-receipt.schema.json +64 -0
  283. package/schemas/v2.0.0/operating-review.schema.json +47 -0
  284. package/schemas/v2.0.0/operating-risk.schema.json +96 -0
  285. package/schemas/v2.0.0/operating-rollback-plan.schema.json +10 -0
  286. package/schemas/v2.0.0/operating-rollback-result.schema.json +20 -0
  287. package/schemas/v2.0.0/operating-runtime-state.schema.json +289 -0
  288. package/schemas/v2.0.0/operating-scenario.schema.json +13 -0
  289. package/schemas/v2.0.0/operating-snapshot.schema.json +38 -0
  290. package/schemas/v2.0.0/operating-submission.schema.json +34 -0
  291. package/schemas/v2.0.0/operating-trace-matrix.schema.json +176 -0
  292. package/schemas/v2.0.0/operating-work-change-set.schema.json +89 -0
  293. package/schemas/v2.0.0/operating-work-ledger.schema.json +40 -0
  294. package/schemas/v2.0.0/software-operating-snapshot-projection.schema.json +14 -0
  295. package/src/browser-contracts.d.mts +5 -0
  296. package/src/browser-contracts.mjs +40 -0
  297. package/src/canonical-json.d.mts +5 -0
  298. package/src/canonical-json.mjs +142 -0
  299. package/src/compat/live-evidence-v2.mjs +1019 -0
  300. package/src/compat/operate-experience-live-patch.mjs +66 -0
  301. package/src/compat/operating-planning-contracts.mjs +114 -0
  302. package/src/contracts.d.mts +42 -0
  303. package/src/contracts.mjs +990 -0
  304. package/src/design-contracts.d.mts +62 -0
  305. package/src/design-contracts.mjs +186 -0
  306. package/src/design-publication-contracts.d.mts +4 -0
  307. package/src/design-publication-contracts.mjs +85 -0
  308. package/src/diagram-contracts.d.mts +19 -0
  309. package/src/diagram-contracts.mjs +28 -0
  310. package/src/enterprise-contracts.d.mts +107 -0
  311. package/src/enterprise-contracts.mjs +463 -0
  312. package/src/errors.d.mts +11 -0
  313. package/src/errors.mjs +109 -0
  314. package/src/generated/canonical-registries.mjs +5554 -0
  315. package/src/generated/contract-catalog-v2.mjs +7076 -0
  316. package/src/generated/diagram-registries.mjs +2529 -0
  317. package/src/index.d.mts +10 -0
  318. package/src/index.mjs +40 -0
  319. package/src/json-schema.d.mts +7 -0
  320. package/src/json-schema.mjs +283 -0
  321. package/src/planning-contracts.d.mts +10 -0
  322. package/src/planning-contracts.mjs +53 -0
  323. package/src/registries.d.mts +40 -0
  324. package/src/registries.mjs +261 -0
  325. package/src/review-experience-contracts.d.mts +11 -0
  326. package/src/review-experience-contracts.mjs +103 -0
  327. package/src/semver.d.mts +2 -0
  328. package/src/semver.mjs +7 -0
  329. package/src/skill-source-contracts.d.mts +25 -0
  330. package/src/skill-source-contracts.mjs +105 -0
  331. package/src/task-contracts.d.mts +7 -0
  332. package/src/task-contracts.mjs +130 -0
  333. package/src/workspace-contracts.d.mts +26 -0
  334. package/src/workspace-contracts.mjs +83 -0
@@ -0,0 +1,394 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openplanr.dev/schemas/v2.0.0/operating-advisor-result.schema.json",
4
+ "x-openplanr-contract": { "id": "operating-advisor-result", "version": "2.0.0" },
5
+ "title": "OpenPlanr Operate 2.0 advisor result",
6
+ "description": "A closed, evidence-linked professional analysis produced by one exact Advisor Assignment.",
7
+ "type": "object",
8
+ "additionalProperties": false,
9
+ "required": [
10
+ "kind", "schemaVersion", "protocolVersion", "assignmentId", "roleId", "roleVersion",
11
+ "analysisProfile", "intelligencePlanId", "snapshotId", "scopeId", "domainId", "domainVersion",
12
+ "outcome", "summary", "analysisMarkdown", "inputAbsenceIds", "analysis", "claims",
13
+ "measurements", "risks", "alternatives", "gaps", "recommendation"
14
+ ],
15
+ "properties": {
16
+ "kind": { "const": "operating-advisor-result" },
17
+ "schemaVersion": { "const": "1.0.0" },
18
+ "protocolVersion": { "const": "2.0.0" },
19
+ "assignmentId": { "$ref": "#/$defs/assignmentId" },
20
+ "roleId": { "$ref": "#/$defs/identifier" },
21
+ "roleVersion": { "$ref": "#/$defs/version" },
22
+ "analysisProfile": { "$ref": "#/$defs/analysisProfile" },
23
+ "intelligencePlanId": { "$ref": "#/$defs/planId" },
24
+ "snapshotId": { "$ref": "#/$defs/snapshotId" },
25
+ "scopeId": { "$ref": "#/$defs/id" },
26
+ "domainId": { "$ref": "#/$defs/identifier" },
27
+ "domainVersion": { "$ref": "#/$defs/version" },
28
+ "outcome": { "enum": ["recommendation", "partial", "quiet"] },
29
+ "summary": { "$ref": "#/$defs/text" },
30
+ "analysisMarkdown": { "$ref": "#/$defs/analysisMarkdown" },
31
+ "inputAbsenceIds": { "$ref": "#/$defs/absenceIds" },
32
+ "analysis": { "$ref": "#/$defs/profileAnalysis" },
33
+ "claims": { "type": "array", "maxItems": 128, "items": { "$ref": "#/$defs/claim" } },
34
+ "measurements": { "type": "array", "maxItems": 128, "items": { "$ref": "#/$defs/measurement" } },
35
+ "risks": { "type": "array", "maxItems": 128, "items": { "$ref": "#/$defs/risk" } },
36
+ "alternatives": { "type": "array", "maxItems": 64, "items": { "$ref": "#/$defs/alternative" } },
37
+ "gaps": { "type": "array", "maxItems": 128, "items": { "$ref": "#/$defs/gap" } },
38
+ "recommendation": { "oneOf": [{ "type": "null" }, { "$ref": "#/$defs/recommendation" }] }
39
+ },
40
+ "allOf": [
41
+ {
42
+ "if": { "properties": { "outcome": { "const": "recommendation" } }, "required": ["outcome"] },
43
+ "then": { "properties": { "claims": { "minItems": 1 }, "recommendation": { "$ref": "#/$defs/recommendation" } } }
44
+ },
45
+ {
46
+ "if": { "properties": { "outcome": { "enum": ["partial", "quiet"] } }, "required": ["outcome"] },
47
+ "then": { "properties": { "recommendation": { "type": "null" } } }
48
+ },
49
+ {
50
+ "if": { "properties": { "analysisProfile": { "properties": { "id": { "const": "strategy-finance" } }, "required": ["id"] } }, "required": ["analysisProfile"] },
51
+ "then": { "properties": { "analysis": { "$ref": "#/$defs/strategyFinanceAnalysis" } } }
52
+ },
53
+ {
54
+ "if": { "properties": { "analysisProfile": { "properties": { "id": { "const": "technology-risk" } }, "required": ["id"] } }, "required": ["analysisProfile"] },
55
+ "then": { "properties": { "analysis": { "$ref": "#/$defs/technologyRiskAnalysis" } } }
56
+ },
57
+ {
58
+ "if": { "properties": { "analysisProfile": { "properties": { "id": { "const": "product-activation" } }, "required": ["id"] } }, "required": ["analysisProfile"] },
59
+ "then": { "properties": { "analysis": { "$ref": "#/$defs/productActivationAnalysis" } } }
60
+ },
61
+ {
62
+ "if": { "properties": { "analysisProfile": { "properties": { "id": { "const": "growth-market" } }, "required": ["id"] } }, "required": ["analysisProfile"] },
63
+ "then": { "properties": { "analysis": { "$ref": "#/$defs/growthMarketAnalysis" } } }
64
+ },
65
+ {
66
+ "if": { "properties": { "analysisProfile": { "properties": { "id": { "const": "operations-customer" } }, "required": ["id"] } }, "required": ["analysisProfile"] },
67
+ "then": { "properties": { "analysis": { "$ref": "#/$defs/operationsCustomerAnalysis" } } }
68
+ },
69
+ {
70
+ "if": { "properties": { "analysisProfile": { "properties": { "id": { "const": "software-delivery" } }, "required": ["id"] } }, "required": ["analysisProfile"] },
71
+ "then": { "properties": { "analysis": { "$ref": "#/$defs/softwareDeliveryAnalysis" } } }
72
+ }
73
+ ],
74
+ "$defs": {
75
+ "id": { "type": "string", "minLength": 1, "maxLength": 128 },
76
+ "identifier": { "type": "string", "pattern": "^[a-z][a-z0-9]*(?:-[a-z0-9]+)*$" },
77
+ "version": { "type": "string", "pattern": "^(?:0|[1-9][0-9]*)\\.(?:0|[1-9][0-9]*)\\.(?:0|[1-9][0-9]*)$" },
78
+ "assignmentId": { "type": "string", "pattern": "^asg_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
79
+ "planId": { "type": "string", "pattern": "^ipl_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
80
+ "snapshotId": { "type": "string", "pattern": "^snp_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
81
+ "evidenceRefId": { "type": "string", "pattern": "^evr_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
82
+ "assumptionId": { "type": "string", "pattern": "^asm_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
83
+ "absenceId": { "type": "string", "pattern": "^abs_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
84
+ "claimId": { "type": "string", "pattern": "^claim:asg_[A-Za-z0-9][A-Za-z0-9._-]{7,127}:[1-9][0-9]*$" },
85
+ "measurementId": { "type": "string", "pattern": "^measurement:asg_[A-Za-z0-9][A-Za-z0-9._-]{7,127}:[1-9][0-9]*$" },
86
+ "analysisId": { "type": "string", "pattern": "^analysis:asg_[A-Za-z0-9][A-Za-z0-9._-]{7,127}:[1-9][0-9]*$" },
87
+ "riskId": { "type": "string", "pattern": "^risk:asg_[A-Za-z0-9][A-Za-z0-9._-]{7,127}:[1-9][0-9]*$" },
88
+ "alternativeId": { "type": "string", "pattern": "^alternative:asg_[A-Za-z0-9][A-Za-z0-9._-]{7,127}:[1-9][0-9]*$" },
89
+ "gapId": { "type": "string", "pattern": "^gap:asg_[A-Za-z0-9][A-Za-z0-9._-]{7,127}:[1-9][0-9]*$" },
90
+ "recommendationId": { "type": "string", "pattern": "^recommendation:asg_[A-Za-z0-9][A-Za-z0-9._-]{7,127}:1$" },
91
+ "text": { "type": "string", "minLength": 1, "maxLength": 4096, "pattern": "^[\\s\\S]*\\S[\\s\\S]*$" },
92
+ "title": { "type": "string", "minLength": 1, "maxLength": 256, "pattern": "^\\S(?:[\\s\\S]*\\S)?$", "not": { "pattern": "(?:<[^>]+>|\\{\\{[^}]+\\}\\})" } },
93
+ "analysisMarkdown": { "type": "string", "minLength": 1, "maxLength": 32768, "pattern": "^[\\s\\S]*\\S[\\s\\S]*$" },
94
+ "evidenceRefIds": { "type": "array", "maxItems": 128, "uniqueItems": true, "items": { "$ref": "#/$defs/evidenceRefId" } },
95
+ "assumptionIds": { "type": "array", "maxItems": 128, "uniqueItems": true, "items": { "$ref": "#/$defs/assumptionId" } },
96
+ "absenceIds": { "type": "array", "maxItems": 128, "uniqueItems": true, "items": { "$ref": "#/$defs/absenceId" } },
97
+ "claimIds": { "type": "array", "maxItems": 128, "uniqueItems": true, "items": { "$ref": "#/$defs/claimId" } },
98
+ "measurementIds": { "type": "array", "maxItems": 128, "uniqueItems": true, "items": { "$ref": "#/$defs/measurementId" } },
99
+ "riskIds": { "type": "array", "maxItems": 128, "uniqueItems": true, "items": { "$ref": "#/$defs/riskId" } },
100
+ "alternativeIds": { "type": "array", "maxItems": 64, "uniqueItems": true, "items": { "$ref": "#/$defs/alternativeId" } },
101
+ "analysisProfile": {
102
+ "type": "object", "additionalProperties": false, "required": ["id", "version", "questionIds"],
103
+ "properties": {
104
+ "id": { "enum": ["strategy-finance", "technology-risk", "product-activation", "growth-market", "operations-customer", "software-delivery"] },
105
+ "version": { "const": "1.0.0" },
106
+ "questionIds": { "type": "array", "minItems": 1, "maxItems": 16, "uniqueItems": true, "items": { "$ref": "#/$defs/identifier" } }
107
+ }
108
+ },
109
+ "questionAnswer": {
110
+ "type": "object", "additionalProperties": false,
111
+ "required": ["questionId", "answer", "claimIds", "measurementIds", "riskIds", "evidenceRefIds", "absenceIds"],
112
+ "properties": {
113
+ "questionId": { "$ref": "#/$defs/identifier" },
114
+ "answer": { "$ref": "#/$defs/text" },
115
+ "claimIds": { "$ref": "#/$defs/claimIds" },
116
+ "measurementIds": { "$ref": "#/$defs/measurementIds" },
117
+ "riskIds": { "$ref": "#/$defs/riskIds" },
118
+ "evidenceRefIds": { "$ref": "#/$defs/evidenceRefIds" },
119
+ "absenceIds": { "$ref": "#/$defs/absenceIds" }
120
+ },
121
+ "anyOf": [
122
+ { "properties": { "claimIds": { "minItems": 1 } } },
123
+ { "properties": { "measurementIds": { "minItems": 1 } } },
124
+ { "properties": { "riskIds": { "minItems": 1 } } },
125
+ { "properties": { "evidenceRefIds": { "minItems": 1 } } },
126
+ { "properties": { "absenceIds": { "minItems": 1 } } }
127
+ ]
128
+ },
129
+ "profileInsight": {
130
+ "type": "object", "additionalProperties": false,
131
+ "required": ["localAnalysisId", "title", "statement", "claimIds", "measurementIds", "riskIds", "alternativeIds", "evidenceRefIds", "absenceIds"],
132
+ "properties": {
133
+ "localAnalysisId": { "$ref": "#/$defs/analysisId" },
134
+ "title": { "$ref": "#/$defs/title" },
135
+ "statement": { "$ref": "#/$defs/text" },
136
+ "claimIds": { "$ref": "#/$defs/claimIds" },
137
+ "measurementIds": { "$ref": "#/$defs/measurementIds" },
138
+ "riskIds": { "$ref": "#/$defs/riskIds" },
139
+ "alternativeIds": { "$ref": "#/$defs/alternativeIds" },
140
+ "evidenceRefIds": { "$ref": "#/$defs/evidenceRefIds" },
141
+ "absenceIds": { "$ref": "#/$defs/absenceIds" }
142
+ },
143
+ "anyOf": [
144
+ { "properties": { "claimIds": { "minItems": 1 } } },
145
+ { "properties": { "measurementIds": { "minItems": 1 } } },
146
+ { "properties": { "riskIds": { "minItems": 1 } } },
147
+ { "properties": { "alternativeIds": { "minItems": 1 } } },
148
+ { "properties": { "evidenceRefIds": { "minItems": 1 } } },
149
+ { "properties": { "absenceIds": { "minItems": 1 } } }
150
+ ]
151
+ },
152
+ "profileInsightList": { "type": "array", "maxItems": 32, "items": { "$ref": "#/$defs/profileInsight" } },
153
+ "questionAnswers": { "type": "array", "minItems": 1, "maxItems": 16, "items": { "$ref": "#/$defs/questionAnswer" } },
154
+ "strategyFinanceAnalysis": {
155
+ "type": "object", "additionalProperties": false,
156
+ "required": ["profileId", "executiveQuestionAnswers", "directionChanges", "capitalAllocations", "financialScenarios", "costOfDelay"],
157
+ "properties": {
158
+ "profileId": { "const": "strategy-finance" },
159
+ "executiveQuestionAnswers": { "$ref": "#/$defs/questionAnswers" },
160
+ "directionChanges": { "$ref": "#/$defs/profileInsightList" },
161
+ "capitalAllocations": { "$ref": "#/$defs/profileInsightList" },
162
+ "financialScenarios": { "$ref": "#/$defs/profileInsightList" },
163
+ "costOfDelay": { "oneOf": [{ "type": "null" }, { "$ref": "#/$defs/profileInsight" }] }
164
+ }
165
+ },
166
+ "technologyRiskAnalysis": {
167
+ "type": "object", "additionalProperties": false,
168
+ "required": ["profileId", "executiveQuestionAnswers", "objectiveConstraints", "riskPortfolio", "implicitArchitectureDecisions", "riskiestChange"],
169
+ "properties": {
170
+ "profileId": { "const": "technology-risk" },
171
+ "executiveQuestionAnswers": { "$ref": "#/$defs/questionAnswers" },
172
+ "objectiveConstraints": { "$ref": "#/$defs/profileInsightList" },
173
+ "riskPortfolio": { "$ref": "#/$defs/profileInsightList" },
174
+ "implicitArchitectureDecisions": { "$ref": "#/$defs/profileInsightList" },
175
+ "riskiestChange": { "oneOf": [{ "type": "null" }, { "$ref": "#/$defs/profileInsight" }] }
176
+ }
177
+ },
178
+ "productActivationAnalysis": {
179
+ "type": "object", "additionalProperties": false,
180
+ "required": ["profileId", "executiveQuestionAnswers", "activationGaps", "unvalidatedBets", "orderedCuts", "acceptanceCriteriaFindings"],
181
+ "properties": {
182
+ "profileId": { "const": "product-activation" },
183
+ "executiveQuestionAnswers": { "$ref": "#/$defs/questionAnswers" },
184
+ "activationGaps": { "$ref": "#/$defs/profileInsightList" },
185
+ "unvalidatedBets": { "$ref": "#/$defs/profileInsightList" },
186
+ "orderedCuts": { "$ref": "#/$defs/profileInsightList" },
187
+ "acceptanceCriteriaFindings": { "$ref": "#/$defs/profileInsightList" }
188
+ }
189
+ },
190
+ "growthMarketAnalysis": {
191
+ "type": "object", "additionalProperties": false,
192
+ "required": ["profileId", "executiveQuestionAnswers", "demandChanges", "channelEconomics", "positioningClaims", "growthLoops"],
193
+ "properties": {
194
+ "profileId": { "const": "growth-market" },
195
+ "executiveQuestionAnswers": { "$ref": "#/$defs/questionAnswers" },
196
+ "demandChanges": { "$ref": "#/$defs/profileInsightList" },
197
+ "channelEconomics": { "$ref": "#/$defs/profileInsightList" },
198
+ "positioningClaims": { "$ref": "#/$defs/profileInsightList" },
199
+ "growthLoops": { "$ref": "#/$defs/profileInsightList" }
200
+ }
201
+ },
202
+ "operationsCustomerAnalysis": {
203
+ "type": "object", "additionalProperties": false,
204
+ "required": ["profileId", "executiveQuestionAnswers", "deliveryCapacity", "customerHealth", "singlePointsOfFailure", "renegotiations"],
205
+ "properties": {
206
+ "profileId": { "const": "operations-customer" },
207
+ "executiveQuestionAnswers": { "$ref": "#/$defs/questionAnswers" },
208
+ "deliveryCapacity": { "$ref": "#/$defs/profileInsightList" },
209
+ "customerHealth": { "$ref": "#/$defs/profileInsightList" },
210
+ "singlePointsOfFailure": { "$ref": "#/$defs/profileInsightList" },
211
+ "renegotiations": { "$ref": "#/$defs/profileInsightList" }
212
+ }
213
+ },
214
+ "softwareDeliveryAnalysis": {
215
+ "type": "object", "additionalProperties": false,
216
+ "required": ["profileId", "executiveQuestionAnswers", "changeSurface", "implementationRisks", "implementationAlternatives", "verificationGaps"],
217
+ "properties": {
218
+ "profileId": { "const": "software-delivery" },
219
+ "executiveQuestionAnswers": { "$ref": "#/$defs/questionAnswers" },
220
+ "changeSurface": { "$ref": "#/$defs/profileInsightList" },
221
+ "implementationRisks": { "$ref": "#/$defs/profileInsightList" },
222
+ "implementationAlternatives": { "$ref": "#/$defs/profileInsightList" },
223
+ "verificationGaps": { "$ref": "#/$defs/profileInsightList" }
224
+ }
225
+ },
226
+ "profileAnalysis": {
227
+ "oneOf": [
228
+ { "$ref": "#/$defs/strategyFinanceAnalysis" },
229
+ { "$ref": "#/$defs/technologyRiskAnalysis" },
230
+ { "$ref": "#/$defs/productActivationAnalysis" },
231
+ { "$ref": "#/$defs/growthMarketAnalysis" },
232
+ { "$ref": "#/$defs/operationsCustomerAnalysis" },
233
+ { "$ref": "#/$defs/softwareDeliveryAnalysis" }
234
+ ]
235
+ },
236
+ "claim": {
237
+ "type": "object", "additionalProperties": false,
238
+ "required": ["localClaimId", "statement", "epistemicStatus", "confidence", "supportingEvidenceRefIds", "contradictingEvidenceRefIds", "assumptionIds", "changeCondition"],
239
+ "properties": {
240
+ "localClaimId": { "$ref": "#/$defs/claimId" }, "statement": { "$ref": "#/$defs/text" },
241
+ "epistemicStatus": { "enum": ["known", "strongly-supported", "probable", "speculative", "unknown"] },
242
+ "confidence": { "type": "number", "minimum": 0, "maximum": 1 },
243
+ "supportingEvidenceRefIds": { "$ref": "#/$defs/evidenceRefIds" },
244
+ "contradictingEvidenceRefIds": { "$ref": "#/$defs/evidenceRefIds" },
245
+ "assumptionIds": { "$ref": "#/$defs/assumptionIds" }, "changeCondition": { "$ref": "#/$defs/text" }
246
+ },
247
+ "allOf": [
248
+ {
249
+ "anyOf": [
250
+ { "properties": { "supportingEvidenceRefIds": { "minItems": 1 } } },
251
+ { "properties": { "contradictingEvidenceRefIds": { "minItems": 1 } } },
252
+ { "properties": { "assumptionIds": { "minItems": 1 } } }
253
+ ]
254
+ },
255
+ {
256
+ "if": { "properties": { "epistemicStatus": { "enum": ["known", "strongly-supported", "probable"] } }, "required": ["epistemicStatus"] },
257
+ "then": { "anyOf": [{ "properties": { "supportingEvidenceRefIds": { "minItems": 1 } } }, { "properties": { "contradictingEvidenceRefIds": { "minItems": 1 } } }] }
258
+ }
259
+ ]
260
+ },
261
+ "measurementBase": {
262
+ "type": "object",
263
+ "required": ["localMeasurementId", "kind", "name", "period", "evidenceRefIds", "interpretation", "confidence"],
264
+ "properties": {
265
+ "localMeasurementId": { "$ref": "#/$defs/measurementId" },
266
+ "kind": { "enum": ["runway", "margin", "funnel", "channel-economics", "capacity", "throughput", "exposure", "scenario", "metric-trend"] },
267
+ "name": { "$ref": "#/$defs/title" },
268
+ "period": { "$ref": "#/$defs/text" },
269
+ "evidenceRefIds": { "allOf": [{ "$ref": "#/$defs/evidenceRefIds" }, { "minItems": 1 }] },
270
+ "interpretation": { "$ref": "#/$defs/text" },
271
+ "confidence": { "type": "number", "minimum": 0, "maximum": 1 }
272
+ }
273
+ },
274
+ "runwayMeasurement": {
275
+ "allOf": [
276
+ { "$ref": "#/$defs/measurementBase" },
277
+ { "type": "object", "required": ["currency", "cashBalance", "netBurnPerPeriod", "runwayPeriods"], "properties": { "kind": { "const": "runway" }, "currency": { "$ref": "#/$defs/id" }, "cashBalance": { "type": "number" }, "netBurnPerPeriod": { "type": "number", "exclusiveMinimum": 0 }, "runwayPeriods": { "type": "number", "minimum": 0 } } }
278
+ ],
279
+ "unevaluatedProperties": false
280
+ },
281
+ "marginMeasurement": {
282
+ "allOf": [
283
+ { "$ref": "#/$defs/measurementBase" },
284
+ { "type": "object", "required": ["currency", "revenue", "cost", "marginAmount", "marginRate"], "properties": { "kind": { "const": "margin" }, "currency": { "$ref": "#/$defs/id" }, "revenue": { "type": "number" }, "cost": { "type": "number" }, "marginAmount": { "type": "number" }, "marginRate": { "type": "number", "minimum": -1, "maximum": 1 } } }
285
+ ],
286
+ "unevaluatedProperties": false
287
+ },
288
+ "funnelMeasurement": {
289
+ "allOf": [
290
+ { "$ref": "#/$defs/measurementBase" },
291
+ { "type": "object", "required": ["stages"], "properties": { "kind": { "const": "funnel" }, "stages": { "type": "array", "minItems": 2, "maxItems": 32, "items": { "type": "object", "additionalProperties": false, "required": ["stage", "entered", "advanced", "conversionRate"], "properties": { "stage": { "$ref": "#/$defs/title" }, "entered": { "type": "number", "minimum": 0 }, "advanced": { "type": "number", "minimum": 0 }, "conversionRate": { "type": "number", "minimum": 0, "maximum": 1 } } } } } }
292
+ ],
293
+ "unevaluatedProperties": false
294
+ },
295
+ "channelEconomicsMeasurement": {
296
+ "allOf": [
297
+ { "$ref": "#/$defs/measurementBase" },
298
+ { "type": "object", "required": ["channel", "currency", "spend", "acquiredCustomers", "customerAcquisitionCost", "attributedRevenue", "paybackPeriods"], "properties": { "kind": { "const": "channel-economics" }, "channel": { "$ref": "#/$defs/title" }, "currency": { "$ref": "#/$defs/id" }, "spend": { "type": "number", "minimum": 0 }, "acquiredCustomers": { "type": "number", "minimum": 0 }, "customerAcquisitionCost": { "type": ["number", "null"], "minimum": 0 }, "attributedRevenue": { "type": "number" }, "paybackPeriods": { "type": ["number", "null"], "minimum": 0 } } }
299
+ ],
300
+ "unevaluatedProperties": false
301
+ },
302
+ "capacityMeasurement": {
303
+ "allOf": [
304
+ { "$ref": "#/$defs/measurementBase" },
305
+ { "type": "object", "required": ["unit", "available", "committed", "utilizationRate"], "properties": { "kind": { "const": "capacity" }, "unit": { "$ref": "#/$defs/id" }, "available": { "type": "number", "minimum": 0 }, "committed": { "type": "number", "minimum": 0 }, "utilizationRate": { "type": "number", "minimum": 0 } } }
306
+ ],
307
+ "unevaluatedProperties": false
308
+ },
309
+ "throughputMeasurement": {
310
+ "allOf": [
311
+ { "$ref": "#/$defs/measurementBase" },
312
+ { "type": "object", "required": ["unit", "completed", "leadTimeP50", "leadTimeP95"], "properties": { "kind": { "const": "throughput" }, "unit": { "$ref": "#/$defs/id" }, "completed": { "type": "number", "minimum": 0 }, "leadTimeP50": { "type": ["number", "null"], "minimum": 0 }, "leadTimeP95": { "type": ["number", "null"], "minimum": 0 } } }
313
+ ],
314
+ "unevaluatedProperties": false
315
+ },
316
+ "exposureMeasurement": {
317
+ "allOf": [
318
+ { "$ref": "#/$defs/measurementBase" },
319
+ { "type": "object", "required": ["surface", "likelihood", "impactScore", "exposureScore", "reversibility"], "properties": { "kind": { "const": "exposure" }, "surface": { "$ref": "#/$defs/title" }, "likelihood": { "type": "number", "minimum": 0, "maximum": 1 }, "impactScore": { "type": "number", "minimum": 0, "maximum": 1 }, "exposureScore": { "type": "number", "minimum": 0, "maximum": 1 }, "reversibility": { "$ref": "#/$defs/text" } } }
320
+ ],
321
+ "unevaluatedProperties": false
322
+ },
323
+ "scenarioMeasurement": {
324
+ "allOf": [
325
+ { "$ref": "#/$defs/measurementBase" },
326
+ { "type": "object", "required": ["scenario", "assumptions", "metric", "baseline", "projected", "unit"], "properties": { "kind": { "const": "scenario" }, "scenario": { "$ref": "#/$defs/title" }, "assumptions": { "type": "array", "minItems": 1, "maxItems": 32, "items": { "$ref": "#/$defs/text" } }, "metric": { "$ref": "#/$defs/title" }, "baseline": { "type": "number" }, "projected": { "type": "number" }, "unit": { "$ref": "#/$defs/id" } } }
327
+ ],
328
+ "unevaluatedProperties": false
329
+ },
330
+ "metricTrendMeasurement": {
331
+ "allOf": [
332
+ { "$ref": "#/$defs/measurementBase" },
333
+ { "type": "object", "required": ["metricId", "direction", "current", "previous", "unit"], "properties": { "kind": { "const": "metric-trend" }, "metricId": { "type": ["string", "null"], "pattern": "^met_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" }, "direction": { "enum": ["improving", "stable", "degrading", "unknown"] }, "current": { "type": "number" }, "previous": { "type": ["number", "null"] }, "unit": { "$ref": "#/$defs/id" } } }
334
+ ],
335
+ "unevaluatedProperties": false
336
+ },
337
+ "measurement": {
338
+ "oneOf": [
339
+ { "$ref": "#/$defs/runwayMeasurement" },
340
+ { "$ref": "#/$defs/marginMeasurement" },
341
+ { "$ref": "#/$defs/funnelMeasurement" },
342
+ { "$ref": "#/$defs/channelEconomicsMeasurement" },
343
+ { "$ref": "#/$defs/capacityMeasurement" },
344
+ { "$ref": "#/$defs/throughputMeasurement" },
345
+ { "$ref": "#/$defs/exposureMeasurement" },
346
+ { "$ref": "#/$defs/scenarioMeasurement" },
347
+ { "$ref": "#/$defs/metricTrendMeasurement" }
348
+ ]
349
+ },
350
+ "risk": {
351
+ "type": "object", "additionalProperties": false,
352
+ "required": ["localRiskId", "title", "statement", "likelihood", "impact", "exposure", "exposedSurfaces", "claimIds", "evidenceRefIds", "mitigation", "reversibility"],
353
+ "properties": {
354
+ "localRiskId": { "$ref": "#/$defs/riskId" }, "title": { "$ref": "#/$defs/title" }, "statement": { "$ref": "#/$defs/text" },
355
+ "likelihood": { "type": "number", "minimum": 0, "maximum": 1 }, "impact": { "enum": ["low", "medium", "high", "critical"] },
356
+ "exposure": { "$ref": "#/$defs/text" }, "exposedSurfaces": { "type": "array", "minItems": 1, "maxItems": 64, "uniqueItems": true, "items": { "$ref": "#/$defs/title" } },
357
+ "claimIds": { "allOf": [{ "$ref": "#/$defs/claimIds" }, { "minItems": 1 }] },
358
+ "evidenceRefIds": { "$ref": "#/$defs/evidenceRefIds" }, "mitigation": { "$ref": "#/$defs/text" }, "reversibility": { "$ref": "#/$defs/text" }
359
+ }
360
+ },
361
+ "alternative": {
362
+ "type": "object", "additionalProperties": false,
363
+ "required": ["localAlternativeId", "title", "description", "supportingClaimIds", "evidenceRefIds", "tradeoffs", "costOfDelay", "reversibility"],
364
+ "properties": {
365
+ "localAlternativeId": { "$ref": "#/$defs/alternativeId" }, "title": { "$ref": "#/$defs/title" }, "description": { "$ref": "#/$defs/text" },
366
+ "supportingClaimIds": { "$ref": "#/$defs/claimIds" },
367
+ "evidenceRefIds": { "$ref": "#/$defs/evidenceRefIds" }, "tradeoffs": { "type": "array", "minItems": 1, "maxItems": 32, "items": { "$ref": "#/$defs/text" } },
368
+ "costOfDelay": { "$ref": "#/$defs/text" }, "reversibility": { "$ref": "#/$defs/text" }
369
+ },
370
+ "anyOf": [
371
+ { "properties": { "supportingClaimIds": { "minItems": 1 } } },
372
+ { "properties": { "evidenceRefIds": { "minItems": 1 } } }
373
+ ]
374
+ },
375
+ "gap": {
376
+ "type": "object", "additionalProperties": false, "required": ["localGapId", "inputAbsenceId", "requirementId", "impact", "recoveryPath"],
377
+ "properties": { "localGapId": { "$ref": "#/$defs/gapId" }, "inputAbsenceId": { "$ref": "#/$defs/absenceId" }, "requirementId": { "$ref": "#/$defs/identifier" }, "impact": { "$ref": "#/$defs/text" }, "recoveryPath": { "$ref": "#/$defs/text" } }
378
+ },
379
+ "recommendation": {
380
+ "type": "object", "additionalProperties": false,
381
+ "required": ["localRecommendationId", "title", "proposal", "rationaleClaimIds", "alternativeIds", "riskIds", "confidence", "expectedUpside", "expectedDownside", "uncertainty", "reversibility", "successMeasurementIds", "revisitConditions"],
382
+ "properties": {
383
+ "localRecommendationId": { "$ref": "#/$defs/recommendationId" }, "title": { "$ref": "#/$defs/title" }, "proposal": { "$ref": "#/$defs/text" },
384
+ "rationaleClaimIds": { "allOf": [{ "$ref": "#/$defs/claimIds" }, { "minItems": 1 }] },
385
+ "alternativeIds": { "$ref": "#/$defs/alternativeIds" },
386
+ "riskIds": { "$ref": "#/$defs/riskIds" },
387
+ "confidence": { "type": "number", "minimum": 0, "maximum": 1 }, "expectedUpside": { "$ref": "#/$defs/text" },
388
+ "expectedDownside": { "$ref": "#/$defs/text" }, "uncertainty": { "$ref": "#/$defs/text" }, "reversibility": { "$ref": "#/$defs/text" },
389
+ "successMeasurementIds": { "$ref": "#/$defs/measurementIds" },
390
+ "revisitConditions": { "type": "array", "minItems": 1, "maxItems": 32, "items": { "$ref": "#/$defs/text" } }
391
+ }
392
+ }
393
+ }
394
+ }
@@ -0,0 +1,23 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://openplanr.dev/schemas/v2.0.0/operating-approval-record.schema.json",
3
+ "x-openplanr-contract": { "id": "operating-approval-record", "version": "2.0.0" }, "title": "OpenPlanr Operate 2.0 approval record",
4
+ "type": "object", "additionalProperties": false,
5
+ "required": ["kind", "schemaVersion", "protocolVersion", "approvalId", "requirementId", "evaluationId", "policy", "action", "scopeId", "domainId", "domainVersion", "capability", "target", "effectClass", "partyId", "actor", "decision", "scopeHash", "issuedAt", "expiresAt", "consumedByOperationId", "recordHash"],
6
+ "properties": {
7
+ "kind": { "const": "operating-approval-record" }, "schemaVersion": { "const": "1.0.0" }, "protocolVersion": { "const": "2.0.0" },
8
+ "approvalId": { "type": "string", "pattern": "^aprv_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" }, "requirementId": { "type": "string", "pattern": "^aprq_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" }, "evaluationId": { "type": "string", "pattern": "^pevl_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
9
+ "policy": { "$ref": "#/$defs/policy" }, "action": { "$ref": "#/$defs/action" },
10
+ "scopeId": { "$ref": "#/$defs/id" }, "domainId": { "$ref": "#/$defs/id" }, "domainVersion": { "$ref": "#/$defs/version" },
11
+ "capability": { "$ref": "#/$defs/versionedId" }, "target": { "$ref": "#/$defs/target" }, "effectClass": { "$ref": "#/$defs/effect" }, "partyId": { "$ref": "#/$defs/id" },
12
+ "actor": { "$ref": "#/$defs/actor" }, "decision": { "enum": ["approved", "rejected", "deferred"] }, "scopeHash": { "$ref": "#/$defs/hash" }, "issuedAt": { "type": "string", "format": "date-time" }, "expiresAt": { "type": ["string", "null"], "format": "date-time" }, "consumedByOperationId": { "type": ["string", "null"], "pattern": "^op_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" }, "recordHash": { "$ref": "#/$defs/hash" }
13
+ },
14
+ "$defs": {
15
+ "id": { "type": "string", "pattern": "^[a-z][a-z0-9]*(?:-[a-z0-9]+)*$" }, "version": { "type": "string", "pattern": "^(?:0|[1-9][0-9]*)\\.(?:0|[1-9][0-9]*)\\.(?:0|[1-9][0-9]*)$" }, "hash": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" },
16
+ "policy": { "type": "object", "additionalProperties": false, "required": ["policyId", "policyVersion", "policyHash"], "properties": { "policyId": { "$ref": "#/$defs/id" }, "policyVersion": { "$ref": "#/$defs/version" }, "policyHash": { "$ref": "#/$defs/hash" } } },
17
+ "action": { "type": "object", "additionalProperties": false, "required": ["actionId", "revision", "actionHash"], "properties": { "actionId": { "type": "string", "pattern": "^act_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" }, "revision": { "type": "integer", "minimum": 1 }, "actionHash": { "$ref": "#/$defs/hash" } } },
18
+ "versionedId": { "type": "object", "additionalProperties": false, "required": ["id", "version"], "properties": { "id": { "$ref": "#/$defs/id" }, "version": { "$ref": "#/$defs/version" } } },
19
+ "effect": { "enum": ["read-only", "machine-local-write", "project-write", "provider-call", "external-effect"] },
20
+ "target": { "type": "object", "additionalProperties": false, "required": ["kind", "id", "revision"], "properties": { "kind": { "$ref": "#/$defs/id" }, "id": { "type": "string", "minLength": 1, "maxLength": 128 }, "revision": { "type": "string", "minLength": 1, "maxLength": 128 } } },
21
+ "actor": { "type": "object", "additionalProperties": false, "required": ["kind", "actorId", "capability"], "properties": { "kind": { "enum": ["human", "engine"] }, "actorId": { "type": "string", "minLength": 1, "maxLength": 128 }, "capability": { "$ref": "#/$defs/versionedId" } } }
22
+ }
23
+ }
@@ -0,0 +1,31 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://openplanr.dev/schemas/v2.0.0/operating-approval-requirement.schema.json",
3
+ "x-openplanr-contract": { "id": "operating-approval-requirement", "version": "2.0.0" }, "title": "OpenPlanr Operate 2.0 approval requirement",
4
+ "type": "object", "additionalProperties": false,
5
+ "required": ["kind", "schemaVersion", "protocolVersion", "requirementId", "evaluationId", "policy", "action", "scopeId", "domainId", "domainVersion", "capability", "target", "effectClass", "parties", "mode", "namedActorIds", "requiredActorKinds", "threshold", "expiresAt", "consumable", "scopeHash"],
6
+ "properties": {
7
+ "kind": { "const": "operating-approval-requirement" }, "schemaVersion": { "const": "1.0.0" }, "protocolVersion": { "const": "2.0.0" },
8
+ "requirementId": { "type": "string", "pattern": "^aprq_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" }, "evaluationId": { "type": "string", "pattern": "^pevl_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
9
+ "policy": { "$ref": "#/$defs/policy" }, "action": { "$ref": "#/$defs/action" },
10
+ "scopeId": { "$ref": "#/$defs/id" }, "domainId": { "$ref": "#/$defs/id" }, "domainVersion": { "$ref": "#/$defs/version" },
11
+ "capability": { "$ref": "#/$defs/versionedId" }, "target": { "$ref": "#/$defs/target" }, "effectClass": { "$ref": "#/$defs/effect" },
12
+ "parties": { "type": "array", "minItems": 1, "uniqueItems": true, "items": { "$ref": "#/$defs/party" } },
13
+ "mode": { "enum": ["automatic", "named-single-party", "named-multi-party", "threshold"] },
14
+ "namedActorIds": { "type": "array", "uniqueItems": true, "items": { "type": "string", "minLength": 1, "maxLength": 128 } }, "requiredActorKinds": { "type": "array", "minItems": 1, "uniqueItems": true, "items": { "enum": ["human", "engine"] } },
15
+ "threshold": { "type": "integer", "minimum": 0 }, "expiresAt": { "type": ["string", "null"], "format": "date-time" }, "consumable": { "type": "boolean" }, "scopeHash": { "$ref": "#/$defs/hash" }
16
+ },
17
+ "allOf": [
18
+ { "if": { "properties": { "mode": { "const": "automatic" } } }, "then": { "properties": { "threshold": { "const": 0 }, "namedActorIds": { "maxItems": 0 } } } },
19
+ { "if": { "properties": { "mode": { "const": "named-single-party" } } }, "then": { "properties": { "threshold": { "const": 1 }, "namedActorIds": { "minItems": 1, "maxItems": 1 } } } },
20
+ { "if": { "properties": { "mode": { "enum": ["named-multi-party", "threshold"] } } }, "then": { "properties": { "threshold": { "minimum": 2 }, "namedActorIds": { "minItems": 2 } } } }
21
+ ],
22
+ "$defs": {
23
+ "id": { "type": "string", "pattern": "^[a-z][a-z0-9]*(?:-[a-z0-9]+)*$" }, "version": { "type": "string", "pattern": "^(?:0|[1-9][0-9]*)\\.(?:0|[1-9][0-9]*)\\.(?:0|[1-9][0-9]*)$" }, "hash": { "type": "string", "pattern": "^sha256:[a-f0-9]{64}$" },
24
+ "policy": { "type": "object", "additionalProperties": false, "required": ["policyId", "policyVersion", "policyHash"], "properties": { "policyId": { "$ref": "#/$defs/id" }, "policyVersion": { "$ref": "#/$defs/version" }, "policyHash": { "$ref": "#/$defs/hash" } } },
25
+ "action": { "type": "object", "additionalProperties": false, "required": ["actionId", "revision", "actionHash"], "properties": { "actionId": { "type": "string", "pattern": "^act_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" }, "revision": { "type": "integer", "minimum": 1 }, "actionHash": { "$ref": "#/$defs/hash" } } },
26
+ "versionedId": { "type": "object", "additionalProperties": false, "required": ["id", "version"], "properties": { "id": { "$ref": "#/$defs/id" }, "version": { "$ref": "#/$defs/version" } } },
27
+ "effect": { "enum": ["read-only", "machine-local-write", "project-write", "provider-call", "external-effect"] },
28
+ "target": { "type": "object", "additionalProperties": false, "required": ["kind", "id", "revision"], "properties": { "kind": { "$ref": "#/$defs/id" }, "id": { "type": "string", "minLength": 1, "maxLength": 128 }, "revision": { "type": "string", "minLength": 1, "maxLength": 128 } } },
29
+ "party": { "type": "object", "additionalProperties": false, "required": ["partyId", "actorKind", "actorId", "requiredCapability"], "properties": { "partyId": { "$ref": "#/$defs/id" }, "actorKind": { "enum": ["human", "engine"] }, "actorId": { "type": ["string", "null"], "minLength": 1, "maxLength": 128 }, "requiredCapability": { "$ref": "#/$defs/versionedId" } } }
30
+ }
31
+ }
@@ -0,0 +1,52 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://openplanr.dev/schemas/v2.0.0/operating-artifact.schema.json",
4
+ "x-openplanr-contract": { "id": "operating-artifact", "version": "2.0.0" },
5
+ "title": "OpenPlanr Operate 2.0 immutable operating artifact metadata",
6
+ "description": "Immutable metadata for accepted results and runtime-owned derivative records. An evidence-snapshot is a runtime-only Artifact that binds one resolved EvidenceRef to exact captured bytes or a referenced accepted Artifact; it is never a second acceptance route.",
7
+ "type": "object",
8
+ "additionalProperties": false,
9
+ "required": ["kind", "schemaVersion", "protocolVersion", "artifactId", "artifactType", "assignmentId", "cycleId", "scopeId", "domainId", "domainVersion", "schemaId", "artifactSchemaVersion", "mediaType", "encoding", "rawHash", "canonicalHash", "sizeBytes", "storageClass", "sensitivity", "retentionClass", "producer", "inputArtifactIds", "createdAt"],
10
+ "properties": {
11
+ "kind": { "const": "operating-artifact" },
12
+ "schemaVersion": { "const": "1.0.0" },
13
+ "protocolVersion": { "const": "2.0.0" },
14
+ "artifactId": { "type": "string", "pattern": "^art_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
15
+ "artifactType": { "type": "string", "minLength": 1, "maxLength": 128 },
16
+ "assignmentId": { "type": "string", "pattern": "^asg_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
17
+ "cycleId": { "type": "string", "minLength": 1, "maxLength": 128 },
18
+ "scopeId": { "type": "string", "minLength": 1, "maxLength": 128 },
19
+ "domainId": { "type": "string", "minLength": 1, "maxLength": 128 },
20
+ "domainVersion": { "type": "string", "minLength": 1, "maxLength": 64 },
21
+ "schemaId": { "type": "string", "minLength": 1, "maxLength": 256 },
22
+ "artifactSchemaVersion": { "type": "string", "minLength": 1, "maxLength": 64 },
23
+ "mediaType": { "type": "string", "minLength": 1, "maxLength": 128 },
24
+ "encoding": { "type": "string", "enum": ["utf-8", "binary"] },
25
+ "rawHash": {
26
+ "type": "string",
27
+ "pattern": "^sha256:[a-f0-9]{64}$",
28
+ "description": "Digest of the exact accepted byte sequence. It is the immutable raw Artifact identity."
29
+ },
30
+ "canonicalHash": {
31
+ "type": ["string", "null"],
32
+ "pattern": "^sha256:[a-f0-9]{64}$",
33
+ "description": "Optional digest of a contract-defined canonical representation; it never substitutes for rawHash."
34
+ },
35
+ "sizeBytes": { "type": "integer", "minimum": 0 },
36
+ "storageClass": { "const": "machine-local" },
37
+ "sensitivity": { "type": "string", "enum": ["public", "internal", "confidential", "restricted"] },
38
+ "retentionClass": { "type": "string", "minLength": 1, "maxLength": 128 },
39
+ "producer": {
40
+ "type": "object", "additionalProperties": false, "required": ["actorId", "roleId", "runtime"],
41
+ "properties": {
42
+ "actorId": { "type": "string", "minLength": 1, "maxLength": 128 },
43
+ "roleId": { "type": "string", "minLength": 1, "maxLength": 128 },
44
+ "runtime": { "type": "string", "minLength": 1, "maxLength": 128 }
45
+ }
46
+ },
47
+ "inputArtifactIds": { "type": "array", "uniqueItems": true, "items": { "type": "string", "pattern": "^art_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" } },
48
+ "governedOperationId": { "type": ["string", "null"], "pattern": "^op_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" },
49
+ "authorityRecordIds": { "type": "array", "uniqueItems": true, "items": { "type": "string", "pattern": "^(?:pevl|aprq|aprv|cava|cgr)_[A-Za-z0-9][A-Za-z0-9._-]{7,127}$" } },
50
+ "createdAt": { "type": "string", "format": "date-time" }
51
+ }
52
+ }