@xemahq/kernel-contracts 0.1.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/dist/agent-composition/index.d.ts +7 -0
- package/dist/agent-composition/index.d.ts.map +1 -0
- package/dist/agent-composition/index.js +23 -0
- package/dist/agent-composition/index.js.map +1 -0
- package/dist/agent-composition/lib/capability-layer.d.ts +11 -0
- package/dist/agent-composition/lib/capability-layer.d.ts.map +1 -0
- package/dist/agent-composition/lib/capability-layer.js +10 -0
- package/dist/agent-composition/lib/capability-layer.js.map +1 -0
- package/dist/agent-composition/lib/composition-limits-schema.d.ts +4 -0
- package/dist/agent-composition/lib/composition-limits-schema.d.ts.map +1 -0
- package/dist/agent-composition/lib/composition-limits-schema.js +13 -0
- package/dist/agent-composition/lib/composition-limits-schema.js.map +1 -0
- package/dist/agent-composition/lib/composition-workspace.d.ts +35 -0
- package/dist/agent-composition/lib/composition-workspace.d.ts.map +1 -0
- package/dist/agent-composition/lib/composition-workspace.js +9 -0
- package/dist/agent-composition/lib/composition-workspace.js.map +1 -0
- package/dist/agent-composition/lib/composition.d.ts +66 -0
- package/dist/agent-composition/lib/composition.d.ts.map +1 -0
- package/dist/agent-composition/lib/composition.js +18 -0
- package/dist/agent-composition/lib/composition.js.map +1 -0
- package/dist/agent-composition/lib/intrinsic-floor.d.ts +15 -0
- package/dist/agent-composition/lib/intrinsic-floor.d.ts.map +1 -0
- package/dist/agent-composition/lib/intrinsic-floor.js +22 -0
- package/dist/agent-composition/lib/intrinsic-floor.js.map +1 -0
- package/dist/agent-composition/lib/model-resolution-matrix.d.ts +38 -0
- package/dist/agent-composition/lib/model-resolution-matrix.d.ts.map +1 -0
- package/dist/agent-composition/lib/model-resolution-matrix.js +12 -0
- package/dist/agent-composition/lib/model-resolution-matrix.js.map +1 -0
- package/dist/agent-workspace/awp-spec.json +225 -0
- package/dist/agent-workspace/index.d.ts +12 -0
- package/dist/agent-workspace/index.d.ts.map +1 -0
- package/dist/agent-workspace/index.js +28 -0
- package/dist/agent-workspace/index.js.map +1 -0
- package/dist/agent-workspace/lib/agent-run-context.d.ts +12 -0
- package/dist/agent-workspace/lib/agent-run-context.d.ts.map +1 -0
- package/dist/agent-workspace/lib/agent-run-context.js +3 -0
- package/dist/agent-workspace/lib/agent-run-context.js.map +1 -0
- package/dist/agent-workspace/lib/agent-tool-defaults.d.ts +21 -0
- package/dist/agent-workspace/lib/agent-tool-defaults.d.ts.map +1 -0
- package/dist/agent-workspace/lib/agent-tool-defaults.js +111 -0
- package/dist/agent-workspace/lib/agent-tool-defaults.js.map +1 -0
- package/dist/agent-workspace/lib/awp-v1.d.ts +15 -0
- package/dist/agent-workspace/lib/awp-v1.d.ts.map +1 -0
- package/dist/agent-workspace/lib/awp-v1.js +197 -0
- package/dist/agent-workspace/lib/awp-v1.js.map +1 -0
- package/dist/agent-workspace/lib/context-json.d.ts +35 -0
- package/dist/agent-workspace/lib/context-json.d.ts.map +1 -0
- package/dist/agent-workspace/lib/context-json.js +3 -0
- package/dist/agent-workspace/lib/context-json.js.map +1 -0
- package/dist/agent-workspace/lib/deliverable-spec-ref.d.ts +10 -0
- package/dist/agent-workspace/lib/deliverable-spec-ref.d.ts.map +1 -0
- package/dist/agent-workspace/lib/deliverable-spec-ref.js +33 -0
- package/dist/agent-workspace/lib/deliverable-spec-ref.js.map +1 -0
- package/dist/agent-workspace/lib/endpoint-fetch-spec.d.ts +31 -0
- package/dist/agent-workspace/lib/endpoint-fetch-spec.d.ts.map +1 -0
- package/dist/agent-workspace/lib/endpoint-fetch-spec.js +20 -0
- package/dist/agent-workspace/lib/endpoint-fetch-spec.js.map +1 -0
- package/dist/agent-workspace/lib/manifest.d.ts +28 -0
- package/dist/agent-workspace/lib/manifest.d.ts.map +1 -0
- package/dist/agent-workspace/lib/manifest.js +16 -0
- package/dist/agent-workspace/lib/manifest.js.map +1 -0
- package/dist/agent-workspace/lib/mount-apply.d.ts +42 -0
- package/dist/agent-workspace/lib/mount-apply.d.ts.map +1 -0
- package/dist/agent-workspace/lib/mount-apply.js +15 -0
- package/dist/agent-workspace/lib/mount-apply.js.map +1 -0
- package/dist/agent-workspace/lib/working-file.d.ts +20 -0
- package/dist/agent-workspace/lib/working-file.d.ts.map +1 -0
- package/dist/agent-workspace/lib/working-file.js +42 -0
- package/dist/agent-workspace/lib/working-file.js.map +1 -0
- package/dist/agent-workspace/lib/workspace-layout.d.ts +34 -0
- package/dist/agent-workspace/lib/workspace-layout.d.ts.map +1 -0
- package/dist/agent-workspace/lib/workspace-layout.js +31 -0
- package/dist/agent-workspace/lib/workspace-layout.js.map +1 -0
- package/dist/agent-workspace/lib/workspace-spec.d.ts +61 -0
- package/dist/agent-workspace/lib/workspace-spec.d.ts.map +1 -0
- package/dist/agent-workspace/lib/workspace-spec.js +19 -0
- package/dist/agent-workspace/lib/workspace-spec.js.map +1 -0
- package/dist/biome/index.d.ts +11 -0
- package/dist/biome/index.d.ts.map +1 -0
- package/dist/biome/index.js +27 -0
- package/dist/biome/index.js.map +1 -0
- package/dist/biome/lib/biome-api.d.ts +12 -0
- package/dist/biome/lib/biome-api.d.ts.map +1 -0
- package/dist/biome/lib/biome-api.js +14 -0
- package/dist/biome/lib/biome-api.js.map +1 -0
- package/dist/biome/lib/biome-capability-refs.d.ts +11 -0
- package/dist/biome/lib/biome-capability-refs.d.ts.map +1 -0
- package/dist/biome/lib/biome-capability-refs.js +12 -0
- package/dist/biome/lib/biome-capability-refs.js.map +1 -0
- package/dist/biome/lib/biome-engines.d.ts +6 -0
- package/dist/biome/lib/biome-engines.d.ts.map +1 -0
- package/dist/biome/lib/biome-engines.js +8 -0
- package/dist/biome/lib/biome-engines.js.map +1 -0
- package/dist/biome/lib/biome-lifecycle-hooks.d.ts +10 -0
- package/dist/biome/lib/biome-lifecycle-hooks.d.ts.map +1 -0
- package/dist/biome/lib/biome-lifecycle-hooks.js +12 -0
- package/dist/biome/lib/biome-lifecycle-hooks.js.map +1 -0
- package/dist/biome/lib/biome-lifecycle.d.ts +12 -0
- package/dist/biome/lib/biome-lifecycle.d.ts.map +1 -0
- package/dist/biome/lib/biome-lifecycle.js +16 -0
- package/dist/biome/lib/biome-lifecycle.js.map +1 -0
- package/dist/biome/lib/biome-manifest.d.ts +36 -0
- package/dist/biome/lib/biome-manifest.d.ts.map +1 -0
- package/dist/biome/lib/biome-manifest.js +38 -0
- package/dist/biome/lib/biome-manifest.js.map +1 -0
- package/dist/biome/lib/biome-permissions.d.ts +9 -0
- package/dist/biome/lib/biome-permissions.d.ts.map +1 -0
- package/dist/biome/lib/biome-permissions.js +11 -0
- package/dist/biome/lib/biome-permissions.js.map +1 -0
- package/dist/biome/lib/biome-scope.d.ts +9 -0
- package/dist/biome/lib/biome-scope.d.ts.map +1 -0
- package/dist/biome/lib/biome-scope.js +13 -0
- package/dist/biome/lib/biome-scope.js.map +1 -0
- package/dist/biome/lib/biome-trust-tier.d.ts +11 -0
- package/dist/biome/lib/biome-trust-tier.d.ts.map +1 -0
- package/dist/biome/lib/biome-trust-tier.js +15 -0
- package/dist/biome/lib/biome-trust-tier.js.map +1 -0
- package/dist/biome/lib/trust-tier-policies.d.ts +8 -0
- package/dist/biome/lib/trust-tier-policies.d.ts.map +1 -0
- package/dist/biome/lib/trust-tier-policies.js +66 -0
- package/dist/biome/lib/trust-tier-policies.js.map +1 -0
- package/dist/capability/index.d.ts +9 -0
- package/dist/capability/index.d.ts.map +1 -0
- package/dist/capability/index.js +25 -0
- package/dist/capability/index.js.map +1 -0
- package/dist/capability/lib/capability-contribution.d.ts +18 -0
- package/dist/capability/lib/capability-contribution.d.ts.map +1 -0
- package/dist/capability/lib/capability-contribution.js +23 -0
- package/dist/capability/lib/capability-contribution.js.map +1 -0
- package/dist/capability/lib/capability-grant.d.ts +22 -0
- package/dist/capability/lib/capability-grant.d.ts.map +1 -0
- package/dist/capability/lib/capability-grant.js +27 -0
- package/dist/capability/lib/capability-grant.js.map +1 -0
- package/dist/capability/lib/capability-policy.d.ts +12 -0
- package/dist/capability/lib/capability-policy.d.ts.map +1 -0
- package/dist/capability/lib/capability-policy.js +14 -0
- package/dist/capability/lib/capability-policy.js.map +1 -0
- package/dist/capability/lib/capability-ref.d.ts +19 -0
- package/dist/capability/lib/capability-ref.d.ts.map +1 -0
- package/dist/capability/lib/capability-ref.js +63 -0
- package/dist/capability/lib/capability-ref.js.map +1 -0
- package/dist/capability/lib/errors.d.ts +60 -0
- package/dist/capability/lib/errors.d.ts.map +1 -0
- package/dist/capability/lib/errors.js +73 -0
- package/dist/capability/lib/errors.js.map +1 -0
- package/dist/capability/lib/meta-tool.d.ts +77 -0
- package/dist/capability/lib/meta-tool.d.ts.map +1 -0
- package/dist/capability/lib/meta-tool.js +76 -0
- package/dist/capability/lib/meta-tool.js.map +1 -0
- package/dist/capability/lib/permission-profile.d.ts +35 -0
- package/dist/capability/lib/permission-profile.d.ts.map +1 -0
- package/dist/capability/lib/permission-profile.js +38 -0
- package/dist/capability/lib/permission-profile.js.map +1 -0
- package/dist/capability/lib/shell-command-descriptor.d.ts +19 -0
- package/dist/capability/lib/shell-command-descriptor.d.ts.map +1 -0
- package/dist/capability/lib/shell-command-descriptor.js +20 -0
- package/dist/capability/lib/shell-command-descriptor.js.map +1 -0
- package/dist/contribution/index.d.ts +5 -0
- package/dist/contribution/index.d.ts.map +1 -0
- package/dist/contribution/index.js +21 -0
- package/dist/contribution/index.js.map +1 -0
- package/dist/contribution/lib/contribution-kind.d.ts +44 -0
- package/dist/contribution/lib/contribution-kind.d.ts.map +1 -0
- package/dist/contribution/lib/contribution-kind.js +47 -0
- package/dist/contribution/lib/contribution-kind.js.map +1 -0
- package/dist/contribution/lib/contribution-source.d.ts +11 -0
- package/dist/contribution/lib/contribution-source.d.ts.map +1 -0
- package/dist/contribution/lib/contribution-source.js +14 -0
- package/dist/contribution/lib/contribution-source.js.map +1 -0
- package/dist/contribution/lib/contribution.d.ts +36 -0
- package/dist/contribution/lib/contribution.d.ts.map +1 -0
- package/dist/contribution/lib/contribution.js +56 -0
- package/dist/contribution/lib/contribution.js.map +1 -0
- package/dist/contribution/lib/registry.d.ts +25 -0
- package/dist/contribution/lib/registry.d.ts.map +1 -0
- package/dist/contribution/lib/registry.js +54 -0
- package/dist/contribution/lib/registry.js.map +1 -0
- package/dist/document-templates/index.d.ts +3 -0
- package/dist/document-templates/index.d.ts.map +1 -0
- package/dist/document-templates/index.js +19 -0
- package/dist/document-templates/index.js.map +1 -0
- package/dist/document-templates/lib/document-template.d.ts +24 -0
- package/dist/document-templates/lib/document-template.d.ts.map +1 -0
- package/dist/document-templates/lib/document-template.js +10 -0
- package/dist/document-templates/lib/document-template.js.map +1 -0
- package/dist/document-templates/lib/index.d.ts +3 -0
- package/dist/document-templates/lib/index.d.ts.map +1 -0
- package/dist/document-templates/lib/index.js +19 -0
- package/dist/document-templates/lib/index.js.map +1 -0
- package/dist/document-templates/lib/rendering-shape.d.ts +7 -0
- package/dist/document-templates/lib/rendering-shape.d.ts.map +1 -0
- package/dist/document-templates/lib/rendering-shape.js +20 -0
- package/dist/document-templates/lib/rendering-shape.js.map +1 -0
- package/dist/document-themes/index.d.ts +3 -0
- package/dist/document-themes/index.d.ts.map +1 -0
- package/dist/document-themes/index.js +19 -0
- package/dist/document-themes/index.js.map +1 -0
- package/dist/document-themes/lib/component-vocabulary.d.ts +16 -0
- package/dist/document-themes/lib/component-vocabulary.d.ts.map +1 -0
- package/dist/document-themes/lib/component-vocabulary.js +55 -0
- package/dist/document-themes/lib/component-vocabulary.js.map +1 -0
- package/dist/document-themes/lib/document-theme.d.ts +57 -0
- package/dist/document-themes/lib/document-theme.d.ts.map +1 -0
- package/dist/document-themes/lib/document-theme.js +10 -0
- package/dist/document-themes/lib/document-theme.js.map +1 -0
- package/dist/document-themes/lib/index.d.ts +3 -0
- package/dist/document-themes/lib/index.d.ts.map +1 -0
- package/dist/document-themes/lib/index.js +19 -0
- package/dist/document-themes/lib/index.js.map +1 -0
- package/dist/entitlement/index.d.ts +2 -0
- package/dist/entitlement/index.d.ts.map +1 -0
- package/dist/entitlement/index.js +18 -0
- package/dist/entitlement/index.js.map +1 -0
- package/dist/entitlement/lib/entitlement.d.ts +25 -0
- package/dist/entitlement/lib/entitlement.d.ts.map +1 -0
- package/dist/entitlement/lib/entitlement.js +54 -0
- package/dist/entitlement/lib/entitlement.js.map +1 -0
- package/dist/execution-context/index.d.ts +4 -0
- package/dist/execution-context/index.d.ts.map +1 -0
- package/dist/execution-context/index.js +20 -0
- package/dist/execution-context/index.js.map +1 -0
- package/dist/execution-context/lib/caller.d.ts +19 -0
- package/dist/execution-context/lib/caller.d.ts.map +1 -0
- package/dist/execution-context/lib/caller.js +22 -0
- package/dist/execution-context/lib/caller.js.map +1 -0
- package/dist/execution-context/lib/execution-context.d.ts +60 -0
- package/dist/execution-context/lib/execution-context.d.ts.map +1 -0
- package/dist/execution-context/lib/execution-context.js +58 -0
- package/dist/execution-context/lib/execution-context.js.map +1 -0
- package/dist/execution-context/lib/subject.d.ts +3 -0
- package/dist/execution-context/lib/subject.d.ts.map +1 -0
- package/dist/execution-context/lib/subject.js +11 -0
- package/dist/execution-context/lib/subject.js.map +1 -0
- package/dist/execution-environment/index.d.ts +4 -0
- package/dist/execution-environment/index.d.ts.map +1 -0
- package/dist/execution-environment/index.js +20 -0
- package/dist/execution-environment/index.js.map +1 -0
- package/dist/execution-environment/lib/approval-rule.d.ts +10 -0
- package/dist/execution-environment/lib/approval-rule.d.ts.map +1 -0
- package/dist/execution-environment/lib/approval-rule.js +12 -0
- package/dist/execution-environment/lib/approval-rule.js.map +1 -0
- package/dist/execution-environment/lib/built-in-environments.d.ts +16 -0
- package/dist/execution-environment/lib/built-in-environments.d.ts.map +1 -0
- package/dist/execution-environment/lib/built-in-environments.js +33 -0
- package/dist/execution-environment/lib/built-in-environments.js.map +1 -0
- package/dist/execution-environment/lib/execution-environment.d.ts +58 -0
- package/dist/execution-environment/lib/execution-environment.d.ts.map +1 -0
- package/dist/execution-environment/lib/execution-environment.js +89 -0
- package/dist/execution-environment/lib/execution-environment.js.map +1 -0
- package/dist/kernel-state/index.d.ts +4 -0
- package/dist/kernel-state/index.d.ts.map +1 -0
- package/dist/kernel-state/index.js +20 -0
- package/dist/kernel-state/index.js.map +1 -0
- package/dist/kernel-state/lib/adapter-kind.d.ts +5 -0
- package/dist/kernel-state/lib/adapter-kind.d.ts.map +1 -0
- package/dist/kernel-state/lib/adapter-kind.js +9 -0
- package/dist/kernel-state/lib/adapter-kind.js.map +1 -0
- package/dist/kernel-state/lib/kernel-state.d.ts +37 -0
- package/dist/kernel-state/lib/kernel-state.d.ts.map +1 -0
- package/dist/kernel-state/lib/kernel-state.js +9 -0
- package/dist/kernel-state/lib/kernel-state.js.map +1 -0
- package/dist/kernel-state/lib/key-grammar.d.ts +16 -0
- package/dist/kernel-state/lib/key-grammar.d.ts.map +1 -0
- package/dist/kernel-state/lib/key-grammar.js +56 -0
- package/dist/kernel-state/lib/key-grammar.js.map +1 -0
- package/dist/llm-gateway/index.d.ts +3 -0
- package/dist/llm-gateway/index.d.ts.map +1 -0
- package/dist/llm-gateway/index.js +19 -0
- package/dist/llm-gateway/index.js.map +1 -0
- package/dist/llm-gateway/lib/caller.d.ts +14 -0
- package/dist/llm-gateway/lib/caller.d.ts.map +1 -0
- package/dist/llm-gateway/lib/caller.js +11 -0
- package/dist/llm-gateway/lib/caller.js.map +1 -0
- package/dist/llm-gateway/lib/errors.d.ts +27 -0
- package/dist/llm-gateway/lib/errors.d.ts.map +1 -0
- package/dist/llm-gateway/lib/errors.js +36 -0
- package/dist/llm-gateway/lib/errors.js.map +1 -0
- package/dist/mcp-tool/index.d.ts +7 -0
- package/dist/mcp-tool/index.d.ts.map +1 -0
- package/dist/mcp-tool/index.js +23 -0
- package/dist/mcp-tool/index.js.map +1 -0
- package/dist/mcp-tool/lib/mcp-protocol.d.ts +75 -0
- package/dist/mcp-tool/lib/mcp-protocol.d.ts.map +1 -0
- package/dist/mcp-tool/lib/mcp-protocol.js +19 -0
- package/dist/mcp-tool/lib/mcp-protocol.js.map +1 -0
- package/dist/mcp-tool/lib/mcp-server-config.d.ts +8 -0
- package/dist/mcp-tool/lib/mcp-server-config.d.ts.map +1 -0
- package/dist/mcp-tool/lib/mcp-server-config.js +3 -0
- package/dist/mcp-tool/lib/mcp-server-config.js.map +1 -0
- package/dist/mcp-tool/lib/provider-kind.d.ts +10 -0
- package/dist/mcp-tool/lib/provider-kind.d.ts.map +1 -0
- package/dist/mcp-tool/lib/provider-kind.js +14 -0
- package/dist/mcp-tool/lib/provider-kind.js.map +1 -0
- package/dist/mcp-tool/lib/resolver-scope.d.ts +16 -0
- package/dist/mcp-tool/lib/resolver-scope.d.ts.map +1 -0
- package/dist/mcp-tool/lib/resolver-scope.js +12 -0
- package/dist/mcp-tool/lib/resolver-scope.js.map +1 -0
- package/dist/mcp-tool/lib/tool-provider.d.ts +21 -0
- package/dist/mcp-tool/lib/tool-provider.d.ts.map +1 -0
- package/dist/mcp-tool/lib/tool-provider.js +3 -0
- package/dist/mcp-tool/lib/tool-provider.js.map +1 -0
- package/dist/mcp-tool/lib/tool-selection.d.ts +34 -0
- package/dist/mcp-tool/lib/tool-selection.d.ts.map +1 -0
- package/dist/mcp-tool/lib/tool-selection.js +18 -0
- package/dist/mcp-tool/lib/tool-selection.js.map +1 -0
- package/dist/object/index.d.ts +5 -0
- package/dist/object/index.d.ts.map +1 -0
- package/dist/object/index.js +21 -0
- package/dist/object/index.js.map +1 -0
- package/dist/object/lib/object-lifecycle.d.ts +8 -0
- package/dist/object/lib/object-lifecycle.d.ts.map +1 -0
- package/dist/object/lib/object-lifecycle.js +12 -0
- package/dist/object/lib/object-lifecycle.js.map +1 -0
- package/dist/object/lib/xema-object-kind.d.ts +43 -0
- package/dist/object/lib/xema-object-kind.d.ts.map +1 -0
- package/dist/object/lib/xema-object-kind.js +47 -0
- package/dist/object/lib/xema-object-kind.js.map +1 -0
- package/dist/object/lib/xema-object-ref.d.ts +20 -0
- package/dist/object/lib/xema-object-ref.d.ts.map +1 -0
- package/dist/object/lib/xema-object-ref.js +133 -0
- package/dist/object/lib/xema-object-ref.js.map +1 -0
- package/dist/object/lib/xema-object.d.ts +24 -0
- package/dist/object/lib/xema-object.d.ts.map +1 -0
- package/dist/object/lib/xema-object.js +24 -0
- package/dist/object/lib/xema-object.js.map +1 -0
- package/dist/policy/index.d.ts +4 -0
- package/dist/policy/index.d.ts.map +1 -0
- package/dist/policy/index.js +20 -0
- package/dist/policy/index.js.map +1 -0
- package/dist/policy/lib/obligations.d.ts +91 -0
- package/dist/policy/lib/obligations.d.ts.map +1 -0
- package/dist/policy/lib/obligations.js +76 -0
- package/dist/policy/lib/obligations.js.map +1 -0
- package/dist/policy/lib/policy.d.ts +29 -0
- package/dist/policy/lib/policy.d.ts.map +1 -0
- package/dist/policy/lib/policy.js +32 -0
- package/dist/policy/lib/policy.js.map +1 -0
- package/dist/policy/lib/route-hints.d.ts +11 -0
- package/dist/policy/lib/route-hints.d.ts.map +1 -0
- package/dist/policy/lib/route-hints.js +15 -0
- package/dist/policy/lib/route-hints.js.map +1 -0
- package/dist/runner/index.d.ts +12 -0
- package/dist/runner/index.d.ts.map +1 -0
- package/dist/runner/index.js +28 -0
- package/dist/runner/index.js.map +1 -0
- package/dist/runner/lib/dispatch.d.ts +13 -0
- package/dist/runner/lib/dispatch.d.ts.map +1 -0
- package/dist/runner/lib/dispatch.js +15 -0
- package/dist/runner/lib/dispatch.js.map +1 -0
- package/dist/runner/lib/input-hash.d.ts +2 -0
- package/dist/runner/lib/input-hash.d.ts.map +1 -0
- package/dist/runner/lib/input-hash.js +37 -0
- package/dist/runner/lib/input-hash.js.map +1 -0
- package/dist/runner/lib/job-token.d.ts +22 -0
- package/dist/runner/lib/job-token.d.ts.map +1 -0
- package/dist/runner/lib/job-token.js +3 -0
- package/dist/runner/lib/job-token.js.map +1 -0
- package/dist/runner/lib/runner-attestation.d.ts +10 -0
- package/dist/runner/lib/runner-attestation.d.ts.map +1 -0
- package/dist/runner/lib/runner-attestation.js +5 -0
- package/dist/runner/lib/runner-attestation.js.map +1 -0
- package/dist/runner/lib/runner-job.d.ts +26 -0
- package/dist/runner/lib/runner-job.d.ts.map +1 -0
- package/dist/runner/lib/runner-job.js +36 -0
- package/dist/runner/lib/runner-job.js.map +1 -0
- package/dist/runner/lib/runner-kind.d.ts +2 -0
- package/dist/runner/lib/runner-kind.d.ts.map +1 -0
- package/dist/runner/lib/runner-kind.js +7 -0
- package/dist/runner/lib/runner-kind.js.map +1 -0
- package/dist/runner/lib/runner-mode.d.ts +5 -0
- package/dist/runner/lib/runner-mode.d.ts.map +1 -0
- package/dist/runner/lib/runner-mode.js +9 -0
- package/dist/runner/lib/runner-mode.js.map +1 -0
- package/dist/runner/lib/runner-plane.d.ts +19 -0
- package/dist/runner/lib/runner-plane.d.ts.map +1 -0
- package/dist/runner/lib/runner-plane.js +31 -0
- package/dist/runner/lib/runner-plane.js.map +1 -0
- package/dist/runner/lib/runner-registration.d.ts +60 -0
- package/dist/runner/lib/runner-registration.d.ts.map +1 -0
- package/dist/runner/lib/runner-registration.js +62 -0
- package/dist/runner/lib/runner-registration.js.map +1 -0
- package/dist/runner/lib/runner.d.ts +24 -0
- package/dist/runner/lib/runner.d.ts.map +1 -0
- package/dist/runner/lib/runner.js +26 -0
- package/dist/runner/lib/runner.js.map +1 -0
- package/dist/runner/lib/runtime-isolation.d.ts +10 -0
- package/dist/runner/lib/runtime-isolation.d.ts.map +1 -0
- package/dist/runner/lib/runtime-isolation.js +23 -0
- package/dist/runner/lib/runtime-isolation.js.map +1 -0
- package/dist/search-source/index.d.ts +5 -0
- package/dist/search-source/index.d.ts.map +1 -0
- package/dist/search-source/index.js +21 -0
- package/dist/search-source/index.js.map +1 -0
- package/dist/search-source/lib/indexable-document.d.ts +40 -0
- package/dist/search-source/lib/indexable-document.d.ts.map +1 -0
- package/dist/search-source/lib/indexable-document.js +26 -0
- package/dist/search-source/lib/indexable-document.js.map +1 -0
- package/dist/search-source/lib/search-index-event.d.ts +52 -0
- package/dist/search-source/lib/search-index-event.d.ts.map +1 -0
- package/dist/search-source/lib/search-index-event.js +29 -0
- package/dist/search-source/lib/search-index-event.js.map +1 -0
- package/dist/search-source/lib/search-replay.d.ts +46 -0
- package/dist/search-source/lib/search-replay.d.ts.map +1 -0
- package/dist/search-source/lib/search-replay.js +36 -0
- package/dist/search-source/lib/search-replay.js.map +1 -0
- package/dist/search-source/lib/search-source-descriptor.d.ts +15 -0
- package/dist/search-source/lib/search-source-descriptor.d.ts.map +1 -0
- package/dist/search-source/lib/search-source-descriptor.js +3 -0
- package/dist/search-source/lib/search-source-descriptor.js.map +1 -0
- package/dist/service-registry/index.d.ts +4 -0
- package/dist/service-registry/index.d.ts.map +1 -0
- package/dist/service-registry/index.js +20 -0
- package/dist/service-registry/index.js.map +1 -0
- package/dist/service-registry/lib/inject-service.d.ts +6 -0
- package/dist/service-registry/lib/inject-service.d.ts.map +1 -0
- package/dist/service-registry/lib/inject-service.js +5 -0
- package/dist/service-registry/lib/inject-service.js.map +1 -0
- package/dist/service-registry/lib/service-descriptor.d.ts +28 -0
- package/dist/service-registry/lib/service-descriptor.d.ts.map +1 -0
- package/dist/service-registry/lib/service-descriptor.js +17 -0
- package/dist/service-registry/lib/service-descriptor.js.map +1 -0
- package/dist/service-registry/lib/service-registry-client.d.ts +30 -0
- package/dist/service-registry/lib/service-registry-client.d.ts.map +1 -0
- package/dist/service-registry/lib/service-registry-client.js +3 -0
- package/dist/service-registry/lib/service-registry-client.js.map +1 -0
- package/dist/skill/index.d.ts +5 -0
- package/dist/skill/index.d.ts.map +1 -0
- package/dist/skill/index.js +21 -0
- package/dist/skill/index.js.map +1 -0
- package/dist/skill/lib/skill-enums.d.ts +41 -0
- package/dist/skill/lib/skill-enums.d.ts.map +1 -0
- package/dist/skill/lib/skill-enums.js +54 -0
- package/dist/skill/lib/skill-enums.js.map +1 -0
- package/dist/skill/lib/skill-governance.d.ts +106 -0
- package/dist/skill/lib/skill-governance.d.ts.map +1 -0
- package/dist/skill/lib/skill-governance.js +61 -0
- package/dist/skill/lib/skill-governance.js.map +1 -0
- package/dist/skill/lib/skill-source.d.ts +14 -0
- package/dist/skill/lib/skill-source.d.ts.map +1 -0
- package/dist/skill/lib/skill-source.js +3 -0
- package/dist/skill/lib/skill-source.js.map +1 -0
- package/dist/skill/lib/skill.d.ts +52 -0
- package/dist/skill/lib/skill.d.ts.map +1 -0
- package/dist/skill/lib/skill.js +3 -0
- package/dist/skill/lib/skill.js.map +1 -0
- package/dist/space/index.d.ts +4 -0
- package/dist/space/index.d.ts.map +1 -0
- package/dist/space/index.js +20 -0
- package/dist/space/index.js.map +1 -0
- package/dist/space/lib/space-ref-parser.d.ts +8 -0
- package/dist/space/lib/space-ref-parser.d.ts.map +1 -0
- package/dist/space/lib/space-ref-parser.js +149 -0
- package/dist/space/lib/space-ref-parser.js.map +1 -0
- package/dist/space/lib/space-traversal.d.ts +3 -0
- package/dist/space/lib/space-traversal.d.ts.map +1 -0
- package/dist/space/lib/space-traversal.js +56 -0
- package/dist/space/lib/space-traversal.js.map +1 -0
- package/dist/space/lib/space.d.ts +53 -0
- package/dist/space/lib/space.d.ts.map +1 -0
- package/dist/space/lib/space.js +98 -0
- package/dist/space/lib/space.js.map +1 -0
- package/dist/subject/index.d.ts +3 -0
- package/dist/subject/index.d.ts.map +1 -0
- package/dist/subject/index.js +19 -0
- package/dist/subject/index.js.map +1 -0
- package/dist/subject/lib/subject.d.ts +29 -0
- package/dist/subject/lib/subject.d.ts.map +1 -0
- package/dist/subject/lib/subject.js +47 -0
- package/dist/subject/lib/subject.js.map +1 -0
- package/dist/subject/lib/token-class.d.ts +11 -0
- package/dist/subject/lib/token-class.d.ts.map +1 -0
- package/dist/subject/lib/token-class.js +15 -0
- package/dist/subject/lib/token-class.js.map +1 -0
- package/dist/workflow/index.d.ts +31 -0
- package/dist/workflow/index.d.ts.map +1 -0
- package/dist/workflow/index.js +47 -0
- package/dist/workflow/index.js.map +1 -0
- package/dist/workflow/lib/action-ref.d.ts +12 -0
- package/dist/workflow/lib/action-ref.d.ts.map +1 -0
- package/dist/workflow/lib/action-ref.js +3 -0
- package/dist/workflow/lib/action-ref.js.map +1 -0
- package/dist/workflow/lib/activity-outputs.d.ts +14 -0
- package/dist/workflow/lib/activity-outputs.d.ts.map +1 -0
- package/dist/workflow/lib/activity-outputs.js +3 -0
- package/dist/workflow/lib/activity-outputs.js.map +1 -0
- package/dist/workflow/lib/agent-role.d.ts +6 -0
- package/dist/workflow/lib/agent-role.d.ts.map +1 -0
- package/dist/workflow/lib/agent-role.js +41 -0
- package/dist/workflow/lib/agent-role.js.map +1 -0
- package/dist/workflow/lib/artifact-ref.d.ts +21 -0
- package/dist/workflow/lib/artifact-ref.d.ts.map +1 -0
- package/dist/workflow/lib/artifact-ref.js +38 -0
- package/dist/workflow/lib/artifact-ref.js.map +1 -0
- package/dist/workflow/lib/briefcase.d.ts +107 -0
- package/dist/workflow/lib/briefcase.d.ts.map +1 -0
- package/dist/workflow/lib/briefcase.js +62 -0
- package/dist/workflow/lib/briefcase.js.map +1 -0
- package/dist/workflow/lib/canonical-concepts/canonical-concept-registry.d.ts +18 -0
- package/dist/workflow/lib/canonical-concepts/canonical-concept-registry.d.ts.map +1 -0
- package/dist/workflow/lib/canonical-concepts/canonical-concept-registry.js +45 -0
- package/dist/workflow/lib/canonical-concepts/canonical-concept-registry.js.map +1 -0
- package/dist/workflow/lib/canonical-concepts/concepts/change-intent.concepts.d.ts +3 -0
- package/dist/workflow/lib/canonical-concepts/concepts/change-intent.concepts.d.ts.map +1 -0
- package/dist/workflow/lib/canonical-concepts/concepts/change-intent.concepts.js +79 -0
- package/dist/workflow/lib/canonical-concepts/concepts/change-intent.concepts.js.map +1 -0
- package/dist/workflow/lib/canonical-concepts/concepts/concern.concepts.d.ts +3 -0
- package/dist/workflow/lib/canonical-concepts/concepts/concern.concepts.d.ts.map +1 -0
- package/dist/workflow/lib/canonical-concepts/concepts/concern.concepts.js +133 -0
- package/dist/workflow/lib/canonical-concepts/concepts/concern.concepts.js.map +1 -0
- package/dist/workflow/lib/canonical-concepts/concepts/domain.concepts.d.ts +3 -0
- package/dist/workflow/lib/canonical-concepts/concepts/domain.concepts.d.ts.map +1 -0
- package/dist/workflow/lib/canonical-concepts/concepts/domain.concepts.js +116 -0
- package/dist/workflow/lib/canonical-concepts/concepts/domain.concepts.js.map +1 -0
- package/dist/workflow/lib/canonical-concepts/concepts/index.d.ts +8 -0
- package/dist/workflow/lib/canonical-concepts/concepts/index.d.ts.map +1 -0
- package/dist/workflow/lib/canonical-concepts/concepts/index.js +18 -0
- package/dist/workflow/lib/canonical-concepts/concepts/index.js.map +1 -0
- package/dist/workflow/lib/canonical-concepts/concepts/technology.concepts.d.ts +3 -0
- package/dist/workflow/lib/canonical-concepts/concepts/technology.concepts.d.ts.map +1 -0
- package/dist/workflow/lib/canonical-concepts/concepts/technology.concepts.js +462 -0
- package/dist/workflow/lib/canonical-concepts/concepts/technology.concepts.js.map +1 -0
- package/dist/workflow/lib/canonical-concepts/index.d.ts +3 -0
- package/dist/workflow/lib/canonical-concepts/index.d.ts.map +1 -0
- package/dist/workflow/lib/canonical-concepts/index.js +16 -0
- package/dist/workflow/lib/canonical-concepts/index.js.map +1 -0
- package/dist/workflow/lib/catalog-taxonomies.d.ts +41 -0
- package/dist/workflow/lib/catalog-taxonomies.d.ts.map +1 -0
- package/dist/workflow/lib/catalog-taxonomies.js +3475 -0
- package/dist/workflow/lib/catalog-taxonomies.js.map +1 -0
- package/dist/workflow/lib/compiled-run.d.ts +118 -0
- package/dist/workflow/lib/compiled-run.d.ts.map +1 -0
- package/dist/workflow/lib/compiled-run.js +3 -0
- package/dist/workflow/lib/compiled-run.js.map +1 -0
- package/dist/workflow/lib/compiled-working-file.d.ts +11 -0
- package/dist/workflow/lib/compiled-working-file.d.ts.map +1 -0
- package/dist/workflow/lib/compiled-working-file.js +3 -0
- package/dist/workflow/lib/compiled-working-file.js.map +1 -0
- package/dist/workflow/lib/compiled-workspace-manifest.d.ts +101 -0
- package/dist/workflow/lib/compiled-workspace-manifest.d.ts.map +1 -0
- package/dist/workflow/lib/compiled-workspace-manifest.js +3 -0
- package/dist/workflow/lib/compiled-workspace-manifest.js.map +1 -0
- package/dist/workflow/lib/concurrency-group.d.ts +6 -0
- package/dist/workflow/lib/concurrency-group.d.ts.map +1 -0
- package/dist/workflow/lib/concurrency-group.js +3 -0
- package/dist/workflow/lib/concurrency-group.js.map +1 -0
- package/dist/workflow/lib/deliverable-result.d.ts +124 -0
- package/dist/workflow/lib/deliverable-result.d.ts.map +1 -0
- package/dist/workflow/lib/deliverable-result.js +27 -0
- package/dist/workflow/lib/deliverable-result.js.map +1 -0
- package/dist/workflow/lib/domain-tag.d.ts +2 -0
- package/dist/workflow/lib/domain-tag.d.ts.map +1 -0
- package/dist/workflow/lib/domain-tag.js +3 -0
- package/dist/workflow/lib/domain-tag.js.map +1 -0
- package/dist/workflow/lib/enums.d.ts +138 -0
- package/dist/workflow/lib/enums.d.ts.map +1 -0
- package/dist/workflow/lib/enums.js +166 -0
- package/dist/workflow/lib/enums.js.map +1 -0
- package/dist/workflow/lib/errors.d.ts +35 -0
- package/dist/workflow/lib/errors.d.ts.map +1 -0
- package/dist/workflow/lib/errors.js +62 -0
- package/dist/workflow/lib/errors.js.map +1 -0
- package/dist/workflow/lib/job-run.d.ts +32 -0
- package/dist/workflow/lib/job-run.d.ts.map +1 -0
- package/dist/workflow/lib/job-run.js +3 -0
- package/dist/workflow/lib/job-run.js.map +1 -0
- package/dist/workflow/lib/model-ref.d.ts +40 -0
- package/dist/workflow/lib/model-ref.d.ts.map +1 -0
- package/dist/workflow/lib/model-ref.js +34 -0
- package/dist/workflow/lib/model-ref.js.map +1 -0
- package/dist/workflow/lib/mount-plan.d.ts +105 -0
- package/dist/workflow/lib/mount-plan.d.ts.map +1 -0
- package/dist/workflow/lib/mount-plan.js +3 -0
- package/dist/workflow/lib/mount-plan.js.map +1 -0
- package/dist/workflow/lib/phase-report.d.ts +9 -0
- package/dist/workflow/lib/phase-report.d.ts.map +1 -0
- package/dist/workflow/lib/phase-report.js +30 -0
- package/dist/workflow/lib/phase-report.js.map +1 -0
- package/dist/workflow/lib/platform-task-queue.d.ts +17 -0
- package/dist/workflow/lib/platform-task-queue.d.ts.map +1 -0
- package/dist/workflow/lib/platform-task-queue.js +33 -0
- package/dist/workflow/lib/platform-task-queue.js.map +1 -0
- package/dist/workflow/lib/review-subject/index.d.ts +5 -0
- package/dist/workflow/lib/review-subject/index.d.ts.map +1 -0
- package/dist/workflow/lib/review-subject/index.js +8 -0
- package/dist/workflow/lib/review-subject/index.js.map +1 -0
- package/dist/workflow/lib/review-subject/kinds.d.ts +5 -0
- package/dist/workflow/lib/review-subject/kinds.d.ts.map +1 -0
- package/dist/workflow/lib/review-subject/kinds.js +9 -0
- package/dist/workflow/lib/review-subject/kinds.js.map +1 -0
- package/dist/workflow/lib/review-subject/narrow.d.ts +5 -0
- package/dist/workflow/lib/review-subject/narrow.d.ts.map +1 -0
- package/dist/workflow/lib/review-subject/narrow.js +79 -0
- package/dist/workflow/lib/review-subject/narrow.js.map +1 -0
- package/dist/workflow/lib/review-subject/producers/artifact-ref.d.ts +9 -0
- package/dist/workflow/lib/review-subject/producers/artifact-ref.d.ts.map +1 -0
- package/dist/workflow/lib/review-subject/producers/artifact-ref.js +16 -0
- package/dist/workflow/lib/review-subject/producers/artifact-ref.js.map +1 -0
- package/dist/workflow/lib/review-subject/producers/string.d.ts +7 -0
- package/dist/workflow/lib/review-subject/producers/string.d.ts.map +1 -0
- package/dist/workflow/lib/review-subject/producers/string.js +11 -0
- package/dist/workflow/lib/review-subject/producers/string.js.map +1 -0
- package/dist/workflow/lib/role-capability.d.ts +16 -0
- package/dist/workflow/lib/role-capability.d.ts.map +1 -0
- package/dist/workflow/lib/role-capability.js +19 -0
- package/dist/workflow/lib/role-capability.js.map +1 -0
- package/dist/workflow/lib/run-progress.d.ts +100 -0
- package/dist/workflow/lib/run-progress.d.ts.map +1 -0
- package/dist/workflow/lib/run-progress.js +96 -0
- package/dist/workflow/lib/run-progress.js.map +1 -0
- package/dist/workflow/lib/sampling-profiles.d.ts +18 -0
- package/dist/workflow/lib/sampling-profiles.d.ts.map +1 -0
- package/dist/workflow/lib/sampling-profiles.js +56 -0
- package/dist/workflow/lib/sampling-profiles.js.map +1 -0
- package/dist/workflow/lib/snapshot-ref.d.ts +10 -0
- package/dist/workflow/lib/snapshot-ref.d.ts.map +1 -0
- package/dist/workflow/lib/snapshot-ref.js +3 -0
- package/dist/workflow/lib/snapshot-ref.js.map +1 -0
- package/dist/workflow/lib/temporal-namespace.d.ts +5 -0
- package/dist/workflow/lib/temporal-namespace.d.ts.map +1 -0
- package/dist/workflow/lib/temporal-namespace.js +34 -0
- package/dist/workflow/lib/temporal-namespace.js.map +1 -0
- package/dist/workflow/lib/trigger-payload.d.ts +35 -0
- package/dist/workflow/lib/trigger-payload.d.ts.map +1 -0
- package/dist/workflow/lib/trigger-payload.js +3 -0
- package/dist/workflow/lib/trigger-payload.js.map +1 -0
- package/dist/workflow/lib/variable-requirement.d.ts +18 -0
- package/dist/workflow/lib/variable-requirement.d.ts.map +1 -0
- package/dist/workflow/lib/variable-requirement.js +3 -0
- package/dist/workflow/lib/variable-requirement.js.map +1 -0
- package/dist/workflow/lib/work-item-payloads.d.ts +114 -0
- package/dist/workflow/lib/work-item-payloads.d.ts.map +1 -0
- package/dist/workflow/lib/work-item-payloads.js +60 -0
- package/dist/workflow/lib/work-item-payloads.js.map +1 -0
- package/dist/workflow/lib/workflow-stage.d.ts +11 -0
- package/dist/workflow/lib/workflow-stage.d.ts.map +1 -0
- package/dist/workflow/lib/workflow-stage.js +28 -0
- package/dist/workflow/lib/workflow-stage.js.map +1 -0
- package/dist/workflow/lib/workspace-manifest-enums.d.ts +42 -0
- package/dist/workflow/lib/workspace-manifest-enums.d.ts.map +1 -0
- package/dist/workflow/lib/workspace-manifest-enums.js +80 -0
- package/dist/workflow/lib/workspace-manifest-enums.js.map +1 -0
- package/package.json +173 -0
- package/src/agent-composition/index.ts +17 -0
- package/src/agent-composition/lib/capability-layer.ts +46 -0
- package/src/agent-composition/lib/composition-limits-schema.ts +38 -0
- package/src/agent-composition/lib/composition-workspace.ts +210 -0
- package/src/agent-composition/lib/composition.ts +205 -0
- package/src/agent-composition/lib/intrinsic-floor.ts +50 -0
- package/src/agent-composition/lib/model-resolution-matrix.ts +112 -0
- package/src/agent-workspace/index.ts +27 -0
- package/src/agent-workspace/lib/agent-run-context.ts +44 -0
- package/src/agent-workspace/lib/agent-tool-defaults.ts +252 -0
- package/src/agent-workspace/lib/awp-v1.ts +289 -0
- package/src/agent-workspace/lib/context-json.ts +92 -0
- package/src/agent-workspace/lib/deliverable-spec-ref.ts +60 -0
- package/src/agent-workspace/lib/endpoint-fetch-spec.ts +66 -0
- package/src/agent-workspace/lib/manifest.ts +53 -0
- package/src/agent-workspace/lib/mount-apply.ts +79 -0
- package/src/agent-workspace/lib/working-file.ts +173 -0
- package/src/agent-workspace/lib/workspace-layout.ts +106 -0
- package/src/agent-workspace/lib/workspace-spec.ts +212 -0
- package/src/biome/index.ts +10 -0
- package/src/biome/lib/biome-api.ts +33 -0
- package/src/biome/lib/biome-capability-refs.ts +29 -0
- package/src/biome/lib/biome-engines.ts +18 -0
- package/src/biome/lib/biome-lifecycle-hooks.ts +28 -0
- package/src/biome/lib/biome-lifecycle.ts +29 -0
- package/src/biome/lib/biome-manifest.ts +102 -0
- package/src/biome/lib/biome-permissions.ts +35 -0
- package/src/biome/lib/biome-scope.ts +19 -0
- package/src/biome/lib/biome-trust-tier.ts +21 -0
- package/src/biome/lib/trust-tier-policies.ts +99 -0
- package/src/capability/index.ts +8 -0
- package/src/capability/lib/capability-contribution.ts +99 -0
- package/src/capability/lib/capability-grant.ts +90 -0
- package/src/capability/lib/capability-policy.ts +37 -0
- package/src/capability/lib/capability-ref.ts +138 -0
- package/src/capability/lib/errors.ts +180 -0
- package/src/capability/lib/meta-tool.ts +213 -0
- package/src/capability/lib/permission-profile.ts +91 -0
- package/src/capability/lib/shell-command-descriptor.ts +66 -0
- package/src/contribution/index.ts +4 -0
- package/src/contribution/lib/contribution-kind.ts +132 -0
- package/src/contribution/lib/contribution-source.ts +29 -0
- package/src/contribution/lib/contribution.ts +209 -0
- package/src/contribution/lib/registry.ts +100 -0
- package/src/document-templates/index.ts +24 -0
- package/src/document-templates/lib/document-template.ts +88 -0
- package/src/document-templates/lib/index.ts +2 -0
- package/src/document-templates/lib/rendering-shape.ts +48 -0
- package/src/document-themes/index.ts +21 -0
- package/src/document-themes/lib/component-vocabulary.ts +100 -0
- package/src/document-themes/lib/document-theme.ts +110 -0
- package/src/document-themes/lib/index.ts +2 -0
- package/src/entitlement/index.ts +1 -0
- package/src/entitlement/lib/entitlement.ts +142 -0
- package/src/execution-context/index.ts +3 -0
- package/src/execution-context/lib/caller.ts +46 -0
- package/src/execution-context/lib/execution-context.ts +205 -0
- package/src/execution-context/lib/subject.ts +17 -0
- package/src/execution-environment/index.ts +3 -0
- package/src/execution-environment/lib/approval-rule.ts +32 -0
- package/src/execution-environment/lib/built-in-environments.ts +89 -0
- package/src/execution-environment/lib/execution-environment.ts +266 -0
- package/src/kernel-state/index.ts +3 -0
- package/src/kernel-state/lib/adapter-kind.ts +18 -0
- package/src/kernel-state/lib/kernel-state.ts +139 -0
- package/src/kernel-state/lib/key-grammar.ts +105 -0
- package/src/llm-gateway/index.ts +2 -0
- package/src/llm-gateway/lib/caller.ts +48 -0
- package/src/llm-gateway/lib/errors.ts +111 -0
- package/src/mcp-tool/index.ts +6 -0
- package/src/mcp-tool/lib/mcp-protocol.ts +94 -0
- package/src/mcp-tool/lib/mcp-server-config.ts +17 -0
- package/src/mcp-tool/lib/provider-kind.ts +35 -0
- package/src/mcp-tool/lib/resolver-scope.ts +32 -0
- package/src/mcp-tool/lib/tool-provider.ts +62 -0
- package/src/mcp-tool/lib/tool-selection.ts +48 -0
- package/src/object/index.ts +4 -0
- package/src/object/lib/object-lifecycle.ts +22 -0
- package/src/object/lib/xema-object-kind.ts +73 -0
- package/src/object/lib/xema-object-ref.ts +233 -0
- package/src/object/lib/xema-object.ts +81 -0
- package/src/policy/index.ts +3 -0
- package/src/policy/lib/obligations.ts +155 -0
- package/src/policy/lib/policy.ts +104 -0
- package/src/policy/lib/route-hints.ts +51 -0
- package/src/runner/index.ts +11 -0
- package/src/runner/lib/dispatch.ts +61 -0
- package/src/runner/lib/input-hash.ts +66 -0
- package/src/runner/lib/job-token.ts +80 -0
- package/src/runner/lib/runner-attestation.ts +53 -0
- package/src/runner/lib/runner-job.ts +90 -0
- package/src/runner/lib/runner-kind.ts +10 -0
- package/src/runner/lib/runner-mode.ts +16 -0
- package/src/runner/lib/runner-plane.ts +101 -0
- package/src/runner/lib/runner-registration.ts +204 -0
- package/src/runner/lib/runner.ts +103 -0
- package/src/runner/lib/runtime-isolation.ts +53 -0
- package/src/search-source/index.ts +4 -0
- package/src/search-source/lib/indexable-document.ts +70 -0
- package/src/search-source/lib/search-index-event.ts +56 -0
- package/src/search-source/lib/search-replay.ts +96 -0
- package/src/search-source/lib/search-source-descriptor.ts +50 -0
- package/src/service-registry/index.ts +3 -0
- package/src/service-registry/lib/inject-service.ts +25 -0
- package/src/service-registry/lib/service-descriptor.ts +75 -0
- package/src/service-registry/lib/service-registry-client.ts +107 -0
- package/src/skill/index.ts +15 -0
- package/src/skill/lib/skill-enums.ts +124 -0
- package/src/skill/lib/skill-governance.ts +281 -0
- package/src/skill/lib/skill-source.ts +41 -0
- package/src/skill/lib/skill.ts +150 -0
- package/src/space/index.ts +3 -0
- package/src/space/lib/space-ref-parser.ts +198 -0
- package/src/space/lib/space-traversal.ts +55 -0
- package/src/space/lib/space.ts +173 -0
- package/src/subject/index.ts +2 -0
- package/src/subject/lib/subject.ts +111 -0
- package/src/subject/lib/token-class.ts +27 -0
- package/src/workflow/index.ts +45 -0
- package/src/workflow/lib/action-ref.ts +48 -0
- package/src/workflow/lib/activity-outputs.ts +105 -0
- package/src/workflow/lib/agent-role.ts +136 -0
- package/src/workflow/lib/artifact-ref.ts +93 -0
- package/src/workflow/lib/briefcase.ts +194 -0
- package/src/workflow/lib/canonical-concepts/canonical-concept-registry.ts +99 -0
- package/src/workflow/lib/canonical-concepts/concepts/change-intent.concepts.ts +124 -0
- package/src/workflow/lib/canonical-concepts/concepts/concern.concepts.ts +194 -0
- package/src/workflow/lib/canonical-concepts/concepts/domain.concepts.ts +205 -0
- package/src/workflow/lib/canonical-concepts/concepts/index.ts +15 -0
- package/src/workflow/lib/canonical-concepts/concepts/technology.concepts.ts +667 -0
- package/src/workflow/lib/canonical-concepts/index.ts +2 -0
- package/src/workflow/lib/catalog-taxonomies.ts +3695 -0
- package/src/workflow/lib/compiled-run.ts +376 -0
- package/src/workflow/lib/compiled-working-file.ts +35 -0
- package/src/workflow/lib/compiled-workspace-manifest.ts +185 -0
- package/src/workflow/lib/concurrency-group.ts +17 -0
- package/src/workflow/lib/deliverable-result.ts +238 -0
- package/src/workflow/lib/domain-tag.ts +48 -0
- package/src/workflow/lib/enums.ts +288 -0
- package/src/workflow/lib/errors.ts +171 -0
- package/src/workflow/lib/job-run.ts +65 -0
- package/src/workflow/lib/model-ref.ts +118 -0
- package/src/workflow/lib/mount-plan.ts +230 -0
- package/src/workflow/lib/phase-report.ts +67 -0
- package/src/workflow/lib/platform-task-queue.ts +83 -0
- package/src/workflow/lib/review-subject/index.ts +15 -0
- package/src/workflow/lib/review-subject/kinds.ts +31 -0
- package/src/workflow/lib/review-subject/narrow.ts +123 -0
- package/src/workflow/lib/review-subject/producers/artifact-ref.ts +33 -0
- package/src/workflow/lib/review-subject/producers/string.ts +24 -0
- package/src/workflow/lib/role-capability.ts +80 -0
- package/src/workflow/lib/run-progress.ts +254 -0
- package/src/workflow/lib/sampling-profiles.ts +153 -0
- package/src/workflow/lib/snapshot-ref.ts +27 -0
- package/src/workflow/lib/temporal-namespace.ts +78 -0
- package/src/workflow/lib/trigger-payload.ts +69 -0
- package/src/workflow/lib/variable-requirement.ts +66 -0
- package/src/workflow/lib/work-item-payloads.ts +139 -0
- package/src/workflow/lib/workflow-stage.ts +89 -0
- package/src/workflow/lib/workspace-manifest-enums.ts +143 -0
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── ActivityOutputs — the unified envelope shape every activity returns ──
|
|
3
|
+
//
|
|
4
|
+
// Under the unified model, every activity's Temporal return value has
|
|
5
|
+
// the same outer shape:
|
|
6
|
+
//
|
|
7
|
+
// {
|
|
8
|
+
// outcome: string, // orchestration flag — fail-fast values
|
|
9
|
+
// durationMs: number, // wall-clock execution time
|
|
10
|
+
// outputs: { name: ArtifactRef | ArtifactRef[] | null },
|
|
11
|
+
// ...activity-specific orchestration metadata,
|
|
12
|
+
// }
|
|
13
|
+
//
|
|
14
|
+
// `outputs` is the named, typed bag of artifacts the activity produced.
|
|
15
|
+
// Each entry is either a single `ArtifactRef`, an array (variadic, for
|
|
16
|
+
// activities like `agent` that emit N deliverables), or `null` (the
|
|
17
|
+
// output was conditionally absent).
|
|
18
|
+
//
|
|
19
|
+
// Activity authors do NOT construct ArtifactRefs themselves. They pass
|
|
20
|
+
// content + type to the `finalizeOutputs` helper (in
|
|
21
|
+
// `biomes/workflow-runtime/api/workflow-runtime-worker/src/activities/shared/finalize-outputs.ts`)
|
|
22
|
+
// which promotes content to artifacts via `workflow-artifact-emitter` and
|
|
23
|
+
// replaces the values with refs.
|
|
24
|
+
//
|
|
25
|
+
// Orchestration metadata (worker IDs, allocation status, page IDs, repo
|
|
26
|
+
// SHAs, etc.) stays on the envelope alongside `outputs`. The discipline
|
|
27
|
+
// is: anything reviewable goes in `outputs`; bookkeeping for `if:`
|
|
28
|
+
// clauses and gate logic stays at the top level.
|
|
29
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
30
|
+
|
|
31
|
+
import type { ArtifactRef } from './artifact-ref';
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* The named-outputs bag. Each value is one of:
|
|
35
|
+
* • `ArtifactRef` — a single artifact
|
|
36
|
+
* • `readonly ArtifactRef[]` — variadic / array outputs (e.g. harvested
|
|
37
|
+
* deliverables, multiple endpoint fetches)
|
|
38
|
+
* • `null` — the output was conditionally absent at this run (e.g. the
|
|
39
|
+
* agent produced no structured payload). Distinguish from "missing
|
|
40
|
+
* key" — declared-but-null is a deliberate signal.
|
|
41
|
+
*
|
|
42
|
+
* Generic over the output-key map so per-activity envelopes can have
|
|
43
|
+
* typed access (`AgentActivityOutput['outputs']['response']` resolves to
|
|
44
|
+
* `ArtifactRef` precisely).
|
|
45
|
+
*/
|
|
46
|
+
export type ActivityOutputsMap = Readonly<
|
|
47
|
+
Record<string, ArtifactRef | readonly ArtifactRef[] | null>
|
|
48
|
+
>;
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* Base shape every activity envelope extends. Activity-specific types
|
|
52
|
+
* (`AgentActivityOutput`, `PublishKbActivityOutput`, …) declare their
|
|
53
|
+
* `outputs` field with a precise per-output map and add orchestration
|
|
54
|
+
* metadata as siblings.
|
|
55
|
+
*
|
|
56
|
+
* NOT a strict superset — the `outputs` field is required even when
|
|
57
|
+
* empty (use `outputs: {}`). The "no outputs" case is an explicit choice,
|
|
58
|
+
* not an omission, so consumers can trust the shape.
|
|
59
|
+
*/
|
|
60
|
+
export interface ActivityEnvelope {
|
|
61
|
+
/**
|
|
62
|
+
* Closed-set orchestration flag. Each activity declares its own enum
|
|
63
|
+
* of valid outcomes (`'succeeded' | 'empty-response' | 'partial'` for
|
|
64
|
+
* agent, `'ok' | 'noop' | 'error'` for others). The base type uses
|
|
65
|
+
* `string` so the enum stays activity-local — the DSL compiler
|
|
66
|
+
* validates `if:` clauses against the per-activity outcome set.
|
|
67
|
+
*/
|
|
68
|
+
readonly outcome: string;
|
|
69
|
+
readonly durationMs: number;
|
|
70
|
+
readonly outputs: ActivityOutputsMap;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* Activity-level declaration of an output's contract. Used by:
|
|
75
|
+
* • the DSL compiler to type-check `${{ needs.X.outputs.Y }}` and the
|
|
76
|
+
* reach-in accessors (positional, byKey, payload-field);
|
|
77
|
+
* • `finalizeOutputs` to pick the producer kind + versioning mode + slug;
|
|
78
|
+
* • the FE Run Detail's Job Inspector to label each output row.
|
|
79
|
+
*
|
|
80
|
+
* Each activity ships a static `OUTPUT_DECLARATIONS` map of these,
|
|
81
|
+
* authored alongside the activity code.
|
|
82
|
+
*/
|
|
83
|
+
export interface ActivityOutputDeclaration {
|
|
84
|
+
/** The output's stable name on the envelope. */
|
|
85
|
+
readonly name: string;
|
|
86
|
+
/** Closed `OutputKind` enum value (or biome-extension string). */
|
|
87
|
+
readonly type: string;
|
|
88
|
+
/** When `true`, the output is `readonly ArtifactRef[]` (variadic). */
|
|
89
|
+
readonly array?: boolean;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
// NOTE: per-output deliverable-spec bindings live on the action
|
|
93
|
+
// MANIFEST (`spec.outputBindings`, see `ActionManifestSpec` in
|
|
94
|
+
// `@xemahq/workflow-dsl`) — that's the single source of truth the DSL
|
|
95
|
+
// compiler reads at compile time. `OUTPUT_DECLARATIONS` is a worker-
|
|
96
|
+
// internal contract used by the output-promotion wrapper, so binding
|
|
97
|
+
// metadata never has to flow through it.
|
|
98
|
+
|
|
99
|
+
/**
|
|
100
|
+
* Static declaration map an activity exports — keyed by output name.
|
|
101
|
+
* Frozen at module load; the activity's runtime cannot mutate it.
|
|
102
|
+
*/
|
|
103
|
+
export type ActivityOutputDeclarations = Readonly<
|
|
104
|
+
Record<string, ActivityOutputDeclaration>
|
|
105
|
+
>;
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── Canonical AgentRunRole ──
|
|
3
|
+
//
|
|
4
|
+
// Single source of truth for the role an agent invocation takes. Every
|
|
5
|
+
// downstream consumer — kernel composer, agent-session-runtime, worker
|
|
6
|
+
// activity, agent-session-api, llm-registry-api API DTO,
|
|
7
|
+
// workspace-manifest-dsl Zod schema, AGENTS.md template registry, and
|
|
8
|
+
// the opencode-xema-plugin context reader — imports from here.
|
|
9
|
+
//
|
|
10
|
+
// `workflow-contracts` is intentionally runtime-dep-free, so this module
|
|
11
|
+
// exports a `const` array + derived type. Validators that need a Zod
|
|
12
|
+
// enum (manifest schema) or a class-validator allow-list (NestJS DTO)
|
|
13
|
+
// wrap `AGENT_RUN_ROLES` themselves; the values stay canonical.
|
|
14
|
+
//
|
|
15
|
+
// Adding a role:
|
|
16
|
+
// 1. Append to `AGENT_RUN_ROLES`.
|
|
17
|
+
// 2. If the role is interactive-only or pipeline-only, register it in
|
|
18
|
+
// either `AGENT_RUN_ROLES_INTERACTIVE` or `AGENT_RUN_ROLES_PIPELINE`
|
|
19
|
+
// below — the surface guard in `agent-run-context.service.ts` reads
|
|
20
|
+
// these to reject mismatched manifests.
|
|
21
|
+
// 3. The role-specific mission prose comes from the agent's own
|
|
22
|
+
// `<slug>.md` body (resolved via `ResolveFullService`); no
|
|
23
|
+
// handlebars template registry exists. AGENTS.md is composed
|
|
24
|
+
// programmatically by `composeAgentsMd` from the resolved body +
|
|
25
|
+
// declared mounts + deliverable spec.
|
|
26
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* Canonical role values. Closed list. New roles MUST be added here
|
|
30
|
+
* first; downstream consumers extend their case-handling from this
|
|
31
|
+
* array.
|
|
32
|
+
*
|
|
33
|
+
* Naming convention: kebab-case strings that read as "what kind of
|
|
34
|
+
* worker is running". Pipeline workers have role names matching their
|
|
35
|
+
* domain (`engineer`, `auditor`, `coordinator`, …). Interactive
|
|
36
|
+
* surfaces have role names matching their context (`agent-session`,
|
|
37
|
+
* `design-system-builder`).
|
|
38
|
+
*/
|
|
39
|
+
export const AGENT_RUN_ROLES = [
|
|
40
|
+
/** Pipeline executor producing deliverables under a builder template. */
|
|
41
|
+
'unit-worker',
|
|
42
|
+
/** Pipeline coordinator merging unit outputs / authoring system-wide pages. */
|
|
43
|
+
'coordinator',
|
|
44
|
+
/** Pipeline gate-reviewer producing pass/fail verdicts; read-only authority. */
|
|
45
|
+
'gate-reviewer',
|
|
46
|
+
/** Pre-pipeline clarification phase that turns raw requests into typed handoff packages. */
|
|
47
|
+
'clarification-coordinator',
|
|
48
|
+
/** Validates whether an upstream output stays inside an envelope; read-only. */
|
|
49
|
+
'scope-validator',
|
|
50
|
+
/** Free-chat session bound to a primary agent (default `session` profile). */
|
|
51
|
+
'agent-session',
|
|
52
|
+
/** Design System Builder session — design canvas, no pipeline retry/manifest concepts. */
|
|
53
|
+
'design-system-builder',
|
|
54
|
+
/** User-defined pipeline agent that doesn't fit the closed catalogue. */
|
|
55
|
+
'generic-agent',
|
|
56
|
+
/** Repo audit role — read-only scanner. */
|
|
57
|
+
'auditor',
|
|
58
|
+
/** Engineer producing code + PRs (auto-remediation pipelines). */
|
|
59
|
+
'engineer',
|
|
60
|
+
/**
|
|
61
|
+
* Studio chat-author. Read-only authoring co-pilot bound to the
|
|
62
|
+
* `studio-{workflow|manifest|spec}-author` workspace manifests
|
|
63
|
+
* shipped by `biomes/kernel/studio-author`. The agent emits typed
|
|
64
|
+
* proposals only — apply goes through the standard write APIs on
|
|
65
|
+
* user confirmation. Interactive surface; never runs in a pipeline.
|
|
66
|
+
*/
|
|
67
|
+
'studio-author',
|
|
68
|
+
/**
|
|
69
|
+
* Webapp Studio session — live-coded Next.js / Vite SPA inside the
|
|
70
|
+
* project's attached repo. Planner-only `webapp-coordinator` agent
|
|
71
|
+
* orchestrates scaffolder + page-builder + data-builder sub-agents.
|
|
72
|
+
* Interactive surface; never runs in a pipeline. Bound to the
|
|
73
|
+
* `webapp-studio-default` workspace manifest shipped by
|
|
74
|
+
* `biomes/platform/webapp-studio`.
|
|
75
|
+
*/
|
|
76
|
+
'webapp-studio',
|
|
77
|
+
/**
|
|
78
|
+
* Document Buddy session — agent authors a single knowledge-base
|
|
79
|
+
* document page (MARKDOWN_DOCUMENT or RICH_DOCUMENT) by editing a
|
|
80
|
+
* real working file at `/workspace/document/<slug>.<ext>` natively;
|
|
81
|
+
* workspace-proxy's document-sync component derives the reviewable
|
|
82
|
+
* diff and persists it to knowledge-base-api. Interactive surface;
|
|
83
|
+
* never runs in a pipeline. Bound to the `document-md-default` /
|
|
84
|
+
* `document-rich-default` workspace manifests shipped by
|
|
85
|
+
* `biomes/platform/document-buddy`.
|
|
86
|
+
*/
|
|
87
|
+
'document',
|
|
88
|
+
] as const;
|
|
89
|
+
|
|
90
|
+
/**
|
|
91
|
+
* Discriminated string literal type derived from {@link AGENT_RUN_ROLES}.
|
|
92
|
+
* Adding a value to that array automatically extends this type;
|
|
93
|
+
* removing a value forces every consumer to handle the deletion at
|
|
94
|
+
* compile time.
|
|
95
|
+
*/
|
|
96
|
+
export type AgentRunRole = (typeof AGENT_RUN_ROLES)[number];
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* Subset of {@link AGENT_RUN_ROLES} that may run on an interactive
|
|
100
|
+
* (chat-driven) surface. The renderer's surface guard rejects any
|
|
101
|
+
* role outside this set when the surface is `agent-session` /
|
|
102
|
+
* `design-system-builder`. Mirrored on the pipeline side by
|
|
103
|
+
* {@link AGENT_RUN_ROLES_PIPELINE}.
|
|
104
|
+
*/
|
|
105
|
+
export const AGENT_RUN_ROLES_INTERACTIVE = [
|
|
106
|
+
'agent-session',
|
|
107
|
+
'design-system-builder',
|
|
108
|
+
'studio-author',
|
|
109
|
+
'webapp-studio',
|
|
110
|
+
'document',
|
|
111
|
+
] as const satisfies ReadonlyArray<AgentRunRole>;
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* Subset of {@link AGENT_RUN_ROLES} valid on the pipeline (workflow
|
|
115
|
+
* run / activity-driven) surface.
|
|
116
|
+
*/
|
|
117
|
+
export const AGENT_RUN_ROLES_PIPELINE = [
|
|
118
|
+
'unit-worker',
|
|
119
|
+
'coordinator',
|
|
120
|
+
'gate-reviewer',
|
|
121
|
+
'clarification-coordinator',
|
|
122
|
+
'scope-validator',
|
|
123
|
+
'generic-agent',
|
|
124
|
+
'auditor',
|
|
125
|
+
'engineer',
|
|
126
|
+
] as const satisfies ReadonlyArray<AgentRunRole>;
|
|
127
|
+
|
|
128
|
+
/**
|
|
129
|
+
* Runtime guard: is `value` one of the canonical roles?
|
|
130
|
+
*/
|
|
131
|
+
export function isAgentRunRole(value: unknown): value is AgentRunRole {
|
|
132
|
+
return (
|
|
133
|
+
typeof value === 'string' &&
|
|
134
|
+
(AGENT_RUN_ROLES as ReadonlyArray<string>).includes(value)
|
|
135
|
+
);
|
|
136
|
+
}
|
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── ArtifactRef — the universal cross-step reference to an artifact ──
|
|
3
|
+
//
|
|
4
|
+
// Under the unified outputs/deliverables/artifacts model, every named
|
|
5
|
+
// output of every activity is an `ArtifactRef`. Activities never carry
|
|
6
|
+
// reviewable bytes inline; the bytes live in artifact-store, the envelope
|
|
7
|
+
// carries refs. Downstream activities consume refs (and fetch bytes when
|
|
8
|
+
// they need them), the FE renders refs uniformly via OutputCard, the DSL
|
|
9
|
+
// supports typed reach-in and `fromJSON` against refs.
|
|
10
|
+
//
|
|
11
|
+
// Shape is intentionally minimal — everything else (size, content-type,
|
|
12
|
+
// pointer, payload) is fetched from artifact-store on demand and cached
|
|
13
|
+
// per `versionId`.
|
|
14
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
15
|
+
|
|
16
|
+
import { z } from 'zod';
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* Stable cross-step pointer to a single artifact version. The fields are
|
|
20
|
+
* sufficient to:
|
|
21
|
+
* • render the artifact via OutputCard (no extra metadata required for
|
|
22
|
+
* the chrome — `type` drives the renderer pick, `title` is the label,
|
|
23
|
+
* `version` is shown in the version selector);
|
|
24
|
+
* • pin a review (`{artifactId, versionId, version, hash}` is the
|
|
25
|
+
* existing `PinnedSubjectArtifact` shape — ArtifactRef is the
|
|
26
|
+
* producer-side superset);
|
|
27
|
+
* • fetch bytes on demand from artifact-store via `versionId`.
|
|
28
|
+
*
|
|
29
|
+
* `type` is the OutputKind string (or a biome-shipped extension). It is
|
|
30
|
+
* the routing key for renderer dispatch on the FE. Keep it as a string
|
|
31
|
+
* here so biome-defined kinds don't require kernel changes — the closed
|
|
32
|
+
* enum on the consumer side (`OutputKind`) gates the built-in renderers.
|
|
33
|
+
*/
|
|
34
|
+
export interface ArtifactRef {
|
|
35
|
+
readonly artifactId: string;
|
|
36
|
+
readonly versionId: string;
|
|
37
|
+
readonly version: number;
|
|
38
|
+
readonly hash: string;
|
|
39
|
+
readonly type: string;
|
|
40
|
+
readonly title?: string;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export const ArtifactRefSchema = z.object({
|
|
44
|
+
artifactId: z.string().min(1),
|
|
45
|
+
versionId: z.string().min(1),
|
|
46
|
+
version: z.number().int().nonnegative(),
|
|
47
|
+
hash: z.string().min(1),
|
|
48
|
+
type: z.string().min(1),
|
|
49
|
+
title: z.string().optional(),
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
/**
|
|
53
|
+
* Structural narrower used by the review-subject taxonomy and DSL runtime.
|
|
54
|
+
* Returns `true` when a value matches the ArtifactRef shape. Deliberately
|
|
55
|
+
* a runtime check (not just a type guard) — the wire receives `unknown`,
|
|
56
|
+
* and the kernel is the single boundary where we decide what's a ref.
|
|
57
|
+
*/
|
|
58
|
+
export function isArtifactRef(value: unknown): value is ArtifactRef {
|
|
59
|
+
if (value === null || typeof value !== 'object') {
|
|
60
|
+
return false;
|
|
61
|
+
}
|
|
62
|
+
const rec = value as Record<string, unknown>;
|
|
63
|
+
return (
|
|
64
|
+
typeof rec.artifactId === 'string' &&
|
|
65
|
+
typeof rec.versionId === 'string' &&
|
|
66
|
+
typeof rec.version === 'number' &&
|
|
67
|
+
Number.isInteger(rec.version) &&
|
|
68
|
+
typeof rec.hash === 'string' &&
|
|
69
|
+
typeof rec.type === 'string'
|
|
70
|
+
);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* Closed set of `ArtifactRef` member names — i.e. the fields a DSL
|
|
75
|
+
* expression `outputs.<name>.<field>` can read directly off the
|
|
76
|
+
* envelope without fetching artifact bytes. Anything else is treated
|
|
77
|
+
* as a payload-reach-in by the DSL compiler (§C.1).
|
|
78
|
+
*
|
|
79
|
+
* Kept here so the DSL compiler, the worker evaluator, and any future
|
|
80
|
+
* static-analysis tools share one source of truth.
|
|
81
|
+
*/
|
|
82
|
+
export const ARTIFACT_REF_ENVELOPE_FIELDS = Object.freeze([
|
|
83
|
+
'artifactId',
|
|
84
|
+
'versionId',
|
|
85
|
+
'version',
|
|
86
|
+
'hash',
|
|
87
|
+
'type',
|
|
88
|
+
'title',
|
|
89
|
+
]) as readonly (keyof ArtifactRef)[];
|
|
90
|
+
|
|
91
|
+
export function isArtifactRefEnvelopeField(name: string): boolean {
|
|
92
|
+
return (ARTIFACT_REF_ENVELOPE_FIELDS as readonly string[]).includes(name);
|
|
93
|
+
}
|
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── Briefcase — run-scoped ephemeral context object ──
|
|
3
|
+
//
|
|
4
|
+
// Every workflow run carries exactly one Briefcase. It is synthesized at
|
|
5
|
+
// dispatch time from the dispatch request body and propagated to every
|
|
6
|
+
// activity / child-workflow via `ActionBaseInput.briefcase`. Discarded
|
|
7
|
+
// when the run terminates.
|
|
8
|
+
//
|
|
9
|
+
// Purpose:
|
|
10
|
+
// - Replace ad-hoc `inputs.uploads[]` / `inputs.references[]` shapes
|
|
11
|
+
// that today's workflows declare-by-convention. Workflows authored
|
|
12
|
+
// against the Briefcase don't need to plumb those fields through.
|
|
13
|
+
// - Give non-agent activities (endpoint-fetch, validate-deliverables,
|
|
14
|
+
// publish-kb, custom transforms) a uniform way to read run-scoped
|
|
15
|
+
// context without each rolling its own input schema.
|
|
16
|
+
// - Give the agent-activity workspace composer a single source for
|
|
17
|
+
// uploads + references to merge into AWP-aligned mount entries.
|
|
18
|
+
//
|
|
19
|
+
// Distinct from workspace manifests:
|
|
20
|
+
// A workspace manifest declares the SHAPE of an agent's workspace
|
|
21
|
+
// (AWP slots, tools available, permissions) — static, agent-bound.
|
|
22
|
+
// A Briefcase carries the CONTENTS for one specific run (the actual
|
|
23
|
+
// uploads, references, vars) — dynamic, run-bound.
|
|
24
|
+
//
|
|
25
|
+
// Lifecycle (intentional non-features):
|
|
26
|
+
// - NOT persisted as a standalone entity (no briefcase-api service).
|
|
27
|
+
// - NOT versioned (briefcases are run-scoped; the run is the version).
|
|
28
|
+
// - NOT a library (no reuse across runs; pre-curated context would
|
|
29
|
+
// live as a biome-shipped seed of dispatch inputs, not here).
|
|
30
|
+
// - NOT biome-contributed.
|
|
31
|
+
//
|
|
32
|
+
// Every slot is OPTIONAL — activities that don't need a slot simply
|
|
33
|
+
// don't read it. An entirely empty Briefcase (`{}`) is a valid value.
|
|
34
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
35
|
+
|
|
36
|
+
import { z } from 'zod';
|
|
37
|
+
|
|
38
|
+
import { ArtifactRefSchema, type ArtifactRef } from './artifact-ref';
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* A file uploaded at dispatch (or promoted from design-system-builder). By the
|
|
42
|
+
* time the engine carries it on the Briefcase the bytes are already in
|
|
43
|
+
* artifact-store-api and the upload is just a typed reference.
|
|
44
|
+
*
|
|
45
|
+
* `filename` is the user-supplied display name (preserved end-to-end so
|
|
46
|
+
* agents see meaningful paths under `inputs/uploads/<filename>`).
|
|
47
|
+
* `contentType` is captured for downstream activities that need to
|
|
48
|
+
* route on MIME type (e.g. a transform that only operates on images).
|
|
49
|
+
*/
|
|
50
|
+
export interface BriefcaseUpload {
|
|
51
|
+
readonly artifact: ArtifactRef;
|
|
52
|
+
readonly filename: string;
|
|
53
|
+
readonly contentType: string | null;
|
|
54
|
+
readonly sizeBytes: number;
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export const BriefcaseUploadSchema = z.object({
|
|
58
|
+
artifact: ArtifactRefSchema,
|
|
59
|
+
filename: z.string().min(1).max(512),
|
|
60
|
+
contentType: z.string().min(1).max(256).nullable(),
|
|
61
|
+
sizeBytes: z.number().int().nonnegative(),
|
|
62
|
+
});
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Tagged pointer to platform content the run should consider
|
|
66
|
+
* authoritative. The kind narrows the resolution path:
|
|
67
|
+
* - `kb_page` → knowledge-base-api page
|
|
68
|
+
* - `kb_space` → knowledge-base-api space slug
|
|
69
|
+
* - `artifact` → existing artifact in artifact-store-api
|
|
70
|
+
* - `scm_repo` → repo at a specific ref (commit-pinned)
|
|
71
|
+
* - `external_url` → external link (fetched only if an activity
|
|
72
|
+
* explicitly asks; agents see the URL string).
|
|
73
|
+
*
|
|
74
|
+
* The discriminator is open-ended-but-typed: new reference kinds can
|
|
75
|
+
* be added without changing every consumer (they fall back to ignoring
|
|
76
|
+
* unknown kinds; the agent activity will skip them silently). New
|
|
77
|
+
* kinds MUST land in this enum and the validating schema below.
|
|
78
|
+
*/
|
|
79
|
+
export const BriefcaseReferenceKind = {
|
|
80
|
+
KB_PAGE: 'kb_page',
|
|
81
|
+
KB_SPACE: 'kb_space',
|
|
82
|
+
ARTIFACT: 'artifact',
|
|
83
|
+
SCM_REPO: 'scm_repo',
|
|
84
|
+
EXTERNAL_URL: 'external_url',
|
|
85
|
+
} as const;
|
|
86
|
+
export type BriefcaseReferenceKind =
|
|
87
|
+
(typeof BriefcaseReferenceKind)[keyof typeof BriefcaseReferenceKind];
|
|
88
|
+
|
|
89
|
+
export interface BriefcaseReference {
|
|
90
|
+
readonly kind: BriefcaseReferenceKind;
|
|
91
|
+
/**
|
|
92
|
+
* Opaque reference target. For `kb_page` this is the page slug; for
|
|
93
|
+
* `kb_space` the space slug; for `artifact` the artifact id; for
|
|
94
|
+
* `scm_repo` it's a `repoSlug@ref` string; for `external_url` it's
|
|
95
|
+
* the URL. Closed-set on the kind, open-string for the value.
|
|
96
|
+
*/
|
|
97
|
+
readonly ref: string;
|
|
98
|
+
/** Optional human-facing label (mostly for run-detail rendering). */
|
|
99
|
+
readonly title: string | null;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export const BriefcaseReferenceSchema = z.object({
|
|
103
|
+
kind: z.enum([
|
|
104
|
+
BriefcaseReferenceKind.KB_PAGE,
|
|
105
|
+
BriefcaseReferenceKind.KB_SPACE,
|
|
106
|
+
BriefcaseReferenceKind.ARTIFACT,
|
|
107
|
+
BriefcaseReferenceKind.SCM_REPO,
|
|
108
|
+
BriefcaseReferenceKind.EXTERNAL_URL,
|
|
109
|
+
]),
|
|
110
|
+
ref: z.string().min(1).max(2048),
|
|
111
|
+
title: z.string().min(1).max(512).nullable(),
|
|
112
|
+
});
|
|
113
|
+
|
|
114
|
+
/**
|
|
115
|
+
* Per-run MCP tool selections that augment whatever the agent's
|
|
116
|
+
* workspace manifest already declares for this run. Union with the
|
|
117
|
+
* job's own `with.tools[]` — never narrows. Activities that talk to
|
|
118
|
+
* the MCP gateway see these via the shared helper's `getMcpTools`.
|
|
119
|
+
*
|
|
120
|
+
* Shape mirrors `ToolSelectionEntry` from `@xemahq/mcp-tool-contracts`
|
|
121
|
+
* but is duplicated here to avoid a new cross-package dep on the
|
|
122
|
+
* workflow-contracts side. The platform-common helper validates with
|
|
123
|
+
* the canonical schema at consumption time.
|
|
124
|
+
*/
|
|
125
|
+
export interface BriefcaseMcpTool {
|
|
126
|
+
readonly kind: 'provider' | 'tool';
|
|
127
|
+
readonly providerKind: string;
|
|
128
|
+
readonly resourceId: string;
|
|
129
|
+
readonly toolName?: string;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
export const BriefcaseMcpToolSchema = z.discriminatedUnion('kind', [
|
|
133
|
+
z.object({
|
|
134
|
+
kind: z.literal('provider'),
|
|
135
|
+
providerKind: z.string().min(1).max(64),
|
|
136
|
+
resourceId: z.string().min(1).max(256),
|
|
137
|
+
}),
|
|
138
|
+
z.object({
|
|
139
|
+
kind: z.literal('tool'),
|
|
140
|
+
providerKind: z.string().min(1).max(64),
|
|
141
|
+
resourceId: z.string().min(1).max(256),
|
|
142
|
+
toolName: z.string().min(1).max(256),
|
|
143
|
+
}),
|
|
144
|
+
]);
|
|
145
|
+
|
|
146
|
+
/**
|
|
147
|
+
* The Briefcase itself. Every field is optional / may be empty; an
|
|
148
|
+
* empty Briefcase is a valid value and means "the dispatcher had
|
|
149
|
+
* nothing extra to attach". The activity decides what it needs.
|
|
150
|
+
*
|
|
151
|
+
* `vars` carries free-form string KV — useful for run-scoped facts
|
|
152
|
+
* like `designSystemVersion`, `kbSpaceSlug`, `targetEnvironment`.
|
|
153
|
+
* NOT a substitute for workflow-level `vars:` (which is the right
|
|
154
|
+
* home for fixed config the YAML author owns) or for run-wide
|
|
155
|
+
* identifiers (orgId / projectId / runId — those live on the run
|
|
156
|
+
* record + `ActionContext`, never duplicated here).
|
|
157
|
+
*/
|
|
158
|
+
export interface Briefcase {
|
|
159
|
+
readonly vars: Readonly<Record<string, string>>;
|
|
160
|
+
readonly uploads: readonly BriefcaseUpload[];
|
|
161
|
+
readonly references: readonly BriefcaseReference[];
|
|
162
|
+
readonly mcpTools: readonly BriefcaseMcpTool[];
|
|
163
|
+
}
|
|
164
|
+
|
|
165
|
+
export const BriefcaseSchema = z.object({
|
|
166
|
+
vars: z.record(z.string(), z.string().max(8_192)),
|
|
167
|
+
uploads: z.array(BriefcaseUploadSchema).max(256),
|
|
168
|
+
references: z.array(BriefcaseReferenceSchema).max(256),
|
|
169
|
+
mcpTools: z.array(BriefcaseMcpToolSchema).max(64),
|
|
170
|
+
});
|
|
171
|
+
|
|
172
|
+
/**
|
|
173
|
+
* Helper to construct an empty Briefcase. Use it instead of `{}` so the
|
|
174
|
+
* field structure stays consistent and future Briefcase fields default
|
|
175
|
+
* to their empty form without every consumer chasing the change.
|
|
176
|
+
*/
|
|
177
|
+
export function emptyBriefcase(): Briefcase {
|
|
178
|
+
return { vars: {}, uploads: [], references: [], mcpTools: [] };
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* Structural check — `true` when every Briefcase field is empty. Used
|
|
183
|
+
* by the engine to skip carrying a no-op briefcase through Temporal
|
|
184
|
+
* history (small but meaningful payload-size optimization).
|
|
185
|
+
*/
|
|
186
|
+
export function isEmptyBriefcase(briefcase: Briefcase | undefined): boolean {
|
|
187
|
+
if (!briefcase) return true;
|
|
188
|
+
return (
|
|
189
|
+
Object.keys(briefcase.vars).length === 0 &&
|
|
190
|
+
briefcase.uploads.length === 0 &&
|
|
191
|
+
briefcase.references.length === 0 &&
|
|
192
|
+
briefcase.mcpTools.length === 0
|
|
193
|
+
);
|
|
194
|
+
}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CanonicalConceptRegistry — machine-owned semantic normalization layer.
|
|
3
|
+
*
|
|
4
|
+
* Maps raw project context (tech stack items, change descriptions, concerns)
|
|
5
|
+
* to canonical concept keys used by the skill selection algorithm.
|
|
6
|
+
*
|
|
7
|
+
* Skills stay clean (OpenCode-style markdown). This registry handles the
|
|
8
|
+
* messy alias resolution so skills don't need to encode every variant.
|
|
9
|
+
*
|
|
10
|
+
* Concept data lives in per-kind files under ./concepts/ for scalability.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
14
|
+
// ── Enums & Types ──
|
|
15
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
16
|
+
|
|
17
|
+
export enum ConceptKind {
|
|
18
|
+
Technology = 'technology',
|
|
19
|
+
Concern = 'concern',
|
|
20
|
+
ChangeIntent = 'change_intent',
|
|
21
|
+
Domain = 'domain',
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export interface CanonicalConcept {
|
|
25
|
+
key: string;
|
|
26
|
+
aliases: string[];
|
|
27
|
+
parents?: string[];
|
|
28
|
+
related?: string[];
|
|
29
|
+
kind: ConceptKind;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
33
|
+
// ── Registry Data (loaded from per-kind concept files) ──
|
|
34
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
35
|
+
|
|
36
|
+
import { ALL_CONCEPTS } from './concepts';
|
|
37
|
+
|
|
38
|
+
const CONCEPTS: CanonicalConcept[] = ALL_CONCEPTS;
|
|
39
|
+
|
|
40
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
41
|
+
// ── Lookup Index ──
|
|
42
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
43
|
+
|
|
44
|
+
/** Alias → canonical concept key lookup. Built once at module init. */
|
|
45
|
+
const ALIAS_INDEX: Map<string, CanonicalConcept> = new Map();
|
|
46
|
+
|
|
47
|
+
for (const concept of CONCEPTS) {
|
|
48
|
+
// Index the canonical key itself
|
|
49
|
+
ALIAS_INDEX.set(concept.key, concept);
|
|
50
|
+
// Index all aliases
|
|
51
|
+
for (const alias of concept.aliases) {
|
|
52
|
+
ALIAS_INDEX.set(alias.toLowerCase(), concept);
|
|
53
|
+
}
|
|
54
|
+
// Index parent concepts as aliases pointing to themselves if not already registered
|
|
55
|
+
if (concept.parents) {
|
|
56
|
+
for (const parent of concept.parents) {
|
|
57
|
+
if (!ALIAS_INDEX.has(parent)) {
|
|
58
|
+
// Parent concept exists but may not have its own entry — skip (no silent creation)
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
65
|
+
// ── Public API ──
|
|
66
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* Resolve a raw term to its canonical concept, or null if not recognized.
|
|
70
|
+
*/
|
|
71
|
+
export function resolveCanonicalConcept(raw: string): CanonicalConcept | null {
|
|
72
|
+
const normalized = raw.toLowerCase().trim().replace(/\s+/g, '-');
|
|
73
|
+
return ALIAS_INDEX.get(normalized) ?? null;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
/**
|
|
77
|
+
* Resolve a raw term to its canonical key, or return the normalized form if not recognized.
|
|
78
|
+
* Unrecognized terms pass through as-is (lowercase, hyphenated) — they won't match any skill
|
|
79
|
+
* index entry, but they're preserved for LLM fallback context.
|
|
80
|
+
*/
|
|
81
|
+
export function resolveCanonicalKey(raw: string): string {
|
|
82
|
+
const concept = resolveCanonicalConcept(raw);
|
|
83
|
+
return concept?.key ?? raw.toLowerCase().trim().replace(/\s+/g, '-');
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
* Get the kind of a canonical concept, or null if not in registry.
|
|
88
|
+
*/
|
|
89
|
+
export function getConceptKind(key: string): ConceptKind | null {
|
|
90
|
+
const concept = ALIAS_INDEX.get(key.toLowerCase());
|
|
91
|
+
return concept?.kind ?? null;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
/**
|
|
95
|
+
* Get all registered concepts.
|
|
96
|
+
*/
|
|
97
|
+
export function getAllConcepts(): readonly CanonicalConcept[] {
|
|
98
|
+
return CONCEPTS;
|
|
99
|
+
}
|