@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,171 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Typed error codes produced by the workflow plane. Every error raised by
|
|
3
|
+
* the engine, compiler, evaluator, or worker picks a code from this enum.
|
|
4
|
+
*
|
|
5
|
+
* Enum-based so:
|
|
6
|
+
* - OpenAPI emits a stable `code` field (docs/API_STANDARDS §3.5).
|
|
7
|
+
* - The retry policy can mark specific codes as non-retryable
|
|
8
|
+
* deterministically (see CompiledRetryPolicy.nonRetryableErrorTypes).
|
|
9
|
+
* - Frontend switches are exhaustive.
|
|
10
|
+
*/
|
|
11
|
+
export enum WorkflowErrorCode {
|
|
12
|
+
// Validation — the authored YAML failed JSON-Schema or semantic rules.
|
|
13
|
+
DSL_SCHEMA_INVALID = 'DSL_SCHEMA_INVALID',
|
|
14
|
+
DSL_SEMANTIC_INVALID = 'DSL_SEMANTIC_INVALID',
|
|
15
|
+
DSL_EXPRESSION_INVALID = 'DSL_EXPRESSION_INVALID',
|
|
16
|
+
DSL_CYCLE_DETECTED = 'DSL_CYCLE_DETECTED',
|
|
17
|
+
DSL_MATRIX_CARDINALITY_EXCEEDED = 'DSL_MATRIX_CARDINALITY_EXCEEDED',
|
|
18
|
+
DSL_UNKNOWN_ACTION = 'DSL_UNKNOWN_ACTION',
|
|
19
|
+
DSL_UNKNOWN_REUSABLE_WORKFLOW = 'DSL_UNKNOWN_REUSABLE_WORKFLOW',
|
|
20
|
+
/**
|
|
21
|
+
* A literal `with.agentSlug` (or `with.reviewers[].agentSlug`) value
|
|
22
|
+
* does not appear in the resolvedAgents map the engine passed to the
|
|
23
|
+
* compiler. Indicates a typo, a stale slug, or a new agent that was
|
|
24
|
+
* never seeded into llm-registry.
|
|
25
|
+
*/
|
|
26
|
+
DSL_UNKNOWN_AGENT = 'DSL_UNKNOWN_AGENT',
|
|
27
|
+
/**
|
|
28
|
+
* A literal `with.deliverableSpecRef` value does not appear in the
|
|
29
|
+
* resolvedDeliverableSpecs map. Indicates a typo or a spec that was
|
|
30
|
+
* renamed/removed from deliverable-specs-api.
|
|
31
|
+
*/
|
|
32
|
+
DSL_UNKNOWN_DELIVERABLE_SPEC = 'DSL_UNKNOWN_DELIVERABLE_SPEC',
|
|
33
|
+
/**
|
|
34
|
+
* An expression of shape `${{ needs.<job>.outputs.deliverable.content.<field> }}`
|
|
35
|
+
* (or the matrix-keyed equivalent `…outputs.byKey[<k>].deliverable.content.<field>`)
|
|
36
|
+
* reads a `<field>` that does NOT exist on the producing job's declared
|
|
37
|
+
* deliverable spec content shape. Indicates the YAML and the spec have
|
|
38
|
+
* drifted: either the expression has a typo or the spec changed shape
|
|
39
|
+
* without the workflow being updated.
|
|
40
|
+
*/
|
|
41
|
+
DSL_UNKNOWN_DELIVERABLE_FIELD = 'DSL_UNKNOWN_DELIVERABLE_FIELD',
|
|
42
|
+
DSL_VERSION_NOT_RESOLVABLE = 'DSL_VERSION_NOT_RESOLVABLE',
|
|
43
|
+
DSL_PERMISSION_ESCALATION = 'DSL_PERMISSION_ESCALATION',
|
|
44
|
+
/**
|
|
45
|
+
* A consumer expression dereferences `needs.<X>.outputs.byKey[…]` but
|
|
46
|
+
* `<X>` is either not a matrix job, or is matrix without `keyBy:`
|
|
47
|
+
* declared. Authors must add `keyBy:` upstream or switch to positional
|
|
48
|
+
* / `matrixGather:` access.
|
|
49
|
+
*/
|
|
50
|
+
DSL_MATRIX_KEY_NOT_DECLARED = 'DSL_MATRIX_KEY_NOT_DECLARED',
|
|
51
|
+
/**
|
|
52
|
+
* A consumer expression accesses a matrix upstream's outputs in a
|
|
53
|
+
* shape the runtime cannot serve — e.g. bare `.deliverables` on a
|
|
54
|
+
* matrix without `matrixGather:`, or `byKey[<non-literal-non-matrix-binding>]`,
|
|
55
|
+
* or `byKey[matrix.x.<wrongField>]` where `<wrongField>` doesn't match
|
|
56
|
+
* upstream's `keyBy:`. Compile-time fix-it carries the three valid
|
|
57
|
+
* shapes (`outputs[<n>]`, `matrixGather:`, `keyBy:` + `byKey[…]`).
|
|
58
|
+
*/
|
|
59
|
+
DSL_INVALID_MATRIX_OUTPUT_ACCESS = 'DSL_INVALID_MATRIX_OUTPUT_ACCESS',
|
|
60
|
+
/**
|
|
61
|
+
* A consumer expression of shape
|
|
62
|
+
* `${{ needs.<job>.outputs.<name>.<payload-field> }}` reaches INTO the
|
|
63
|
+
* artifact payload of an upstream's named output, but the producing
|
|
64
|
+
* job's output declaration has no schema-bearing deliverable spec
|
|
65
|
+
* (`ZOD_SCHEMA` / `JSON_SCHEMA` / `DOCUMENT_TEMPLATE` with declared
|
|
66
|
+
* frontmatter). Authors must either bind a typed spec to the output
|
|
67
|
+
* or use the `fromJSON(...)` escape hatch — silent string fallback
|
|
68
|
+
* is forbidden.
|
|
69
|
+
*/
|
|
70
|
+
DSL_FIELD_NOT_TYPED = 'DSL_FIELD_NOT_TYPED',
|
|
71
|
+
/**
|
|
72
|
+
* A consumer expression reaches into a typed payload at a path that
|
|
73
|
+
* does NOT exist on the bound deliverable spec's JSON Schema. The
|
|
74
|
+
* spec and the YAML have drifted: fix the path or update the spec.
|
|
75
|
+
*/
|
|
76
|
+
DSL_FIELD_NOT_IN_SCHEMA = 'DSL_FIELD_NOT_IN_SCHEMA',
|
|
77
|
+
|
|
78
|
+
// Compile — compile-time failure not covered above.
|
|
79
|
+
COMPILE_INTERNAL = 'COMPILE_INTERNAL',
|
|
80
|
+
/**
|
|
81
|
+
* Compile-preview was called without a resolvable projectId — neither
|
|
82
|
+
* `trigger.projectId` in the body nor the `X-Project-Id` header was
|
|
83
|
+
* supplied. Surfaced as 400 so the Workflow Builder can prompt the
|
|
84
|
+
* author to pick a project before validating drafts.
|
|
85
|
+
*/
|
|
86
|
+
COMPILE_PROJECT_ID_REQUIRED = 'COMPILE_PROJECT_ID_REQUIRED',
|
|
87
|
+
|
|
88
|
+
// Runtime — reported via the workflow runtime's activity failures.
|
|
89
|
+
RUNTIME_ACTION_FAILED = 'RUNTIME_ACTION_FAILED',
|
|
90
|
+
RUNTIME_APPROVAL_REJECTED = 'RUNTIME_APPROVAL_REJECTED',
|
|
91
|
+
RUNTIME_APPROVAL_EXPIRED = 'RUNTIME_APPROVAL_EXPIRED',
|
|
92
|
+
RUNTIME_UNKNOWN_MATRIX_ENTRY = 'RUNTIME_UNKNOWN_MATRIX_ENTRY',
|
|
93
|
+
RUNTIME_DYNAMIC_MATRIX_OVERFLOW = 'RUNTIME_DYNAMIC_MATRIX_OVERFLOW',
|
|
94
|
+
/**
|
|
95
|
+
* Two upstream matrix entries produced the same `keyBy` value. Fail-
|
|
96
|
+
* fast at dispatch time before any iteration runs — the keyed output
|
|
97
|
+
* map cannot be built unambiguously.
|
|
98
|
+
*/
|
|
99
|
+
RUNTIME_MATRIX_KEY_DUPLICATE = 'RUNTIME_MATRIX_KEY_DUPLICATE',
|
|
100
|
+
/**
|
|
101
|
+
* An upstream matrix entry doesn't carry the `keyBy` path (e.g. an
|
|
102
|
+
* entry produced by a dynamic `from:` source has no `id` field while
|
|
103
|
+
* `keyBy: id` is declared). Fail-fast at dispatch time.
|
|
104
|
+
*/
|
|
105
|
+
RUNTIME_MATRIX_KEY_MISSING_AT_BIND_TIME = 'RUNTIME_MATRIX_KEY_MISSING_AT_BIND_TIME',
|
|
106
|
+
RUNTIME_SNAPSHOT_UNREADABLE = 'RUNTIME_SNAPSHOT_UNREADABLE',
|
|
107
|
+
RUNTIME_CONCURRENCY_CONFLICT = 'RUNTIME_CONCURRENCY_CONFLICT',
|
|
108
|
+
/**
|
|
109
|
+
* `fromJSON(ref)` evaluated against an `ArtifactRef` whose payload
|
|
110
|
+
* could not be fetched or parsed as JSON at runtime. Surfaces both
|
|
111
|
+
* artifact-store transport failures and "the bytes are not JSON"
|
|
112
|
+
* cases; the `cause` carries the upstream error message. This is the
|
|
113
|
+
* runtime counterpart of `DSL_FIELD_NOT_TYPED` / `DSL_FIELD_NOT_IN_SCHEMA`
|
|
114
|
+
* for authors who opted out of compile-time validation via the
|
|
115
|
+
* `fromJSON(...)` escape hatch.
|
|
116
|
+
*/
|
|
117
|
+
DSL_PAYLOAD_PARSE_ERROR = 'DSL_PAYLOAD_PARSE_ERROR',
|
|
118
|
+
/**
|
|
119
|
+
* The agent activity harvested its workspace and ran the deliverable
|
|
120
|
+
* spec's kind handler validation. Validation failed twice: once on the
|
|
121
|
+
* initial drive, then again after the structured self-correction
|
|
122
|
+
* attempt that re-uses the same agent session. The activity surfaces
|
|
123
|
+
* both failure objects (`{ first, second }`) on the error cause and
|
|
124
|
+
* fails the activity non-retryably.
|
|
125
|
+
*/
|
|
126
|
+
DELIVERABLE_CONTRACT_VIOLATED = 'DELIVERABLE_CONTRACT_VIOLATED',
|
|
127
|
+
|
|
128
|
+
/**
|
|
129
|
+
* The workflow's `requires.variables` declares one or more entries the
|
|
130
|
+
* engine could not resolve from the org/project variable store at
|
|
131
|
+
* dispatch time. The run is never started. The error payload carries
|
|
132
|
+
* `{ missing: string[] }` so the dispatch UI can list the unconfigured
|
|
133
|
+
* keys and deep-link to the variables settings page.
|
|
134
|
+
*/
|
|
135
|
+
WORKFLOW_VARIABLES_MISSING = 'WORKFLOW_VARIABLES_MISSING',
|
|
136
|
+
|
|
137
|
+
/**
|
|
138
|
+
* One or more wallets declared under `requires.wallets` (or passed at
|
|
139
|
+
* dispatch / session-create time as additional wallets) does not
|
|
140
|
+
* exist for the target project/org scope. The error payload carries
|
|
141
|
+
* `{ missing: string[] }` so the UI can list them and offer a
|
|
142
|
+
* "create wallet" affordance.
|
|
143
|
+
*/
|
|
144
|
+
WORKFLOW_WALLET_NOT_FOUND = 'WORKFLOW_WALLET_NOT_FOUND',
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
/** Error codes that must never be retried by an activity retry policy. */
|
|
148
|
+
export const NON_RETRYABLE_WORKFLOW_ERROR_CODES: readonly WorkflowErrorCode[] = [
|
|
149
|
+
WorkflowErrorCode.DSL_SCHEMA_INVALID,
|
|
150
|
+
WorkflowErrorCode.DSL_SEMANTIC_INVALID,
|
|
151
|
+
WorkflowErrorCode.DSL_EXPRESSION_INVALID,
|
|
152
|
+
WorkflowErrorCode.DSL_CYCLE_DETECTED,
|
|
153
|
+
WorkflowErrorCode.DSL_MATRIX_CARDINALITY_EXCEEDED,
|
|
154
|
+
WorkflowErrorCode.DSL_UNKNOWN_ACTION,
|
|
155
|
+
WorkflowErrorCode.DSL_UNKNOWN_REUSABLE_WORKFLOW,
|
|
156
|
+
WorkflowErrorCode.DSL_UNKNOWN_AGENT,
|
|
157
|
+
WorkflowErrorCode.DSL_UNKNOWN_DELIVERABLE_SPEC,
|
|
158
|
+
WorkflowErrorCode.DSL_UNKNOWN_DELIVERABLE_FIELD,
|
|
159
|
+
WorkflowErrorCode.DSL_VERSION_NOT_RESOLVABLE,
|
|
160
|
+
WorkflowErrorCode.DSL_PERMISSION_ESCALATION,
|
|
161
|
+
WorkflowErrorCode.DSL_MATRIX_KEY_NOT_DECLARED,
|
|
162
|
+
WorkflowErrorCode.DSL_INVALID_MATRIX_OUTPUT_ACCESS,
|
|
163
|
+
WorkflowErrorCode.DSL_FIELD_NOT_TYPED,
|
|
164
|
+
WorkflowErrorCode.DSL_FIELD_NOT_IN_SCHEMA,
|
|
165
|
+
WorkflowErrorCode.RUNTIME_APPROVAL_REJECTED,
|
|
166
|
+
WorkflowErrorCode.RUNTIME_APPROVAL_EXPIRED,
|
|
167
|
+
WorkflowErrorCode.RUNTIME_DYNAMIC_MATRIX_OVERFLOW,
|
|
168
|
+
WorkflowErrorCode.RUNTIME_MATRIX_KEY_DUPLICATE,
|
|
169
|
+
WorkflowErrorCode.RUNTIME_MATRIX_KEY_MISSING_AT_BIND_TIME,
|
|
170
|
+
WorkflowErrorCode.DELIVERABLE_CONTRACT_VIOLATED,
|
|
171
|
+
] as const;
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { JobRunStatus, StepRunStatus } from './enums';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Projection row for a single job run in the engine's read model. Not the
|
|
5
|
+
* Temporal execution truth (that lives in Temporal history); this is the
|
|
6
|
+
* materialized view the UI queries without touching Temporal on every
|
|
7
|
+
* request.
|
|
8
|
+
*
|
|
9
|
+
* Projections are rebuilt by consuming `WorkflowEvent` records produced by
|
|
10
|
+
* the worker via activity completions and workflow signals. The read model
|
|
11
|
+
* can be recomputed from event history at any time — deterministic by
|
|
12
|
+
* construction.
|
|
13
|
+
*/
|
|
14
|
+
export interface JobRun {
|
|
15
|
+
readonly id: string;
|
|
16
|
+
readonly workflowRunId: string;
|
|
17
|
+
readonly jobKey: string;
|
|
18
|
+
/**
|
|
19
|
+
* Index within the parent job's matrix expansion. `0` for single-strategy
|
|
20
|
+
* jobs; 0..N-1 for matrix/dynamic expansions.
|
|
21
|
+
*/
|
|
22
|
+
readonly matrixIndex: number;
|
|
23
|
+
/** Matrix binding values for this instance (empty object for single-strategy). */
|
|
24
|
+
readonly matrixBinding: Readonly<Record<string, unknown>>;
|
|
25
|
+
readonly status: JobRunStatus;
|
|
26
|
+
readonly startedAt: string | null;
|
|
27
|
+
readonly completedAt: string | null;
|
|
28
|
+
/** Number of attempts Temporal made for this job (post-retry). */
|
|
29
|
+
readonly attempt: number;
|
|
30
|
+
/**
|
|
31
|
+
* Outputs from the job's action, typed by the action's output schema.
|
|
32
|
+
* Null until status reaches SUCCEEDED.
|
|
33
|
+
*/
|
|
34
|
+
readonly outputs: Readonly<Record<string, unknown>> | null;
|
|
35
|
+
/** Error record, null unless status is FAILED. */
|
|
36
|
+
readonly error: JobRunError | null;
|
|
37
|
+
/** Temporal child workflow id or activity id this job is backed by. */
|
|
38
|
+
readonly temporalHandle: string;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export interface JobRunError {
|
|
42
|
+
/** Short error type code. Used by retry policy to decide non-retryable. */
|
|
43
|
+
readonly type: string;
|
|
44
|
+
readonly message: string;
|
|
45
|
+
/** Structured details — may include validation issues or downstream trace id. */
|
|
46
|
+
readonly details: Readonly<Record<string, unknown>> | null;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/**
|
|
50
|
+
* Projection row for a single step run (one action invocation) inside a
|
|
51
|
+
* job. Most jobs have exactly one step — steps are granular enough to
|
|
52
|
+
* distinguish retries and, for composite actions like `xema/review@v3`
|
|
53
|
+
* that fan out per reviewer, the per-reviewer sub-activities.
|
|
54
|
+
*/
|
|
55
|
+
export interface StepRun {
|
|
56
|
+
readonly id: string;
|
|
57
|
+
readonly jobRunId: string;
|
|
58
|
+
readonly stepKey: string;
|
|
59
|
+
readonly status: StepRunStatus;
|
|
60
|
+
readonly startedAt: string | null;
|
|
61
|
+
readonly completedAt: string | null;
|
|
62
|
+
readonly attempt: number;
|
|
63
|
+
readonly outputs: Readonly<Record<string, unknown>> | null;
|
|
64
|
+
readonly error: JobRunError | null;
|
|
65
|
+
}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── Model Reference + Sub-Agent Binding ──
|
|
3
|
+
//
|
|
4
|
+
// Shared contract for "which model should this invocation use?" and
|
|
5
|
+
// "which delegates should the primary agent have access to?".
|
|
6
|
+
//
|
|
7
|
+
// Used by every override slot in the platform:
|
|
8
|
+
// - Session.modelSelection (agent-session-api)
|
|
9
|
+
// - Session.subAgentBindings (agent-session-api)
|
|
10
|
+
// - AgentSessionProfile.defaultModel / defaultSubAgents (llm-registry-api)
|
|
11
|
+
// - ManifestAgentBlock.defaultModel / subAgents (workspace-manifest-dsl)
|
|
12
|
+
// - workflow DSL with.model / with.subAgents (workflow-dsl)
|
|
13
|
+
// - DrivePromptParams.modelOverride (agent-runtime-bridge)
|
|
14
|
+
//
|
|
15
|
+
// Resolution chain (highest precedence first):
|
|
16
|
+
// 1. Session/run override
|
|
17
|
+
// 2. Profile default (agent-session only)
|
|
18
|
+
// 3. Manifest default
|
|
19
|
+
// 4. AgentModelOverride (project/user/org cascade)
|
|
20
|
+
// 5. Agent's modelClass strategy (built-in default)
|
|
21
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
22
|
+
|
|
23
|
+
import { z } from 'zod';
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* LLM-routing tier. The SINGLE source of truth for the closed set
|
|
27
|
+
* `utility | planning | creative | coding | review` — every other
|
|
28
|
+
* consumer (DTOs, Zod schemas, frontend lookups) MUST import from here
|
|
29
|
+
* (or re-export this enum) instead of restating the literal list.
|
|
30
|
+
*
|
|
31
|
+
* Mirrors `biomes/agent-runtime/api/llm-registry-api`'s Prisma `ModelClass` column.
|
|
32
|
+
*
|
|
33
|
+
* IMPORTANT — the one allowed copy is in `@xemahq/biome-builder`'s
|
|
34
|
+
* `contribution-schemas.ts`, because that package publishes to the
|
|
35
|
+
* public npm registry and cannot depend on this GitHub-Packages-scoped
|
|
36
|
+
* package. That copy carries a comment marker; keep both lists
|
|
37
|
+
* value-identical. The vitest at
|
|
38
|
+
* `packages/ui/biome-builder/tests/model-class-parity.spec.ts` fails
|
|
39
|
+
* fast if they drift.
|
|
40
|
+
*/
|
|
41
|
+
export enum ModelClass {
|
|
42
|
+
CODING = 'coding',
|
|
43
|
+
REVIEW = 'review',
|
|
44
|
+
CREATIVE = 'creative',
|
|
45
|
+
PLANNING = 'planning',
|
|
46
|
+
UTILITY = 'utility',
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export const MODEL_CLASS_VALUES: readonly ModelClass[] = [
|
|
50
|
+
ModelClass.CODING,
|
|
51
|
+
ModelClass.REVIEW,
|
|
52
|
+
ModelClass.CREATIVE,
|
|
53
|
+
ModelClass.PLANNING,
|
|
54
|
+
ModelClass.UTILITY,
|
|
55
|
+
];
|
|
56
|
+
|
|
57
|
+
/**
|
|
58
|
+
* Zod schema for {@link ModelClass}. Built from the enum so the literal
|
|
59
|
+
* list lives in exactly one place. Use this in any YAML/wire schema that
|
|
60
|
+
* needs to validate a model-class field.
|
|
61
|
+
*/
|
|
62
|
+
export const ModelClassSchema = z.enum(
|
|
63
|
+
MODEL_CLASS_VALUES as readonly [ModelClass, ...ModelClass[]],
|
|
64
|
+
);
|
|
65
|
+
|
|
66
|
+
export enum ModelRefKind {
|
|
67
|
+
CONCRETE = 'concrete',
|
|
68
|
+
STRATEGY = 'strategy',
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* Pin to a specific (modelId, providerSlug). The provider slug is
|
|
73
|
+
* optional only when the modelId is globally unique across credentialed
|
|
74
|
+
* providers for the org — when ambiguous, the resolver returns 400.
|
|
75
|
+
*/
|
|
76
|
+
export interface ConcreteModelRef {
|
|
77
|
+
readonly kind: ModelRefKind.CONCRETE;
|
|
78
|
+
readonly modelId: string;
|
|
79
|
+
readonly providerSlug?: string;
|
|
80
|
+
readonly temperature?: number;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* Route through the existing `ModelStrategy` cascade for a given
|
|
85
|
+
* `ModelClass`. The bound model can change without invalidating the
|
|
86
|
+
* reference (lazy resolution).
|
|
87
|
+
*/
|
|
88
|
+
export interface StrategyModelRef {
|
|
89
|
+
readonly kind: ModelRefKind.STRATEGY;
|
|
90
|
+
readonly modelClass: ModelClass;
|
|
91
|
+
readonly temperature?: number;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
export type ModelRef = ConcreteModelRef | StrategyModelRef;
|
|
95
|
+
|
|
96
|
+
export function isConcreteModelRef(ref: ModelRef): ref is ConcreteModelRef {
|
|
97
|
+
return ref.kind === ModelRefKind.CONCRETE;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
export function isStrategyModelRef(ref: ModelRef): ref is StrategyModelRef {
|
|
101
|
+
return ref.kind === ModelRefKind.STRATEGY;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
/**
|
|
105
|
+
* A runtime attachment: "while this session/step runs, mount agent
|
|
106
|
+
* `slug` as a delegate available to the primary, optionally with a
|
|
107
|
+
* model override."
|
|
108
|
+
*
|
|
109
|
+
* Intrinsic delegates (those declared in the primary's own source
|
|
110
|
+
* manifest under `permission.task.<slug>: allow`) are the floor — they
|
|
111
|
+
* are always mounted and cannot be removed by any binding layer. A
|
|
112
|
+
* binding on an intrinsic slug refines its model only.
|
|
113
|
+
*/
|
|
114
|
+
export interface SubAgentBinding {
|
|
115
|
+
readonly slug: string;
|
|
116
|
+
readonly alias?: string;
|
|
117
|
+
readonly modelOverride?: ModelRef;
|
|
118
|
+
}
|
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Compile-time mount plan — declarative list of mount keys grouped by
|
|
3
|
+
* access mode. The compiler does NOT have access to the engine's resource
|
|
4
|
+
* registries (org-scoped Postgres state), so it emits only the authored
|
|
5
|
+
* declaration shape.
|
|
6
|
+
*
|
|
7
|
+
* At dispatch time the engine resolves each declared key against the org's
|
|
8
|
+
* resource registry + the calling user's permission scope, producing a
|
|
9
|
+
* {@link ResolvedMountPlan} that the activity uses to materialize files
|
|
10
|
+
* inside `/workspace`.
|
|
11
|
+
*
|
|
12
|
+
* Read-only vs read-write is fixed at compile time: the set of authored
|
|
13
|
+
* read-write mount keys is closed (today: `deliverables`) and enforced by
|
|
14
|
+
* the compiler's mount-plan stage.
|
|
15
|
+
*/
|
|
16
|
+
export interface MountPlan {
|
|
17
|
+
readonly readOnly: readonly MountDeclaration[];
|
|
18
|
+
readonly readWrite: readonly MountDeclaration[];
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
export interface MountDeclaration {
|
|
22
|
+
/** Logical mount key as authored, e.g. `references`, `uploads`, `repos`, `deliverables`. */
|
|
23
|
+
readonly key: string;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
/** Engine-dispatch-time resolved mount plan — produced from {@link MountPlan}. */
|
|
27
|
+
export interface ResolvedMountPlan {
|
|
28
|
+
readonly readOnly: readonly ResolvedMount[];
|
|
29
|
+
readonly readWrite: readonly ResolvedMount[];
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export interface ResolvedMount {
|
|
33
|
+
readonly key: string;
|
|
34
|
+
readonly source: MountSource;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
// `AgentRunRole` is the canonical role enum defined alongside `agent-role.ts`.
|
|
38
|
+
// Imported for use within this module's `MountSource` discriminator and
|
|
39
|
+
// re-exported below for back-compat with consumers that historically
|
|
40
|
+
// imported it from this module. The `export type {}` form is required
|
|
41
|
+
// (over `export … from`) because the symbol is also referenced inline in
|
|
42
|
+
// the discriminator union below.
|
|
43
|
+
import type { AgentRunRole } from './agent-role';
|
|
44
|
+
|
|
45
|
+
// eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents
|
|
46
|
+
export type { AgentRunRole };
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Concrete source for a single mount entry. The `kind` is an enum-like
|
|
50
|
+
* discriminator; the runtime dispatches on it. Unknown kinds must fail
|
|
51
|
+
* fast (never a silent skip).
|
|
52
|
+
*
|
|
53
|
+
* The `*-definition` and `rendered-*` kinds are platform-rendered: the
|
|
54
|
+
* resolver hits llm-registry-api (or its scope-aware composition) to
|
|
55
|
+
* produce the file content. They land in the same mount-apply pipeline
|
|
56
|
+
* as user-data sources so every byte under `/workspace/` is a typed
|
|
57
|
+
* mount entry.
|
|
58
|
+
*/
|
|
59
|
+
export type MountSource =
|
|
60
|
+
| { readonly kind: 'artifact-store-collection'; readonly collectionId: string }
|
|
61
|
+
| {
|
|
62
|
+
/**
|
|
63
|
+
* Mount a single artifact-store version as a file at the entry's
|
|
64
|
+
* `relPath`. Used by activities that emit large primary outputs
|
|
65
|
+
* (e.g. `xema/http@v1` with `outputMode: artifact`) so the next
|
|
66
|
+
* agent can read the bytes from `/workspace/<slot>/<fileName>`
|
|
67
|
+
* via tools instead of having the engine inline them into the
|
|
68
|
+
* agent-run-context prompt.
|
|
69
|
+
*
|
|
70
|
+
* `payloadField` selects a string field inside the artifact's JSON
|
|
71
|
+
* payload to materialise as the file content. Omit to write the
|
|
72
|
+
* entire JSON payload (pretty-printed). When set and the value is
|
|
73
|
+
* not a string, the resolver fails fast — silent stringification
|
|
74
|
+
* would let an HTML body land as `"[object Object]"`.
|
|
75
|
+
*/
|
|
76
|
+
readonly kind: 'artifact-version';
|
|
77
|
+
readonly artifactId: string;
|
|
78
|
+
/**
|
|
79
|
+
* Monotonic per-artifact version sequence (the integer surfaced by
|
|
80
|
+
* `xema/emit-artifact@v1.outputs.version`). Used directly against
|
|
81
|
+
* `GET /artifacts/:id/versions/:version/content`. We deliberately
|
|
82
|
+
* key off the integer rather than the row PK so the wire shape
|
|
83
|
+
* lines up with the only artifact-store read endpoint that
|
|
84
|
+
* returns the canonical content.
|
|
85
|
+
*/
|
|
86
|
+
readonly version: number;
|
|
87
|
+
readonly fileName: string;
|
|
88
|
+
readonly payloadField?: string;
|
|
89
|
+
readonly contentType?: string;
|
|
90
|
+
}
|
|
91
|
+
| { readonly kind: 'kb-space'; readonly spaceId: string }
|
|
92
|
+
| {
|
|
93
|
+
/**
|
|
94
|
+
* Mount a curated subset of KB pages from a single space. Each
|
|
95
|
+
* page is materialised as its own `<pageSlug>.md` file under the
|
|
96
|
+
* entry's slot+relPath. Used by the runtime KB-mount feature
|
|
97
|
+
* (user picks individual pages/folders to attach to a live
|
|
98
|
+
* Interactive Session or Design System Builder session) — the matching
|
|
99
|
+
* `kb-space` kind is for whole-space bundles instead.
|
|
100
|
+
*
|
|
101
|
+
* `pageSlugs` MUST be non-empty; resolver fails fast otherwise
|
|
102
|
+
* so an empty selection cannot silently materialise a zero-byte
|
|
103
|
+
* mount. Duplicate slugs are de-duplicated by the resolver.
|
|
104
|
+
*/
|
|
105
|
+
readonly kind: 'kb-pages';
|
|
106
|
+
readonly spaceId: string;
|
|
107
|
+
readonly pageSlugs: readonly string[];
|
|
108
|
+
}
|
|
109
|
+
| { readonly kind: 'scm-repo'; readonly repoRef: string; readonly ref: string }
|
|
110
|
+
| { readonly kind: 'session-attachment'; readonly sessionId: string }
|
|
111
|
+
| { readonly kind: 'deliverable-specs'; readonly contractKey: string }
|
|
112
|
+
| { readonly kind: 'deliverables'; readonly contractKey: string }
|
|
113
|
+
| { readonly kind: 'static-literal'; readonly pathWithinWorkspace: string; readonly bytes: string }
|
|
114
|
+
// Platform-rendered (PR 1 of unified-workspace-image refactor):
|
|
115
|
+
| {
|
|
116
|
+
readonly kind: 'agent-definition';
|
|
117
|
+
readonly orgId: string;
|
|
118
|
+
readonly agentSlug: string;
|
|
119
|
+
readonly groupKey: string;
|
|
120
|
+
/**
|
|
121
|
+
* Frontmatter `mode` for the rendered .opencode/agents/<slug>.md
|
|
122
|
+
* file. Per OpenCode docs, primary agents and sub-agents share the
|
|
123
|
+
* same directory and are differentiated by frontmatter.
|
|
124
|
+
*/
|
|
125
|
+
readonly agentMode: 'primary' | 'subagent';
|
|
126
|
+
}
|
|
127
|
+
| {
|
|
128
|
+
/**
|
|
129
|
+
* Mount a complete skill BUNDLE — SKILL.md plus every bundled
|
|
130
|
+
* resource (reference docs, scripts, assets, templates) — as a
|
|
131
|
+
* directory under the `skill-bundles` slot. The resolver fetches
|
|
132
|
+
* the multi-file bundle from skill-registry-api; the mount entry's
|
|
133
|
+
* `relPath` is the skill directory (`<skillKey>`) and the resolver
|
|
134
|
+
* yields one file per bundle member.
|
|
135
|
+
*/
|
|
136
|
+
readonly kind: 'skill-bundle';
|
|
137
|
+
readonly skillKey: string;
|
|
138
|
+
}
|
|
139
|
+
| {
|
|
140
|
+
readonly kind: 'instruction-section';
|
|
141
|
+
readonly orgId: string;
|
|
142
|
+
readonly sectionKey: string;
|
|
143
|
+
readonly agentSlug?: string;
|
|
144
|
+
readonly groupKey?: string;
|
|
145
|
+
}
|
|
146
|
+
| ({ readonly kind: 'rendered-agents-md' } & RenderedAgentRunContextParams)
|
|
147
|
+
| ({ readonly kind: 'rendered-system-overlay' } & RenderedAgentRunContextParams)
|
|
148
|
+
| ({ readonly kind: 'rendered-context-json' } & RenderedAgentRunContextParams);
|
|
149
|
+
|
|
150
|
+
/**
|
|
151
|
+
* Shared parameter shape for the three `rendered-*` mount sources. All
|
|
152
|
+
* three resolve to bytes by calling
|
|
153
|
+
* `llm-registry-api/agent-run-context/render` once per mount-apply —
|
|
154
|
+
* the upstream returns `{agentsMd, contextJson, systemOverlay}` in a
|
|
155
|
+
* single response and each resolver yields a different field.
|
|
156
|
+
*
|
|
157
|
+
* The shape MUST be identical across the three discriminator variants
|
|
158
|
+
* so the workspace-proxy resolver-cache can coalesce the three calls
|
|
159
|
+
* by hashing the params consistently. Diverging shapes break the cache
|
|
160
|
+
* key and cause one mount-apply to issue three upstream renders
|
|
161
|
+
* instead of one (and risk the three slots seeing inconsistent
|
|
162
|
+
* contextJson/systemOverlay output if the upstream is non-deterministic
|
|
163
|
+
* on the omitted fields).
|
|
164
|
+
*
|
|
165
|
+
* Every field that affects the upstream render output must live here.
|
|
166
|
+
* Cosmetic fields not consumed by the renderer must NOT live here —
|
|
167
|
+
* they would invalidate the cache key without changing the bytes.
|
|
168
|
+
*/
|
|
169
|
+
export interface RenderedAgentRunContextParams {
|
|
170
|
+
readonly orgId: string;
|
|
171
|
+
readonly projectId: string;
|
|
172
|
+
readonly agentSlug: string;
|
|
173
|
+
readonly groupKey: string;
|
|
174
|
+
readonly role: AgentRunRole;
|
|
175
|
+
readonly sessionId?: string;
|
|
176
|
+
readonly runId?: string;
|
|
177
|
+
readonly jobRunId?: string;
|
|
178
|
+
readonly deliverableSpecRef?: string;
|
|
179
|
+
/**
|
|
180
|
+
* Workflow `with:` / `agentContext` payload, surfaced verbatim under
|
|
181
|
+
* `context.json.workflowInputs.*` so the agent can read what the
|
|
182
|
+
* caller asked for (e.g. the user's original request) without
|
|
183
|
+
* relying on a separate `inputs/prompt.md` seed file.
|
|
184
|
+
*/
|
|
185
|
+
readonly workflowInputs?: Readonly<Record<string, unknown>>;
|
|
186
|
+
/**
|
|
187
|
+
* Mounted slots and their access mode, surfaced through the renderer
|
|
188
|
+
* so `context.json.authority.mayWriteWorkspace[]` lists the slots
|
|
189
|
+
* the agent is allowed to write to. Without this the xema authority-
|
|
190
|
+
* guard hook denies every `write`/`edit`/`patch` call.
|
|
191
|
+
*/
|
|
192
|
+
readonly mounts?: ReadonlyArray<{
|
|
193
|
+
readonly mount: string;
|
|
194
|
+
readonly mode: 'read-only' | 'read-write';
|
|
195
|
+
}>;
|
|
196
|
+
/**
|
|
197
|
+
* Workflow-driven input artifacts surfaced through the renderer so
|
|
198
|
+
* the agent's AGENTS.md and `context.json` enumerate exactly which
|
|
199
|
+
* files were materialised from upstream steps. Each entry maps a
|
|
200
|
+
* single artifact-store version onto an absolute workspace path —
|
|
201
|
+
* the same path the `artifact-version` mount resolver writes.
|
|
202
|
+
*
|
|
203
|
+
* The agent doesn't have to discover these by ls'ing slot
|
|
204
|
+
* directories; they appear under `# Inputs` in AGENTS.md and as
|
|
205
|
+
* `context.json.workflow.inputArtifacts[]` so a quick `read` tool
|
|
206
|
+
* call gets the bytes.
|
|
207
|
+
*/
|
|
208
|
+
readonly inputArtifacts?: ReadonlyArray<{
|
|
209
|
+
readonly path: string;
|
|
210
|
+
readonly contentType?: string;
|
|
211
|
+
readonly sourceArtifactId: string;
|
|
212
|
+
readonly sourceVersion: number;
|
|
213
|
+
}>;
|
|
214
|
+
/**
|
|
215
|
+
* Working files materialized for the session before the first turn.
|
|
216
|
+
* The renderer mirrors this into `context.json.workingFiles[]` and
|
|
217
|
+
* extends `authority.mayWriteWorkspace[]` for every writable binding
|
|
218
|
+
* (`syncDirection !== 'up-only'`) so agents can discover + edit the
|
|
219
|
+
* real document file path deterministically.
|
|
220
|
+
*/
|
|
221
|
+
readonly workingFiles?: ReadonlyArray<{
|
|
222
|
+
readonly slug: string;
|
|
223
|
+
readonly path: string;
|
|
224
|
+
readonly format: 'markdown' | 'html' | 'json' | 'yaml' | 'text';
|
|
225
|
+
readonly syncDirection: 'down-only' | 'up-only' | 'bidirectional';
|
|
226
|
+
readonly sourceKind: string;
|
|
227
|
+
readonly sourceRef: Readonly<Record<string, string>>;
|
|
228
|
+
}>;
|
|
229
|
+
readonly hasRetryContext?: boolean;
|
|
230
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
2
|
+
// ── Complexity Tier Types ──
|
|
3
|
+
//
|
|
4
|
+
// Closed enum of complexity tiers used to size workflow runs and tune
|
|
5
|
+
// their downstream behavior (sampling, gating, deliverable depth).
|
|
6
|
+
// ═══════════════════════════════════════════════════════════════════════════
|
|
7
|
+
|
|
8
|
+
// ── Complexity Tiers ───────────────────────────────────────────────────
|
|
9
|
+
|
|
10
|
+
export const COMPLEXITY_TIERS = [
|
|
11
|
+
'simple',
|
|
12
|
+
'standard',
|
|
13
|
+
'complex',
|
|
14
|
+
'enterprise',
|
|
15
|
+
] as const;
|
|
16
|
+
|
|
17
|
+
/** Complexity tier for a pipeline run */
|
|
18
|
+
export type ComplexityTier = (typeof COMPLEXITY_TIERS)[number];
|
|
19
|
+
|
|
20
|
+
/** Set of valid complexity tiers for runtime validation */
|
|
21
|
+
export const COMPLEXITY_TIER_SET: ReadonlySet<string> = new Set(
|
|
22
|
+
COMPLEXITY_TIERS,
|
|
23
|
+
);
|
|
24
|
+
|
|
25
|
+
/**
|
|
26
|
+
* Validate whether a string is a valid ComplexityTier.
|
|
27
|
+
* Returns the typed value or undefined if invalid.
|
|
28
|
+
*/
|
|
29
|
+
export function parseComplexityTier(
|
|
30
|
+
value: string | null | undefined,
|
|
31
|
+
): ComplexityTier | undefined {
|
|
32
|
+
if (value && COMPLEXITY_TIER_SET.has(value)) {
|
|
33
|
+
return value as ComplexityTier;
|
|
34
|
+
}
|
|
35
|
+
return undefined;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
* Complexity tier with an additional 'auto' sentinel —
|
|
40
|
+
* used in DTOs / UI selectors where the user can let the system decide.
|
|
41
|
+
*/
|
|
42
|
+
export const COMPLEXITY_TIERS_WITH_AUTO = [
|
|
43
|
+
'auto',
|
|
44
|
+
...COMPLEXITY_TIERS,
|
|
45
|
+
] as const;
|
|
46
|
+
|
|
47
|
+
/** Complexity tier including the 'auto' sentinel value */
|
|
48
|
+
export type ComplexityTierOrAuto = (typeof COMPLEXITY_TIERS_WITH_AUTO)[number];
|
|
49
|
+
|
|
50
|
+
/** Set of valid complexity tiers including 'auto' for runtime validation */
|
|
51
|
+
export const COMPLEXITY_TIER_OR_AUTO_SET: ReadonlySet<string> = new Set(
|
|
52
|
+
COMPLEXITY_TIERS_WITH_AUTO,
|
|
53
|
+
);
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* Validate whether a string is a valid ComplexityTierOrAuto.
|
|
57
|
+
* Returns the typed value or undefined if invalid.
|
|
58
|
+
*/
|
|
59
|
+
export function parseComplexityTierOrAuto(
|
|
60
|
+
value: string | null | undefined,
|
|
61
|
+
): ComplexityTierOrAuto | undefined {
|
|
62
|
+
if (value && COMPLEXITY_TIER_OR_AUTO_SET.has(value)) {
|
|
63
|
+
return value as ComplexityTierOrAuto;
|
|
64
|
+
}
|
|
65
|
+
return undefined;
|
|
66
|
+
}
|
|
67
|
+
|