@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,209 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { ContributionKind, ContributionKindSchema } from './contribution-kind';
|
|
3
|
+
import {
|
|
4
|
+
ContributionSource,
|
|
5
|
+
ContributionSourceSchema,
|
|
6
|
+
} from './contribution-source';
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Contribution slug grammar.
|
|
10
|
+
*
|
|
11
|
+
* Every contribution is addressed as `<namespace>/<local-slug>` where:
|
|
12
|
+
* - `<namespace>` is either `system` (kernel-shipped contributions) or a
|
|
13
|
+
* biome (biome) id; lowercase letters, digits, and hyphens.
|
|
14
|
+
* - `<local-slug>` is the kind-local identifier; lowercase letters, digits,
|
|
15
|
+
* hyphens, dots, and nested `/` segments allowed (e.g. `scm/create-pr`).
|
|
16
|
+
*
|
|
17
|
+
* The slug MUST be unique within a `(kind, source)` registry shard — see
|
|
18
|
+
* `createContributionRegistry`.
|
|
19
|
+
*/
|
|
20
|
+
const SLUG_NAMESPACE = '[a-z][a-z0-9-]*';
|
|
21
|
+
const SLUG_LOCAL = '[a-z0-9][a-z0-9._-]*(?:/[a-z0-9][a-z0-9._-]*)*';
|
|
22
|
+
export const CONTRIBUTION_SLUG_REGEX = new RegExp(
|
|
23
|
+
`^${SLUG_NAMESPACE}/${SLUG_LOCAL}$`,
|
|
24
|
+
);
|
|
25
|
+
|
|
26
|
+
export const ContributionSlugSchema = z
|
|
27
|
+
.string()
|
|
28
|
+
.regex(
|
|
29
|
+
CONTRIBUTION_SLUG_REGEX,
|
|
30
|
+
'Contribution slug must match `<namespace>/<local-slug>` (lowercase, hyphens, dots, slashes).',
|
|
31
|
+
);
|
|
32
|
+
|
|
33
|
+
/** Matcher for a bare namespace segment (no `/`). */
|
|
34
|
+
const CONTRIBUTION_NAMESPACE_REGEX = new RegExp(`^${SLUG_NAMESPACE}$`);
|
|
35
|
+
|
|
36
|
+
/** The canonical namespace for kernel-shipped (System-source) contributions. */
|
|
37
|
+
export const SYSTEM_CONTRIBUTION_NAMESPACE = 'system';
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* Coerce an arbitrary provenance token (a biome id, scope key, or the
|
|
41
|
+
* `__platform__` sentinel) into a contract-legal contribution namespace
|
|
42
|
+
* (`[a-z][a-z0-9-]*`).
|
|
43
|
+
*
|
|
44
|
+
* The transform is deterministic and total:
|
|
45
|
+
* - drop any `<prefix>:` qualifier (e.g. `biome:agent-runtime` → `agent-runtime`);
|
|
46
|
+
* - lowercase, then replace every run of illegal characters with a single `-`;
|
|
47
|
+
* - trim leading/trailing `-`, and drop a leading run of digits so the first
|
|
48
|
+
* character is a letter (the regex requires `[a-z]` first).
|
|
49
|
+
*
|
|
50
|
+
* Throws fail-fast if no legal namespace can be derived (e.g. the input has
|
|
51
|
+
* no letters), rather than silently emitting an invalid slug.
|
|
52
|
+
*/
|
|
53
|
+
export function sanitizeContributionNamespace(raw: string): string {
|
|
54
|
+
const afterColon = raw.includes(':') ? raw.slice(raw.lastIndexOf(':') + 1) : raw;
|
|
55
|
+
const collapsed = afterColon
|
|
56
|
+
.toLowerCase()
|
|
57
|
+
.replace(/[^a-z0-9]+/g, '-')
|
|
58
|
+
.replace(/^-+|-+$/g, '')
|
|
59
|
+
.replace(/^[0-9]+/, '');
|
|
60
|
+
const namespace = collapsed.replace(/^-+/, '');
|
|
61
|
+
if (!CONTRIBUTION_NAMESPACE_REGEX.test(namespace)) {
|
|
62
|
+
throw new Error(
|
|
63
|
+
`Cannot derive a contract-legal contribution namespace from "${raw}" — ` +
|
|
64
|
+
`result "${namespace}" does not match ${SLUG_NAMESPACE}.`,
|
|
65
|
+
);
|
|
66
|
+
}
|
|
67
|
+
return namespace;
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
/**
|
|
71
|
+
* Compose a contract-legal contribution envelope slug `<namespace>/<localSlug>`.
|
|
72
|
+
*
|
|
73
|
+
* `localSlug` is the bare, kind-local identifier stored on the manifest/DB row
|
|
74
|
+
* (e.g. `scm/create-pr`); it is preserved verbatim. `namespace` is sanitized
|
|
75
|
+
* via {@link sanitizeContributionNamespace}. The composed slug is validated
|
|
76
|
+
* against {@link ContributionSlugSchema} so a malformed `localSlug` fails fast
|
|
77
|
+
* here rather than at the SDK ingest boundary.
|
|
78
|
+
*
|
|
79
|
+
* Centralizes the namespacing every contribution producer needs so the ENVELOPE
|
|
80
|
+
* slug satisfies the kernel grammar while the BARE `localSlug` keeps flowing
|
|
81
|
+
* through `manifest` to the handler unchanged.
|
|
82
|
+
*/
|
|
83
|
+
export function composeContributionSlug(
|
|
84
|
+
namespace: string,
|
|
85
|
+
localSlug: string,
|
|
86
|
+
): string {
|
|
87
|
+
const ns = sanitizeContributionNamespace(namespace);
|
|
88
|
+
return ContributionSlugSchema.parse(`${ns}/${localSlug}`);
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* Loose semver matcher accepting the standard `MAJOR.MINOR.PATCH` shape plus
|
|
93
|
+
* the optional pre-release and build-metadata tails. We deliberately do NOT
|
|
94
|
+
* pull in a semver lib at this layer — the kernel contract only needs the
|
|
95
|
+
* shape; richer comparison lives downstream.
|
|
96
|
+
*/
|
|
97
|
+
export const CONTRIBUTION_VERSION_REGEX =
|
|
98
|
+
/^(0|[1-9]\d*)\.(0|[1-9]\d*)\.(0|[1-9]\d*)(?:-[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?(?:\+[0-9A-Za-z-]+(?:\.[0-9A-Za-z-]+)*)?$/;
|
|
99
|
+
|
|
100
|
+
export const ContributionVersionSchema = z
|
|
101
|
+
.string()
|
|
102
|
+
.regex(
|
|
103
|
+
CONTRIBUTION_VERSION_REGEX,
|
|
104
|
+
'Contribution version must be valid semver (MAJOR.MINOR.PATCH[-pre][+build]).',
|
|
105
|
+
);
|
|
106
|
+
|
|
107
|
+
/**
|
|
108
|
+
* Generic Contribution envelope. Every entry in the Backend Slot Registry,
|
|
109
|
+
* regardless of `kind`, carries this shape. Kind-specific contracts packages
|
|
110
|
+
* own their own `TManifest` Zod schemas and feed them to
|
|
111
|
+
* `contributionEnvelopeSchema` to get a fully-typed runtime validator.
|
|
112
|
+
*
|
|
113
|
+
* See plan-of-record §12.2 for the prose definition.
|
|
114
|
+
*/
|
|
115
|
+
export interface Contribution<
|
|
116
|
+
TKind extends ContributionKind,
|
|
117
|
+
TManifest,
|
|
118
|
+
> {
|
|
119
|
+
readonly kind: TKind;
|
|
120
|
+
readonly slug: string;
|
|
121
|
+
readonly source: ContributionSource;
|
|
122
|
+
readonly version: string;
|
|
123
|
+
readonly manifest: TManifest;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* Factory producing a strongly-typed Zod schema for a single `kind`.
|
|
128
|
+
*
|
|
129
|
+
* The factory pins `kind` to a literal so the resulting schema rejects
|
|
130
|
+
* cross-kind envelopes at the wire and so TypeScript narrows `kind` to
|
|
131
|
+
* `TKind` (not the full union) when consumers `parse()`.
|
|
132
|
+
*/
|
|
133
|
+
export function contributionEnvelopeSchema<
|
|
134
|
+
TKind extends ContributionKind,
|
|
135
|
+
TManifest,
|
|
136
|
+
>(
|
|
137
|
+
kind: TKind,
|
|
138
|
+
manifestSchema: z.ZodType<TManifest>,
|
|
139
|
+
): z.ZodType<Contribution<TKind, TManifest>> {
|
|
140
|
+
// `z.literal` on an enum value gives us "this exact kind" at runtime
|
|
141
|
+
// and a discriminated narrowing at the type level.
|
|
142
|
+
return z.object({
|
|
143
|
+
kind: z.literal(kind),
|
|
144
|
+
slug: ContributionSlugSchema,
|
|
145
|
+
source: ContributionSourceSchema,
|
|
146
|
+
version: ContributionVersionSchema,
|
|
147
|
+
manifest: manifestSchema,
|
|
148
|
+
}) as z.ZodType<Contribution<TKind, TManifest>>;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
/**
|
|
152
|
+
* Untyped envelope schema — accepts any `ContributionKind` and an opaque
|
|
153
|
+
* manifest. Useful for the slot registry's first-pass decode before
|
|
154
|
+
* routing the envelope to the kind-specific schema.
|
|
155
|
+
*/
|
|
156
|
+
export const AnyContributionEnvelopeSchema = z.object({
|
|
157
|
+
kind: ContributionKindSchema,
|
|
158
|
+
slug: ContributionSlugSchema,
|
|
159
|
+
source: ContributionSourceSchema,
|
|
160
|
+
version: ContributionVersionSchema,
|
|
161
|
+
manifest: z.unknown(),
|
|
162
|
+
});
|
|
163
|
+
|
|
164
|
+
export type AnyContribution = z.infer<typeof AnyContributionEnvelopeSchema>;
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* Per-invocation context passed to a `ContributionKindHandler.ingest` call.
|
|
168
|
+
* Carries the provenance of the contribution so handlers can stamp registry
|
|
169
|
+
* rows with the biome that shipped them without re-deriving it from the
|
|
170
|
+
* slug. Closed shape — extending it is a coordinated kernel change.
|
|
171
|
+
*/
|
|
172
|
+
export interface ContributionIngestContext {
|
|
173
|
+
readonly biomeId: string;
|
|
174
|
+
readonly biomeVersion: string;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
/**
|
|
178
|
+
* Per-kind ingestion handler. Phase C of the Xema OS plan replaces 14 hand-
|
|
179
|
+
* rolled `Bootstrap*Service` seeders with a single generic
|
|
180
|
+
* `BootstrapContributionsService<TKind, TManifest>` template (see plan §6
|
|
181
|
+
* C.3) whose only per-kind specialisation is an implementation of this
|
|
182
|
+
* interface.
|
|
183
|
+
*
|
|
184
|
+
* Implementations MUST:
|
|
185
|
+
* - pin `kind` to the concrete `ContributionKind` they handle so the
|
|
186
|
+
* dispatcher can route by kind;
|
|
187
|
+
* - expose `manifestSchema` so the generic bootstrap template can validate
|
|
188
|
+
* each candidate envelope's `manifest` payload at the wire boundary
|
|
189
|
+
* (fail-fast — no silent coercion, no partial ingest);
|
|
190
|
+
* - be idempotent — the bootstrap service replays contributions on every
|
|
191
|
+
* biome reload.
|
|
192
|
+
*/
|
|
193
|
+
export interface ContributionKindHandler<
|
|
194
|
+
TManifest,
|
|
195
|
+
TKind extends ContributionKind = ContributionKind,
|
|
196
|
+
> {
|
|
197
|
+
readonly kind: TKind;
|
|
198
|
+
/**
|
|
199
|
+
* Zod schema for `TManifest`. The generic bootstrap template feeds every
|
|
200
|
+
* incoming envelope's `manifest` field through this before dispatching to
|
|
201
|
+
* `ingest`, so handler implementations can assume a fully-validated
|
|
202
|
+
* payload.
|
|
203
|
+
*/
|
|
204
|
+
readonly manifestSchema: z.ZodType<TManifest>;
|
|
205
|
+
ingest(
|
|
206
|
+
contribution: Contribution<TKind, TManifest>,
|
|
207
|
+
ctx: ContributionIngestContext,
|
|
208
|
+
): Promise<void>;
|
|
209
|
+
}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
import type { Contribution } from './contribution';
|
|
2
|
+
import type { ContributionKind } from './contribution-kind';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Structured error codes raised by the in-process per-kind registry.
|
|
6
|
+
* Closed set — extending requires updating both this enum and the
|
|
7
|
+
* registry implementation in one PR.
|
|
8
|
+
*/
|
|
9
|
+
export enum ContributionRegistryErrorCode {
|
|
10
|
+
DuplicateSlug = 'CONTRIBUTION_DUPLICATE_SLUG',
|
|
11
|
+
KindMismatch = 'CONTRIBUTION_KIND_MISMATCH',
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Thrown by `ContributionRegistry` operations. Carries a structured `code`
|
|
16
|
+
* so callers can branch on the reason without string-matching the message.
|
|
17
|
+
*/
|
|
18
|
+
export class ContributionRegistryError extends Error {
|
|
19
|
+
public readonly code: ContributionRegistryErrorCode;
|
|
20
|
+
public readonly kind: ContributionKind;
|
|
21
|
+
public readonly slug: string;
|
|
22
|
+
|
|
23
|
+
public constructor(args: {
|
|
24
|
+
code: ContributionRegistryErrorCode;
|
|
25
|
+
kind: ContributionKind;
|
|
26
|
+
slug: string;
|
|
27
|
+
message: string;
|
|
28
|
+
}) {
|
|
29
|
+
super(args.message);
|
|
30
|
+
this.name = 'ContributionRegistryError';
|
|
31
|
+
this.code = args.code;
|
|
32
|
+
this.kind = args.kind;
|
|
33
|
+
this.slug = args.slug;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* Pure in-process per-kind registry interface. One registry instance per
|
|
39
|
+
* `(ContributionKind, TManifest)` pair. The Backend Slot Registry is the
|
|
40
|
+
* union catalog over many of these, indexed by `ContributionKind`.
|
|
41
|
+
*
|
|
42
|
+
* Implementations MUST:
|
|
43
|
+
* - fail-fast on duplicate slug registration (no silent overwrite);
|
|
44
|
+
* - reject entries whose `kind` does not match the registry's pinned kind;
|
|
45
|
+
* - return readonly snapshots from `list()` so callers cannot mutate state.
|
|
46
|
+
*/
|
|
47
|
+
export interface ContributionRegistry<
|
|
48
|
+
TKind extends ContributionKind,
|
|
49
|
+
TManifest,
|
|
50
|
+
> {
|
|
51
|
+
readonly kind: TKind;
|
|
52
|
+
register(entry: Contribution<TKind, TManifest>): void;
|
|
53
|
+
get(slug: string): Contribution<TKind, TManifest> | undefined;
|
|
54
|
+
list(): readonly Contribution<TKind, TManifest>[];
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* Factory for the canonical in-process registry. The returned registry is
|
|
59
|
+
* the plain reference implementation — no persistence, no eventing — and is
|
|
60
|
+
* the building block the Backend Slot Registry composes per kind.
|
|
61
|
+
*
|
|
62
|
+
* Fails fast (throws `ContributionRegistryError`) on:
|
|
63
|
+
* - duplicate slug within the same registry instance;
|
|
64
|
+
* - an entry whose `kind` differs from the registry's pinned `kind`.
|
|
65
|
+
*/
|
|
66
|
+
export function createContributionRegistry<
|
|
67
|
+
TKind extends ContributionKind,
|
|
68
|
+
TManifest,
|
|
69
|
+
>(kind: TKind): ContributionRegistry<TKind, TManifest> {
|
|
70
|
+
const entries = new Map<string, Contribution<TKind, TManifest>>();
|
|
71
|
+
|
|
72
|
+
return {
|
|
73
|
+
kind,
|
|
74
|
+
register(entry) {
|
|
75
|
+
if (entry.kind !== kind) {
|
|
76
|
+
throw new ContributionRegistryError({
|
|
77
|
+
code: ContributionRegistryErrorCode.KindMismatch,
|
|
78
|
+
kind,
|
|
79
|
+
slug: entry.slug,
|
|
80
|
+
message: `Cannot register contribution of kind "${entry.kind}" in a registry pinned to kind "${kind}".`,
|
|
81
|
+
});
|
|
82
|
+
}
|
|
83
|
+
if (entries.has(entry.slug)) {
|
|
84
|
+
throw new ContributionRegistryError({
|
|
85
|
+
code: ContributionRegistryErrorCode.DuplicateSlug,
|
|
86
|
+
kind,
|
|
87
|
+
slug: entry.slug,
|
|
88
|
+
message: `Contribution "${entry.slug}" is already registered for kind "${kind}".`,
|
|
89
|
+
});
|
|
90
|
+
}
|
|
91
|
+
entries.set(entry.slug, entry);
|
|
92
|
+
},
|
|
93
|
+
get(slug) {
|
|
94
|
+
return entries.get(slug);
|
|
95
|
+
},
|
|
96
|
+
list() {
|
|
97
|
+
return Array.from(entries.values());
|
|
98
|
+
},
|
|
99
|
+
};
|
|
100
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── Document Templates — Kernel Contracts ──
|
|
3
|
+
//
|
|
4
|
+
// Kernel (Layer 1) contracts for the Document Template primitive. Pure
|
|
5
|
+
// types + closed enums — zero runtime deps, no NestJS, no Prisma.
|
|
6
|
+
//
|
|
7
|
+
// A Document Template binds a category of document (open string: report,
|
|
8
|
+
// sales-proposal, letter, lookbook, …) to:
|
|
9
|
+
// - a kernel-closed `RenderingShape` (PAGINATED / ANIMATED_SLIDES /
|
|
10
|
+
// SINGLE_PAGE) that picks the renderer,
|
|
11
|
+
// - default geometry (page format + orientation),
|
|
12
|
+
// - a default theme reference,
|
|
13
|
+
// - a skill bundle (the sub-skills the agent loads when authoring),
|
|
14
|
+
// - optional sub-agents (when category-specific work needs its own
|
|
15
|
+
// model / tools / context),
|
|
16
|
+
// - optional seed content (skeleton HTML inserted on document create).
|
|
17
|
+
//
|
|
18
|
+
// Templates are *content* (shipped by biomes / orgs / users), not
|
|
19
|
+
// kernel concepts. The kernel commits to the SHAPE of a template, not
|
|
20
|
+
// the set of templates that exist.
|
|
21
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
22
|
+
|
|
23
|
+
export * from './lib/rendering-shape';
|
|
24
|
+
export * from './lib/document-template';
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── DocumentTemplate ──
|
|
3
|
+
//
|
|
4
|
+
// The open registry entry that binds a document CATEGORY (sales-proposal,
|
|
5
|
+
// report, letter, lookbook, …) to its kernel-closed RenderingShape +
|
|
6
|
+
// default geometry + default theme + skill bundle + (optionally) sub-
|
|
7
|
+
// agents + (optionally) seed content.
|
|
8
|
+
//
|
|
9
|
+
// Templates are content. Biomes, orgs, and users contribute them.
|
|
10
|
+
// Adding a new category is shipping a new template manifest + the
|
|
11
|
+
// sub-skills it references — NEVER a kernel change.
|
|
12
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
13
|
+
|
|
14
|
+
import type { RenderingShape } from './rendering-shape';
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* Scope under which a template is registered.
|
|
18
|
+
*
|
|
19
|
+
* - `SYSTEM` — kernel/platform-shipped (today: only the document-buddy
|
|
20
|
+
* biome's built-ins ship under SYSTEM via the biome-folder seeder).
|
|
21
|
+
* - `BIOME` — contributed by an installed biome (other than the
|
|
22
|
+
* document-buddy seed).
|
|
23
|
+
* - `ORG` — authored by an organization (via the design-system-builder
|
|
24
|
+
* document-variant flow once that ships).
|
|
25
|
+
*
|
|
26
|
+
* Resolution precedence — most specific wins — is the same 5-tier rule
|
|
27
|
+
* used by skills and other biome-contributed primitives:
|
|
28
|
+
* USER > ORG > PROJECT > BIOME > SYSTEM. (Templates are scoped only
|
|
29
|
+
* to the three values above today; the wider 5-tier set leaves room
|
|
30
|
+
* for project + user template variants without a future kernel
|
|
31
|
+
* change.)
|
|
32
|
+
*/
|
|
33
|
+
export enum DocumentTemplateScope {
|
|
34
|
+
SYSTEM = 'SYSTEM',
|
|
35
|
+
BIOME = 'BIOME',
|
|
36
|
+
ORG = 'ORG',
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
/**
|
|
40
|
+
* Manifest the registry persists for one document template.
|
|
41
|
+
*
|
|
42
|
+
* `category` is intentionally a free-form string. The kernel never
|
|
43
|
+
* enumerates categories — that is the whole point of treating templates
|
|
44
|
+
* as content. Two biomes MAY ship templates in the same category (e.g.
|
|
45
|
+
* two `sales-proposal` variants); the registry surfaces both and the FE
|
|
46
|
+
* groups them by category.
|
|
47
|
+
*
|
|
48
|
+
* `skillRefs` are skill slugs the authoring agent loads on session bind.
|
|
49
|
+
* Today's pattern is hierarchical (e.g.
|
|
50
|
+
* `document-editor-rich/categories/sales-proposal`); the kernel does
|
|
51
|
+
* not interpret the strings, just hands them to skill-registry-api.
|
|
52
|
+
*
|
|
53
|
+
* `subAgents` are agent slugs delegated as sub-agents on the session's
|
|
54
|
+
* Agent Composition. The bar for declaring one is "needs its own model,
|
|
55
|
+
* tools, or context"; most templates leave this empty and rely on
|
|
56
|
+
* sub-skills (cheap, shared context).
|
|
57
|
+
*
|
|
58
|
+
* `seedContent` is optional HTML inserted into the new document's
|
|
59
|
+
* Page.content at create time. It uses the closed component-class
|
|
60
|
+
* vocabulary (see `@xemahq/document-themes-contracts`) so it renders
|
|
61
|
+
* correctly under any theme.
|
|
62
|
+
*
|
|
63
|
+
* `previewThumbnailUrl` is the URL the FE template gallery shows.
|
|
64
|
+
* Resolves to a static asset under the contributing biome's bundle.
|
|
65
|
+
*/
|
|
66
|
+
export interface DocumentTemplateManifest {
|
|
67
|
+
readonly slug: string;
|
|
68
|
+
readonly name: string;
|
|
69
|
+
readonly description: string;
|
|
70
|
+
readonly category: string;
|
|
71
|
+
readonly renderingShape: RenderingShape;
|
|
72
|
+
readonly defaultThemeRef: string;
|
|
73
|
+
readonly defaultPageFormat: string;
|
|
74
|
+
readonly defaultOrientation: 'PORTRAIT' | 'LANDSCAPE';
|
|
75
|
+
readonly skillRefs: readonly string[];
|
|
76
|
+
readonly subAgents?: readonly string[];
|
|
77
|
+
readonly seedContent?: string;
|
|
78
|
+
readonly previewThumbnailUrl?: string;
|
|
79
|
+
readonly version: string;
|
|
80
|
+
readonly scope: DocumentTemplateScope;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* Wire-shape reference to a template — `<scope>:<slug>` (system or
|
|
85
|
+
* biome) or `<scope>:<orgId>:<slug>` (org). The kb-api template
|
|
86
|
+
* registry parses these into a `DocumentTemplateManifest` lookup.
|
|
87
|
+
*/
|
|
88
|
+
export type DocumentTemplateRef = string;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── RenderingShape ──
|
|
3
|
+
//
|
|
4
|
+
// Closed kernel enum that decides WHICH renderer materialises a rich
|
|
5
|
+
// document at view, print, and export time. The only kernel-closed
|
|
6
|
+
// dimension of a document — everything else (category, theme, skill
|
|
7
|
+
// bundle) is template metadata (open).
|
|
8
|
+
//
|
|
9
|
+
// Adding a new shape is a coordinated kernel change: the enum here, the
|
|
10
|
+
// Prisma enum on `pages.rendering_shape`, the FE branch in
|
|
11
|
+
// `RichDocumentCanvas`, the server-side branch in `document-render-api`,
|
|
12
|
+
// and a new `rendering-shape/<key>/SKILL.md` so the authoring agent
|
|
13
|
+
// knows the patterns. Three shapes are sufficient for v1; resist
|
|
14
|
+
// inventing a fourth before a concrete consumer demands it.
|
|
15
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* The closed set of rendering pipelines a rich document can take.
|
|
19
|
+
*
|
|
20
|
+
* - `PAGINATED` — Paged.js in the browser preview, Chrome's native
|
|
21
|
+
* `@page` rules at PDF export time. Multi-page reports, letters,
|
|
22
|
+
* case studies, sales proposals, technical specs.
|
|
23
|
+
* - `ANIMATED_SLIDES` — Reveal.js slideshow with fragments + speaker
|
|
24
|
+
* notes + fullscreen presenter mode. PDF export via Reveal's
|
|
25
|
+
* `?print-pdf` flow (one PDF page per slide). EDIT-mode is still a
|
|
26
|
+
* vertical stack of sized sheets — Reveal only loads in PRESENT.
|
|
27
|
+
* - `SINGLE_PAGE` — One white sheet, no pagination. Envelopes, lookbook
|
|
28
|
+
* spreads, single-screen layouts.
|
|
29
|
+
*/
|
|
30
|
+
export enum RenderingShape {
|
|
31
|
+
PAGINATED = 'PAGINATED',
|
|
32
|
+
ANIMATED_SLIDES = 'ANIMATED_SLIDES',
|
|
33
|
+
SINGLE_PAGE = 'SINGLE_PAGE',
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
/** Total runtime guard projected over the closed set. */
|
|
37
|
+
const RENDERING_SHAPE_VALUES: ReadonlySet<RenderingShape> = new Set([
|
|
38
|
+
RenderingShape.PAGINATED,
|
|
39
|
+
RenderingShape.ANIMATED_SLIDES,
|
|
40
|
+
RenderingShape.SINGLE_PAGE,
|
|
41
|
+
]);
|
|
42
|
+
|
|
43
|
+
export function isRenderingShape(value: unknown): value is RenderingShape {
|
|
44
|
+
return (
|
|
45
|
+
typeof value === 'string' &&
|
|
46
|
+
RENDERING_SHAPE_VALUES.has(value as RenderingShape)
|
|
47
|
+
);
|
|
48
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── Document Themes — Kernel Contracts ──
|
|
3
|
+
//
|
|
4
|
+
// Kernel (Layer 1) contracts for the Document Theme primitive. Pure
|
|
5
|
+
// types + closed enums — zero runtime deps, no NestJS, no Prisma.
|
|
6
|
+
//
|
|
7
|
+
// A Document Theme is a swappable styling layer for rich documents:
|
|
8
|
+
// - `manifest.json` — slug, name, description, supported shapes, version
|
|
9
|
+
// - `theme.json` — token pack (CSS variables: color, type, space, …)
|
|
10
|
+
// - `theme.css` — component CSS using ONLY the closed semantic-class
|
|
11
|
+
// vocabulary declared in this package
|
|
12
|
+
//
|
|
13
|
+
// Swapping a theme on a document changes the visual identity (typography,
|
|
14
|
+
// color, spacing, callout chrome) WITHOUT touching the document content
|
|
15
|
+
// or its paper geometry. Themes are forbidden from setting page-frame
|
|
16
|
+
// width/height — that is kernel-owned via the page row's pageFormat +
|
|
17
|
+
// orientation.
|
|
18
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
19
|
+
|
|
20
|
+
export * from './lib/document-theme';
|
|
21
|
+
export * from './lib/component-vocabulary';
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── Closed component-class vocabulary ──
|
|
3
|
+
//
|
|
4
|
+
// THE contract that makes "swap the theme → boom, same content, new
|
|
5
|
+
// look" true. Skills emit ONLY these classes; themes style ONLY these
|
|
6
|
+
// classes. Adding a class is a coordinated change to the vocabulary
|
|
7
|
+
// here PLUS at least the system default theme.
|
|
8
|
+
//
|
|
9
|
+
// The classes are organised by purpose. Each group is a frozen tuple so
|
|
10
|
+
// runtime callers can iterate it deterministically (for validation,
|
|
11
|
+
// theme-completeness lints, etc.). Tests in the kb-api theme module
|
|
12
|
+
// assert every theme's `theme.css` selects every class in this list.
|
|
13
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
14
|
+
|
|
15
|
+
export const STRUCTURE_CLASSES = [
|
|
16
|
+
'xema-cover',
|
|
17
|
+
'xema-toc',
|
|
18
|
+
'xema-section',
|
|
19
|
+
'xema-sidebar',
|
|
20
|
+
'xema-footer',
|
|
21
|
+
] as const;
|
|
22
|
+
export type StructureClass = (typeof STRUCTURE_CLASSES)[number];
|
|
23
|
+
|
|
24
|
+
export const TYPE_CLASSES = [
|
|
25
|
+
'xema-display',
|
|
26
|
+
'xema-title',
|
|
27
|
+
'xema-subtitle',
|
|
28
|
+
'xema-body',
|
|
29
|
+
'xema-caption',
|
|
30
|
+
'xema-overline',
|
|
31
|
+
] as const;
|
|
32
|
+
export type TypeClass = (typeof TYPE_CLASSES)[number];
|
|
33
|
+
|
|
34
|
+
export const CALLOUT_CLASSES = [
|
|
35
|
+
'xema-callout--info',
|
|
36
|
+
'xema-callout--warn',
|
|
37
|
+
'xema-callout--success',
|
|
38
|
+
'xema-callout--danger',
|
|
39
|
+
'xema-pull-quote',
|
|
40
|
+
] as const;
|
|
41
|
+
export type CalloutClass = (typeof CALLOUT_CLASSES)[number];
|
|
42
|
+
|
|
43
|
+
export const DATA_CLASSES = [
|
|
44
|
+
'xema-data-table',
|
|
45
|
+
'xema-kpi',
|
|
46
|
+
'xema-chart',
|
|
47
|
+
'xema-figure',
|
|
48
|
+
] as const;
|
|
49
|
+
export type DataClass = (typeof DATA_CLASSES)[number];
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Slide vocabulary — emitted only by ANIMATED_SLIDES documents. Reveal.js
|
|
53
|
+
* uses native `<section>` for slide boundaries; we add the `xema-slide`
|
|
54
|
+
* class so themes can style slides as a recognisable unit + we add
|
|
55
|
+
* fragment + speaker-notes hooks under the same prefix.
|
|
56
|
+
*/
|
|
57
|
+
export const SLIDE_CLASSES = [
|
|
58
|
+
'xema-slide',
|
|
59
|
+
'xema-slide-fragment',
|
|
60
|
+
'xema-slide-notes',
|
|
61
|
+
] as const;
|
|
62
|
+
export type SlideClass = (typeof SLIDE_CLASSES)[number];
|
|
63
|
+
|
|
64
|
+
export const LETTER_CLASSES = [
|
|
65
|
+
'xema-letterhead',
|
|
66
|
+
'xema-address-block',
|
|
67
|
+
'xema-signature',
|
|
68
|
+
] as const;
|
|
69
|
+
export type LetterClass = (typeof LETTER_CLASSES)[number];
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* The union of every class in the vocabulary. Use this as the only
|
|
73
|
+
* allowed lookup type when checking whether a class belongs to the
|
|
74
|
+
* vocabulary.
|
|
75
|
+
*/
|
|
76
|
+
export type DocumentComponentClass =
|
|
77
|
+
| StructureClass
|
|
78
|
+
| TypeClass
|
|
79
|
+
| CalloutClass
|
|
80
|
+
| DataClass
|
|
81
|
+
| SlideClass
|
|
82
|
+
| LetterClass;
|
|
83
|
+
|
|
84
|
+
/** Flat readonly array for iteration / completeness checks. */
|
|
85
|
+
export const ALL_COMPONENT_CLASSES: readonly DocumentComponentClass[] = [
|
|
86
|
+
...STRUCTURE_CLASSES,
|
|
87
|
+
...TYPE_CLASSES,
|
|
88
|
+
...CALLOUT_CLASSES,
|
|
89
|
+
...DATA_CLASSES,
|
|
90
|
+
...SLIDE_CLASSES,
|
|
91
|
+
...LETTER_CLASSES,
|
|
92
|
+
];
|
|
93
|
+
|
|
94
|
+
const VOCABULARY_SET: ReadonlySet<string> = new Set(ALL_COMPONENT_CLASSES);
|
|
95
|
+
|
|
96
|
+
export function isDocumentComponentClass(
|
|
97
|
+
value: unknown,
|
|
98
|
+
): value is DocumentComponentClass {
|
|
99
|
+
return typeof value === 'string' && VOCABULARY_SET.has(value);
|
|
100
|
+
}
|