@vibesdotdev/external 0.0.0-stage → 1.0.0-rc.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/LICENSE +18 -0
- package/README.md +68 -2
- package/REFERENCE.md +217 -0
- package/dist/acp/index.d.ts +28 -0
- package/dist/acp/index.d.ts.map +1 -0
- package/dist/acp/index.js +31 -0
- package/dist/acp/index.js.map +1 -0
- package/dist/ambient/agent-roster-heartbeat.d.ts +67 -0
- package/dist/ambient/agent-roster-heartbeat.d.ts.map +1 -0
- package/dist/ambient/agent-roster-heartbeat.js +257 -0
- package/dist/ambient/agent-roster-heartbeat.js.map +1 -0
- package/dist/ambient/attempt.d.ts +19 -0
- package/dist/ambient/attempt.d.ts.map +1 -0
- package/dist/ambient/attempt.js +39 -0
- package/dist/ambient/attempt.js.map +1 -0
- package/dist/ambient/cloud-agent-roster-provider.impl.d.ts +13 -0
- package/dist/ambient/cloud-agent-roster-provider.impl.d.ts.map +1 -0
- package/dist/ambient/cloud-agent-roster-provider.impl.js +71 -0
- package/dist/ambient/cloud-agent-roster-provider.impl.js.map +1 -0
- package/dist/ambient/cloud-authenticated-json.d.ts +69 -0
- package/dist/ambient/cloud-authenticated-json.d.ts.map +1 -0
- package/dist/ambient/cloud-authenticated-json.js +108 -0
- package/dist/ambient/cloud-authenticated-json.js.map +1 -0
- package/dist/ambient/cloud-touch-projection.impl.d.ts +74 -0
- package/dist/ambient/cloud-touch-projection.impl.d.ts.map +1 -0
- package/dist/ambient/cloud-touch-projection.impl.js +225 -0
- package/dist/ambient/cloud-touch-projection.impl.js.map +1 -0
- package/dist/ambient/collaboration-settings.d.ts +50 -0
- package/dist/ambient/collaboration-settings.d.ts.map +1 -0
- package/dist/ambient/collaboration-settings.js +57 -0
- package/dist/ambient/collaboration-settings.js.map +1 -0
- package/dist/ambient/collision-notice.d.ts +41 -0
- package/dist/ambient/collision-notice.d.ts.map +1 -0
- package/dist/ambient/collision-notice.js +104 -0
- package/dist/ambient/collision-notice.js.map +1 -0
- package/dist/ambient/default-collision-filter.impl.d.ts +19 -0
- package/dist/ambient/default-collision-filter.impl.d.ts.map +1 -0
- package/dist/ambient/default-collision-filter.impl.js +53 -0
- package/dist/ambient/default-collision-filter.impl.js.map +1 -0
- package/dist/ambient/default-notice-formatter.impl.d.ts +4 -0
- package/dist/ambient/default-notice-formatter.impl.d.ts.map +1 -0
- package/dist/ambient/default-notice-formatter.impl.js +38 -0
- package/dist/ambient/default-notice-formatter.impl.js.map +1 -0
- package/dist/ambient/file-access-ambient-drain.impl.d.ts +21 -0
- package/dist/ambient/file-access-ambient-drain.impl.d.ts.map +1 -0
- package/dist/ambient/file-access-ambient-drain.impl.js +53 -0
- package/dist/ambient/file-access-ambient-drain.impl.js.map +1 -0
- package/dist/ambient/file-access-ambient-drain.subscription.descriptor.d.ts +27 -0
- package/dist/ambient/file-access-ambient-drain.subscription.descriptor.d.ts.map +1 -0
- package/dist/ambient/file-access-ambient-drain.subscription.descriptor.js +27 -0
- package/dist/ambient/file-access-ambient-drain.subscription.descriptor.js.map +1 -0
- package/dist/ambient/file-access-ambient-fs.impl.d.ts +45 -0
- package/dist/ambient/file-access-ambient-fs.impl.d.ts.map +1 -0
- package/dist/ambient/file-access-ambient-fs.impl.js +243 -0
- package/dist/ambient/file-access-ambient-fs.impl.js.map +1 -0
- package/dist/ambient/file-access-ambient-fs.subscription.descriptor.d.ts +32 -0
- package/dist/ambient/file-access-ambient-fs.subscription.descriptor.d.ts.map +1 -0
- package/dist/ambient/file-access-ambient-fs.subscription.descriptor.js +39 -0
- package/dist/ambient/file-access-ambient-fs.subscription.descriptor.js.map +1 -0
- package/dist/ambient/file-access-ambient.impl.d.ts +32 -0
- package/dist/ambient/file-access-ambient.impl.d.ts.map +1 -0
- package/dist/ambient/file-access-ambient.impl.js +231 -0
- package/dist/ambient/file-access-ambient.impl.js.map +1 -0
- package/dist/ambient/file-access-ambient.subscription.descriptor.d.ts +31 -0
- package/dist/ambient/file-access-ambient.subscription.descriptor.d.ts.map +1 -0
- package/dist/ambient/file-access-ambient.subscription.descriptor.js +31 -0
- package/dist/ambient/file-access-ambient.subscription.descriptor.js.map +1 -0
- package/dist/ambient/file-access-shared.d.ts +48 -0
- package/dist/ambient/file-access-shared.d.ts.map +1 -0
- package/dist/ambient/file-access-shared.js +59 -0
- package/dist/ambient/file-access-shared.js.map +1 -0
- package/dist/ambient/message-transport.impl.d.ts +47 -0
- package/dist/ambient/message-transport.impl.d.ts.map +1 -0
- package/dist/ambient/message-transport.impl.js +300 -0
- package/dist/ambient/message-transport.impl.js.map +1 -0
- package/dist/ambient/pending-notices.d.ts +11 -0
- package/dist/ambient/pending-notices.d.ts.map +1 -0
- package/dist/ambient/pending-notices.js +24 -0
- package/dist/ambient/pending-notices.js.map +1 -0
- package/dist/ambient/subsystem-overlap.impl.d.ts +60 -0
- package/dist/ambient/subsystem-overlap.impl.d.ts.map +1 -0
- package/dist/ambient/subsystem-overlap.impl.js +127 -0
- package/dist/ambient/subsystem-overlap.impl.js.map +1 -0
- package/dist/cli/dev.external.hooks-install.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.hooks-install.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.hooks-install.descriptor.js +27 -0
- package/dist/cli/dev.external.hooks-install.descriptor.js.map +1 -0
- package/dist/cli/dev.external.hooks-install.impl.d.ts +9 -0
- package/dist/cli/dev.external.hooks-install.impl.d.ts.map +1 -0
- package/dist/cli/dev.external.hooks-install.impl.js +57 -0
- package/dist/cli/dev.external.hooks-install.impl.js.map +1 -0
- package/dist/cli/dev.external.hooks-list.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.hooks-list.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.hooks-list.descriptor.js +16 -0
- package/dist/cli/dev.external.hooks-list.descriptor.js.map +1 -0
- package/dist/cli/dev.external.hooks-list.impl.d.ts +3 -0
- package/dist/cli/dev.external.hooks-list.impl.d.ts.map +1 -0
- package/dist/cli/dev.external.hooks-list.impl.js +68 -0
- package/dist/cli/dev.external.hooks-list.impl.js.map +1 -0
- package/dist/cli/dev.external.hooks-uninstall.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.hooks-uninstall.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.hooks-uninstall.descriptor.js +30 -0
- package/dist/cli/dev.external.hooks-uninstall.descriptor.js.map +1 -0
- package/dist/cli/dev.external.hooks-uninstall.impl.d.ts +9 -0
- package/dist/cli/dev.external.hooks-uninstall.impl.d.ts.map +1 -0
- package/dist/cli/dev.external.hooks-uninstall.impl.js +59 -0
- package/dist/cli/dev.external.hooks-uninstall.impl.js.map +1 -0
- package/dist/cli/dev.external.hooks.call.descriptor.d.ts +12 -0
- package/dist/cli/dev.external.hooks.call.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.hooks.call.descriptor.js +51 -0
- package/dist/cli/dev.external.hooks.call.descriptor.js.map +1 -0
- package/dist/cli/dev.external.hooks.call.impl.d.ts +6 -0
- package/dist/cli/dev.external.hooks.call.impl.d.ts.map +1 -0
- package/dist/cli/dev.external.hooks.call.impl.js +162 -0
- package/dist/cli/dev.external.hooks.call.impl.js.map +1 -0
- package/dist/cli/dev.external.hooks.descriptor.d.ts +9 -0
- package/dist/cli/dev.external.hooks.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.hooks.descriptor.js +17 -0
- package/dist/cli/dev.external.hooks.descriptor.js.map +1 -0
- package/dist/cli/dev.external.launch.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.launch.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.launch.descriptor.js +31 -0
- package/dist/cli/dev.external.launch.descriptor.js.map +1 -0
- package/dist/cli/dev.external.launch.impl.d.ts +17 -0
- package/dist/cli/dev.external.launch.impl.d.ts.map +1 -0
- package/dist/cli/dev.external.launch.impl.js +137 -0
- package/dist/cli/dev.external.launch.impl.js.map +1 -0
- package/dist/cli/dev.external.presets-apply.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.presets-apply.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.presets-apply.descriptor.js +36 -0
- package/dist/cli/dev.external.presets-apply.descriptor.js.map +1 -0
- package/dist/cli/dev.external.presets-apply.impl.d.ts +3 -0
- package/dist/cli/dev.external.presets-apply.impl.d.ts.map +1 -0
- package/dist/cli/dev.external.presets-apply.impl.js +119 -0
- package/dist/cli/dev.external.presets-apply.impl.js.map +1 -0
- package/dist/cli/dev.external.presets-list.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.presets-list.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.presets-list.descriptor.js +21 -0
- package/dist/cli/dev.external.presets-list.descriptor.js.map +1 -0
- package/dist/cli/dev.external.presets-list.impl.d.ts +3 -0
- package/dist/cli/dev.external.presets-list.impl.d.ts.map +1 -0
- package/dist/cli/dev.external.presets-list.impl.js +33 -0
- package/dist/cli/dev.external.presets-list.impl.js.map +1 -0
- package/dist/cli/dev.external.presets-show.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.presets-show.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.presets-show.descriptor.js +29 -0
- package/dist/cli/dev.external.presets-show.descriptor.js.map +1 -0
- package/dist/cli/dev.external.presets-show.impl.d.ts +7 -0
- package/dist/cli/dev.external.presets-show.impl.d.ts.map +1 -0
- package/dist/cli/dev.external.presets-show.impl.js +39 -0
- package/dist/cli/dev.external.presets-show.impl.js.map +1 -0
- package/dist/cli/dev.external.presets.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.presets.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.presets.descriptor.js +15 -0
- package/dist/cli/dev.external.presets.descriptor.js.map +1 -0
- package/dist/cli/dev.external.setup.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.setup.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.setup.descriptor.js +29 -0
- package/dist/cli/dev.external.setup.descriptor.js.map +1 -0
- package/dist/cli/dev.external.setup.impl.d.ts +3 -0
- package/dist/cli/dev.external.setup.impl.d.ts.map +1 -0
- package/dist/cli/dev.external.setup.impl.js +129 -0
- package/dist/cli/dev.external.setup.impl.js.map +1 -0
- package/dist/cli/dev.external.skills-generate.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.skills-generate.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.skills-generate.descriptor.js +43 -0
- package/dist/cli/dev.external.skills-generate.descriptor.js.map +1 -0
- package/dist/cli/dev.external.skills-generate.impl.consumer.d.ts +3 -0
- package/dist/cli/dev.external.skills-generate.impl.consumer.d.ts.map +1 -0
- package/dist/cli/dev.external.skills-generate.impl.consumer.js +140 -0
- package/dist/cli/dev.external.skills-generate.impl.consumer.js.map +1 -0
- package/dist/cli/dev.external.skills.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.skills.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.skills.descriptor.js +15 -0
- package/dist/cli/dev.external.skills.descriptor.js.map +1 -0
- package/dist/cli/dev.external.status.descriptor.d.ts +7 -0
- package/dist/cli/dev.external.status.descriptor.d.ts.map +1 -0
- package/dist/cli/dev.external.status.descriptor.js +16 -0
- package/dist/cli/dev.external.status.descriptor.js.map +1 -0
- package/dist/cli/dev.external.status.impl.d.ts +24 -0
- package/dist/cli/dev.external.status.impl.d.ts.map +1 -0
- package/dist/cli/dev.external.status.impl.js +165 -0
- package/dist/cli/dev.external.status.impl.js.map +1 -0
- package/dist/cli/launch/launch.cli-group.descriptor.d.ts +4 -0
- package/dist/cli/launch/launch.cli-group.descriptor.d.ts.map +1 -0
- package/dist/cli/launch/launch.cli-group.descriptor.js +12 -0
- package/dist/cli/launch/launch.cli-group.descriptor.js.map +1 -0
- package/dist/cli/launch/launch.harness.impl.consumer.d.ts +6 -0
- package/dist/cli/launch/launch.harness.impl.consumer.d.ts.map +1 -0
- package/dist/cli/launch/launch.harness.impl.consumer.js +55 -0
- package/dist/cli/launch/launch.harness.impl.consumer.js.map +1 -0
- package/dist/cli/launch/launch.list.descriptor.d.ts +4 -0
- package/dist/cli/launch/launch.list.descriptor.d.ts.map +1 -0
- package/dist/cli/launch/launch.list.descriptor.js +13 -0
- package/dist/cli/launch/launch.list.descriptor.js.map +1 -0
- package/dist/cli/launch/launch.list.impl.consumer.d.ts +7 -0
- package/dist/cli/launch/launch.list.impl.consumer.d.ts.map +1 -0
- package/dist/cli/launch/launch.list.impl.consumer.js +26 -0
- package/dist/cli/launch/launch.list.impl.consumer.js.map +1 -0
- package/dist/cli/launch/launch.logs.descriptor.d.ts +4 -0
- package/dist/cli/launch/launch.logs.descriptor.d.ts.map +1 -0
- package/dist/cli/launch/launch.logs.descriptor.js +30 -0
- package/dist/cli/launch/launch.logs.descriptor.js.map +1 -0
- package/dist/cli/launch/launch.logs.impl.consumer.d.ts +7 -0
- package/dist/cli/launch/launch.logs.impl.consumer.d.ts.map +1 -0
- package/dist/cli/launch/launch.logs.impl.consumer.js +78 -0
- package/dist/cli/launch/launch.logs.impl.consumer.js.map +1 -0
- package/dist/cli/launch/launch.status.descriptor.d.ts +4 -0
- package/dist/cli/launch/launch.status.descriptor.d.ts.map +1 -0
- package/dist/cli/launch/launch.status.descriptor.js +21 -0
- package/dist/cli/launch/launch.status.descriptor.js.map +1 -0
- package/dist/cli/launch/launch.status.impl.consumer.d.ts +7 -0
- package/dist/cli/launch/launch.status.impl.consumer.d.ts.map +1 -0
- package/dist/cli/launch/launch.status.impl.consumer.js +69 -0
- package/dist/cli/launch/launch.status.impl.consumer.js.map +1 -0
- package/dist/cli/plugin.d.ts +4 -0
- package/dist/cli/plugin.d.ts.map +1 -0
- package/dist/cli/plugin.js +76 -0
- package/dist/cli/plugin.js.map +1 -0
- package/dist/cli/runtime-projection.d.ts +34 -0
- package/dist/cli/runtime-projection.d.ts.map +1 -0
- package/dist/cli/runtime-projection.js +272 -0
- package/dist/cli/runtime-projection.js.map +1 -0
- package/dist/cli/stdio.d.ts +15 -0
- package/dist/cli/stdio.d.ts.map +1 -0
- package/dist/cli/stdio.js +15 -0
- package/dist/cli/stdio.js.map +1 -0
- package/dist/cli/who.descriptor.d.ts +16 -0
- package/dist/cli/who.descriptor.d.ts.map +1 -0
- package/dist/cli/who.descriptor.js +38 -0
- package/dist/cli/who.descriptor.js.map +1 -0
- package/dist/cli/who.impl.d.ts +16 -0
- package/dist/cli/who.impl.d.ts.map +1 -0
- package/dist/cli/who.impl.js +127 -0
- package/dist/cli/who.impl.js.map +1 -0
- package/dist/client/external-client.d.ts +423 -0
- package/dist/client/external-client.d.ts.map +1 -0
- package/dist/client/external-client.js +979 -0
- package/dist/client/external-client.js.map +1 -0
- package/dist/client/index.d.ts +9 -0
- package/dist/client/index.d.ts.map +1 -0
- package/dist/client/index.js +8 -0
- package/dist/client/index.js.map +1 -0
- package/dist/client/lifecycle.d.ts +25 -0
- package/dist/client/lifecycle.d.ts.map +1 -0
- package/dist/client/lifecycle.js +134 -0
- package/dist/client/lifecycle.js.map +1 -0
- package/dist/config/binary-detection.d.ts +26 -0
- package/dist/config/binary-detection.d.ts.map +1 -0
- package/dist/config/binary-detection.js +105 -0
- package/dist/config/binary-detection.js.map +1 -0
- package/dist/config/external.config.descriptor.d.ts +11 -0
- package/dist/config/external.config.descriptor.d.ts.map +1 -0
- package/dist/config/external.config.descriptor.js +41 -0
- package/dist/config/external.config.descriptor.js.map +1 -0
- package/dist/config/index.d.ts +10 -0
- package/dist/config/index.d.ts.map +1 -0
- package/dist/config/index.js +10 -0
- package/dist/config/index.js.map +1 -0
- package/dist/config/manifest.d.ts +4696 -0
- package/dist/config/manifest.d.ts.map +1 -0
- package/dist/config/manifest.js +210 -0
- package/dist/config/manifest.js.map +1 -0
- package/dist/config/read.d.ts +13 -0
- package/dist/config/read.d.ts.map +1 -0
- package/dist/config/read.js +20 -0
- package/dist/config/read.js.map +1 -0
- package/dist/consumer.d.ts +15 -0
- package/dist/consumer.d.ts.map +1 -0
- package/dist/consumer.js +15 -0
- package/dist/consumer.js.map +1 -0
- package/dist/detection/base.d.ts +71 -0
- package/dist/detection/base.d.ts.map +1 -0
- package/dist/detection/base.js +115 -0
- package/dist/detection/base.js.map +1 -0
- package/dist/detection/command-probe.d.ts +43 -0
- package/dist/detection/command-probe.d.ts.map +1 -0
- package/dist/detection/command-probe.js +75 -0
- package/dist/detection/command-probe.js.map +1 -0
- package/dist/detection/config-document.d.ts +31 -0
- package/dist/detection/config-document.d.ts.map +1 -0
- package/dist/detection/config-document.js +138 -0
- package/dist/detection/config-document.js.map +1 -0
- package/dist/detection/index.d.ts +11 -0
- package/dist/detection/index.d.ts.map +1 -0
- package/dist/detection/index.js +13 -0
- package/dist/detection/index.js.map +1 -0
- package/dist/detection/manifest-detector-helpers.d.ts +45 -0
- package/dist/detection/manifest-detector-helpers.d.ts.map +1 -0
- package/dist/detection/manifest-detector-helpers.js +198 -0
- package/dist/detection/manifest-detector-helpers.js.map +1 -0
- package/dist/detection/manifest-detector.d.ts +34 -0
- package/dist/detection/manifest-detector.d.ts.map +1 -0
- package/dist/detection/manifest-detector.js +123 -0
- package/dist/detection/manifest-detector.js.map +1 -0
- package/dist/detection/service.d.ts +99 -0
- package/dist/detection/service.d.ts.map +1 -0
- package/dist/detection/service.js +124 -0
- package/dist/detection/service.js.map +1 -0
- package/dist/detection/types.d.ts +113 -0
- package/dist/detection/types.d.ts.map +1 -0
- package/dist/detection/types.js +30 -0
- package/dist/detection/types.js.map +1 -0
- package/dist/dev.external.descriptor.d.ts +9 -0
- package/dist/dev.external.descriptor.d.ts.map +1 -0
- package/dist/dev.external.descriptor.js +17 -0
- package/dist/dev.external.descriptor.js.map +1 -0
- package/dist/docs/external.ambient.docs.descriptor.d.ts +4 -0
- package/dist/docs/external.ambient.docs.descriptor.d.ts.map +1 -0
- package/dist/docs/external.ambient.docs.descriptor.js +109 -0
- package/dist/docs/external.ambient.docs.descriptor.js.map +1 -0
- package/dist/external-adapter/descriptors.d.ts +133 -0
- package/dist/external-adapter/descriptors.d.ts.map +1 -0
- package/dist/external-adapter/descriptors.js +70 -0
- package/dist/external-adapter/descriptors.js.map +1 -0
- package/dist/external-adapter/implementations.d.ts +13 -0
- package/dist/external-adapter/implementations.d.ts.map +1 -0
- package/dist/external-adapter/implementations.js +97 -0
- package/dist/external-adapter/implementations.js.map +1 -0
- package/dist/external-adapter/schemas/adapter.d.ts +66 -0
- package/dist/external-adapter/schemas/adapter.d.ts.map +1 -0
- package/dist/external-adapter/schemas/adapter.js +55 -0
- package/dist/external-adapter/schemas/adapter.js.map +1 -0
- package/dist/external-tool/impl/default-tool.d.ts +201 -0
- package/dist/external-tool/impl/default-tool.d.ts.map +1 -0
- package/dist/external-tool/impl/default-tool.js +243 -0
- package/dist/external-tool/impl/default-tool.js.map +1 -0
- package/dist/external-tool/interfaces/tool.d.ts +102 -0
- package/dist/external-tool/interfaces/tool.d.ts.map +1 -0
- package/dist/external-tool/interfaces/tool.js +2 -0
- package/dist/external-tool/interfaces/tool.js.map +1 -0
- package/dist/external-tool/loader.d.ts +5 -0
- package/dist/external-tool/loader.d.ts.map +1 -0
- package/dist/external-tool/loader.js +8 -0
- package/dist/external-tool/loader.js.map +1 -0
- package/dist/external-tool/path-template.d.ts +54 -0
- package/dist/external-tool/path-template.d.ts.map +1 -0
- package/dist/external-tool/path-template.js +65 -0
- package/dist/external-tool/path-template.js.map +1 -0
- package/dist/external-tool/runtime.d.ts +38 -0
- package/dist/external-tool/runtime.d.ts.map +1 -0
- package/dist/external-tool/runtime.js +89 -0
- package/dist/external-tool/runtime.js.map +1 -0
- package/dist/external-tool/schemas/tool.d.ts +269 -0
- package/dist/external-tool/schemas/tool.d.ts.map +1 -0
- package/dist/external-tool/schemas/tool.js +77 -0
- package/dist/external-tool/schemas/tool.js.map +1 -0
- package/dist/external.plugin.d.ts +4 -0
- package/dist/external.plugin.d.ts.map +1 -0
- package/dist/external.plugin.js +184 -0
- package/dist/external.plugin.js.map +1 -0
- package/dist/harness/agent-host-scope.d.ts +18 -0
- package/dist/harness/agent-host-scope.d.ts.map +1 -0
- package/dist/harness/agent-host-scope.js +30 -0
- package/dist/harness/agent-host-scope.js.map +1 -0
- package/dist/harness/agent-host-settings.d.ts +6 -0
- package/dist/harness/agent-host-settings.d.ts.map +1 -0
- package/dist/harness/agent-host-settings.js +18 -0
- package/dist/harness/agent-host-settings.js.map +1 -0
- package/dist/harness/agent-host.config.descriptor.d.ts +6 -0
- package/dist/harness/agent-host.config.descriptor.d.ts.map +1 -0
- package/dist/harness/agent-host.config.descriptor.js +22 -0
- package/dist/harness/agent-host.config.descriptor.js.map +1 -0
- package/dist/harness/agent-host.d.ts +98 -0
- package/dist/harness/agent-host.d.ts.map +1 -0
- package/dist/harness/agent-host.js +201 -0
- package/dist/harness/agent-host.js.map +1 -0
- package/dist/harness/command-arguments.d.ts +54 -0
- package/dist/harness/command-arguments.d.ts.map +1 -0
- package/dist/harness/command-arguments.js +113 -0
- package/dist/harness/command-arguments.js.map +1 -0
- package/dist/harness/command-execution.d.ts +20 -0
- package/dist/harness/command-execution.d.ts.map +1 -0
- package/dist/harness/command-execution.js +78 -0
- package/dist/harness/command-execution.js.map +1 -0
- package/dist/harness/command-output.d.ts +59 -0
- package/dist/harness/command-output.d.ts.map +1 -0
- package/dist/harness/command-output.js +173 -0
- package/dist/harness/command-output.js.map +1 -0
- package/dist/harness/execution-queue.d.ts +14 -0
- package/dist/harness/execution-queue.d.ts.map +1 -0
- package/dist/harness/execution-queue.js +23 -0
- package/dist/harness/execution-queue.js.map +1 -0
- package/dist/harness/index.d.ts +15 -0
- package/dist/harness/index.d.ts.map +1 -0
- package/dist/harness/index.js +12 -0
- package/dist/harness/index.js.map +1 -0
- package/dist/harness/live-tools.d.ts +130 -0
- package/dist/harness/live-tools.d.ts.map +1 -0
- package/dist/harness/live-tools.js +257 -0
- package/dist/harness/live-tools.js.map +1 -0
- package/dist/harness/managed-block.d.ts +34 -0
- package/dist/harness/managed-block.d.ts.map +1 -0
- package/dist/harness/managed-block.js +66 -0
- package/dist/harness/managed-block.js.map +1 -0
- package/dist/harness/markers.d.ts +22 -0
- package/dist/harness/markers.d.ts.map +1 -0
- package/dist/harness/markers.js +28 -0
- package/dist/harness/markers.js.map +1 -0
- package/dist/harness/node.d.ts +6 -0
- package/dist/harness/node.d.ts.map +1 -0
- package/dist/harness/node.js +6 -0
- package/dist/harness/node.js.map +1 -0
- package/dist/harness/prompt.d.ts +54 -0
- package/dist/harness/prompt.d.ts.map +1 -0
- package/dist/harness/prompt.js +78 -0
- package/dist/harness/prompt.js.map +1 -0
- package/dist/harness/prompts/index.d.ts +113 -0
- package/dist/harness/prompts/index.d.ts.map +1 -0
- package/dist/harness/prompts/index.js +5 -0
- package/dist/harness/prompts/index.js.map +1 -0
- package/dist/harness/prompts/static-briefing-note.prompt.descriptor.d.ts +114 -0
- package/dist/harness/prompts/static-briefing-note.prompt.descriptor.d.ts.map +1 -0
- package/dist/harness/prompts/static-briefing-note.prompt.descriptor.js +17 -0
- package/dist/harness/prompts/static-briefing-note.prompt.descriptor.js.map +1 -0
- package/dist/harness/prompts/system-prompt.prompt.descriptor.d.ts +114 -0
- package/dist/harness/prompts/system-prompt.prompt.descriptor.d.ts.map +1 -0
- package/dist/harness/prompts/system-prompt.prompt.descriptor.js +35 -0
- package/dist/harness/prompts/system-prompt.prompt.descriptor.js.map +1 -0
- package/dist/harness/role-prompt.d.ts +12 -0
- package/dist/harness/role-prompt.d.ts.map +1 -0
- package/dist/harness/role-prompt.js +24 -0
- package/dist/harness/role-prompt.js.map +1 -0
- package/dist/harness/runtime-transport.d.ts +89 -0
- package/dist/harness/runtime-transport.d.ts.map +1 -0
- package/dist/harness/runtime-transport.js +356 -0
- package/dist/harness/runtime-transport.js.map +1 -0
- package/dist/harness/schemas/agent-host.d.ts +142 -0
- package/dist/harness/schemas/agent-host.d.ts.map +1 -0
- package/dist/harness/schemas/agent-host.js +26 -0
- package/dist/harness/schemas/agent-host.js.map +1 -0
- package/dist/harness/stdio-sink.d.ts +35 -0
- package/dist/harness/stdio-sink.d.ts.map +1 -0
- package/dist/harness/stdio-sink.js +34 -0
- package/dist/harness/stdio-sink.js.map +1 -0
- package/dist/harness/strip-undefined.d.ts +9 -0
- package/dist/harness/strip-undefined.d.ts.map +1 -0
- package/dist/harness/strip-undefined.js +11 -0
- package/dist/harness/strip-undefined.js.map +1 -0
- package/dist/harness/tool-projection.d.ts +130 -0
- package/dist/harness/tool-projection.d.ts.map +1 -0
- package/dist/harness/tool-projection.js +195 -0
- package/dist/harness/tool-projection.js.map +1 -0
- package/dist/harness/validation-errors.d.ts +11 -0
- package/dist/harness/validation-errors.d.ts.map +1 -0
- package/dist/harness/validation-errors.js +32 -0
- package/dist/harness/validation-errors.js.map +1 -0
- package/dist/hooks/bounded-payload.d.ts +39 -0
- package/dist/hooks/bounded-payload.d.ts.map +1 -0
- package/dist/hooks/bounded-payload.js +70 -0
- package/dist/hooks/bounded-payload.js.map +1 -0
- package/dist/hooks/bridge.d.ts +34 -0
- package/dist/hooks/bridge.d.ts.map +1 -0
- package/dist/hooks/bridge.js +86 -0
- package/dist/hooks/bridge.js.map +1 -0
- package/dist/hooks/call.d.ts +298 -0
- package/dist/hooks/call.d.ts.map +1 -0
- package/dist/hooks/call.js +1550 -0
- package/dist/hooks/call.js.map +1 -0
- package/dist/hooks/consumer.d.ts +7 -0
- package/dist/hooks/consumer.d.ts.map +1 -0
- package/dist/hooks/consumer.js +5 -0
- package/dist/hooks/consumer.js.map +1 -0
- package/dist/hooks/continuity.d.ts +155 -0
- package/dist/hooks/continuity.d.ts.map +1 -0
- package/dist/hooks/continuity.js +187 -0
- package/dist/hooks/continuity.js.map +1 -0
- package/dist/hooks/dispatch-script.d.ts +27 -0
- package/dist/hooks/dispatch-script.d.ts.map +1 -0
- package/dist/hooks/dispatch-script.js +77 -0
- package/dist/hooks/dispatch-script.js.map +1 -0
- package/dist/hooks/edit-targets.d.ts +23 -0
- package/dist/hooks/edit-targets.d.ts.map +1 -0
- package/dist/hooks/edit-targets.js +74 -0
- package/dist/hooks/edit-targets.js.map +1 -0
- package/dist/hooks/hook-delivery.d.ts +21 -0
- package/dist/hooks/hook-delivery.d.ts.map +1 -0
- package/dist/hooks/hook-delivery.js +87 -0
- package/dist/hooks/hook-delivery.js.map +1 -0
- package/dist/hooks/hook-seat.d.ts +37 -0
- package/dist/hooks/hook-seat.d.ts.map +1 -0
- package/dist/hooks/hook-seat.js +59 -0
- package/dist/hooks/hook-seat.js.map +1 -0
- package/dist/hooks/index.d.ts +9 -0
- package/dist/hooks/index.d.ts.map +1 -0
- package/dist/hooks/index.js +8 -0
- package/dist/hooks/index.js.map +1 -0
- package/dist/hooks/native-edit-guard.d.ts +25 -0
- package/dist/hooks/native-edit-guard.d.ts.map +1 -0
- package/dist/hooks/native-edit-guard.js +33 -0
- package/dist/hooks/native-edit-guard.js.map +1 -0
- package/dist/hooks/native-edit-locks.d.ts +54 -0
- package/dist/hooks/native-edit-locks.d.ts.map +1 -0
- package/dist/hooks/native-edit-locks.js +98 -0
- package/dist/hooks/native-edit-locks.js.map +1 -0
- package/dist/hooks/resolve-event.d.ts +13 -0
- package/dist/hooks/resolve-event.d.ts.map +1 -0
- package/dist/hooks/resolve-event.js +32 -0
- package/dist/hooks/resolve-event.js.map +1 -0
- package/dist/hooks/review-state.d.ts +22 -0
- package/dist/hooks/review-state.d.ts.map +1 -0
- package/dist/hooks/review-state.js +57 -0
- package/dist/hooks/review-state.js.map +1 -0
- package/dist/hooks/runtime.d.ts +146 -0
- package/dist/hooks/runtime.d.ts.map +1 -0
- package/dist/hooks/runtime.js +83 -0
- package/dist/hooks/runtime.js.map +1 -0
- package/dist/hooks/self-review.d.ts +14 -0
- package/dist/hooks/self-review.d.ts.map +1 -0
- package/dist/hooks/self-review.js +28 -0
- package/dist/hooks/self-review.js.map +1 -0
- package/dist/index.d.ts +41 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +33 -0
- package/dist/index.js.map +1 -0
- package/dist/ingest/logging/subagent-completions.output.descriptor.d.ts +4 -0
- package/dist/ingest/logging/subagent-completions.output.descriptor.d.ts.map +1 -0
- package/dist/ingest/logging/subagent-completions.output.descriptor.js +22 -0
- package/dist/ingest/logging/subagent-completions.output.descriptor.js.map +1 -0
- package/dist/ingest/logging/success-patterns.output.descriptor.d.ts +4 -0
- package/dist/ingest/logging/success-patterns.output.descriptor.d.ts.map +1 -0
- package/dist/ingest/logging/success-patterns.output.descriptor.js +22 -0
- package/dist/ingest/logging/success-patterns.output.descriptor.js.map +1 -0
- package/dist/ingest/logging/tool-use.output.descriptor.d.ts +4 -0
- package/dist/ingest/logging/tool-use.output.descriptor.d.ts.map +1 -0
- package/dist/ingest/logging/tool-use.output.descriptor.js +22 -0
- package/dist/ingest/logging/tool-use.output.descriptor.js.map +1 -0
- package/dist/ingest/resolve-log-paths.d.ts +16 -0
- package/dist/ingest/resolve-log-paths.d.ts.map +1 -0
- package/dist/ingest/resolve-log-paths.js +43 -0
- package/dist/ingest/resolve-log-paths.js.map +1 -0
- package/dist/ingest/schemas.d.ts +43 -0
- package/dist/ingest/schemas.d.ts.map +1 -0
- package/dist/ingest/schemas.js +46 -0
- package/dist/ingest/schemas.js.map +1 -0
- package/dist/jsonrpc/client.d.ts +129 -0
- package/dist/jsonrpc/client.d.ts.map +1 -0
- package/dist/jsonrpc/client.js +553 -0
- package/dist/jsonrpc/client.js.map +1 -0
- package/dist/jsonrpc/envelope.d.ts +37 -0
- package/dist/jsonrpc/envelope.d.ts.map +1 -0
- package/dist/jsonrpc/envelope.js +46 -0
- package/dist/jsonrpc/envelope.js.map +1 -0
- package/dist/jsonrpc/errors.d.ts +28 -0
- package/dist/jsonrpc/errors.d.ts.map +1 -0
- package/dist/jsonrpc/errors.js +110 -0
- package/dist/jsonrpc/errors.js.map +1 -0
- package/dist/jsonrpc/framing.d.ts +35 -0
- package/dist/jsonrpc/framing.d.ts.map +1 -0
- package/dist/jsonrpc/framing.js +134 -0
- package/dist/jsonrpc/framing.js.map +1 -0
- package/dist/jsonrpc/index.d.ts +11 -0
- package/dist/jsonrpc/index.d.ts.map +1 -0
- package/dist/jsonrpc/index.js +11 -0
- package/dist/jsonrpc/index.js.map +1 -0
- package/dist/jsonrpc/outcome.d.ts +25 -0
- package/dist/jsonrpc/outcome.d.ts.map +1 -0
- package/dist/jsonrpc/outcome.js +32 -0
- package/dist/jsonrpc/outcome.js.map +1 -0
- package/dist/jsonrpc/queue.d.ts +30 -0
- package/dist/jsonrpc/queue.d.ts.map +1 -0
- package/dist/jsonrpc/queue.js +113 -0
- package/dist/jsonrpc/queue.js.map +1 -0
- package/dist/jsonrpc/schemas.d.ts +74 -0
- package/dist/jsonrpc/schemas.d.ts.map +1 -0
- package/dist/jsonrpc/schemas.js +65 -0
- package/dist/jsonrpc/schemas.js.map +1 -0
- package/dist/launch/consumer/execute.d.ts +5 -0
- package/dist/launch/consumer/execute.d.ts.map +1 -0
- package/dist/launch/consumer/execute.js +358 -0
- package/dist/launch/consumer/execute.js.map +1 -0
- package/dist/launch/consumer/paths.d.ts +15 -0
- package/dist/launch/consumer/paths.d.ts.map +1 -0
- package/dist/launch/consumer/paths.js +18 -0
- package/dist/launch/consumer/paths.js.map +1 -0
- package/dist/launch/consumer/prepare.d.ts +25 -0
- package/dist/launch/consumer/prepare.d.ts.map +1 -0
- package/dist/launch/consumer/prepare.js +158 -0
- package/dist/launch/consumer/prepare.js.map +1 -0
- package/dist/launch/consumer/prompt.d.ts +18 -0
- package/dist/launch/consumer/prompt.d.ts.map +1 -0
- package/dist/launch/consumer/prompt.js +45 -0
- package/dist/launch/consumer/prompt.js.map +1 -0
- package/dist/launch/consumer/rotate-logs.d.ts +23 -0
- package/dist/launch/consumer/rotate-logs.d.ts.map +1 -0
- package/dist/launch/consumer/rotate-logs.js +43 -0
- package/dist/launch/consumer/rotate-logs.js.map +1 -0
- package/dist/launch/consumer/spawn.d.ts +38 -0
- package/dist/launch/consumer/spawn.d.ts.map +1 -0
- package/dist/launch/consumer/spawn.js +82 -0
- package/dist/launch/consumer/spawn.js.map +1 -0
- package/dist/launch/consumer/state-rows.d.ts +41 -0
- package/dist/launch/consumer/state-rows.d.ts.map +1 -0
- package/dist/launch/consumer/state-rows.js +78 -0
- package/dist/launch/consumer/state-rows.js.map +1 -0
- package/dist/launch/consumer/store.d.ts +139 -0
- package/dist/launch/consumer/store.d.ts.map +1 -0
- package/dist/launch/consumer/store.js +495 -0
- package/dist/launch/consumer/store.js.map +1 -0
- package/dist/launch/index.d.ts +5 -0
- package/dist/launch/index.d.ts.map +1 -0
- package/dist/launch/index.js +3 -0
- package/dist/launch/index.js.map +1 -0
- package/dist/launch/resolve.d.ts +9 -0
- package/dist/launch/resolve.d.ts.map +1 -0
- package/dist/launch/resolve.js +139 -0
- package/dist/launch/resolve.js.map +1 -0
- package/dist/launch/schemas.d.ts +289 -0
- package/dist/launch/schemas.d.ts.map +1 -0
- package/dist/launch/schemas.js +154 -0
- package/dist/launch/schemas.js.map +1 -0
- package/dist/launch/task-executor/external-harness.descriptor.d.ts +6 -0
- package/dist/launch/task-executor/external-harness.descriptor.d.ts.map +1 -0
- package/dist/launch/task-executor/external-harness.descriptor.js +13 -0
- package/dist/launch/task-executor/external-harness.descriptor.js.map +1 -0
- package/dist/launch/task-executor/external-harness.impl.consumer.d.ts +17 -0
- package/dist/launch/task-executor/external-harness.impl.consumer.d.ts.map +1 -0
- package/dist/launch/task-executor/external-harness.impl.consumer.js +151 -0
- package/dist/launch/task-executor/external-harness.impl.consumer.js.map +1 -0
- package/dist/launch/task-executor/isolated-workspace.d.ts +3 -0
- package/dist/launch/task-executor/isolated-workspace.d.ts.map +1 -0
- package/dist/launch/task-executor/isolated-workspace.js +3 -0
- package/dist/launch/task-executor/isolated-workspace.js.map +1 -0
- package/dist/launch/task-executor/session-locks.d.ts +28 -0
- package/dist/launch/task-executor/session-locks.d.ts.map +1 -0
- package/dist/launch/task-executor/session-locks.js +50 -0
- package/dist/launch/task-executor/session-locks.js.map +1 -0
- package/dist/pack/adapter-codegen.d.ts +38 -0
- package/dist/pack/adapter-codegen.d.ts.map +1 -0
- package/dist/pack/adapter-codegen.js +70 -0
- package/dist/pack/adapter-codegen.js.map +1 -0
- package/dist/pack/build.d.ts +48 -0
- package/dist/pack/build.d.ts.map +1 -0
- package/dist/pack/build.js +171 -0
- package/dist/pack/build.js.map +1 -0
- package/dist/pack/emitters/hooks.d.ts +14 -0
- package/dist/pack/emitters/hooks.d.ts.map +1 -0
- package/dist/pack/emitters/hooks.js +15 -0
- package/dist/pack/emitters/hooks.js.map +1 -0
- package/dist/pack/emitters/json.d.ts +10 -0
- package/dist/pack/emitters/json.d.ts.map +1 -0
- package/dist/pack/emitters/json.js +17 -0
- package/dist/pack/emitters/json.js.map +1 -0
- package/dist/pack/emitters/registry.d.ts +22 -0
- package/dist/pack/emitters/registry.d.ts.map +1 -0
- package/dist/pack/emitters/registry.js +38 -0
- package/dist/pack/emitters/registry.js.map +1 -0
- package/dist/pack/emitters/toml.d.ts +8 -0
- package/dist/pack/emitters/toml.d.ts.map +1 -0
- package/dist/pack/emitters/toml.js +28 -0
- package/dist/pack/emitters/toml.js.map +1 -0
- package/dist/pack/emitters/yaml.d.ts +8 -0
- package/dist/pack/emitters/yaml.d.ts.map +1 -0
- package/dist/pack/emitters/yaml.js +27 -0
- package/dist/pack/emitters/yaml.js.map +1 -0
- package/dist/pack/index.d.ts +11 -0
- package/dist/pack/index.d.ts.map +1 -0
- package/dist/pack/index.js +11 -0
- package/dist/pack/index.js.map +1 -0
- package/dist/pack/mcp.d.ts +28 -0
- package/dist/pack/mcp.d.ts.map +1 -0
- package/dist/pack/mcp.js +70 -0
- package/dist/pack/mcp.js.map +1 -0
- package/dist/pack/persist.d.ts +28 -0
- package/dist/pack/persist.d.ts.map +1 -0
- package/dist/pack/persist.js +35 -0
- package/dist/pack/persist.js.map +1 -0
- package/dist/pack/schema.d.ts +126 -0
- package/dist/pack/schema.d.ts.map +1 -0
- package/dist/pack/schema.js +56 -0
- package/dist/pack/schema.js.map +1 -0
- package/dist/plugins/index.d.ts +512 -0
- package/dist/plugins/index.d.ts.map +1 -0
- package/dist/plugins/index.js +25 -0
- package/dist/plugins/index.js.map +1 -0
- package/dist/plugins/installers/config-file.d.ts +21 -0
- package/dist/plugins/installers/config-file.d.ts.map +1 -0
- package/dist/plugins/installers/config-file.js +48 -0
- package/dist/plugins/installers/config-file.js.map +1 -0
- package/dist/plugins/installers/config-value.d.ts +35 -0
- package/dist/plugins/installers/config-value.d.ts.map +1 -0
- package/dist/plugins/installers/config-value.js +52 -0
- package/dist/plugins/installers/config-value.js.map +1 -0
- package/dist/plugins/installers/hooks/index.d.ts +9 -0
- package/dist/plugins/installers/hooks/index.d.ts.map +1 -0
- package/dist/plugins/installers/hooks/index.js +12 -0
- package/dist/plugins/installers/hooks/index.js.map +1 -0
- package/dist/plugins/installers/hooks/scoped-paths.d.ts +24 -0
- package/dist/plugins/installers/hooks/scoped-paths.d.ts.map +1 -0
- package/dist/plugins/installers/hooks/scoped-paths.js +80 -0
- package/dist/plugins/installers/hooks/scoped-paths.js.map +1 -0
- package/dist/plugins/installers/hooks/settings-registration.d.ts +79 -0
- package/dist/plugins/installers/hooks/settings-registration.d.ts.map +1 -0
- package/dist/plugins/installers/hooks/settings-registration.js +125 -0
- package/dist/plugins/installers/hooks/settings-registration.js.map +1 -0
- package/dist/plugins/installers/hooks/shell-installer.d.ts +21 -0
- package/dist/plugins/installers/hooks/shell-installer.d.ts.map +1 -0
- package/dist/plugins/installers/hooks/shell-installer.js +298 -0
- package/dist/plugins/installers/hooks/shell-installer.js.map +1 -0
- package/dist/plugins/installers/hooks/uninstall-backup.d.ts +19 -0
- package/dist/plugins/installers/hooks/uninstall-backup.d.ts.map +1 -0
- package/dist/plugins/installers/hooks/uninstall-backup.js +20 -0
- package/dist/plugins/installers/hooks/uninstall-backup.js.map +1 -0
- package/dist/plugins/installers/index.d.ts +58 -0
- package/dist/plugins/installers/index.d.ts.map +1 -0
- package/dist/plugins/installers/index.js +303 -0
- package/dist/plugins/installers/index.js.map +1 -0
- package/dist/plugins/installers/mcp/environment.d.ts +180 -0
- package/dist/plugins/installers/mcp/environment.d.ts.map +1 -0
- package/dist/plugins/installers/mcp/environment.js +314 -0
- package/dist/plugins/installers/mcp/environment.js.map +1 -0
- package/dist/plugins/installers/mcp/index.d.ts +9 -0
- package/dist/plugins/installers/mcp/index.d.ts.map +1 -0
- package/dist/plugins/installers/mcp/index.js +11 -0
- package/dist/plugins/installers/mcp/index.js.map +1 -0
- package/dist/plugins/installers/mcp/json-installer.d.ts +18 -0
- package/dist/plugins/installers/mcp/json-installer.d.ts.map +1 -0
- package/dist/plugins/installers/mcp/json-installer.js +155 -0
- package/dist/plugins/installers/mcp/json-installer.js.map +1 -0
- package/dist/plugins/installers/mcp/json-paths.d.ts +13 -0
- package/dist/plugins/installers/mcp/json-paths.d.ts.map +1 -0
- package/dist/plugins/installers/mcp/json-paths.js +130 -0
- package/dist/plugins/installers/mcp/json-paths.js.map +1 -0
- package/dist/plugins/installers/mcp/serve-identity.d.ts +19 -0
- package/dist/plugins/installers/mcp/serve-identity.d.ts.map +1 -0
- package/dist/plugins/installers/mcp/serve-identity.js +31 -0
- package/dist/plugins/installers/mcp/serve-identity.js.map +1 -0
- package/dist/plugins/installers/mcp/server-config.d.ts +20 -0
- package/dist/plugins/installers/mcp/server-config.d.ts.map +1 -0
- package/dist/plugins/installers/mcp/server-config.js +64 -0
- package/dist/plugins/installers/mcp/server-config.js.map +1 -0
- package/dist/plugins/installers/mcp/toml-installer.d.ts +41 -0
- package/dist/plugins/installers/mcp/toml-installer.d.ts.map +1 -0
- package/dist/plugins/installers/mcp/toml-installer.js +407 -0
- package/dist/plugins/installers/mcp/toml-installer.js.map +1 -0
- package/dist/plugins/installers/mcp/yaml-installer.d.ts +22 -0
- package/dist/plugins/installers/mcp/yaml-installer.d.ts.map +1 -0
- package/dist/plugins/installers/mcp/yaml-installer.js +156 -0
- package/dist/plugins/installers/mcp/yaml-installer.js.map +1 -0
- package/dist/plugins/installers/runtime.d.ts +42 -0
- package/dist/plugins/installers/runtime.d.ts.map +1 -0
- package/dist/plugins/installers/runtime.js +56 -0
- package/dist/plugins/installers/runtime.js.map +1 -0
- package/dist/plugins/installers/types.d.ts +306 -0
- package/dist/plugins/installers/types.d.ts.map +1 -0
- package/dist/plugins/installers/types.js +40 -0
- package/dist/plugins/installers/types.js.map +1 -0
- package/dist/plugins/schemas/index.d.ts +6 -0
- package/dist/plugins/schemas/index.d.ts.map +1 -0
- package/dist/plugins/schemas/index.js +5 -0
- package/dist/plugins/schemas/index.js.map +1 -0
- package/dist/plugins/schemas/manifest.d.ts +527 -0
- package/dist/plugins/schemas/manifest.d.ts.map +1 -0
- package/dist/plugins/schemas/manifest.js +355 -0
- package/dist/plugins/schemas/manifest.js.map +1 -0
- package/dist/plugins/tools/index.d.ts +12 -0
- package/dist/plugins/tools/index.d.ts.map +1 -0
- package/dist/plugins/tools/index.js +19 -0
- package/dist/plugins/tools/index.js.map +1 -0
- package/dist/presets/executor.d.ts +20 -0
- package/dist/presets/executor.d.ts.map +1 -0
- package/dist/presets/executor.js +629 -0
- package/dist/presets/executor.js.map +1 -0
- package/dist/presets/file-backup.d.ts +66 -0
- package/dist/presets/file-backup.d.ts.map +1 -0
- package/dist/presets/file-backup.js +108 -0
- package/dist/presets/file-backup.js.map +1 -0
- package/dist/presets/index.d.ts +11 -0
- package/dist/presets/index.d.ts.map +1 -0
- package/dist/presets/index.js +10 -0
- package/dist/presets/index.js.map +1 -0
- package/dist/presets/resolve.d.ts +32 -0
- package/dist/presets/resolve.d.ts.map +1 -0
- package/dist/presets/resolve.js +49 -0
- package/dist/presets/resolve.js.map +1 -0
- package/dist/presets/runtime.d.ts +21 -0
- package/dist/presets/runtime.d.ts.map +1 -0
- package/dist/presets/runtime.js +115 -0
- package/dist/presets/runtime.js.map +1 -0
- package/dist/projection/attestation.d.ts +43 -0
- package/dist/projection/attestation.d.ts.map +1 -0
- package/dist/projection/attestation.js +59 -0
- package/dist/projection/attestation.js.map +1 -0
- package/dist/runtime/agent-roster-provider.d.ts +75 -0
- package/dist/runtime/agent-roster-provider.d.ts.map +1 -0
- package/dist/runtime/agent-roster-provider.js +30 -0
- package/dist/runtime/agent-roster-provider.js.map +1 -0
- package/dist/runtime/external-surface-projector.d.ts +37 -0
- package/dist/runtime/external-surface-projector.d.ts.map +1 -0
- package/dist/runtime/external-surface-projector.js +21 -0
- package/dist/runtime/external-surface-projector.js.map +1 -0
- package/dist/runtime/lifecycle-task.d.ts +54 -0
- package/dist/runtime/lifecycle-task.d.ts.map +1 -0
- package/dist/runtime/lifecycle-task.js +106 -0
- package/dist/runtime/lifecycle-task.js.map +1 -0
- package/dist/runtime.d.ts +496 -0
- package/dist/runtime.d.ts.map +1 -0
- package/dist/runtime.js +168 -0
- package/dist/runtime.js.map +1 -0
- package/dist/schemas/agent-message.d.ts +136 -0
- package/dist/schemas/agent-message.d.ts.map +1 -0
- package/dist/schemas/agent-message.js +131 -0
- package/dist/schemas/agent-message.js.map +1 -0
- package/dist/schemas/agent-roster.d.ts +50 -0
- package/dist/schemas/agent-roster.d.ts.map +1 -0
- package/dist/schemas/agent-roster.js +52 -0
- package/dist/schemas/agent-roster.js.map +1 -0
- package/dist/schemas/collision.d.ts +109 -0
- package/dist/schemas/collision.d.ts.map +1 -0
- package/dist/schemas/collision.js +71 -0
- package/dist/schemas/collision.js.map +1 -0
- package/dist/schemas/context-summary.d.ts +225 -0
- package/dist/schemas/context-summary.d.ts.map +1 -0
- package/dist/schemas/context-summary.js +117 -0
- package/dist/schemas/context-summary.js.map +1 -0
- package/dist/schemas/file-access.d.ts +176 -0
- package/dist/schemas/file-access.d.ts.map +1 -0
- package/dist/schemas/file-access.js +139 -0
- package/dist/schemas/file-access.js.map +1 -0
- package/dist/schemas/hooks.d.ts +170 -0
- package/dist/schemas/hooks.d.ts.map +1 -0
- package/dist/schemas/hooks.js +171 -0
- package/dist/schemas/hooks.js.map +1 -0
- package/dist/schemas/index.d.ts +19 -0
- package/dist/schemas/index.d.ts.map +1 -0
- package/dist/schemas/index.js +17 -0
- package/dist/schemas/index.js.map +1 -0
- package/dist/schemas/path-identity.d.ts +44 -0
- package/dist/schemas/path-identity.d.ts.map +1 -0
- package/dist/schemas/path-identity.js +93 -0
- package/dist/schemas/path-identity.js.map +1 -0
- package/dist/schemas/pending-notice.d.ts +13 -0
- package/dist/schemas/pending-notice.d.ts.map +1 -0
- package/dist/schemas/pending-notice.js +5 -0
- package/dist/schemas/pending-notice.js.map +1 -0
- package/dist/schemas/presets.d.ts +1239 -0
- package/dist/schemas/presets.d.ts.map +1 -0
- package/dist/schemas/presets.js +270 -0
- package/dist/schemas/presets.js.map +1 -0
- package/dist/schemas/roster.d.ts +96 -0
- package/dist/schemas/roster.d.ts.map +1 -0
- package/dist/schemas/roster.js +310 -0
- package/dist/schemas/roster.js.map +1 -0
- package/dist/schemas/tiers.d.ts +95 -0
- package/dist/schemas/tiers.d.ts.map +1 -0
- package/dist/schemas/tiers.js +143 -0
- package/dist/schemas/tiers.js.map +1 -0
- package/dist/schemas/touch-identity.d.ts +25 -0
- package/dist/schemas/touch-identity.d.ts.map +1 -0
- package/dist/schemas/touch-identity.js +16 -0
- package/dist/schemas/touch-identity.js.map +1 -0
- package/dist/schemas/touch-projection.d.ts +157 -0
- package/dist/schemas/touch-projection.d.ts.map +1 -0
- package/dist/schemas/touch-projection.js +100 -0
- package/dist/schemas/touch-projection.js.map +1 -0
- package/dist/session-capability.d.ts +88 -0
- package/dist/session-capability.d.ts.map +1 -0
- package/dist/session-capability.js +28 -0
- package/dist/session-capability.js.map +1 -0
- package/dist/setup/index.d.ts +9 -0
- package/dist/setup/index.d.ts.map +1 -0
- package/dist/setup/index.js +8 -0
- package/dist/setup/index.js.map +1 -0
- package/dist/setup/steps/detect-tools.d.ts +9 -0
- package/dist/setup/steps/detect-tools.d.ts.map +1 -0
- package/dist/setup/steps/detect-tools.js +120 -0
- package/dist/setup/steps/detect-tools.js.map +1 -0
- package/dist/setup/steps/index.d.ts +11 -0
- package/dist/setup/steps/index.d.ts.map +1 -0
- package/dist/setup/steps/index.js +11 -0
- package/dist/setup/steps/index.js.map +1 -0
- package/dist/setup/steps/install-helpers.d.ts +9 -0
- package/dist/setup/steps/install-helpers.d.ts.map +1 -0
- package/dist/setup/steps/install-helpers.js +29 -0
- package/dist/setup/steps/install-helpers.js.map +1 -0
- package/dist/setup/steps/install.d.ts +11 -0
- package/dist/setup/steps/install.d.ts.map +1 -0
- package/dist/setup/steps/install.js +143 -0
- package/dist/setup/steps/install.js.map +1 -0
- package/dist/setup/steps/select-location.d.ts +8 -0
- package/dist/setup/steps/select-location.d.ts.map +1 -0
- package/dist/setup/steps/select-location.js +55 -0
- package/dist/setup/steps/select-location.js.map +1 -0
- package/dist/setup/steps/select-targets.d.ts +8 -0
- package/dist/setup/steps/select-targets.d.ts.map +1 -0
- package/dist/setup/steps/select-targets.js +53 -0
- package/dist/setup/steps/select-targets.js.map +1 -0
- package/dist/setup/steps/select-tiers.d.ts +8 -0
- package/dist/setup/steps/select-tiers.d.ts.map +1 -0
- package/dist/setup/steps/select-tiers.js +124 -0
- package/dist/setup/steps/select-tiers.js.map +1 -0
- package/dist/setup/types.d.ts +128 -0
- package/dist/setup/types.d.ts.map +1 -0
- package/dist/setup/types.js +28 -0
- package/dist/setup/types.js.map +1 -0
- package/dist/setup/wizard.d.ts +25 -0
- package/dist/setup/wizard.d.ts.map +1 -0
- package/dist/setup/wizard.js +182 -0
- package/dist/setup/wizard.js.map +1 -0
- package/dist/storage/agent-message.record.descriptor.d.ts +43 -0
- package/dist/storage/agent-message.record.descriptor.d.ts.map +1 -0
- package/dist/storage/agent-message.record.descriptor.js +72 -0
- package/dist/storage/agent-message.record.descriptor.js.map +1 -0
- package/dist/storage/file-access.record.descriptor.d.ts +104 -0
- package/dist/storage/file-access.record.descriptor.d.ts.map +1 -0
- package/dist/storage/file-access.record.descriptor.js +370 -0
- package/dist/storage/file-access.record.descriptor.js.map +1 -0
- package/dist/storage/touch-identity.d.ts +43 -0
- package/dist/storage/touch-identity.d.ts.map +1 -0
- package/dist/storage/touch-identity.js +155 -0
- package/dist/storage/touch-identity.js.map +1 -0
- package/dist/svelte/external-svelte.plugin.d.ts +39 -0
- package/dist/svelte/external-svelte.plugin.d.ts.map +1 -0
- package/dist/svelte/external-svelte.plugin.js +25 -0
- package/dist/svelte/index.d.ts +11 -0
- package/dist/svelte/index.d.ts.map +1 -0
- package/dist/svelte/index.js +10 -0
- package/dist/svelte/styles.css +8 -0
- package/dist/svelte/tool-widgets/ExternalToolCard.svelte +71 -0
- package/dist/svelte/tool-widgets/ExternalToolCard.svelte.d.ts +5 -0
- package/dist/svelte/tool-widgets/ExternalToolCard.svelte.d.ts.map +1 -0
- package/dist/svelte/tool-widgets/index.d.ts +3 -0
- package/dist/svelte/tool-widgets/index.d.ts.map +1 -0
- package/dist/svelte/tool-widgets/index.js +2 -0
- package/dist/svelte/tool-widgets/summary.d.ts +27 -0
- package/dist/svelte/tool-widgets/summary.d.ts.map +1 -0
- package/dist/svelte/tool-widgets/summary.js +198 -0
- package/dist/tools/index.d.ts +3 -0
- package/dist/tools/index.d.ts.map +1 -0
- package/dist/tools/index.js +2 -0
- package/dist/tools/index.js.map +1 -0
- package/dist/tools/unified/action-descriptors.d.ts +185 -0
- package/dist/tools/unified/action-descriptors.d.ts.map +1 -0
- package/dist/tools/unified/action-descriptors.js +10 -0
- package/dist/tools/unified/action-descriptors.js.map +1 -0
- package/dist/tools/unified/action-input.d.ts +7 -0
- package/dist/tools/unified/action-input.d.ts.map +1 -0
- package/dist/tools/unified/action-input.js +13 -0
- package/dist/tools/unified/action-input.js.map +1 -0
- package/dist/tools/unified/actions.d.ts +10 -0
- package/dist/tools/unified/actions.d.ts.map +1 -0
- package/dist/tools/unified/actions.js +26 -0
- package/dist/tools/unified/actions.js.map +1 -0
- package/dist/tools/unified/external.descriptor.d.ts +30 -0
- package/dist/tools/unified/external.descriptor.d.ts.map +1 -0
- package/dist/tools/unified/external.descriptor.js +27 -0
- package/dist/tools/unified/external.descriptor.js.map +1 -0
- package/dist/tools/unified/external.impl.consumer.d.ts +8 -0
- package/dist/tools/unified/external.impl.consumer.d.ts.map +1 -0
- package/dist/tools/unified/external.impl.consumer.js +38 -0
- package/dist/tools/unified/external.impl.consumer.js.map +1 -0
- package/dist/tools/unified/handlers/context-summary.d.ts +4 -0
- package/dist/tools/unified/handlers/context-summary.d.ts.map +1 -0
- package/dist/tools/unified/handlers/context-summary.js +271 -0
- package/dist/tools/unified/handlers/context-summary.js.map +1 -0
- package/dist/tools/unified/handlers/file-access-list.d.ts +4 -0
- package/dist/tools/unified/handlers/file-access-list.d.ts.map +1 -0
- package/dist/tools/unified/handlers/file-access-list.js +39 -0
- package/dist/tools/unified/handlers/file-access-list.js.map +1 -0
- package/dist/tools/unified/handlers/file-access-track.d.ts +4 -0
- package/dist/tools/unified/handlers/file-access-track.d.ts.map +1 -0
- package/dist/tools/unified/handlers/file-access-track.js +34 -0
- package/dist/tools/unified/handlers/file-access-track.js.map +1 -0
- package/dist/tools/unified/handlers/hook-call.d.ts +23 -0
- package/dist/tools/unified/handlers/hook-call.d.ts.map +1 -0
- package/dist/tools/unified/handlers/hook-call.js +86 -0
- package/dist/tools/unified/handlers/hook-call.js.map +1 -0
- package/dist/tools/unified/handlers/hook-generator.d.ts +4 -0
- package/dist/tools/unified/handlers/hook-generator.d.ts.map +1 -0
- package/dist/tools/unified/handlers/hook-generator.js +37 -0
- package/dist/tools/unified/handlers/hook-generator.js.map +1 -0
- package/dist/tools/unified/handlers/signal.d.ts +22 -0
- package/dist/tools/unified/handlers/signal.d.ts.map +1 -0
- package/dist/tools/unified/handlers/signal.js +114 -0
- package/dist/tools/unified/handlers/signal.js.map +1 -0
- package/dist/tools/unified/index.d.ts +6 -0
- package/dist/tools/unified/index.d.ts.map +1 -0
- package/dist/tools/unified/index.js +6 -0
- package/dist/tools/unified/index.js.map +1 -0
- package/dist/tools/unified/install/handler.d.ts +4 -0
- package/dist/tools/unified/install/handler.d.ts.map +1 -0
- package/dist/tools/unified/install/handler.js +17 -0
- package/dist/tools/unified/install/handler.js.map +1 -0
- package/dist/tools/unified/runtime.d.ts +35 -0
- package/dist/tools/unified/runtime.d.ts.map +1 -0
- package/dist/tools/unified/runtime.js +23 -0
- package/dist/tools/unified/runtime.js.map +1 -0
- package/dist/tools/unified/schemas.d.ts +160 -0
- package/dist/tools/unified/schemas.d.ts.map +1 -0
- package/dist/tools/unified/schemas.js +139 -0
- package/dist/tools/unified/schemas.js.map +1 -0
- package/dist/utils/fs-absence.d.ts +22 -0
- package/dist/utils/fs-absence.d.ts.map +1 -0
- package/dist/utils/fs-absence.js +37 -0
- package/dist/utils/fs-absence.js.map +1 -0
- package/dist/utils/runtime-fs.d.ts +37 -0
- package/dist/utils/runtime-fs.d.ts.map +1 -0
- package/dist/utils/runtime-fs.js +100 -0
- package/dist/utils/runtime-fs.js.map +1 -0
- package/dist/utils/toml.d.ts +26 -0
- package/dist/utils/toml.d.ts.map +1 -0
- package/dist/utils/toml.js +415 -0
- package/dist/utils/toml.js.map +1 -0
- package/package.json +263 -4
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Warm runtime client transport for external host projections.
|
|
3
|
+
*
|
|
4
|
+
* Connects to the per-workspace runtime socket via @vibesdotdev/kernel-rpc/unix.
|
|
5
|
+
* A tool call cannot spawn a process. The transport locates nothing: the
|
|
6
|
+
* host that constructs it hands in the socket (named by the runtime daemon's
|
|
7
|
+
* socket-path owner) and the workspace it serves.
|
|
8
|
+
*
|
|
9
|
+
* Everything the socket answers is untrusted: answers are schema-checked, and
|
|
10
|
+
* failure text reaching a host tool is a typed refusal's message or value-free
|
|
11
|
+
* facts, never a raw error message.
|
|
12
|
+
*/
|
|
13
|
+
import * as z from 'zod/v4';
|
|
14
|
+
import { CapabilityError, type CaughtFailure } from '@vibesdotdev/kernel';
|
|
15
|
+
import type { RpcSocketRuntime } from '@vibesdotdev/kernel-rpc/unix';
|
|
16
|
+
import { type RunVibesOptions, type RunVibesResult } from '@vibesdotdev/cli-contracts';
|
|
17
|
+
/** The reason a handed runtime socket could not be used (stale, refused, unreadable). */
|
|
18
|
+
export declare const RUNTIME_SOCKET_UNAVAILABLE = "runtime-socket-unavailable";
|
|
19
|
+
/** Whether `failure` is a transport's typed "the handed socket is unavailable". */
|
|
20
|
+
export declare function isRuntimeSocketUnavailable(failure: CaughtFailure): failure is CapabilityError;
|
|
21
|
+
/** A JSON value as the runtime socket carries it. */
|
|
22
|
+
declare const WireJsonSchema: z.ZodType<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue, z.core.$ZodTypeInternals<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue>>;
|
|
23
|
+
export type WireJson = z.output<typeof WireJsonSchema>;
|
|
24
|
+
/** A tool invocation request sent over the runtime socket. */
|
|
25
|
+
export interface RuntimeInvokeRequest {
|
|
26
|
+
readonly type: 'runtime-command';
|
|
27
|
+
readonly invokeType: 'tool';
|
|
28
|
+
readonly id: string;
|
|
29
|
+
readonly params: WireJson;
|
|
30
|
+
readonly caller: 'host-projection';
|
|
31
|
+
readonly timeout?: number;
|
|
32
|
+
}
|
|
33
|
+
/** A registry query sent over the runtime socket. */
|
|
34
|
+
export interface RuntimeQueryRequest {
|
|
35
|
+
readonly kind: string;
|
|
36
|
+
}
|
|
37
|
+
/** The runtime socket's root methods a host projection calls. */
|
|
38
|
+
export interface RuntimeSocketRoot {
|
|
39
|
+
invoke?: (payload: RuntimeInvokeRequest) => Promise<WireJson>;
|
|
40
|
+
query?: (payload: RuntimeQueryRequest) => Promise<WireJson>;
|
|
41
|
+
}
|
|
42
|
+
export type RuntimeTransportConnection = {
|
|
43
|
+
conn: {
|
|
44
|
+
close: () => Promise<void>;
|
|
45
|
+
closed?: Promise<void>;
|
|
46
|
+
};
|
|
47
|
+
root: RuntimeSocketRoot;
|
|
48
|
+
};
|
|
49
|
+
export type RuntimeTransportOptions = {
|
|
50
|
+
/** The runtime daemon socket for `workspaceRoot`, as its socket-path owner names it. */
|
|
51
|
+
socketPath: string;
|
|
52
|
+
/** The workspace this host serves; `run` refuses a command for any other cwd. */
|
|
53
|
+
workspaceRoot: string;
|
|
54
|
+
/**
|
|
55
|
+
* The runtime whose `runtime/socket` service opens the connection (the
|
|
56
|
+
* host's own runtime). Required unless `connect` is injected.
|
|
57
|
+
*/
|
|
58
|
+
runtime?: RpcSocketRuntime;
|
|
59
|
+
/** Injected connect function for testing or custom transports */
|
|
60
|
+
connect?: (socketPath: string) => Promise<RuntimeTransportConnection>;
|
|
61
|
+
signal?: AbortSignal;
|
|
62
|
+
};
|
|
63
|
+
/** One `tools/tool` descriptor as the runtime catalog answers it. */
|
|
64
|
+
declare const RuntimeToolDescriptorSchema: z.ZodObject<{
|
|
65
|
+
id: z.ZodString;
|
|
66
|
+
name: z.ZodOptional<z.ZodString>;
|
|
67
|
+
description: z.ZodOptional<z.ZodString>;
|
|
68
|
+
parameters: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodType<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue, z.core.$ZodTypeInternals<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue>>>>;
|
|
69
|
+
schemas: z.ZodOptional<z.ZodObject<{
|
|
70
|
+
input: z.ZodOptional<z.ZodType<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue, z.core.$ZodTypeInternals<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue>>>;
|
|
71
|
+
output: z.ZodOptional<z.ZodType<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue, z.core.$ZodTypeInternals<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue>>>;
|
|
72
|
+
}, z.core.$loose>>;
|
|
73
|
+
}, z.core.$loose>;
|
|
74
|
+
export type RuntimeToolDescriptor = z.output<typeof RuntimeToolDescriptorSchema>;
|
|
75
|
+
/** Connect to a runtime socket through `runtime`'s socket service and wire its root. */
|
|
76
|
+
export declare function connectRuntimeSocket(socketPath: string, runtime: RpcSocketRuntime): Promise<RuntimeTransportConnection>;
|
|
77
|
+
/** A socket-backed runner spawns nothing, so it needs no host env: options are all optional. */
|
|
78
|
+
export type RuntimeRunFn = (argv: string[], options?: Partial<RunVibesOptions>) => Promise<RunVibesResult>;
|
|
79
|
+
export type RuntimeTransport = {
|
|
80
|
+
getConnection: () => Promise<RuntimeTransportConnection | null>;
|
|
81
|
+
fetchToolCatalog: () => Promise<RuntimeToolDescriptor[] | null>;
|
|
82
|
+
invalidateToolCatalog: () => void;
|
|
83
|
+
run: RuntimeRunFn;
|
|
84
|
+
dispose: () => Promise<void>;
|
|
85
|
+
};
|
|
86
|
+
/** One host owns one workspace, connection and catalog. Dispose never closes another handle. */
|
|
87
|
+
export declare function createRuntimeTransport(options: RuntimeTransportOptions): RuntimeTransport;
|
|
88
|
+
export {};
|
|
89
|
+
//# sourceMappingURL=runtime-transport.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime-transport.d.ts","sourceRoot":"","sources":["../../src/harness/runtime-transport.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAE5B,OAAO,EACN,eAAe,EAKf,KAAK,aAAa,EAElB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,8BAA8B,CAAC;AACrE,OAAO,EAAE,KAAK,eAAe,EAAE,KAAK,cAAc,EAAE,MAAM,4BAA4B,CAAC;AAEvF,yFAAyF;AACzF,eAAO,MAAM,0BAA0B,+BAA+B,CAA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AC,EAAE,gBAAgB,CAAC;IAC3B,iEAAiE;IACjE,OAAO,CAAC,EAAE,CAAC,UAAU,EAAE,MAAM,KAAK,OAAO,CAAC,0BAA0B,CAAC,CAAC;IACtE,MAAM,CAAC,EAAE,WAAW,CAAC;CACrB,CAAC;AAEF,qEAAqE;AACrE,QAAA,MAAM,2BAA2B;;;;;;;;;iBAQxB,CAAC;AACV,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAAC,OAAO,2BAA2B,CAAC,CAAC;AAiBjF,wFAAwF;AACxF,wBAAsB,oBAAoB,CACzC,UAAU,EAAE,MAAM,EAClB,OAAO,EAAE,gBAAgB,GACvB,OAAO,CAAC,0BAA0B,CAAC,CAiCrC;AAED,gGAAgG;AAChG,MAAM,MAAM,YAAY,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,OAAO,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC,KAAK,OAAO,CAAC,cAAc,CAAC,CAAC;AAE3G,MAAM,MAAM,gBAAgB,GAAG;IAC9B,aAAa,EAAE,MAAM,OAAO,CAAC,0BAA0B,GAAG,IAAI,CAAC,CAAC;IAChE,gBAAgB,EAAE,MAAM,OAAO,CAAC,qBAAqB,EAAE,GAAG,IAAI,CAAC,CAAC;IAChE,qBAAqB,EAAE,MAAM,IAAI,CAAC;IAClC,GAAG,EAAE,YAAY,CAAC;IAClB,OAAO,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;CAC7B,CAAC;AA6CF,gGAAgG;AAChG,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,uBAAuB,GAAG,gBAAgB,CA4MzF"}
|
|
@@ -0,0 +1,356 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Warm runtime client transport for external host projections.
|
|
3
|
+
*
|
|
4
|
+
* Connects to the per-workspace runtime socket via @vibesdotdev/kernel-rpc/unix.
|
|
5
|
+
* A tool call cannot spawn a process. The transport locates nothing: the
|
|
6
|
+
* host that constructs it hands in the socket (named by the runtime daemon's
|
|
7
|
+
* socket-path owner) and the workspace it serves.
|
|
8
|
+
*
|
|
9
|
+
* Everything the socket answers is untrusted: answers are schema-checked, and
|
|
10
|
+
* failure text reaching a host tool is a typed refusal's message or value-free
|
|
11
|
+
* facts, never a raw error message.
|
|
12
|
+
*/
|
|
13
|
+
import * as z from 'zod/v4';
|
|
14
|
+
import { resolve } from '@vibesdotdev/filesystem';
|
|
15
|
+
import { CapabilityError, CaughtFailureSchema, isCapabilityError, settle, valueFreeFailure } from '@vibesdotdev/kernel';
|
|
16
|
+
import { JsonValueSchema } from '@vibesdotdev/kernel/schemas/json';
|
|
17
|
+
import {} from '@vibesdotdev/cli-contracts';
|
|
18
|
+
/** The reason a handed runtime socket could not be used (stale, refused, unreadable). */
|
|
19
|
+
export const RUNTIME_SOCKET_UNAVAILABLE = 'runtime-socket-unavailable';
|
|
20
|
+
/** Whether `failure` is a transport's typed "the handed socket is unavailable". */
|
|
21
|
+
export function isRuntimeSocketUnavailable(failure) {
|
|
22
|
+
return failure instanceof Error && isCapabilityError(failure) && failure.reason === RUNTIME_SOCKET_UNAVAILABLE;
|
|
23
|
+
}
|
|
24
|
+
/** A failure as text: a typed refusal by its own message, anything else by its value-free facts. */
|
|
25
|
+
function failureText(failure) {
|
|
26
|
+
if (failure instanceof Error && isCapabilityError(failure))
|
|
27
|
+
return failure.message;
|
|
28
|
+
const facts = valueFreeFailure(failure);
|
|
29
|
+
return facts.code ? `${facts.name} (${facts.code})` : facts.name;
|
|
30
|
+
}
|
|
31
|
+
function socketUnavailable(socketPath, workspaceRoot, detail, cause) {
|
|
32
|
+
const details = cause instanceof Error && isCapabilityError(cause)
|
|
33
|
+
? { socketPath, workspaceRoot, socketReason: cause.reason }
|
|
34
|
+
: { socketPath, workspaceRoot };
|
|
35
|
+
const options = {
|
|
36
|
+
reason: RUNTIME_SOCKET_UNAVAILABLE,
|
|
37
|
+
retryable: true,
|
|
38
|
+
details
|
|
39
|
+
};
|
|
40
|
+
if (cause !== undefined)
|
|
41
|
+
options.cause = cause;
|
|
42
|
+
return new CapabilityError(`The runtime socket ${socketPath} for ${workspaceRoot} is unavailable: ${detail}`, 'UNAVAILABLE', options);
|
|
43
|
+
}
|
|
44
|
+
/** A JSON value as the runtime socket carries it. */
|
|
45
|
+
const WireJsonSchema = JsonValueSchema;
|
|
46
|
+
/** The socket root as the wire hands it: each method checked for its request and answer at call time. */
|
|
47
|
+
const RuntimeSocketRootSchema = z.object({
|
|
48
|
+
invoke: z.function({ input: [z.custom((value) => value instanceof Object)], output: z.promise(WireJsonSchema) }).optional(),
|
|
49
|
+
query: z.function({ input: [z.custom((value) => value instanceof Object)], output: z.promise(WireJsonSchema) }).optional()
|
|
50
|
+
});
|
|
51
|
+
/** One `tools/tool` descriptor as the runtime catalog answers it. */
|
|
52
|
+
const RuntimeToolDescriptorSchema = z
|
|
53
|
+
.object({
|
|
54
|
+
id: z.string(),
|
|
55
|
+
name: z.string().optional(),
|
|
56
|
+
description: z.string().optional(),
|
|
57
|
+
parameters: z.record(z.string(), WireJsonSchema).optional(),
|
|
58
|
+
schemas: z.object({ input: WireJsonSchema.optional(), output: WireJsonSchema.optional() }).loose().optional()
|
|
59
|
+
})
|
|
60
|
+
.loose();
|
|
61
|
+
/** A catalog answer: the descriptor list, bare or under `descriptors` / `result`. */
|
|
62
|
+
const CatalogAnswerSchema = z.union([
|
|
63
|
+
z.array(RuntimeToolDescriptorSchema),
|
|
64
|
+
z.object({ descriptors: z.array(RuntimeToolDescriptorSchema) }).loose().transform((answer) => answer.descriptors),
|
|
65
|
+
z.object({ result: z.array(RuntimeToolDescriptorSchema) }).loose().transform((answer) => answer.result)
|
|
66
|
+
]);
|
|
67
|
+
/** An invoke answer's fields a host projection reads. */
|
|
68
|
+
const InvokeAnswerSchema = z
|
|
69
|
+
.object({ success: z.boolean().optional(), result: WireJsonSchema.optional(), error: z.string().optional() })
|
|
70
|
+
.loose();
|
|
71
|
+
/** Tool input on the command line: a JSON object. */
|
|
72
|
+
const ToolParamsSchema = z.record(z.string(), WireJsonSchema);
|
|
73
|
+
/** Connect to a runtime socket through `runtime`'s socket service and wire its root. */
|
|
74
|
+
export async function connectRuntimeSocket(socketPath, runtime) {
|
|
75
|
+
const { connectUnix } = await import('@vibesdotdev/kernel-rpc/unix');
|
|
76
|
+
const { wireConsumer, asRefId } = await import('@vibesdotdev/kernel-rpc');
|
|
77
|
+
let connected = await settle(() => connectUnix(socketPath, { runtime, timeoutMs: 60_000 }));
|
|
78
|
+
for (let retry = 0; !connected.ok &&
|
|
79
|
+
retry < 3 &&
|
|
80
|
+
!runtime.lifecycle.signal.aborted &&
|
|
81
|
+
isCapabilityError(connected.cause) &&
|
|
82
|
+
(connected.cause.reason === 'rpc-handshake-timeout' ||
|
|
83
|
+
connected.cause.reason === 'socket-connect-timeout' ||
|
|
84
|
+
connected.cause.reason === 'rpc-handshake-closed'); retry++) {
|
|
85
|
+
await runtime.lifecycle.delay(250 * (retry + 1));
|
|
86
|
+
if (runtime.lifecycle.signal.aborted)
|
|
87
|
+
break;
|
|
88
|
+
connected = await settle(() => connectUnix(socketPath, { runtime, timeoutMs: 60_000 }));
|
|
89
|
+
}
|
|
90
|
+
if (!connected.ok)
|
|
91
|
+
throw connected.cause;
|
|
92
|
+
const conn = connected.value;
|
|
93
|
+
try {
|
|
94
|
+
const { root } = wireConsumer({
|
|
95
|
+
rootRef: conn.rootRef,
|
|
96
|
+
send: (request) => conn.send(request),
|
|
97
|
+
openStream: (ref, channel) => conn.openStream(asRefId(ref), channel),
|
|
98
|
+
closed: conn.closed
|
|
99
|
+
});
|
|
100
|
+
return { conn, root: RuntimeSocketRootSchema.parse(root) };
|
|
101
|
+
}
|
|
102
|
+
catch (error) {
|
|
103
|
+
await conn.close();
|
|
104
|
+
throw error;
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
/** Close a discarded socket; a failure to close is returned value-free, never thrown. */
|
|
108
|
+
async function closeDiscarded(connection) {
|
|
109
|
+
try {
|
|
110
|
+
await connection.conn.close();
|
|
111
|
+
return {};
|
|
112
|
+
}
|
|
113
|
+
catch (error) {
|
|
114
|
+
return { failure: valueFreeFailure(CaughtFailureSchema.parse(error)) };
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
/** The tool input on a `tools run <id> [--input] <json>` command line, or the refusal to read it. */
|
|
118
|
+
function readToolParams(argv, toolId) {
|
|
119
|
+
for (let i = 3; i < argv.length; i++) {
|
|
120
|
+
const arg = argv[i];
|
|
121
|
+
const raw = arg === '--input' ? argv[i + 1] : arg && !arg.startsWith('-') ? arg : undefined;
|
|
122
|
+
if (raw === undefined)
|
|
123
|
+
continue;
|
|
124
|
+
let decoded;
|
|
125
|
+
try {
|
|
126
|
+
decoded = JSON.parse(raw);
|
|
127
|
+
}
|
|
128
|
+
catch (error) {
|
|
129
|
+
// A tool never runs on input it could not read.
|
|
130
|
+
return {
|
|
131
|
+
refused: {
|
|
132
|
+
exitCode: 2,
|
|
133
|
+
stdout: '',
|
|
134
|
+
stderr: `Tool ${toolId} input is not valid JSON.`,
|
|
135
|
+
failure: valueFreeFailure(CaughtFailureSchema.parse(error))
|
|
136
|
+
}
|
|
137
|
+
};
|
|
138
|
+
}
|
|
139
|
+
const parsed = ToolParamsSchema.safeParse(decoded);
|
|
140
|
+
if (!parsed.success)
|
|
141
|
+
return { refused: { exitCode: 2, stdout: '', stderr: `Tool ${toolId} input must be a JSON object.` } };
|
|
142
|
+
return { params: parsed.data };
|
|
143
|
+
}
|
|
144
|
+
return { params: {} };
|
|
145
|
+
}
|
|
146
|
+
/** One host owns one workspace, connection and catalog. Dispose never closes another handle. */
|
|
147
|
+
export function createRuntimeTransport(options) {
|
|
148
|
+
const workspaceRoot = resolve(options.workspaceRoot);
|
|
149
|
+
const socketPath = resolve(options.socketPath);
|
|
150
|
+
const runtime = options.runtime;
|
|
151
|
+
const connect = options.connect ??
|
|
152
|
+
(runtime ? (path) => connectRuntimeSocket(path, runtime) : undefined);
|
|
153
|
+
if (!connect) {
|
|
154
|
+
throw new CapabilityError('A runtime transport needs the host runtime (its socket service) or an injected connect.', 'INTERNAL', { reason: 'runtime-transport-unconfigured', retryable: false, details: { socketPath, workspaceRoot } });
|
|
155
|
+
}
|
|
156
|
+
let connectFailure;
|
|
157
|
+
let activeConnection = null;
|
|
158
|
+
let connectionPromise = null;
|
|
159
|
+
let cachedToolCatalog = null;
|
|
160
|
+
let catalogPromise = null;
|
|
161
|
+
let catalogRevision = 0;
|
|
162
|
+
let disposed = false;
|
|
163
|
+
let disposal;
|
|
164
|
+
const invalidateToolCatalog = () => {
|
|
165
|
+
catalogRevision++;
|
|
166
|
+
cachedToolCatalog = null;
|
|
167
|
+
catalogPromise = null;
|
|
168
|
+
};
|
|
169
|
+
const dispose = () => {
|
|
170
|
+
if (disposal)
|
|
171
|
+
return disposal;
|
|
172
|
+
disposed = true;
|
|
173
|
+
options.signal?.removeEventListener('abort', onAbort);
|
|
174
|
+
invalidateToolCatalog();
|
|
175
|
+
const connection = activeConnection;
|
|
176
|
+
activeConnection = null;
|
|
177
|
+
connectionPromise = null;
|
|
178
|
+
// A pending opener closes its own late result; disposal need not wait for it.
|
|
179
|
+
// The socket is being discarded: a failed close leaves nothing to recover.
|
|
180
|
+
disposal = connection ? closeDiscarded(connection).then(() => undefined) : Promise.resolve();
|
|
181
|
+
return disposal;
|
|
182
|
+
};
|
|
183
|
+
const onAbort = () => {
|
|
184
|
+
void dispose();
|
|
185
|
+
};
|
|
186
|
+
if (options.signal?.aborted)
|
|
187
|
+
void dispose();
|
|
188
|
+
else
|
|
189
|
+
options.signal?.addEventListener('abort', onAbort, { once: true });
|
|
190
|
+
/** Connect, or the typed "socket unavailable" refusal (with the value-free failure) when it cannot. */
|
|
191
|
+
const attemptConnect = async () => {
|
|
192
|
+
try {
|
|
193
|
+
return { connection: await connect(socketPath) };
|
|
194
|
+
}
|
|
195
|
+
catch (error) {
|
|
196
|
+
// The one outcome a caller may route around: the handed socket is unavailable.
|
|
197
|
+
const failure = CaughtFailureSchema.parse(error);
|
|
198
|
+
return {
|
|
199
|
+
refused: socketUnavailable(socketPath, workspaceRoot, failureText(failure), failure),
|
|
200
|
+
failure: valueFreeFailure(CaughtFailureSchema.parse(error))
|
|
201
|
+
};
|
|
202
|
+
}
|
|
203
|
+
};
|
|
204
|
+
/** Open the socket; an unavailable socket is recorded typed (surfaced by `run`) and answers null. */
|
|
205
|
+
const open = async () => {
|
|
206
|
+
if (disposed)
|
|
207
|
+
return null;
|
|
208
|
+
const attempt = await attemptConnect();
|
|
209
|
+
if ('refused' in attempt) {
|
|
210
|
+
connectFailure = attempt.refused;
|
|
211
|
+
return null;
|
|
212
|
+
}
|
|
213
|
+
const { connection } = attempt;
|
|
214
|
+
if (disposed) {
|
|
215
|
+
// The transport was disposed while opening; the late socket is discarded.
|
|
216
|
+
await closeDiscarded(connection);
|
|
217
|
+
return null;
|
|
218
|
+
}
|
|
219
|
+
activeConnection = connection;
|
|
220
|
+
const closed = () => {
|
|
221
|
+
if (activeConnection !== connection)
|
|
222
|
+
return;
|
|
223
|
+
activeConnection = null;
|
|
224
|
+
invalidateToolCatalog();
|
|
225
|
+
};
|
|
226
|
+
// A close, clean or failed, invalidates the connection; the next `run` reconnects
|
|
227
|
+
// and surfaces its own typed failure. The failed close's facts are its outcome.
|
|
228
|
+
void connection.conn.closed?.then(closed, (error) => {
|
|
229
|
+
closed();
|
|
230
|
+
return { failure: valueFreeFailure(CaughtFailureSchema.parse(error)) };
|
|
231
|
+
});
|
|
232
|
+
return connection;
|
|
233
|
+
};
|
|
234
|
+
const getConnection = () => {
|
|
235
|
+
if (disposed)
|
|
236
|
+
return Promise.resolve(null);
|
|
237
|
+
if (activeConnection)
|
|
238
|
+
return Promise.resolve(activeConnection);
|
|
239
|
+
if (connectionPromise)
|
|
240
|
+
return connectionPromise;
|
|
241
|
+
const opening = open().finally(() => {
|
|
242
|
+
if (connectionPromise === opening)
|
|
243
|
+
connectionPromise = null;
|
|
244
|
+
});
|
|
245
|
+
connectionPromise = opening;
|
|
246
|
+
return opening;
|
|
247
|
+
};
|
|
248
|
+
const fetchToolCatalog = () => {
|
|
249
|
+
if (disposed)
|
|
250
|
+
return Promise.resolve(null);
|
|
251
|
+
if (cachedToolCatalog)
|
|
252
|
+
return Promise.resolve(cachedToolCatalog);
|
|
253
|
+
if (catalogPromise)
|
|
254
|
+
return catalogPromise;
|
|
255
|
+
const revision = catalogRevision;
|
|
256
|
+
const query = (async () => {
|
|
257
|
+
try {
|
|
258
|
+
const connection = await getConnection();
|
|
259
|
+
if (!connection || !connection.root.query || disposed || revision !== catalogRevision)
|
|
260
|
+
return null;
|
|
261
|
+
const answer = await connection.root.query({ kind: 'tools/tool' });
|
|
262
|
+
if (disposed || revision !== catalogRevision || activeConnection !== connection)
|
|
263
|
+
return null;
|
|
264
|
+
const descriptors = CatalogAnswerSchema.safeParse(answer);
|
|
265
|
+
if (!descriptors.success)
|
|
266
|
+
return null;
|
|
267
|
+
cachedToolCatalog = descriptors.data;
|
|
268
|
+
return cachedToolCatalog;
|
|
269
|
+
}
|
|
270
|
+
finally {
|
|
271
|
+
if (revision === catalogRevision)
|
|
272
|
+
catalogPromise = null;
|
|
273
|
+
}
|
|
274
|
+
})();
|
|
275
|
+
catalogPromise = query;
|
|
276
|
+
return query;
|
|
277
|
+
};
|
|
278
|
+
const invokeTool = async (transport, invoke, toolId, params) => {
|
|
279
|
+
const startTime = performance.now();
|
|
280
|
+
const timeout = z.number().positive().safeParse(params.timeoutMs);
|
|
281
|
+
const request = timeout.success
|
|
282
|
+
? { type: 'runtime-command', invokeType: 'tool', id: toolId, params, caller: 'host-projection', timeout: timeout.data }
|
|
283
|
+
: { type: 'runtime-command', invokeType: 'tool', id: toolId, params, caller: 'host-projection' };
|
|
284
|
+
let raw;
|
|
285
|
+
try {
|
|
286
|
+
raw = await invoke.call(transport.root, request);
|
|
287
|
+
}
|
|
288
|
+
catch (error) {
|
|
289
|
+
const failure = CaughtFailureSchema.parse(error);
|
|
290
|
+
return {
|
|
291
|
+
exitCode: 1,
|
|
292
|
+
stdout: '',
|
|
293
|
+
stderr: `Tool ${toolId} failed: ${failureText(failure)}`,
|
|
294
|
+
durationMs: Math.round(performance.now() - startTime),
|
|
295
|
+
failure: valueFreeFailure(CaughtFailureSchema.parse(error))
|
|
296
|
+
};
|
|
297
|
+
}
|
|
298
|
+
const durationMs = Math.round(performance.now() - startTime);
|
|
299
|
+
const answer = InvokeAnswerSchema.safeParse(raw);
|
|
300
|
+
if (!answer.success) {
|
|
301
|
+
return { exitCode: 1, stdout: '', stderr: `Tool ${toolId} answered in an unreadable shape.`, durationMs };
|
|
302
|
+
}
|
|
303
|
+
if (answer.data.success !== false) {
|
|
304
|
+
const result = answer.data.result ?? raw;
|
|
305
|
+
const stdout = z.string().safeParse(result).data ?? JSON.stringify(result, null, 2);
|
|
306
|
+
return { exitCode: 0, stdout, stderr: '', durationMs };
|
|
307
|
+
}
|
|
308
|
+
return {
|
|
309
|
+
exitCode: 1,
|
|
310
|
+
stdout: answer.data.result !== undefined ? JSON.stringify(answer.data.result, null, 2) : '',
|
|
311
|
+
stderr: answer.data.error ?? `Tool ${toolId} failed`,
|
|
312
|
+
durationMs
|
|
313
|
+
};
|
|
314
|
+
};
|
|
315
|
+
const run = async (argv, runOptions) => {
|
|
316
|
+
if (disposed) {
|
|
317
|
+
throw new CapabilityError('The runtime transport was disposed.', 'UNAVAILABLE', {
|
|
318
|
+
reason: 'runtime-transport-disposed',
|
|
319
|
+
retryable: false
|
|
320
|
+
});
|
|
321
|
+
}
|
|
322
|
+
if (runOptions?.cwd && resolve(runOptions.cwd) !== workspaceRoot) {
|
|
323
|
+
throw new CapabilityError('The command cwd does not match the runtime transport workspace.', 'INVALID_INPUT', {
|
|
324
|
+
reason: 'runtime-transport-cwd-mismatch',
|
|
325
|
+
retryable: false,
|
|
326
|
+
details: { workspaceRoot }
|
|
327
|
+
});
|
|
328
|
+
}
|
|
329
|
+
if (runOptions?.signal?.aborted) {
|
|
330
|
+
return { exitCode: 1, stdout: '', stderr: 'Command aborted', cancelled: true };
|
|
331
|
+
}
|
|
332
|
+
const toolId = argv[0] === 'tools' && argv[1] === 'run' ? argv[2] : undefined;
|
|
333
|
+
if (toolId) {
|
|
334
|
+
const input = readToolParams(argv, toolId);
|
|
335
|
+
if ('refused' in input)
|
|
336
|
+
return input.refused;
|
|
337
|
+
const transport = await getConnection();
|
|
338
|
+
if (!transport) {
|
|
339
|
+
throw connectFailure ?? socketUnavailable(socketPath, workspaceRoot, `tool ${toolId} was not run`);
|
|
340
|
+
}
|
|
341
|
+
const invoke = transport.root.invoke;
|
|
342
|
+
if (!invoke) {
|
|
343
|
+
throw socketUnavailable(socketPath, workspaceRoot, `the runtime socket exposes no invoke; tool ${toolId} was not run`);
|
|
344
|
+
}
|
|
345
|
+
return invokeTool(transport, invoke, toolId, input.params);
|
|
346
|
+
}
|
|
347
|
+
// A host command cannot spawn a process.
|
|
348
|
+
return {
|
|
349
|
+
exitCode: 1,
|
|
350
|
+
stdout: '',
|
|
351
|
+
stderr: `Runtime socket did not run ${argv.join(' ') || 'the command'}.`
|
|
352
|
+
};
|
|
353
|
+
};
|
|
354
|
+
return { getConnection, fetchToolCatalog, invalidateToolCatalog, run, dispose };
|
|
355
|
+
}
|
|
356
|
+
//# sourceMappingURL=runtime-transport.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime-transport.js","sourceRoot":"","sources":["../../src/harness/runtime-transport.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAC;AAClD,OAAO,EACN,eAAe,EACf,mBAAmB,EACnB,iBAAiB,EACjB,MAAM,EACN,gBAAgB,EAGhB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,eAAe,EAAE,MAAM,kCAAkC,CAAC;AAEnE,OAAO,EAA6C,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YAC3C,IAAI,SAAS,IAAI,KAAK;gBAAE,OAAO,KAAK,CAAC,OAAO,CAAC;YAC7C,MAAM,SAAS,GAAG,MAAM,aAAa,EAAE,CAAC;YACxC,IAAI,CAAC,SAAS,EAAE,CAAC;gBAChB,MAAM,cAAc,IAAI,iBAAiB,CAAC,UAAU,EAAE,aAAa,EAAE,QAAQ,MAAM,cAAc,CAAC,CAAC;YACpG,CAAC;YACD,MAAM,MAAM,GAAG,SAAS,CAAC,IAAI,CAAC,MAAM,CAAC;YACrC,IAAI,CAAC,MAAM,EAAE,CAAC;gBACb,MAAM,iBAAiB,CAAC,UAAU,EAAE,aAAa,EAAE,8CAA8C,MAAM,cAAc,CAAC,CAAC;YACxH,CAAC;YACD,OAAO,UAAU,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;QAC5D,CAAC;QAED,yCAAyC;QACzC,OAAO;YACN,QAAQ,EAAE,CAAC;YACX,MAAM,EAAE,EAAE;YACV,MAAM,EAAE,8BAA8B,IAAI,CAAC,IAAI,CAAC,GAAG,CAAC,IAAI,aAAa,GAAG;SACxE,CAAC;IACH,CAAC,CAAC;IACF,OAAO,EAAE,aAAa,EAAE,gBAAgB,EAAE,qBAAqB,EAAE,GAAG,EAAE,OAAO,EAAE,CAAC;AACjF,CAAC"}
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The agent host's contracts.
|
|
3
|
+
*
|
|
4
|
+
* R-SCHEMA-001 keeps an exported interface or type alias in a schemas directory,
|
|
5
|
+
* so every type a host reads from this module is declared here and
|
|
6
|
+
* `./agent-host.ts` carries only behaviour. Each shape is derived from the
|
|
7
|
+
* contract it describes rather than restated: a runtime descriptor is a
|
|
8
|
+
* `RuntimeDescriptor`, a command is a `cli/command` asset, a prompt is a
|
|
9
|
+
* `prompts/manifest` asset. Nothing here invents a parallel vocabulary.
|
|
10
|
+
*/
|
|
11
|
+
import * as z from 'zod/v4';
|
|
12
|
+
import type { CLICommandAssetDescriptor, CLIGroupAssetDescriptor, CommandContext, CommandOptions } from '@vibesdotdev/cli-contracts';
|
|
13
|
+
import type { RuntimeDescriptor, RuntimePlugin, RuntimeWorkspaceCompositionRequest, ValueFreeFailure } from '@vibesdotdev/kernel';
|
|
14
|
+
import type { PromptsManifestDescriptor } from '@vibesdotdev/ai-schemas';
|
|
15
|
+
import type { LiveToolDescriptor } from '../live-tools.ts';
|
|
16
|
+
/**
|
|
17
|
+
* A JSON value, which is all that crosses a host bridge.
|
|
18
|
+
*
|
|
19
|
+
* A coding-agent host is a separate process behind a JSON boundary, so both
|
|
20
|
+
* ends of every host call are this and nothing richer: a tool's arguments
|
|
21
|
+
* arrive as JSON and its answer leaves as JSON. A value that is not JSON fails at
|
|
22
|
+
* the boundary rather than reaching a host that cannot render or forward it.
|
|
23
|
+
*/
|
|
24
|
+
export declare const HostJsonSchema: z.ZodType<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue, z.core.$ZodTypeInternals<import("@vibesdotdev/kernel/bootstrap").JsonValue, import("@vibesdotdev/kernel/bootstrap").JsonValue>>;
|
|
25
|
+
export type HostJson = z.output<typeof HostJsonSchema>;
|
|
26
|
+
/**
|
|
27
|
+
* A descriptor a host reads as identity and metadata — `ai/model`, `ai/provider`
|
|
28
|
+
* and every other kind that has no richer host contract.
|
|
29
|
+
*
|
|
30
|
+
* This is the runtime's own descriptor, not a second shape beside it: a host
|
|
31
|
+
* reads `id`, `name`, `description` and `tags`, and the owner payload a
|
|
32
|
+
* descriptor may carry is never part of what a host shows.
|
|
33
|
+
*/
|
|
34
|
+
export type AgentHostDescriptor = RuntimeDescriptor;
|
|
35
|
+
/** One command's result, as a host presents it: the text it wrote, and whether it failed. */
|
|
36
|
+
export type AgentHostCommandResult = {
|
|
37
|
+
readonly exitCode: number;
|
|
38
|
+
readonly stdout: string;
|
|
39
|
+
readonly stderr: string;
|
|
40
|
+
/** The command's own answer, recorded when it published one through `ui.json`. */
|
|
41
|
+
readonly json?: HostJson;
|
|
42
|
+
/**
|
|
43
|
+
* The failure that ended the command, with its value withheld: the bounded
|
|
44
|
+
* facts a host reports by. Absent when the command ended on its own terms.
|
|
45
|
+
*/
|
|
46
|
+
readonly failure?: ValueFreeFailure;
|
|
47
|
+
};
|
|
48
|
+
/** How a host asks for a command to stop before it finishes. */
|
|
49
|
+
export type CommandInvocation = {
|
|
50
|
+
readonly signal?: AbortSignal;
|
|
51
|
+
};
|
|
52
|
+
export type AgentHostInvokeOptions = {
|
|
53
|
+
/** The caller session tool calls are attributed to. */
|
|
54
|
+
readonly session?: string;
|
|
55
|
+
readonly signal?: AbortSignal;
|
|
56
|
+
};
|
|
57
|
+
/** The scope an agent host declares. It is the CLI host's own declaration for a persistent, interactive, local session. */
|
|
58
|
+
export type AgentHostScopeInput = {
|
|
59
|
+
/** The workspace the host session runs in. */
|
|
60
|
+
readonly workspaceRoot: string;
|
|
61
|
+
/** A released agent host declares `false`; a host running from source may omit it. */
|
|
62
|
+
readonly dev?: boolean;
|
|
63
|
+
};
|
|
64
|
+
/** The runtime scope an agent host declares, resolved by `agentHostScope`. */
|
|
65
|
+
export type AgentHostScope = {
|
|
66
|
+
readonly surface: 'agent';
|
|
67
|
+
readonly hardware: 'consumer';
|
|
68
|
+
readonly purpose: 'projection';
|
|
69
|
+
readonly lifecycle: 'persistent';
|
|
70
|
+
readonly hosting: {
|
|
71
|
+
readonly mode: 'local';
|
|
72
|
+
readonly owner: 'consumer';
|
|
73
|
+
readonly venue: 'user-device';
|
|
74
|
+
};
|
|
75
|
+
readonly capabilities: {
|
|
76
|
+
readonly interactiveSession: true;
|
|
77
|
+
};
|
|
78
|
+
readonly workspace: {
|
|
79
|
+
readonly root: string;
|
|
80
|
+
readonly access: 'write';
|
|
81
|
+
};
|
|
82
|
+
readonly qualifiers?: {
|
|
83
|
+
readonly dev: boolean;
|
|
84
|
+
};
|
|
85
|
+
};
|
|
86
|
+
/** Commands forward by default; a terminal host may declare capture-only delivery. */
|
|
87
|
+
export declare const AgentHostSettingsSchema: z.ZodObject<{
|
|
88
|
+
commandCaptureDelivery: z.ZodDefault<z.ZodEnum<{
|
|
89
|
+
capture: "capture";
|
|
90
|
+
forward: "forward";
|
|
91
|
+
}>>;
|
|
92
|
+
}, z.core.$strict>;
|
|
93
|
+
export type AgentHostSettings = z.output<typeof AgentHostSettingsSchema>;
|
|
94
|
+
/** The composition an agent host boots: the host's floor, the global scope, the bound workspace. */
|
|
95
|
+
export type AgentHostComposition = {
|
|
96
|
+
/** Plugins every agent host composes under the global and workspace scopes. */
|
|
97
|
+
readonly floor: readonly (() => Promise<RuntimePlugin>)[];
|
|
98
|
+
/** Host defaults passed to the kernel; workspace values may override them with their owner selected by workspace/global. */
|
|
99
|
+
readonly config?: RuntimeWorkspaceCompositionRequest['floor']['config'];
|
|
100
|
+
};
|
|
101
|
+
export type BootAgentHostOptions = {
|
|
102
|
+
/** The host's own environment plugin (Node, Bun, …). The host builds it; this module never imports one. */
|
|
103
|
+
readonly environment: RuntimePlugin;
|
|
104
|
+
readonly composition: AgentHostComposition;
|
|
105
|
+
/** The workspace the host session runs in. */
|
|
106
|
+
readonly workspaceRoot: string;
|
|
107
|
+
/**
|
|
108
|
+
* R: the root whose `node_modules` supplies the framework. One per process;
|
|
109
|
+
* every first-party name must resolve under it. The host resolves it by its own
|
|
110
|
+
* rules and hands it here.
|
|
111
|
+
*/
|
|
112
|
+
readonly root: string;
|
|
113
|
+
/** `owned` leaves the default binding alone; `default` binds it. */
|
|
114
|
+
readonly binding?: 'default' | 'owned';
|
|
115
|
+
};
|
|
116
|
+
/**
|
|
117
|
+
* One `cli/command` as a host presents it: the name the host shows, the
|
|
118
|
+
* description it lists, and a parser from the host's argument string into the
|
|
119
|
+
* positional arguments the descriptor declares.
|
|
120
|
+
*/
|
|
121
|
+
export type AgentHostCommand = {
|
|
122
|
+
/** Group path and name, e.g. `session init`; a group-less command is just its name. */
|
|
123
|
+
readonly name: string;
|
|
124
|
+
readonly description: string;
|
|
125
|
+
readonly descriptor: CLICommandAssetDescriptor;
|
|
126
|
+
/** Parse the host's argument string into this command's declared positionals. */
|
|
127
|
+
parse(input: string): CommandOptions;
|
|
128
|
+
};
|
|
129
|
+
/** The registries and results `VibesAgentHost` answers. */
|
|
130
|
+
export type AgentHostCatalog = {
|
|
131
|
+
readonly tools: readonly LiveToolDescriptor[];
|
|
132
|
+
readonly groups: readonly CLIGroupAssetDescriptor[];
|
|
133
|
+
readonly commands: readonly CLICommandAssetDescriptor[];
|
|
134
|
+
readonly prompts: readonly PromptsManifestDescriptor[];
|
|
135
|
+
readonly models: readonly AgentHostDescriptor[];
|
|
136
|
+
readonly providers: readonly AgentHostDescriptor[];
|
|
137
|
+
};
|
|
138
|
+
/** A command implementation's entry, as the CLI surface resolves it. */
|
|
139
|
+
export type CliCommandExecute = (args: CommandOptions, opts: CommandOptions, context: CommandContext) => Promise<void | HostJson>;
|
|
140
|
+
/** The command's exit status: a thrown failure is a nonzero status with its message as stderr. */
|
|
141
|
+
export type CommandExitStatus = number;
|
|
142
|
+
//# sourceMappingURL=agent-host.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agent-host.d.ts","sourceRoot":"","sources":["../../../src/harness/schemas/agent-host.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,CAAC,MAAM,QAAQ,CAAC;AAC5B,OAAO,KAAK,EAAE,yBAAyB,EAAE,uBAAuB,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAC;AACrI,OAAO,KAAK,EAAE,iBAAiB,EAAE,aAAa,EAAE,kCAAkC,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAElI,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,yBAAyB,CAAC;AACzE,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAE3D;;;;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AIG;AACH,MAAM,MAAM,gBAAgB,GAAG;IAC9B,uFAAuF;IACvF,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;IAC7B,QAAQ,CAAC,UAAU,EAAE,yBAAyB,CAAC;IAC/C,iFAAiF;IACjF,KAAK,CAAC,KAAK,EAAE,MAAM,GAAG,cAAc,CAAC;CACrC,CAAC;AAEF,2DAA2D;AAC3D,MAAM,MAAM,gBAAgB,GAAG;IAC9B,QAAQ,CAAC,KAAK,EAAE,SAAS,kBAAkB,EAAE,CAAC;IAC9C,QAAQ,CAAC,MAAM,EAAE,SAAS,uBAAuB,EAAE,CAAC;IACpD,QAAQ,CAAC,QAAQ,EAAE,SAAS,yBAAyB,EAAE,CAAC;IACxD,QAAQ,CAAC,OAAO,EAAE,SAAS,yBAAyB,EAAE,CAAC;IACvD,QAAQ,CAAC,MAAM,EAAE,SAAS,mBAAmB,EAAE,CAAC;IAChD,QAAQ,CAAC,SAAS,EAAE,SAAS,mBAAmB,EAAE,CAAC;CACnD,CAAC;AAEF,wEAAwE;AACxE,MAAM,MAAM,iBAAiB,GAAG,CAC/B,IAAI,EAAE,cAAc,EACpB,IAAI,EAAE,cAAc,EACpB,OAAO,EAAE,cAAc,KACnB,OAAO,CAAC,IAAI,GAAG,QAAQ,CAAC,CAAC;AAE9B,kGAAkG;AAClG,MAAM,MAAM,iBAAiB,GAAG,MAAM,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The agent host's contracts.
|
|
3
|
+
*
|
|
4
|
+
* R-SCHEMA-001 keeps an exported interface or type alias in a schemas directory,
|
|
5
|
+
* so every type a host reads from this module is declared here and
|
|
6
|
+
* `./agent-host.ts` carries only behaviour. Each shape is derived from the
|
|
7
|
+
* contract it describes rather than restated: a runtime descriptor is a
|
|
8
|
+
* `RuntimeDescriptor`, a command is a `cli/command` asset, a prompt is a
|
|
9
|
+
* `prompts/manifest` asset. Nothing here invents a parallel vocabulary.
|
|
10
|
+
*/
|
|
11
|
+
import * as z from 'zod/v4';
|
|
12
|
+
import { JsonValueSchema } from '@vibesdotdev/kernel/schemas/json';
|
|
13
|
+
/**
|
|
14
|
+
* A JSON value, which is all that crosses a host bridge.
|
|
15
|
+
*
|
|
16
|
+
* A coding-agent host is a separate process behind a JSON boundary, so both
|
|
17
|
+
* ends of every host call are this and nothing richer: a tool's arguments
|
|
18
|
+
* arrive as JSON and its answer leaves as JSON. A value that is not JSON fails at
|
|
19
|
+
* the boundary rather than reaching a host that cannot render or forward it.
|
|
20
|
+
*/
|
|
21
|
+
export const HostJsonSchema = JsonValueSchema;
|
|
22
|
+
/** Commands forward by default; a terminal host may declare capture-only delivery. */
|
|
23
|
+
export const AgentHostSettingsSchema = z.strictObject({
|
|
24
|
+
commandCaptureDelivery: z.enum(['forward', 'capture']).default('forward')
|
|
25
|
+
});
|
|
26
|
+
//# sourceMappingURL=agent-host.js.map
|