@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,103 @@
|
|
|
1
|
+
import { RunnerKind } from '../../policy';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Runner-plane contracts (plan §6 Phase F).
|
|
5
|
+
*
|
|
6
|
+
* A runner is the executor that picks up a `RunnerJobDispatch` and
|
|
7
|
+
* actually invokes the capability.
|
|
8
|
+
*
|
|
9
|
+
* Note: `RunnerKind` (the policy-routing classifier — Local / Cloud /
|
|
10
|
+
* CustomerEdge / GPU / Sandbox / CI) is owned by `@xemahq/policy-contracts`
|
|
11
|
+
* and re-exported from this package via `./runner-kind`. The execution
|
|
12
|
+
* mode (Embedded / LocalModule / Remote) lives in `./runner-registration`
|
|
13
|
+
* as `RunnerMode`.
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Trust tier assigned to a runner at attestation time (Phase F.4). The
|
|
18
|
+
* authorization-api's policy bundle MAY gate sensitive capabilities to
|
|
19
|
+
* `Trusted` or `System` tiers only.
|
|
20
|
+
*
|
|
21
|
+
* Order is intentional: each higher tier is a strict superset of the
|
|
22
|
+
* authority granted to lower tiers. Do NOT compare via string equality
|
|
23
|
+
* outside of policy code — compare via the enum.
|
|
24
|
+
*/
|
|
25
|
+
export enum RunnerTrustTier {
|
|
26
|
+
Untrusted = 'untrusted',
|
|
27
|
+
Verified = 'verified',
|
|
28
|
+
Trusted = 'trusted',
|
|
29
|
+
System = 'system',
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/**
|
|
33
|
+
* Canonical ordinal rank for each {@link RunnerTrustTier}. Higher = more
|
|
34
|
+
* authority. This is the SINGLE source of trust ordering — the router's
|
|
35
|
+
* dispatch min-trust gate (Phase F.4) and the runner's per-capability
|
|
36
|
+
* min-trust gate (Phase F.7) MUST both rank through this map so a runner
|
|
37
|
+
* the router accepts is ranked identically by the executor. Do not inline a
|
|
38
|
+
* second ordering.
|
|
39
|
+
*/
|
|
40
|
+
export const RUNNER_TRUST_TIER_RANK: Record<RunnerTrustTier, number> = {
|
|
41
|
+
[RunnerTrustTier.Untrusted]: 0,
|
|
42
|
+
[RunnerTrustTier.Verified]: 1,
|
|
43
|
+
[RunnerTrustTier.Trusted]: 2,
|
|
44
|
+
[RunnerTrustTier.System]: 3,
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* True iff `actual` grants at least the authority of `minimum` (i.e. ranks
|
|
49
|
+
* equal-or-higher). Use this for every trust-tier comparison — never `===`
|
|
50
|
+
* on the enum, which would reject a strictly-higher tier.
|
|
51
|
+
*/
|
|
52
|
+
export function runnerTrustTierMeets(
|
|
53
|
+
actual: RunnerTrustTier,
|
|
54
|
+
minimum: RunnerTrustTier,
|
|
55
|
+
): boolean {
|
|
56
|
+
return RUNNER_TRUST_TIER_RANK[actual] >= RUNNER_TRUST_TIER_RANK[minimum];
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
/** Runtime guard: is `value` a member of the closed {@link RunnerTrustTier} set? */
|
|
60
|
+
export function isRunnerTrustTier(value: unknown): value is RunnerTrustTier {
|
|
61
|
+
return (
|
|
62
|
+
typeof value === 'string' &&
|
|
63
|
+
(Object.values(RunnerTrustTier) as string[]).includes(value)
|
|
64
|
+
);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
/**
|
|
68
|
+
* Nominal string for a runner identifier. The brand is a phantom type
|
|
69
|
+
* so the value still serializes as a plain string across the wire while
|
|
70
|
+
* giving editor / TS narrowing protection against passing a random
|
|
71
|
+
* string where a `RunnerId` is expected.
|
|
72
|
+
*/
|
|
73
|
+
export type RunnerId = string & { readonly __brand: 'RunnerId' };
|
|
74
|
+
|
|
75
|
+
/**
|
|
76
|
+
* Self-description a runner publishes at registration time. Mirrors
|
|
77
|
+
* `ServiceDescriptor` in spirit but carries runner-specific labels
|
|
78
|
+
* (data locality, region) consumed by `Policy.routeHints` (Phase F.6).
|
|
79
|
+
*
|
|
80
|
+
* For the richer Phase F.3 registration shape (mode + biome
|
|
81
|
+
* provisioning + transport) see `RunnerRegistration`.
|
|
82
|
+
*/
|
|
83
|
+
export interface RunnerDescriptor {
|
|
84
|
+
id: RunnerId;
|
|
85
|
+
kind: RunnerKind;
|
|
86
|
+
trustTier: RunnerTrustTier;
|
|
87
|
+
version: string;
|
|
88
|
+
/**
|
|
89
|
+
* IDs of `ExecutionEnvironment`s this runner is allowed to serve.
|
|
90
|
+
* The list is signed by the org admin via Phase F.4 attestation; a
|
|
91
|
+
* runner MUST refuse a dispatch whose `executionContext.environmentId`
|
|
92
|
+
* is not in this list.
|
|
93
|
+
*/
|
|
94
|
+
allowedEnvironments: string[];
|
|
95
|
+
labels: Record<string, string>;
|
|
96
|
+
/**
|
|
97
|
+
* Data-locality classifier consumed by policy (e.g. `customer-private`,
|
|
98
|
+
* `xema-cloud`). Free-form string deliberately — the closed set of
|
|
99
|
+
* values is defined by org-level policy bundles, not the kernel.
|
|
100
|
+
*/
|
|
101
|
+
dataLocality?: string;
|
|
102
|
+
region?: string;
|
|
103
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Coarse isolation boundary a biome runtime provides for the workloads it
|
|
5
|
+
* runs. A biome manifest declares the isolation levels it ACCEPTS (via
|
|
6
|
+
* `runtimeRequirements.isolation.allowed`); a runtime/runner advertises the
|
|
7
|
+
* isolation level it PROVIDES. The scheduler matches the two — a runtime
|
|
8
|
+
* whose isolation is not in the biome's allowed set is ineligible.
|
|
9
|
+
*
|
|
10
|
+
* This is the *runtime placement* concern (where/how strongly a biome's
|
|
11
|
+
* workload is isolated), DISTINCT from `RunnerMode` (embedded vs local
|
|
12
|
+
* sidecar vs remote — how the biome is provisioned onto a runner). A
|
|
13
|
+
* `local-module` biome may run at `process` isolation today and `container`
|
|
14
|
+
* isolation on a hardened runner tomorrow without changing its mode.
|
|
15
|
+
*
|
|
16
|
+
* Closed set on purpose — adding a level is a coordinated kernel change so
|
|
17
|
+
* producer (manifest) and consumer (runtime descriptor) stay in lockstep.
|
|
18
|
+
* Ordered weakest → strongest for callers that gate on a minimum.
|
|
19
|
+
*/
|
|
20
|
+
export enum RuntimeIsolationLevel {
|
|
21
|
+
/** No dedicated boundary — shares the host process (in-process module). */
|
|
22
|
+
None = 'none',
|
|
23
|
+
/** A separate OS process on a shared host. */
|
|
24
|
+
Process = 'process',
|
|
25
|
+
/** A container (namespaced filesystem/network/cgroups). */
|
|
26
|
+
Container = 'container',
|
|
27
|
+
/** A virtual machine / micro-VM (hardware-virtualized boundary). */
|
|
28
|
+
Vm = 'vm',
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export const RuntimeIsolationLevelSchema = z.nativeEnum(RuntimeIsolationLevel);
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* Weakest → strongest ordering used by `runtimeIsolationMeets`. Index is
|
|
35
|
+
* the rank; a higher rank is a stronger boundary.
|
|
36
|
+
*/
|
|
37
|
+
const ISOLATION_RANK: readonly RuntimeIsolationLevel[] = [
|
|
38
|
+
RuntimeIsolationLevel.None,
|
|
39
|
+
RuntimeIsolationLevel.Process,
|
|
40
|
+
RuntimeIsolationLevel.Container,
|
|
41
|
+
RuntimeIsolationLevel.Vm,
|
|
42
|
+
];
|
|
43
|
+
|
|
44
|
+
/**
|
|
45
|
+
* True when `actual` provides at least as strong a boundary as `minimum`.
|
|
46
|
+
* Mirrors `runnerTrustTierMeets` so a single ranking governs every gate.
|
|
47
|
+
*/
|
|
48
|
+
export function runtimeIsolationMeets(
|
|
49
|
+
actual: RuntimeIsolationLevel,
|
|
50
|
+
minimum: RuntimeIsolationLevel,
|
|
51
|
+
): boolean {
|
|
52
|
+
return ISOLATION_RANK.indexOf(actual) >= ISOLATION_RANK.indexOf(minimum);
|
|
53
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* The canonical, source-AGNOSTIC indexable document. A searchable biome
|
|
5
|
+
* projects its own domain entity into this shape (producer-side) so that
|
|
6
|
+
* search-api can index it WITHOUT importing the biome's client or knowing its
|
|
7
|
+
* entity schema.
|
|
8
|
+
*
|
|
9
|
+
* Server-owned fields (vector embedding, chunk index, parent-doc linkage) are
|
|
10
|
+
* NOT part of this contract — search computes them from `content`. The producer
|
|
11
|
+
* supplies identity, scope, and the human/searchable text only.
|
|
12
|
+
*
|
|
13
|
+
* `sourceKey` + `docType` + `sourceId` is the stable natural key: re-emitting
|
|
14
|
+
* the same triple is an idempotent upsert.
|
|
15
|
+
*/
|
|
16
|
+
export interface IndexableDocument {
|
|
17
|
+
/** Registered source that produced this document (e.g. `knowledge-base`). */
|
|
18
|
+
readonly sourceKey: string;
|
|
19
|
+
/** Entity kind within the source (e.g. `kb_page`, `backlog_item`). Open taxonomy owned by search. */
|
|
20
|
+
readonly docType: string;
|
|
21
|
+
/** The source's stable primary key for this entity. */
|
|
22
|
+
readonly sourceId: string;
|
|
23
|
+
/** Tenant scope. Search re-derives/validates this from the event envelope — the producer copy is advisory. */
|
|
24
|
+
readonly orgId: string;
|
|
25
|
+
/** Project scope, when applicable. */
|
|
26
|
+
readonly projectId?: string;
|
|
27
|
+
readonly title?: string;
|
|
28
|
+
readonly summary?: string;
|
|
29
|
+
/** Full searchable text. */
|
|
30
|
+
readonly content?: string;
|
|
31
|
+
/** Code text (separate analyzer), when applicable. */
|
|
32
|
+
readonly code?: string;
|
|
33
|
+
readonly tags?: readonly string[];
|
|
34
|
+
readonly status?: string;
|
|
35
|
+
readonly phase?: string;
|
|
36
|
+
readonly priority?: string;
|
|
37
|
+
readonly createdBy?: string;
|
|
38
|
+
/** ISO-8601 timestamp. */
|
|
39
|
+
readonly createdAt?: string;
|
|
40
|
+
/** ISO-8601 timestamp. */
|
|
41
|
+
readonly updatedAt?: string;
|
|
42
|
+
/** Free-form per-source metadata carried verbatim onto the index document. */
|
|
43
|
+
readonly metadata?: Readonly<Record<string, unknown>>;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* Wire schema for {@link IndexableDocument}. search-api validates every consumed
|
|
48
|
+
* upsert against this and dead-letters on failure — no silent thin-index.
|
|
49
|
+
*/
|
|
50
|
+
export const IndexableDocumentSchema = z
|
|
51
|
+
.object({
|
|
52
|
+
sourceKey: z.string().min(1),
|
|
53
|
+
docType: z.string().min(1),
|
|
54
|
+
sourceId: z.string().min(1),
|
|
55
|
+
orgId: z.string().min(1),
|
|
56
|
+
projectId: z.string().min(1).optional(),
|
|
57
|
+
title: z.string().optional(),
|
|
58
|
+
summary: z.string().optional(),
|
|
59
|
+
content: z.string().optional(),
|
|
60
|
+
code: z.string().optional(),
|
|
61
|
+
tags: z.array(z.string()).optional(),
|
|
62
|
+
status: z.string().optional(),
|
|
63
|
+
phase: z.string().optional(),
|
|
64
|
+
priority: z.string().optional(),
|
|
65
|
+
createdBy: z.string().optional(),
|
|
66
|
+
createdAt: z.string().optional(),
|
|
67
|
+
updatedAt: z.string().optional(),
|
|
68
|
+
metadata: z.record(z.string(), z.unknown()).optional(),
|
|
69
|
+
})
|
|
70
|
+
.strict();
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
import { IndexableDocumentSchema, type IndexableDocument } from './indexable-document';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* Canonical search-index change operation. Closed set.
|
|
7
|
+
*/
|
|
8
|
+
export enum SearchIndexOp {
|
|
9
|
+
Upsert = 'upsert',
|
|
10
|
+
Delete = 'delete',
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* The TWO canonical event types search-api subscribes to. EVERY searchable
|
|
15
|
+
* biome projects its domain events into one of these (producer-side) and emits
|
|
16
|
+
* it on the generic event bus. search-api subscribes to exactly these two and
|
|
17
|
+
* nothing else — so a NEW searchable biome requires ZERO search-api changes.
|
|
18
|
+
*/
|
|
19
|
+
export const SEARCH_INDEX_UPSERT_EVENT_TYPE = 'search.index.upsert' as const;
|
|
20
|
+
export const SEARCH_INDEX_DELETE_EVENT_TYPE = 'search.index.delete' as const;
|
|
21
|
+
|
|
22
|
+
/** Upsert: the full canonical document to (re)index. */
|
|
23
|
+
export interface SearchIndexUpsert {
|
|
24
|
+
readonly op: SearchIndexOp.Upsert;
|
|
25
|
+
readonly document: IndexableDocument;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
/** Delete: drop the identified document (or whole source scope) from the index. */
|
|
29
|
+
export interface SearchIndexDelete {
|
|
30
|
+
readonly op: SearchIndexOp.Delete;
|
|
31
|
+
readonly sourceKey: string;
|
|
32
|
+
readonly docType: string;
|
|
33
|
+
readonly sourceId: string;
|
|
34
|
+
readonly orgId: string;
|
|
35
|
+
readonly projectId?: string;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export type SearchIndexChange = SearchIndexUpsert | SearchIndexDelete;
|
|
39
|
+
|
|
40
|
+
export const SearchIndexUpsertSchema = z
|
|
41
|
+
.object({
|
|
42
|
+
op: z.literal(SearchIndexOp.Upsert),
|
|
43
|
+
document: IndexableDocumentSchema,
|
|
44
|
+
})
|
|
45
|
+
.strict();
|
|
46
|
+
|
|
47
|
+
export const SearchIndexDeleteSchema = z
|
|
48
|
+
.object({
|
|
49
|
+
op: z.literal(SearchIndexOp.Delete),
|
|
50
|
+
sourceKey: z.string().min(1),
|
|
51
|
+
docType: z.string().min(1),
|
|
52
|
+
sourceId: z.string().min(1),
|
|
53
|
+
orgId: z.string().min(1),
|
|
54
|
+
projectId: z.string().min(1).optional(),
|
|
55
|
+
})
|
|
56
|
+
.strict();
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
|
|
3
|
+
import { IndexableDocumentSchema, type IndexableDocument } from './indexable-document';
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* The `<resource>.<verb>` segment every source-replay capability ref carries.
|
|
7
|
+
* search-api discovers backfill-capable sources by listing capability-registry
|
|
8
|
+
* and matching refs of shape `<sourceKey>:search.replay@<major>` — so it never
|
|
9
|
+
* imports a source client and a new source becomes reindexable simply by
|
|
10
|
+
* registering its capability.
|
|
11
|
+
*/
|
|
12
|
+
export const SEARCH_REPLAY_CAPABILITY_KIND = 'search.replay' as const;
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Major version of the replay capability contract. Bumped only on a breaking
|
|
16
|
+
* change to the {@link SearchReplayRequest} / {@link SearchReplayResponse}
|
|
17
|
+
* wire shape.
|
|
18
|
+
*/
|
|
19
|
+
export const SEARCH_REPLAY_CAPABILITY_MAJOR = 1 as const;
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* Canonical capability ref for a source's replay endpoint. Convention:
|
|
23
|
+
* `<sourceKey>:search.replay@<major>`. This is a FULL kernel CapabilityRef
|
|
24
|
+
* (`<domain>:<resource>.<verb>@<major>`) — the source key is the domain — so
|
|
25
|
+
* it registers in capability-registry, resolves in the capability-router, and
|
|
26
|
+
* invokes through the gateway like any other capability. Deterministic +
|
|
27
|
+
* auditable: derivable from the sourceKey alone, so the registry and the
|
|
28
|
+
* descriptor never drift.
|
|
29
|
+
*/
|
|
30
|
+
export function searchReplayCapabilityRef(sourceKey: string): string {
|
|
31
|
+
return `${sourceKey}:${SEARCH_REPLAY_CAPABILITY_KIND}@${SEARCH_REPLAY_CAPABILITY_MAJOR}`;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Matches any source's replay capability ref (`<sourceKey>:search.replay@<n>`).
|
|
36
|
+
* The `<sourceKey>` capture is the domain segment of the kernel CapabilityRef
|
|
37
|
+
* grammar (kebab, must start with a letter).
|
|
38
|
+
*/
|
|
39
|
+
const SEARCH_REPLAY_REF_REGEX = /^([a-z][a-z0-9-]*):search\.replay@(\d+)$/;
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* True when `ref` is a source-replay capability ref. search-api uses this to
|
|
43
|
+
* pick backfill-capable capabilities out of the full registry listing without
|
|
44
|
+
* knowing any specific source.
|
|
45
|
+
*/
|
|
46
|
+
export function isSearchReplayCapabilityRef(ref: string): boolean {
|
|
47
|
+
return SEARCH_REPLAY_REF_REGEX.test(ref);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/**
|
|
51
|
+
* Extract the `sourceKey` (domain segment) from a replay capability ref, or
|
|
52
|
+
* `null` when `ref` is not a replay ref. Used by the capability-router to map
|
|
53
|
+
* a replay ref to the owning source's HTTP endpoint.
|
|
54
|
+
*/
|
|
55
|
+
export function searchSourceKeyFromReplayRef(ref: string): string | null {
|
|
56
|
+
const match = SEARCH_REPLAY_REF_REGEX.exec(ref);
|
|
57
|
+
return match?.[1] ?? null;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* Backfill request search sends to a source's replay capability (via
|
|
62
|
+
* capability-router — NOT a direct client call). Paginated so a large source
|
|
63
|
+
* drains in bounded batches.
|
|
64
|
+
*/
|
|
65
|
+
export interface SearchReplayRequest {
|
|
66
|
+
readonly orgId?: string;
|
|
67
|
+
readonly projectId?: string;
|
|
68
|
+
readonly cursor?: string;
|
|
69
|
+
readonly limit?: number;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* Backfill response: a page of canonical documents plus an opaque cursor for
|
|
74
|
+
* the next page (absent = drained). The source re-projects its current rows
|
|
75
|
+
* through the SAME projection used on the hot path.
|
|
76
|
+
*/
|
|
77
|
+
export interface SearchReplayResponse {
|
|
78
|
+
readonly documents: readonly IndexableDocument[];
|
|
79
|
+
readonly nextCursor?: string;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
export const SearchReplayRequestSchema = z
|
|
83
|
+
.object({
|
|
84
|
+
orgId: z.string().min(1).optional(),
|
|
85
|
+
projectId: z.string().min(1).optional(),
|
|
86
|
+
cursor: z.string().min(1).optional(),
|
|
87
|
+
limit: z.number().int().positive().max(1000).optional(),
|
|
88
|
+
})
|
|
89
|
+
.strict();
|
|
90
|
+
|
|
91
|
+
export const SearchReplayResponseSchema = z
|
|
92
|
+
.object({
|
|
93
|
+
documents: z.array(IndexableDocumentSchema),
|
|
94
|
+
nextCursor: z.string().min(1).optional(),
|
|
95
|
+
})
|
|
96
|
+
.strict();
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import type { SearchIndexChange } from './search-index-event';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Producer-side declaration that makes a biome SEARCHABLE. The biome owns this
|
|
5
|
+
* descriptor; search-api NEVER imports it. It is used in two places, both on
|
|
6
|
+
* the SOURCE side:
|
|
7
|
+
*
|
|
8
|
+
* 1. At emit time — a shared producer helper runs `project()` on each of the
|
|
9
|
+
* source's own domain events and emits the resulting canonical
|
|
10
|
+
* `search.index.upsert` / `search.index.delete` event on the bus.
|
|
11
|
+
* 2. At backfill time — the source's `replay` capability (if declared)
|
|
12
|
+
* re-projects its current rows into the same canonical events.
|
|
13
|
+
*
|
|
14
|
+
* Because the projection runs on the producer (which already owns the entity
|
|
15
|
+
* schema), search-api consumes only the canonical change events and imports no
|
|
16
|
+
* source client. A new searchable biome adds a descriptor + emits the canonical
|
|
17
|
+
* events; search-api is untouched.
|
|
18
|
+
*
|
|
19
|
+
* @typeParam TEvent the union of the source's own domain event payloads
|
|
20
|
+
*/
|
|
21
|
+
export interface SearchSourceDescriptor<TEvent = unknown> {
|
|
22
|
+
/** Stable identifier of this source (e.g. `knowledge-base`, `design-system-builder`). */
|
|
23
|
+
readonly sourceKey: string;
|
|
24
|
+
/** Human label for ops/registry surfaces. */
|
|
25
|
+
readonly displayName: string;
|
|
26
|
+
/** The `docType`(s) this source emits — the open taxonomy entries search will see. */
|
|
27
|
+
readonly docTypes: readonly string[];
|
|
28
|
+
/** Source domain event types that drive (re)indexing vs deletion. */
|
|
29
|
+
readonly events: {
|
|
30
|
+
readonly indexed: readonly string[];
|
|
31
|
+
readonly deleted?: readonly string[];
|
|
32
|
+
};
|
|
33
|
+
/**
|
|
34
|
+
* Project ONE of the source's domain events into a canonical change, or
|
|
35
|
+
* `null` to skip (e.g. an event the source listed but that carries nothing
|
|
36
|
+
* indexable yet). Runs PRODUCER-side. MUST be deterministic and free of
|
|
37
|
+
* silent fallbacks — return `null` only for a genuine, intended skip.
|
|
38
|
+
*/
|
|
39
|
+
project(eventType: string, data: TEvent): SearchIndexChange | null;
|
|
40
|
+
/**
|
|
41
|
+
* Optional backfill/reindex support. When present, the source exposes a
|
|
42
|
+
* capability (ref = {@link searchReplayCapabilityRef}) that re-emits the
|
|
43
|
+
* canonical events for its current rows. ABSENT means this source does not
|
|
44
|
+
* support full reindex — search treats that as an explicit, declared
|
|
45
|
+
* limitation (no silent fallback to a stale or partial index).
|
|
46
|
+
*/
|
|
47
|
+
readonly replay?: {
|
|
48
|
+
readonly capabilityRef: string;
|
|
49
|
+
};
|
|
50
|
+
}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Declarative contract referenced by the `@xemahq/service-registry-nest`
|
|
3
|
+
* SDK's `@InjectService(name)` decorator. Lives in the kernel-leaf so
|
|
4
|
+
* any package can describe an injection point without importing NestJS.
|
|
5
|
+
*
|
|
6
|
+
* The runtime decorator itself (which reads / attaches this metadata via
|
|
7
|
+
* `reflect-metadata`) belongs in the SDK package — kernel leaves never
|
|
8
|
+
* carry NestJS or `reflect-metadata` runtime deps.
|
|
9
|
+
*
|
|
10
|
+
* The literal string in `kind` doubles as the metadata key used by the
|
|
11
|
+
* SDK's `Reflector.get(...)`; bumping it is a breaking change.
|
|
12
|
+
*/
|
|
13
|
+
export interface InjectServiceMetadata<T extends string = string> {
|
|
14
|
+
kind: 'xema/inject-service';
|
|
15
|
+
service: T;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* Metadata key under which `InjectServiceMetadata` is stamped on a
|
|
20
|
+
* parameter / property by the SDK decorator. Exposed as a `const`
|
|
21
|
+
* (not just a TS type) so tooling that scans `reflect-metadata` (e.g.
|
|
22
|
+
* boundary-check scripts) can reference it without hard-coding the
|
|
23
|
+
* string.
|
|
24
|
+
*/
|
|
25
|
+
export const INJECT_SERVICE_METADATA_KEY = 'xema/inject-service' as const;
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Service Registry contracts (plan §6 Phase B.1).
|
|
3
|
+
*
|
|
4
|
+
* The Service Registry is the kernel primitive that replaces the
|
|
5
|
+
* `*_API_URL` env-var hellscape. Every NestJS app at boot registers a
|
|
6
|
+
* `ServiceDescriptor` keyed under `/xema/services/<name>/<instanceId>/`
|
|
7
|
+
* in KernelState; consumers `resolve()` or `watch()` instead of reading
|
|
8
|
+
* env vars. The Kernel state grammar enum lives in
|
|
9
|
+
* `@xemahq/kernel-state-contracts`.
|
|
10
|
+
*
|
|
11
|
+
* These contracts are pure TS — no runtime deps, no NestJS imports.
|
|
12
|
+
*/
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Transport protocols a Xema service may expose. Closed set: adding a new
|
|
16
|
+
* transport is an explicit enum change so consumers cannot silently match
|
|
17
|
+
* an unknown one.
|
|
18
|
+
*/
|
|
19
|
+
export enum ServiceEndpointProtocol {
|
|
20
|
+
Http = 'http',
|
|
21
|
+
Grpc = 'grpc',
|
|
22
|
+
EventHub = 'event-hub',
|
|
23
|
+
Mcp = 'mcp',
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Authentication mode a caller must use against a given endpoint. Closed
|
|
28
|
+
* set; an endpoint that has no auth requirement MUST set `auth: 'none'`
|
|
29
|
+
* explicitly — `undefined` is reserved for "auth metadata not declared"
|
|
30
|
+
* and downstream resolvers MUST refuse to call such an endpoint.
|
|
31
|
+
*/
|
|
32
|
+
export enum ServiceEndpointAuth {
|
|
33
|
+
ServiceToken = 'service-token',
|
|
34
|
+
Mtls = 'mtls',
|
|
35
|
+
None = 'none',
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Single network endpoint declared by a service. A service MAY expose
|
|
40
|
+
* multiple endpoints (e.g. HTTP for control-plane + MCP for tool calls).
|
|
41
|
+
*/
|
|
42
|
+
export interface ServiceEndpoint {
|
|
43
|
+
protocol: ServiceEndpointProtocol;
|
|
44
|
+
url: string;
|
|
45
|
+
auth?: ServiceEndpointAuth;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Self-description a service writes to the registry at boot. The shape is
|
|
50
|
+
* deliberately flat so it round-trips losslessly through KernelState
|
|
51
|
+
* (SQLite or etcd) as a JSON blob.
|
|
52
|
+
*
|
|
53
|
+
* Invariants (consumers MUST fail-fast on violation):
|
|
54
|
+
* - `name` is the canonical service slug (matches `package.json#name`
|
|
55
|
+
* stripped of scope, e.g. `llm-registry-api`).
|
|
56
|
+
* - `semver` matches the published service version, not the kernel
|
|
57
|
+
* schema version.
|
|
58
|
+
* - `instanceId` is the per-replica identifier; the same `name` MAY have
|
|
59
|
+
* N concurrent `instanceId`s under horizontal scaling.
|
|
60
|
+
* - `endpoints` is non-empty; a service with no endpoints cannot be
|
|
61
|
+
* resolved and must not register.
|
|
62
|
+
* - `exposesCapabilities` / `requiresServices` carry only canonical
|
|
63
|
+
* refs / service names — no env-var URLs.
|
|
64
|
+
*/
|
|
65
|
+
export interface ServiceDescriptor {
|
|
66
|
+
name: string;
|
|
67
|
+
semver: string;
|
|
68
|
+
instanceId: string;
|
|
69
|
+
endpoints: ServiceEndpoint[];
|
|
70
|
+
exposesCapabilities: string[];
|
|
71
|
+
requiresServices: string[];
|
|
72
|
+
healthEndpoint?: string;
|
|
73
|
+
region?: string;
|
|
74
|
+
labels?: Record<string, string>;
|
|
75
|
+
}
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import type { ServiceDescriptor, ServiceEndpoint } from './service-descriptor';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Lease granted by the registry on `register` / `renew`. The lease is the
|
|
5
|
+
* sole proof-of-liveness — if a service stops renewing, its descriptor is
|
|
6
|
+
* GC'd and `resolve()` will stop returning it. There is NO secondary
|
|
7
|
+
* heartbeat channel.
|
|
8
|
+
*/
|
|
9
|
+
export interface ServiceLease {
|
|
10
|
+
leaseId: string;
|
|
11
|
+
instanceId: string;
|
|
12
|
+
name: string;
|
|
13
|
+
/**
|
|
14
|
+
* Absolute UTC timestamp (ISO-8601) at which the lease expires unless
|
|
15
|
+
* renewed. Consumers MUST renew before this instant.
|
|
16
|
+
*/
|
|
17
|
+
expiresAt: string;
|
|
18
|
+
/**
|
|
19
|
+
* Time-to-live in seconds as granted by the registry. May be shorter
|
|
20
|
+
* than the value the caller requested; the registry has authority to
|
|
21
|
+
* cap.
|
|
22
|
+
*/
|
|
23
|
+
ttlSeconds: number;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Descriptor plus resolved endpoint(s) returned by `resolve` / `watch`.
|
|
28
|
+
* Selection between multiple endpoints (e.g. HTTP vs MCP) is the
|
|
29
|
+
* consumer's responsibility — the registry returns the full set.
|
|
30
|
+
*/
|
|
31
|
+
export interface ResolvedService {
|
|
32
|
+
name: string;
|
|
33
|
+
instanceId: string;
|
|
34
|
+
semver: string;
|
|
35
|
+
endpoints: ServiceEndpoint[];
|
|
36
|
+
/**
|
|
37
|
+
* The full original descriptor. Carried so callers performing
|
|
38
|
+
* capability-aware routing don't need a second lookup.
|
|
39
|
+
*/
|
|
40
|
+
descriptor: ServiceDescriptor;
|
|
41
|
+
/**
|
|
42
|
+
* Absolute UTC timestamp at which the underlying lease expires. A
|
|
43
|
+
* consumer cache SHOULD evict on or before this instant.
|
|
44
|
+
*/
|
|
45
|
+
leaseExpiresAt: string;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Optional filters applied at resolution time. Filters AND together;
|
|
50
|
+
* a service must match every populated filter to be returned.
|
|
51
|
+
*/
|
|
52
|
+
export interface ResolveOptions {
|
|
53
|
+
region?: string;
|
|
54
|
+
/**
|
|
55
|
+
* Subset of labels that the resolved service's `descriptor.labels`
|
|
56
|
+
* MUST contain (string equality on each key).
|
|
57
|
+
*/
|
|
58
|
+
labels?: Record<string, string>;
|
|
59
|
+
/**
|
|
60
|
+
* If set, only return services whose `exposesCapabilities` contains
|
|
61
|
+
* every entry. Empty array is treated as "no constraint".
|
|
62
|
+
*/
|
|
63
|
+
requiredCapabilities?: string[];
|
|
64
|
+
/**
|
|
65
|
+
* Semver range the resolved service's `semver` must satisfy. The
|
|
66
|
+
* registry implementation is responsible for parsing the range —
|
|
67
|
+
* this contract carries it through opaquely as a string.
|
|
68
|
+
*/
|
|
69
|
+
semverRange?: string;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* Kernel-leaf interface every Service Registry adapter implements
|
|
74
|
+
* (SQLite-backed in dev / single-instance, etcd-backed in cluster).
|
|
75
|
+
*
|
|
76
|
+
* Implementations MUST:
|
|
77
|
+
* - throw on register if `descriptor.endpoints` is empty.
|
|
78
|
+
* - throw on renew if the lease is unknown / already expired (fail-fast,
|
|
79
|
+
* no silent re-register).
|
|
80
|
+
* - return an empty array (not throw) from `resolve` when no instance
|
|
81
|
+
* matches — "no providers" is a valid state callers must handle.
|
|
82
|
+
* - call the `watch` callback synchronously on subscribe with the
|
|
83
|
+
* current set, then again on every change. The returned function
|
|
84
|
+
* detaches the subscription.
|
|
85
|
+
*/
|
|
86
|
+
export interface ServiceRegistry {
|
|
87
|
+
register(descriptor: ServiceDescriptor): Promise<ServiceLease>;
|
|
88
|
+
renew(leaseId: string): Promise<ServiceLease>;
|
|
89
|
+
resolve(name: string, opts?: ResolveOptions): Promise<ResolvedService>;
|
|
90
|
+
watch(
|
|
91
|
+
name: string,
|
|
92
|
+
cb: (services: ResolvedService[]) => void,
|
|
93
|
+
): () => void;
|
|
94
|
+
/**
|
|
95
|
+
* Enumerate EVERY current registration across all service names — one
|
|
96
|
+
* {@link ResolvedService} entry per live instance. Unlike {@link resolve}
|
|
97
|
+
* (single name, fail-fast on miss), this is the full-mesh read used by
|
|
98
|
+
* operator/topology surfaces.
|
|
99
|
+
*
|
|
100
|
+
* Implementations MUST reflect the registry the process is connected to
|
|
101
|
+
* — the shared cluster registry (etcd) for the KernelState adapter, the
|
|
102
|
+
* in-process map for the dev adapter — NOT merely the caller's own
|
|
103
|
+
* registration. An empty registry returns an empty array (it does NOT
|
|
104
|
+
* throw); a registry-unavailable condition propagates (fail-fast).
|
|
105
|
+
*/
|
|
106
|
+
list(): Promise<ResolvedService[]>;
|
|
107
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── Skill Contracts — Barrel Export ──
|
|
3
|
+
//
|
|
4
|
+
// Kernel (Layer 1) contracts for the Skill primitive. Pure types + closed
|
|
5
|
+
// enums — zero runtime deps, no NestJS, no Prisma. Shared between
|
|
6
|
+
// skill-registry-api, the workspace composer, deliverable-specs-api (for
|
|
7
|
+
// the deliverable-skill projection) and the frontend Agent Studio.
|
|
8
|
+
//
|
|
9
|
+
// A Skill is a folder bundle whose only strict part is SKILL.md.
|
|
10
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
11
|
+
|
|
12
|
+
export * from './lib/skill-enums';
|
|
13
|
+
export * from './lib/skill-governance';
|
|
14
|
+
export * from './lib/skill-source';
|
|
15
|
+
export * from './lib/skill';
|