wicked-crew 0.18.20 → 0.18.22
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/dist/api/audit.d.ts +28 -1
- package/dist/api/audit.d.ts.map +1 -1
- package/dist/api/audit.js +90 -9
- package/dist/api/audit.js.map +1 -1
- package/dist/api/auth.d.ts +7 -0
- package/dist/api/auth.d.ts.map +1 -1
- package/dist/api/auth.js +53 -10
- package/dist/api/auth.js.map +1 -1
- package/dist/api/capture.d.ts +16 -4
- package/dist/api/capture.d.ts.map +1 -1
- package/dist/api/capture.js +20 -12
- package/dist/api/capture.js.map +1 -1
- package/dist/api/chat-context.d.ts +17 -0
- package/dist/api/chat-context.d.ts.map +1 -1
- package/dist/api/chat-context.js +94 -5
- package/dist/api/chat-context.js.map +1 -1
- package/dist/api/chat-freshness.js +2 -2
- package/dist/api/chat-freshness.js.map +1 -1
- package/dist/api/chat-jobs.d.ts +54 -0
- package/dist/api/chat-jobs.d.ts.map +1 -1
- package/dist/api/chat-jobs.js +199 -7
- package/dist/api/chat-jobs.js.map +1 -1
- package/dist/api/chat-proposals.d.ts +62 -12
- package/dist/api/chat-proposals.d.ts.map +1 -1
- package/dist/api/chat-proposals.js +257 -52
- package/dist/api/chat-proposals.js.map +1 -1
- package/dist/api/chat-requirements.d.ts.map +1 -1
- package/dist/api/chat-requirements.js +4 -1
- package/dist/api/chat-requirements.js.map +1 -1
- package/dist/api/chat-scope.d.ts +12 -0
- package/dist/api/chat-scope.d.ts.map +1 -1
- package/dist/api/chat-scope.js +35 -5
- package/dist/api/chat-scope.js.map +1 -1
- package/dist/api/cluster-status.d.ts +41 -12
- package/dist/api/cluster-status.d.ts.map +1 -1
- package/dist/api/cluster-status.js +148 -3
- package/dist/api/cluster-status.js.map +1 -1
- package/dist/api/codebase-archive.js +2 -2
- package/dist/api/codebase-archive.js.map +1 -1
- package/dist/api/compose-facts.d.ts +35 -0
- package/dist/api/compose-facts.d.ts.map +1 -0
- package/dist/api/compose-facts.js +46 -0
- package/dist/api/compose-facts.js.map +1 -0
- package/dist/api/cut-read.d.ts +62 -0
- package/dist/api/cut-read.d.ts.map +1 -0
- package/dist/api/cut-read.js +101 -0
- package/dist/api/cut-read.js.map +1 -0
- package/dist/api/delivery-cache.d.ts +2 -0
- package/dist/api/delivery-cache.d.ts.map +1 -1
- package/dist/api/delivery-cache.js +1 -2
- package/dist/api/delivery-cache.js.map +1 -1
- package/dist/api/delivery-index.d.ts +2 -2
- package/dist/api/delivery-index.d.ts.map +1 -1
- package/dist/api/delivery-index.js +1 -2
- package/dist/api/delivery-index.js.map +1 -1
- package/dist/api/desk-snoozes.d.ts +54 -0
- package/dist/api/desk-snoozes.d.ts.map +1 -0
- package/dist/api/desk-snoozes.js +174 -0
- package/dist/api/desk-snoozes.js.map +1 -0
- package/dist/api/diagnostics.d.ts +4 -0
- package/dist/api/diagnostics.d.ts.map +1 -1
- package/dist/api/diagnostics.js +15 -7
- package/dist/api/diagnostics.js.map +1 -1
- package/dist/api/disk-stores.d.ts +66 -0
- package/dist/api/disk-stores.d.ts.map +1 -0
- package/dist/api/disk-stores.js +206 -0
- package/dist/api/disk-stores.js.map +1 -0
- package/dist/api/eval-compare.d.ts +1 -1
- package/dist/api/eval-compare.js +1 -1
- package/dist/api/eval-sample.d.ts +7 -0
- package/dist/api/eval-sample.d.ts.map +1 -1
- package/dist/api/eval-sample.js +20 -0
- package/dist/api/eval-sample.js.map +1 -1
- package/dist/api/gate-cache.d.ts +8 -0
- package/dist/api/gate-cache.d.ts.map +1 -1
- package/dist/api/gate-cache.js +8 -1
- package/dist/api/gate-cache.js.map +1 -1
- package/dist/api/governance-steering.d.ts +13 -0
- package/dist/api/governance-steering.d.ts.map +1 -1
- package/dist/api/governance-steering.js +56 -7
- package/dist/api/governance-steering.js.map +1 -1
- package/dist/api/mcp.d.ts +19 -1
- package/dist/api/mcp.d.ts.map +1 -1
- package/dist/api/mcp.js +123 -3
- package/dist/api/mcp.js.map +1 -1
- package/dist/api/needs.d.ts +23 -0
- package/dist/api/needs.d.ts.map +1 -1
- package/dist/api/needs.js +124 -19
- package/dist/api/needs.js.map +1 -1
- package/dist/api/onboarding-capture.d.ts +21 -1
- package/dist/api/onboarding-capture.d.ts.map +1 -1
- package/dist/api/onboarding-capture.js +112 -8
- package/dist/api/onboarding-capture.js.map +1 -1
- package/dist/api/policy-landing.d.ts +36 -0
- package/dist/api/policy-landing.d.ts.map +1 -1
- package/dist/api/policy-landing.js +123 -4
- package/dist/api/policy-landing.js.map +1 -1
- package/dist/api/post-hoc-deliver.d.ts +7 -0
- package/dist/api/post-hoc-deliver.d.ts.map +1 -1
- package/dist/api/post-hoc-deliver.js +17 -5
- package/dist/api/post-hoc-deliver.js.map +1 -1
- package/dist/api/product-publish.d.ts +242 -0
- package/dist/api/product-publish.d.ts.map +1 -0
- package/dist/api/product-publish.js +902 -0
- package/dist/api/product-publish.js.map +1 -0
- package/dist/api/product.d.ts +5 -6
- package/dist/api/product.d.ts.map +1 -1
- package/dist/api/product.js +4 -4
- package/dist/api/product.js.map +1 -1
- package/dist/api/proposal-cut.d.ts +95 -0
- package/dist/api/proposal-cut.d.ts.map +1 -0
- package/dist/api/proposal-cut.js +231 -0
- package/dist/api/proposal-cut.js.map +1 -0
- package/dist/api/proposal-decisions.d.ts +44 -0
- package/dist/api/proposal-decisions.d.ts.map +1 -0
- package/dist/api/proposal-decisions.js +85 -0
- package/dist/api/proposal-decisions.js.map +1 -0
- package/dist/api/proposal-onboard.d.ts +29 -0
- package/dist/api/proposal-onboard.d.ts.map +1 -1
- package/dist/api/proposal-onboard.js +162 -11
- package/dist/api/proposal-onboard.js.map +1 -1
- package/dist/api/recording.d.ts.map +1 -1
- package/dist/api/recording.js +4 -5
- package/dist/api/recording.js.map +1 -1
- package/dist/api/redeliver.d.ts.map +1 -1
- package/dist/api/redeliver.js +11 -7
- package/dist/api/redeliver.js.map +1 -1
- package/dist/api/repo-input.d.ts.map +1 -1
- package/dist/api/repo-input.js +5 -2
- package/dist/api/repo-input.js.map +1 -1
- package/dist/api/repo-origins.d.ts +24 -0
- package/dist/api/repo-origins.d.ts.map +1 -0
- package/dist/api/repo-origins.js +71 -0
- package/dist/api/repo-origins.js.map +1 -0
- package/dist/api/requirements.d.ts +39 -4
- package/dist/api/requirements.d.ts.map +1 -1
- package/dist/api/requirements.js +76 -5
- package/dist/api/requirements.js.map +1 -1
- package/dist/api/review-change.d.ts +5 -6
- package/dist/api/review-change.d.ts.map +1 -1
- package/dist/api/review-change.js +45 -8
- package/dist/api/review-change.js.map +1 -1
- package/dist/api/routes.d.ts +48 -4
- package/dist/api/routes.d.ts.map +1 -1
- package/dist/api/routes.js +926 -268
- package/dist/api/routes.js.map +1 -1
- package/dist/api/run-liveness.d.ts.map +1 -1
- package/dist/api/run-liveness.js +3 -1
- package/dist/api/run-liveness.js.map +1 -1
- package/dist/api/run-sources.d.ts +11 -1
- package/dist/api/run-sources.d.ts.map +1 -1
- package/dist/api/run-sources.js +26 -3
- package/dist/api/run-sources.js.map +1 -1
- package/dist/api/run-timing-index.d.ts +56 -1
- package/dist/api/run-timing-index.d.ts.map +1 -1
- package/dist/api/run-timing-index.js +164 -10
- package/dist/api/run-timing-index.js.map +1 -1
- package/dist/api/runtime-state.d.ts +6 -0
- package/dist/api/runtime-state.d.ts.map +1 -1
- package/dist/api/runtime-state.js +14 -3
- package/dist/api/runtime-state.js.map +1 -1
- package/dist/api/seat-agents.d.ts.map +1 -1
- package/dist/api/seat-agents.js +3 -3
- package/dist/api/seat-agents.js.map +1 -1
- package/dist/api/seat-container-login.d.ts +17 -19
- package/dist/api/seat-container-login.d.ts.map +1 -1
- package/dist/api/seat-container-login.js +51 -76
- package/dist/api/seat-container-login.js.map +1 -1
- package/dist/api/seat-governance.d.ts +3 -2
- package/dist/api/seat-governance.d.ts.map +1 -1
- package/dist/api/seat-governance.js +31 -9
- package/dist/api/seat-governance.js.map +1 -1
- package/dist/api/seat-standing.d.ts +8 -0
- package/dist/api/seat-standing.d.ts.map +1 -1
- package/dist/api/seat-standing.js +26 -1
- package/dist/api/seat-standing.js.map +1 -1
- package/dist/api/server.d.ts +7 -0
- package/dist/api/server.d.ts.map +1 -1
- package/dist/api/server.js +93 -39
- package/dist/api/server.js.map +1 -1
- package/dist/api/start-on-login.d.ts +4 -0
- package/dist/api/start-on-login.d.ts.map +1 -0
- package/dist/api/start-on-login.js +35 -0
- package/dist/api/start-on-login.js.map +1 -0
- package/dist/api/steering-landing.d.ts +33 -8
- package/dist/api/steering-landing.d.ts.map +1 -1
- package/dist/api/steering-landing.js +235 -51
- package/dist/api/steering-landing.js.map +1 -1
- package/dist/api/system-snapshot.d.ts +2 -1
- package/dist/api/system-snapshot.d.ts.map +1 -1
- package/dist/api/system-snapshot.js +22 -9
- package/dist/api/system-snapshot.js.map +1 -1
- package/dist/api/ui-text.d.ts.map +1 -1
- package/dist/api/ui-text.js +3 -1
- package/dist/api/ui-text.js.map +1 -1
- package/dist/api/worktree-sweep.d.ts +7 -3
- package/dist/api/worktree-sweep.d.ts.map +1 -1
- package/dist/api/worktree-sweep.js +10 -6
- package/dist/api/worktree-sweep.js.map +1 -1
- package/dist/apps/exec/recall.d.ts.map +1 -1
- package/dist/apps/exec/recall.js +4 -4
- package/dist/apps/exec/recall.js.map +1 -1
- package/dist/apps/git.js +2 -2
- package/dist/apps/git.js.map +1 -1
- package/dist/apps/publish/manifest.d.ts +2 -0
- package/dist/apps/publish/manifest.d.ts.map +1 -1
- package/dist/apps/publish/manifest.js +8 -3
- package/dist/apps/publish/manifest.js.map +1 -1
- package/dist/apps/publish/run.d.ts +11 -1
- package/dist/apps/publish/run.d.ts.map +1 -1
- package/dist/apps/publish/run.js +97 -17
- package/dist/apps/publish/run.js.map +1 -1
- package/dist/apps/routes.d.ts +2 -0
- package/dist/apps/routes.d.ts.map +1 -1
- package/dist/apps/routes.js +45 -2
- package/dist/apps/routes.js.map +1 -1
- package/dist/apps/store.d.ts +35 -3
- package/dist/apps/store.d.ts.map +1 -1
- package/dist/apps/store.js +73 -9
- package/dist/apps/store.js.map +1 -1
- package/dist/apps/turns.d.ts +25 -2
- package/dist/apps/turns.d.ts.map +1 -1
- package/dist/apps/turns.js +276 -11
- package/dist/apps/turns.js.map +1 -1
- package/dist/apps-server/runners/sqlite-runner.mjs +39 -1
- package/dist/apps-server/server/lib/bundle/server.mjs +124 -14
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +27 -52
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/start-stand-ins.d.ts +13 -0
- package/dist/cli/start-stand-ins.d.ts.map +1 -0
- package/dist/cli/start-stand-ins.js +30 -0
- package/dist/cli/start-stand-ins.js.map +1 -0
- package/dist/core/adapter.d.ts +66 -14
- package/dist/core/adapter.d.ts.map +1 -1
- package/dist/core/adapter.js +228 -56
- package/dist/core/adapter.js.map +1 -1
- package/dist/core/ado-deliver-helper.d.ts +2 -1
- package/dist/core/ado-deliver-helper.d.ts.map +1 -1
- package/dist/core/ado-deliver-helper.js +26 -1
- package/dist/core/ado-deliver-helper.js.map +1 -1
- package/dist/core/ado-env.d.ts +17 -0
- package/dist/core/ado-env.d.ts.map +1 -0
- package/dist/core/ado-env.js +34 -0
- package/dist/core/ado-env.js.map +1 -0
- package/dist/core/assurance.d.ts +10 -0
- package/dist/core/assurance.d.ts.map +1 -1
- package/dist/core/assurance.js +23 -0
- package/dist/core/assurance.js.map +1 -1
- package/dist/core/deliver-text.d.ts +19 -0
- package/dist/core/deliver-text.d.ts.map +1 -1
- package/dist/core/deliver-text.js +77 -1
- package/dist/core/deliver-text.js.map +1 -1
- package/dist/core/deliver.d.ts +49 -1
- package/dist/core/deliver.d.ts.map +1 -1
- package/dist/core/deliver.js +142 -6
- package/dist/core/deliver.js.map +1 -1
- package/dist/core/estate-mcp-client.d.ts.map +1 -1
- package/dist/core/estate-mcp-client.js +4 -8
- package/dist/core/estate-mcp-client.js.map +1 -1
- package/dist/core/exec.d.ts +16 -1
- package/dist/core/exec.d.ts.map +1 -1
- package/dist/core/exec.js +32 -2
- package/dist/core/exec.js.map +1 -1
- package/dist/core/governance-store.d.ts +3 -1
- package/dist/core/governance-store.d.ts.map +1 -1
- package/dist/core/governance-store.js +7 -2
- package/dist/core/governance-store.js.map +1 -1
- package/dist/core/linked-issues.d.ts +13 -2
- package/dist/core/linked-issues.d.ts.map +1 -1
- package/dist/core/linked-issues.js +135 -4
- package/dist/core/linked-issues.js.map +1 -1
- package/dist/core/redeliver.js +2 -2
- package/dist/core/redeliver.js.map +1 -1
- package/dist/core/repo-clone.d.ts +64 -0
- package/dist/core/repo-clone.d.ts.map +1 -0
- package/dist/core/repo-clone.js +307 -0
- package/dist/core/repo-clone.js.map +1 -0
- package/dist/core/run-identity.d.ts.map +1 -1
- package/dist/core/run-identity.js +3 -0
- package/dist/core/run-identity.js.map +1 -1
- package/dist/core/run-log-facts.d.ts +56 -0
- package/dist/core/run-log-facts.d.ts.map +1 -0
- package/dist/core/run-log-facts.js +230 -0
- package/dist/core/run-log-facts.js.map +1 -0
- package/dist/core/run-read-lane.d.ts +30 -0
- package/dist/core/run-read-lane.d.ts.map +1 -0
- package/dist/core/run-read-lane.js +103 -0
- package/dist/core/run-read-lane.js.map +1 -0
- package/dist/core/shutdown.d.ts +27 -0
- package/dist/core/shutdown.d.ts.map +1 -1
- package/dist/core/shutdown.js +72 -0
- package/dist/core/shutdown.js.map +1 -1
- package/dist/core/stand-in.d.ts +40 -0
- package/dist/core/stand-in.d.ts.map +1 -0
- package/dist/core/stand-in.js +118 -0
- package/dist/core/stand-in.js.map +1 -0
- package/dist/core/types.d.ts +27 -0
- package/dist/core/types.d.ts.map +1 -1
- package/dist/core/types.js.map +1 -1
- package/dist/core/walkthrough-root.d.ts.map +1 -1
- package/dist/core/walkthrough-root.js +3 -5
- package/dist/core/walkthrough-root.js.map +1 -1
- package/dist/core/wicked-home.d.ts +9 -0
- package/dist/core/wicked-home.d.ts.map +1 -0
- package/dist/core/wicked-home.js +25 -0
- package/dist/core/wicked-home.js.map +1 -0
- package/dist/decisions/consider.d.ts +2 -1
- package/dist/decisions/consider.d.ts.map +1 -1
- package/dist/decisions/consider.js +2 -2
- package/dist/decisions/consider.js.map +1 -1
- package/dist/decisions/land.d.ts +2 -0
- package/dist/decisions/land.d.ts.map +1 -1
- package/dist/decisions/land.js +16 -3
- package/dist/decisions/land.js.map +1 -1
- package/dist/decisions/rules-brief.d.ts +2 -1
- package/dist/decisions/rules-brief.d.ts.map +1 -1
- package/dist/decisions/rules-brief.js +3 -2
- package/dist/decisions/rules-brief.js.map +1 -1
- package/dist/editors/conformance-runtime.d.ts +0 -2
- package/dist/editors/conformance-runtime.d.ts.map +1 -1
- package/dist/editors/conformance-runtime.js +0 -4
- package/dist/editors/conformance-runtime.js.map +1 -1
- package/dist/editors/pack-extras.d.ts +162 -0
- package/dist/editors/pack-extras.d.ts.map +1 -0
- package/dist/editors/pack-extras.js +596 -0
- package/dist/editors/pack-extras.js.map +1 -0
- package/dist/editors/pack-install.d.ts +26 -22
- package/dist/editors/pack-install.d.ts.map +1 -1
- package/dist/editors/pack-install.js +187 -80
- package/dist/editors/pack-install.js.map +1 -1
- package/dist/editors/registry.d.ts +66 -13
- package/dist/editors/registry.d.ts.map +1 -1
- package/dist/editors/registry.js +147 -24
- package/dist/editors/registry.js.map +1 -1
- package/dist/editors/routes.d.ts +10 -5
- package/dist/editors/routes.d.ts.map +1 -1
- package/dist/editors/routes.js +45 -11
- package/dist/editors/routes.js.map +1 -1
- package/dist/editors/visuals.d.ts +4 -3
- package/dist/editors/visuals.d.ts.map +1 -1
- package/dist/editors/visuals.js +17 -7
- package/dist/editors/visuals.js.map +1 -1
- package/dist/evals/runner.js +1 -1
- package/dist/evals/runner.js.map +1 -1
- package/dist/evals/shape.d.ts +7 -1
- package/dist/evals/shape.d.ts.map +1 -1
- package/dist/evals/shape.js +26 -6
- package/dist/evals/shape.js.map +1 -1
- package/dist/evals/workflow.d.ts +16 -3
- package/dist/evals/workflow.d.ts.map +1 -1
- package/dist/evals/workflow.js +31 -6
- package/dist/evals/workflow.js.map +1 -1
- package/dist/insights/review-service.d.ts +24 -3
- package/dist/insights/review-service.d.ts.map +1 -1
- package/dist/insights/review-service.js +75 -12
- package/dist/insights/review-service.js.map +1 -1
- package/dist/insights/routes.d.ts +2 -1
- package/dist/insights/routes.d.ts.map +1 -1
- package/dist/insights/routes.js +19 -4
- package/dist/insights/routes.js.map +1 -1
- package/dist/insights/run-facts.d.ts +5 -0
- package/dist/insights/run-facts.d.ts.map +1 -1
- package/dist/insights/run-facts.js +15 -0
- package/dist/insights/run-facts.js.map +1 -1
- package/dist/insights/workflow.d.ts +2 -1
- package/dist/insights/workflow.d.ts.map +1 -1
- package/dist/insights/workflow.js +4 -4
- package/dist/insights/workflow.js.map +1 -1
- package/dist/inspect/service.d.ts +3 -2
- package/dist/inspect/service.d.ts.map +1 -1
- package/dist/inspect/service.js +4 -4
- package/dist/inspect/service.js.map +1 -1
- package/dist/interactive/bridge-pool.d.ts +5 -2
- package/dist/interactive/bridge-pool.d.ts.map +1 -1
- package/dist/interactive/bridge-pool.js +10 -5
- package/dist/interactive/bridge-pool.js.map +1 -1
- package/dist/interactive/chat-events.d.ts.map +1 -1
- package/dist/interactive/chat-events.js +7 -1
- package/dist/interactive/chat-events.js.map +1 -1
- package/dist/interactive/draft-events.d.ts +3 -0
- package/dist/interactive/draft-events.d.ts.map +1 -1
- package/dist/interactive/draft-events.js +5 -8
- package/dist/interactive/draft-events.js.map +1 -1
- package/dist/interactive/draft-skill.d.ts +56 -3
- package/dist/interactive/draft-skill.d.ts.map +1 -1
- package/dist/interactive/draft-skill.js +129 -20
- package/dist/interactive/draft-skill.js.map +1 -1
- package/dist/interactive/landing-guard.d.ts +30 -5
- package/dist/interactive/landing-guard.d.ts.map +1 -1
- package/dist/interactive/landing-guard.js +196 -6
- package/dist/interactive/landing-guard.js.map +1 -1
- package/dist/interactive/proposal-create.d.ts.map +1 -1
- package/dist/interactive/proposal-create.js +1 -0
- package/dist/interactive/proposal-create.js.map +1 -1
- package/dist/interactive/proposal-refine.d.ts.map +1 -1
- package/dist/interactive/proposal-refine.js +16 -1
- package/dist/interactive/proposal-refine.js.map +1 -1
- package/dist/interactive/review-events.js +1 -1
- package/dist/interactive/review-events.js.map +1 -1
- package/dist/interactive/run-units.d.ts.map +1 -1
- package/dist/interactive/run-units.js +3 -2
- package/dist/interactive/run-units.js.map +1 -1
- package/dist/interactive/source-packet.d.ts +8 -0
- package/dist/interactive/source-packet.d.ts.map +1 -1
- package/dist/interactive/source-packet.js +47 -6
- package/dist/interactive/source-packet.js.map +1 -1
- package/dist/knowledge/adapters/toolbox/memory.d.ts.map +1 -1
- package/dist/knowledge/adapters/toolbox/memory.js +3 -2
- package/dist/knowledge/adapters/toolbox/memory.js.map +1 -1
- package/dist/knowledge/adapters/toolbox/supervisor.d.ts +21 -1
- package/dist/knowledge/adapters/toolbox/supervisor.d.ts.map +1 -1
- package/dist/knowledge/adapters/toolbox/supervisor.js +76 -26
- package/dist/knowledge/adapters/toolbox/supervisor.js.map +1 -1
- package/dist/knowledge/estate-write.d.ts +5 -0
- package/dist/knowledge/estate-write.d.ts.map +1 -1
- package/dist/knowledge/estate-write.js +7 -0
- package/dist/knowledge/estate-write.js.map +1 -1
- package/dist/knowledge/projector.d.ts +60 -5
- package/dist/knowledge/projector.d.ts.map +1 -1
- package/dist/knowledge/projector.js +264 -21
- package/dist/knowledge/projector.js.map +1 -1
- package/dist/knowledge/shapes/map.d.ts.map +1 -1
- package/dist/knowledge/shapes/map.js +12 -2
- package/dist/knowledge/shapes/map.js.map +1 -1
- package/dist/knowledge/shapes/routes.d.ts +1 -1
- package/dist/knowledge/shapes/routes.d.ts.map +1 -1
- package/dist/knowledge/shapes/routes.js +42 -16
- package/dist/knowledge/shapes/routes.js.map +1 -1
- package/dist/knowledge/shapes/shapes.d.ts +60 -13
- package/dist/knowledge/shapes/shapes.d.ts.map +1 -1
- package/dist/knowledge/shapes/shapes.js +199 -31
- package/dist/knowledge/shapes/shapes.js.map +1 -1
- package/dist/knowledge/shapes/verified.d.ts.map +1 -1
- package/dist/knowledge/shapes/verified.js +3 -2
- package/dist/knowledge/shapes/verified.js.map +1 -1
- package/dist/knowledge/trackers/addresses.d.ts +27 -3
- package/dist/knowledge/trackers/addresses.d.ts.map +1 -1
- package/dist/knowledge/trackers/addresses.js +33 -5
- package/dist/knowledge/trackers/addresses.js.map +1 -1
- package/dist/knowledge/trackers/gate-pm.d.ts.map +1 -1
- package/dist/knowledge/trackers/gate-pm.js +4 -2
- package/dist/knowledge/trackers/gate-pm.js.map +1 -1
- package/dist/knowledge/trackers/projector.d.ts +3 -1
- package/dist/knowledge/trackers/projector.d.ts.map +1 -1
- package/dist/knowledge/trackers/projector.js +59 -8
- package/dist/knowledge/trackers/projector.js.map +1 -1
- package/dist/knowledge/trackers/set.d.ts +28 -0
- package/dist/knowledge/trackers/set.d.ts.map +1 -1
- package/dist/knowledge/trackers/set.js +26 -0
- package/dist/knowledge/trackers/set.js.map +1 -1
- package/dist/learn/scheduler.d.ts.map +1 -1
- package/dist/learn/scheduler.js +11 -2
- package/dist/learn/scheduler.js.map +1 -1
- package/dist/learnings/extract.d.ts +9 -3
- package/dist/learnings/extract.d.ts.map +1 -1
- package/dist/learnings/extract.js +62 -4
- package/dist/learnings/extract.js.map +1 -1
- package/dist/learnings/replacement-lineage.d.ts +3 -2
- package/dist/learnings/replacement-lineage.d.ts.map +1 -1
- package/dist/learnings/replacement-lineage.js +7 -6
- package/dist/learnings/replacement-lineage.js.map +1 -1
- package/dist/learnings/service.d.ts +12 -2
- package/dist/learnings/service.d.ts.map +1 -1
- package/dist/learnings/service.js +30 -5
- package/dist/learnings/service.js.map +1 -1
- package/dist/mcp/broker.d.ts.map +1 -1
- package/dist/mcp/broker.js +18 -4
- package/dist/mcp/broker.js.map +1 -1
- package/dist/mcp/estate-relay.d.ts +3 -0
- package/dist/mcp/estate-relay.d.ts.map +1 -1
- package/dist/mcp/estate-relay.js +5 -2
- package/dist/mcp/estate-relay.js.map +1 -1
- package/dist/mcp/invoke.js +2 -2
- package/dist/mcp/invoke.js.map +1 -1
- package/dist/mcp/policies.d.ts +35 -0
- package/dist/mcp/policies.d.ts.map +1 -1
- package/dist/mcp/policies.js +138 -1
- package/dist/mcp/policies.js.map +1 -1
- package/dist/mcp/redact.d.ts +1 -1
- package/dist/mcp/redact.d.ts.map +1 -1
- package/dist/mcp/redact.js +61 -4
- package/dist/mcp/redact.js.map +1 -1
- package/dist/mcp/registry-store.d.ts +35 -0
- package/dist/mcp/registry-store.d.ts.map +1 -1
- package/dist/mcp/registry-store.js +33 -0
- package/dist/mcp/registry-store.js.map +1 -1
- package/dist/mcp/registry.d.ts +65 -4
- package/dist/mcp/registry.d.ts.map +1 -1
- package/dist/mcp/registry.js +295 -21
- package/dist/mcp/registry.js.map +1 -1
- package/dist/mcp/rest.js +3 -3
- package/dist/mcp/rest.js.map +1 -1
- package/dist/mcp/run-fence.d.ts +2 -0
- package/dist/mcp/run-fence.d.ts.map +1 -1
- package/dist/mcp/run-fence.js +9 -0
- package/dist/mcp/run-fence.js.map +1 -1
- package/dist/mcp/trigger-names.d.ts +32 -0
- package/dist/mcp/trigger-names.d.ts.map +1 -0
- package/dist/mcp/trigger-names.js +529 -0
- package/dist/mcp/trigger-names.js.map +1 -0
- package/dist/mcp/upstream-error.d.ts +5 -1
- package/dist/mcp/upstream-error.d.ts.map +1 -1
- package/dist/mcp/upstream-error.js +5 -1
- package/dist/mcp/upstream-error.js.map +1 -1
- package/dist/projects/graph.d.ts +6 -4
- package/dist/projects/graph.d.ts.map +1 -1
- package/dist/projects/graph.js +173 -25
- package/dist/projects/graph.js.map +1 -1
- package/dist/projects/routes.d.ts +7 -1
- package/dist/projects/routes.d.ts.map +1 -1
- package/dist/projects/routes.js +13 -5
- package/dist/projects/routes.js.map +1 -1
- package/dist/projects/state-home-preflight.d.ts +5 -0
- package/dist/projects/state-home-preflight.d.ts.map +1 -1
- package/dist/projects/state-home-preflight.js +48 -8
- package/dist/projects/state-home-preflight.js.map +1 -1
- package/dist/projects/state-home-registry.d.ts.map +1 -1
- package/dist/projects/state-home-registry.js +6 -0
- package/dist/projects/state-home-registry.js.map +1 -1
- package/dist/projects/state-home.d.ts +6 -2
- package/dist/projects/state-home.d.ts.map +1 -1
- package/dist/projects/state-home.js +8 -5
- package/dist/projects/state-home.js.map +1 -1
- package/dist/qe/test-sets.d.ts +1 -1
- package/dist/qe/test-sets.d.ts.map +1 -1
- package/dist/qe/test-sets.js +2 -2
- package/dist/qe/test-sets.js.map +1 -1
- package/dist/schedules/routes.d.ts +5 -0
- package/dist/schedules/routes.d.ts.map +1 -1
- package/dist/schedules/routes.js +32 -5
- package/dist/schedules/routes.js.map +1 -1
- package/dist/schedules/scheduler.d.ts +8 -1
- package/dist/schedules/scheduler.d.ts.map +1 -1
- package/dist/schedules/scheduler.js +10 -1
- package/dist/schedules/scheduler.js.map +1 -1
- package/dist/schedules/store.d.ts +7 -0
- package/dist/schedules/store.d.ts.map +1 -1
- package/dist/schedules/store.js +19 -4
- package/dist/schedules/store.js.map +1 -1
- package/dist/skills/plugin-source.js +4 -4
- package/dist/skills/plugin-source.js.map +1 -1
- package/dist/skills/store.d.ts +11 -1
- package/dist/skills/store.d.ts.map +1 -1
- package/dist/skills/store.js +37 -3
- package/dist/skills/store.js.map +1 -1
- package/dist/sources/drivers/sqlite.d.ts +13 -0
- package/dist/sources/drivers/sqlite.d.ts.map +1 -1
- package/dist/sources/drivers/sqlite.js +11 -0
- package/dist/sources/drivers/sqlite.js.map +1 -1
- package/dist/sources/routes.d.ts.map +1 -1
- package/dist/sources/routes.js +1 -0
- package/dist/sources/routes.js.map +1 -1
- package/dist/sources/uploads.d.ts +22 -2
- package/dist/sources/uploads.d.ts.map +1 -1
- package/dist/sources/uploads.js +108 -10
- package/dist/sources/uploads.js.map +1 -1
- package/dist/standing-orders/parse.d.ts +8 -0
- package/dist/standing-orders/parse.d.ts.map +1 -1
- package/dist/standing-orders/parse.js +52 -5
- package/dist/standing-orders/parse.js.map +1 -1
- package/dist/studio/apps-standalone/fixture.js +3 -3
- package/dist/studio/assets/{KnowledgeGraph-dfq7Flyj.js → KnowledgeGraph-D6RRLDnV.js} +1 -1
- package/dist/studio/assets/index-BLo9vFQI.js +1128 -0
- package/dist/studio/assets/index-xW21Gkam.css +32 -0
- package/dist/studio/editors/wicked-apps/editor.json +1 -1
- package/dist/studio/editors/wicked-apps/index.html +1 -1
- package/dist/studio/editors/wicked-deck/editor.json +1 -1
- package/dist/studio/editors/wicked-deck/index.html +1 -1
- package/dist/studio/editors/wicked-doc/editor.json +1 -1
- package/dist/studio/editors/wicked-doc/index.html +1 -1
- package/dist/studio/editors/wicked-insights/editor.json +1 -1
- package/dist/studio/editors/wicked-insights/index.html +1 -1
- package/dist/studio/editors/wicked-page/editor.json +1 -1
- package/dist/studio/editors/wicked-page/index.html +1 -1
- package/dist/studio/editors/wicked-video/editor.json +1 -1
- package/dist/studio/editors/wicked-video/index.html +1 -1
- package/dist/studio/index.html +2 -2
- package/dist/studio/testid-inventory.json +1687 -236
- package/dist/team/routes.d.ts +4 -1
- package/dist/team/routes.d.ts.map +1 -1
- package/dist/team/routes.js +3 -2
- package/dist/team/routes.js.map +1 -1
- package/dist/voice/tts.d.ts +18 -0
- package/dist/voice/tts.d.ts.map +1 -1
- package/dist/voice/tts.js +134 -29
- package/dist/voice/tts.js.map +1 -1
- package/dist/workflow-catalog/build-v2.d.ts +34 -0
- package/dist/workflow-catalog/build-v2.d.ts.map +1 -1
- package/dist/workflow-catalog/build-v2.js +131 -10
- package/dist/workflow-catalog/build-v2.js.map +1 -1
- package/dist/workflow-catalog/catalog-data.d.ts.map +1 -1
- package/dist/workflow-catalog/catalog-data.js +0 -2
- package/dist/workflow-catalog/catalog-data.js.map +1 -1
- package/dist/workflow-catalog/detect.d.ts +18 -3
- package/dist/workflow-catalog/detect.d.ts.map +1 -1
- package/dist/workflow-catalog/detect.js +43 -8
- package/dist/workflow-catalog/detect.js.map +1 -1
- package/dist/working-doc/event-lines.d.ts +5 -2
- package/dist/working-doc/event-lines.d.ts.map +1 -1
- package/dist/working-doc/event-lines.js +38 -7
- package/dist/working-doc/event-lines.js.map +1 -1
- package/dist/working-doc/sections.d.ts +3 -0
- package/dist/working-doc/sections.d.ts.map +1 -1
- package/dist/working-doc/sections.js +5 -0
- package/dist/working-doc/sections.js.map +1 -1
- package/dist/working-doc/service.d.ts +23 -3
- package/dist/working-doc/service.d.ts.map +1 -1
- package/dist/working-doc/service.js +93 -54
- package/dist/working-doc/service.js.map +1 -1
- package/endpoint-manifest.json +144 -8
- package/evals/corpora/shape-v1.json +25 -1
- package/evals/corpora/shape-v1.seat-fixture.json +25 -1
- package/package.json +4 -4
- package/runners/sqlite-runner.mjs +39 -1
- package/voice-locks/darwin-arm64-cp310.txt +12 -0
- package/voice-locks/darwin-arm64-cp311.txt +8 -0
- package/voice-locks/darwin-arm64-cp312.txt +8 -0
- package/voice-locks/darwin-arm64-cp313.txt +8 -0
- package/voice-locks/darwin-arm64-cp314.txt +8 -0
- package/voice-locks/darwin-arm64-cp39.txt +12 -0
- package/voice-locks/darwin-x64-cp310.txt +12 -0
- package/voice-locks/darwin-x64-cp311.txt +12 -0
- package/voice-locks/darwin-x64-cp312.txt +12 -0
- package/voice-locks/darwin-x64-cp313.txt +12 -0
- package/voice-locks/darwin-x64-cp39.txt +12 -0
- package/voice-locks/linux-arm64-cp310.txt +12 -0
- package/voice-locks/linux-arm64-cp311.txt +8 -0
- package/voice-locks/linux-arm64-cp312.txt +8 -0
- package/voice-locks/linux-arm64-cp313.txt +8 -0
- package/voice-locks/linux-arm64-cp314.txt +8 -0
- package/voice-locks/linux-arm64-cp39.txt +12 -0
- package/voice-locks/linux-x64-cp310.txt +12 -0
- package/voice-locks/linux-x64-cp311.txt +8 -0
- package/voice-locks/linux-x64-cp312.txt +8 -0
- package/voice-locks/linux-x64-cp313.txt +8 -0
- package/voice-locks/linux-x64-cp314.txt +8 -0
- package/voice-locks/linux-x64-cp39.txt +12 -0
- package/dist/studio/assets/index-Bame65hj.js +0 -1108
- package/dist/studio/assets/index-CtB1BJRI.css +0 -32
package/dist/core/adapter.js
CHANGED
|
@@ -3,18 +3,21 @@ import { builtinDefs as deriveBuiltinDefs, engineDefOf } from './builtin-catalog
|
|
|
3
3
|
import { createRequire } from 'node:module';
|
|
4
4
|
import { attachEngineBus, detachEngineBus } from './bus.js';
|
|
5
5
|
import { mkdir, access, readFile, writeFile, chmod, rm, link, rename, realpath, stat, lstat } from 'node:fs/promises';
|
|
6
|
-
import { existsSync, readFileSync } from 'node:fs';
|
|
6
|
+
import { existsSync, readFileSync, statSync } from 'node:fs';
|
|
7
7
|
import { join, dirname, resolve, isAbsolute, relative, sep } from 'node:path';
|
|
8
8
|
import { isPlainRunId, WALKTHROUGH_AUTHOR_SUBDIR, walkthroughRootDir } from './walkthrough-root.js';
|
|
9
9
|
import { mcpStateDir } from '../mcp/registry-store.js';
|
|
10
|
+
import { resolveMemoryDbPath } from './estate-mcp-client.js';
|
|
10
11
|
import { crewStateHome, isDefaultStateHome, wickedWorkRoot } from '../projects/state-home.js';
|
|
11
12
|
import { fileURLToPath } from 'node:url';
|
|
12
13
|
import { homedir } from 'node:os';
|
|
13
14
|
import { randomUUID } from 'node:crypto';
|
|
15
|
+
import { RunReadLane } from './run-read-lane.js';
|
|
14
16
|
import { AskError, AskUnsupportedError } from './types.js';
|
|
17
|
+
import { factsFromEvents, runFingerprint, RunFactsFile } from './run-log-facts.js';
|
|
15
18
|
import { DEFAULT_SETTINGS } from './types.js';
|
|
16
19
|
import { BASE_SKILL_REF_SHAPE } from '../skills/base-skill.js';
|
|
17
|
-
import {
|
|
20
|
+
import { cloneRepository } from './repo-clone.js';
|
|
18
21
|
import { gitCommitIdents, usableGitIdent } from '../setup/known.js';
|
|
19
22
|
import { composeDeliverWorkflow, DELIVER_PHASE_ID, deliverPresetStep, deliverIdentityFor, deliverRepoFor, isGitHubLogin, pushIdentityOf, readDeliverOriginUrl } from './deliver.js';
|
|
20
23
|
import { engineCampaignDef, engineRosterJson } from './engine-roster.js';
|
|
@@ -367,6 +370,7 @@ const VIEW_NEUTRAL_CALLS = new Set([
|
|
|
367
370
|
'campaignDetail',
|
|
368
371
|
'sessions',
|
|
369
372
|
'sessionsDetail',
|
|
373
|
+
'sessionDetail',
|
|
370
374
|
'workOutput',
|
|
371
375
|
'unitTranscript',
|
|
372
376
|
'runEvents',
|
|
@@ -793,6 +797,8 @@ export class CoreAdapter {
|
|
|
793
797
|
listeners = new Set();
|
|
794
798
|
/** F35: the views version, moved by every engine frame (bar the live streams) and every engine call that may write. */
|
|
795
799
|
viewsEpoch = 0;
|
|
800
|
+
/** crew#1779: one-run reads a frame's listeners start wait in this lane, behind every request's read. */
|
|
801
|
+
runReads = new RunReadLane((runId) => this.runViewRead(runId), (view) => (view === undefined ? undefined : structuredClone(view)));
|
|
796
802
|
launchListeners = new Set();
|
|
797
803
|
/** crew#1145: what each engine launch awaits first (`setLaunchGate`); `null` = nothing. */
|
|
798
804
|
launchGate = null;
|
|
@@ -946,6 +952,10 @@ export class CoreAdapter {
|
|
|
946
952
|
applyGovernanceStoreEnv(this.governanceStore);
|
|
947
953
|
this.stub = opts.stub === true;
|
|
948
954
|
this.dbPath = opts.dbPath;
|
|
955
|
+
this.runFactsFile =
|
|
956
|
+
typeof opts.dbPath === 'string' && opts.dbPath !== '' && opts.dbPath !== ':memory:'
|
|
957
|
+
? new RunFactsFile(`${opts.dbPath}.run-facts.jsonl`, opts.dbPath)
|
|
958
|
+
: null;
|
|
949
959
|
// The QE acceptance setting's engine mirror (`syncEngineQeSetting`) must hold BEFORE the engine
|
|
950
960
|
// arms its bus bridge inside `spawn`, or a bus request in between would launch under the
|
|
951
961
|
// default: hand the boot value over in the engine's own variable, read at spawn.
|
|
@@ -1015,14 +1025,17 @@ export class CoreAdapter {
|
|
|
1015
1025
|
// any listener runs, so a read a listener starts sees the change).
|
|
1016
1026
|
if (!VIEW_NEUTRAL_EVENTS.has(event.type))
|
|
1017
1027
|
this.viewsEpoch++;
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1028
|
+
// crew#1779: a one-run read any listener starts from here takes the frame lane (`runView`).
|
|
1029
|
+
this.runReads.inFrame(() => {
|
|
1030
|
+
for (const listener of this.listeners) {
|
|
1031
|
+
try {
|
|
1032
|
+
listener(event);
|
|
1033
|
+
}
|
|
1034
|
+
catch {
|
|
1035
|
+
/* isolate a faulty listener */
|
|
1036
|
+
}
|
|
1024
1037
|
}
|
|
1025
|
-
}
|
|
1038
|
+
});
|
|
1026
1039
|
}
|
|
1027
1040
|
/**
|
|
1028
1041
|
* The engine's EVENT-node counter over an estate store (`Core.eventStoreCount`, crew#495's
|
|
@@ -1203,6 +1216,10 @@ export class CoreAdapter {
|
|
|
1203
1216
|
setDraining(drain) {
|
|
1204
1217
|
this.drainSince = drain ? (this.drainSince ?? Date.now()) : null;
|
|
1205
1218
|
}
|
|
1219
|
+
/** Whether new work is refused for maintenance (the launch's stand-in question is not asked of a draining daemon). */
|
|
1220
|
+
isDraining() {
|
|
1221
|
+
return this.drainSince !== null;
|
|
1222
|
+
}
|
|
1206
1223
|
/** Parked and human-held runs are idle for maintenance, but still hold their repository. */
|
|
1207
1224
|
async maintenanceState() {
|
|
1208
1225
|
const active = (await this.sessionsDetail())
|
|
@@ -1442,6 +1459,7 @@ export class CoreAdapter {
|
|
|
1442
1459
|
credentials, commitIdents) {
|
|
1443
1460
|
return deliverPresetStep(name, phases, input.sessionId, input.problem, {
|
|
1444
1461
|
repoRef: input.repoRef ?? null,
|
|
1462
|
+
...(input.trackerRefs !== undefined ? { trackerRefs: input.trackerRefs } : {}),
|
|
1445
1463
|
apiOrigin: this.deliverApiOrigin?.() ?? null,
|
|
1446
1464
|
revisesPr: input.revisesPr ?? null,
|
|
1447
1465
|
ghAccount: process.env['GH_ACCOUNT'] ?? null,
|
|
@@ -1523,6 +1541,12 @@ export class CoreAdapter {
|
|
|
1523
1541
|
if (input.extraReadRoots !== undefined && input.extraReadRoots.length > 0) {
|
|
1524
1542
|
opts.extraReadRoots = input.extraReadRoots;
|
|
1525
1543
|
}
|
|
1544
|
+
// wicked-core#1463: an older addon ignores the field, which only keeps every read root
|
|
1545
|
+
// required (today's fail-closed behaviour), so it needs no version gate. Widened locally, as
|
|
1546
|
+
// `primary` and `voice` are, so crew still compiles against an addon's older declarations.
|
|
1547
|
+
if (input.optionalReadRoots !== undefined && input.optionalReadRoots.length > 0) {
|
|
1548
|
+
opts.optionalReadRoots = input.optionalReadRoots;
|
|
1549
|
+
}
|
|
1526
1550
|
if (input.excludeSeats !== undefined && input.excludeSeats.length > 0) {
|
|
1527
1551
|
// Fail CLOSED on an old addon (napi ignores undeclared fields): a silently-dropped exclusion
|
|
1528
1552
|
// would let the seat that wrote the work judge it — the one thing the caller asked to rule out.
|
|
@@ -1542,6 +1566,17 @@ export class CoreAdapter {
|
|
|
1542
1566
|
}
|
|
1543
1567
|
opts.reducedAssurance = true;
|
|
1544
1568
|
}
|
|
1569
|
+
// (DES-STANDIN-001 §3.8, K2a) Fail CLOSED on an addon without stand-ins (napi ignores undeclared fields): the
|
|
1570
|
+
// person's consent would be dropped and the run would hold or fail where they were told it would be checked.
|
|
1571
|
+
if (input.standInAware === true) {
|
|
1572
|
+
if (!this.supportsStandIns()) {
|
|
1573
|
+
throw new Error('stand-in checks need a wicked-core-ts that carries them (Core.independencePreflight and grantStandIns); upgrade the engine');
|
|
1574
|
+
}
|
|
1575
|
+
const o = opts;
|
|
1576
|
+
o.standInAware = true;
|
|
1577
|
+
if (input.standIn !== undefined)
|
|
1578
|
+
o.standInJson = JSON.stringify(input.standIn);
|
|
1579
|
+
}
|
|
1545
1580
|
// (program DES-POWER-MODE) Fail CLOSED on an addon without power mode (napi ignores an undeclared
|
|
1546
1581
|
// field): the run would launch phased while its launcher reported power mode on.
|
|
1547
1582
|
if (input.power === true) {
|
|
@@ -1724,6 +1759,8 @@ export class CoreAdapter {
|
|
|
1724
1759
|
// def and one registration below, never two armed ids.
|
|
1725
1760
|
composed = composeDeliverWorkflow(composed, input.sessionId, input.problem, {
|
|
1726
1761
|
repoRef: input.repoRef ?? null,
|
|
1762
|
+
// crew#1352: the tracker issues the launch resolved, so the embedded fallback links them back.
|
|
1763
|
+
...(input.trackerRefs !== undefined ? { trackerRefs: input.trackerRefs } : {}),
|
|
1727
1764
|
apiOrigin: this.deliverApiOrigin?.() ?? null,
|
|
1728
1765
|
// DES-L9: the revised PR (push target) and the push identity for the gate card —
|
|
1729
1766
|
// GH_ACCOUNT's value and whether GH_TOKEN is exported (presence only, never the value).
|
|
@@ -1863,9 +1900,11 @@ export class CoreAdapter {
|
|
|
1863
1900
|
return Promise.reject(new PlanGateNoteUnsupportedError());
|
|
1864
1901
|
}
|
|
1865
1902
|
const core = this.core;
|
|
1903
|
+
// (crew#1698, core#1808) `expectGateSeq`: the opening of the gate the record showed; the engine refuses a
|
|
1904
|
+
// gate that closed and re-opened since (`gate_changed:`), at the same ord too.
|
|
1866
1905
|
return plan !== undefined
|
|
1867
|
-
? core.confirmGate(runId, true, note ?? null, 'edit_plan', null, JSON.stringify(plan), actorLabel ?? null, expect.ord ?? null, expect.planRev ?? null)
|
|
1868
|
-
: core.confirmGate(runId, approve, amend ?? null, action ?? null, amendScope ?? null, null, actorLabel ?? null, expect.ord ?? null, expect.planRev ?? null);
|
|
1906
|
+
? core.confirmGate(runId, true, note ?? null, 'edit_plan', null, JSON.stringify(plan), actorLabel ?? null, expect.ord ?? null, expect.planRev ?? null, expect.gateSeq ?? null)
|
|
1907
|
+
: core.confirmGate(runId, approve, amend ?? null, action ?? null, amendScope ?? null, null, actorLabel ?? null, expect.ord ?? null, expect.planRev ?? null, expect.gateSeq ?? null);
|
|
1869
1908
|
}, undefined, resumesWork);
|
|
1870
1909
|
}
|
|
1871
1910
|
return this.handedToEngine('run', runId, () => {
|
|
@@ -2027,6 +2066,45 @@ export class CoreAdapter {
|
|
|
2027
2066
|
const C = Core;
|
|
2028
2067
|
return typeof C.supportsPlanSendBack === 'function' && C.supportsPlanSendBack() === true;
|
|
2029
2068
|
}
|
|
2069
|
+
/** (DES-STANDIN-001 §3.9, §3.10; K2a) The linked engine takes stand-in launches: it carries both the preflight and
|
|
2070
|
+
* the gate grant (method presence, as core-ts documents). Read at call time. */
|
|
2071
|
+
supportsStandIns() {
|
|
2072
|
+
const c = this.core;
|
|
2073
|
+
return typeof c.independencePreflight === 'function' && typeof c.grantStandIns === 'function';
|
|
2074
|
+
}
|
|
2075
|
+
/**
|
|
2076
|
+
* (DES-STANDIN-001 §3.9) Which independent roles this launch would be short of, on the shape it would take: the
|
|
2077
|
+
* engine resolves the contract through the launch's own code. Rejects as the launch would refuse the shape.
|
|
2078
|
+
*/
|
|
2079
|
+
async independencePreflight(input) {
|
|
2080
|
+
const core = this.core;
|
|
2081
|
+
const shape = {
|
|
2082
|
+
...(input.workflow !== undefined ? { workflow: input.workflow } : {}),
|
|
2083
|
+
...(input.projectId !== undefined ? { projectId: input.projectId } : {}),
|
|
2084
|
+
...(input.plan !== undefined ? { planJson: JSON.stringify(input.plan) } : {}),
|
|
2085
|
+
...(input.power === true ? { power: true } : {}),
|
|
2086
|
+
...(input.primary !== undefined ? { primary: input.primary } : {}),
|
|
2087
|
+
...(input.excludeSeats !== undefined && input.excludeSeats.length > 0 ? { excludeSeats: input.excludeSeats } : {}),
|
|
2088
|
+
...(input.skipQeAcceptanceReason !== undefined ? { skipQeAcceptanceReason: input.skipQeAcceptanceReason } : {}),
|
|
2089
|
+
...(input.forceQeAcceptance === true ? { forceQeAcceptance: true } : {}),
|
|
2090
|
+
repoBound: input.repoRef !== undefined,
|
|
2091
|
+
};
|
|
2092
|
+
return core.independencePreflight(engineRosterJson(input.clisJson), JSON.stringify(shape));
|
|
2093
|
+
}
|
|
2094
|
+
/**
|
|
2095
|
+
* (DES-STANDIN-001 §3.10, crew#1856) USE STAND-INS at the run's open `stand_in_needed` gate: the person's consent
|
|
2096
|
+
* (`scope`) goes on the run and the held check continues. `gateSeq` is the open gate's opening (its durable row's
|
|
2097
|
+
* `gate_seq`), `actor` the server's name for the person. The engine refuses a stale opening (`gate_changed:`).
|
|
2098
|
+
*/
|
|
2099
|
+
grantStandIns(runId, scope, gateSeq, actor, ord) {
|
|
2100
|
+
const core = this.core;
|
|
2101
|
+
return this.handedToEngine('run', runId, () => {
|
|
2102
|
+
if (!this.supportsStandIns()) {
|
|
2103
|
+
return Promise.reject(new Error('Using stand-ins at a gate needs a wicked-core-ts with Core.grantStandIns; upgrade the engine'));
|
|
2104
|
+
}
|
|
2105
|
+
return core.grantStandIns(runId, scope, gateSeq, actor, ord ?? null);
|
|
2106
|
+
}, undefined, true);
|
|
2107
|
+
}
|
|
2030
2108
|
/** (workdoc-all-runs; core lane context-block-core) The linked engine keeps a per-run CONTEXT BLOCK it hands every
|
|
2031
2109
|
* seat it spawns (`Core.supportsRunContext`). Until it does, crew's working document re-sends the person's context
|
|
2032
2110
|
* before each later worker step (the standing note). Read at call time. */
|
|
@@ -2122,41 +2200,108 @@ export class CoreAdapter {
|
|
|
2122
2200
|
}
|
|
2123
2201
|
/**
|
|
2124
2202
|
* Each run's launch name as the engine RECORDED it — `sessionStarted.workflowId` from its event
|
|
2125
|
-
* log (the preset, the registered def, `<run>:plan-<rev>`, or `null` for free text).
|
|
2126
|
-
*
|
|
2127
|
-
*
|
|
2128
|
-
*
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2203
|
+
* log (the preset, the registered def, `<run>:plan-<rev>`, or `null` for free text). Seam X2 — the one input
|
|
2204
|
+
* `resolveRunIdentity` needs that the session record lacks.
|
|
2205
|
+
*
|
|
2206
|
+
* crew#1880: read through the run's log FACTS (run-log-facts.ts), one read per run answering both this and the
|
|
2207
|
+
* `ended_at` backfill ({@link runEndedFact}). A read made while the run is terminal is FINAL (its facts settle);
|
|
2208
|
+
* one made while it is live keeps only a found launch name (a live run's frame may not be flushed yet). A final
|
|
2209
|
+
* read's positive facts are kept beside the store, so the next start reads no log for them.
|
|
2210
|
+
*/
|
|
2211
|
+
runFactsMemo = new Map();
|
|
2212
|
+
/** One in-flight read per run and kind (a terminal-time read is never answered by a live-time one). */
|
|
2213
|
+
runFactsReads = new Map();
|
|
2214
|
+
/** crew#1880: `<db>.run-facts.jsonl`; null for an in-memory or unnamed store. */
|
|
2215
|
+
runFactsFile;
|
|
2216
|
+
/** One read of a run's log, shared by concurrent callers. `null` = no event-log binding; a failed read throws. */
|
|
2217
|
+
readRunFacts(view) {
|
|
2132
2218
|
const id = view.session.id;
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2219
|
+
const final = TERMINAL_RUN_STATUSES.has(view.session.status);
|
|
2220
|
+
const key = `${final ? 'T' : 'L'}:${id}`;
|
|
2221
|
+
const inFlight = this.runFactsReads.get(key);
|
|
2222
|
+
if (inFlight !== undefined)
|
|
2223
|
+
return inFlight;
|
|
2224
|
+
const read = (async () => {
|
|
2225
|
+
const events = await this.runEvents(id);
|
|
2226
|
+
if (events === null)
|
|
2227
|
+
return null;
|
|
2228
|
+
const facts = { ...factsFromEvents(events), final };
|
|
2229
|
+
if (final) {
|
|
2230
|
+
this.runFactsMemo.set(id, facts);
|
|
2231
|
+
this.runFactsFile?.put(id, runFingerprint(view.session.problem), facts);
|
|
2232
|
+
}
|
|
2233
|
+
else if (facts.launched !== undefined && this.runFactsMemo.get(id)?.final !== true) {
|
|
2234
|
+
this.runFactsMemo.set(id, facts);
|
|
2235
|
+
}
|
|
2236
|
+
return facts;
|
|
2237
|
+
})();
|
|
2238
|
+
this.runFactsReads.set(key, read);
|
|
2239
|
+
const clear = () => {
|
|
2240
|
+
if (this.runFactsReads.get(key) === read)
|
|
2241
|
+
this.runFactsReads.delete(key);
|
|
2242
|
+
};
|
|
2243
|
+
read.then(clear, clear);
|
|
2244
|
+
return read;
|
|
2245
|
+
}
|
|
2246
|
+
/** The facts kept for this run on disk (bound to its problem). A kept launch name is folded into the in-process
|
|
2247
|
+
* memo (so later folds skip the hash); the memo is FINAL only when both facts were kept (a negative never is). */
|
|
2248
|
+
keptRunFacts(view) {
|
|
2249
|
+
if (this.runFactsFile === null)
|
|
2250
|
+
return undefined;
|
|
2251
|
+
const kept = this.runFactsFile.get(view.session.id, runFingerprint(view.session.problem));
|
|
2252
|
+
if (kept?.launched !== undefined) {
|
|
2253
|
+
this.runFactsMemo.set(view.session.id, {
|
|
2254
|
+
launched: kept.launched,
|
|
2255
|
+
endedAt: kept.endedAt ?? null,
|
|
2256
|
+
final: kept.endedAt !== undefined,
|
|
2257
|
+
});
|
|
2258
|
+
}
|
|
2259
|
+
return kept;
|
|
2260
|
+
}
|
|
2261
|
+
async launchedWorkflowOf(view) {
|
|
2262
|
+
const known = this.runFactsMemo.get(view.session.id);
|
|
2263
|
+
if (known !== undefined && (known.final || known.launched !== undefined))
|
|
2264
|
+
return known.launched;
|
|
2265
|
+
const kept = this.keptRunFacts(view);
|
|
2266
|
+
if (kept?.launched !== undefined)
|
|
2267
|
+
return kept.launched;
|
|
2136
2268
|
try {
|
|
2137
|
-
|
|
2269
|
+
return (await this.readRunFacts(view))?.launched;
|
|
2138
2270
|
}
|
|
2139
2271
|
catch {
|
|
2140
2272
|
return undefined;
|
|
2141
2273
|
}
|
|
2142
|
-
|
|
2274
|
+
}
|
|
2275
|
+
/**
|
|
2276
|
+
* crew#1880: a terminal run's FIRST terminal frame `ts` (millis), for the `ended_at` backfill — from the in-process
|
|
2277
|
+
* memo, the kept facts, or one read of its log (shared with the identity read). `null` = the log holds no terminal
|
|
2278
|
+
* frame; `undefined` = no event-log binding. A failed read throws (the backfill retries it on a later request).
|
|
2279
|
+
*/
|
|
2280
|
+
async runEndedFact(view) {
|
|
2281
|
+
const known = this.runFactsMemo.get(view.session.id);
|
|
2282
|
+
if (known?.final === true)
|
|
2283
|
+
return known.endedAt;
|
|
2284
|
+
const kept = this.keptRunFacts(view);
|
|
2285
|
+
if (kept?.endedAt !== undefined)
|
|
2286
|
+
return kept.endedAt;
|
|
2287
|
+
const facts = await this.readRunFacts(view);
|
|
2288
|
+
if (facts === null)
|
|
2143
2289
|
return undefined;
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
this.launchedWorkflows.set(id, launched);
|
|
2150
|
-
}
|
|
2151
|
-
return launched;
|
|
2290
|
+
return facts.final ? facts.endedAt : null;
|
|
2291
|
+
}
|
|
2292
|
+
/** crew#1880: write the kept facts still buffered (tests; `close` flushes too). */
|
|
2293
|
+
flushRunFacts() {
|
|
2294
|
+
return this.runFactsFile?.flush() ?? Promise.resolve();
|
|
2152
2295
|
}
|
|
2153
2296
|
/**
|
|
2154
2297
|
* (DES-CATALOG-002 §2.3) The name one run was launched under, as the engine recorded it (`sessionStarted.workflowId`):
|
|
2155
2298
|
* the run fence's fallback for a run crew no longer holds in memory. Memoized once found; `undefined` = not known.
|
|
2156
2299
|
*/
|
|
2157
2300
|
async launchedWorkflowOfRun(runId) {
|
|
2158
|
-
|
|
2159
|
-
|
|
2301
|
+
// As before crew#1880: a found launch name, or a terminal run's settled "none", answers without a read.
|
|
2302
|
+
const known = this.runFactsMemo.get(runId);
|
|
2303
|
+
if (known !== undefined && (known.final || known.launched !== undefined))
|
|
2304
|
+
return known.launched;
|
|
2160
2305
|
let events;
|
|
2161
2306
|
try {
|
|
2162
2307
|
events = await this.runEvents(runId);
|
|
@@ -2164,13 +2309,14 @@ export class CoreAdapter {
|
|
|
2164
2309
|
catch {
|
|
2165
2310
|
return undefined;
|
|
2166
2311
|
}
|
|
2167
|
-
|
|
2168
|
-
|
|
2312
|
+
if (events === null)
|
|
2313
|
+
return undefined;
|
|
2314
|
+
const facts = factsFromEvents(events);
|
|
2315
|
+
if (facts.launched === undefined)
|
|
2169
2316
|
return undefined;
|
|
2170
|
-
|
|
2171
|
-
|
|
2172
|
-
|
|
2173
|
-
return launched;
|
|
2317
|
+
if (known === undefined)
|
|
2318
|
+
this.runFactsMemo.set(runId, { ...facts, final: false });
|
|
2319
|
+
return facts.launched;
|
|
2174
2320
|
}
|
|
2175
2321
|
/**
|
|
2176
2322
|
* Every run + its ordered units, each with its `run_identity` (seam X2) resolved from the engine's
|
|
@@ -2188,16 +2334,24 @@ export class CoreAdapter {
|
|
|
2188
2334
|
}
|
|
2189
2335
|
/**
|
|
2190
2336
|
* One run's view (as `sessionsDetail` serves it), or `undefined` for an unknown id: the caller's own
|
|
2191
|
-
* copy
|
|
2192
|
-
*
|
|
2193
|
-
*
|
|
2194
|
-
*
|
|
2195
|
-
|
|
2196
|
-
|
|
2197
|
-
|
|
2198
|
-
|
|
2199
|
-
|
|
2200
|
-
return
|
|
2337
|
+
* copy. crew#1775: read through the engine's per-run read (`sessionDetail`, core#1346), off the actor,
|
|
2338
|
+
* so a request about one run never folds the store. The whole-store snapshot was invalidated by every
|
|
2339
|
+
* engine frame, so while runs were active each gate read paid for a fresh fold of every run (and its
|
|
2340
|
+
* parse on the event loop), and studio's per-page gate reads queued behind those folds. The read
|
|
2341
|
+
* starts now, so it is never older than a change this adapter made or a frame it delivered.
|
|
2342
|
+
* crew#1779: a read a frame listener starts takes the frame lane ({@link RunReadLane}): it waits
|
|
2343
|
+
* behind no request's read, and the listeners of one frame share one read of the run.
|
|
2344
|
+
*/
|
|
2345
|
+
async runView(runId) {
|
|
2346
|
+
return this.runReads.get(runId);
|
|
2347
|
+
}
|
|
2348
|
+
/** One run's read and its identity, as one operation: the frame lane shares and bounds all of it (crew#1779). */
|
|
2349
|
+
async runViewRead(runId) {
|
|
2350
|
+
const view = JSON.parse(await this.core.sessionDetail(runId));
|
|
2351
|
+
if (view === null)
|
|
2352
|
+
return undefined;
|
|
2353
|
+
await this.resolveIdentities([view]);
|
|
2354
|
+
return view;
|
|
2201
2355
|
}
|
|
2202
2356
|
/**
|
|
2203
2357
|
* The shared, deep-frozen views snapshot itself — the same object for every caller until the store
|
|
@@ -2252,7 +2406,7 @@ export class CoreAdapter {
|
|
|
2252
2406
|
const views = JSON.parse(await this.core.sessionsDetail());
|
|
2253
2407
|
await this.resolveIdentities(views);
|
|
2254
2408
|
deepFreeze(views);
|
|
2255
|
-
const done = { epoch, at, snapshot: Object.freeze({ views })
|
|
2409
|
+
const done = { epoch, at, snapshot: Object.freeze({ views }) };
|
|
2256
2410
|
this.viewsLatest = done;
|
|
2257
2411
|
return done;
|
|
2258
2412
|
})();
|
|
@@ -2703,12 +2857,8 @@ export class CoreAdapter {
|
|
|
2703
2857
|
catch { /* not yet cloned */ }
|
|
2704
2858
|
if (needsClone) {
|
|
2705
2859
|
try {
|
|
2706
|
-
|
|
2707
|
-
|
|
2708
|
-
// crew-0182: a repository that needs a sign-in fails in seconds with git's own reason, instead of waiting on a
|
|
2709
|
-
// credential prompt no one can answer until the 5-minute timeout.
|
|
2710
|
-
env: { ...process.env, GIT_TERMINAL_PROMPT: '0', ...(opts.allowProtocols !== undefined ? { GIT_ALLOW_PROTOCOL: opts.allowProtocols } : {}) },
|
|
2711
|
-
});
|
|
2860
|
+
// crew#1839: an Azure DevOps URL clones with the daemon's Azure DevOps credential when it holds one.
|
|
2861
|
+
await cloneRepository(gitUrl, cloneDir, opts);
|
|
2712
2862
|
}
|
|
2713
2863
|
catch (err) {
|
|
2714
2864
|
// Cleanup is best-effort: swallow any cleanup error so the original
|
|
@@ -3130,6 +3280,22 @@ export class CoreAdapter {
|
|
|
3130
3280
|
return override;
|
|
3131
3281
|
return isDefaultStateHome() ? undefined : join(mcpStateDir(), 'evals-knowledge.db');
|
|
3132
3282
|
}
|
|
3283
|
+
/**
|
|
3284
|
+
* (crew#1128) The memory store the evals' memory axis recalls from (core#397): the store this daemon's workers recall
|
|
3285
|
+
* from ({@link resolveMemoryDbPath}: `WICKED_MEMORY_DB`, else `<state home>/mcp/memory.db`, else the operator's
|
|
3286
|
+
* global store), opened read-only by the engine. `undefined` while that file does not exist: the engine refuses a
|
|
3287
|
+
* run whose `memoryDb` is missing, so a daemon with no memories yet keeps the rules-only report (`memory: null`), and
|
|
3288
|
+
* a sample that declares memories gets the engine's own "no memory store" refusal.
|
|
3289
|
+
*/
|
|
3290
|
+
static governanceMemoryDb() {
|
|
3291
|
+
const path = resolveMemoryDbPath();
|
|
3292
|
+
try {
|
|
3293
|
+
return statSync(path).isFile() ? path : undefined;
|
|
3294
|
+
}
|
|
3295
|
+
catch {
|
|
3296
|
+
return undefined;
|
|
3297
|
+
}
|
|
3298
|
+
}
|
|
3133
3299
|
/**
|
|
3134
3300
|
* Run the governance evals: every sample of the corpus (`corpus` = an `evals:<name>` estate
|
|
3135
3301
|
* scope minted by {@link importGovernanceCorpus}; omitted = the engine's built-in default
|
|
@@ -3151,10 +3317,12 @@ export class CoreAdapter {
|
|
|
3151
3317
|
throw new GovernanceEvalsUnsupportedError('Running governance evals');
|
|
3152
3318
|
}
|
|
3153
3319
|
const knowledgeDb = CoreAdapter.governanceKnowledgeDb();
|
|
3320
|
+
const memoryDb = CoreAdapter.governanceMemoryDb();
|
|
3154
3321
|
const payload = {
|
|
3155
3322
|
...(args.type !== undefined ? { type: args.type } : {}),
|
|
3156
3323
|
...(args.corpus !== undefined ? { corpus: args.corpus } : {}),
|
|
3157
3324
|
...(knowledgeDb !== undefined ? { knowledgeDb } : {}),
|
|
3325
|
+
...(memoryDb !== undefined ? { memoryDb } : {}),
|
|
3158
3326
|
dbPath: this.dbPath,
|
|
3159
3327
|
};
|
|
3160
3328
|
return parseEngineJson(await fn.call(this.core, JSON.stringify(payload)), 'governanceEvals');
|
|
@@ -3507,6 +3675,9 @@ export class CoreAdapter {
|
|
|
3507
3675
|
// powerModeDefault (program DES-POWER-MODE): a boolean only; anything else reads as the shipped default (on).
|
|
3508
3676
|
if ('powerModeDefault' in parsed && typeof parsed.powerModeDefault !== 'boolean')
|
|
3509
3677
|
delete parsed.powerModeDefault;
|
|
3678
|
+
// standInReview (DES-STANDIN-001 §4): 'ask' | 'always' only; anything else reads as unset ('ask', asked each time).
|
|
3679
|
+
if ('standInReview' in parsed && parsed.standInReview !== 'ask' && parsed.standInReview !== 'always')
|
|
3680
|
+
delete parsed.standInReview;
|
|
3510
3681
|
// newWorkSeats (F1/F2): a list of seat keys, or null. An invalid value is left out of the settings served (they
|
|
3511
3682
|
// keep the API's type) but KEPT for the next write (`kept`): new work reads it strictly (`readNewWorkSeats`) and
|
|
3512
3683
|
// refuses it, and an unrelated write that erased it would quietly widen the pool to every seat.
|
|
@@ -3618,6 +3789,7 @@ export class CoreAdapter {
|
|
|
3618
3789
|
if (this.closed)
|
|
3619
3790
|
return;
|
|
3620
3791
|
this.closed = true;
|
|
3792
|
+
void this.runFactsFile?.flush();
|
|
3621
3793
|
if (this.engineBus !== null && this.busDbPath !== undefined)
|
|
3622
3794
|
detachEngineBus(this.busDbPath, this.engineBus);
|
|
3623
3795
|
this.listeners.clear();
|