openplanr 1.25.2 → 2.0.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.
- package/CHANGELOG.md +78 -0
- package/CONTRIBUTING.md +33 -0
- package/README.md +154 -131
- package/dist/cli/commands/artifact.d.ts.map +1 -1
- package/dist/cli/commands/artifact.js +214 -30
- package/dist/cli/commands/artifact.js.map +1 -1
- package/dist/cli/commands/backlog.d.ts +1 -21
- package/dist/cli/commands/backlog.d.ts.map +1 -1
- package/dist/cli/commands/backlog.js +1 -428
- package/dist/cli/commands/backlog.js.map +1 -1
- package/dist/cli/commands/company.d.ts +3 -0
- package/dist/cli/commands/company.d.ts.map +1 -0
- package/dist/cli/commands/company.js +173 -0
- package/dist/cli/commands/company.js.map +1 -0
- package/dist/cli/commands/config-deterministic.d.ts +3 -0
- package/dist/cli/commands/config-deterministic.d.ts.map +1 -0
- package/dist/cli/commands/config-deterministic.js +88 -0
- package/dist/cli/commands/config-deterministic.js.map +1 -0
- package/dist/cli/commands/dashboard.d.ts +3 -0
- package/dist/cli/commands/dashboard.d.ts.map +1 -0
- package/dist/cli/commands/dashboard.js +36 -0
- package/dist/cli/commands/dashboard.js.map +1 -0
- package/dist/cli/commands/diagram/index.d.ts +3 -0
- package/dist/cli/commands/diagram/index.d.ts.map +1 -0
- package/dist/cli/commands/diagram/index.js +73 -0
- package/dist/cli/commands/diagram/index.js.map +1 -0
- package/dist/cli/commands/diagram/presentation.d.ts +4 -0
- package/dist/cli/commands/diagram/presentation.d.ts.map +1 -0
- package/dist/cli/commands/diagram/presentation.js +38 -0
- package/dist/cli/commands/diagram/presentation.js.map +1 -0
- package/dist/cli/commands/doctor.d.ts.map +1 -1
- package/dist/cli/commands/doctor.js +1 -11
- package/dist/cli/commands/doctor.js.map +1 -1
- package/dist/cli/commands/epic.d.ts +1 -9
- package/dist/cli/commands/epic.d.ts.map +1 -1
- package/dist/cli/commands/epic.js +1 -259
- package/dist/cli/commands/epic.js.map +1 -1
- package/dist/cli/commands/feature.d.ts +1 -8
- package/dist/cli/commands/feature.d.ts.map +1 -1
- package/dist/cli/commands/feature.js +1 -220
- package/dist/cli/commands/feature.js.map +1 -1
- package/dist/cli/commands/groups/delivery.d.ts +3 -0
- package/dist/cli/commands/groups/delivery.d.ts.map +1 -0
- package/dist/cli/commands/groups/delivery.js +13 -0
- package/dist/cli/commands/groups/delivery.js.map +1 -0
- package/dist/cli/commands/groups/foundation.d.ts +3 -0
- package/dist/cli/commands/groups/foundation.d.ts.map +1 -0
- package/dist/cli/commands/groups/foundation.js +11 -0
- package/dist/cli/commands/groups/foundation.js.map +1 -0
- package/dist/cli/commands/groups/intelligence.d.ts +3 -0
- package/dist/cli/commands/groups/intelligence.d.ts.map +1 -0
- package/dist/cli/commands/groups/intelligence.js +19 -0
- package/dist/cli/commands/groups/intelligence.js.map +1 -0
- package/dist/cli/commands/groups/operations.d.ts +3 -0
- package/dist/cli/commands/groups/operations.d.ts.map +1 -0
- package/dist/cli/commands/groups/operations.js +17 -0
- package/dist/cli/commands/groups/operations.js.map +1 -0
- package/dist/cli/commands/groups/planning.d.ts +3 -0
- package/dist/cli/commands/groups/planning.d.ts.map +1 -0
- package/dist/cli/commands/groups/planning.js +25 -0
- package/dist/cli/commands/groups/planning.js.map +1 -0
- package/dist/cli/commands/index.d.ts +4 -0
- package/dist/cli/commands/index.d.ts.map +1 -0
- package/dist/cli/commands/index.js +14 -0
- package/dist/cli/commands/index.js.map +1 -0
- package/dist/cli/commands/init-deterministic.d.ts +3 -0
- package/dist/cli/commands/init-deterministic.d.ts.map +1 -0
- package/dist/cli/commands/init-deterministic.js +40 -0
- package/dist/cli/commands/init-deterministic.js.map +1 -0
- package/dist/cli/commands/land.d.ts +15 -0
- package/dist/cli/commands/land.d.ts.map +1 -0
- package/dist/cli/commands/land.js +176 -0
- package/dist/cli/commands/land.js.map +1 -0
- package/dist/cli/commands/operate/input.d.ts +54 -0
- package/dist/cli/commands/operate/input.d.ts.map +1 -0
- package/dist/cli/commands/operate/input.js +98 -0
- package/dist/cli/commands/operate/input.js.map +1 -0
- package/dist/cli/commands/operate/registrars/assignments.d.ts +5 -0
- package/dist/cli/commands/operate/registrars/assignments.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/assignments.js +167 -0
- package/dist/cli/commands/operate/registrars/assignments.js.map +1 -0
- package/dist/cli/commands/operate/registrars/catalog.d.ts +4 -0
- package/dist/cli/commands/operate/registrars/catalog.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/catalog.js +12 -0
- package/dist/cli/commands/operate/registrars/catalog.js.map +1 -0
- package/dist/cli/commands/operate/registrars/contracts.d.ts +41 -0
- package/dist/cli/commands/operate/registrars/contracts.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/contracts.js +2 -0
- package/dist/cli/commands/operate/registrars/contracts.js.map +1 -0
- package/dist/cli/commands/operate/registrars/dashboard.d.ts +4 -0
- package/dist/cli/commands/operate/registrars/dashboard.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/dashboard.js +26 -0
- package/dist/cli/commands/operate/registrars/dashboard.js.map +1 -0
- package/dist/cli/commands/operate/registrars/dispatch.d.ts +7 -0
- package/dist/cli/commands/operate/registrars/dispatch.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/dispatch.js +55 -0
- package/dist/cli/commands/operate/registrars/dispatch.js.map +1 -0
- package/dist/cli/commands/operate/registrars/experience.d.ts +4 -0
- package/dist/cli/commands/operate/registrars/experience.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/experience.js +93 -0
- package/dist/cli/commands/operate/registrars/experience.js.map +1 -0
- package/dist/cli/commands/operate/registrars/index.d.ts +5 -0
- package/dist/cli/commands/operate/registrars/index.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/index.js +28 -0
- package/dist/cli/commands/operate/registrars/index.js.map +1 -0
- package/dist/cli/commands/operate/registrars/lifecycle.d.ts +4 -0
- package/dist/cli/commands/operate/registrars/lifecycle.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/lifecycle.js +46 -0
- package/dist/cli/commands/operate/registrars/lifecycle.js.map +1 -0
- package/dist/cli/commands/operate/registrars/measurement.d.ts +4 -0
- package/dist/cli/commands/operate/registrars/measurement.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/measurement.js +122 -0
- package/dist/cli/commands/operate/registrars/measurement.js.map +1 -0
- package/dist/cli/commands/operate/registrars/note-validation.d.ts +6 -0
- package/dist/cli/commands/operate/registrars/note-validation.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/note-validation.js +103 -0
- package/dist/cli/commands/operate/registrars/note-validation.js.map +1 -0
- package/dist/cli/commands/operate/registrars/planning.d.ts +4 -0
- package/dist/cli/commands/operate/registrars/planning.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/planning.js +41 -0
- package/dist/cli/commands/operate/registrars/planning.js.map +1 -0
- package/dist/cli/commands/operate/registrars/recovery.d.ts +4 -0
- package/dist/cli/commands/operate/registrars/recovery.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/recovery.js +65 -0
- package/dist/cli/commands/operate/registrars/recovery.js.map +1 -0
- package/dist/cli/commands/operate/registrars/reviews.d.ts +4 -0
- package/dist/cli/commands/operate/registrars/reviews.d.ts.map +1 -0
- package/dist/cli/commands/operate/registrars/reviews.js +83 -0
- package/dist/cli/commands/operate/registrars/reviews.js.map +1 -0
- package/dist/cli/commands/operate/registration.d.ts +4 -0
- package/dist/cli/commands/operate/registration.d.ts.map +1 -0
- package/dist/cli/commands/operate/registration.js +3 -0
- package/dist/cli/commands/operate/registration.js.map +1 -0
- package/dist/cli/commands/operate/render.d.ts +19 -0
- package/dist/cli/commands/operate/render.d.ts.map +1 -0
- package/dist/cli/commands/operate/render.js +201 -0
- package/dist/cli/commands/operate/render.js.map +1 -0
- package/dist/cli/commands/operate.d.ts +58 -13
- package/dist/cli/commands/operate.d.ts.map +1 -1
- package/dist/cli/commands/operate.js +169 -984
- package/dist/cli/commands/operate.js.map +1 -1
- package/dist/cli/commands/planning-artifacts.d.ts +10 -0
- package/dist/cli/commands/planning-artifacts.d.ts.map +1 -0
- package/dist/cli/commands/planning-artifacts.js +350 -0
- package/dist/cli/commands/planning-artifacts.js.map +1 -0
- package/dist/cli/commands/quick/interaction.d.ts +8 -0
- package/dist/cli/commands/quick/interaction.d.ts.map +1 -0
- package/dist/cli/commands/quick/interaction.js +8 -0
- package/dist/cli/commands/quick/interaction.js.map +1 -0
- package/dist/cli/commands/quick/project.d.ts +8 -0
- package/dist/cli/commands/quick/project.d.ts.map +1 -0
- package/dist/cli/commands/quick/project.js +8 -0
- package/dist/cli/commands/quick/project.js.map +1 -0
- package/dist/cli/commands/quick.d.ts +1 -29
- package/dist/cli/commands/quick.d.ts.map +1 -1
- package/dist/cli/commands/quick.js +1 -337
- package/dist/cli/commands/quick.js.map +1 -1
- package/dist/cli/commands/rules.js +1 -1
- package/dist/cli/commands/rules.js.map +1 -1
- package/dist/cli/commands/setup.d.ts.map +1 -1
- package/dist/cli/commands/setup.js +40 -18
- package/dist/cli/commands/setup.js.map +1 -1
- package/dist/cli/commands/spec.d.ts +6 -4
- package/dist/cli/commands/spec.d.ts.map +1 -1
- package/dist/cli/commands/spec.js +166 -174
- package/dist/cli/commands/spec.js.map +1 -1
- package/dist/cli/commands/sprint.d.ts +1 -8
- package/dist/cli/commands/sprint.d.ts.map +1 -1
- package/dist/cli/commands/sprint.js +1 -522
- package/dist/cli/commands/sprint.js.map +1 -1
- package/dist/cli/commands/story/interaction.d.ts +7 -0
- package/dist/cli/commands/story/interaction.d.ts.map +1 -0
- package/dist/cli/commands/story/interaction.js +7 -0
- package/dist/cli/commands/story/interaction.js.map +1 -0
- package/dist/cli/commands/story/project.d.ts +10 -0
- package/dist/cli/commands/story/project.d.ts.map +1 -0
- package/dist/cli/commands/story/project.js +10 -0
- package/dist/cli/commands/story/project.js.map +1 -0
- package/dist/cli/commands/story.d.ts +1 -8
- package/dist/cli/commands/story.d.ts.map +1 -1
- package/dist/cli/commands/story.js +1 -358
- package/dist/cli/commands/story.js.map +1 -1
- package/dist/cli/commands/task.d.ts +1 -9
- package/dist/cli/commands/task.d.ts.map +1 -1
- package/dist/cli/commands/task.js +1 -351
- package/dist/cli/commands/task.js.map +1 -1
- package/dist/cli/error-boundary.d.ts +29 -0
- package/dist/cli/error-boundary.d.ts.map +1 -0
- package/dist/cli/error-boundary.js +103 -0
- package/dist/cli/error-boundary.js.map +1 -0
- package/dist/cli/helpers/bulk-checkbox-update.d.ts +1 -1
- package/dist/cli/helpers/bulk-checkbox-update.js +1 -1
- package/dist/cli/index.js +38 -113
- package/dist/cli/index.js.map +1 -1
- package/dist/dashboard/.vite/manifest.json +68 -0
- package/dist/dashboard/assets/geist-cyrillic-ext-wght-normal-DjL33-gN.woff2 +0 -0
- package/dist/dashboard/assets/geist-cyrillic-wght-normal-BEAKL7Jp.woff2 +0 -0
- package/dist/dashboard/assets/geist-latin-ext-wght-normal-DC-KSUi6.woff2 +0 -0
- package/dist/dashboard/assets/geist-latin-wght-normal-BgDaEnEv.woff2 +0 -0
- package/dist/dashboard/assets/geist-mono-cyrillic-ext-wght-normal-X_5orZeX.woff2 +0 -0
- package/dist/dashboard/assets/geist-mono-cyrillic-wght-normal-DiZS0aHC.woff2 +0 -0
- package/dist/dashboard/assets/geist-mono-latin-ext-wght-normal-Bwz-egvJ.woff2 +0 -0
- package/dist/dashboard/assets/geist-mono-latin-wght-normal-XN7g48iV.woff2 +0 -0
- package/dist/dashboard/assets/geist-mono-symbols2-wght-normal-CO5SzqOn.woff2 +0 -0
- package/dist/dashboard/assets/geist-mono-vietnamese-wght-normal-DadHysG0.woff2 +0 -0
- package/dist/dashboard/assets/geist-vietnamese-wght-normal-6IgcOCM7.woff2 +0 -0
- package/dist/dashboard/assets/index-Bk8DyO_2.css +1 -0
- package/dist/dashboard/assets/index-zeygL5iu.js +557 -0
- package/dist/dashboard/assets/index-zeygL5iu.js.map +1 -0
- package/dist/dashboard/dashboard-manifest.json +84 -0
- package/dist/dashboard/index.html +13 -0
- package/dist/generators/base-generator.d.ts +2 -0
- package/dist/generators/base-generator.d.ts.map +1 -1
- package/dist/generators/base-generator.js +8 -0
- package/dist/generators/base-generator.js.map +1 -1
- package/dist/generators/claude-generator.d.ts.map +1 -1
- package/dist/generators/claude-generator.js +12 -14
- package/dist/generators/claude-generator.js.map +1 -1
- package/dist/generators/codex-generator.d.ts.map +1 -1
- package/dist/generators/codex-generator.js +7 -7
- package/dist/generators/codex-generator.js.map +1 -1
- package/dist/generators/cursor-generator.d.ts.map +1 -1
- package/dist/generators/cursor-generator.js +11 -30
- package/dist/generators/cursor-generator.js.map +1 -1
- package/dist/models/schema.d.ts +0 -23
- package/dist/models/schema.d.ts.map +1 -1
- package/dist/models/schema.js +0 -7
- package/dist/models/schema.js.map +1 -1
- package/dist/models/types.d.ts +3 -14
- package/dist/models/types.d.ts.map +1 -1
- package/dist/services/artifact-pipeline-service.d.ts +99 -1
- package/dist/services/artifact-pipeline-service.d.ts.map +1 -1
- package/dist/services/artifact-pipeline-service.js +681 -4
- package/dist/services/artifact-pipeline-service.js.map +1 -1
- package/dist/services/canonical-json.d.ts +3 -0
- package/dist/services/canonical-json.d.ts.map +1 -0
- package/dist/services/canonical-json.js +71 -0
- package/dist/services/canonical-json.js.map +1 -0
- package/dist/services/claude-plugin-service.d.ts +6 -1
- package/dist/services/claude-plugin-service.d.ts.map +1 -1
- package/dist/services/claude-plugin-service.js +184 -12
- package/dist/services/claude-plugin-service.js.map +1 -1
- package/dist/services/codex-plugin-service.d.ts +30 -0
- package/dist/services/codex-plugin-service.d.ts.map +1 -0
- package/dist/services/codex-plugin-service.js +195 -0
- package/dist/services/codex-plugin-service.js.map +1 -0
- package/dist/services/company-auth-service.d.ts +70 -0
- package/dist/services/company-auth-service.d.ts.map +1 -0
- package/dist/services/company-auth-service.js +720 -0
- package/dist/services/company-auth-service.js.map +1 -0
- package/dist/services/company-auth-store.d.ts +22 -0
- package/dist/services/company-auth-store.d.ts.map +1 -0
- package/dist/services/company-auth-store.js +158 -0
- package/dist/services/company-auth-store.js.map +1 -0
- package/dist/services/company-common.d.ts +9 -0
- package/dist/services/company-common.d.ts.map +1 -0
- package/dist/services/company-common.js +35 -0
- package/dist/services/company-common.js.map +1 -0
- package/dist/services/company-sync-service.d.ts +214 -0
- package/dist/services/company-sync-service.d.ts.map +1 -0
- package/dist/services/company-sync-service.js +1299 -0
- package/dist/services/company-sync-service.js.map +1 -0
- package/dist/services/connectors/adapters/business-metrics.d.ts +5 -0
- package/dist/services/connectors/adapters/business-metrics.d.ts.map +1 -0
- package/dist/services/connectors/adapters/business-metrics.js +41 -0
- package/dist/services/connectors/adapters/business-metrics.js.map +1 -0
- package/dist/services/connectors/adapters/deployment-health.d.ts +18 -0
- package/dist/services/connectors/adapters/deployment-health.d.ts.map +1 -0
- package/dist/services/connectors/adapters/deployment-health.js +67 -0
- package/dist/services/connectors/adapters/deployment-health.js.map +1 -0
- package/dist/services/connectors/adapters/github.d.ts +5 -0
- package/dist/services/connectors/adapters/github.d.ts.map +1 -0
- package/dist/services/connectors/adapters/github.js +31 -0
- package/dist/services/connectors/adapters/github.js.map +1 -0
- package/dist/services/connectors/adapters/linear-jira.d.ts +5 -0
- package/dist/services/connectors/adapters/linear-jira.d.ts.map +1 -0
- package/dist/services/connectors/adapters/linear-jira.js +26 -0
- package/dist/services/connectors/adapters/linear-jira.js.map +1 -0
- package/dist/services/connectors/adapters/posthog.d.ts +5 -0
- package/dist/services/connectors/adapters/posthog.d.ts.map +1 -0
- package/dist/services/connectors/adapters/posthog.js +31 -0
- package/dist/services/connectors/adapters/posthog.js.map +1 -0
- package/dist/services/connectors/adapters/sentry.d.ts +5 -0
- package/dist/services/connectors/adapters/sentry.d.ts.map +1 -0
- package/dist/services/connectors/adapters/sentry.js +31 -0
- package/dist/services/connectors/adapters/sentry.js.map +1 -0
- package/dist/services/connectors/checkpoint-custody.d.ts +45 -0
- package/dist/services/connectors/checkpoint-custody.d.ts.map +1 -0
- package/dist/services/connectors/checkpoint-custody.js +496 -0
- package/dist/services/connectors/checkpoint-custody.js.map +1 -0
- package/dist/services/connectors/connector-registry.d.ts +144 -0
- package/dist/services/connectors/connector-registry.d.ts.map +1 -0
- package/dist/services/connectors/connector-registry.js +423 -0
- package/dist/services/connectors/connector-registry.js.map +1 -0
- package/dist/services/connectors/connector-runtime.d.ts +200 -0
- package/dist/services/connectors/connector-runtime.d.ts.map +1 -0
- package/dist/services/connectors/connector-runtime.js +1297 -0
- package/dist/services/connectors/connector-runtime.js.map +1 -0
- package/dist/services/connectors/credential-custody.d.ts +96 -0
- package/dist/services/connectors/credential-custody.d.ts.map +1 -0
- package/dist/services/connectors/credential-custody.js +390 -0
- package/dist/services/connectors/credential-custody.js.map +1 -0
- package/dist/services/credential-backends.d.ts +11 -1
- package/dist/services/credential-backends.d.ts.map +1 -1
- package/dist/services/credential-backends.js +104 -21
- package/dist/services/credential-backends.js.map +1 -1
- package/dist/services/credential-write-lock.d.ts +8 -0
- package/dist/services/credential-write-lock.d.ts.map +1 -0
- package/dist/services/credential-write-lock.js +104 -0
- package/dist/services/credential-write-lock.js.map +1 -0
- package/dist/services/credentials-service.d.ts +8 -2
- package/dist/services/credentials-service.d.ts.map +1 -1
- package/dist/services/credentials-service.js +66 -21
- package/dist/services/credentials-service.js.map +1 -1
- package/dist/services/deprecation-notices.d.ts +2 -2
- package/dist/services/deprecation-notices.d.ts.map +1 -1
- package/dist/services/deprecation-notices.js +2 -2
- package/dist/services/deprecation-notices.js.map +1 -1
- package/dist/services/design-artifact-service.d.ts +37 -0
- package/dist/services/design-artifact-service.d.ts.map +1 -0
- package/dist/services/design-artifact-service.js +94 -0
- package/dist/services/design-artifact-service.js.map +1 -0
- package/dist/services/diagram-artifact-service.d.ts +12 -0
- package/dist/services/diagram-artifact-service.d.ts.map +1 -0
- package/dist/services/diagram-artifact-service.js +41 -0
- package/dist/services/diagram-artifact-service.js.map +1 -0
- package/dist/services/diagram-pipeline-service.d.ts +125 -0
- package/dist/services/diagram-pipeline-service.d.ts.map +1 -0
- package/dist/services/diagram-pipeline-service.js +329 -0
- package/dist/services/diagram-pipeline-service.js.map +1 -0
- package/dist/services/gherkin-service.d.ts +3 -0
- package/dist/services/gherkin-service.d.ts.map +1 -0
- package/dist/services/gherkin-service.js +9 -0
- package/dist/services/gherkin-service.js.map +1 -0
- package/dist/services/graph-service.d.ts.map +1 -1
- package/dist/services/graph-service.js +6 -4
- package/dist/services/graph-service.js.map +1 -1
- package/dist/services/landing/landing-service.d.ts +42 -0
- package/dist/services/landing/landing-service.d.ts.map +1 -0
- package/dist/services/landing/landing-service.js +197 -0
- package/dist/services/landing/landing-service.js.map +1 -0
- package/dist/services/landing/operation-registry.d.ts +56 -0
- package/dist/services/landing/operation-registry.d.ts.map +1 -0
- package/dist/services/landing/operation-registry.js +165 -0
- package/dist/services/landing/operation-registry.js.map +1 -0
- package/dist/services/landing/receipt-custody.d.ts +48 -0
- package/dist/services/landing/receipt-custody.d.ts.map +1 -0
- package/dist/services/landing/receipt-custody.js +375 -0
- package/dist/services/landing/receipt-custody.js.map +1 -0
- package/dist/services/linear/constants.d.ts.map +1 -1
- package/dist/services/linear/constants.js +2 -6
- package/dist/services/linear/constants.js.map +1 -1
- package/dist/services/linear/task-status-aggregation.d.ts +1 -1
- package/dist/services/linear/task-status-aggregation.js +1 -1
- package/dist/services/linear-pull-service.d.ts.map +1 -1
- package/dist/services/linear-pull-service.js +7 -30
- package/dist/services/linear-pull-service.js.map +1 -1
- package/dist/services/linear-push-service.d.ts.map +1 -1
- package/dist/services/linear-push-service.js +4 -5
- package/dist/services/linear-push-service.js.map +1 -1
- package/dist/services/migration-registry.d.ts +0 -19
- package/dist/services/migration-registry.d.ts.map +1 -1
- package/dist/services/migration-registry.js +18 -32
- package/dist/services/migration-registry.js.map +1 -1
- package/dist/services/operate/assignment-lifecycle-service.d.ts +135 -0
- package/dist/services/operate/assignment-lifecycle-service.d.ts.map +1 -0
- package/dist/services/operate/assignment-lifecycle-service.js +113 -0
- package/dist/services/operate/assignment-lifecycle-service.js.map +1 -0
- package/dist/services/operate/assignment-packet-service.d.ts +79 -0
- package/dist/services/operate/assignment-packet-service.d.ts.map +1 -0
- package/dist/services/operate/assignment-packet-service.js +1030 -0
- package/dist/services/operate/assignment-packet-service.js.map +1 -0
- package/dist/services/operate/client/governance.d.ts +4 -0
- package/dist/services/operate/client/governance.d.ts.map +1 -0
- package/dist/services/operate/client/governance.js +3 -0
- package/dist/services/operate/client/governance.js.map +1 -0
- package/dist/services/operate/client/lifecycle.d.ts +18 -0
- package/dist/services/operate/client/lifecycle.d.ts.map +1 -0
- package/dist/services/operate/client/lifecycle.js +15 -0
- package/dist/services/operate/client/lifecycle.js.map +1 -0
- package/dist/services/operate/client/runtime.d.ts +13 -0
- package/dist/services/operate/client/runtime.d.ts.map +1 -0
- package/dist/services/operate/client/runtime.js +11 -0
- package/dist/services/operate/client/runtime.js.map +1 -0
- package/dist/services/operate/client-error.d.ts +9 -0
- package/dist/services/operate/client-error.d.ts.map +1 -0
- package/dist/services/operate/client-error.js +14 -0
- package/dist/services/operate/client-error.js.map +1 -0
- package/dist/services/operate/client.d.ts +415 -0
- package/dist/services/operate/client.d.ts.map +1 -0
- package/dist/services/operate/client.js +2432 -0
- package/dist/services/operate/client.js.map +1 -0
- package/dist/services/operate/command-gateway.d.ts +152 -0
- package/dist/services/operate/command-gateway.d.ts.map +1 -0
- package/dist/services/operate/command-gateway.js +883 -0
- package/dist/services/operate/command-gateway.js.map +1 -0
- package/dist/services/operate/composition.d.ts +421 -0
- package/dist/services/operate/composition.d.ts.map +1 -0
- package/dist/services/operate/composition.js +394 -0
- package/dist/services/operate/composition.js.map +1 -0
- package/dist/services/operate/cycle-lifecycle-service.d.ts +35 -0
- package/dist/services/operate/cycle-lifecycle-service.d.ts.map +1 -0
- package/dist/services/operate/cycle-lifecycle-service.js +427 -0
- package/dist/services/operate/cycle-lifecycle-service.js.map +1 -0
- package/dist/services/operate/delivery-evidence.d.ts +34 -0
- package/dist/services/operate/delivery-evidence.d.ts.map +1 -0
- package/dist/services/operate/delivery-evidence.js +666 -0
- package/dist/services/operate/delivery-evidence.js.map +1 -0
- package/dist/services/operate/domain-catalog-service.d.ts +24 -0
- package/dist/services/operate/domain-catalog-service.d.ts.map +1 -0
- package/dist/services/operate/domain-catalog-service.js +99 -0
- package/dist/services/operate/domain-catalog-service.js.map +1 -0
- package/dist/services/operate/experience-read-service.d.ts +64 -0
- package/dist/services/operate/experience-read-service.d.ts.map +1 -0
- package/dist/services/operate/experience-read-service.js +109 -0
- package/dist/services/operate/experience-read-service.js.map +1 -0
- package/dist/services/operate/governed-action-service.d.ts +80 -0
- package/dist/services/operate/governed-action-service.d.ts.map +1 -0
- package/dist/services/operate/governed-action-service.js +497 -0
- package/dist/services/operate/governed-action-service.js.map +1 -0
- package/dist/services/operate/identity-contract.d.ts +3 -0
- package/dist/services/operate/identity-contract.d.ts.map +1 -0
- package/dist/services/operate/identity-contract.js +6 -0
- package/dist/services/operate/identity-contract.js.map +1 -0
- package/dist/services/operate/measurement-schedule-service.d.ts +81 -0
- package/dist/services/operate/measurement-schedule-service.d.ts.map +1 -0
- package/dist/services/operate/measurement-schedule-service.js +461 -0
- package/dist/services/operate/measurement-schedule-service.js.map +1 -0
- package/dist/services/operate/path-custody.d.ts +16 -0
- package/dist/services/operate/path-custody.d.ts.map +1 -0
- package/dist/services/operate/path-custody.js +120 -0
- package/dist/services/operate/path-custody.js.map +1 -0
- package/dist/services/operate/pinned-legacy-replay-runner.d.ts +9 -0
- package/dist/services/operate/pinned-legacy-replay-runner.d.ts.map +1 -0
- package/dist/services/operate/pinned-legacy-replay-runner.js +441 -0
- package/dist/services/operate/pinned-legacy-replay-runner.js.map +1 -0
- package/dist/services/operate/planning-bridge.d.ts +28 -0
- package/dist/services/operate/planning-bridge.d.ts.map +1 -0
- package/dist/services/operate/planning-bridge.js +341 -0
- package/dist/services/operate/planning-bridge.js.map +1 -0
- package/dist/services/operate/planning-handoff-gateway.d.ts +47 -0
- package/dist/services/operate/planning-handoff-gateway.d.ts.map +1 -0
- package/dist/services/operate/planning-handoff-gateway.js +169 -0
- package/dist/services/operate/planning-handoff-gateway.js.map +1 -0
- package/dist/services/operate/planning-handoff-service.d.ts +38 -0
- package/dist/services/operate/planning-handoff-service.d.ts.map +1 -0
- package/dist/services/operate/planning-handoff-service.js +304 -0
- package/dist/services/operate/planning-handoff-service.js.map +1 -0
- package/dist/services/operate/project-transaction-lock.d.ts +6 -0
- package/dist/services/operate/project-transaction-lock.d.ts.map +1 -0
- package/dist/services/operate/project-transaction-lock.js +146 -0
- package/dist/services/operate/project-transaction-lock.js.map +1 -0
- package/dist/services/operate/recovery-service.d.ts +16 -0
- package/dist/services/operate/recovery-service.d.ts.map +1 -0
- package/dist/services/operate/recovery-service.js +59 -0
- package/dist/services/operate/recovery-service.js.map +1 -0
- package/dist/services/operate/replay-safe-retry-service.d.ts +21 -0
- package/dist/services/operate/replay-safe-retry-service.d.ts.map +1 -0
- package/dist/services/operate/replay-safe-retry-service.js +66 -0
- package/dist/services/operate/replay-safe-retry-service.js.map +1 -0
- package/dist/services/operate/repository-read-service.d.ts +13 -0
- package/dist/services/operate/repository-read-service.d.ts.map +1 -0
- package/dist/services/operate/repository-read-service.js +153 -0
- package/dist/services/operate/repository-read-service.js.map +1 -0
- package/dist/services/operate/review-lifecycle-service.d.ts +50 -0
- package/dist/services/operate/review-lifecycle-service.d.ts.map +1 -0
- package/dist/services/operate/review-lifecycle-service.js +63 -0
- package/dist/services/operate/review-lifecycle-service.js.map +1 -0
- package/dist/services/operate/review-read-gateway.d.ts +21 -0
- package/dist/services/operate/review-read-gateway.d.ts.map +1 -0
- package/dist/services/operate/review-read-gateway.js +119 -0
- package/dist/services/operate/review-read-gateway.js.map +1 -0
- package/dist/services/operate/screened-evidence-service.d.ts +24 -0
- package/dist/services/operate/screened-evidence-service.d.ts.map +1 -0
- package/dist/services/operate/screened-evidence-service.js +186 -0
- package/dist/services/operate/screened-evidence-service.js.map +1 -0
- package/dist/services/operate/search-hit-contract.d.ts +11 -0
- package/dist/services/operate/search-hit-contract.d.ts.map +1 -0
- package/dist/services/operate/search-hit-contract.js +29 -0
- package/dist/services/operate/search-hit-contract.js.map +1 -0
- package/dist/services/operate/session-capability.d.ts +61 -0
- package/dist/services/operate/session-capability.d.ts.map +1 -0
- package/dist/services/operate/session-capability.js +124 -0
- package/dist/services/operate/session-capability.js.map +1 -0
- package/dist/services/operate/spec-operating-origin-service.d.ts +60 -0
- package/dist/services/operate/spec-operating-origin-service.d.ts.map +1 -0
- package/dist/services/operate/spec-operating-origin-service.js +401 -0
- package/dist/services/operate/spec-operating-origin-service.js.map +1 -0
- package/dist/services/operate/storage-layout.d.ts +82 -0
- package/dist/services/operate/storage-layout.d.ts.map +1 -0
- package/dist/services/operate/storage-layout.js +1244 -0
- package/dist/services/operate/storage-layout.js.map +1 -0
- package/dist/services/operate/storage-migration-service.d.ts +15 -0
- package/dist/services/operate/storage-migration-service.d.ts.map +1 -0
- package/dist/services/operate/storage-migration-service.js +27 -0
- package/dist/services/operate/storage-migration-service.js.map +1 -0
- package/dist/services/operate/store.d.ts +132 -0
- package/dist/services/operate/store.d.ts.map +1 -0
- package/dist/services/operate/store.js +1344 -0
- package/dist/services/operate/store.js.map +1 -0
- package/dist/services/pipeline-package-service.d.ts +93 -2
- package/dist/services/pipeline-package-service.d.ts.map +1 -1
- package/dist/services/pipeline-package-service.js +867 -7
- package/dist/services/pipeline-package-service.js.map +1 -1
- package/dist/services/planning-id-service.d.ts +8 -0
- package/dist/services/planning-id-service.d.ts.map +1 -0
- package/dist/services/planning-id-service.js +114 -0
- package/dist/services/planning-id-service.js.map +1 -0
- package/dist/services/provenance-service.d.ts +33 -1
- package/dist/services/provenance-service.d.ts.map +1 -1
- package/dist/services/provenance-service.js +104 -8
- package/dist/services/provenance-service.js.map +1 -1
- package/dist/services/runtime-manager/doctor.d.ts +22 -0
- package/dist/services/runtime-manager/doctor.d.ts.map +1 -0
- package/dist/services/runtime-manager/doctor.js +74 -0
- package/dist/services/runtime-manager/doctor.js.map +1 -0
- package/dist/services/runtime-manager/global-state.d.ts +47 -0
- package/dist/services/runtime-manager/global-state.d.ts.map +1 -0
- package/dist/services/runtime-manager/global-state.js +59 -0
- package/dist/services/runtime-manager/global-state.js.map +1 -0
- package/dist/services/runtime-manager/install-plan.d.ts +37 -0
- package/dist/services/runtime-manager/install-plan.d.ts.map +1 -0
- package/dist/services/runtime-manager/install-plan.js +91 -0
- package/dist/services/runtime-manager/install-plan.js.map +1 -0
- package/dist/services/runtime-manager/inventory.d.ts +29 -0
- package/dist/services/runtime-manager/inventory.d.ts.map +1 -0
- package/dist/services/runtime-manager/inventory.js +46 -0
- package/dist/services/runtime-manager/inventory.js.map +1 -0
- package/dist/services/runtime-manager-service.d.ts +16 -71
- package/dist/services/runtime-manager-service.d.ts.map +1 -1
- package/dist/services/runtime-manager-service.js +1288 -505
- package/dist/services/runtime-manager-service.js.map +1 -1
- package/dist/services/spec-service.d.ts +213 -39
- package/dist/services/spec-service.d.ts.map +1 -1
- package/dist/services/spec-service.js +938 -171
- package/dist/services/spec-service.js.map +1 -1
- package/dist/services/template-service.d.ts.map +1 -1
- package/dist/services/template-service.js +1 -0
- package/dist/services/template-service.js.map +1 -1
- package/dist/templates/quick/quick-task.md.hbs +6 -0
- package/dist/templates/rules/claude/CLAUDE.md.hbs +3 -111
- package/dist/templates/rules/codex/AGENTS.md.hbs +2 -92
- package/dist/templates/rules/cursor/create-task-list.mdc.hbs +1 -1
- package/dist/templates/rules/cursor/implement-task-list.mdc.hbs +5 -83
- package/dist/templates/rules/cursor/openplanr.mdc.hbs +12 -0
- package/dist/templates/rules/shared/host-native-guidance.md.hbs +12 -0
- package/dist/templates/rules/shared/implementation-guidance.md.hbs +44 -0
- package/dist/templates/spec/spec-shaped.md.hbs +66 -22
- package/dist/templates/spec/spec.md.hbs +46 -23
- package/dist/templates/spec/story.md.hbs +15 -4
- package/dist/templates/spec/task.md.hbs +53 -5
- package/dist/utils/constants.d.ts +1 -1
- package/dist/utils/constants.js +1 -1
- package/dist/utils/logger.d.ts +0 -3
- package/dist/utils/logger.d.ts.map +1 -1
- package/dist/utils/logger.js +0 -6
- package/dist/utils/logger.js.map +1 -1
- package/docs/ARTIFACT_REVIEW.md +110 -0
- package/docs/CLI.md +1216 -0
- package/docs/CROSS_RUNTIME_SETUP.md +168 -0
- package/docs/TROUBLESHOOTING.md +227 -0
- package/lib/dashboard-verifier.d.mts +29 -0
- package/lib/dashboard-verifier.mjs +307 -0
- package/lib/host-packages/adapter-registry.json +44 -0
- package/lib/host-packages/claude/.claude-plugin/marketplace.json +20 -0
- package/lib/host-packages/claude/openplanr/.claude-plugin/plugin.json +9 -0
- package/lib/host-packages/claude/openplanr/.openplanr-content.json +1179 -0
- package/lib/host-packages/claude/openplanr/agents/planr-backend.md +66 -0
- package/lib/host-packages/claude/openplanr/agents/planr-database.md +165 -0
- package/lib/host-packages/claude/openplanr/agents/planr-designer.md +57 -0
- package/lib/host-packages/claude/openplanr/agents/planr-devops.md +57 -0
- package/lib/host-packages/claude/openplanr/agents/planr-documentation.md +63 -0
- package/lib/host-packages/claude/openplanr/agents/planr-entity-scaffold.md +29 -0
- package/lib/host-packages/claude/openplanr/agents/planr-frontend.md +69 -0
- package/lib/host-packages/claude/openplanr/agents/planr-qa.md +162 -0
- package/lib/host-packages/claude/openplanr/agents/planr-specification.md +124 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/default/backend.md +93 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/default/designer.md +90 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/default/devops.md +55 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/default/doc-gen.md +67 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/default/frontend.md +94 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/default/qa.md +17 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/default/specification.md +111 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/shared/contract-create-modify-preserve.md +17 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/shared/design-craft-rubric.md +51 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/shared/design-principles.md +43 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/shared/design-spec-template.md +88 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/shared/task-context-resolution.md +60 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/shared/verification-and-recovery-backend.md +26 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/shared/verification-and-recovery-frontend.md +27 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/spec-driven/backend.md +96 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/spec-driven/designer.md +83 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/spec-driven/devops.md +55 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/spec-driven/doc-gen.md +67 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/spec-driven/frontend.md +96 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/spec-driven/qa.md +17 -0
- package/lib/host-packages/claude/openplanr/references/agents/shared/modes/spec-driven/specification.md +112 -0
- package/lib/host-packages/claude/openplanr/references/pipeline/stacks/backend/nestjs.md +130 -0
- package/lib/host-packages/claude/openplanr/references/pipeline/stacks/database/mongodb.md +122 -0
- package/lib/host-packages/claude/openplanr/references/pipeline/stacks/database/prisma.md +155 -0
- package/lib/host-packages/claude/openplanr/references/pipeline/stacks/devops/docker-compose.md +140 -0
- package/lib/host-packages/claude/openplanr/references/pipeline/stacks/frontend/nextjs.md +123 -0
- package/lib/host-packages/claude/openplanr/skills/artifact/SKILL.md +54 -0
- package/lib/host-packages/claude/openplanr/skills/artifact/openplanr.skill.json +48 -0
- package/lib/host-packages/claude/openplanr/skills/artifact/references/company-review.md +18 -0
- package/lib/host-packages/claude/openplanr/skills/artifact/references/design-sharing.md +51 -0
- package/lib/host-packages/claude/openplanr/skills/browser-qa/SKILL.md +34 -0
- package/lib/host-packages/claude/openplanr/skills/browser-qa/openplanr.skill.json +26 -0
- package/lib/host-packages/claude/openplanr/skills/ceo-review/SKILL.md +47 -0
- package/lib/host-packages/claude/openplanr/skills/ceo-review/openplanr.skill.json +81 -0
- package/lib/host-packages/claude/openplanr/skills/ceo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/claude/openplanr/skills/ceo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/claude/openplanr/skills/ceo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/claude/openplanr/skills/ceo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/claude/openplanr/skills/ceo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/claude/openplanr/skills/chair-review/SKILL.md +101 -0
- package/lib/host-packages/claude/openplanr/skills/chair-review/openplanr.skill.json +70 -0
- package/lib/host-packages/claude/openplanr/skills/chair-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/claude/openplanr/skills/chair-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/claude/openplanr/skills/chair-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/claude/openplanr/skills/chair-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/claude/openplanr/skills/challenger-review/SKILL.md +86 -0
- package/lib/host-packages/claude/openplanr/skills/challenger-review/openplanr.skill.json +70 -0
- package/lib/host-packages/claude/openplanr/skills/challenger-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/claude/openplanr/skills/challenger-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/claude/openplanr/skills/challenger-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/claude/openplanr/skills/challenger-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/claude/openplanr/skills/cmo-review/SKILL.md +46 -0
- package/lib/host-packages/claude/openplanr/skills/cmo-review/openplanr.skill.json +81 -0
- package/lib/host-packages/claude/openplanr/skills/cmo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/claude/openplanr/skills/cmo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/claude/openplanr/skills/cmo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/claude/openplanr/skills/cmo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/claude/openplanr/skills/cmo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/claude/openplanr/skills/coo-review/SKILL.md +45 -0
- package/lib/host-packages/claude/openplanr/skills/coo-review/openplanr.skill.json +81 -0
- package/lib/host-packages/claude/openplanr/skills/coo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/claude/openplanr/skills/coo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/claude/openplanr/skills/coo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/claude/openplanr/skills/coo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/claude/openplanr/skills/coo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/claude/openplanr/skills/cpo-review/SKILL.md +48 -0
- package/lib/host-packages/claude/openplanr/skills/cpo-review/openplanr.skill.json +81 -0
- package/lib/host-packages/claude/openplanr/skills/cpo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/claude/openplanr/skills/cpo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/claude/openplanr/skills/cpo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/claude/openplanr/skills/cpo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/claude/openplanr/skills/cpo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/claude/openplanr/skills/cto-review/SKILL.md +47 -0
- package/lib/host-packages/claude/openplanr/skills/cto-review/openplanr.skill.json +81 -0
- package/lib/host-packages/claude/openplanr/skills/cto-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/claude/openplanr/skills/cto-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/claude/openplanr/skills/cto-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/claude/openplanr/skills/cto-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/claude/openplanr/skills/cto-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/claude/openplanr/skills/dashboard/SKILL.md +20 -0
- package/lib/host-packages/claude/openplanr/skills/dashboard/openplanr.skill.json +26 -0
- package/lib/host-packages/claude/openplanr/skills/design/SKILL.md +73 -0
- package/lib/host-packages/claude/openplanr/skills/design/openplanr.skill.json +466 -0
- package/lib/host-packages/claude/openplanr/skills/design/references/craft.md +68 -0
- package/lib/host-packages/claude/openplanr/skills/design/references/design-spec-template.md +88 -0
- package/lib/host-packages/claude/openplanr/skills/design/references/design-system.md +33 -0
- package/lib/host-packages/claude/openplanr/skills/design/references/discovery.md +53 -0
- package/lib/host-packages/claude/openplanr/skills/design/references/generation.md +105 -0
- package/lib/host-packages/claude/openplanr/skills/design/references/handoff.md +47 -0
- package/lib/host-packages/claude/openplanr/skills/design/references/review.md +88 -0
- package/lib/host-packages/claude/openplanr/skills/design/references/team-review.md +131 -0
- package/lib/host-packages/claude/openplanr/skills/design/references/utilities.md +93 -0
- package/lib/host-packages/claude/openplanr/skills/design/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/claude/openplanr/skills/design/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/claude/openplanr/skills/design/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/design.mjs +17323 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/claude/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/SKILL.md +58 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/openplanr.skill.json +466 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/references/craft.md +68 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/references/design-spec-template.md +88 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/references/design-system.md +33 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/references/discovery.md +53 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/references/generation.md +105 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/references/handoff.md +47 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/references/review.md +88 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/references/team-review.md +131 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/references/utilities.md +93 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/design.mjs +17323 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/claude/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/SKILL.md +54 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/openplanr.skill.json +466 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/references/craft.md +68 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/references/design-spec-template.md +88 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/references/design-system.md +33 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/references/discovery.md +53 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/references/generation.md +105 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/references/handoff.md +47 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/references/review.md +88 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/references/team-review.md +131 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/references/utilities.md +93 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/design.mjs +17323 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/claude/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/claude/openplanr/skills/diagram/SKILL.md +65 -0
- package/lib/host-packages/claude/openplanr/skills/diagram/openplanr.skill.json +59 -0
- package/lib/host-packages/claude/openplanr/skills/diagram/references/diagram-document.md +86 -0
- package/lib/host-packages/claude/openplanr/skills/diagram/references/diagram-fidelity.md +19 -0
- package/lib/host-packages/claude/openplanr/skills/diagram/references/diagram-intent-to-ir.md +22 -0
- package/lib/host-packages/claude/openplanr/skills/doctor/SKILL.md +40 -0
- package/lib/host-packages/claude/openplanr/skills/doctor/openplanr.skill.json +37 -0
- package/lib/host-packages/claude/openplanr/skills/doctor/references/upgrade.md +106 -0
- package/lib/host-packages/claude/openplanr/skills/investigate/SKILL.md +31 -0
- package/lib/host-packages/claude/openplanr/skills/investigate/openplanr.skill.json +26 -0
- package/lib/host-packages/claude/openplanr/skills/land/SKILL.md +33 -0
- package/lib/host-packages/claude/openplanr/skills/land/openplanr.skill.json +26 -0
- package/lib/host-packages/claude/openplanr/skills/operate/SKILL.md +181 -0
- package/lib/host-packages/claude/openplanr/skills/operate/openplanr.skill.json +70 -0
- package/lib/host-packages/claude/openplanr/skills/operate/scripts/errors.mjs +8 -0
- package/lib/host-packages/claude/openplanr/skills/operate/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/claude/openplanr/skills/operate/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/claude/openplanr/skills/operate/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/claude/openplanr/skills/plan/SKILL.md +106 -0
- package/lib/host-packages/claude/openplanr/skills/plan/openplanr.skill.json +389 -0
- package/lib/host-packages/claude/openplanr/skills/plan/references/artifact-contract.md +39 -0
- package/lib/host-packages/claude/openplanr/skills/plan/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/claude/openplanr/skills/plan/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/claude/openplanr/skills/plan/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/design.mjs +17323 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/planning-ids.mjs +120 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/claude/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/claude/openplanr/skills/plan-review/SKILL.md +39 -0
- package/lib/host-packages/claude/openplanr/skills/plan-review/openplanr.skill.json +26 -0
- package/lib/host-packages/claude/openplanr/skills/release/SKILL.md +180 -0
- package/lib/host-packages/claude/openplanr/skills/release/assets/changelog-template.md +18 -0
- package/lib/host-packages/claude/openplanr/skills/release/assets/profile-template.md +45 -0
- package/lib/host-packages/claude/openplanr/skills/release/openplanr.skill.json +92 -0
- package/lib/host-packages/claude/openplanr/skills/release/references/cadence.md +92 -0
- package/lib/host-packages/claude/openplanr/skills/release/references/release-notes.md +127 -0
- package/lib/host-packages/claude/openplanr/skills/release/references/schemes.md +103 -0
- package/lib/host-packages/claude/openplanr/skills/release/scripts/collect_changes.sh +85 -0
- package/lib/host-packages/claude/openplanr/skills/ship/SKILL.md +80 -0
- package/lib/host-packages/claude/openplanr/skills/ship/openplanr.skill.json +48 -0
- package/lib/host-packages/claude/openplanr/skills/ship/references/result-contract.md +14 -0
- package/lib/host-packages/claude/openplanr/skills/ship/scripts/discover-verification.mjs +107 -0
- package/lib/host-packages/claude/openplanr/skills/spec/SKILL.md +53 -0
- package/lib/host-packages/claude/openplanr/skills/spec/openplanr.skill.json +37 -0
- package/lib/host-packages/claude/openplanr/skills/spec/references/specification-contract.md +32 -0
- package/lib/host-packages/claude/openplanr/skills/status/SKILL.md +21 -0
- package/lib/host-packages/claude/openplanr/skills/status/openplanr.skill.json +26 -0
- package/lib/host-packages/claude/openplanr/skills/sync/SKILL.md +30 -0
- package/lib/host-packages/claude/openplanr/skills/sync/openplanr.skill.json +37 -0
- package/lib/host-packages/claude/openplanr/skills/sync/scripts/sync.mjs +230 -0
- package/lib/host-packages/cursor/openplanr/.openplanr-content.json +939 -0
- package/lib/host-packages/cursor/openplanr/manifest.json +32 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-artifact/references/company-review.md +18 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-artifact/references/design-sharing.md +51 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-artifact.mdc +53 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-browser-qa.mdc +34 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-ceo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-ceo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-ceo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-ceo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-ceo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-ceo-review.mdc +45 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-chair-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-chair-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-chair-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-chair-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-chair-review.mdc +99 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-challenger-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-challenger-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-challenger-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-challenger-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-challenger-review.mdc +84 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cmo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cmo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cmo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cmo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cmo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cmo-review.mdc +44 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-coo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-coo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-coo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-coo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-coo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-coo-review.mdc +43 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cpo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cpo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cpo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cpo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cpo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cpo-review.mdc +46 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cto-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cto-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cto-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cto-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cto-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-cto-review.mdc +45 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-dashboard.mdc +19 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/references/craft.md +68 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/references/design-spec-template.md +88 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/references/design-system.md +33 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/references/discovery.md +53 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/references/generation.md +105 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/references/handoff.md +47 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/references/review.md +88 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/references/team-review.md +131 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/references/utilities.md +93 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/design.mjs +17323 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/references/craft.md +68 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/references/design-spec-template.md +88 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/references/design-system.md +33 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/references/discovery.md +53 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/references/generation.md +105 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/references/handoff.md +47 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/references/review.md +88 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/references/team-review.md +131 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/references/utilities.md +93 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/design.mjs +17323 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-loop.mdc +57 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/references/craft.md +68 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/references/design-spec-template.md +88 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/references/design-system.md +33 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/references/discovery.md +53 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/references/generation.md +105 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/references/handoff.md +47 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/references/review.md +88 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/references/team-review.md +131 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/references/utilities.md +93 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/design.mjs +17323 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design-review.mdc +53 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-design.mdc +72 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-diagram/references/diagram-document.md +86 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-diagram/references/diagram-fidelity.md +19 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-diagram/references/diagram-intent-to-ir.md +22 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-diagram.mdc +64 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-doctor/references/upgrade.md +106 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-doctor.mdc +39 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-investigate.mdc +31 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-land.mdc +32 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-operate/scripts/errors.mjs +8 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-operate/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-operate/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-operate/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-operate.mdc +180 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/references/artifact-contract.md +39 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/design.mjs +17323 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/planning-ids.mjs +120 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan-review.mdc +38 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-plan.mdc +105 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-release/assets/changelog-template.md +18 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-release/assets/profile-template.md +45 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-release/references/cadence.md +92 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-release/references/release-notes.md +127 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-release/references/schemes.md +103 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-release/scripts/collect_changes.sh +85 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-release.mdc +179 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-ship/references/result-contract.md +14 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-ship/scripts/discover-verification.mjs +107 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-ship.mdc +79 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-spec/references/specification-contract.md +32 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-spec.mdc +52 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-status.mdc +20 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-sync/scripts/sync.mjs +230 -0
- package/lib/host-packages/cursor/openplanr/rules/planr-sync.mdc +29 -0
- package/lib/host-packages/openai/.claude-plugin/marketplace.json +19 -0
- package/lib/host-packages/openai/openplanr/.codex-plugin/plugin.json +10 -0
- package/lib/host-packages/openai/openplanr/.openplanr-content.json +1139 -0
- package/lib/host-packages/openai/openplanr/skills/artifact/SKILL.md +54 -0
- package/lib/host-packages/openai/openplanr/skills/artifact/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/artifact/openplanr.skill.json +48 -0
- package/lib/host-packages/openai/openplanr/skills/artifact/references/company-review.md +18 -0
- package/lib/host-packages/openai/openplanr/skills/artifact/references/design-sharing.md +51 -0
- package/lib/host-packages/openai/openplanr/skills/browser-qa/SKILL.md +34 -0
- package/lib/host-packages/openai/openplanr/skills/browser-qa/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/browser-qa/openplanr.skill.json +26 -0
- package/lib/host-packages/openai/openplanr/skills/ceo-review/SKILL.md +47 -0
- package/lib/host-packages/openai/openplanr/skills/ceo-review/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/ceo-review/openplanr.skill.json +81 -0
- package/lib/host-packages/openai/openplanr/skills/ceo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/openai/openplanr/skills/ceo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/openai/openplanr/skills/ceo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/openai/openplanr/skills/ceo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/openai/openplanr/skills/ceo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/openai/openplanr/skills/chair-review/SKILL.md +101 -0
- package/lib/host-packages/openai/openplanr/skills/chair-review/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/chair-review/openplanr.skill.json +70 -0
- package/lib/host-packages/openai/openplanr/skills/chair-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/openai/openplanr/skills/chair-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/openai/openplanr/skills/chair-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/openai/openplanr/skills/chair-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/openai/openplanr/skills/challenger-review/SKILL.md +86 -0
- package/lib/host-packages/openai/openplanr/skills/challenger-review/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/challenger-review/openplanr.skill.json +70 -0
- package/lib/host-packages/openai/openplanr/skills/challenger-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/openai/openplanr/skills/challenger-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/openai/openplanr/skills/challenger-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/openai/openplanr/skills/challenger-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/openai/openplanr/skills/cmo-review/SKILL.md +46 -0
- package/lib/host-packages/openai/openplanr/skills/cmo-review/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/cmo-review/openplanr.skill.json +81 -0
- package/lib/host-packages/openai/openplanr/skills/cmo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/openai/openplanr/skills/cmo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/openai/openplanr/skills/cmo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/openai/openplanr/skills/cmo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/openai/openplanr/skills/cmo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/openai/openplanr/skills/coo-review/SKILL.md +45 -0
- package/lib/host-packages/openai/openplanr/skills/coo-review/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/coo-review/openplanr.skill.json +81 -0
- package/lib/host-packages/openai/openplanr/skills/coo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/openai/openplanr/skills/coo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/openai/openplanr/skills/coo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/openai/openplanr/skills/coo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/openai/openplanr/skills/coo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/openai/openplanr/skills/cpo-review/SKILL.md +48 -0
- package/lib/host-packages/openai/openplanr/skills/cpo-review/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/cpo-review/openplanr.skill.json +81 -0
- package/lib/host-packages/openai/openplanr/skills/cpo-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/openai/openplanr/skills/cpo-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/openai/openplanr/skills/cpo-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/openai/openplanr/skills/cpo-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/openai/openplanr/skills/cpo-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/openai/openplanr/skills/cto-review/SKILL.md +47 -0
- package/lib/host-packages/openai/openplanr/skills/cto-review/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/cto-review/openplanr.skill.json +81 -0
- package/lib/host-packages/openai/openplanr/skills/cto-review/references/operate-advisor-contract.md +111 -0
- package/lib/host-packages/openai/openplanr/skills/cto-review/scripts/errors.mjs +8 -0
- package/lib/host-packages/openai/openplanr/skills/cto-review/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/openai/openplanr/skills/cto-review/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/openai/openplanr/skills/cto-review/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/openai/openplanr/skills/dashboard/SKILL.md +20 -0
- package/lib/host-packages/openai/openplanr/skills/dashboard/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/dashboard/openplanr.skill.json +26 -0
- package/lib/host-packages/openai/openplanr/skills/design/SKILL.md +73 -0
- package/lib/host-packages/openai/openplanr/skills/design/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/design/openplanr.skill.json +466 -0
- package/lib/host-packages/openai/openplanr/skills/design/references/craft.md +68 -0
- package/lib/host-packages/openai/openplanr/skills/design/references/design-spec-template.md +88 -0
- package/lib/host-packages/openai/openplanr/skills/design/references/design-system.md +33 -0
- package/lib/host-packages/openai/openplanr/skills/design/references/discovery.md +53 -0
- package/lib/host-packages/openai/openplanr/skills/design/references/generation.md +105 -0
- package/lib/host-packages/openai/openplanr/skills/design/references/handoff.md +47 -0
- package/lib/host-packages/openai/openplanr/skills/design/references/review.md +88 -0
- package/lib/host-packages/openai/openplanr/skills/design/references/team-review.md +131 -0
- package/lib/host-packages/openai/openplanr/skills/design/references/utilities.md +93 -0
- package/lib/host-packages/openai/openplanr/skills/design/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/openai/openplanr/skills/design/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/openai/openplanr/skills/design/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/design.mjs +17323 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/openai/openplanr/skills/design/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/SKILL.md +58 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/openplanr.skill.json +466 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/references/craft.md +68 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/references/design-spec-template.md +88 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/references/design-system.md +33 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/references/discovery.md +53 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/references/generation.md +105 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/references/handoff.md +47 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/references/review.md +88 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/references/team-review.md +131 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/references/utilities.md +93 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/design.mjs +17323 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/openai/openplanr/skills/design-loop/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/SKILL.md +54 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/openplanr.skill.json +466 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/references/craft.md +68 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/references/design-spec-template.md +88 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/references/design-system.md +33 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/references/discovery.md +53 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/references/generation.md +105 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/references/handoff.md +47 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/references/review.md +88 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/references/team-review.md +131 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/references/utilities.md +93 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/design.mjs +17323 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/openai/openplanr/skills/design-review/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/openai/openplanr/skills/diagram/SKILL.md +65 -0
- package/lib/host-packages/openai/openplanr/skills/diagram/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/diagram/openplanr.skill.json +59 -0
- package/lib/host-packages/openai/openplanr/skills/diagram/references/diagram-document.md +86 -0
- package/lib/host-packages/openai/openplanr/skills/diagram/references/diagram-fidelity.md +19 -0
- package/lib/host-packages/openai/openplanr/skills/diagram/references/diagram-intent-to-ir.md +22 -0
- package/lib/host-packages/openai/openplanr/skills/doctor/SKILL.md +40 -0
- package/lib/host-packages/openai/openplanr/skills/doctor/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/doctor/openplanr.skill.json +37 -0
- package/lib/host-packages/openai/openplanr/skills/doctor/references/upgrade.md +106 -0
- package/lib/host-packages/openai/openplanr/skills/investigate/SKILL.md +31 -0
- package/lib/host-packages/openai/openplanr/skills/investigate/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/investigate/openplanr.skill.json +26 -0
- package/lib/host-packages/openai/openplanr/skills/land/SKILL.md +33 -0
- package/lib/host-packages/openai/openplanr/skills/land/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/land/openplanr.skill.json +26 -0
- package/lib/host-packages/openai/openplanr/skills/operate/SKILL.md +181 -0
- package/lib/host-packages/openai/openplanr/skills/operate/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/operate/openplanr.skill.json +70 -0
- package/lib/host-packages/openai/openplanr/skills/operate/scripts/errors.mjs +8 -0
- package/lib/host-packages/openai/openplanr/skills/operate/scripts/operate-review-contract.mjs +438 -0
- package/lib/host-packages/openai/openplanr/skills/operate/scripts/operate-review-note.mjs +595 -0
- package/lib/host-packages/openai/openplanr/skills/operate/scripts/validate-note.mjs +31 -0
- package/lib/host-packages/openai/openplanr/skills/plan/SKILL.md +106 -0
- package/lib/host-packages/openai/openplanr/skills/plan/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/plan/openplanr.skill.json +389 -0
- package/lib/host-packages/openai/openplanr/skills/plan/references/artifact-contract.md +39 -0
- package/lib/host-packages/openai/openplanr/skills/plan/schemas/design-document.schema.json +306 -0
- package/lib/host-packages/openai/openplanr/skills/plan/schemas/design-review-context.schema.json +191 -0
- package/lib/host-packages/openai/openplanr/skills/plan/schemas/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/design.mjs +17323 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/planning-ids.mjs +120 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/notices/entities.txt +13 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/notices/parse5.txt +21 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/artifact/templates/artifact-review-stage.js +3994 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/enhancements.css +378 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/enhancements.js +805 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/share.css +1 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/share.js +132 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/studio.css +1103 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/design/templates/studio/studio.js +1775 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/package.json +115 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/registry/artifact-theme.json +60 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.0.0/design-manifest.schema.json +90 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-envelope.schema.json +142 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-paste.schema.json +49 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-review.schema.json +97 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.1.0/artifact-theme.schema.json +139 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-bundle.schema.json +584 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-context.schema.json +191 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-handoff.schema.json +407 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.10.0/design-review-metadata-payload.schema.json +106 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.11.0/design-review-metadata-payload.schema.json +107 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-document.schema.json +306 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-bundle.schema.json +346 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-review-workspace.schema.json +108 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-create.schema.json +170 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-event.schema.json +97 -0
- package/lib/host-packages/openai/openplanr/skills/plan/scripts/runtime/packages/protocol/schemas/v1.9.0/design-workspace-revision.schema.json +56 -0
- package/lib/host-packages/openai/openplanr/skills/plan-review/SKILL.md +39 -0
- package/lib/host-packages/openai/openplanr/skills/plan-review/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/plan-review/openplanr.skill.json +26 -0
- package/lib/host-packages/openai/openplanr/skills/release/SKILL.md +180 -0
- package/lib/host-packages/openai/openplanr/skills/release/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/release/assets/changelog-template.md +18 -0
- package/lib/host-packages/openai/openplanr/skills/release/assets/profile-template.md +45 -0
- package/lib/host-packages/openai/openplanr/skills/release/openplanr.skill.json +92 -0
- package/lib/host-packages/openai/openplanr/skills/release/references/cadence.md +92 -0
- package/lib/host-packages/openai/openplanr/skills/release/references/release-notes.md +127 -0
- package/lib/host-packages/openai/openplanr/skills/release/references/schemes.md +103 -0
- package/lib/host-packages/openai/openplanr/skills/release/scripts/collect_changes.sh +85 -0
- package/lib/host-packages/openai/openplanr/skills/ship/SKILL.md +80 -0
- package/lib/host-packages/openai/openplanr/skills/ship/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/ship/openplanr.skill.json +48 -0
- package/lib/host-packages/openai/openplanr/skills/ship/references/result-contract.md +14 -0
- package/lib/host-packages/openai/openplanr/skills/ship/scripts/discover-verification.mjs +107 -0
- package/lib/host-packages/openai/openplanr/skills/spec/SKILL.md +53 -0
- package/lib/host-packages/openai/openplanr/skills/spec/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/spec/openplanr.skill.json +37 -0
- package/lib/host-packages/openai/openplanr/skills/spec/references/specification-contract.md +32 -0
- package/lib/host-packages/openai/openplanr/skills/status/SKILL.md +21 -0
- package/lib/host-packages/openai/openplanr/skills/status/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/status/openplanr.skill.json +26 -0
- package/lib/host-packages/openai/openplanr/skills/sync/SKILL.md +30 -0
- package/lib/host-packages/openai/openplanr/skills/sync/agents/openai.yaml +6 -0
- package/lib/host-packages/openai/openplanr/skills/sync/openplanr.skill.json +37 -0
- package/lib/host-packages/openai/openplanr/skills/sync/scripts/sync.mjs +230 -0
- package/lib/integrations.d.mts +43 -0
- package/lib/integrations.mjs +230 -0
- package/lib/skill-runtime/errors.mjs +8 -0
- package/lib/skill-runtime/operate-review-contract.mjs +438 -0
- package/lib/skill-runtime/operate-review-note.mjs +595 -0
- package/package.json +56 -18
- package/dist/ai/codebase/context-builder.d.ts +0 -50
- package/dist/ai/codebase/context-builder.d.ts.map +0 -1
- package/dist/ai/codebase/context-builder.js +0 -281
- package/dist/ai/codebase/context-builder.js.map +0 -1
- package/dist/ai/codebase/file-reader.d.ts +0 -22
- package/dist/ai/codebase/file-reader.d.ts.map +0 -1
- package/dist/ai/codebase/file-reader.js +0 -144
- package/dist/ai/codebase/file-reader.js.map +0 -1
- package/dist/ai/codebase/index.d.ts +0 -7
- package/dist/ai/codebase/index.d.ts.map +0 -1
- package/dist/ai/codebase/index.js +0 -7
- package/dist/ai/codebase/index.js.map +0 -1
- package/dist/ai/codebase/pattern-rules.d.ts +0 -28
- package/dist/ai/codebase/pattern-rules.d.ts.map +0 -1
- package/dist/ai/codebase/pattern-rules.js +0 -186
- package/dist/ai/codebase/pattern-rules.js.map +0 -1
- package/dist/ai/codebase/rules-reader.d.ts +0 -14
- package/dist/ai/codebase/rules-reader.d.ts.map +0 -1
- package/dist/ai/codebase/rules-reader.js +0 -25
- package/dist/ai/codebase/rules-reader.js.map +0 -1
- package/dist/ai/codebase/stack-detector.d.ts +0 -18
- package/dist/ai/codebase/stack-detector.d.ts.map +0 -1
- package/dist/ai/codebase/stack-detector.js +0 -173
- package/dist/ai/codebase/stack-detector.js.map +0 -1
- package/dist/ai/codebase/tree-generator.d.ts +0 -8
- package/dist/ai/codebase/tree-generator.d.ts.map +0 -1
- package/dist/ai/codebase/tree-generator.js +0 -84
- package/dist/ai/codebase/tree-generator.js.map +0 -1
- package/dist/ai/errors.d.ts +0 -22
- package/dist/ai/errors.d.ts.map +0 -1
- package/dist/ai/errors.js +0 -72
- package/dist/ai/errors.js.map +0 -1
- package/dist/ai/index.d.ts +0 -11
- package/dist/ai/index.d.ts.map +0 -1
- package/dist/ai/index.js +0 -10
- package/dist/ai/index.js.map +0 -1
- package/dist/ai/prompts/prompt-builder.d.ts +0 -134
- package/dist/ai/prompts/prompt-builder.d.ts.map +0 -1
- package/dist/ai/prompts/prompt-builder.js +0 -295
- package/dist/ai/prompts/prompt-builder.js.map +0 -1
- package/dist/ai/prompts/system-prompts.d.ts +0 -41
- package/dist/ai/prompts/system-prompts.d.ts.map +0 -1
- package/dist/ai/prompts/system-prompts.js +0 -512
- package/dist/ai/prompts/system-prompts.js.map +0 -1
- package/dist/ai/provider-factory.d.ts +0 -10
- package/dist/ai/provider-factory.d.ts.map +0 -1
- package/dist/ai/provider-factory.js +0 -49
- package/dist/ai/provider-factory.js.map +0 -1
- package/dist/ai/providers/anthropic-provider.d.ts +0 -24
- package/dist/ai/providers/anthropic-provider.d.ts.map +0 -1
- package/dist/ai/providers/anthropic-provider.js +0 -97
- package/dist/ai/providers/anthropic-provider.js.map +0 -1
- package/dist/ai/providers/ollama-provider.d.ts +0 -13
- package/dist/ai/providers/ollama-provider.d.ts.map +0 -1
- package/dist/ai/providers/ollama-provider.js +0 -16
- package/dist/ai/providers/ollama-provider.js.map +0 -1
- package/dist/ai/providers/openai-provider.d.ts +0 -19
- package/dist/ai/providers/openai-provider.d.ts.map +0 -1
- package/dist/ai/providers/openai-provider.js +0 -84
- package/dist/ai/providers/openai-provider.js.map +0 -1
- package/dist/ai/schemas/ai-response-schemas.d.ts +0 -340
- package/dist/ai/schemas/ai-response-schemas.d.ts.map +0 -1
- package/dist/ai/schemas/ai-response-schemas.js +0 -278
- package/dist/ai/schemas/ai-response-schemas.js.map +0 -1
- package/dist/ai/types.d.ts +0 -76
- package/dist/ai/types.d.ts.map +0 -1
- package/dist/ai/types.js +0 -49
- package/dist/ai/types.js.map +0 -1
- package/dist/ai/validation/index.d.ts +0 -2
- package/dist/ai/validation/index.d.ts.map +0 -1
- package/dist/ai/validation/index.js +0 -2
- package/dist/ai/validation/index.js.map +0 -1
- package/dist/ai/validation/task-validator.d.ts +0 -37
- package/dist/ai/validation/task-validator.d.ts.map +0 -1
- package/dist/ai/validation/task-validator.js +0 -81
- package/dist/ai/validation/task-validator.js.map +0 -1
- package/dist/cli/commands/config.d.ts +0 -8
- package/dist/cli/commands/config.d.ts.map +0 -1
- package/dist/cli/commands/config.js +0 -224
- package/dist/cli/commands/config.js.map +0 -1
- package/dist/cli/commands/estimate.d.ts +0 -3
- package/dist/cli/commands/estimate.d.ts.map +0 -1
- package/dist/cli/commands/estimate.js +0 -368
- package/dist/cli/commands/estimate.js.map +0 -1
- package/dist/cli/commands/init.d.ts +0 -9
- package/dist/cli/commands/init.d.ts.map +0 -1
- package/dist/cli/commands/init.js +0 -166
- package/dist/cli/commands/init.js.map +0 -1
- package/dist/cli/commands/pipeline.d.ts +0 -3
- package/dist/cli/commands/pipeline.d.ts.map +0 -1
- package/dist/cli/commands/pipeline.js +0 -59
- package/dist/cli/commands/pipeline.js.map +0 -1
- package/dist/cli/commands/plan.d.ts +0 -15
- package/dist/cli/commands/plan.d.ts.map +0 -1
- package/dist/cli/commands/plan.js +0 -444
- package/dist/cli/commands/plan.js.map +0 -1
- package/dist/cli/commands/refine.d.ts +0 -10
- package/dist/cli/commands/refine.d.ts.map +0 -1
- package/dist/cli/commands/refine.js +0 -226
- package/dist/cli/commands/refine.js.map +0 -1
- package/dist/cli/commands/revise.d.ts +0 -24
- package/dist/cli/commands/revise.d.ts.map +0 -1
- package/dist/cli/commands/revise.js +0 -572
- package/dist/cli/commands/revise.js.map +0 -1
- package/dist/cli/helpers/task-creation.d.ts +0 -89
- package/dist/cli/helpers/task-creation.d.ts.map +0 -1
- package/dist/cli/helpers/task-creation.js +0 -139
- package/dist/cli/helpers/task-creation.js.map +0 -1
- package/dist/services/ai-service.d.ts +0 -77
- package/dist/services/ai-service.d.ts.map +0 -1
- package/dist/services/ai-service.js +0 -241
- package/dist/services/ai-service.js.map +0 -1
- package/dist/services/artifact-gathering.d.ts +0 -55
- package/dist/services/artifact-gathering.d.ts.map +0 -1
- package/dist/services/artifact-gathering.js +0 -147
- package/dist/services/artifact-gathering.js.map +0 -1
- package/dist/services/operate/advisors.d.ts +0 -625
- package/dist/services/operate/advisors.d.ts.map +0 -1
- package/dist/services/operate/advisors.js +0 -1545
- package/dist/services/operate/advisors.js.map +0 -1
- package/dist/services/operate/artifact-route-generation.d.ts +0 -111
- package/dist/services/operate/artifact-route-generation.d.ts.map +0 -1
- package/dist/services/operate/artifact-route-generation.js +0 -460
- package/dist/services/operate/artifact-route-generation.js.map +0 -1
- package/dist/services/operate/artifacts.d.ts +0 -66
- package/dist/services/operate/artifacts.d.ts.map +0 -1
- package/dist/services/operate/artifacts.js +0 -336
- package/dist/services/operate/artifacts.js.map +0 -1
- package/dist/services/operate/cadence.d.ts +0 -50
- package/dist/services/operate/cadence.d.ts.map +0 -1
- package/dist/services/operate/cadence.js +0 -56
- package/dist/services/operate/cadence.js.map +0 -1
- package/dist/services/operate/canonical.d.ts +0 -18
- package/dist/services/operate/canonical.d.ts.map +0 -1
- package/dist/services/operate/canonical.js +0 -157
- package/dist/services/operate/canonical.js.map +0 -1
- package/dist/services/operate/citation-resolution.d.ts +0 -161
- package/dist/services/operate/citation-resolution.d.ts.map +0 -1
- package/dist/services/operate/citation-resolution.js +0 -593
- package/dist/services/operate/citation-resolution.js.map +0 -1
- package/dist/services/operate/completion.d.ts +0 -80
- package/dist/services/operate/completion.d.ts.map +0 -1
- package/dist/services/operate/completion.js +0 -279
- package/dist/services/operate/completion.js.map +0 -1
- package/dist/services/operate/config.d.ts +0 -154
- package/dist/services/operate/config.d.ts.map +0 -1
- package/dist/services/operate/config.js +0 -791
- package/dist/services/operate/config.js.map +0 -1
- package/dist/services/operate/consolidation.d.ts +0 -18
- package/dist/services/operate/consolidation.d.ts.map +0 -1
- package/dist/services/operate/consolidation.js +0 -539
- package/dist/services/operate/consolidation.js.map +0 -1
- package/dist/services/operate/context-research.d.ts +0 -84
- package/dist/services/operate/context-research.d.ts.map +0 -1
- package/dist/services/operate/context-research.js +0 -448
- package/dist/services/operate/context-research.js.map +0 -1
- package/dist/services/operate/decision-brief.d.ts +0 -237
- package/dist/services/operate/decision-brief.d.ts.map +0 -1
- package/dist/services/operate/decision-brief.js +0 -368
- package/dist/services/operate/decision-brief.js.map +0 -1
- package/dist/services/operate/doctor.d.ts +0 -85
- package/dist/services/operate/doctor.d.ts.map +0 -1
- package/dist/services/operate/doctor.js +0 -1070
- package/dist/services/operate/doctor.js.map +0 -1
- package/dist/services/operate/drafts.d.ts +0 -48
- package/dist/services/operate/drafts.d.ts.map +0 -1
- package/dist/services/operate/drafts.js +0 -398
- package/dist/services/operate/drafts.js.map +0 -1
- package/dist/services/operate/engine.d.ts +0 -151
- package/dist/services/operate/engine.d.ts.map +0 -1
- package/dist/services/operate/engine.js +0 -1896
- package/dist/services/operate/engine.js.map +0 -1
- package/dist/services/operate/event-store.d.ts +0 -113
- package/dist/services/operate/event-store.d.ts.map +0 -1
- package/dist/services/operate/event-store.js +0 -384
- package/dist/services/operate/event-store.js.map +0 -1
- package/dist/services/operate/evidence-cache.d.ts +0 -41
- package/dist/services/operate/evidence-cache.d.ts.map +0 -1
- package/dist/services/operate/evidence-cache.js +0 -193
- package/dist/services/operate/evidence-cache.js.map +0 -1
- package/dist/services/operate/evidence-import.d.ts +0 -40
- package/dist/services/operate/evidence-import.d.ts.map +0 -1
- package/dist/services/operate/evidence-import.js +0 -340
- package/dist/services/operate/evidence-import.js.map +0 -1
- package/dist/services/operate/evidence.d.ts +0 -21
- package/dist/services/operate/evidence.d.ts.map +0 -1
- package/dist/services/operate/evidence.js +0 -20
- package/dist/services/operate/evidence.js.map +0 -1
- package/dist/services/operate/ids.d.ts +0 -7
- package/dist/services/operate/ids.d.ts.map +0 -1
- package/dist/services/operate/ids.js +0 -23
- package/dist/services/operate/ids.js.map +0 -1
- package/dist/services/operate/index.d.ts +0 -16
- package/dist/services/operate/index.d.ts.map +0 -1
- package/dist/services/operate/index.js +0 -1864
- package/dist/services/operate/index.js.map +0 -1
- package/dist/services/operate/integrity.d.ts +0 -81
- package/dist/services/operate/integrity.d.ts.map +0 -1
- package/dist/services/operate/integrity.js +0 -152
- package/dist/services/operate/integrity.js.map +0 -1
- package/dist/services/operate/interaction/action-service.d.ts +0 -34
- package/dist/services/operate/interaction/action-service.d.ts.map +0 -1
- package/dist/services/operate/interaction/action-service.js +0 -103
- package/dist/services/operate/interaction/action-service.js.map +0 -1
- package/dist/services/operate/interaction/answer-service.d.ts +0 -40
- package/dist/services/operate/interaction/answer-service.d.ts.map +0 -1
- package/dist/services/operate/interaction/answer-service.js +0 -317
- package/dist/services/operate/interaction/answer-service.js.map +0 -1
- package/dist/services/operate/interaction/charter-suggestions.d.ts +0 -29
- package/dist/services/operate/interaction/charter-suggestions.d.ts.map +0 -1
- package/dist/services/operate/interaction/charter-suggestions.js +0 -104
- package/dist/services/operate/interaction/charter-suggestions.js.map +0 -1
- package/dist/services/operate/interaction/confirmation-service.d.ts +0 -30
- package/dist/services/operate/interaction/confirmation-service.d.ts.map +0 -1
- package/dist/services/operate/interaction/confirmation-service.js +0 -78
- package/dist/services/operate/interaction/confirmation-service.js.map +0 -1
- package/dist/services/operate/interaction/initialization-replay.d.ts +0 -9
- package/dist/services/operate/interaction/initialization-replay.d.ts.map +0 -1
- package/dist/services/operate/interaction/initialization-replay.js +0 -64
- package/dist/services/operate/interaction/initialization-replay.js.map +0 -1
- package/dist/services/operate/interaction/question-engine.d.ts +0 -41
- package/dist/services/operate/interaction/question-engine.d.ts.map +0 -1
- package/dist/services/operate/interaction/question-engine.js +0 -434
- package/dist/services/operate/interaction/question-engine.js.map +0 -1
- package/dist/services/operate/interaction/question-registry.d.ts +0 -52
- package/dist/services/operate/interaction/question-registry.d.ts.map +0 -1
- package/dist/services/operate/interaction/question-registry.js +0 -305
- package/dist/services/operate/interaction/question-registry.js.map +0 -1
- package/dist/services/operate/interaction/session-service.d.ts +0 -55
- package/dist/services/operate/interaction/session-service.d.ts.map +0 -1
- package/dist/services/operate/interaction/session-service.js +0 -304
- package/dist/services/operate/interaction/session-service.js.map +0 -1
- package/dist/services/operate/interaction/terminal-renderer.d.ts +0 -19
- package/dist/services/operate/interaction/terminal-renderer.d.ts.map +0 -1
- package/dist/services/operate/interaction/terminal-renderer.js +0 -124
- package/dist/services/operate/interaction/terminal-renderer.js.map +0 -1
- package/dist/services/operate/journal.d.ts +0 -34
- package/dist/services/operate/journal.d.ts.map +0 -1
- package/dist/services/operate/journal.js +0 -235
- package/dist/services/operate/journal.js.map +0 -1
- package/dist/services/operate/legacy-import-service.d.ts +0 -58
- package/dist/services/operate/legacy-import-service.d.ts.map +0 -1
- package/dist/services/operate/legacy-import-service.js +0 -922
- package/dist/services/operate/legacy-import-service.js.map +0 -1
- package/dist/services/operate/lifecycle-driver.d.ts +0 -309
- package/dist/services/operate/lifecycle-driver.d.ts.map +0 -1
- package/dist/services/operate/lifecycle-driver.js +0 -434
- package/dist/services/operate/lifecycle-driver.js.map +0 -1
- package/dist/services/operate/lifecycle.d.ts +0 -96
- package/dist/services/operate/lifecycle.d.ts.map +0 -1
- package/dist/services/operate/lifecycle.js +0 -596
- package/dist/services/operate/lifecycle.js.map +0 -1
- package/dist/services/operate/lock-service.d.ts +0 -37
- package/dist/services/operate/lock-service.d.ts.map +0 -1
- package/dist/services/operate/lock-service.js +0 -215
- package/dist/services/operate/lock-service.js.map +0 -1
- package/dist/services/operate/maintenance.d.ts +0 -139
- package/dist/services/operate/maintenance.d.ts.map +0 -1
- package/dist/services/operate/maintenance.js +0 -2200
- package/dist/services/operate/maintenance.js.map +0 -1
- package/dist/services/operate/migration.d.ts +0 -68
- package/dist/services/operate/migration.d.ts.map +0 -1
- package/dist/services/operate/migration.js +0 -243
- package/dist/services/operate/migration.js.map +0 -1
- package/dist/services/operate/mission-dispatch.d.ts +0 -271
- package/dist/services/operate/mission-dispatch.d.ts.map +0 -1
- package/dist/services/operate/mission-dispatch.js +0 -590
- package/dist/services/operate/mission-dispatch.js.map +0 -1
- package/dist/services/operate/outcomes.d.ts +0 -48
- package/dist/services/operate/outcomes.d.ts.map +0 -1
- package/dist/services/operate/outcomes.js +0 -312
- package/dist/services/operate/outcomes.js.map +0 -1
- package/dist/services/operate/pipeline-handoff.d.ts +0 -138
- package/dist/services/operate/pipeline-handoff.d.ts.map +0 -1
- package/dist/services/operate/pipeline-handoff.js +0 -175
- package/dist/services/operate/pipeline-handoff.js.map +0 -1
- package/dist/services/operate/profile-migration.d.ts +0 -69
- package/dist/services/operate/profile-migration.d.ts.map +0 -1
- package/dist/services/operate/profile-migration.js +0 -462
- package/dist/services/operate/profile-migration.js.map +0 -1
- package/dist/services/operate/projection-persistence.d.ts +0 -126
- package/dist/services/operate/projection-persistence.d.ts.map +0 -1
- package/dist/services/operate/projection-persistence.js +0 -752
- package/dist/services/operate/projection-persistence.js.map +0 -1
- package/dist/services/operate/projection.d.ts +0 -37
- package/dist/services/operate/projection.d.ts.map +0 -1
- package/dist/services/operate/projection.js +0 -209
- package/dist/services/operate/projection.js.map +0 -1
- package/dist/services/operate/protocol.d.ts +0 -86
- package/dist/services/operate/protocol.d.ts.map +0 -1
- package/dist/services/operate/protocol.js +0 -76
- package/dist/services/operate/protocol.js.map +0 -1
- package/dist/services/operate/read-only-providers.d.ts +0 -76
- package/dist/services/operate/read-only-providers.d.ts.map +0 -1
- package/dist/services/operate/read-only-providers.js +0 -421
- package/dist/services/operate/read-only-providers.js.map +0 -1
- package/dist/services/operate/redaction.d.ts +0 -74
- package/dist/services/operate/redaction.d.ts.map +0 -1
- package/dist/services/operate/redaction.js +0 -406
- package/dist/services/operate/redaction.js.map +0 -1
- package/dist/services/operate/reducer.d.ts +0 -10
- package/dist/services/operate/reducer.d.ts.map +0 -1
- package/dist/services/operate/reducer.js +0 -11
- package/dist/services/operate/reducer.js.map +0 -1
- package/dist/services/operate/report-html.d.ts +0 -32
- package/dist/services/operate/report-html.d.ts.map +0 -1
- package/dist/services/operate/report-html.js +0 -289
- package/dist/services/operate/report-html.js.map +0 -1
- package/dist/services/operate/reports.d.ts +0 -72
- package/dist/services/operate/reports.d.ts.map +0 -1
- package/dist/services/operate/reports.js +0 -481
- package/dist/services/operate/reports.js.map +0 -1
- package/dist/services/operate/routes.d.ts +0 -133
- package/dist/services/operate/routes.d.ts.map +0 -1
- package/dist/services/operate/routes.js +0 -1577
- package/dist/services/operate/routes.js.map +0 -1
- package/dist/services/operate/scratch.d.ts +0 -81
- package/dist/services/operate/scratch.d.ts.map +0 -1
- package/dist/services/operate/scratch.js +0 -190
- package/dist/services/operate/scratch.js.map +0 -1
- package/dist/services/operate/shipment-observer.d.ts +0 -14
- package/dist/services/operate/shipment-observer.d.ts.map +0 -1
- package/dist/services/operate/shipment-observer.js +0 -320
- package/dist/services/operate/shipment-observer.js.map +0 -1
- package/dist/services/operate/stalled-item-service.d.ts +0 -18
- package/dist/services/operate/stalled-item-service.d.ts.map +0 -1
- package/dist/services/operate/stalled-item-service.js +0 -121
- package/dist/services/operate/stalled-item-service.js.map +0 -1
- package/dist/services/operate/subprocess-env.d.ts +0 -4
- package/dist/services/operate/subprocess-env.d.ts.map +0 -1
- package/dist/services/operate/subprocess-env.js +0 -45
- package/dist/services/operate/subprocess-env.js.map +0 -1
- package/dist/services/operate/types.d.ts +0 -1064
- package/dist/services/operate/types.d.ts.map +0 -1
- package/dist/services/operate/types.js +0 -27
- package/dist/services/operate/types.js.map +0 -1
- package/dist/services/operate/workspace.d.ts +0 -76
- package/dist/services/operate/workspace.d.ts.map +0 -1
- package/dist/services/operate/workspace.js +0 -350
- package/dist/services/operate/workspace.js.map +0 -1
- package/dist/services/revise-service.d.ts +0 -115
- package/dist/services/revise-service.d.ts.map +0 -1
- package/dist/services/revise-service.js +0 -294
- package/dist/services/revise-service.js.map +0 -1
- package/dist/templates/rules/claude/planr-pipeline.md.hbs +0 -69
- package/dist/templates/rules/codex/_pipeline-section.md.hbs +0 -154
- package/dist/templates/rules/cursor/agents/backend-agent.md +0 -299
- package/dist/templates/rules/cursor/agents/db-agent.md +0 -163
- package/dist/templates/rules/cursor/agents/designer-agent.md +0 -219
- package/dist/templates/rules/cursor/agents/devops-agent.md +0 -197
- package/dist/templates/rules/cursor/agents/doc-gen-agent.md +0 -203
- package/dist/templates/rules/cursor/agents/frontend-agent.md +0 -220
- package/dist/templates/rules/cursor/agents/qa-agent.md +0 -170
- package/dist/templates/rules/cursor/agents/specification-agent.md +0 -282
- package/dist/templates/rules/cursor/planr-pipeline-plan.mdc.hbs +0 -196
- package/dist/templates/rules/cursor/planr-pipeline-ship.mdc.hbs +0 -246
- package/dist/templates/rules/cursor/planr-pipeline.mdc.hbs +0 -134
|
@@ -1,1864 +0,0 @@
|
|
|
1
|
-
import { readFile } from 'node:fs/promises';
|
|
2
|
-
import path from 'node:path';
|
|
3
|
-
import { resolveAIProviderReadiness } from '../ai-service.js';
|
|
4
|
-
import { loadConfig } from '../config-service.js';
|
|
5
|
-
import { computeNextDueAt } from './cadence.js';
|
|
6
|
-
import { canonicalDigest, sha256Digest } from './canonical.js';
|
|
7
|
-
import { verifyOperatingCompletionPhases } from './completion.js';
|
|
8
|
-
import { applyOperatingInitialization, getOperatingProfile, listOperatingProfiles, normalizeCustomOperatingProfile, normalizeOperatingInitializationAnswers, prepareOperatingInitialization, readOperatingLastRunAt, validateOperatingConfiguration, } from './config.js';
|
|
9
|
-
import { operatingInitializationAnswersFromResearch, prepareOperatingContextResearch, readOperatingContextResearch, recordOperatingContextResearch, } from './context-research.js';
|
|
10
|
-
import { approveOperatingDraft, discardOperatingDraft, listOperatingDrafts, materializeOperatingDrafts, showOperatingDraft, } from './drafts.js';
|
|
11
|
-
import { runOperatingCycle } from './engine.js';
|
|
12
|
-
import { OperatingEventStore } from './event-store.js';
|
|
13
|
-
import { parseStrictJson } from './evidence-import.js';
|
|
14
|
-
import { createOperatingAction } from './interaction/action-service.js';
|
|
15
|
-
import { persistableOperatingInitAnswers, probeGitUserName, probePipelineInstalled, resumeGuidedSession, submitGuidedAnswers, } from './interaction/answer-service.js';
|
|
16
|
-
import { assertOperatingConfirmation } from './interaction/confirmation-service.js';
|
|
17
|
-
import { decodeOperatingInitializationReplay, encodeOperatingInitializationReplay, } from './interaction/initialization-replay.js';
|
|
18
|
-
import { createOperatingInitQuestionnaire, evaluateOperatingInitQuestions, operatingInitAnswersFromOptions, } from './interaction/question-engine.js';
|
|
19
|
-
import { cancelGuidedSession, createGuidedSession, createGuidedSessionId, currentGuidedSessionBindings, updateGuidedSession, } from './interaction/session-service.js';
|
|
20
|
-
import { assertCommittedOperatingView } from './journal.js';
|
|
21
|
-
import { applyOperatingMigration, inspectOperatingMigration, rollbackOperatingMigration, } from './legacy-import-service.js';
|
|
22
|
-
import { answerOperatingGap, applyOrRollbackRoute, decideOperatingDecision, governOperatingFinding, readOperatingCollection, readOperatingReview, transitionOperatingCycle, verifyOperatingGap, } from './lifecycle.js';
|
|
23
|
-
import { createOperatingAdapterStartHandoff, exportOperatingDiagnostics, operateAdapterLifecycle, operatingCacheAction, operatingIntegrityAction, purgeBoardMachineLocalCaches, readPersistedOperatingRoleResults, reapStalledOperatingRoles, repairOperatingSecurity, } from './maintenance.js';
|
|
24
|
-
import { migrateOperatingStorageLayoutOnOpen } from './migration.js';
|
|
25
|
-
import { applyOperatingProfileMigration, inspectOperatingProfileMigration, } from './profile-migration.js';
|
|
26
|
-
import { OPERATING_BOARD_ROLES, renderOperatingBrief } from './projection.js';
|
|
27
|
-
import { persistOperatingProjections } from './projection-persistence.js';
|
|
28
|
-
import { loadOperatingProtocol, resolveOperatingPipelineRoot } from './protocol.js';
|
|
29
|
-
import { readOperatingReport } from './reports.js';
|
|
30
|
-
import { OPERATE_AGENT_PROTOCOL_VERSION, OperateError, } from './types.js';
|
|
31
|
-
import { assertOperatingProject, resolveContainedPath, resolveOperatingPaths, } from './workspace.js';
|
|
32
|
-
export { canonicalDigest, canonicalize, sha256Digest, } from './canonical.js';
|
|
33
|
-
export { OperatingEventStore } from './event-store.js';
|
|
34
|
-
export { acquireOperatingLock, recoverStaleOperatingLock, withOperatingLock, } from './lock-service.js';
|
|
35
|
-
export { assertOperatingProjectionsCurrent, inspectOperatingProjectionDrift, persistOperatingProjections, prepareOperatingProjectionPersistence, renderOperatingProjectionFiles, } from './projection-persistence.js';
|
|
36
|
-
export { assertOperatingArtifact, loadOperatingProtocol, operatingPipelineAvailable, } from './protocol.js';
|
|
37
|
-
function option(request, name, fallback) {
|
|
38
|
-
return request.options[name] ?? fallback;
|
|
39
|
-
}
|
|
40
|
-
function argument(request, name) {
|
|
41
|
-
const value = request.arguments?.[name];
|
|
42
|
-
return typeof value === 'string' ? value : undefined;
|
|
43
|
-
}
|
|
44
|
-
function stringList(value) {
|
|
45
|
-
if (Array.isArray(value))
|
|
46
|
-
return value
|
|
47
|
-
.map(String)
|
|
48
|
-
.map((entry) => entry.trim())
|
|
49
|
-
.filter(Boolean);
|
|
50
|
-
if (typeof value === 'string')
|
|
51
|
-
return value
|
|
52
|
-
.split(',')
|
|
53
|
-
.map((entry) => entry.trim())
|
|
54
|
-
.filter(Boolean);
|
|
55
|
-
return [];
|
|
56
|
-
}
|
|
57
|
-
/**
|
|
58
|
-
* Probe the coding-runtime identity of the host process from the environment
|
|
59
|
-
* markers set by the agent that launched the CLI. Mirrors the compatible-runtime
|
|
60
|
-
* detection in terminal-renderer.ts's `detectOperatingQuestionContext`, but keys
|
|
61
|
-
* off the launcher's env markers so a non-interactive/JSON invocation can stamp a
|
|
62
|
-
* truthful adapter block and resolve `auto` instead of stamping `unknown`/`none`
|
|
63
|
-
* or silently disabling native dispatch.
|
|
64
|
-
*/
|
|
65
|
-
function detectOperatingHostRuntime() {
|
|
66
|
-
const env = process.env;
|
|
67
|
-
const marker = (value) => (value ?? '').length > 0;
|
|
68
|
-
if (marker(env.CLAUDECODE) || marker(env.CLAUDE_CODE_ENTRYPOINT))
|
|
69
|
-
return 'claude';
|
|
70
|
-
if (marker(env.CURSOR_TRACE_ID) || marker(env.CURSOR_AGENT))
|
|
71
|
-
return 'cursor';
|
|
72
|
-
if (marker(env.CODEX_SANDBOX) || marker(env.CODEX_HOME))
|
|
73
|
-
return 'codex';
|
|
74
|
-
return undefined;
|
|
75
|
-
}
|
|
76
|
-
async function resolvedOperatingRuntime(projectRoot, requested) {
|
|
77
|
-
if (requested !== 'auto')
|
|
78
|
-
return requested === 'claude' ? 'claude-code' : requested;
|
|
79
|
-
const persisted = await readFile(path.join(resolveOperatingPaths(projectRoot).localRoot, 'preferences.json'), 'utf8')
|
|
80
|
-
.then((raw) => {
|
|
81
|
-
const runtime = JSON.parse(raw).runtime;
|
|
82
|
-
return typeof runtime === 'string' && runtime ? runtime : 'auto';
|
|
83
|
-
})
|
|
84
|
-
.catch(() => 'auto');
|
|
85
|
-
if (persisted !== 'auto')
|
|
86
|
-
return persisted === 'claude' ? 'claude-code' : persisted;
|
|
87
|
-
// A persisted (or absent) `auto` preference must never silently disable native
|
|
88
|
-
// dispatch inside a capable host: resolve it to the detected runtime identity
|
|
89
|
-
// so `usesNativeOperatingAdvisors` evaluates the real host, not the `auto`
|
|
90
|
-
// placeholder that always returns false.
|
|
91
|
-
const detected = detectOperatingHostRuntime();
|
|
92
|
-
return detected === 'claude' ? 'claude-code' : (detected ?? 'auto');
|
|
93
|
-
}
|
|
94
|
-
export async function usesNativeOperatingAdvisors(projectRoot, requestedRuntime) {
|
|
95
|
-
const runtime = await resolvedOperatingRuntime(projectRoot, requestedRuntime);
|
|
96
|
-
const adapterId = runtime === 'claude' ? 'claude-code' : runtime;
|
|
97
|
-
if (adapterId === 'auto')
|
|
98
|
-
return false;
|
|
99
|
-
const pipelineRoot = resolveOperatingPipelineRoot();
|
|
100
|
-
if (!pipelineRoot)
|
|
101
|
-
return false;
|
|
102
|
-
const registry = await readFile(path.join(pipelineRoot, 'registry', 'adapters.json'), 'utf8')
|
|
103
|
-
.then((raw) => JSON.parse(raw))
|
|
104
|
-
.catch(() => ({ adapters: [] }));
|
|
105
|
-
const adapter = registry.adapters?.find((entry) => entry.id === adapterId);
|
|
106
|
-
if (adapter?.capabilities?.operatingBoard !== true)
|
|
107
|
-
return false;
|
|
108
|
-
if (
|
|
109
|
-
// `native-read-only` is the US-001/T-001 adapters-registry capability name that
|
|
110
|
-
// supersedes the earlier isolation labels; recognize it alongside them.
|
|
111
|
-
[
|
|
112
|
-
'native-agent',
|
|
113
|
-
'sequential-native',
|
|
114
|
-
'native-isolated',
|
|
115
|
-
'native-bounded',
|
|
116
|
-
'native-read-only',
|
|
117
|
-
].includes(adapter.capabilities.operatingAdvisorDispatch ?? '')) {
|
|
118
|
-
return true;
|
|
119
|
-
}
|
|
120
|
-
// Compatibility with Protocol v1.2 registries published before the
|
|
121
|
-
// operatingAdvisorDispatch capability was added.
|
|
122
|
-
return (adapter.capabilities.toolIsolation === 'enforced' ||
|
|
123
|
-
(adapterId === 'codex' &&
|
|
124
|
-
adapter.capabilities.subagents === 'dynamic' &&
|
|
125
|
-
adapter.capabilities.headlessBridge === true));
|
|
126
|
-
}
|
|
127
|
-
async function readCustomOperatingProfile(projectRoot, file) {
|
|
128
|
-
const resolved = await resolveContainedPath(projectRoot, file, { mustExist: true });
|
|
129
|
-
try {
|
|
130
|
-
return normalizeCustomOperatingProfile(parseStrictJson(await readFile(resolved, 'utf8')));
|
|
131
|
-
}
|
|
132
|
-
catch (error) {
|
|
133
|
-
if (error instanceof OperateError && error.code === 'E_OPERATE_CONFIG_INVALID') {
|
|
134
|
-
throw error;
|
|
135
|
-
}
|
|
136
|
-
throw new OperateError('E_OPERATE_CONFIG_INVALID', 'Custom profile must be a valid bounded JSON object.');
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
function success(action, value = {}) {
|
|
140
|
-
const nextActions = value.nextActions ?? value.next ?? [];
|
|
141
|
-
return {
|
|
142
|
-
schemaVersion: '1.0.0',
|
|
143
|
-
protocolVersion: '1.2.0',
|
|
144
|
-
ok: true,
|
|
145
|
-
action,
|
|
146
|
-
...value,
|
|
147
|
-
state: value.state ?? null,
|
|
148
|
-
paths: value.paths ?? {},
|
|
149
|
-
counts: value.counts ?? {},
|
|
150
|
-
warnings: value.warnings ?? [],
|
|
151
|
-
nextActions,
|
|
152
|
-
};
|
|
153
|
-
}
|
|
154
|
-
/**
|
|
155
|
-
* A healthy continuation (FR7/E-007): a guided-stage advance
|
|
156
|
-
* (`E_OPERATE_INPUT_REQUIRED`) or first-use provider consent
|
|
157
|
-
* (`E_OPERATE_AUTHORITY_REQUIRED`) is not a failure. It is returned as an
|
|
158
|
-
* `ok: true` handoff carrying a machine-readable `flow: 'handoff'` discriminator
|
|
159
|
-
* (and the originating `code`), mirroring `run`'s adapter-handoff shape so a
|
|
160
|
-
* harness reads the pause without treating it as a red exit. No `exitCode` is
|
|
161
|
-
* set: the CLI leaves the process exit code at 0 for `ok: true` results.
|
|
162
|
-
*/
|
|
163
|
-
function handoffContinuation(action, code, value = {}) {
|
|
164
|
-
return { ...success(action, value), code, flow: 'handoff' };
|
|
165
|
-
}
|
|
166
|
-
/**
|
|
167
|
-
* First-use / renewal provider consent is disclosed by
|
|
168
|
-
* `ensureOperatingProviderConsent` (advisors.ts) as an
|
|
169
|
-
* `E_OPERATE_AUTHORITY_REQUIRED` carrying the full policy disclosure
|
|
170
|
-
* (`endpoint`, `permittedDataClasses`, `policyDigest`). That specific
|
|
171
|
-
* disclosure is a continuation, not a refusal — unlike every other
|
|
172
|
-
* `E_OPERATE_AUTHORITY_REQUIRED` (a mutation attempted without `--yes`), which
|
|
173
|
-
* stays an `ok: false` exit-4 failure so the authority model is unchanged.
|
|
174
|
-
*/
|
|
175
|
-
function isProviderConsentHandoff(error) {
|
|
176
|
-
if (!(error instanceof OperateError) || error.code !== 'E_OPERATE_AUTHORITY_REQUIRED') {
|
|
177
|
-
return false;
|
|
178
|
-
}
|
|
179
|
-
const details = error.details;
|
|
180
|
-
return (typeof details === 'object' &&
|
|
181
|
-
details !== null &&
|
|
182
|
-
'policyDigest' in details &&
|
|
183
|
-
'endpoint' in details &&
|
|
184
|
-
'permittedDataClasses' in details);
|
|
185
|
-
}
|
|
186
|
-
function providerConsentContinuation(action, error) {
|
|
187
|
-
const retry = `planr operate ${action} --yes`;
|
|
188
|
-
return handoffContinuation(action, 'E_OPERATE_AUTHORITY_REQUIRED', {
|
|
189
|
-
message: error.message,
|
|
190
|
-
data: error.details,
|
|
191
|
-
nextActions: [retry],
|
|
192
|
-
next: [retry],
|
|
193
|
-
});
|
|
194
|
-
}
|
|
195
|
-
/**
|
|
196
|
-
* Stable process exit classes for automation.
|
|
197
|
-
*
|
|
198
|
-
* 2 — invalid invocation or configuration
|
|
199
|
-
* 3 — required project/component is unavailable
|
|
200
|
-
* 4 — explicit human authority or confirmation is required
|
|
201
|
-
* 5 — committed state, integrity, or concurrency conflict
|
|
202
|
-
* 6 — evidence/provider/advisor execution could not complete safely
|
|
203
|
-
* 1 — unexpected internal failure
|
|
204
|
-
*
|
|
205
|
-
* Keep this exhaustive so adding a public Operate error cannot silently fall
|
|
206
|
-
* through to the internal-error class.
|
|
207
|
-
*
|
|
208
|
-
* FR7/E-007 continuation note: `E_OPERATE_INPUT_REQUIRED` and
|
|
209
|
-
* `E_OPERATE_AUTHORITY_REQUIRED` keep this class-4 mapping for the cases that
|
|
210
|
-
* are genuine refusals — a mutation attempted without `--yes` still fails with
|
|
211
|
-
* `ok: false` and exit 4. But a *healthy continuation* — a guided-stage advance
|
|
212
|
-
* or first-use provider consent — is not a failure: it is returned as an
|
|
213
|
-
* `ok: true` handoff (`flow: 'handoff'`) with no failure exit code, mirroring
|
|
214
|
-
* `run`'s adapter handoff, so a harness never paints the happy path red. The
|
|
215
|
-
* numeric class below is therefore only consulted for the failure branch.
|
|
216
|
-
*/
|
|
217
|
-
const OPERATE_EXIT_CODES = {
|
|
218
|
-
E_OPERATE_INTERNAL: 1,
|
|
219
|
-
E_OPERATE_ACTION_UNKNOWN: 2,
|
|
220
|
-
E_OPERATE_ARTIFACT_REJECTED: 2,
|
|
221
|
-
E_OPERATE_CHARTER_INCOMPLETE: 2,
|
|
222
|
-
E_OPERATE_CONFIG_INVALID: 2,
|
|
223
|
-
E_OPERATE_INPUT_TOO_LARGE: 2,
|
|
224
|
-
E_OPERATE_QUESTIONNAIRE_INVALID: 2,
|
|
225
|
-
E_OPERATE_PATH_ESCAPE: 2,
|
|
226
|
-
E_OPERATE_NOT_INITIALIZED: 3,
|
|
227
|
-
E_OPERATE_PROJECT_REQUIRED: 3,
|
|
228
|
-
E_PIPELINE_NOT_INSTALLED: 3,
|
|
229
|
-
E_PIPELINE_VERSION_INCOMPATIBLE: 3,
|
|
230
|
-
E_OPERATE_AUTHORITY_REQUIRED: 4,
|
|
231
|
-
E_OPERATE_INPUT_REQUIRED: 4,
|
|
232
|
-
E_OPERATE_SESSION_CANCELLED: 4,
|
|
233
|
-
E_OPERATE_SESSION_EXPIRED: 4,
|
|
234
|
-
E_OPERATE_ROUTE_CONFIRMATION_REQUIRED: 4,
|
|
235
|
-
E_OPERATE_CHECKPOINT_INVALID: 5,
|
|
236
|
-
E_OPERATE_CYCLE_ACTIVE: 5,
|
|
237
|
-
E_OPERATE_CYCLE_INPUT_CONFLICT: 5,
|
|
238
|
-
E_OPERATE_CYCLE_NOT_DISPOSED: 5,
|
|
239
|
-
E_OPERATE_HEAD_DIVERGED: 5,
|
|
240
|
-
E_OPERATE_MIGRATION_CONFLICT: 5,
|
|
241
|
-
E_OPERATE_OUTCOME_NOT_READY: 5,
|
|
242
|
-
E_OPERATE_PLANNER_CONFLICT: 5,
|
|
243
|
-
E_OPERATE_PROJECTION_DRIFT: 5,
|
|
244
|
-
E_OPERATE_ROUTE_DRIFT: 5,
|
|
245
|
-
E_OPERATE_SECURITY_REPAIR_REQUIRED: 5,
|
|
246
|
-
E_OPERATE_STALE_LOCK_UNSAFE: 5,
|
|
247
|
-
E_OPERATE_STATE_INVALID: 5,
|
|
248
|
-
E_OPERATE_STATE_UNAVAILABLE: 3,
|
|
249
|
-
E_OPERATE_TRANSACTION_INVALID: 5,
|
|
250
|
-
E_OPERATE_SESSION_REPLAY_CONFLICT: 5,
|
|
251
|
-
E_OPERATE_SESSION_STALE: 5,
|
|
252
|
-
E_OPERATE_ADVISOR_FAILED: 6,
|
|
253
|
-
E_OPERATE_ADVISOR_ISOLATION: 6,
|
|
254
|
-
E_OPERATE_CAP_EXCEEDED: 6,
|
|
255
|
-
E_OPERATE_CRITICAL_CAP: 6,
|
|
256
|
-
E_OPERATE_EVIDENCE_BUDGET: 6,
|
|
257
|
-
E_OPERATE_EVIDENCE_NOT_READY: 6,
|
|
258
|
-
E_OPERATE_EVIDENCE_REJECTED: 6,
|
|
259
|
-
E_OPERATE_PROVIDER_READ_ONLY: 6,
|
|
260
|
-
E_OPERATE_PROVIDER_DEPRECATED: 6,
|
|
261
|
-
E_OPERATE_SECRET_DETECTED: 6,
|
|
262
|
-
E_OPERATE_MISSION_PACKET_BUDGET: 6,
|
|
263
|
-
E_OPERATE_MISSION_UNAVAILABLE: 3,
|
|
264
|
-
E_OPERATE_SESSION_INVALID: 2,
|
|
265
|
-
E_OPERATE_RUNTIME_MISMATCH: 5,
|
|
266
|
-
E_OPERATE_DRAFT_UNAPPROVED: 4,
|
|
267
|
-
E_RUNTIME_UNSUPPORTED: 3,
|
|
268
|
-
};
|
|
269
|
-
function operateExitCode(code) {
|
|
270
|
-
return OPERATE_EXIT_CODES[code];
|
|
271
|
-
}
|
|
272
|
-
export function failure(action, error) {
|
|
273
|
-
const code = error instanceof OperateError ? error.code : 'E_OPERATE_INTERNAL';
|
|
274
|
-
// E_OPERATE_INTERNAL must never be zero-information: record the redacted error
|
|
275
|
-
// class/name (no message or stack, which can carry paths or secrets) so the
|
|
276
|
-
// diagnostics export and automation callers can classify the internal failure.
|
|
277
|
-
const internalErrorClass = code === 'E_OPERATE_INTERNAL'
|
|
278
|
-
? error instanceof Error && typeof error.name === 'string' && error.name.length > 0
|
|
279
|
-
? error.name
|
|
280
|
-
: 'Error'
|
|
281
|
-
: undefined;
|
|
282
|
-
const confirmationAction = error instanceof OperateError &&
|
|
283
|
-
error.details?.action &&
|
|
284
|
-
typeof error.details.action === 'object' &&
|
|
285
|
-
!Array.isArray(error.details.action)
|
|
286
|
-
? error.details.action
|
|
287
|
-
: null;
|
|
288
|
-
const confirmationRecovery = code === 'E_OPERATE_ROUTE_CONFIRMATION_REQUIRED' &&
|
|
289
|
-
typeof confirmationAction?.command === 'string' &&
|
|
290
|
-
typeof confirmationAction.confirmationDigest === 'string'
|
|
291
|
-
? [`${confirmationAction.command} --confirm ${confirmationAction.confirmationDigest} --yes`]
|
|
292
|
-
: null;
|
|
293
|
-
const explicitRecovery = error instanceof OperateError && typeof error.details?.recoveryCommand === 'string'
|
|
294
|
-
? [error.details.recoveryCommand]
|
|
295
|
-
: null;
|
|
296
|
-
const nextActions = explicitRecovery ??
|
|
297
|
-
confirmationRecovery ??
|
|
298
|
-
(code === 'E_PIPELINE_NOT_INSTALLED'
|
|
299
|
-
? ['npm install -g openplanr@latest', 'planr setup --scope user', 'planr operate inspect']
|
|
300
|
-
: code === 'E_OPERATE_NOT_INITIALIZED'
|
|
301
|
-
? ['planr operate init']
|
|
302
|
-
: code === 'E_OPERATE_PROJECT_REQUIRED'
|
|
303
|
-
? ['cd /path/to/your/project', 'planr init', 'planr operate inspect']
|
|
304
|
-
: code === 'E_OPERATE_CONFIG_INVALID' || code === 'E_OPERATE_CHARTER_INCOMPLETE'
|
|
305
|
-
? ['planr operate config validate']
|
|
306
|
-
: code === 'E_OPERATE_ROUTE_CONFIRMATION_REQUIRED'
|
|
307
|
-
? ['planr operate routes apply <route-id> --preview --json']
|
|
308
|
-
: code === 'E_OPERATE_MIGRATION_CONFLICT'
|
|
309
|
-
? ['planr operate migrate inspect', 'planr operate migrations list']
|
|
310
|
-
: code === 'E_OPERATE_HEAD_DIVERGED' ||
|
|
311
|
-
code === 'E_OPERATE_CHECKPOINT_INVALID' ||
|
|
312
|
-
code === 'E_OPERATE_PROJECTION_DRIFT'
|
|
313
|
-
? ['planr operate integrity status', 'planr operate cycles recover <cycle-id>']
|
|
314
|
-
: code === 'E_OPERATE_CYCLE_ACTIVE' || code === 'E_OPERATE_CYCLE_INPUT_CONFLICT'
|
|
315
|
-
? ['planr operate status', 'planr operate cycles resume <cycle-id>']
|
|
316
|
-
: code === 'E_OPERATE_CYCLE_NOT_DISPOSED'
|
|
317
|
-
? [
|
|
318
|
-
'planr operate findings list',
|
|
319
|
-
'planr operate decisions list',
|
|
320
|
-
'planr operate cycles close <cycle-id>',
|
|
321
|
-
]
|
|
322
|
-
: code.startsWith('E_OPERATE_EVIDENCE') ||
|
|
323
|
-
code.startsWith('E_OPERATE_PROVIDER') ||
|
|
324
|
-
code.startsWith('E_OPERATE_ADVISOR')
|
|
325
|
-
? ['planr operate run --preview --json', 'planr operate diagnostics export']
|
|
326
|
-
: ['planr operate diagnostics export']);
|
|
327
|
-
return {
|
|
328
|
-
schemaVersion: '1.0.0',
|
|
329
|
-
protocolVersion: '1.2.0',
|
|
330
|
-
ok: false,
|
|
331
|
-
action,
|
|
332
|
-
code,
|
|
333
|
-
message: error instanceof OperateError
|
|
334
|
-
? error.message
|
|
335
|
-
: 'An unexpected internal Operating Board error occurred.',
|
|
336
|
-
state: null,
|
|
337
|
-
paths: {},
|
|
338
|
-
counts: {},
|
|
339
|
-
warnings: [],
|
|
340
|
-
nextActions,
|
|
341
|
-
data: error instanceof OperateError
|
|
342
|
-
? error.details
|
|
343
|
-
: internalErrorClass
|
|
344
|
-
? { errorClass: internalErrorClass }
|
|
345
|
-
: undefined,
|
|
346
|
-
next: nextActions,
|
|
347
|
-
exitCode: operateExitCode(code),
|
|
348
|
-
};
|
|
349
|
-
}
|
|
350
|
-
/**
|
|
351
|
-
* Reduce recovery `nextActions` to the set of public `planr operate` commands
|
|
352
|
-
* that back the structured actions. The digest-bound authority flags
|
|
353
|
-
* (`--yes`, `--confirm <digest>`, `--preview-digest <digest>`) are stripped from
|
|
354
|
-
* the *command* string — a raw sha256 digest must never enter a structured
|
|
355
|
-
* command (it would trip the sensitive-data guard in `assertSafeCommand`).
|
|
356
|
-
*
|
|
357
|
-
* FR8/E-008: stripping them here no longer strands a runner. For a
|
|
358
|
-
* digest-confirmable command the exact, ready-to-run argv (including the real
|
|
359
|
-
* `--confirm <digest> --yes` token) is re-surfaced on the structured action as
|
|
360
|
-
* `confirmArgv` in `attachStructuredActions`, so the runner never has to
|
|
361
|
-
* re-synthesize a confirmation token it was handed. A command whose only
|
|
362
|
-
* authority is `--yes` is never given a confirmationDigest at all.
|
|
363
|
-
*/
|
|
364
|
-
function publicActionCommands(nextActions) {
|
|
365
|
-
return [
|
|
366
|
-
...new Set(nextActions
|
|
367
|
-
.flatMap((value) => value.split(/\s+&&\s+/))
|
|
368
|
-
.map((value) => value
|
|
369
|
-
.trim()
|
|
370
|
-
.replace(/\s+--yes(?=\s|$)/g, '')
|
|
371
|
-
.replace(/\s+--confirm\s+\S+/g, '')
|
|
372
|
-
.replace(/\s+--preview-digest\s+\S+/g, ''))
|
|
373
|
-
.filter((value) => /^planr\s+/.test(value))),
|
|
374
|
-
];
|
|
375
|
-
}
|
|
376
|
-
/**
|
|
377
|
-
* The digest-bound confirmation flag a public command's CLI actually accepts, or
|
|
378
|
-
* `null` when its only authority is `--yes`. A confirmationDigest is meaningful
|
|
379
|
-
* only for a command that can consume it via `--confirm`; a `--yes`-only command
|
|
380
|
-
* (e.g. `operate run`) must never be handed one (FR8/E-008).
|
|
381
|
-
*/
|
|
382
|
-
function commandConfirmFlag(command) {
|
|
383
|
-
return /\boperate\s+init\b/.test(command) || /\bevidence\s+classify\b/.test(command)
|
|
384
|
-
? '--confirm'
|
|
385
|
-
: null;
|
|
386
|
-
}
|
|
387
|
-
function hasFlag(command, flag) {
|
|
388
|
-
return new RegExp(`(?:^|\\s)${flag.replace(/[.*+?^${}()|[\]\\]/g, '\\$&')}(?:\\s|$)`).test(command);
|
|
389
|
-
}
|
|
390
|
-
async function actionEffect(request, command) {
|
|
391
|
-
if (/\b(?:inspect|status|brief|report|review|list|show)\b/.test(command) ||
|
|
392
|
-
/\bconfig validate\b/.test(command) ||
|
|
393
|
-
/\bprofiles validate\b/.test(command) ||
|
|
394
|
-
/\bsources test\b/.test(command) ||
|
|
395
|
-
(/\brun\b/.test(command) && hasFlag(command, '--preview')) ||
|
|
396
|
-
/\bmigrate inspect\b/.test(command) ||
|
|
397
|
-
/\bcache status\b/.test(command) ||
|
|
398
|
-
/\bintegrity status\b/.test(command)) {
|
|
399
|
-
return 'read-only';
|
|
400
|
-
}
|
|
401
|
-
if (/\boperate run\b/.test(command)) {
|
|
402
|
-
if (hasFlag(command, '--offline'))
|
|
403
|
-
return 'project-write';
|
|
404
|
-
const commandRuntime = command.match(/(?:^|\s)--runtime\s+(\S+)/)?.[1];
|
|
405
|
-
if (await usesNativeOperatingAdvisors(request.projectRoot, commandRuntime ?? option(request, 'runtime', 'auto'))) {
|
|
406
|
-
return 'project-write';
|
|
407
|
-
}
|
|
408
|
-
return 'provider-call';
|
|
409
|
-
}
|
|
410
|
-
if (/\badapter resume\b/.test(command))
|
|
411
|
-
return 'read-only';
|
|
412
|
-
if (/\badapter finalize\b/.test(command))
|
|
413
|
-
return 'project-write';
|
|
414
|
-
if (/\b(?:adapter (?:prepare|record|cancel)|cache purge|diagnostics export)\b/.test(command)) {
|
|
415
|
-
return 'machine-local-write';
|
|
416
|
-
}
|
|
417
|
-
if (/\bpipeline (?:plan|ship)\b/.test(command))
|
|
418
|
-
return 'external-effect';
|
|
419
|
-
return 'project-write';
|
|
420
|
-
}
|
|
421
|
-
async function attachStructuredActions(request, result) {
|
|
422
|
-
if (result.actions?.length || result.action === 'input_required' || result.flow === 'handoff') {
|
|
423
|
-
return result;
|
|
424
|
-
}
|
|
425
|
-
const commands = publicActionCommands(result.nextActions);
|
|
426
|
-
if (commands.length === 0)
|
|
427
|
-
return result;
|
|
428
|
-
// Planning-only installations intentionally omit the portable pipeline and
|
|
429
|
-
// therefore its Protocol v1.2 action validators. Provider-free inspection
|
|
430
|
-
// and demonstration must still work; their legacy nextActions remain the
|
|
431
|
-
// compatible fallback until the full package is installed.
|
|
432
|
-
if (!resolveOperatingPipelineRoot())
|
|
433
|
-
return result;
|
|
434
|
-
const bindings = await currentGuidedSessionBindings(request.projectRoot);
|
|
435
|
-
const eventHead = await new OperatingEventStore(request.projectRoot)
|
|
436
|
-
.replay()
|
|
437
|
-
.then((value) => (value.eventHead.hash ? value.eventHead : null))
|
|
438
|
-
.catch(() => null);
|
|
439
|
-
const requestDigest = canonicalDigest({
|
|
440
|
-
action: request.action,
|
|
441
|
-
arguments: request.arguments ?? {},
|
|
442
|
-
options: Object.fromEntries(Object.entries(request.options)
|
|
443
|
-
.filter(([key]) => !['yes', 'confirm', 'stdin'].includes(key))
|
|
444
|
-
.map(([key, value]) => [key, canonicalDigest({ value })])),
|
|
445
|
-
});
|
|
446
|
-
const sessionId = `GIS-action-${requestDigest.slice('sha256:'.length, 'sha256:'.length + 24)}`;
|
|
447
|
-
const actions = [];
|
|
448
|
-
for (const [index, command] of commands.entries()) {
|
|
449
|
-
const effect = await actionEffect(request, command);
|
|
450
|
-
const confirmFlag = commandConfirmFlag(command);
|
|
451
|
-
const id = `operate.next.${canonicalDigest({ command }).slice('sha256:'.length, 'sha256:'.length + 20)}`.toLowerCase();
|
|
452
|
-
const created = await createOperatingAction({
|
|
453
|
-
id,
|
|
454
|
-
label: (() => {
|
|
455
|
-
const publicLabel = command.replace(/^planr\s+/, '');
|
|
456
|
-
return publicLabel.length <= 160
|
|
457
|
-
? publicLabel
|
|
458
|
-
: `${publicLabel.slice(0, 157).trimEnd()}...`;
|
|
459
|
-
})(),
|
|
460
|
-
description: `Run the named ${effect} action returned by ${request.action}.`,
|
|
461
|
-
command,
|
|
462
|
-
effect,
|
|
463
|
-
recommended: index === 0,
|
|
464
|
-
...(effect === 'read-only'
|
|
465
|
-
? {}
|
|
466
|
-
: {
|
|
467
|
-
confirmation: {
|
|
468
|
-
sessionId,
|
|
469
|
-
confirmationScope: `${request.action}:${index + 1}`,
|
|
470
|
-
projectIdentity: bindings.projectIdentity,
|
|
471
|
-
projectHead: bindings.projectHead,
|
|
472
|
-
configHead: bindings.configHead,
|
|
473
|
-
eventHead,
|
|
474
|
-
arguments: [requestDigest],
|
|
475
|
-
destinations: [],
|
|
476
|
-
writes: [],
|
|
477
|
-
},
|
|
478
|
-
}),
|
|
479
|
-
});
|
|
480
|
-
let action = created.action;
|
|
481
|
-
// FR8/E-008: `operate run` authorizes with `--yes` alone — its CLI accepts no
|
|
482
|
-
// `--confirm` flag — so it must never carry a confirmationDigest a runner
|
|
483
|
-
// could never pass. It still appears as a structured action (mirroring the
|
|
484
|
-
// handoff `run` continuation) but with its digest binding cleared.
|
|
485
|
-
if (/\boperate\s+run\b/.test(command)) {
|
|
486
|
-
action = {
|
|
487
|
-
...action,
|
|
488
|
-
requiresConfirmation: false,
|
|
489
|
-
confirmationScope: null,
|
|
490
|
-
confirmationDigest: null,
|
|
491
|
-
};
|
|
492
|
-
}
|
|
493
|
-
// A digest-confirmable action (`--confirm <digest>`) carries its exact,
|
|
494
|
-
// ready-to-run argv so a runner never has to re-synthesize the confirmation
|
|
495
|
-
// token it was already handed.
|
|
496
|
-
const confirmArgv = confirmFlag && action.confirmationDigest
|
|
497
|
-
? [...command.split(/\s+/), confirmFlag, action.confirmationDigest, '--yes']
|
|
498
|
-
: undefined;
|
|
499
|
-
actions.push(confirmArgv ? { ...action, confirmArgv } : action);
|
|
500
|
-
}
|
|
501
|
-
if (actions.length === 0)
|
|
502
|
-
return result;
|
|
503
|
-
return { ...result, actions };
|
|
504
|
-
}
|
|
505
|
-
async function inspect(request) {
|
|
506
|
-
const pipelineRoot = resolveOperatingPipelineRoot();
|
|
507
|
-
const localRoot = option(request, 'localRoot', undefined);
|
|
508
|
-
const paths = resolveOperatingPaths(request.projectRoot, { localRoot });
|
|
509
|
-
const customStateRoot = Boolean(localRoot ?? process.env.OPENPLANR_STATE_ROOT);
|
|
510
|
-
const initialized = await readFile(paths.config, 'utf8').then(() => true, () => false);
|
|
511
|
-
let project = false;
|
|
512
|
-
try {
|
|
513
|
-
await assertOperatingProject(request.projectRoot);
|
|
514
|
-
project = true;
|
|
515
|
-
}
|
|
516
|
-
catch {
|
|
517
|
-
project = false;
|
|
518
|
-
}
|
|
519
|
-
return success(request.action, {
|
|
520
|
-
message: initialized
|
|
521
|
-
? 'Operating Board is initialized.'
|
|
522
|
-
: 'Operating Board is available; initialization is optional.',
|
|
523
|
-
data: {
|
|
524
|
-
project,
|
|
525
|
-
initialized,
|
|
526
|
-
pipeline: {
|
|
527
|
-
available: Boolean(pipelineRoot),
|
|
528
|
-
root: pipelineRoot ? '(installed)' : null,
|
|
529
|
-
// The contract the installed pipeline ENFORCES — mandates are signed and
|
|
530
|
-
// validated at the agent protocol version. This previously reported the
|
|
531
|
-
// frozen on-disk artifact envelope version instead, so the first command
|
|
532
|
-
// of the journey advertised a two-generation-stale capability.
|
|
533
|
-
protocolVersion: pipelineRoot ? OPERATE_AGENT_PROTOCOL_VERSION : null,
|
|
534
|
-
},
|
|
535
|
-
commitSafeRoot: project ? '.planr/operate' : null,
|
|
536
|
-
machineLocalState: customStateRoot ? paths.localRoot : '~/.planr/operate/<project-hash>',
|
|
537
|
-
},
|
|
538
|
-
// FND-001: an uninitialized project is pointed at the research-first entry, not
|
|
539
|
-
// cold into the guided questionnaire. Bare `planr operate` auto-runs
|
|
540
|
-
// `context.refresh` (which pre-fills most charter fields from the repo) before
|
|
541
|
-
// init; `planr operate context refresh` is the explicit standalone step. Both
|
|
542
|
-
// verified to run uninitialized. The structured `actions[]` are derived from
|
|
543
|
-
// these same commands, so the text hint and the actions can never disagree.
|
|
544
|
-
next: initialized
|
|
545
|
-
? ['planr operate status']
|
|
546
|
-
: ['planr operate', 'planr operate context refresh'],
|
|
547
|
-
});
|
|
548
|
-
}
|
|
549
|
-
function demo(request) {
|
|
550
|
-
const evidence = [
|
|
551
|
-
{
|
|
552
|
-
id: 'EVD-demo-activation',
|
|
553
|
-
source: 'demo-fixture',
|
|
554
|
-
summary: 'The product has no verified activation baseline for the current cycle.',
|
|
555
|
-
observedFrom: '2026-06-01T00:00:00.000Z',
|
|
556
|
-
observedTo: '2026-06-30T23:59:59.000Z',
|
|
557
|
-
sensitivity: 'public',
|
|
558
|
-
},
|
|
559
|
-
{
|
|
560
|
-
id: 'EVD-demo-delivery',
|
|
561
|
-
source: 'demo-fixture',
|
|
562
|
-
summary: 'Delivery capacity is already allocated to three unmeasured feature bets.',
|
|
563
|
-
observedFrom: '2026-06-01T00:00:00.000Z',
|
|
564
|
-
observedTo: '2026-06-30T23:59:59.000Z',
|
|
565
|
-
sensitivity: 'public',
|
|
566
|
-
},
|
|
567
|
-
];
|
|
568
|
-
const demoState = {
|
|
569
|
-
kind: 'operating-state',
|
|
570
|
-
schemaVersion: '1.0.0',
|
|
571
|
-
protocolVersion: '1.2.0',
|
|
572
|
-
generatedAt: '2026-07-01T00:00:00.000Z',
|
|
573
|
-
eventHead: { sequence: 0, hash: null },
|
|
574
|
-
cycles: [{ id: 'CYCLE-001', state: 'reviewable', health: 'normal' }],
|
|
575
|
-
findings: [
|
|
576
|
-
{
|
|
577
|
-
id: 'FND-001',
|
|
578
|
-
cycleId: 'CYCLE-001',
|
|
579
|
-
status: 'proposed',
|
|
580
|
-
title: 'Measure activation before increasing delivery scope',
|
|
581
|
-
problem: 'The product has no verified activation baseline.',
|
|
582
|
-
proposal: 'Create one bounded activation instrumentation specification.',
|
|
583
|
-
severity: 'high',
|
|
584
|
-
sensitivity: 'public',
|
|
585
|
-
score: 48,
|
|
586
|
-
lane: 'DEV',
|
|
587
|
-
owner: 'product-engineering',
|
|
588
|
-
parked: false,
|
|
589
|
-
evidenceRefs: ['EVD-demo-activation', 'EVD-demo-delivery'],
|
|
590
|
-
},
|
|
591
|
-
],
|
|
592
|
-
decisions: [
|
|
593
|
-
{
|
|
594
|
-
id: 'DEC-001',
|
|
595
|
-
cycleId: 'CYCLE-001',
|
|
596
|
-
status: 'open',
|
|
597
|
-
question: 'Which customer event defines activation?',
|
|
598
|
-
recommendation: 'Choose one observable event before planning more feature work.',
|
|
599
|
-
evidenceRefs: ['EVD-demo-activation'],
|
|
600
|
-
},
|
|
601
|
-
],
|
|
602
|
-
dataGaps: [],
|
|
603
|
-
routes: [
|
|
604
|
-
{
|
|
605
|
-
id: 'ACT-001',
|
|
606
|
-
cycleId: 'CYCLE-001',
|
|
607
|
-
state: 'proposed',
|
|
608
|
-
findingIds: ['FND-001'],
|
|
609
|
-
},
|
|
610
|
-
],
|
|
611
|
-
specLinks: [],
|
|
612
|
-
outcomes: [],
|
|
613
|
-
learnings: [],
|
|
614
|
-
evidenceSources: [{ id: 'demo-fixture', status: 'collected', itemCount: 2 }],
|
|
615
|
-
summary: {
|
|
616
|
-
currentCycleId: 'CYCLE-001',
|
|
617
|
-
currentConstraint: 'The product has no verified activation baseline.',
|
|
618
|
-
quiet: false,
|
|
619
|
-
evidenceFreshness: 'fresh',
|
|
620
|
-
surfacedFindings: 1,
|
|
621
|
-
parkedFindings: 0,
|
|
622
|
-
openDecisions: 1,
|
|
623
|
-
openGaps: 0,
|
|
624
|
-
stalledItems: 0,
|
|
625
|
-
},
|
|
626
|
-
};
|
|
627
|
-
return success(request.action, {
|
|
628
|
-
message: 'Generated a deterministic, credential-free Operating Board demonstration.',
|
|
629
|
-
data: {
|
|
630
|
-
brief: renderOperatingBrief(demoState),
|
|
631
|
-
evidence,
|
|
632
|
-
state: demoState,
|
|
633
|
-
note: 'Demo performs no provider/model calls and writes no project state.',
|
|
634
|
-
},
|
|
635
|
-
next: ['planr operate init'],
|
|
636
|
-
});
|
|
637
|
-
}
|
|
638
|
-
async function initializationApplyAction(input) {
|
|
639
|
-
const sessionId = input.sessionId ??
|
|
640
|
-
`GIS-init-${input.preview.previewDigest.slice('sha256:'.length, 'sha256:'.length + 24)}`;
|
|
641
|
-
const command = input.sessionId
|
|
642
|
-
? `planr operate init --resume ${input.sessionId}`
|
|
643
|
-
: [
|
|
644
|
-
'planr operate init',
|
|
645
|
-
`--answers-token ${encodeOperatingInitializationReplay(input.answers)}`,
|
|
646
|
-
`--preview-created-at ${input.preview.workspace.capturedAt}`,
|
|
647
|
-
].join(' ');
|
|
648
|
-
return createOperatingAction({
|
|
649
|
-
id: 'operate.init.apply',
|
|
650
|
-
label: 'Apply Operating Board configuration',
|
|
651
|
-
description: 'Write only the reviewed charter, workspace, configuration, and machine-local preferences.',
|
|
652
|
-
command,
|
|
653
|
-
effect: 'project-write',
|
|
654
|
-
recommended: true,
|
|
655
|
-
confirmation: {
|
|
656
|
-
sessionId,
|
|
657
|
-
confirmationScope: 'operate.init.apply',
|
|
658
|
-
projectIdentity: input.bindings.projectIdentity,
|
|
659
|
-
projectHead: input.bindings.projectHead,
|
|
660
|
-
configHead: input.bindings.configHead,
|
|
661
|
-
eventHead: input.preview.expectedEventHead.hash ? input.preview.expectedEventHead : null,
|
|
662
|
-
arguments: [
|
|
663
|
-
`answers=${canonicalDigest(input.answers)}`,
|
|
664
|
-
`preview=${input.preview.previewDigest}`,
|
|
665
|
-
],
|
|
666
|
-
destinations: [
|
|
667
|
-
...input.preview.changedPaths,
|
|
668
|
-
...(input.preview.preferencesChanged ? ['~/.planr/operate/preferences.json'] : []),
|
|
669
|
-
],
|
|
670
|
-
writes: input.preview.writes.map((write) => `${write.relativePath}:${write.operation ?? 'replace'}:${sha256Digest(write.content)}`),
|
|
671
|
-
},
|
|
672
|
-
});
|
|
673
|
-
}
|
|
674
|
-
async function initialize(request) {
|
|
675
|
-
await loadOperatingProtocol();
|
|
676
|
-
const replayToken = option(request, 'answersToken', undefined);
|
|
677
|
-
let supplied = replayToken
|
|
678
|
-
? decodeOperatingInitializationReplay(replayToken)
|
|
679
|
-
: normalizeOperatingInitializationAnswers(operatingInitAnswersFromOptions(request.options));
|
|
680
|
-
const resumeId = option(request, 'resume', undefined);
|
|
681
|
-
const localRoot = option(request, 'localRoot', undefined);
|
|
682
|
-
if (option(request, 'cancelSession', false)) {
|
|
683
|
-
if (!resumeId) {
|
|
684
|
-
throw new OperateError('E_OPERATE_SESSION_INVALID', '--cancel-session requires --resume <session-id>.');
|
|
685
|
-
}
|
|
686
|
-
return success(request.action, {
|
|
687
|
-
message: 'Guided initialization session cancelled.',
|
|
688
|
-
state: 'cancelled',
|
|
689
|
-
data: await cancelGuidedSession({
|
|
690
|
-
projectRoot: request.projectRoot,
|
|
691
|
-
sessionId: resumeId,
|
|
692
|
-
localRoot,
|
|
693
|
-
}),
|
|
694
|
-
next: ['planr operate init --json'],
|
|
695
|
-
});
|
|
696
|
-
}
|
|
697
|
-
if (request.stdin !== undefined && !resumeId) {
|
|
698
|
-
throw new OperateError('E_OPERATE_SESSION_INVALID', '--stdin requires --resume <session-id>.');
|
|
699
|
-
}
|
|
700
|
-
const bindings = await currentGuidedSessionBindings(request.projectRoot);
|
|
701
|
-
let resumedSession = null;
|
|
702
|
-
if (resumeId) {
|
|
703
|
-
resumedSession =
|
|
704
|
-
request.stdin === undefined
|
|
705
|
-
? await resumeGuidedSession({
|
|
706
|
-
projectRoot: request.projectRoot,
|
|
707
|
-
sessionId: resumeId,
|
|
708
|
-
bindings,
|
|
709
|
-
localRoot,
|
|
710
|
-
})
|
|
711
|
-
: await submitGuidedAnswers({
|
|
712
|
-
projectRoot: request.projectRoot,
|
|
713
|
-
sessionId: resumeId,
|
|
714
|
-
raw: request.stdin,
|
|
715
|
-
bindings,
|
|
716
|
-
localRoot,
|
|
717
|
-
});
|
|
718
|
-
supplied = normalizeOperatingInitializationAnswers(resumedSession.answers);
|
|
719
|
-
if (resumedSession.status === 'input-required') {
|
|
720
|
-
// FR7/E-007: a guided-stage advance is a healthy continuation, not a
|
|
721
|
-
// failure. Report it as an `ok: true` handoff (`flow: 'handoff'`) carrying
|
|
722
|
-
// the next questionnaire, mirroring `run`'s adapter handoff.
|
|
723
|
-
return handoffContinuation('input_required', 'E_OPERATE_INPUT_REQUIRED', {
|
|
724
|
-
message: 'Operating Board initialization needs explicit human input.',
|
|
725
|
-
state: resumedSession.session.state,
|
|
726
|
-
questionnaire: resumedSession.questionnaire,
|
|
727
|
-
});
|
|
728
|
-
}
|
|
729
|
-
}
|
|
730
|
-
let customProfile;
|
|
731
|
-
if (supplied.profile === 'custom' && supplied.profileFile) {
|
|
732
|
-
customProfile = await readCustomOperatingProfile(request.projectRoot, supplied.profileFile);
|
|
733
|
-
}
|
|
734
|
-
else if (supplied.profile !== undefined &&
|
|
735
|
-
supplied.profile !== 'custom' &&
|
|
736
|
-
supplied.profileFile) {
|
|
737
|
-
throw new OperateError('E_OPERATE_CONFIG_INVALID', '--profile-file is valid only with --profile custom.');
|
|
738
|
-
}
|
|
739
|
-
// Probe the real host runtime instead of stamping `unknown`/`none`: an explicit
|
|
740
|
-
// --runtime flag wins, otherwise the launcher's env markers name the host so the
|
|
741
|
-
// questionnaire's adapter block is truthful (and the runtime question can be a
|
|
742
|
-
// detect-don't-ask suggestion rather than a required prompt).
|
|
743
|
-
const detectedHostRuntime = detectOperatingHostRuntime();
|
|
744
|
-
const requestedRuntimeOption = option(request, 'runtime', 'auto');
|
|
745
|
-
// Probe the same signals the terminal path does so the JSON/native init path is
|
|
746
|
-
// equally truthful: Git can suggest the decision owner and the installed
|
|
747
|
-
// pipeline can suggest the planning-engine handoff.
|
|
748
|
-
const gitUserName = await probeGitUserName(request.projectRoot);
|
|
749
|
-
// Agent-native bootstrap researches first and stores epistemically labelled
|
|
750
|
-
// context. Use it as provisional initialization input so the old serial
|
|
751
|
-
// questionnaire does not ask the owner to retype discoverable project facts.
|
|
752
|
-
// Explicit user/runtime answers always win; decisionOwner is intentionally
|
|
753
|
-
// never inferred here because it is an authority assignment.
|
|
754
|
-
if (!resumeId) {
|
|
755
|
-
const researched = await operatingInitializationAnswersFromResearch(request.projectRoot);
|
|
756
|
-
if (researched) {
|
|
757
|
-
supplied = normalizeOperatingInitializationAnswers({
|
|
758
|
-
...researched,
|
|
759
|
-
...supplied,
|
|
760
|
-
charter: {
|
|
761
|
-
...researched.charter,
|
|
762
|
-
...supplied.charter,
|
|
763
|
-
},
|
|
764
|
-
});
|
|
765
|
-
}
|
|
766
|
-
}
|
|
767
|
-
const context = {
|
|
768
|
-
projectRoot: request.projectRoot,
|
|
769
|
-
...bindings,
|
|
770
|
-
...(detectedHostRuntime ? { detectedRuntime: detectedHostRuntime } : {}),
|
|
771
|
-
...(gitUserName ? { gitUserName } : {}),
|
|
772
|
-
timezone: Intl.DateTimeFormat().resolvedOptions().timeZone,
|
|
773
|
-
pipelineInstalled: probePipelineInstalled(),
|
|
774
|
-
runtime: requestedRuntimeOption && requestedRuntimeOption !== 'auto'
|
|
775
|
-
? requestedRuntimeOption
|
|
776
|
-
: (detectedHostRuntime ?? (request.interactive ? 'terminal' : 'unknown')),
|
|
777
|
-
interaction: detectedHostRuntime
|
|
778
|
-
? 'native'
|
|
779
|
-
: request.interactive
|
|
780
|
-
? 'terminal'
|
|
781
|
-
: 'none',
|
|
782
|
-
};
|
|
783
|
-
const questionState = await evaluateOperatingInitQuestions({
|
|
784
|
-
answers: supplied,
|
|
785
|
-
context,
|
|
786
|
-
requireCharter: true,
|
|
787
|
-
});
|
|
788
|
-
if (questionState.status === 'input-required') {
|
|
789
|
-
const sessionId = createGuidedSessionId();
|
|
790
|
-
const questionnaire = await createOperatingInitQuestionnaire({
|
|
791
|
-
context,
|
|
792
|
-
questions: questionState.questions,
|
|
793
|
-
stage: questionState.stage,
|
|
794
|
-
sessionId,
|
|
795
|
-
});
|
|
796
|
-
await createGuidedSession({
|
|
797
|
-
projectRoot: request.projectRoot,
|
|
798
|
-
questionnaire,
|
|
799
|
-
persistedAnswers: persistableOperatingInitAnswers(questionState.answers, context),
|
|
800
|
-
localRoot,
|
|
801
|
-
});
|
|
802
|
-
// FR7/E-007: the first guided-stage prompt is a healthy continuation — an
|
|
803
|
-
// `ok: true` handoff (`flow: 'handoff'`) carrying the questionnaire, not an
|
|
804
|
-
// exit-4 failure.
|
|
805
|
-
//
|
|
806
|
-
// FND-002 (level 1): when a terminal is present, the handoff carries a
|
|
807
|
-
// human-legible message and a next step describing the interactive
|
|
808
|
-
// continuation, so no renderer is left with a shapeless payload. When there is
|
|
809
|
-
// no interactive continuation (a non-TTY human, or the machine `--json`
|
|
810
|
-
// channel) the handoff stays lean: the CLI renderer (`renderHuman`) owns the
|
|
811
|
-
// transport-correct guidance there — an interactive "answer the questions"
|
|
812
|
-
// instruction would be a lie in a non-TTY shell, and a machine reads the
|
|
813
|
-
// questionnaire/`flow` directly. This keeps the no-silent-success fallback in
|
|
814
|
-
// `renderHuman` the single, load-bearing source for the non-interactive case.
|
|
815
|
-
const interactiveGuidance = request.interactive
|
|
816
|
-
? {
|
|
817
|
-
message: 'Operating Board initialization needs a few governance answers before it can continue.',
|
|
818
|
-
next: ['Answer the guided initialization questions to continue.'],
|
|
819
|
-
}
|
|
820
|
-
: {};
|
|
821
|
-
return handoffContinuation('input_required', 'E_OPERATE_INPUT_REQUIRED', {
|
|
822
|
-
...interactiveGuidance,
|
|
823
|
-
questionnaire,
|
|
824
|
-
});
|
|
825
|
-
}
|
|
826
|
-
const profile = supplied.profile;
|
|
827
|
-
const decisionOwner = supplied.decisionOwner ?? option(request, 'decisionOwner', '').trim();
|
|
828
|
-
const planningEngine = supplied.planningEngine ??
|
|
829
|
-
option(request, 'planningEngine', 'openplanr');
|
|
830
|
-
const rawCharter = supplied.charter ?? option(request, 'charter', {});
|
|
831
|
-
const preview = await prepareOperatingInitialization({
|
|
832
|
-
projectRoot: request.projectRoot,
|
|
833
|
-
profile,
|
|
834
|
-
decisionOwner,
|
|
835
|
-
planningEngine,
|
|
836
|
-
runtime: supplied.runtime ?? option(request, 'runtime', 'auto'),
|
|
837
|
-
cadence: supplied.cadence ?? option(request, 'cadence', 'manual'),
|
|
838
|
-
timezone: supplied.timezone ??
|
|
839
|
-
option(request, 'timezone', Intl.DateTimeFormat().resolvedOptions().timeZone),
|
|
840
|
-
sensitivityCeiling: supplied.sensitivityCeiling ?? option(request, 'sensitivityCeiling', 'internal'),
|
|
841
|
-
charter: rawCharter,
|
|
842
|
-
customProfile,
|
|
843
|
-
componentRoots: supplied.componentRoots ?? stringList(request.options.components),
|
|
844
|
-
localRoot,
|
|
845
|
-
now: resumedSession?.session.createdAt ??
|
|
846
|
-
option(request, 'previewCreatedAt', undefined),
|
|
847
|
-
});
|
|
848
|
-
const legacyMigration = await inspectOperatingMigration({
|
|
849
|
-
projectRoot: request.projectRoot,
|
|
850
|
-
});
|
|
851
|
-
const previewData = {
|
|
852
|
-
previewDigest: preview.previewDigest,
|
|
853
|
-
expectedEventHead: preview.expectedEventHead,
|
|
854
|
-
resultingEventHead: preview.resultingEventHead,
|
|
855
|
-
changedPaths: preview.changedPaths,
|
|
856
|
-
localPreferencesChanged: preview.preferencesChanged,
|
|
857
|
-
// FR5 / T-005: name the machine-local preference keys a re-init will actually
|
|
858
|
-
// change (dispatch-mode overrides, adapter lease, cadence marker), so the
|
|
859
|
-
// operator sees the field-level delta — not just that preferences.json is in
|
|
860
|
-
// the affected-files list — before confirming.
|
|
861
|
-
changedPreferenceKeys: preview.changedPreferenceKeys,
|
|
862
|
-
previewCreatedAt: preview.workspace.capturedAt,
|
|
863
|
-
workspaceDigest: preview.workspace.workspaceDigest,
|
|
864
|
-
config: preview.config,
|
|
865
|
-
legacyMigration,
|
|
866
|
-
...(resumedSession ? { sessionId: resumedSession.session.sessionId } : {}),
|
|
867
|
-
};
|
|
868
|
-
const { action: applyAction, confirmation } = await initializationApplyAction({
|
|
869
|
-
request,
|
|
870
|
-
preview,
|
|
871
|
-
bindings,
|
|
872
|
-
sessionId: resumedSession?.session.sessionId,
|
|
873
|
-
answers: questionState.answers,
|
|
874
|
-
});
|
|
875
|
-
const requestedConfirmation = option(request, 'confirm', undefined);
|
|
876
|
-
const confirmed = option(request, 'yes', false);
|
|
877
|
-
if (resumedSession) {
|
|
878
|
-
await updateGuidedSession({
|
|
879
|
-
projectRoot: request.projectRoot,
|
|
880
|
-
localRoot,
|
|
881
|
-
session: {
|
|
882
|
-
...resumedSession.session,
|
|
883
|
-
state: 'preview-ready',
|
|
884
|
-
previewDigest: preview.previewDigest,
|
|
885
|
-
confirmationDigest: confirmation?.confirmationDigest,
|
|
886
|
-
updatedAt: new Date().toISOString(),
|
|
887
|
-
},
|
|
888
|
-
});
|
|
889
|
-
if (!confirmed || !requestedConfirmation) {
|
|
890
|
-
return success(request.action, {
|
|
891
|
-
message: 'Operating Board initialization preview is ready; no state was written.',
|
|
892
|
-
state: 'preview-ready',
|
|
893
|
-
preview: { ...previewData, confirmation },
|
|
894
|
-
actions: [applyAction],
|
|
895
|
-
next: [
|
|
896
|
-
`planr operate init --resume ${resumedSession.session.sessionId} --confirm ${confirmation?.confirmationDigest} --yes --json`,
|
|
897
|
-
],
|
|
898
|
-
});
|
|
899
|
-
}
|
|
900
|
-
}
|
|
901
|
-
if (option(request, 'preview', false) || option(request, 'dryRun', false)) {
|
|
902
|
-
return success(request.action, {
|
|
903
|
-
message: 'Operating Board initialization preview is ready; no state was written.',
|
|
904
|
-
state: 'preview-ready',
|
|
905
|
-
preview: { ...previewData, confirmation },
|
|
906
|
-
actions: [applyAction],
|
|
907
|
-
next: [`${applyAction.command} --confirm ${confirmation?.confirmationDigest} --yes`],
|
|
908
|
-
});
|
|
909
|
-
}
|
|
910
|
-
if (!confirmed || !requestedConfirmation || !confirmation) {
|
|
911
|
-
throw new OperateError('E_OPERATE_ROUTE_CONFIRMATION_REQUIRED', 'Initialization requires the exact named confirmation returned by its preview.', {
|
|
912
|
-
preview: { ...previewData, confirmation },
|
|
913
|
-
action: applyAction,
|
|
914
|
-
});
|
|
915
|
-
}
|
|
916
|
-
const accepted = assertOperatingConfirmation({
|
|
917
|
-
expected: confirmation,
|
|
918
|
-
actionId: applyAction.id,
|
|
919
|
-
confirmationDigest: requestedConfirmation,
|
|
920
|
-
confirmed,
|
|
921
|
-
});
|
|
922
|
-
if (resumedSession) {
|
|
923
|
-
await updateGuidedSession({
|
|
924
|
-
projectRoot: request.projectRoot,
|
|
925
|
-
localRoot,
|
|
926
|
-
session: {
|
|
927
|
-
...resumedSession.session,
|
|
928
|
-
state: 'confirmed',
|
|
929
|
-
previewDigest: preview.previewDigest,
|
|
930
|
-
confirmationDigest: accepted.confirmationDigest,
|
|
931
|
-
confirmedAt: accepted.confirmedAt,
|
|
932
|
-
updatedAt: accepted.confirmedAt ?? new Date().toISOString(),
|
|
933
|
-
},
|
|
934
|
-
});
|
|
935
|
-
}
|
|
936
|
-
const applied = await applyOperatingInitialization({
|
|
937
|
-
projectRoot: request.projectRoot,
|
|
938
|
-
preview,
|
|
939
|
-
confirmationDigest: preview.previewDigest,
|
|
940
|
-
});
|
|
941
|
-
// FR4: a committed init apply is a fresh (re-genesised) board. Purge the
|
|
942
|
-
// machine-local advisor sessions and incremental evidence baselines a prior
|
|
943
|
-
// generation left at this path so the new board never inherits a stale
|
|
944
|
-
// session or a baseline bound to a superseded workspace/board identity.
|
|
945
|
-
await purgeBoardMachineLocalCaches({ projectRoot: request.projectRoot, localRoot });
|
|
946
|
-
if (resumedSession) {
|
|
947
|
-
const appliedAt = new Date().toISOString();
|
|
948
|
-
await updateGuidedSession({
|
|
949
|
-
projectRoot: request.projectRoot,
|
|
950
|
-
localRoot,
|
|
951
|
-
session: {
|
|
952
|
-
...resumedSession.session,
|
|
953
|
-
state: 'applied',
|
|
954
|
-
previewDigest: preview.previewDigest,
|
|
955
|
-
confirmationDigest: accepted.confirmationDigest,
|
|
956
|
-
confirmedAt: accepted.confirmedAt,
|
|
957
|
-
appliedAt,
|
|
958
|
-
updatedAt: appliedAt,
|
|
959
|
-
},
|
|
960
|
-
});
|
|
961
|
-
}
|
|
962
|
-
return success(request.action, {
|
|
963
|
-
message: applied.initialized
|
|
964
|
-
? 'Operating Board initialized.'
|
|
965
|
-
: 'Operating Board already matches this configuration.',
|
|
966
|
-
data: {
|
|
967
|
-
changedPaths: applied.changedPaths,
|
|
968
|
-
workspaceDigest: preview.workspace.workspaceDigest,
|
|
969
|
-
legacyMigration,
|
|
970
|
-
},
|
|
971
|
-
next: [
|
|
972
|
-
...(legacyMigration.record
|
|
973
|
-
? legacyMigration.record.state === 'conflict'
|
|
974
|
-
? ['planr operate migrate inspect']
|
|
975
|
-
: ['planr operate migrate apply']
|
|
976
|
-
: []),
|
|
977
|
-
'planr operate run',
|
|
978
|
-
'planr operate status',
|
|
979
|
-
],
|
|
980
|
-
});
|
|
981
|
-
}
|
|
982
|
-
async function showConfig(request) {
|
|
983
|
-
const config = await validateOperatingConfiguration(request.projectRoot);
|
|
984
|
-
if (request.action === 'config.edit') {
|
|
985
|
-
return success(request.action, {
|
|
986
|
-
message: 'Operating configuration is managed at .planr/operate/config.json.',
|
|
987
|
-
data: { path: '.planr/operate/config.json', config },
|
|
988
|
-
next: ['Edit .planr/operate/config.json', 'planr operate config validate'],
|
|
989
|
-
});
|
|
990
|
-
}
|
|
991
|
-
return success(request.action, {
|
|
992
|
-
data: config,
|
|
993
|
-
message: request.action === 'config.validate' ? 'Operating configuration is valid.' : undefined,
|
|
994
|
-
});
|
|
995
|
-
}
|
|
996
|
-
async function profiles(request) {
|
|
997
|
-
if (request.action === 'profiles.list') {
|
|
998
|
-
return success(request.action, { data: listOperatingProfiles() });
|
|
999
|
-
}
|
|
1000
|
-
if (request.action === 'profiles.show') {
|
|
1001
|
-
const profile = argument(request, 'profile');
|
|
1002
|
-
if (!profile) {
|
|
1003
|
-
throw new OperateError('E_OPERATE_CONFIG_INVALID', 'Profile ID is required.');
|
|
1004
|
-
}
|
|
1005
|
-
return success(request.action, {
|
|
1006
|
-
data: getOperatingProfile(profile),
|
|
1007
|
-
});
|
|
1008
|
-
}
|
|
1009
|
-
const file = argument(request, 'file');
|
|
1010
|
-
if (!file)
|
|
1011
|
-
throw new OperateError('E_OPERATE_CONFIG_INVALID', 'Profile file is required.');
|
|
1012
|
-
const parsed = await readCustomOperatingProfile(request.projectRoot, file);
|
|
1013
|
-
const profile = { ...getOperatingProfile('custom'), ...parsed };
|
|
1014
|
-
if (!profile.enabledRoles?.length) {
|
|
1015
|
-
throw new OperateError('E_OPERATE_CONFIG_INVALID', 'Custom profile is incomplete.');
|
|
1016
|
-
}
|
|
1017
|
-
return success(request.action, { data: profile, message: 'Custom profile is valid.' });
|
|
1018
|
-
}
|
|
1019
|
-
/**
|
|
1020
|
-
* FR10 / T-009 + T-018 — the legacy `.planr/operate-profile.json` field migration
|
|
1021
|
-
* (`profiles migrate inspect|apply`), routed through the action map. T-009 wired
|
|
1022
|
-
* these directly to `profile-migration.ts`, which meant they bypassed the
|
|
1023
|
-
* cross-cutting handling every other action receives here — notably the
|
|
1024
|
-
* storage-layout auto-migration guard in `executeOperateAction`. Dispatching them
|
|
1025
|
-
* through the map restores that guard for the mutating `apply` (so a
|
|
1026
|
-
* SPEC-002-layout project is reconciled on open before the profile is rewritten),
|
|
1027
|
-
* plus the standard `--json` shaping and structured provenance. `inspect` stays a
|
|
1028
|
-
* read-only preview (`OPERATE_READ_ONLY_ACTIONS`): per FR10 it previews without
|
|
1029
|
-
* mutating, so it must not migrate the on-disk layout as a side effect. The
|
|
1030
|
-
* migration's own semantics are unchanged: still idempotent, still an exact
|
|
1031
|
-
* digest-verified backup before mutation, still a journalled transaction with
|
|
1032
|
-
* rollback — all owned by `profile-migration.ts`, which this handler only calls.
|
|
1033
|
-
*/
|
|
1034
|
-
async function profileMigration(request) {
|
|
1035
|
-
const localRoot = option(request, 'localRoot', undefined);
|
|
1036
|
-
const scoped = localRoot ? { localRoot } : {};
|
|
1037
|
-
if (request.action === 'profiles.migrate.inspect') {
|
|
1038
|
-
const inspection = await inspectOperatingProfileMigration({
|
|
1039
|
-
projectRoot: request.projectRoot,
|
|
1040
|
-
...scoped,
|
|
1041
|
-
});
|
|
1042
|
-
return success(request.action, {
|
|
1043
|
-
message: !inspection.present
|
|
1044
|
-
? 'No legacy .planr/operate-profile.json is present; nothing to migrate.'
|
|
1045
|
-
: inspection.changed
|
|
1046
|
-
? `Legacy profile migration previewed: ${inspection.converted.length} field(s) converted, ${inspection.unsupported.length} unsupported. No change was made.`
|
|
1047
|
-
: 'Legacy profile already matches the current schema; nothing to migrate.',
|
|
1048
|
-
counts: {
|
|
1049
|
-
preserved: inspection.preserved.length,
|
|
1050
|
-
converted: inspection.converted.length,
|
|
1051
|
-
unsupported: inspection.unsupported.length,
|
|
1052
|
-
},
|
|
1053
|
-
warnings: inspection.unsupported.map((entry) => `${entry.field}: ${entry.reason}`),
|
|
1054
|
-
data: inspection,
|
|
1055
|
-
next: inspection.present && inspection.changed
|
|
1056
|
-
? ['planr operate profiles migrate apply --yes']
|
|
1057
|
-
: [],
|
|
1058
|
-
});
|
|
1059
|
-
}
|
|
1060
|
-
const applied = await applyOperatingProfileMigration({
|
|
1061
|
-
projectRoot: request.projectRoot,
|
|
1062
|
-
confirmed: option(request, 'yes', false),
|
|
1063
|
-
...scoped,
|
|
1064
|
-
});
|
|
1065
|
-
return success(request.action, {
|
|
1066
|
-
message: !applied.present
|
|
1067
|
-
? 'No legacy .planr/operate-profile.json is present; nothing to migrate.'
|
|
1068
|
-
: applied.applied
|
|
1069
|
-
? `Migrated the legacy operating profile; exact pre-migration backup written. Converted ${applied.converted.length} field(s); dropped ${applied.unsupported.length} unsupported field(s).`
|
|
1070
|
-
: 'Legacy operating profile already matches the current schema; no change was made.',
|
|
1071
|
-
paths: applied.backupPath ? { backup: applied.backupPath } : {},
|
|
1072
|
-
counts: {
|
|
1073
|
-
preserved: applied.preserved.length,
|
|
1074
|
-
converted: applied.converted.length,
|
|
1075
|
-
unsupported: applied.unsupported.length,
|
|
1076
|
-
},
|
|
1077
|
-
warnings: applied.unsupported.map((entry) => `${entry.field}: ${entry.reason}`),
|
|
1078
|
-
data: applied,
|
|
1079
|
-
});
|
|
1080
|
-
}
|
|
1081
|
-
/**
|
|
1082
|
-
* The cycle states a governed cycle carries while it is still mid-flight: work
|
|
1083
|
-
* may already be durably recorded, but no gate has been reached. The aggregate
|
|
1084
|
-
* surfaces (`status`, `review`) must never describe a board in one of these
|
|
1085
|
-
* states as quiet or as standing at the review gate — the per-lens board files
|
|
1086
|
-
* stay honest, so an aggregate that claims otherwise is the only thing a reader
|
|
1087
|
-
* can be misled by.
|
|
1088
|
-
*/
|
|
1089
|
-
const OPERATING_IN_FLIGHT_CYCLE_STATES = new Set([
|
|
1090
|
-
'preparing',
|
|
1091
|
-
'collecting',
|
|
1092
|
-
'advising',
|
|
1093
|
-
'consolidating',
|
|
1094
|
-
]);
|
|
1095
|
-
/** The only cycle states that genuinely present the mandatory human review gate. */
|
|
1096
|
-
const OPERATING_REVIEW_GATE_CYCLE_STATES = new Set(['reviewable', 'blocked', 'failed']);
|
|
1097
|
-
/**
|
|
1098
|
-
* The advisory lenses a cycle is expected to record: the roles the cycle itself
|
|
1099
|
-
* enabled (or every board role when it recorded no explicit selection), with
|
|
1100
|
-
* Chair always expected because the review gate needs the consolidation.
|
|
1101
|
-
*/
|
|
1102
|
-
function expectedOperatingCycleRoles(cycle) {
|
|
1103
|
-
const enabled = Array.isArray(cycle.enabledRoles)
|
|
1104
|
-
? cycle.enabledRoles.filter((entry) => typeof entry === 'string')
|
|
1105
|
-
: [];
|
|
1106
|
-
const wanted = new Set(enabled.length > 0 ? enabled : OPERATING_BOARD_ROLES.map((role) => role.id));
|
|
1107
|
-
wanted.add('chair');
|
|
1108
|
-
return OPERATING_BOARD_ROLES.map((role) => role.id).filter((id) => wanted.has(id));
|
|
1109
|
-
}
|
|
1110
|
-
/**
|
|
1111
|
-
* The truthful one-line account of a mid-flight cycle for `status`: how much of
|
|
1112
|
-
* the board has durably recorded, and what is still outstanding before the
|
|
1113
|
-
* review gate. Sourced from the committed `advisor-result` records, never from
|
|
1114
|
-
* `state.summary.quiet` — projected findings only exist after consolidation, so
|
|
1115
|
-
* a board with five recorded lenses and no Chair still summarizes as quiet, and
|
|
1116
|
-
* reporting that summary is the false-negative this replaces.
|
|
1117
|
-
*/
|
|
1118
|
-
async function describeInFlightOperatingCycle(store, cycle) {
|
|
1119
|
-
const expected = expectedOperatingCycleRoles(cycle);
|
|
1120
|
-
const results = await readPersistedOperatingRoleResults(store, cycle.id);
|
|
1121
|
-
const recorded = new Set(results.map((result) => result.roleId));
|
|
1122
|
-
const pending = expected.filter((roleId) => !recorded.has(roleId));
|
|
1123
|
-
const proposals = results.reduce((total, result) => total + result.proposals.length, 0);
|
|
1124
|
-
return [
|
|
1125
|
-
`Cycle ${cycle.id} is ${cycle.state}, not quiet:`,
|
|
1126
|
-
`${expected.filter((roleId) => recorded.has(roleId)).length} of ${expected.length}`,
|
|
1127
|
-
`advisory lens result(s) recorded, ${proposals} recorded proposal(s) awaiting consolidation.`,
|
|
1128
|
-
pending.length > 0
|
|
1129
|
-
? `Outstanding lens(es): ${pending.join(', ')}.`
|
|
1130
|
-
: 'Every expected lens has recorded; consolidation into a reviewable board is outstanding.',
|
|
1131
|
-
].join(' ');
|
|
1132
|
-
}
|
|
1133
|
-
async function status(request) {
|
|
1134
|
-
const config = await validateOperatingConfiguration(request.projectRoot);
|
|
1135
|
-
const localRoot = option(request, 'localRoot', undefined);
|
|
1136
|
-
await assertCommittedOperatingView(request.projectRoot, localRoot ? { localRoot } : {});
|
|
1137
|
-
const store = new OperatingEventStore(request.projectRoot, localRoot ? { localRoot } : {});
|
|
1138
|
-
const state = await store.state();
|
|
1139
|
-
const activeCycle = [...state.cycles]
|
|
1140
|
-
.filter((cycle) => !['closed', 'cancelled'].includes(cycle.state))
|
|
1141
|
-
.sort((left, right) => left.id.localeCompare(right.id))
|
|
1142
|
-
.at(-1);
|
|
1143
|
-
// FR8 / E-008: surface `nextDueAt` via the pipeline's pure calculator with an
|
|
1144
|
-
// INJECTED clock. This CLI boundary supplies `now` (an explicit option or the
|
|
1145
|
-
// wall clock); the calculator itself reads no `Date.now()`. `manual` → null;
|
|
1146
|
-
// `weekly` / `monthly` → the computed due date from the persisted `lastRunAt`.
|
|
1147
|
-
const now = option(request, 'now', undefined) ?? new Date().toISOString();
|
|
1148
|
-
const lastRunAt = await readOperatingLastRunAt(request.projectRoot, localRoot ? { localRoot } : {});
|
|
1149
|
-
const nextDueAt = await computeNextDueAt(config.cadence, lastRunAt, now);
|
|
1150
|
-
// A cycle that is still preparing/collecting/advising/consolidating is
|
|
1151
|
-
// mid-flight, so neither `quiet` nor a surfaced-findings count describes it:
|
|
1152
|
-
// both are projections that only become meaningful after consolidation. Report
|
|
1153
|
-
// the real cycle state and the outstanding lenses instead.
|
|
1154
|
-
const inFlightCycle = activeCycle && OPERATING_IN_FLIGHT_CYCLE_STATES.has(activeCycle.state)
|
|
1155
|
-
? activeCycle
|
|
1156
|
-
: undefined;
|
|
1157
|
-
return success(request.action, {
|
|
1158
|
-
data: { ...state, cadence: { mode: config.cadence, lastRunAt, nextDueAt } },
|
|
1159
|
-
message: activeCycle?.state === 'blocked'
|
|
1160
|
-
? `Operating Board is blocked on ${state.summary.openGaps} evidence or advisor readiness gap(s).`
|
|
1161
|
-
: inFlightCycle
|
|
1162
|
-
? await describeInFlightOperatingCycle(store, inFlightCycle)
|
|
1163
|
-
: state.summary.quiet
|
|
1164
|
-
? 'Operating Board is quiet.'
|
|
1165
|
-
: `${state.summary.surfacedFindings} finding(s) are surfaced.`,
|
|
1166
|
-
});
|
|
1167
|
-
}
|
|
1168
|
-
async function run(request) {
|
|
1169
|
-
await validateOperatingConfiguration(request.projectRoot);
|
|
1170
|
-
const requestedRuntime = option(request, 'runtime', 'auto');
|
|
1171
|
-
const resolvedRuntime = await resolvedOperatingRuntime(request.projectRoot, requestedRuntime);
|
|
1172
|
-
const nativeAdvisors = await usesNativeOperatingAdvisors(request.projectRoot, requestedRuntime);
|
|
1173
|
-
if (resolvedRuntime !== 'auto' &&
|
|
1174
|
-
!nativeAdvisors &&
|
|
1175
|
-
!option(request, 'offline', false) &&
|
|
1176
|
-
!option(request, 'reviewOnly', false)) {
|
|
1177
|
-
throw new OperateError('E_RUNTIME_UNSUPPORTED', `Runtime ${resolvedRuntime} does not expose a compatible agent-native Operate workflow.`, {
|
|
1178
|
-
runtime: resolvedRuntime,
|
|
1179
|
-
recovery: 'Run `planr setup --scope user`, then restart the runtime so its generated Operate workflow is available.',
|
|
1180
|
-
});
|
|
1181
|
-
}
|
|
1182
|
-
const deferAdvisors = !option(request, 'offline', false) &&
|
|
1183
|
-
!option(request, 'dryRun', false) &&
|
|
1184
|
-
!option(request, 'reviewOnly', false) &&
|
|
1185
|
-
nativeAdvisors;
|
|
1186
|
-
// Preflight the structured-provider key on a non-offline, non-native preview so
|
|
1187
|
-
// `run --preview` names a missing key before any cycle starts, rather than
|
|
1188
|
-
// surfacing it only when a real cycle reaches the provider path. Native and
|
|
1189
|
-
// offline runs never need the structured key, so they skip the check.
|
|
1190
|
-
const previewProviderWarnings = [];
|
|
1191
|
-
if (option(request, 'preview', false) &&
|
|
1192
|
-
!option(request, 'offline', false) &&
|
|
1193
|
-
!option(request, 'reviewOnly', false) &&
|
|
1194
|
-
!nativeAdvisors) {
|
|
1195
|
-
const openPlanrConfig = await loadConfig(request.projectRoot).catch(() => null);
|
|
1196
|
-
const readiness = openPlanrConfig
|
|
1197
|
-
? await resolveAIProviderReadiness(openPlanrConfig)
|
|
1198
|
-
: {
|
|
1199
|
-
configured: false,
|
|
1200
|
-
keyResolvable: false,
|
|
1201
|
-
remedy: 'No AI provider is configured. Run `planr config set-provider <name>` then `planr config set-key <provider>`, or run offline with --offline.',
|
|
1202
|
-
};
|
|
1203
|
-
if (!readiness.keyResolvable && readiness.remedy) {
|
|
1204
|
-
previewProviderWarnings.push(readiness.remedy);
|
|
1205
|
-
}
|
|
1206
|
-
}
|
|
1207
|
-
const result = await runOperatingCycle({
|
|
1208
|
-
projectRoot: request.projectRoot,
|
|
1209
|
-
cycleId: option(request, 'cycleId', undefined),
|
|
1210
|
-
focus: stringList(request.options.focus),
|
|
1211
|
-
depth: option(request, 'depth', 'standard'),
|
|
1212
|
-
runtime: resolvedRuntime,
|
|
1213
|
-
offline: option(request, 'offline', false),
|
|
1214
|
-
reviewOnly: option(request, 'reviewOnly', false),
|
|
1215
|
-
preview: option(request, 'preview', false),
|
|
1216
|
-
dryRun: option(request, 'dryRun', false),
|
|
1217
|
-
confirmed: option(request, 'yes', false),
|
|
1218
|
-
quiet: option(request, 'json', false),
|
|
1219
|
-
deferAdvisors,
|
|
1220
|
-
});
|
|
1221
|
-
const projected = result.state?.cycles.find((cycle) => cycle.id === result.cycle.id);
|
|
1222
|
-
const drafts = !result.preview &&
|
|
1223
|
-
!result.dryRun &&
|
|
1224
|
-
!result.nativeHandoff &&
|
|
1225
|
-
['reviewable', 'closed'].includes(projected?.state ?? '')
|
|
1226
|
-
? await materializeOperatingDrafts({
|
|
1227
|
-
projectRoot: request.projectRoot,
|
|
1228
|
-
cycleId: result.cycle.id,
|
|
1229
|
-
})
|
|
1230
|
-
: { created: [], existing: [], rejected: [] };
|
|
1231
|
-
if (drafts.created.length > 0 && result.state) {
|
|
1232
|
-
await persistOperatingProjections({
|
|
1233
|
-
projectRoot: request.projectRoot,
|
|
1234
|
-
state: result.state,
|
|
1235
|
-
revalidateEventHead: async () => (await new OperatingEventStore(request.projectRoot).replay()).eventHead,
|
|
1236
|
-
});
|
|
1237
|
-
}
|
|
1238
|
-
const counts = {
|
|
1239
|
-
findings: result.state?.findings.filter((entry) => entry.cycleId === result.cycle.id).length ?? 0,
|
|
1240
|
-
decisions: result.state?.decisions.filter((entry) => entry.cycleId === result.cycle.id).length ?? 0,
|
|
1241
|
-
gaps: result.state?.dataGaps.filter((entry) => entry.cycleId === result.cycle.id).length ?? 0,
|
|
1242
|
-
specs: result.state?.specLinks.filter((entry) => entry.cycleId === result.cycle.id).length ?? 0,
|
|
1243
|
-
artifacts: drafts.created.length + drafts.existing.length,
|
|
1244
|
-
};
|
|
1245
|
-
const handoff = result.nativeHandoff
|
|
1246
|
-
? await createOperatingAdapterStartHandoff({
|
|
1247
|
-
projectRoot: request.projectRoot,
|
|
1248
|
-
cycleId: result.nativeHandoff.cycleId,
|
|
1249
|
-
evidenceDigest: result.nativeHandoff.evidenceDigest,
|
|
1250
|
-
runtime: result.cycle.producer.runtime,
|
|
1251
|
-
phase: result.nativeHandoff.phase,
|
|
1252
|
-
roles: result.nativeHandoff.roles,
|
|
1253
|
-
})
|
|
1254
|
-
: undefined;
|
|
1255
|
-
const nextActions = result.preview
|
|
1256
|
-
? [
|
|
1257
|
-
option(request, 'offline', false)
|
|
1258
|
-
? 'planr operate run --offline'
|
|
1259
|
-
: nativeAdvisors
|
|
1260
|
-
? `planr operate run --runtime ${resolvedRuntime}`
|
|
1261
|
-
: 'planr operate run',
|
|
1262
|
-
]
|
|
1263
|
-
: handoff
|
|
1264
|
-
? handoff.next.map(({ argv }) => argv.join(' '))
|
|
1265
|
-
: [`planr operate review ${result.cycle.id}`];
|
|
1266
|
-
return success(request.action, {
|
|
1267
|
-
message: result.preview
|
|
1268
|
-
? 'Operating cycle preview is ready; no provider calls or writes were made.'
|
|
1269
|
-
: result.dryRun
|
|
1270
|
-
? 'Operating cycle dry-run completed without committing state.'
|
|
1271
|
-
: result.nativeHandoff
|
|
1272
|
-
? `Operating cycle is awaiting isolated native ${result.nativeHandoff.phase} execution.`
|
|
1273
|
-
: projected?.state === 'blocked'
|
|
1274
|
-
? 'Operating cycle is blocked on evidence or advisor readiness.'
|
|
1275
|
-
: 'Operating cycle is ready for human review.',
|
|
1276
|
-
cycleId: result.cycle.id,
|
|
1277
|
-
state: projected?.state ?? result.cycle.state,
|
|
1278
|
-
paths: {
|
|
1279
|
-
cycle: `.planr/operate/cycles/${result.cycle.id}`,
|
|
1280
|
-
brief: `.planr/operate/cycles/${result.cycle.id}/brief.md`,
|
|
1281
|
-
report: `.planr/operate/cycles/${result.cycle.id}/report.md`,
|
|
1282
|
-
reportJson: `.planr/operate/cycles/${result.cycle.id}/report.json`,
|
|
1283
|
-
actions: `.planr/operate/cycles/${result.cycle.id}/actions.md`,
|
|
1284
|
-
},
|
|
1285
|
-
counts,
|
|
1286
|
-
handoff,
|
|
1287
|
-
warnings: [
|
|
1288
|
-
...new Set([
|
|
1289
|
-
...(result.cycle.warnings ?? []),
|
|
1290
|
-
...stringList(projected?.warnings),
|
|
1291
|
-
...previewProviderWarnings,
|
|
1292
|
-
]),
|
|
1293
|
-
],
|
|
1294
|
-
nextActions,
|
|
1295
|
-
data: { ...result, drafts },
|
|
1296
|
-
next: nextActions,
|
|
1297
|
-
});
|
|
1298
|
-
}
|
|
1299
|
-
async function drafts(request) {
|
|
1300
|
-
if (request.action === 'drafts.list') {
|
|
1301
|
-
const records = await listOperatingDrafts(request.projectRoot);
|
|
1302
|
-
return success(request.action, {
|
|
1303
|
-
data: records.map((record) => record.draft),
|
|
1304
|
-
counts: { artifacts: records.length },
|
|
1305
|
-
});
|
|
1306
|
-
}
|
|
1307
|
-
const draftId = argument(request, 'draftId') ?? argument(request, 'id');
|
|
1308
|
-
if (!draftId) {
|
|
1309
|
-
throw new OperateError('E_OPERATE_CONFIG_INVALID', 'Draft ID is required.');
|
|
1310
|
-
}
|
|
1311
|
-
if (request.action === 'drafts.show') {
|
|
1312
|
-
return success(request.action, {
|
|
1313
|
-
data: await showOperatingDraft(request.projectRoot, draftId),
|
|
1314
|
-
});
|
|
1315
|
-
}
|
|
1316
|
-
if (!option(request, 'yes', false)) {
|
|
1317
|
-
throw new OperateError('E_OPERATE_AUTHORITY_REQUIRED', `${request.action} requires explicit confirmation with --yes.`);
|
|
1318
|
-
}
|
|
1319
|
-
if (request.action === 'drafts.approve') {
|
|
1320
|
-
return success(request.action, {
|
|
1321
|
-
data: await approveOperatingDraft(request.projectRoot, draftId),
|
|
1322
|
-
message: `Operating draft ${draftId} approved. PLAN and SHIP remain separate actions.`,
|
|
1323
|
-
});
|
|
1324
|
-
}
|
|
1325
|
-
return success(request.action, {
|
|
1326
|
-
data: await discardOperatingDraft(request.projectRoot, draftId),
|
|
1327
|
-
message: `Operating draft ${draftId} discarded.`,
|
|
1328
|
-
});
|
|
1329
|
-
}
|
|
1330
|
-
async function contextResearch(request) {
|
|
1331
|
-
if (request.action === 'context.show') {
|
|
1332
|
-
return success(request.action, {
|
|
1333
|
-
data: await readOperatingContextResearch(request.projectRoot),
|
|
1334
|
-
});
|
|
1335
|
-
}
|
|
1336
|
-
if (request.action === 'context.review') {
|
|
1337
|
-
return success(request.action, {
|
|
1338
|
-
data: await recordOperatingContextResearch({
|
|
1339
|
-
projectRoot: request.projectRoot,
|
|
1340
|
-
stdin: request.stdin,
|
|
1341
|
-
}),
|
|
1342
|
-
message: 'Runtime-authored context was validated against the workspace and is ready for one compact owner review.',
|
|
1343
|
-
next: ['planr operate init'],
|
|
1344
|
-
});
|
|
1345
|
-
}
|
|
1346
|
-
const runtime = await resolvedOperatingRuntime(request.projectRoot, option(request, 'runtime', 'auto'));
|
|
1347
|
-
if (runtime === 'auto') {
|
|
1348
|
-
throw new OperateError('E_RUNTIME_UNSUPPORTED', 'Context research requires a selected Claude Code, Codex, or Cursor runtime.');
|
|
1349
|
-
}
|
|
1350
|
-
const researchMode = option(request, 'research', 'local');
|
|
1351
|
-
const consentDigest = researchMode === 'connected'
|
|
1352
|
-
? canonicalDigest({
|
|
1353
|
-
action: 'operate.context.connected-research',
|
|
1354
|
-
runtime,
|
|
1355
|
-
project: canonicalDigest(request.projectRoot),
|
|
1356
|
-
})
|
|
1357
|
-
: null;
|
|
1358
|
-
const preview = option(request, 'preview', false);
|
|
1359
|
-
if (researchMode === 'connected' && !preview && !option(request, 'yes', false)) {
|
|
1360
|
-
throw new OperateError('E_OPERATE_AUTHORITY_REQUIRED', 'Connected research requires the exact preview and explicit confirmation.', {
|
|
1361
|
-
confirmationDigest: consentDigest,
|
|
1362
|
-
recovery: `planr operate context refresh --research connected --runtime ${runtime} --yes --confirm ${consentDigest}`,
|
|
1363
|
-
});
|
|
1364
|
-
}
|
|
1365
|
-
const confirmed = option(request, 'confirm', undefined);
|
|
1366
|
-
if (researchMode === 'connected' && !preview && confirmed !== consentDigest) {
|
|
1367
|
-
throw new OperateError('E_OPERATE_AUTHORITY_REQUIRED', 'Connected research confirmation does not match the current project and runtime.', { confirmationDigest: consentDigest });
|
|
1368
|
-
}
|
|
1369
|
-
const prepared = await prepareOperatingContextResearch({
|
|
1370
|
-
projectRoot: request.projectRoot,
|
|
1371
|
-
runtime,
|
|
1372
|
-
researchMode,
|
|
1373
|
-
connectedResearchConsentDigest: consentDigest,
|
|
1374
|
-
preview,
|
|
1375
|
-
});
|
|
1376
|
-
return success(request.action, {
|
|
1377
|
-
data: { ...prepared, confirmationDigest: consentDigest },
|
|
1378
|
-
preview: preview ? { researchMode, runtime, confirmationDigest: consentDigest } : undefined,
|
|
1379
|
-
message: preview
|
|
1380
|
-
? 'Context research preview is ready; no workspace or provider action occurred.'
|
|
1381
|
-
: 'Agent-native context research is prepared for the selected runtime.',
|
|
1382
|
-
next: preview
|
|
1383
|
-
? [
|
|
1384
|
-
`planr operate context refresh --research ${researchMode} --runtime ${runtime}${researchMode === 'connected' ? ` --yes --confirm ${consentDigest}` : ''}`,
|
|
1385
|
-
]
|
|
1386
|
-
: ['planr operate context review --stdin --json'],
|
|
1387
|
-
});
|
|
1388
|
-
}
|
|
1389
|
-
/**
|
|
1390
|
-
* Whether `review` is genuinely standing at the mandatory human review gate —
|
|
1391
|
-
* and, when it is not, the exact phase the cycle actually reached plus the
|
|
1392
|
-
* artifacts still missing. Verified from the committed cycle state and the
|
|
1393
|
-
* on-disk artifacts (`verifyOperatingCompletionPhases`), never from the fact
|
|
1394
|
-
* that the command ran: announcing the gate for a cycle still in `advising`
|
|
1395
|
-
* tells a reader the board is done deliberating when five lenses are recorded
|
|
1396
|
-
* and the Chair has not run.
|
|
1397
|
-
*/
|
|
1398
|
-
async function operatingReviewGateMessage(input) {
|
|
1399
|
-
const scoped = input.localRoot ? { localRoot: input.localRoot } : {};
|
|
1400
|
-
const state = await new OperatingEventStore(input.projectRoot, scoped).state();
|
|
1401
|
-
const targetId = input.cycleId ?? state.summary.currentCycleId ?? undefined;
|
|
1402
|
-
const cycle = targetId ? state.cycles.find((entry) => entry.id === targetId) : undefined;
|
|
1403
|
-
if (!cycle) {
|
|
1404
|
-
return {
|
|
1405
|
-
message: 'No governed operating cycle exists yet, so no review gate has been reached. No route has been applied.',
|
|
1406
|
-
warnings: [],
|
|
1407
|
-
};
|
|
1408
|
-
}
|
|
1409
|
-
if (OPERATING_REVIEW_GATE_CYCLE_STATES.has(cycle.state)) {
|
|
1410
|
-
return {
|
|
1411
|
-
message: 'This is the mandatory human review gate. No route has been applied.',
|
|
1412
|
-
warnings: [],
|
|
1413
|
-
};
|
|
1414
|
-
}
|
|
1415
|
-
const completion = await verifyOperatingCompletionPhases(state, cycle.id, resolveOperatingPaths(input.projectRoot, scoped));
|
|
1416
|
-
return {
|
|
1417
|
-
message: [
|
|
1418
|
-
`Cycle ${cycle.id} is ${cycle.state} and has NOT reached the human review gate.`,
|
|
1419
|
-
`Verified on disk: reached phase ${completion.reachedPhase ?? 'none'} (${completion.reachedLabel}).`,
|
|
1420
|
-
...(completion.nextPhase
|
|
1421
|
-
? [`Current phase: ${completion.nextPhase} — ${completion.nextLabel}.`]
|
|
1422
|
-
: []),
|
|
1423
|
-
...(completion.missing.length > 0
|
|
1424
|
-
? [`Still missing: ${completion.missing.join('; ')}.`]
|
|
1425
|
-
: []),
|
|
1426
|
-
'No route has been applied.',
|
|
1427
|
-
].join(' '),
|
|
1428
|
-
warnings: completion.missing.map((item) => `Missing before the review gate: ${item}`),
|
|
1429
|
-
};
|
|
1430
|
-
}
|
|
1431
|
-
async function reviewOrBrief(request) {
|
|
1432
|
-
const cycleId = argument(request, 'cycleId');
|
|
1433
|
-
// FR3/E-003: the human review gate renders report Markdown (brief + per-role
|
|
1434
|
-
// lens reports + exact next actions), never a raw `JSON.stringify` of the
|
|
1435
|
-
// state. `--json` keeps returning the exact raw state object, byte-unchanged.
|
|
1436
|
-
const human = request.action === 'review' && !option(request, 'json', false);
|
|
1437
|
-
const localRoot = option(request, 'localRoot', undefined);
|
|
1438
|
-
const data = await readOperatingReview({
|
|
1439
|
-
projectRoot: request.projectRoot,
|
|
1440
|
-
cycleId,
|
|
1441
|
-
brief: request.action === 'brief',
|
|
1442
|
-
human,
|
|
1443
|
-
localRoot,
|
|
1444
|
-
});
|
|
1445
|
-
if (request.action !== 'review')
|
|
1446
|
-
return success(request.action, { data });
|
|
1447
|
-
const gate = await operatingReviewGateMessage({
|
|
1448
|
-
projectRoot: request.projectRoot,
|
|
1449
|
-
cycleId,
|
|
1450
|
-
localRoot,
|
|
1451
|
-
});
|
|
1452
|
-
return success(request.action, { data, message: gate.message, warnings: gate.warnings });
|
|
1453
|
-
}
|
|
1454
|
-
async function report(request) {
|
|
1455
|
-
const requestedFormat = option(request, 'format', undefined);
|
|
1456
|
-
if (requestedFormat && !['markdown', 'json'].includes(requestedFormat)) {
|
|
1457
|
-
throw new OperateError('E_OPERATE_CONFIG_INVALID', `Unknown report format ${requestedFormat}. Use markdown or json.`);
|
|
1458
|
-
}
|
|
1459
|
-
const data = await readOperatingReport({
|
|
1460
|
-
projectRoot: request.projectRoot,
|
|
1461
|
-
cycleId: argument(request, 'cycleId'),
|
|
1462
|
-
lens: option(request, 'lens', 'all'),
|
|
1463
|
-
localRoot: option(request, 'localRoot', undefined),
|
|
1464
|
-
});
|
|
1465
|
-
const format = requestedFormat ?? (option(request, 'json', false) ? 'json' : 'markdown');
|
|
1466
|
-
return success(request.action, {
|
|
1467
|
-
data: format === 'json' ? data : data.markdown,
|
|
1468
|
-
message: `Operating report is ready for ${data.cycleId}.`,
|
|
1469
|
-
});
|
|
1470
|
-
}
|
|
1471
|
-
async function collections(request) {
|
|
1472
|
-
const [collection, operation] = request.action.split('.');
|
|
1473
|
-
const singular = collection === 'cycles'
|
|
1474
|
-
? 'cycleId'
|
|
1475
|
-
: collection === 'findings'
|
|
1476
|
-
? 'findingId'
|
|
1477
|
-
: collection === 'decisions'
|
|
1478
|
-
? 'decisionId'
|
|
1479
|
-
: collection === 'gaps'
|
|
1480
|
-
? 'gapId'
|
|
1481
|
-
: collection === 'routes'
|
|
1482
|
-
? 'routeId'
|
|
1483
|
-
: collection === 'evidence'
|
|
1484
|
-
? 'evidenceId'
|
|
1485
|
-
: 'migrationId';
|
|
1486
|
-
const id = argument(request, singular) ?? argument(request, 'id');
|
|
1487
|
-
const data = await readOperatingCollection({
|
|
1488
|
-
projectRoot: request.projectRoot,
|
|
1489
|
-
collection: collection,
|
|
1490
|
-
...(operation === 'show' ? { id } : {}),
|
|
1491
|
-
});
|
|
1492
|
-
if (operation === 'show' && !data) {
|
|
1493
|
-
throw new OperateError('E_OPERATE_STATE_INVALID', `Unknown ${collection} record ${id}.`);
|
|
1494
|
-
}
|
|
1495
|
-
return success(request.action, { data });
|
|
1496
|
-
}
|
|
1497
|
-
async function cycleMutation(request) {
|
|
1498
|
-
const cycleId = argument(request, 'cycleId');
|
|
1499
|
-
if (!cycleId)
|
|
1500
|
-
throw new OperateError('E_OPERATE_STATE_INVALID', 'Cycle ID is required.');
|
|
1501
|
-
const action = request.action.slice('cycles.'.length);
|
|
1502
|
-
return success(request.action, {
|
|
1503
|
-
data: await transitionOperatingCycle({
|
|
1504
|
-
projectRoot: request.projectRoot,
|
|
1505
|
-
cycleId,
|
|
1506
|
-
action,
|
|
1507
|
-
confirmed: option(request, 'yes', false),
|
|
1508
|
-
}),
|
|
1509
|
-
});
|
|
1510
|
-
}
|
|
1511
|
-
async function abandonStalledRole(request) {
|
|
1512
|
-
// SPEC-005 T-020 — the operator escape for a cycle stranded at `phase: advisors`
|
|
1513
|
-
// because a runtime dispatched a lens and reported nothing. Gated on a lapsed
|
|
1514
|
-
// adapter lease + `--yes`, it terminally governs the still-unrecorded lenses
|
|
1515
|
-
// `not_evaluated` so a following `planr operate run` (offline when no runtime is
|
|
1516
|
-
// available) reaches a reviewable cycle without discarding the recorded work. It
|
|
1517
|
-
// never invokes the runtime lifecycle, so it works when the runtime is gone.
|
|
1518
|
-
const cycleId = argument(request, 'cycleId');
|
|
1519
|
-
if (!cycleId)
|
|
1520
|
-
throw new OperateError('E_OPERATE_STATE_INVALID', 'Cycle ID is required.');
|
|
1521
|
-
const data = await reapStalledOperatingRoles({
|
|
1522
|
-
projectRoot: request.projectRoot,
|
|
1523
|
-
cycleId,
|
|
1524
|
-
role: option(request, 'role', undefined),
|
|
1525
|
-
reason: option(request, 'reason', undefined),
|
|
1526
|
-
confirmed: option(request, 'yes', false),
|
|
1527
|
-
});
|
|
1528
|
-
return success(request.action, { data, nextActions: data.next, next: data.next });
|
|
1529
|
-
}
|
|
1530
|
-
async function findingMutation(request) {
|
|
1531
|
-
const findingId = argument(request, 'findingId');
|
|
1532
|
-
if (!findingId)
|
|
1533
|
-
throw new OperateError('E_OPERATE_STATE_INVALID', 'Finding ID is required.');
|
|
1534
|
-
return success(request.action, {
|
|
1535
|
-
data: await governOperatingFinding({
|
|
1536
|
-
projectRoot: request.projectRoot,
|
|
1537
|
-
findingId,
|
|
1538
|
-
action: request.action.slice('findings.'.length),
|
|
1539
|
-
confirmed: option(request, 'yes', false),
|
|
1540
|
-
reason: option(request, 'reason', undefined),
|
|
1541
|
-
impact: request.options.impact,
|
|
1542
|
-
confidence: request.options.confidence,
|
|
1543
|
-
ease: request.options.ease,
|
|
1544
|
-
}),
|
|
1545
|
-
});
|
|
1546
|
-
}
|
|
1547
|
-
async function routeMutation(request) {
|
|
1548
|
-
const routeId = argument(request, 'routeId');
|
|
1549
|
-
if (!routeId)
|
|
1550
|
-
throw new OperateError('E_OPERATE_STATE_INVALID', 'Route ID is required.');
|
|
1551
|
-
const data = (await applyOrRollbackRoute({
|
|
1552
|
-
projectRoot: request.projectRoot,
|
|
1553
|
-
routeId,
|
|
1554
|
-
action: request.action.endsWith('.apply') ? 'apply' : 'rollback',
|
|
1555
|
-
previewDigest: option(request, 'previewDigest', undefined),
|
|
1556
|
-
preview: option(request, 'preview', false) || option(request, 'dryRun', false),
|
|
1557
|
-
confirmed: option(request, 'yes', false),
|
|
1558
|
-
}));
|
|
1559
|
-
return success(request.action, {
|
|
1560
|
-
data,
|
|
1561
|
-
nextActions: data.state === 'awaiting-artifact-review'
|
|
1562
|
-
? [
|
|
1563
|
-
`planr operate routes apply ${routeId} --preview`,
|
|
1564
|
-
`planr operate routes apply ${routeId} --preview-digest <generated-preview-digest> --yes`,
|
|
1565
|
-
]
|
|
1566
|
-
: [],
|
|
1567
|
-
});
|
|
1568
|
-
}
|
|
1569
|
-
async function answerMutation(request) {
|
|
1570
|
-
if (request.action === 'gaps.verify') {
|
|
1571
|
-
const gapId = argument(request, 'gapId');
|
|
1572
|
-
if (!gapId)
|
|
1573
|
-
throw new OperateError('E_OPERATE_STATE_INVALID', 'Gap ID is required.');
|
|
1574
|
-
return success(request.action, {
|
|
1575
|
-
data: await verifyOperatingGap({
|
|
1576
|
-
projectRoot: request.projectRoot,
|
|
1577
|
-
gapId,
|
|
1578
|
-
evidenceRefs: stringList(request.options.evidenceRef),
|
|
1579
|
-
confirmed: option(request, 'yes', false),
|
|
1580
|
-
}),
|
|
1581
|
-
});
|
|
1582
|
-
}
|
|
1583
|
-
const value = String(option(request, 'value', request.stdin ?? '')).trim();
|
|
1584
|
-
if (request.action === 'decisions.decide') {
|
|
1585
|
-
const decisionId = argument(request, 'decisionId');
|
|
1586
|
-
if (!decisionId)
|
|
1587
|
-
throw new OperateError('E_OPERATE_STATE_INVALID', 'Decision ID is required.');
|
|
1588
|
-
return success(request.action, {
|
|
1589
|
-
data: await decideOperatingDecision({
|
|
1590
|
-
projectRoot: request.projectRoot,
|
|
1591
|
-
decisionId,
|
|
1592
|
-
value,
|
|
1593
|
-
reason: option(request, 'reason', undefined),
|
|
1594
|
-
confirmed: option(request, 'yes', false),
|
|
1595
|
-
}),
|
|
1596
|
-
});
|
|
1597
|
-
}
|
|
1598
|
-
const gapId = argument(request, 'gapId');
|
|
1599
|
-
if (!gapId)
|
|
1600
|
-
throw new OperateError('E_OPERATE_STATE_INVALID', 'Gap ID is required.');
|
|
1601
|
-
return success(request.action, {
|
|
1602
|
-
data: await answerOperatingGap({
|
|
1603
|
-
projectRoot: request.projectRoot,
|
|
1604
|
-
gapId,
|
|
1605
|
-
value,
|
|
1606
|
-
confirmed: option(request, 'yes', false),
|
|
1607
|
-
}),
|
|
1608
|
-
});
|
|
1609
|
-
}
|
|
1610
|
-
async function maintenance(request) {
|
|
1611
|
-
if (request.action.startsWith('cache.')) {
|
|
1612
|
-
return success(request.action, {
|
|
1613
|
-
data: await operatingCacheAction({
|
|
1614
|
-
projectRoot: request.projectRoot,
|
|
1615
|
-
action: request.action.endsWith('purge') ? 'purge' : 'status',
|
|
1616
|
-
confirmed: option(request, 'yes', false),
|
|
1617
|
-
localRoot: option(request, 'localRoot', undefined),
|
|
1618
|
-
}),
|
|
1619
|
-
});
|
|
1620
|
-
}
|
|
1621
|
-
if (request.action.startsWith('integrity.')) {
|
|
1622
|
-
return success(request.action, {
|
|
1623
|
-
data: await operatingIntegrityAction({
|
|
1624
|
-
projectRoot: request.projectRoot,
|
|
1625
|
-
action: request.action.endsWith('enable') ? 'enable' : 'status',
|
|
1626
|
-
confirmed: option(request, 'yes', false),
|
|
1627
|
-
}),
|
|
1628
|
-
});
|
|
1629
|
-
}
|
|
1630
|
-
if (request.action === 'diagnostics.export') {
|
|
1631
|
-
return success(request.action, {
|
|
1632
|
-
data: await exportOperatingDiagnostics({
|
|
1633
|
-
projectRoot: request.projectRoot,
|
|
1634
|
-
output: option(request, 'output', undefined),
|
|
1635
|
-
}),
|
|
1636
|
-
});
|
|
1637
|
-
}
|
|
1638
|
-
if (request.action === 'security.repair') {
|
|
1639
|
-
return success(request.action, {
|
|
1640
|
-
data: await repairOperatingSecurity({
|
|
1641
|
-
projectRoot: request.projectRoot,
|
|
1642
|
-
confirmed: option(request, 'yes', false),
|
|
1643
|
-
}),
|
|
1644
|
-
});
|
|
1645
|
-
}
|
|
1646
|
-
if (request.action === 'migrate.inspect') {
|
|
1647
|
-
return success(request.action, {
|
|
1648
|
-
data: await inspectOperatingMigration({ projectRoot: request.projectRoot }),
|
|
1649
|
-
});
|
|
1650
|
-
}
|
|
1651
|
-
if (request.action === 'migrate.apply') {
|
|
1652
|
-
return success(request.action, {
|
|
1653
|
-
data: await applyOperatingMigration({
|
|
1654
|
-
projectRoot: request.projectRoot,
|
|
1655
|
-
confirmed: option(request, 'yes', false),
|
|
1656
|
-
}),
|
|
1657
|
-
});
|
|
1658
|
-
}
|
|
1659
|
-
if (request.action === 'migrations.rollback') {
|
|
1660
|
-
const migrationId = argument(request, 'migrationId');
|
|
1661
|
-
if (!migrationId) {
|
|
1662
|
-
throw new OperateError('E_OPERATE_STATE_INVALID', 'Migration ID is required.');
|
|
1663
|
-
}
|
|
1664
|
-
return success(request.action, {
|
|
1665
|
-
data: await rollbackOperatingMigration({
|
|
1666
|
-
projectRoot: request.projectRoot,
|
|
1667
|
-
migrationId,
|
|
1668
|
-
confirmed: option(request, 'yes', false),
|
|
1669
|
-
}),
|
|
1670
|
-
});
|
|
1671
|
-
}
|
|
1672
|
-
const lifecycleNamespace = request.action.startsWith('harness.') ? 'harness.' : 'adapter.';
|
|
1673
|
-
const data = await operateAdapterLifecycle({
|
|
1674
|
-
projectRoot: request.projectRoot,
|
|
1675
|
-
action: request.action.slice(lifecycleNamespace.length),
|
|
1676
|
-
cycleId: option(request, 'cycleId', undefined),
|
|
1677
|
-
evidenceDigest: option(request, 'evidenceDigest', undefined),
|
|
1678
|
-
lease: option(request, 'lease', undefined),
|
|
1679
|
-
idempotencyKey: option(request, 'idempotencyKey', undefined),
|
|
1680
|
-
role: option(request, 'role', undefined),
|
|
1681
|
-
reason: option(request, 'reason', undefined),
|
|
1682
|
-
stdin: request.stdin,
|
|
1683
|
-
});
|
|
1684
|
-
const handoff = data && typeof data === 'object' && 'handoff' in data && data.handoff
|
|
1685
|
-
? data.handoff
|
|
1686
|
-
: undefined;
|
|
1687
|
-
const nextActions = handoff?.next.map(({ argv }) => argv.join(' ')) ?? [];
|
|
1688
|
-
return success(request.action, {
|
|
1689
|
-
data,
|
|
1690
|
-
handoff,
|
|
1691
|
-
nextActions,
|
|
1692
|
-
next: nextActions,
|
|
1693
|
-
});
|
|
1694
|
-
}
|
|
1695
|
-
const HANDLERS = {
|
|
1696
|
-
inspect,
|
|
1697
|
-
demo,
|
|
1698
|
-
init: initialize,
|
|
1699
|
-
'config.show': showConfig,
|
|
1700
|
-
'config.validate': showConfig,
|
|
1701
|
-
'config.edit': showConfig,
|
|
1702
|
-
'profiles.list': profiles,
|
|
1703
|
-
'profiles.show': profiles,
|
|
1704
|
-
'profiles.validate': profiles,
|
|
1705
|
-
'profiles.migrate.inspect': profileMigration,
|
|
1706
|
-
'profiles.migrate.apply': profileMigration,
|
|
1707
|
-
'context.show': contextResearch,
|
|
1708
|
-
'context.refresh': contextResearch,
|
|
1709
|
-
'context.review': contextResearch,
|
|
1710
|
-
'drafts.list': drafts,
|
|
1711
|
-
'drafts.show': drafts,
|
|
1712
|
-
'drafts.approve': drafts,
|
|
1713
|
-
'drafts.discard': drafts,
|
|
1714
|
-
run,
|
|
1715
|
-
review: reviewOrBrief,
|
|
1716
|
-
brief: reviewOrBrief,
|
|
1717
|
-
report,
|
|
1718
|
-
status,
|
|
1719
|
-
'cycles.list': collections,
|
|
1720
|
-
'cycles.show': collections,
|
|
1721
|
-
'cycles.resume': cycleMutation,
|
|
1722
|
-
'cycles.cancel': cycleMutation,
|
|
1723
|
-
'cycles.recover': cycleMutation,
|
|
1724
|
-
'cycles.close': cycleMutation,
|
|
1725
|
-
'findings.list': collections,
|
|
1726
|
-
'findings.show': collections,
|
|
1727
|
-
'findings.accept': findingMutation,
|
|
1728
|
-
'findings.reject': findingMutation,
|
|
1729
|
-
'findings.supersede': findingMutation,
|
|
1730
|
-
'routes.list': collections,
|
|
1731
|
-
'routes.show': collections,
|
|
1732
|
-
'routes.apply': routeMutation,
|
|
1733
|
-
'routes.rollback': routeMutation,
|
|
1734
|
-
'decisions.list': collections,
|
|
1735
|
-
'decisions.show': collections,
|
|
1736
|
-
'decisions.decide': answerMutation,
|
|
1737
|
-
'gaps.list': collections,
|
|
1738
|
-
'gaps.show': collections,
|
|
1739
|
-
'gaps.answer': answerMutation,
|
|
1740
|
-
'gaps.verify': answerMutation,
|
|
1741
|
-
'evidence.list': collections,
|
|
1742
|
-
'evidence.show': collections,
|
|
1743
|
-
'migrate.inspect': maintenance,
|
|
1744
|
-
'migrate.apply': maintenance,
|
|
1745
|
-
'migrations.list': collections,
|
|
1746
|
-
'migrations.show': collections,
|
|
1747
|
-
'migrations.rollback': maintenance,
|
|
1748
|
-
'cache.status': maintenance,
|
|
1749
|
-
'cache.purge': maintenance,
|
|
1750
|
-
'integrity.status': maintenance,
|
|
1751
|
-
'integrity.enable': maintenance,
|
|
1752
|
-
'diagnostics.export': maintenance,
|
|
1753
|
-
'security.repair': maintenance,
|
|
1754
|
-
'adapter.prepare': maintenance,
|
|
1755
|
-
'adapter.record': maintenance,
|
|
1756
|
-
'adapter.validate': maintenance,
|
|
1757
|
-
'adapter.resume': maintenance,
|
|
1758
|
-
'adapter.finalize': maintenance,
|
|
1759
|
-
'adapter.cancel': maintenance,
|
|
1760
|
-
'adapter.heartbeat': maintenance,
|
|
1761
|
-
'adapter.abandon': maintenance,
|
|
1762
|
-
'harness.prepare': maintenance,
|
|
1763
|
-
'harness.record': maintenance,
|
|
1764
|
-
'harness.validate': maintenance,
|
|
1765
|
-
'harness.resume': maintenance,
|
|
1766
|
-
'harness.finalize': maintenance,
|
|
1767
|
-
'harness.cancel': maintenance,
|
|
1768
|
-
'harness.heartbeat': maintenance,
|
|
1769
|
-
'harness.abandon': maintenance,
|
|
1770
|
-
'cycles.abandon-role': abandonStalledRole,
|
|
1771
|
-
};
|
|
1772
|
-
/**
|
|
1773
|
-
* Actions that only read committed state. A SPEC-002-layout project stays
|
|
1774
|
-
* readable through these without being migrated; only a mutating action opening
|
|
1775
|
-
* such a project triggers the automatic, journal-safe v1.3 migration (FR5/E-005).
|
|
1776
|
-
*
|
|
1777
|
-
* T-018: `profiles.migrate.inspect` is listed here — it previews the profile
|
|
1778
|
-
* migration without writing (FR10), so it must not reconcile the storage layout
|
|
1779
|
-
* as a side effect. Only the mutating `profiles.migrate.apply` is absent, so it
|
|
1780
|
-
* receives the guard the T-009 direct wiring skipped before it rewrites the
|
|
1781
|
-
* profile on a SPEC-002-layout project.
|
|
1782
|
-
*/
|
|
1783
|
-
const OPERATE_READ_ONLY_ACTIONS = new Set([
|
|
1784
|
-
'inspect',
|
|
1785
|
-
'demo',
|
|
1786
|
-
'config.show',
|
|
1787
|
-
'config.validate',
|
|
1788
|
-
'config.edit',
|
|
1789
|
-
'profiles.list',
|
|
1790
|
-
'profiles.show',
|
|
1791
|
-
'profiles.validate',
|
|
1792
|
-
'profiles.migrate.inspect',
|
|
1793
|
-
'context.show',
|
|
1794
|
-
'status',
|
|
1795
|
-
'review',
|
|
1796
|
-
'brief',
|
|
1797
|
-
'report',
|
|
1798
|
-
'cycles.list',
|
|
1799
|
-
'cycles.show',
|
|
1800
|
-
'findings.list',
|
|
1801
|
-
'findings.show',
|
|
1802
|
-
'routes.list',
|
|
1803
|
-
'routes.show',
|
|
1804
|
-
'decisions.list',
|
|
1805
|
-
'decisions.show',
|
|
1806
|
-
'gaps.list',
|
|
1807
|
-
'gaps.show',
|
|
1808
|
-
'evidence.list',
|
|
1809
|
-
'evidence.show',
|
|
1810
|
-
'migrate.inspect',
|
|
1811
|
-
'migrations.list',
|
|
1812
|
-
'migrations.show',
|
|
1813
|
-
'cache.status',
|
|
1814
|
-
'integrity.status',
|
|
1815
|
-
'adapter.resume',
|
|
1816
|
-
'harness.resume',
|
|
1817
|
-
// US-T1: the harness/adapter response dry-run reads the prepared session, takes
|
|
1818
|
-
// no lease, and mutates nothing — so it must not trigger the mutating-action
|
|
1819
|
-
// storage-layout migration on open.
|
|
1820
|
-
'adapter.validate',
|
|
1821
|
-
'harness.validate',
|
|
1822
|
-
]);
|
|
1823
|
-
/**
|
|
1824
|
-
* Stable runtime-neutral Operating Board facade. Public CLI adapters only parse
|
|
1825
|
-
* arguments and render this structured result; all state and security semantics
|
|
1826
|
-
* live behind this function.
|
|
1827
|
-
*/
|
|
1828
|
-
export async function executeOperateAction(request) {
|
|
1829
|
-
try {
|
|
1830
|
-
const handler = HANDLERS[request.action];
|
|
1831
|
-
if (!handler) {
|
|
1832
|
-
throw new OperateError('E_OPERATE_ACTION_UNKNOWN', `Unknown Operating Board action: ${request.action}.`);
|
|
1833
|
-
}
|
|
1834
|
-
// Any mutating action that opens a SPEC-002-layout project migrates it to the
|
|
1835
|
-
// v1.3 storage layout, through the write-ahead journal, before proceeding.
|
|
1836
|
-
if (!OPERATE_READ_ONLY_ACTIONS.has(request.action)) {
|
|
1837
|
-
await migrateOperatingStorageLayoutOnOpen(request.projectRoot, {
|
|
1838
|
-
localRoot: option(request, 'localRoot', undefined),
|
|
1839
|
-
});
|
|
1840
|
-
}
|
|
1841
|
-
return await attachStructuredActions(request, await handler(request));
|
|
1842
|
-
}
|
|
1843
|
-
catch (error) {
|
|
1844
|
-
// FR7/E-007: first-use provider consent is a healthy continuation, not a
|
|
1845
|
-
// failure — return the `ok: true` handoff shape instead of an exit-4 error.
|
|
1846
|
-
// Every other authority/error stays a genuine failure.
|
|
1847
|
-
if (isProviderConsentHandoff(error)) {
|
|
1848
|
-
const continuation = providerConsentContinuation(request.action, error);
|
|
1849
|
-
try {
|
|
1850
|
-
return await attachStructuredActions(request, continuation);
|
|
1851
|
-
}
|
|
1852
|
-
catch {
|
|
1853
|
-
return continuation;
|
|
1854
|
-
}
|
|
1855
|
-
}
|
|
1856
|
-
try {
|
|
1857
|
-
return await attachStructuredActions(request, failure(request.action, error));
|
|
1858
|
-
}
|
|
1859
|
-
catch {
|
|
1860
|
-
return failure(request.action, error);
|
|
1861
|
-
}
|
|
1862
|
-
}
|
|
1863
|
-
}
|
|
1864
|
-
//# sourceMappingURL=index.js.map
|