@skaile/workspaces 5.4.0 → 5.6.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/CHANGELOG.md +98 -0
- package/dist/app-sdk/index.js +1 -1
- package/dist/{asset-feeds-3MVRNS5U.js → asset-feeds-4O2JK5S4.js} +27 -14
- package/dist/asset-feeds-4O2JK5S4.js.map +1 -0
- package/dist/asset-manager/catalog-deployer.js +9 -9
- package/dist/asset-manager/index.js +18 -18
- package/dist/asset-manager/installer.js +11 -11
- package/dist/asset-manager/renderers.js +20 -2
- package/dist/asset-manager/src/index.d.ts +75 -24
- package/dist/asset-manager/src/index.d.ts.map +1 -1
- package/dist/asset-manager/src/install-agent.d.ts +22 -14
- package/dist/asset-manager/src/install-agent.d.ts.map +1 -1
- package/dist/asset-manager/src/install-instances.d.ts +55 -0
- package/dist/asset-manager/src/install-instances.d.ts.map +1 -0
- package/dist/asset-manager/src/installer.d.ts +30 -7
- package/dist/asset-manager/src/installer.d.ts.map +1 -1
- package/dist/asset-manager/src/renderers.d.ts +29 -8
- package/dist/asset-manager/src/renderers.d.ts.map +1 -1
- package/dist/bridge/drivers/claude-sdk.js +14 -14
- package/dist/bridge/drivers/codex.js +20 -14
- package/dist/bridge/drivers/codex.js.map +1 -1
- package/dist/bridge/drivers/continue.js +11 -11
- package/dist/bridge/drivers/echo.js +3 -3
- package/dist/bridge/drivers/gemini.js +6 -6
- package/dist/bridge/drivers/goose.js +11 -11
- package/dist/bridge/drivers/omp.js +4 -4
- package/dist/bridge/drivers/opencode.js +11 -11
- package/dist/bridge/drivers/qwen.js +6 -6
- package/dist/bridge/index.js +15 -15
- package/dist/bridge/src/codex/native-policy.d.ts +1 -1
- package/dist/bridge/src/drivers/codex.d.ts +2 -1
- package/dist/bridge/src/drivers/codex.d.ts.map +1 -1
- package/dist/{chunk-LUBS5DXY.js → chunk-27HS2DHB.js} +4 -4
- package/dist/{chunk-LUBS5DXY.js.map → chunk-27HS2DHB.js.map} +1 -1
- package/dist/{chunk-RD6GE4HU.js → chunk-2GRB5ITE.js} +4 -4
- package/dist/{chunk-RD6GE4HU.js.map → chunk-2GRB5ITE.js.map} +1 -1
- package/dist/{chunk-UKDFOOEG.js → chunk-2NYXQYHN.js} +4 -4
- package/dist/{chunk-UKDFOOEG.js.map → chunk-2NYXQYHN.js.map} +1 -1
- package/dist/{chunk-6IGFSUTE.js → chunk-2W4LBLIN.js} +388 -61
- package/dist/chunk-2W4LBLIN.js.map +1 -0
- package/dist/{chunk-OXE5A6H6.js → chunk-2XFUXGV6.js} +3 -3
- package/dist/{chunk-OXE5A6H6.js.map → chunk-2XFUXGV6.js.map} +1 -1
- package/dist/{chunk-ZDKJHQY2.js → chunk-3TXEJN4W.js} +2 -2
- package/dist/{chunk-ZDKJHQY2.js.map → chunk-3TXEJN4W.js.map} +1 -1
- package/dist/{chunk-QK756IRJ.js → chunk-436GRQC2.js} +15 -15
- package/dist/chunk-436GRQC2.js.map +1 -0
- package/dist/{chunk-JELTQ4H7.js → chunk-45VFGT7A.js} +3 -3
- package/dist/{chunk-JELTQ4H7.js.map → chunk-45VFGT7A.js.map} +1 -1
- package/dist/{chunk-XGIS325V.js → chunk-46OVMT76.js} +3 -3
- package/dist/{chunk-XGIS325V.js.map → chunk-46OVMT76.js.map} +1 -1
- package/dist/{chunk-37GBJLF5.js → chunk-47ZD34KB.js} +3 -3
- package/dist/{chunk-37GBJLF5.js.map → chunk-47ZD34KB.js.map} +1 -1
- package/dist/{chunk-BATL2CWI.js → chunk-4CTGEEN6.js} +297 -124
- package/dist/chunk-4CTGEEN6.js.map +1 -0
- package/dist/{chunk-DTV7HL5R.js → chunk-4GNJELPH.js} +2 -2
- package/dist/{chunk-DTV7HL5R.js.map → chunk-4GNJELPH.js.map} +1 -1
- package/dist/{chunk-AE42DHSH.js → chunk-5B5IZVEP.js} +2 -2
- package/dist/{chunk-AE42DHSH.js.map → chunk-5B5IZVEP.js.map} +1 -1
- package/dist/{chunk-BHUHGLNS.js → chunk-6NPINANG.js} +6 -6
- package/dist/{chunk-BHUHGLNS.js.map → chunk-6NPINANG.js.map} +1 -1
- package/dist/{chunk-SQBPE66C.js → chunk-7KLC4LZO.js} +8 -8
- package/dist/{chunk-SQBPE66C.js.map → chunk-7KLC4LZO.js.map} +1 -1
- package/dist/{chunk-SR4RFKHM.js → chunk-7ZHLYXTI.js} +3 -3
- package/dist/{chunk-SR4RFKHM.js.map → chunk-7ZHLYXTI.js.map} +1 -1
- package/dist/{chunk-WX74MVNA.js → chunk-AO7VJ6G6.js} +3 -24
- package/dist/chunk-AO7VJ6G6.js.map +1 -0
- package/dist/{chunk-UAAAERXI.js → chunk-AOAZCSDI.js} +4 -3
- package/dist/chunk-AOAZCSDI.js.map +1 -0
- package/dist/{chunk-JCATNLY3.js → chunk-BF33SCLY.js} +10 -5
- package/dist/chunk-BF33SCLY.js.map +1 -0
- package/dist/{chunk-VKSA2CDJ.js → chunk-BTISGSK4.js} +4 -4
- package/dist/{chunk-VKSA2CDJ.js.map → chunk-BTISGSK4.js.map} +1 -1
- package/dist/{chunk-TOSHZX4C.js → chunk-CPSIPIX7.js} +2 -2
- package/dist/chunk-CPSIPIX7.js.map +1 -0
- package/dist/{chunk-K2K7OF4P.js → chunk-DMLDYFDS.js} +23 -6
- package/dist/chunk-DMLDYFDS.js.map +1 -0
- package/dist/{chunk-A67BHJCH.js → chunk-DZM73WDN.js} +4 -4
- package/dist/{chunk-A67BHJCH.js.map → chunk-DZM73WDN.js.map} +1 -1
- package/dist/{chunk-QMWMSZQ4.js → chunk-FK6HPLQA.js} +3 -3
- package/dist/{chunk-QMWMSZQ4.js.map → chunk-FK6HPLQA.js.map} +1 -1
- package/dist/chunk-FRHE7FFB.js +655 -0
- package/dist/chunk-FRHE7FFB.js.map +1 -0
- package/dist/{chunk-37DN45RR.js → chunk-IPWR33AW.js} +181 -111
- package/dist/chunk-IPWR33AW.js.map +1 -0
- package/dist/{chunk-2XXAVTTO.js → chunk-KUFNKVBM.js} +3 -3
- package/dist/{chunk-2XXAVTTO.js.map → chunk-KUFNKVBM.js.map} +1 -1
- package/dist/{chunk-GCYD4EGY.js → chunk-KYXOGHY6.js} +4 -4
- package/dist/{chunk-GCYD4EGY.js.map → chunk-KYXOGHY6.js.map} +1 -1
- package/dist/{chunk-ZIYYMR6Y.js → chunk-LLKKLKZJ.js} +3 -3
- package/dist/{chunk-ZIYYMR6Y.js.map → chunk-LLKKLKZJ.js.map} +1 -1
- package/dist/{chunk-Y5OCUOXF.js → chunk-MX3UQXLU.js} +52 -35
- package/dist/chunk-MX3UQXLU.js.map +1 -0
- package/dist/{chunk-7KITVWXK.js → chunk-MX6LZE2C.js} +44 -13
- package/dist/chunk-MX6LZE2C.js.map +1 -0
- package/dist/{chunk-BNUZEYC3.js → chunk-NARITJS2.js} +3 -3
- package/dist/{chunk-BNUZEYC3.js.map → chunk-NARITJS2.js.map} +1 -1
- package/dist/{chunk-OANSNVCP.js → chunk-NLXIALVO.js} +5 -5
- package/dist/{chunk-OANSNVCP.js.map → chunk-NLXIALVO.js.map} +1 -1
- package/dist/{chunk-U6ORGQHZ.js → chunk-O5GDKC5I.js} +3 -3
- package/dist/{chunk-U6ORGQHZ.js.map → chunk-O5GDKC5I.js.map} +1 -1
- package/dist/{chunk-ZUZ5LLZ2.js → chunk-OGLDAJFL.js} +4 -4
- package/dist/{chunk-ZUZ5LLZ2.js.map → chunk-OGLDAJFL.js.map} +1 -1
- package/dist/chunk-OLLAQLFJ.js +17 -0
- package/dist/chunk-OLLAQLFJ.js.map +1 -0
- package/dist/{chunk-LFMX2UEF.js → chunk-PA7WLID3.js} +86 -69
- package/dist/chunk-PA7WLID3.js.map +1 -0
- package/dist/{chunk-UNRZCQD4.js → chunk-PJS2YWGG.js} +6 -6
- package/dist/{chunk-UNRZCQD4.js.map → chunk-PJS2YWGG.js.map} +1 -1
- package/dist/{chunk-VETH6MDG.js → chunk-RGXVQZOV.js} +6021 -3099
- package/dist/chunk-RGXVQZOV.js.map +1 -0
- package/dist/{chunk-JEA32KB6.js → chunk-S7QXEXKY.js} +19 -6
- package/dist/chunk-S7QXEXKY.js.map +1 -0
- package/dist/{chunk-JKWU6ULI.js → chunk-SDFROXSA.js} +3 -3
- package/dist/{chunk-JKWU6ULI.js.map → chunk-SDFROXSA.js.map} +1 -1
- package/dist/{chunk-XMQAV6T3.js → chunk-SX4UIDKT.js} +3 -3
- package/dist/{chunk-XMQAV6T3.js.map → chunk-SX4UIDKT.js.map} +1 -1
- package/dist/{chunk-QEXEHXX5.js → chunk-TZCQ7ZWQ.js} +83 -9
- package/dist/chunk-TZCQ7ZWQ.js.map +1 -0
- package/dist/{chunk-ONWTPXVU.js → chunk-UAP2XHRF.js} +10 -10
- package/dist/{chunk-ONWTPXVU.js.map → chunk-UAP2XHRF.js.map} +1 -1
- package/dist/{chunk-JF26V3BC.js → chunk-V7NN3HXR.js} +7 -12
- package/dist/chunk-V7NN3HXR.js.map +1 -0
- package/dist/{chunk-LAI7X6I2.js → chunk-VBBBZDI7.js} +3 -3
- package/dist/{chunk-LAI7X6I2.js.map → chunk-VBBBZDI7.js.map} +1 -1
- package/dist/{chunk-TNWXGHLD.js → chunk-VKSXST23.js} +51 -42
- package/dist/chunk-VKSXST23.js.map +1 -0
- package/dist/{chunk-HTKZ4AOW.js → chunk-VSQFGU5D.js} +3 -3
- package/dist/{chunk-HTKZ4AOW.js.map → chunk-VSQFGU5D.js.map} +1 -1
- package/dist/{chunk-IDUGP4V7.js → chunk-VX3INFBA.js} +4 -4
- package/dist/{chunk-IDUGP4V7.js.map → chunk-VX3INFBA.js.map} +1 -1
- package/dist/{chunk-Y7UBRRKG.js → chunk-XOGG7VDZ.js} +40 -31
- package/dist/chunk-XOGG7VDZ.js.map +1 -0
- package/dist/{chunk-JAJG4G5E.js → chunk-ZBBM6O6P.js} +3 -3
- package/dist/{chunk-JAJG4G5E.js.map → chunk-ZBBM6O6P.js.map} +1 -1
- package/dist/cli/index.js +5031 -3384
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/src/asset-feeds.d.ts.map +1 -1
- package/dist/cli/src/commands/catalog.d.ts +7 -7
- package/dist/cli/src/commands/catalog.d.ts.map +1 -1
- package/dist/cli/src/commands/connector.d.ts +2 -2
- package/dist/cli/src/commands/connector.d.ts.map +1 -1
- package/dist/cli/src/commands/diff.d.ts.map +1 -1
- package/dist/cli/src/commands/history.d.ts.map +1 -1
- package/dist/cli/src/commands/library-cmd.d.ts.map +1 -1
- package/dist/cli/src/commands/manage.d.ts.map +1 -1
- package/dist/cli/src/commands/migrate-agents.d.ts +131 -0
- package/dist/cli/src/commands/migrate-agents.d.ts.map +1 -0
- package/dist/cli/src/commands/migrate-assets.d.ts +54 -0
- package/dist/cli/src/commands/migrate-assets.d.ts.map +1 -0
- package/dist/cli/src/commands/migrate-files.d.ts +52 -0
- package/dist/cli/src/commands/migrate-files.d.ts.map +1 -0
- package/dist/cli/src/commands/migrate-providers.d.ts +5 -8
- package/dist/cli/src/commands/migrate-providers.d.ts.map +1 -1
- package/dist/cli/src/commands/migrate.d.ts +21 -0
- package/dist/cli/src/commands/migrate.d.ts.map +1 -0
- package/dist/cli/src/commands/npx.d.ts.map +1 -1
- package/dist/cli/src/commands/outdated.d.ts.map +1 -1
- package/dist/cli/src/commands/patch.d.ts.map +1 -1
- package/dist/cli/src/commands/preset-cmd.d.ts.map +1 -1
- package/dist/cli/src/commands/project.d.ts +13 -1
- package/dist/cli/src/commands/project.d.ts.map +1 -1
- package/dist/cli/src/commands/rebuild.d.ts.map +1 -1
- package/dist/cli/src/commands/run.d.ts.map +1 -1
- package/dist/cli/src/commands/show.d.ts.map +1 -1
- package/dist/cli/src/commands/tree.d.ts.map +1 -1
- package/dist/cli/src/commands/update.d.ts.map +1 -1
- package/dist/cli/src/commands/validate-instances.d.ts +17 -0
- package/dist/cli/src/commands/validate-instances.d.ts.map +1 -0
- package/dist/cli/src/commands/validate.d.ts +14 -0
- package/dist/cli/src/commands/validate.d.ts.map +1 -1
- package/dist/cli/src/commands/why.d.ts.map +1 -1
- package/dist/cli/src/helpers.d.ts +10 -0
- package/dist/cli/src/helpers.d.ts.map +1 -1
- package/dist/cli/src/open-library.d.ts.map +1 -1
- package/dist/cli/src/open-registry.d.ts +13 -16
- package/dist/cli/src/open-registry.d.ts.map +1 -1
- package/dist/cli/src/type-guards.d.ts +3 -0
- package/dist/cli/src/type-guards.d.ts.map +1 -0
- package/dist/connectors/config.js +6 -6
- package/dist/connectors/index.js +19 -19
- package/dist/{connectors-OB3OAZTK.js → connectors-HWENZFKW.js} +22 -22
- package/dist/{connectors-OB3OAZTK.js.map → connectors-HWENZFKW.js.map} +1 -1
- package/dist/connectors-shared/index.js +2 -2
- package/dist/core/driver-targets.js +1 -1
- package/dist/core/index.js +8 -8
- package/dist/core/manifest.js +2 -2
- package/dist/core/models.js +1 -1
- package/dist/core/publish-manifest.js +2 -2
- package/dist/core/ref.js +1 -1
- package/dist/core/runtime-assets.js +6 -6
- package/dist/core/src/agent-instances.d.ts +93 -0
- package/dist/core/src/agent-instances.d.ts.map +1 -0
- package/dist/core/src/agent-prompt-sections.d.ts +90 -0
- package/dist/core/src/agent-prompt-sections.d.ts.map +1 -0
- package/dist/core/src/driver-targets.d.ts +4 -2
- package/dist/core/src/driver-targets.d.ts.map +1 -1
- package/dist/core/src/index.d.ts +12 -8
- package/dist/core/src/index.d.ts.map +1 -1
- package/dist/core/src/manifest.d.ts +71 -27
- package/dist/core/src/manifest.d.ts.map +1 -1
- package/dist/core/src/models.d.ts +6 -92
- package/dist/core/src/models.d.ts.map +1 -1
- package/dist/core/src/repo-manager.d.ts +54 -3
- package/dist/core/src/repo-manager.d.ts.map +1 -1
- package/dist/core/src/type-guards.d.ts +3 -0
- package/dist/core/src/type-guards.d.ts.map +1 -0
- package/dist/core/src/walker.d.ts +7 -3
- package/dist/core/src/walker.d.ts.map +1 -1
- package/dist/core/src/workspace-config.d.ts +19 -15
- package/dist/core/src/workspace-config.d.ts.map +1 -1
- package/dist/core/store.js +2 -2
- package/dist/core/workspace-config.js +5 -5
- package/dist/deploy/index.js +8 -8
- package/dist/discovery/index.js +6 -6
- package/dist/discovery/src/builtin-providers.d.ts +5 -4
- package/dist/discovery/src/builtin-providers.d.ts.map +1 -1
- package/dist/discovery/src/default-registry.d.ts +23 -0
- package/dist/discovery/src/default-registry.d.ts.map +1 -0
- package/dist/discovery/src/discover.d.ts +0 -6
- package/dist/discovery/src/discover.d.ts.map +1 -1
- package/dist/discovery/src/index.d.ts +2 -1
- package/dist/discovery/src/index.d.ts.map +1 -1
- package/dist/discovery/src/tree-entries.d.ts +1 -1
- package/dist/discovery/src/tree-entries.d.ts.map +1 -1
- package/dist/{ensure-sources-Z3KKLEM6.js → ensure-sources-VCPKNPK2.js} +21 -21
- package/dist/{ensure-sources-Z3KKLEM6.js.map → ensure-sources-VCPKNPK2.js.map} +1 -1
- package/dist/factory-assets/README.md +3 -3
- package/dist/factory-assets/connectors/box.js +19 -19
- package/dist/factory-assets/connectors/deploy.js +19 -19
- package/dist/factory-assets/connectors/devserver.js +19 -19
- package/dist/factory-assets/connectors/flow/adapter.js +19 -19
- package/dist/factory-assets/connectors/flow/engine/flow-kind-provider.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/engine.js +9 -9
- package/dist/factory-assets/connectors/flow/run-flow.js +21 -21
- package/dist/factory-assets/connectors/flow.js +19 -19
- package/dist/factory-assets/connectors/git.js +19 -19
- package/dist/factory-assets/connectors/gmail.js +19 -19
- package/dist/factory-assets/connectors/googledrive.js +19 -19
- package/dist/factory-assets/connectors/local.js +19 -19
- package/dist/factory-assets/connectors/mattermost.js +19 -19
- package/dist/factory-assets/connectors/memory.js +19 -19
- package/dist/factory-assets/connectors/minio.js +19 -19
- package/dist/factory-assets/connectors/postgres.js +19 -19
- package/dist/factory-assets/connectors/s3.js +19 -19
- package/dist/factory-assets/connectors/sharepoint.js +19 -19
- package/dist/factory-assets/connectors/sqlite.js +19 -19
- package/dist/factory-assets/connectors/static-server.js +19 -19
- package/dist/factory-assets/connectors/tunnel.js +19 -19
- package/dist/factory-assets/connectors/webdav.js +19 -19
- package/dist/factory-assets/connectors/xstate-store.js +19 -19
- package/dist/factory-assets/connectors/xstate.js +19 -19
- package/dist/factory-assets/index.js.map +1 -1
- package/dist/factory-assets/presets/workspaces-authoring/workspaces-authoring.preset.yaml +9 -0
- package/dist/factory-assets/skaile.manifest.yaml +2 -2
- package/dist/factory-assets/skills/authoring-skaile-assets/SKILL.md +16 -12
- package/dist/factory-assets/skills/authoring-skaile-manifests/SKILL.md +8 -8
- package/dist/factory-assets/skills/authoring-skaile-manifests/references/dependency-standard.md +13 -11
- package/dist/factory-assets/skills/skaile-manage-workspace/SKILL.md +1 -1
- package/dist/{flows-DTADYIXH.js → flows-ENQY2DV7.js} +13 -13
- package/dist/{flows-DTADYIXH.js.map → flows-ENQY2DV7.js.map} +1 -1
- package/dist/helpers-IW36CEJX.js +34 -0
- package/dist/{helpers-F2RFRT5D.js.map → helpers-IW36CEJX.js.map} +1 -1
- package/dist/library/index.js +13 -13
- package/dist/library/install.js +3 -3
- package/dist/library/src/index.d.ts +2 -2
- package/dist/library/src/index.d.ts.map +1 -1
- package/dist/library/src/library.d.ts +2 -12
- package/dist/library/src/library.d.ts.map +1 -1
- package/dist/library/src/local/local-catalog-source.d.ts +2 -2
- package/dist/library/src/local/local-catalog-source.d.ts.map +1 -1
- package/dist/library/src/manifest-writer.d.ts +4 -1
- package/dist/library/src/manifest-writer.d.ts.map +1 -1
- package/dist/library/src/remote/remote-catalog-source.d.ts +11 -2
- package/dist/library/src/remote/remote-catalog-source.d.ts.map +1 -1
- package/dist/library/src/sync/manifest-writeback.d.ts.map +1 -1
- package/dist/{library-publish-62RFU74A.js → library-publish-R3DQLMTD.js} +27 -27
- package/dist/{library-publish-62RFU74A.js.map → library-publish-R3DQLMTD.js.map} +1 -1
- package/dist/open-library-FAJZRDKE.js +40 -0
- package/dist/{open-library-NVG3CZUO.js.map → open-library-FAJZRDKE.js.map} +1 -1
- package/dist/open-registry-NVPCQPND.js +32 -0
- package/dist/{open-registry-IYH6W6CN.js.map → open-registry-NVPCQPND.js.map} +1 -1
- package/dist/paths-YUCP7K6U.js +22 -0
- package/dist/{paths-STQO4FYF.js.map → paths-YUCP7K6U.js.map} +1 -1
- package/dist/{plugin-store-2DTEIJTG.js → plugin-store-66QFBNEO.js} +10 -10
- package/dist/{plugin-store-2DTEIJTG.js.map → plugin-store-66QFBNEO.js.map} +1 -1
- package/dist/plugins/index.js +1 -1
- package/dist/plugins/src/asset-kind-provider.d.ts +14 -2
- package/dist/plugins/src/asset-kind-provider.d.ts.map +1 -1
- package/dist/plugins/src/catalog-source.d.ts +7 -0
- package/dist/plugins/src/catalog-source.d.ts.map +1 -1
- package/dist/plugins/src/index.d.ts +1 -1
- package/dist/plugins/src/index.d.ts.map +1 -1
- package/dist/project-ALJIVFHI.js +41 -0
- package/dist/{project-44LM6SRV.js.map → project-ALJIVFHI.js.map} +1 -1
- package/dist/resolver/index.js +9 -9
- package/dist/runner/index.js +34 -29
- package/dist/runner/src/agent-capabilities.d.ts +101 -0
- package/dist/runner/src/agent-capabilities.d.ts.map +1 -0
- package/dist/runner/src/agent.d.ts.map +1 -1
- package/dist/runner/src/agents/in-process-host.d.ts +56 -0
- package/dist/runner/src/agents/in-process-host.d.ts.map +1 -0
- package/dist/runner/src/agents/instances.d.ts +62 -0
- package/dist/runner/src/agents/instances.d.ts.map +1 -0
- package/dist/runner/src/agents/json-schema.d.ts +16 -0
- package/dist/runner/src/agents/json-schema.d.ts.map +1 -0
- package/dist/runner/src/agents/memory-run-store.d.ts +19 -0
- package/dist/runner/src/agents/memory-run-store.d.ts.map +1 -0
- package/dist/runner/src/agents/run-controller.d.ts +208 -0
- package/dist/runner/src/agents/run-controller.d.ts.map +1 -0
- package/dist/runner/src/agents/standalone-surface.d.ts +30 -0
- package/dist/runner/src/agents/standalone-surface.d.ts.map +1 -0
- package/dist/runner/src/capability-registry.d.ts.map +1 -1
- package/dist/runner/src/composition/bootstrap.d.ts +13 -51
- package/dist/runner/src/composition/bootstrap.d.ts.map +1 -1
- package/dist/runner/src/composition/compile.d.ts +43 -27
- package/dist/runner/src/composition/compile.d.ts.map +1 -1
- package/dist/runner/src/composition/content-source.d.ts +94 -0
- package/dist/runner/src/composition/content-source.d.ts.map +1 -0
- package/dist/runner/src/composition/dry-run.d.ts +34 -0
- package/dist/runner/src/composition/dry-run.d.ts.map +1 -0
- package/dist/runner/src/composition/errors.d.ts +41 -0
- package/dist/runner/src/composition/errors.d.ts.map +1 -0
- package/dist/runner/src/composition/index.d.ts +10 -3
- package/dist/runner/src/composition/index.d.ts.map +1 -1
- package/dist/runner/src/composition/prompt-sections.d.ts +31 -0
- package/dist/runner/src/composition/prompt-sections.d.ts.map +1 -0
- package/dist/runner/src/composition/resolve-instance.d.ts +140 -0
- package/dist/runner/src/composition/resolve-instance.d.ts.map +1 -0
- package/dist/runner/src/composition/resolve.d.ts +43 -25
- package/dist/runner/src/composition/resolve.d.ts.map +1 -1
- package/dist/runner/src/composition/revision-hash.d.ts +58 -0
- package/dist/runner/src/composition/revision-hash.d.ts.map +1 -0
- package/dist/runner/src/composition/run-snapshot.d.ts +37 -0
- package/dist/runner/src/composition/run-snapshot.d.ts.map +1 -0
- package/dist/runner/src/composition/types.d.ts +79 -12
- package/dist/runner/src/composition/types.d.ts.map +1 -1
- package/dist/runner/src/index.d.ts +2 -0
- package/dist/runner/src/index.d.ts.map +1 -1
- package/dist/runner/src/manifest.d.ts +1 -1
- package/dist/runner/src/manifest.d.ts.map +1 -1
- package/dist/runner/src/mixin-resolver.d.ts +14 -15
- package/dist/runner/src/mixin-resolver.d.ts.map +1 -1
- package/dist/runner/src/serve.d.ts +6 -0
- package/dist/runner/src/serve.d.ts.map +1 -1
- package/dist/runner/src/session-builder.d.ts +35 -6
- package/dist/runner/src/session-builder.d.ts.map +1 -1
- package/dist/sdk/asset-manager.js +18 -18
- package/dist/sdk/bridge.js +15 -15
- package/dist/sdk/core.js +8 -8
- package/dist/sdk/flow.js +9 -9
- package/dist/sdk/index.js +34 -29
- package/dist/sdk/index.js.map +1 -1
- package/dist/sdk/resolver.js +9 -9
- package/dist/sdk/runner.js +34 -29
- package/dist/sdk/session.js +2 -2
- package/dist/sdk/types.js +1 -1
- package/dist/secrets/index.js +2 -2
- package/dist/session/index.js +2 -2
- package/dist/{setup-4BV5ZWOZ.js → setup-35JXIA3N.js} +28 -28
- package/dist/{setup-4BV5ZWOZ.js.map → setup-35JXIA3N.js.map} +1 -1
- package/dist/skills-CS7NE5TT.js +26 -0
- package/dist/{skills-M7OU3WMP.js.map → skills-CS7NE5TT.js.map} +1 -1
- package/dist/source-ISR4KRZV.js +41 -0
- package/dist/{source-HTT6CXUP.js.map → source-ISR4KRZV.js.map} +1 -1
- package/dist/{source-manifest-publish-CPXUX3CL.js → source-manifest-publish-P22IPK5F.js} +27 -27
- package/dist/{source-manifest-publish-CPXUX3CL.js.map → source-manifest-publish-P22IPK5F.js.map} +1 -1
- package/dist/tui/index.js +34 -29
- package/dist/tui/index.js.map +1 -1
- package/dist/types/index.js +1 -1
- package/dist/types/manifests.js +1 -1
- package/dist/types/src/agent-lifecycle.d.ts +402 -0
- package/dist/types/src/agent-lifecycle.d.ts.map +1 -0
- package/dist/types/src/capabilities.d.ts +0 -4
- package/dist/types/src/capabilities.d.ts.map +1 -1
- package/dist/types/src/delivery.d.ts.map +1 -1
- package/dist/types/src/events.d.ts +66 -4
- package/dist/types/src/events.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +3 -1
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/lifecycle.d.ts +21 -3
- package/dist/types/src/lifecycle.d.ts.map +1 -1
- package/dist/types/src/manifests/_shared.d.ts +1 -16
- package/dist/types/src/manifests/_shared.d.ts.map +1 -1
- package/dist/types/src/manifests/agent-composition.d.ts +44 -0
- package/dist/types/src/manifests/agent-composition.d.ts.map +1 -0
- package/dist/types/src/manifests/agent.d.ts +184 -6
- package/dist/types/src/manifests/agent.d.ts.map +1 -1
- package/dist/types/src/manifests/index.d.ts +6 -15
- package/dist/types/src/manifests/index.d.ts.map +1 -1
- package/dist/types/src/manifests/preset.d.ts +5 -5
- package/dist/types/src/version.d.ts +16 -1
- package/dist/types/src/version.d.ts.map +1 -1
- package/dist/workspace-plugin/adapters/mcp.js +26 -26
- package/dist/workspace-plugin/adapters/omp.js +14 -14
- package/dist/workspace-plugin/index.js +1 -1
- package/package.json +1 -1
- package/dist/asset-feeds-3MVRNS5U.js.map +0 -1
- package/dist/chunk-37DN45RR.js.map +0 -1
- package/dist/chunk-5CYEWBPB.js +0 -440
- package/dist/chunk-5CYEWBPB.js.map +0 -1
- package/dist/chunk-5NH3U6N5.js +0 -15
- package/dist/chunk-5NH3U6N5.js.map +0 -1
- package/dist/chunk-6IGFSUTE.js.map +0 -1
- package/dist/chunk-7KITVWXK.js.map +0 -1
- package/dist/chunk-BATL2CWI.js.map +0 -1
- package/dist/chunk-JCATNLY3.js.map +0 -1
- package/dist/chunk-JEA32KB6.js.map +0 -1
- package/dist/chunk-JF26V3BC.js.map +0 -1
- package/dist/chunk-K2K7OF4P.js.map +0 -1
- package/dist/chunk-LFMX2UEF.js.map +0 -1
- package/dist/chunk-QEXEHXX5.js.map +0 -1
- package/dist/chunk-QK756IRJ.js.map +0 -1
- package/dist/chunk-TNWXGHLD.js.map +0 -1
- package/dist/chunk-TOSHZX4C.js.map +0 -1
- package/dist/chunk-UAAAERXI.js.map +0 -1
- package/dist/chunk-VETH6MDG.js.map +0 -1
- package/dist/chunk-WX74MVNA.js.map +0 -1
- package/dist/chunk-Y5OCUOXF.js.map +0 -1
- package/dist/chunk-Y7UBRRKG.js.map +0 -1
- package/dist/factory-assets/bundles/workspaces-authoring/workspaces-authoring.bundle.yaml +0 -9
- package/dist/helpers-F2RFRT5D.js +0 -34
- package/dist/open-library-NVG3CZUO.js +0 -40
- package/dist/open-registry-IYH6W6CN.js +0 -32
- package/dist/paths-STQO4FYF.js +0 -22
- package/dist/project-44LM6SRV.js +0 -36
- package/dist/skills-M7OU3WMP.js +0 -26
- package/dist/source-HTT6CXUP.js +0 -41
- package/dist/types/src/manifests/mount.d.ts +0 -21
- package/dist/types/src/manifests/mount.d.ts.map +0 -1
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* composition/errors.ts
|
|
3
|
+
*
|
|
4
|
+
* Typed failures of the composition pipeline. Composition never omits an item
|
|
5
|
+
* silently: a ref that cannot be served exactly as pinned ends the session
|
|
6
|
+
* start (or the rebuild) with one of these.
|
|
7
|
+
*/
|
|
8
|
+
/** Diagnostic code carried by a {@link CompositionError}. */
|
|
9
|
+
export type CompositionErrorCode = "composition_asset_missing" | "composition_conflict" | "composition_rebuild_required";
|
|
10
|
+
/** Why a {@link CompositionError} was raised (stable, for tests and tooling). */
|
|
11
|
+
export type CompositionErrorReason =
|
|
12
|
+
/** No content found for the ref (nothing on disk, no lock pin bytes, no catalog hit). */
|
|
13
|
+
"missing"
|
|
14
|
+
/** Several distinct catalog/lock candidates match the ref. */
|
|
15
|
+
| "ambiguous"
|
|
16
|
+
/** Bytes on disk differ from the hash the lock or compile manifest recorded. */
|
|
17
|
+
| "hash_mismatch"
|
|
18
|
+
/** Sub-agent composition loops back onto an agent already being composed. */
|
|
19
|
+
| "cycle"
|
|
20
|
+
/** `compile_manifest.json` has the old schema or is malformed. */
|
|
21
|
+
| "stale_manifest"
|
|
22
|
+
/** An `inline-snapshot` item has no compiled bytes. */
|
|
23
|
+
| "not_compiled";
|
|
24
|
+
/**
|
|
25
|
+
* Thrown by the content source, the compile writer and the resolver. `code`
|
|
26
|
+
* mirrors the `skaile validate` diagnostic of the same name.
|
|
27
|
+
*
|
|
28
|
+
* @docLink packages/runner/capabilities#composition-error
|
|
29
|
+
*/
|
|
30
|
+
export declare class CompositionError extends Error {
|
|
31
|
+
readonly code: CompositionErrorCode;
|
|
32
|
+
readonly reason: CompositionErrorReason;
|
|
33
|
+
/** The composes ref the failure belongs to, when there is one. */
|
|
34
|
+
readonly ref?: string | undefined;
|
|
35
|
+
constructor(code: CompositionErrorCode, reason: CompositionErrorReason, message: string,
|
|
36
|
+
/** The composes ref the failure belongs to, when there is one. */
|
|
37
|
+
ref?: string | undefined);
|
|
38
|
+
}
|
|
39
|
+
/** True for a {@link CompositionError} with the given code (any code when omitted). */
|
|
40
|
+
export declare function isCompositionError(err: unknown, code?: CompositionErrorCode): err is CompositionError;
|
|
41
|
+
//# sourceMappingURL=errors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/errors.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,6DAA6D;AAC7D,MAAM,MAAM,oBAAoB,GAC5B,2BAA2B,GAC3B,sBAAsB,GACtB,8BAA8B,CAAC;AAEnC,iFAAiF;AACjF,MAAM,MAAM,sBAAsB;AAChC,yFAAyF;AACvF,SAAS;AACX,8DAA8D;GAC5D,WAAW;AACb,gFAAgF;GAC9E,eAAe;AACjB,6EAA6E;GAC3E,OAAO;AACT,kEAAkE;GAChE,gBAAgB;AAClB,uDAAuD;GACrD,cAAc,CAAC;AAEnB;;;;;GAKG;AACH,qBAAa,gBAAiB,SAAQ,KAAK;IAEvC,QAAQ,CAAC,IAAI,EAAE,oBAAoB;IACnC,QAAQ,CAAC,MAAM,EAAE,sBAAsB;IAEvC,kEAAkE;IAClE,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM;gBAJZ,IAAI,EAAE,oBAAoB,EAC1B,MAAM,EAAE,sBAAsB,EACvC,OAAO,EAAE,MAAM;IACf,kEAAkE;IACzD,GAAG,CAAC,EAAE,MAAM,YAAA;CAKxB;AAED,uFAAuF;AACvF,wBAAgB,kBAAkB,CAChC,GAAG,EAAE,OAAO,EACZ,IAAI,CAAC,EAAE,oBAAoB,GAC1B,GAAG,IAAI,gBAAgB,CAEzB"}
|
|
@@ -7,8 +7,15 @@
|
|
|
7
7
|
*
|
|
8
8
|
* And supports `skaile rebuild <agent>` via the compile module.
|
|
9
9
|
*/
|
|
10
|
-
export {
|
|
11
|
-
export { COMPILE_MANIFEST_FILENAME, type CompileOpts, type CompileResult, compileComposition, loadCompileManifest, loadCompileManifestFromDir, } from "./compile.js";
|
|
10
|
+
export { registerCompositionCapabilities } from "./bootstrap.js";
|
|
11
|
+
export { COMPILE_MANIFEST_FILENAME, CompileManifestEntrySchema, type CompileOpts, type CompileResult, compileComposition, loadCompileManifest, loadCompileManifestFromDir, } from "./compile.js";
|
|
12
|
+
export { type CompositionDryRunRow, describeComposition } from "./dry-run.js";
|
|
13
|
+
export { type CompositionAsset, type CompositionContentSource, type CompositionContentSourceOpts, createCompositionContentSource, hashContent, } from "./content-source.js";
|
|
14
|
+
export { CompositionError, type CompositionErrorCode, type CompositionErrorReason, isCompositionError, } from "./errors.js";
|
|
15
|
+
export { type AgentInstanceAsset, type AgentInstanceHost, instanceForSession, type ResolveAgentInstanceOpts, type ResolvedAgentInstance, type ResolvedMemoryBlock, type ResolvedSubagent, type ResolvedTrigger, resolveAgentInstance, } from "./resolve-instance.js";
|
|
12
16
|
export { type ResolveCompositionOpts, resolveComposition } from "./resolve.js";
|
|
13
|
-
export {
|
|
17
|
+
export { canonicalJson, computeRevisionHash, hashAgentFiles, type RevisionCompileEntry, type RevisionFileEntry, type RevisionHashInput, } from "./revision-hash.js";
|
|
18
|
+
export { buildRunnerAgentSections, type PromptExtensionPart } from "./prompt-sections.js";
|
|
19
|
+
export { buildCompositionRunSnapshot, compositionRunSnapshotPath, loadCompositionRunSnapshot, saveCompositionRunSnapshot, } from "./run-snapshot.js";
|
|
20
|
+
export { type AgentComposeItem, type Binding, type CompileManifest, type CompileManifestEntry, type CompositionRunSnapshot, type DiscoverableEntry, type InlineBlock, type ResolvedComposition, type ResolvedCompositionItem, resolveBinding, UnknownCompositionKindError, } from "./types.js";
|
|
14
21
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAGH,OAAO,EAAE,+BAA+B,EAAE,MAAM,gBAAgB,CAAC;AAEjE,OAAO,EACL,yBAAyB,EACzB,0BAA0B,EAC1B,KAAK,WAAW,EAChB,KAAK,aAAa,EAClB,kBAAkB,EAClB,mBAAmB,EACnB,0BAA0B,GAC3B,MAAM,cAAc,CAAC;AAEtB,OAAO,EAAE,KAAK,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAE9E,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,wBAAwB,EAC7B,KAAK,4BAA4B,EACjC,8BAA8B,EAC9B,WAAW,GACZ,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EACL,gBAAgB,EAChB,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,kBAAkB,GACnB,MAAM,aAAa,CAAC;AAErB,OAAO,EACL,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,kBAAkB,EAClB,KAAK,wBAAwB,EAC7B,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACpB,oBAAoB,GACrB,MAAM,uBAAuB,CAAC;AAE/B,OAAO,EAAE,KAAK,sBAAsB,EAAE,kBAAkB,EAAE,MAAM,cAAc,CAAC;AAE/E,OAAO,EACL,aAAa,EACb,mBAAmB,EACnB,cAAc,EACd,KAAK,oBAAoB,EACzB,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,GACvB,MAAM,oBAAoB,CAAC;AAE5B,OAAO,EAAE,wBAAwB,EAAE,KAAK,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAE1F,OAAO,EACL,2BAA2B,EAC3B,0BAA0B,EAC1B,0BAA0B,EAC1B,0BAA0B,GAC3B,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,OAAO,EACZ,KAAK,eAAe,EACpB,KAAK,oBAAoB,EACzB,KAAK,sBAAsB,EAC3B,KAAK,iBAAiB,EACtB,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,cAAc,EACd,2BAA2B,GAC5B,MAAM,YAAY,CAAC"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* composition/prompt-sections.ts
|
|
3
|
+
*
|
|
4
|
+
* The agent part of the runner's live system prompt, built by the same
|
|
5
|
+
* `buildAgentPromptSections` the install renderers use (`asset-manager`), so
|
|
6
|
+
* the two can never disagree on section order:
|
|
7
|
+
* soul → `<MEMORY>` → fragments → constraints → duties → abilities → contracts
|
|
8
|
+
* → composed → extensions.
|
|
9
|
+
*
|
|
10
|
+
* The runner contributes only the sections a harness does not already carry:
|
|
11
|
+
* the agent's convention files (soul, constraints, duties) are rendered into
|
|
12
|
+
* the native agent file at install, so they are not repeated here; memory
|
|
13
|
+
* blocks, composed inline blocks and prompt-extensions are.
|
|
14
|
+
*/
|
|
15
|
+
import { type AgentPromptSection } from "@skaile/workspaces/core";
|
|
16
|
+
import type { ResolvedAgentInstance } from "./resolve-instance.js";
|
|
17
|
+
/** A loaded `agent.prompt-extensions` entry. */
|
|
18
|
+
export interface PromptExtensionPart {
|
|
19
|
+
value: string;
|
|
20
|
+
/** Path the extension was loaded from. */
|
|
21
|
+
source: string;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Build the agent sections of the live system prompt.
|
|
25
|
+
*
|
|
26
|
+
* @param resolved - The resolved instance, or `null` when the session has no agent definition.
|
|
27
|
+
* @param promptExtensions - Loaded `agent.prompt-extensions`, in declared order.
|
|
28
|
+
* @returns Non-empty sections in the shared order; join `text` with the runner's section separator.
|
|
29
|
+
*/
|
|
30
|
+
export declare function buildRunnerAgentSections(resolved: ResolvedAgentInstance | null, promptExtensions: readonly PromptExtensionPart[]): AgentPromptSection[];
|
|
31
|
+
//# sourceMappingURL=prompt-sections.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"prompt-sections.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/prompt-sections.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;GAaG;AAEH,OAAO,EAAE,KAAK,kBAAkB,EAA4B,MAAM,yBAAyB,CAAC;AAC5F,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,uBAAuB,CAAC;AAEnE,gDAAgD;AAChD,MAAM,WAAW,mBAAmB;IAClC,KAAK,EAAE,MAAM,CAAC;IACd,0CAA0C;IAC1C,MAAM,EAAE,MAAM,CAAC;CAChB;AAED;;;;;;GAMG;AACH,wBAAgB,wBAAwB,CACtC,QAAQ,EAAE,qBAAqB,GAAG,IAAI,EACtC,gBAAgB,EAAE,SAAS,mBAAmB,EAAE,GAC/C,kBAAkB,EAAE,CAQtB"}
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* composition/resolve-instance.ts
|
|
3
|
+
*
|
|
4
|
+
* Resolves one agent *instance* — an agent asset bound into a workspace under
|
|
5
|
+
* an id (see `skaile.yaml` `agents:`) — into everything a host needs to run it:
|
|
6
|
+
* inline blocks, discoverable entries, sub-agents split into delegate vs run,
|
|
7
|
+
* memory blocks, effective triggers, io, connector slot bindings, warnings and
|
|
8
|
+
* a stable {@link ResolvedAgentInstance.revisionHash}.
|
|
9
|
+
*
|
|
10
|
+
* The composition is the asset's convention files (SOUL.md, RULES.md,
|
|
11
|
+
* DUTIES.md, knowledge/) as implicit items followed by its declared
|
|
12
|
+
* `composes:`. Bytes come from the content source and the compile manifest as
|
|
13
|
+
* in {@link resolveComposition}; a standalone `persona` / `ruleset` item
|
|
14
|
+
* composes exactly like the convention file of the same role (persona →
|
|
15
|
+
* inline-snapshot like SOUL.md, ruleset → inline-live like RULES.md).
|
|
16
|
+
*
|
|
17
|
+
* Failures are {@link CompositionError}s that end session start: a required
|
|
18
|
+
* capability nobody provides is `composition_asset_missing`.
|
|
19
|
+
*/
|
|
20
|
+
import { type AgentInstanceConfig, type SkWorkspaceConfig } from "@skaile/workspaces/core";
|
|
21
|
+
import type { IAssetKindRegistry } from "@skaile/workspaces/plugins";
|
|
22
|
+
import type { Logger } from "@skaile/workspaces/types";
|
|
23
|
+
import { type AgentIo, type AgentLifecycle, type AgentManifest, type AgentTrigger, type MemoryScope } from "@skaile/workspaces/types/manifests";
|
|
24
|
+
import { type CompositionContentSource } from "./content-source.js";
|
|
25
|
+
import { type ResolvedComposition } from "./types.js";
|
|
26
|
+
/** The agent asset an instance binds: its parsed manifest and its directory. */
|
|
27
|
+
export interface AgentInstanceAsset {
|
|
28
|
+
manifest: AgentManifest;
|
|
29
|
+
/** Directory holding `agent.yaml` and the convention files. */
|
|
30
|
+
dir: string;
|
|
31
|
+
}
|
|
32
|
+
/** What the host running the instance can do. Every field is optional. */
|
|
33
|
+
export interface AgentInstanceHost {
|
|
34
|
+
/**
|
|
35
|
+
* Whether the driver spawns native sub-agents (rendered agent files). Drives
|
|
36
|
+
* the default of a `kind: agent` item without an explicit binding:
|
|
37
|
+
* `delegate` when true, `run` otherwise. An explicit `delegate` on a driver
|
|
38
|
+
* without native sub-agents is demoted to `run` with a warning.
|
|
39
|
+
*/
|
|
40
|
+
nativeSubagents?: boolean;
|
|
41
|
+
/** Names of the capabilities the host provides (what `capabilities[]` requirements are checked against). */
|
|
42
|
+
capabilities?: readonly string[];
|
|
43
|
+
/** Current memory block content by block name (host-owned state); falls back to the block's seed. */
|
|
44
|
+
memory?: Readonly<Record<string, string>>;
|
|
45
|
+
}
|
|
46
|
+
/** Options of {@link resolveAgentInstance}. */
|
|
47
|
+
export interface ResolveAgentInstanceOpts {
|
|
48
|
+
/** Id of the instance in `skaile.yaml` `agents:` (`default` for the primary `agent:`). Never part of the revision hash. */
|
|
49
|
+
instanceId: string;
|
|
50
|
+
instance: AgentInstanceConfig;
|
|
51
|
+
asset: AgentInstanceAsset;
|
|
52
|
+
/** Project root — holds `skaile.lock.yaml`, `.skaile/cache/store` and run snapshots. */
|
|
53
|
+
projectDir: string;
|
|
54
|
+
/** Content source; defaults to the project's (local files, lock pins, local catalog). */
|
|
55
|
+
source?: CompositionContentSource;
|
|
56
|
+
host?: AgentInstanceHost;
|
|
57
|
+
/** Id of the run this resolution starts; its bytes are kept in a run snapshot (unless one exists). */
|
|
58
|
+
sessionId?: string;
|
|
59
|
+
/** Id of an earlier run this one continues; its run snapshot outranks the live sources. */
|
|
60
|
+
resumeSessionId?: string;
|
|
61
|
+
/**
|
|
62
|
+
* Resolve without writing a run snapshot (`skaile run --dry-run`). A dry run
|
|
63
|
+
* has no host, so a missing required capability is a warning, not an error.
|
|
64
|
+
*/
|
|
65
|
+
dryRun?: boolean;
|
|
66
|
+
log?: Logger;
|
|
67
|
+
/** Kind registry for recognising a kind's manifest file; defaults to the built-in providers. */
|
|
68
|
+
registry?: IAssetKindRegistry;
|
|
69
|
+
}
|
|
70
|
+
/** A `kind: agent` composition item, loaded and bound. */
|
|
71
|
+
export interface ResolvedSubagent {
|
|
72
|
+
/** `composes[].ref` as written. */
|
|
73
|
+
ref: string;
|
|
74
|
+
/** Alias the sub-agent is exposed under: `as`, else the asset's `name`, else the ref's basename. */
|
|
75
|
+
as: string;
|
|
76
|
+
/** Effective binding. */
|
|
77
|
+
binding: "delegate" | "run";
|
|
78
|
+
description?: string;
|
|
79
|
+
resolvedRef: string;
|
|
80
|
+
version: string | null;
|
|
81
|
+
/** SHA256 of the sub-agent's `agent.yaml` bytes. */
|
|
82
|
+
hash: string;
|
|
83
|
+
}
|
|
84
|
+
/** One memory block of the instance. */
|
|
85
|
+
export interface ResolvedMemoryBlock {
|
|
86
|
+
name: string;
|
|
87
|
+
/** Declared scope, or the instance's `memory.scope` when it overrides. */
|
|
88
|
+
scope: MemoryScope;
|
|
89
|
+
maxChars: number;
|
|
90
|
+
/** Convention file the block is seeded from. */
|
|
91
|
+
source?: string;
|
|
92
|
+
/** The seed bytes (from `source`), when it has one. */
|
|
93
|
+
seed?: string;
|
|
94
|
+
/** What `<MEMORY>` renders: host content, else the seed, else empty. */
|
|
95
|
+
content: string;
|
|
96
|
+
/** False when the instance has `memory.scope: none` — only the seed is shown, nothing is stored. */
|
|
97
|
+
persisted: boolean;
|
|
98
|
+
}
|
|
99
|
+
/** An effective trigger: the asset's, with the instance's overrides applied, or one the instance added. */
|
|
100
|
+
export type ResolvedTrigger = AgentTrigger & {
|
|
101
|
+
origin: "asset" | "instance";
|
|
102
|
+
};
|
|
103
|
+
/** The result of {@link resolveAgentInstance}. */
|
|
104
|
+
export interface ResolvedAgentInstance extends ResolvedComposition {
|
|
105
|
+
instanceId: string;
|
|
106
|
+
/** Normalized manifest: the asset's with lifecycle/model overrides, effective `composes`, merged triggers and effective memory blocks. */
|
|
107
|
+
manifest: AgentManifest;
|
|
108
|
+
lifecycle: AgentLifecycle;
|
|
109
|
+
subagents: {
|
|
110
|
+
delegate: ResolvedSubagent[];
|
|
111
|
+
run: ResolvedSubagent[];
|
|
112
|
+
};
|
|
113
|
+
memoryBlocks: ResolvedMemoryBlock[];
|
|
114
|
+
triggers: ResolvedTrigger[];
|
|
115
|
+
io?: AgentIo;
|
|
116
|
+
/** Compose slot id → `skaile.yaml` `connectors[].id`. Not part of the revision hash. */
|
|
117
|
+
slots: Record<string, string>;
|
|
118
|
+
/** SHA-256 of {normalized manifest, files, compile entries}; see `revision-hash.ts`. */
|
|
119
|
+
revisionHash: string;
|
|
120
|
+
}
|
|
121
|
+
/**
|
|
122
|
+
* The instance a session runs: the entry of `skaile.yaml` `agents:` (or the
|
|
123
|
+
* primary `agent:` for `default`), else a bare instance of the session's own
|
|
124
|
+
* agent directory.
|
|
125
|
+
*/
|
|
126
|
+
export declare function instanceForSession(config: Pick<SkWorkspaceConfig, "agent">, instanceId: string | undefined, agentDir: string): {
|
|
127
|
+
instanceId: string;
|
|
128
|
+
instance: AgentInstanceConfig;
|
|
129
|
+
};
|
|
130
|
+
/**
|
|
131
|
+
* Resolve an agent instance. Convention files compose first (implicit items),
|
|
132
|
+
* then the asset's `composes:`.
|
|
133
|
+
*
|
|
134
|
+
* @throws {CompositionError} `composition_rebuild_required` (declared `inline-snapshot` item never
|
|
135
|
+
* compiled), `composition_asset_missing` (item bytes or a required capability missing),
|
|
136
|
+
* `composition_conflict` (ambiguous or cyclic).
|
|
137
|
+
* @docLink packages/runner/capabilities#resolve-agent-instance
|
|
138
|
+
*/
|
|
139
|
+
export declare function resolveAgentInstance(opts: ResolveAgentInstanceOpts): Promise<ResolvedAgentInstance>;
|
|
140
|
+
//# sourceMappingURL=resolve-instance.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resolve-instance.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/resolve-instance.ts"],"names":[],"mappings":"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"}
|
|
@@ -1,20 +1,27 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* composition/resolve.ts
|
|
3
3
|
*
|
|
4
|
-
* Resolves an agent's `composes:` items
|
|
5
|
-
*
|
|
6
|
-
* entries for tool-list items.
|
|
4
|
+
* Resolves an agent's `composes:` items into a ResolvedComposition — prompt
|
|
5
|
+
* blocks for inline items and discoverable entries for tool-list items.
|
|
7
6
|
*
|
|
8
|
-
*
|
|
9
|
-
* - `inline-snapshot`:
|
|
10
|
-
*
|
|
11
|
-
*
|
|
7
|
+
* Where each binding's bytes come from:
|
|
8
|
+
* - `inline-snapshot`: the compile manifest only. An item that was never
|
|
9
|
+
* compiled is a `composition_rebuild_required` error — there is no live
|
|
10
|
+
* fallback.
|
|
11
|
+
* - `inline-live`: the content source (lock pin, else catalog/local file),
|
|
12
|
+
* read once when a run starts. The caller keeps the bytes in the run's
|
|
13
|
+
* snapshot; a resumed run passes that snapshot back and gets them again.
|
|
14
|
+
* - `discoverable`: registered by name + description; the content the tool
|
|
15
|
+
* hands out is the compiled capture (or, for an item added after the last
|
|
16
|
+
* rebuild, what the content source serves at run start).
|
|
12
17
|
*
|
|
13
|
-
*
|
|
18
|
+
* A run snapshot, when given, outranks every other origin so a resumed run is
|
|
19
|
+
* byte-identical to the run it continues.
|
|
14
20
|
*/
|
|
15
21
|
import type { IAssetIndex } from "@skaile/workspaces/library";
|
|
16
22
|
import type { AgentComposeItem } from "@skaile/workspaces/types/manifests";
|
|
17
|
-
import
|
|
23
|
+
import type { CompositionContentSource } from "./content-source.js";
|
|
24
|
+
import { type CompileManifest, type CompositionRunSnapshot, type ResolvedComposition, type ResolvedCompositionItem } from "./types.js";
|
|
18
25
|
/**
|
|
19
26
|
* Options for {@link resolveComposition}.
|
|
20
27
|
*
|
|
@@ -23,31 +30,42 @@ import { type CompileManifest, type ResolvedComposition } from "./types.js";
|
|
|
23
30
|
export interface ResolveCompositionOpts {
|
|
24
31
|
/** The agent's composes: items */
|
|
25
32
|
items: AgentComposeItem[];
|
|
26
|
-
/** Library for asset
|
|
33
|
+
/** Library for asset descriptions (optional enrichment) */
|
|
27
34
|
library: IAssetIndex;
|
|
28
|
-
/**
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
*/
|
|
35
|
+
/** Where live bytes come from */
|
|
36
|
+
source: CompositionContentSource;
|
|
37
|
+
/** Pre-loaded compile manifest (absent when the agent was never compiled). */
|
|
32
38
|
compileManifest?: CompileManifest;
|
|
39
|
+
/** The bytes a run already captured; set when resuming it. */
|
|
40
|
+
runSnapshot?: CompositionRunSnapshot;
|
|
33
41
|
/**
|
|
34
|
-
*
|
|
35
|
-
*
|
|
36
|
-
*
|
|
42
|
+
* Marks the implicit convention items (SOUL.md, RULES.md, DUTIES.md,
|
|
43
|
+
* knowledge/). They are the agent's own files, which harnesses also carry
|
|
44
|
+
* natively, so they are held to a softer rule than declared items: an
|
|
45
|
+
* `inline-snapshot` item that was never compiled is read from the source
|
|
46
|
+
* (with a warning) instead of ending session start, and one the source
|
|
47
|
+
* cannot serve is skipped with a warning. Declared items stay strict.
|
|
37
48
|
*/
|
|
38
|
-
|
|
49
|
+
implicit?: (item: AgentComposeItem) => boolean;
|
|
39
50
|
}
|
|
40
51
|
/**
|
|
41
52
|
* Resolve all composition items for an agent.
|
|
42
53
|
*
|
|
43
|
-
*
|
|
44
|
-
*
|
|
45
|
-
*
|
|
46
|
-
*
|
|
47
|
-
*
|
|
48
|
-
* @param opts - Resolution options with items, library, optional compile manifest and content loader.
|
|
49
|
-
* @returns A {@link ResolvedComposition} with inline blocks, discoverable entries, and warnings.
|
|
54
|
+
* @param opts - Resolution options with items, library, content source, compile manifest and run snapshot.
|
|
55
|
+
* @returns A {@link ResolvedComposition} with inline blocks, discoverable entries, the resolved items and warnings.
|
|
56
|
+
* @throws {CompositionError} `composition_rebuild_required` for an uncompiled `inline-snapshot` item;
|
|
57
|
+
* `composition_asset_missing` / `composition_conflict` for an item the content source cannot serve.
|
|
50
58
|
* @docLink packages/runner/capabilities#resolve-composition
|
|
51
59
|
*/
|
|
52
60
|
export declare function resolveComposition(opts: ResolveCompositionOpts): Promise<ResolvedComposition>;
|
|
61
|
+
/**
|
|
62
|
+
* Load the asset a `kind: agent` item names (its `agent.yaml` text). Sub-agents
|
|
63
|
+
* are pinned like discoverable items: a run snapshot, then the compiled
|
|
64
|
+
* capture, then the content source. The compiled entry is found whichever
|
|
65
|
+
* delegate/run binding it was compiled under — the effective binding depends
|
|
66
|
+
* on the driver, the pinned bytes do not.
|
|
67
|
+
*
|
|
68
|
+
* @throws {CompositionError} `composition_asset_missing` / `composition_conflict` from the content source.
|
|
69
|
+
*/
|
|
70
|
+
export declare function resolveSubagentItem(item: AgentComposeItem, binding: "delegate" | "run", source: CompositionContentSource, compileManifest: CompileManifest | undefined, runSnapshot: CompositionRunSnapshot | undefined): Promise<ResolvedCompositionItem>;
|
|
53
71
|
//# sourceMappingURL=resolve.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"resolve.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/resolve.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"resolve.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/resolve.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;GAmBG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAC9D,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,oCAAoC,CAAC;AAC3E,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,qBAAqB,CAAC;AAGpE,OAAO,EACL,KAAK,eAAe,EAEpB,KAAK,sBAAsB,EAC3B,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAE7B,MAAM,YAAY,CAAC;AAMpB;;;;GAIG;AACH,MAAM,WAAW,sBAAsB;IACrC,kCAAkC;IAClC,KAAK,EAAE,gBAAgB,EAAE,CAAC;IAC1B,2DAA2D;IAC3D,OAAO,EAAE,WAAW,CAAC;IACrB,iCAAiC;IACjC,MAAM,EAAE,wBAAwB,CAAC;IACjC,8EAA8E;IAC9E,eAAe,CAAC,EAAE,eAAe,CAAC;IAClC,8DAA8D;IAC9D,WAAW,CAAC,EAAE,sBAAsB,CAAC;IACrC;;;;;;;OAOG;IACH,QAAQ,CAAC,EAAE,CAAC,IAAI,EAAE,gBAAgB,KAAK,OAAO,CAAC;CAChD;AAMD;;;;;;;;GAQG;AACH,wBAAsB,kBAAkB,CACtC,IAAI,EAAE,sBAAsB,GAC3B,OAAO,CAAC,mBAAmB,CAAC,CAsE9B;AAuFD;;;;;;;;GAQG;AACH,wBAAsB,mBAAmB,CACvC,IAAI,EAAE,gBAAgB,EACtB,OAAO,EAAE,UAAU,GAAG,KAAK,EAC3B,MAAM,EAAE,wBAAwB,EAChC,eAAe,EAAE,eAAe,GAAG,SAAS,EAC5C,WAAW,EAAE,sBAAsB,GAAG,SAAS,GAC9C,OAAO,CAAC,uBAAuB,CAAC,CAMlC"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* composition/revision-hash.ts
|
|
3
|
+
*
|
|
4
|
+
* The one place a resolved agent instance is reduced to a content hash.
|
|
5
|
+
* `skaile run --dry-run` and every host that records instance revisions call
|
|
6
|
+
* {@link computeRevisionHash}, so the same inputs always give the same hash.
|
|
7
|
+
*
|
|
8
|
+
* The hash covers what defines the agent's behaviour: the normalized manifest,
|
|
9
|
+
* the agent directory's files (path + sha256) and the composition entries
|
|
10
|
+
* (ref, binding, hash of the bytes composed). It excludes everything that
|
|
11
|
+
* varies between runs of the same definition: timestamps, host/workspace ids,
|
|
12
|
+
* the instance id and connector slot bindings.
|
|
13
|
+
*/
|
|
14
|
+
/** One file of the agent directory. */
|
|
15
|
+
export interface RevisionFileEntry {
|
|
16
|
+
/** Path relative to the agent directory, `/`-separated. */
|
|
17
|
+
path: string;
|
|
18
|
+
sha256: string;
|
|
19
|
+
}
|
|
20
|
+
/** One composition item as it enters the hash. */
|
|
21
|
+
export interface RevisionCompileEntry {
|
|
22
|
+
kind: string;
|
|
23
|
+
ref: string;
|
|
24
|
+
/** Slot id, when the item has one (part of the definition, unlike its connector binding). */
|
|
25
|
+
id?: string;
|
|
26
|
+
/** Effective binding. */
|
|
27
|
+
binding: string;
|
|
28
|
+
/** SHA256 of the composed bytes. */
|
|
29
|
+
hash: string;
|
|
30
|
+
}
|
|
31
|
+
/** Input of {@link computeRevisionHash}. */
|
|
32
|
+
export interface RevisionHashInput {
|
|
33
|
+
/** The normalized (effective) manifest: asset manifest with instance overrides applied. */
|
|
34
|
+
manifest: unknown;
|
|
35
|
+
/** Files of the agent directory; order does not matter. */
|
|
36
|
+
files: readonly RevisionFileEntry[];
|
|
37
|
+
/** Composition entries in effective order (order shapes the prompt, so it is kept). */
|
|
38
|
+
entries: readonly RevisionCompileEntry[];
|
|
39
|
+
}
|
|
40
|
+
/**
|
|
41
|
+
* Deterministic JSON: object keys sorted, `undefined` dropped, no whitespace.
|
|
42
|
+
* Two values that differ only in key order or `undefined` members serialise equally.
|
|
43
|
+
*/
|
|
44
|
+
export declare function canonicalJson(value: unknown): string;
|
|
45
|
+
/**
|
|
46
|
+
* SHA-256 (hex) over the canonical JSON of `{ manifest, files, entries }`,
|
|
47
|
+
* with `files` sorted by path.
|
|
48
|
+
*
|
|
49
|
+
* @docLink packages/runner/capabilities#compute-revision-hash
|
|
50
|
+
*/
|
|
51
|
+
export declare function computeRevisionHash(input: RevisionHashInput): string;
|
|
52
|
+
/**
|
|
53
|
+
* List and hash the files of an agent directory (recursive, sorted by path).
|
|
54
|
+
* Dot-entries, `node_modules` and the compile manifest are not part of the
|
|
55
|
+
* definition and are skipped. A missing directory yields no entries.
|
|
56
|
+
*/
|
|
57
|
+
export declare function hashAgentFiles(agentDir: string): Promise<RevisionFileEntry[]>;
|
|
58
|
+
//# sourceMappingURL=revision-hash.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"revision-hash.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/revision-hash.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AAQH,uCAAuC;AACvC,MAAM,WAAW,iBAAiB;IAChC,2DAA2D;IAC3D,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,kDAAkD;AAClD,MAAM,WAAW,oBAAoB;IACnC,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,6FAA6F;IAC7F,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,yBAAyB;IACzB,OAAO,EAAE,MAAM,CAAC;IAChB,oCAAoC;IACpC,IAAI,EAAE,MAAM,CAAC;CACd;AAED,4CAA4C;AAC5C,MAAM,WAAW,iBAAiB;IAChC,2FAA2F;IAC3F,QAAQ,EAAE,OAAO,CAAC;IAClB,2DAA2D;IAC3D,KAAK,EAAE,SAAS,iBAAiB,EAAE,CAAC;IACpC,uFAAuF;IACvF,OAAO,EAAE,SAAS,oBAAoB,EAAE,CAAC;CAC1C;AAED;;;GAGG;AACH,wBAAgB,aAAa,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAEpD;AAeD;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,iBAAiB,GAAG,MAAM,CAcpE;AAID;;;;GAIG;AACH,wBAAsB,cAAc,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAAC,iBAAiB,EAAE,CAAC,CAuBnF"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* composition/run-snapshot.ts
|
|
3
|
+
*
|
|
4
|
+
* Per-run capture of composition bytes. `inline-live` is read once when a run
|
|
5
|
+
* starts; the bytes are written beside the session's persisted state so a
|
|
6
|
+
* resumed run is byte-identical to the run it continues. File:
|
|
7
|
+
* `<project>/.skaile/composition-runs/<sessionId>.json`.
|
|
8
|
+
*/
|
|
9
|
+
import type { CompositionRunSnapshot, ResolvedCompositionItem } from "./types.js";
|
|
10
|
+
/**
|
|
11
|
+
* Absolute path of the snapshot file for a session.
|
|
12
|
+
*
|
|
13
|
+
* @docLink packages/runner/capabilities#composition-run-snapshot
|
|
14
|
+
*/
|
|
15
|
+
export declare function compositionRunSnapshotPath(projectDir: string, sessionId: string): string;
|
|
16
|
+
/**
|
|
17
|
+
* Load a session's run snapshot.
|
|
18
|
+
*
|
|
19
|
+
* @returns The snapshot, or `undefined` when the session captured none.
|
|
20
|
+
* @throws {CompositionError} `composition_conflict` when the file is malformed or an item's
|
|
21
|
+
* bytes no longer match its hash.
|
|
22
|
+
* @docLink packages/runner/capabilities#composition-run-snapshot
|
|
23
|
+
*/
|
|
24
|
+
export declare function loadCompositionRunSnapshot(projectDir: string, sessionId: string): Promise<CompositionRunSnapshot | undefined>;
|
|
25
|
+
/**
|
|
26
|
+
* Build a run snapshot from what a resolution just served.
|
|
27
|
+
*
|
|
28
|
+
* @docLink packages/runner/capabilities#composition-run-snapshot
|
|
29
|
+
*/
|
|
30
|
+
export declare function buildCompositionRunSnapshot(sessionId: string, items: readonly ResolvedCompositionItem[], promptVersion: number | null): CompositionRunSnapshot;
|
|
31
|
+
/**
|
|
32
|
+
* Persist a run snapshot (atomic write).
|
|
33
|
+
*
|
|
34
|
+
* @docLink packages/runner/capabilities#composition-run-snapshot
|
|
35
|
+
*/
|
|
36
|
+
export declare function saveCompositionRunSnapshot(projectDir: string, snapshot: CompositionRunSnapshot): Promise<void>;
|
|
37
|
+
//# sourceMappingURL=run-snapshot.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"run-snapshot.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/run-snapshot.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAQH,OAAO,KAAK,EAEV,sBAAsB,EACtB,uBAAuB,EACxB,MAAM,YAAY,CAAC;AAgBpB;;;;GAIG;AACH,wBAAgB,0BAA0B,CAAC,UAAU,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,MAAM,CAExF;AAED;;;;;;;GAOG;AACH,wBAAsB,0BAA0B,CAC9C,UAAU,EAAE,MAAM,EAClB,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,sBAAsB,GAAG,SAAS,CAAC,CAqC7C;AAED;;;;GAIG;AACH,wBAAgB,2BAA2B,CACzC,SAAS,EAAE,MAAM,EACjB,KAAK,EAAE,SAAS,uBAAuB,EAAE,EACzC,aAAa,EAAE,MAAM,GAAG,IAAI,GAC3B,sBAAsB,CAmBxB;AAED;;;;GAIG;AACH,wBAAsB,0BAA0B,CAC9C,UAAU,EAAE,MAAM,EAClB,QAAQ,EAAE,sBAAsB,GAC/B,OAAO,CAAC,IAAI,CAAC,CAMf"}
|
|
@@ -8,6 +8,17 @@
|
|
|
8
8
|
*/
|
|
9
9
|
import type { AgentComposeItem, Binding } from "@skaile/workspaces/types/manifests";
|
|
10
10
|
export type { AgentComposeItem, Binding };
|
|
11
|
+
/**
|
|
12
|
+
* Thrown by {@link resolveBinding} when a composition item has no explicit
|
|
13
|
+
* `binding` and its `kind` has no default. `skaile validate` reports the same
|
|
14
|
+
* condition earlier as `unknown_asset_kind`.
|
|
15
|
+
*/
|
|
16
|
+
export declare class UnknownCompositionKindError extends Error {
|
|
17
|
+
readonly kind: string;
|
|
18
|
+
readonly ref: string;
|
|
19
|
+
readonly code = "unknown_asset_kind";
|
|
20
|
+
constructor(kind: string, ref: string);
|
|
21
|
+
}
|
|
11
22
|
/**
|
|
12
23
|
* Resolve the effective binding for a composition item.
|
|
13
24
|
* Uses explicit `binding` if set, otherwise falls back to kind default.
|
|
@@ -15,39 +26,46 @@ export type { AgentComposeItem, Binding };
|
|
|
15
26
|
* @param item - A single entry from an agent manifest's `composes:` list.
|
|
16
27
|
* @returns The effective {@link Binding} — explicit value when set, otherwise
|
|
17
28
|
* the kind-specific default (e.g. `soul` → `inline-snapshot`, `skill` → `discoverable`).
|
|
29
|
+
* @throws {UnknownCompositionKindError} when no `binding` is set and the kind has no default.
|
|
18
30
|
* @docLink packages/runner/capabilities#resolve-binding
|
|
19
31
|
*/
|
|
20
32
|
export declare function resolveBinding(item: AgentComposeItem): Binding;
|
|
21
33
|
/**
|
|
22
34
|
* Single entry in the agent's `compile_manifest.json`. Records the resolved
|
|
23
|
-
* version, content hash,
|
|
24
|
-
* the time of the last `skaile rebuild` run.
|
|
35
|
+
* ref, version, content hash, effective binding and the captured bytes of one
|
|
36
|
+
* composition item at the time of the last `skaile rebuild` run.
|
|
25
37
|
*
|
|
26
38
|
* @docLink packages/runner/capabilities#compile-manifest-entry
|
|
27
39
|
*/
|
|
28
40
|
export interface CompileManifestEntry {
|
|
29
|
-
/**
|
|
41
|
+
/** The `composes[].ref` exactly as written in agent.yaml. */
|
|
30
42
|
asset_ref: string;
|
|
31
|
-
/**
|
|
43
|
+
/** The item's asset kind. */
|
|
44
|
+
kind: string;
|
|
45
|
+
/** Where the bytes actually came from (`kind:@publisher/name#version` or `local:<path>`). */
|
|
46
|
+
resolved_ref: string;
|
|
47
|
+
/** Resolved version; `null` for a local file. */
|
|
32
48
|
version: string | null;
|
|
33
|
-
/** SHA256 of
|
|
49
|
+
/** SHA256 of `content` (recomputed on every read). */
|
|
34
50
|
hash: string;
|
|
35
|
-
/** Effective binding */
|
|
51
|
+
/** Effective binding. */
|
|
36
52
|
binding: Binding;
|
|
37
|
-
/** ISO timestamp when this entry was resolved */
|
|
53
|
+
/** ISO timestamp when this entry was resolved. */
|
|
38
54
|
resolved_at: string;
|
|
55
|
+
/** The captured bytes: what `inline-snapshot` serves and `discoverable` hands out on invocation. */
|
|
56
|
+
content: string;
|
|
39
57
|
}
|
|
40
58
|
/**
|
|
41
59
|
* Root structure of `compile_manifest.json` written by `skaile rebuild`.
|
|
42
60
|
* Tracks the prompt version counter and all resolved composition entries.
|
|
43
|
-
* The runner
|
|
44
|
-
*
|
|
61
|
+
* The runner serves `inline-snapshot` and `discoverable` content from these
|
|
62
|
+
* entries and never from the live sources.
|
|
45
63
|
*
|
|
46
64
|
* @docLink packages/runner/capabilities#compile-manifest
|
|
47
65
|
*/
|
|
48
66
|
export interface CompileManifest {
|
|
49
|
-
/** Compile manifest schema version */
|
|
50
|
-
schema_version:
|
|
67
|
+
/** Compile manifest schema version (1 was the hash-only format; it must be rebuilt). */
|
|
68
|
+
schema_version: 2;
|
|
51
69
|
/** Prompt version — bumped on every rebuild */
|
|
52
70
|
prompt_version: number;
|
|
53
71
|
/** Entries for each composition item */
|
|
@@ -55,6 +73,24 @@ export interface CompileManifest {
|
|
|
55
73
|
/** ISO timestamp of the last rebuild */
|
|
56
74
|
compiled_at: string;
|
|
57
75
|
}
|
|
76
|
+
/**
|
|
77
|
+
* The bytes one run of an agent uses for every non-snapshot composition item,
|
|
78
|
+
* captured when the run starts and reused when the run resumes. Stored beside
|
|
79
|
+
* the session's persisted state (`<project>/.skaile/composition-runs/<id>.json`).
|
|
80
|
+
*
|
|
81
|
+
* @docLink packages/runner/capabilities#composition-run-snapshot
|
|
82
|
+
*/
|
|
83
|
+
export interface CompositionRunSnapshot {
|
|
84
|
+
schema_version: 1;
|
|
85
|
+
/** Session id (or run id) the snapshot belongs to. */
|
|
86
|
+
session_id: string;
|
|
87
|
+
/** ISO timestamp of capture. */
|
|
88
|
+
captured_at: string;
|
|
89
|
+
/** Compile `prompt_version` the run started under (`null` when never compiled). */
|
|
90
|
+
prompt_version: number | null;
|
|
91
|
+
/** One entry per resolved item (content items and sub-agent items). */
|
|
92
|
+
items: CompileManifestEntry[];
|
|
93
|
+
}
|
|
58
94
|
/**
|
|
59
95
|
* A resolved inline content block for system prompt injection.
|
|
60
96
|
*
|
|
@@ -69,6 +105,12 @@ export interface InlineBlock {
|
|
|
69
105
|
content: string;
|
|
70
106
|
/** Binding mode that produced this block */
|
|
71
107
|
binding: "inline-live" | "inline-snapshot";
|
|
108
|
+
/**
|
|
109
|
+
* True for the agent's own convention files (SOUL.md, RULES.md, DUTIES.md).
|
|
110
|
+
* Harnesses carry those natively (rendered at install), so the runner does
|
|
111
|
+
* not repeat them in the live system prompt.
|
|
112
|
+
*/
|
|
113
|
+
implicit?: boolean;
|
|
72
114
|
}
|
|
73
115
|
/**
|
|
74
116
|
* A resolved discoverable item (becomes a tool-list entry).
|
|
@@ -87,6 +129,29 @@ export interface DiscoverableEntry {
|
|
|
87
129
|
/** Full content (loaded on demand when the tool is invoked) */
|
|
88
130
|
content: string;
|
|
89
131
|
}
|
|
132
|
+
/**
|
|
133
|
+
* One composition item as resolved for a run — what `skaile run --dry-run`
|
|
134
|
+
* prints and what the run snapshot is built from.
|
|
135
|
+
*
|
|
136
|
+
* @docLink packages/runner/capabilities#resolved-composition-item
|
|
137
|
+
*/
|
|
138
|
+
export interface ResolvedCompositionItem {
|
|
139
|
+
/** `composes[].ref` as written. */
|
|
140
|
+
ref: string;
|
|
141
|
+
kind: string;
|
|
142
|
+
binding: Binding;
|
|
143
|
+
/** Where the bytes came from (`kind:@publisher/name#version` or `local:<path>`). */
|
|
144
|
+
resolvedRef: string;
|
|
145
|
+
version: string | null;
|
|
146
|
+
/** SHA256 of `content`. */
|
|
147
|
+
hash: string;
|
|
148
|
+
content: string;
|
|
149
|
+
/**
|
|
150
|
+
* `compiled` — served from the compile manifest; `run-snapshot` — reused from
|
|
151
|
+
* the run's own capture (resume); `source` — read from the content source now.
|
|
152
|
+
*/
|
|
153
|
+
origin: "compiled" | "run-snapshot" | "source";
|
|
154
|
+
}
|
|
90
155
|
/**
|
|
91
156
|
* The full result of resolving an agent's composes: field.
|
|
92
157
|
*
|
|
@@ -97,7 +162,9 @@ export interface ResolvedComposition {
|
|
|
97
162
|
inlineBlocks: InlineBlock[];
|
|
98
163
|
/** Items to register as discoverable capabilities */
|
|
99
164
|
discoverableEntries: DiscoverableEntry[];
|
|
100
|
-
/**
|
|
165
|
+
/** Every resolved content item, in `composes:` order (sub-agent items carry no content and are absent). */
|
|
166
|
+
items: ResolvedCompositionItem[];
|
|
167
|
+
/** Non-fatal notes */
|
|
101
168
|
warnings: string[];
|
|
102
169
|
}
|
|
103
170
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/types.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;AAMpF,YAAY,EAAE,gBAAgB,EAAE,OAAO,EAAE,CAAC;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../runner/src/composition/types.ts"],"names":[],"mappings":"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"}
|