@skaile/workspaces 5.7.0 → 5.9.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 +120 -0
- package/dist/app-sdk/index.js +1 -1
- package/dist/{asset-feeds-K36CR52Q.js → asset-feeds-XMKKUUK6.js} +54 -30
- package/dist/asset-feeds-XMKKUUK6.js.map +1 -0
- package/dist/asset-manager/catalog-deployer.js +9 -9
- package/dist/asset-manager/index.js +15 -15
- package/dist/asset-manager/installer.js +11 -11
- package/dist/asset-manager/renderers.js +10 -10
- package/dist/asset-manager/src/index.d.ts +268 -24
- package/dist/asset-manager/src/index.d.ts.map +1 -1
- package/dist/asset-manager/src/install-agent.d.ts +11 -0
- package/dist/asset-manager/src/install-agent.d.ts.map +1 -1
- package/dist/asset-manager/src/installer.d.ts +2 -2
- package/dist/asset-manager/src/installer.d.ts.map +1 -1
- package/dist/bridge/drivers/claude-sdk.js +301 -212
- package/dist/bridge/drivers/claude-sdk.js.map +1 -1
- package/dist/bridge/drivers/codex.js +92 -66
- package/dist/bridge/drivers/codex.js.map +1 -1
- package/dist/bridge/drivers/continue.js +14 -15
- package/dist/bridge/drivers/continue.js.map +1 -1
- package/dist/bridge/drivers/echo.js +4 -4
- package/dist/bridge/drivers/gemini.js +8 -8
- package/dist/bridge/drivers/goose.js +14 -15
- package/dist/bridge/drivers/goose.js.map +1 -1
- package/dist/bridge/drivers/omp.js +70 -104
- package/dist/bridge/drivers/omp.js.map +1 -1
- package/dist/bridge/drivers/opencode.js +14 -15
- package/dist/bridge/drivers/opencode.js.map +1 -1
- package/dist/bridge/drivers/qwen.js +8 -8
- package/dist/bridge/index.js +16 -17
- package/dist/bridge/src/codex/managed-driver.d.ts +13 -10
- package/dist/bridge/src/codex/managed-driver.d.ts.map +1 -1
- package/dist/bridge/src/drivers/_subprocess-cli.d.ts +12 -2
- package/dist/bridge/src/drivers/_subprocess-cli.d.ts.map +1 -1
- package/dist/bridge/src/drivers/claude-sdk.d.ts +67 -62
- package/dist/bridge/src/drivers/claude-sdk.d.ts.map +1 -1
- package/dist/bridge/src/drivers/claude-tool-allowlist.d.ts +43 -0
- package/dist/bridge/src/drivers/claude-tool-allowlist.d.ts.map +1 -0
- package/dist/bridge/src/drivers/codex.d.ts +26 -10
- package/dist/bridge/src/drivers/codex.d.ts.map +1 -1
- package/dist/bridge/src/drivers/continue.d.ts +2 -2
- package/dist/bridge/src/drivers/continue.d.ts.map +1 -1
- package/dist/bridge/src/drivers/gemini.d.ts +2 -2
- package/dist/bridge/src/drivers/gemini.d.ts.map +1 -1
- package/dist/bridge/src/drivers/goose.d.ts +2 -2
- package/dist/bridge/src/drivers/goose.d.ts.map +1 -1
- package/dist/bridge/src/drivers/omp.d.ts +24 -35
- package/dist/bridge/src/drivers/omp.d.ts.map +1 -1
- package/dist/bridge/src/drivers/opencode.d.ts +2 -2
- package/dist/bridge/src/drivers/opencode.d.ts.map +1 -1
- package/dist/bridge/src/drivers/recovery-policy.d.ts +79 -0
- package/dist/bridge/src/drivers/recovery-policy.d.ts.map +1 -0
- package/dist/bridge/src/index.d.ts +1 -0
- package/dist/bridge/src/index.d.ts.map +1 -1
- package/dist/bridge/src/reconfigure-ledger.d.ts +117 -0
- package/dist/bridge/src/reconfigure-ledger.d.ts.map +1 -0
- package/dist/bridge/src/types.d.ts +77 -7
- package/dist/bridge/src/types.d.ts.map +1 -1
- package/dist/{chunk-WIEC3ZE4.js → chunk-2FRUUDZY.js} +5 -5
- package/dist/{chunk-WIEC3ZE4.js.map → chunk-2FRUUDZY.js.map} +1 -1
- package/dist/{chunk-NARITJS2.js → chunk-2H73V6XR.js} +3 -3
- package/dist/{chunk-NARITJS2.js.map → chunk-2H73V6XR.js.map} +1 -1
- package/dist/{chunk-O4Z7MAW7.js → chunk-2LWYNQK7.js} +3 -3
- package/dist/{chunk-O4Z7MAW7.js.map → chunk-2LWYNQK7.js.map} +1 -1
- package/dist/{chunk-OOLT6HGP.js → chunk-36AFURKZ.js} +7 -7
- package/dist/{chunk-OOLT6HGP.js.map → chunk-36AFURKZ.js.map} +1 -1
- package/dist/{chunk-DFFD4BFG.js → chunk-4MQS7CAF.js} +174 -86
- package/dist/chunk-4MQS7CAF.js.map +1 -0
- package/dist/{chunk-RNPHRRLG.js → chunk-4PTSR4UU.js} +3 -3
- package/dist/{chunk-RNPHRRLG.js.map → chunk-4PTSR4UU.js.map} +1 -1
- package/dist/{chunk-BTK7ECLH.js → chunk-5NNNV76P.js} +41 -8
- package/dist/chunk-5NNNV76P.js.map +1 -0
- package/dist/{chunk-IZLQ4GDO.js → chunk-7AI3Q5AQ.js} +43 -21
- package/dist/chunk-7AI3Q5AQ.js.map +1 -0
- package/dist/{chunk-NFGRW3L7.js → chunk-7RGTAEG6.js} +3 -3
- package/dist/{chunk-NFGRW3L7.js.map → chunk-7RGTAEG6.js.map} +1 -1
- package/dist/{chunk-XBSQ4KMC.js → chunk-B4X2N7JQ.js} +205 -3
- package/dist/chunk-B4X2N7JQ.js.map +1 -0
- package/dist/{chunk-FRHE7FFB.js → chunk-B6GIW55K.js} +5 -3
- package/dist/chunk-B6GIW55K.js.map +1 -0
- package/dist/{chunk-RVIZQ5XD.js → chunk-BTE2V4IW.js} +3 -3
- package/dist/{chunk-RVIZQ5XD.js.map → chunk-BTE2V4IW.js.map} +1 -1
- package/dist/{chunk-EB4XN3KE.js → chunk-CGT45WN7.js} +3 -3
- package/dist/{chunk-EB4XN3KE.js.map → chunk-CGT45WN7.js.map} +1 -1
- package/dist/{chunk-FAP63KV7.js → chunk-CKQEIY43.js} +4 -4
- package/dist/{chunk-FAP63KV7.js.map → chunk-CKQEIY43.js.map} +1 -1
- package/dist/{chunk-NWQB7UTY.js → chunk-DNZYOKOJ.js} +3 -3
- package/dist/{chunk-NWQB7UTY.js.map → chunk-DNZYOKOJ.js.map} +1 -1
- package/dist/{chunk-AVCUPPG6.js → chunk-EF7NPDDU.js} +4 -4
- package/dist/{chunk-AVCUPPG6.js.map → chunk-EF7NPDDU.js.map} +1 -1
- package/dist/chunk-EPBKISS5.js +84 -0
- package/dist/chunk-EPBKISS5.js.map +1 -0
- package/dist/{chunk-DMLDYFDS.js → chunk-F4NJDSR7.js} +9 -5
- package/dist/chunk-F4NJDSR7.js.map +1 -0
- package/dist/{chunk-PSA6ONFB.js → chunk-FVJK4QWM.js} +4 -4
- package/dist/{chunk-PSA6ONFB.js.map → chunk-FVJK4QWM.js.map} +1 -1
- package/dist/{chunk-KNWCFEWU.js → chunk-FYXZRVID.js} +20 -7
- package/dist/{chunk-KNWCFEWU.js.map → chunk-FYXZRVID.js.map} +1 -1
- package/dist/{chunk-LBQ4BBX4.js → chunk-FZNG4V4J.js} +16 -30
- package/dist/chunk-FZNG4V4J.js.map +1 -0
- package/dist/{chunk-SWO25LTO.js → chunk-GB7WDMH2.js} +4 -4
- package/dist/{chunk-SWO25LTO.js.map → chunk-GB7WDMH2.js.map} +1 -1
- package/dist/{chunk-EU3Q5AQ4.js → chunk-GKMZ6THE.js} +23 -32
- package/dist/chunk-GKMZ6THE.js.map +1 -0
- package/dist/{chunk-TTPSDC2G.js → chunk-GTILM2CI.js} +34 -13
- package/dist/chunk-GTILM2CI.js.map +1 -0
- package/dist/{chunk-LXY4BUA3.js → chunk-GXLQLPE5.js} +9 -5
- package/dist/chunk-GXLQLPE5.js.map +1 -0
- package/dist/{chunk-D5HOETOB.js → chunk-IMKSM5NL.js} +981 -126
- package/dist/chunk-IMKSM5NL.js.map +1 -0
- package/dist/{chunk-6UFFKMVC.js → chunk-IR33D6EP.js} +6 -6
- package/dist/{chunk-6UFFKMVC.js.map → chunk-IR33D6EP.js.map} +1 -1
- package/dist/{chunk-CT6NQSA4.js → chunk-ISHJITXJ.js} +3 -3
- package/dist/{chunk-CT6NQSA4.js.map → chunk-ISHJITXJ.js.map} +1 -1
- package/dist/chunk-IZCR27MU.js +60 -0
- package/dist/chunk-IZCR27MU.js.map +1 -0
- package/dist/{chunk-GWXFSLBK.js → chunk-J7U3PIOE.js} +4 -4
- package/dist/{chunk-GWXFSLBK.js.map → chunk-J7U3PIOE.js.map} +1 -1
- package/dist/{chunk-LCU5U5IW.js → chunk-JAKOMFC6.js} +67 -19
- package/dist/chunk-JAKOMFC6.js.map +1 -0
- package/dist/{chunk-THEJJBOU.js → chunk-JZ5EHBPI.js} +3 -3
- package/dist/{chunk-THEJJBOU.js.map → chunk-JZ5EHBPI.js.map} +1 -1
- package/dist/{chunk-BWZF2ZIF.js → chunk-K3CVFRVS.js} +3 -3
- package/dist/{chunk-BWZF2ZIF.js.map → chunk-K3CVFRVS.js.map} +1 -1
- package/dist/{chunk-VOOI7B2L.js → chunk-LAMCXQGA.js} +241 -73
- package/dist/chunk-LAMCXQGA.js.map +1 -0
- package/dist/{chunk-37FTLYFP.js → chunk-LNFKL23K.js} +3 -3
- package/dist/{chunk-37FTLYFP.js.map → chunk-LNFKL23K.js.map} +1 -1
- package/dist/{chunk-XUUYAS3Z.js → chunk-M3WPBTGJ.js} +3 -3
- package/dist/{chunk-XUUYAS3Z.js.map → chunk-M3WPBTGJ.js.map} +1 -1
- package/dist/{chunk-QZLWJETK.js → chunk-MGGFBZWA.js} +3 -3
- package/dist/{chunk-QZLWJETK.js.map → chunk-MGGFBZWA.js.map} +1 -1
- package/dist/{chunk-34C42MJX.js → chunk-MR5HBOUF.js} +5 -5
- package/dist/{chunk-34C42MJX.js.map → chunk-MR5HBOUF.js.map} +1 -1
- package/dist/{chunk-QCI6D7E4.js → chunk-NUELZWCF.js} +266 -170
- package/dist/chunk-NUELZWCF.js.map +1 -0
- package/dist/{chunk-GIC3G5YG.js → chunk-P67WJVP4.js} +7 -13
- package/dist/chunk-P67WJVP4.js.map +1 -0
- package/dist/{chunk-G67BOI2J.js → chunk-PMECEZK3.js} +15 -9
- package/dist/chunk-PMECEZK3.js.map +1 -0
- package/dist/{chunk-OKGUDNDT.js → chunk-Q6E6FM7P.js} +35 -33
- package/dist/chunk-Q6E6FM7P.js.map +1 -0
- package/dist/{chunk-CWM3MYGX.js → chunk-QVEKLSEH.js} +8 -9
- package/dist/chunk-QVEKLSEH.js.map +1 -0
- package/dist/{chunk-O7VPNKYN.js → chunk-QVNRCDTV.js} +23 -7
- package/dist/chunk-QVNRCDTV.js.map +1 -0
- package/dist/{chunk-UX3K4RKE.js → chunk-S53LOR7B.js} +3 -3
- package/dist/{chunk-UX3K4RKE.js.map → chunk-S53LOR7B.js.map} +1 -1
- package/dist/{chunk-53MSCGR2.js → chunk-SCOT677Q.js} +5 -5
- package/dist/{chunk-53MSCGR2.js.map → chunk-SCOT677Q.js.map} +1 -1
- package/dist/{chunk-SZWRPEF7.js → chunk-TTRYE6AC.js} +39 -29
- package/dist/chunk-TTRYE6AC.js.map +1 -0
- package/dist/{chunk-KM7XWC4Y.js → chunk-UAROCOXF.js} +3 -3
- package/dist/{chunk-KM7XWC4Y.js.map → chunk-UAROCOXF.js.map} +1 -1
- package/dist/{chunk-MKLBK7HI.js → chunk-UM7RIAHO.js} +17 -13
- package/dist/chunk-UM7RIAHO.js.map +1 -0
- package/dist/{chunk-JMKB7IB4.js → chunk-UMVKJM4Q.js} +4 -4
- package/dist/chunk-UMVKJM4Q.js.map +1 -0
- package/dist/{chunk-JLSCA5T5.js → chunk-UO7WPLDY.js} +3 -3
- package/dist/{chunk-JLSCA5T5.js.map → chunk-UO7WPLDY.js.map} +1 -1
- package/dist/{chunk-HCYS7GFP.js → chunk-V2DXZYBB.js} +3 -3
- package/dist/{chunk-HCYS7GFP.js.map → chunk-V2DXZYBB.js.map} +1 -1
- package/dist/{chunk-47ZD34KB.js → chunk-VMKMFS2Q.js} +28 -7
- package/dist/chunk-VMKMFS2Q.js.map +1 -0
- package/dist/{chunk-IUUYRXT6.js → chunk-W5DWWE4Y.js} +4 -4
- package/dist/{chunk-IUUYRXT6.js.map → chunk-W5DWWE4Y.js.map} +1 -1
- package/dist/{chunk-FK6HPLQA.js → chunk-X4BAYGMT.js} +3 -3
- package/dist/{chunk-FK6HPLQA.js.map → chunk-X4BAYGMT.js.map} +1 -1
- package/dist/{chunk-OJ4N4T4H.js → chunk-XDVR7QIT.js} +20 -6
- package/dist/chunk-XDVR7QIT.js.map +1 -0
- package/dist/{chunk-7FJQT3GT.js → chunk-Y4N2NUZD.js} +4 -4
- package/dist/{chunk-7FJQT3GT.js.map → chunk-Y4N2NUZD.js.map} +1 -1
- package/dist/{chunk-6VRJH4MR.js → chunk-Y7QA2OLD.js} +6 -6
- package/dist/{chunk-6VRJH4MR.js.map → chunk-Y7QA2OLD.js.map} +1 -1
- package/dist/{chunk-74EEFB52.js → chunk-YSHVQGUS.js} +115 -27
- package/dist/chunk-YSHVQGUS.js.map +1 -0
- package/dist/{chunk-6C654TFI.js → chunk-ZAOGFXDO.js} +36 -8
- package/dist/chunk-ZAOGFXDO.js.map +1 -0
- package/dist/{chunk-N6FBTXQ5.js → chunk-ZTBAYUDY.js} +2 -2
- package/dist/{chunk-N6FBTXQ5.js.map → chunk-ZTBAYUDY.js.map} +1 -1
- package/dist/cli/index.js +373 -188
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/src/asset-feeds.d.ts +5 -2
- package/dist/cli/src/asset-feeds.d.ts.map +1 -1
- package/dist/cli/src/commands/asset-cmd.d.ts.map +1 -1
- package/dist/cli/src/commands/catalog.d.ts +15 -2
- package/dist/cli/src/commands/catalog.d.ts.map +1 -1
- package/dist/cli/src/commands/library-cmd.d.ts.map +1 -1
- package/dist/cli/src/commands/library-index.d.ts +8 -0
- package/dist/cli/src/commands/library-index.d.ts.map +1 -1
- package/dist/cli/src/commands/library-publish.d.ts.map +1 -1
- package/dist/cli/src/commands/manage.d.ts.map +1 -1
- package/dist/cli/src/commands/outdated.d.ts +7 -2
- package/dist/cli/src/commands/outdated.d.ts.map +1 -1
- package/dist/cli/src/commands/project.d.ts +2 -0
- package/dist/cli/src/commands/project.d.ts.map +1 -1
- package/dist/cli/src/commands/publish-core.d.ts +10 -1
- package/dist/cli/src/commands/publish-core.d.ts.map +1 -1
- package/dist/cli/src/commands/session.d.ts.map +1 -1
- package/dist/cli/src/commands/source.d.ts +14 -0
- package/dist/cli/src/commands/source.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.d.ts.map +1 -1
- package/dist/cli/src/flow-discovery.d.ts +8 -5
- package/dist/cli/src/flow-discovery.d.ts.map +1 -1
- package/dist/cli/src/open-library.d.ts +0 -11
- package/dist/cli/src/open-library.d.ts.map +1 -1
- package/dist/cli/src/skill-checks.d.ts +11 -2
- package/dist/cli/src/skill-checks.d.ts.map +1 -1
- package/dist/client/index.js +1 -1
- package/dist/client/src/client.d.ts +10 -3
- package/dist/client/src/client.d.ts.map +1 -1
- package/dist/connectors/config.js +5 -5
- package/dist/connectors/index.js +25 -26
- package/dist/connectors/src/access-policy.d.ts +33 -0
- package/dist/connectors/src/access-policy.d.ts.map +1 -0
- package/dist/connectors/src/connector-manager.d.ts.map +1 -1
- package/dist/connectors/src/index.d.ts +2 -0
- package/dist/connectors/src/index.d.ts.map +1 -1
- package/dist/connectors-C7UQ73BK.js +44 -0
- package/dist/{connectors-SSOTIDHT.js.map → connectors-C7UQ73BK.js.map} +1 -1
- package/dist/connectors-shared/index.js +2 -2
- package/dist/core/index.js +8 -8
- package/dist/core/logging.js +1 -1
- 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 +5 -5
- package/dist/core/src/index.d.ts +3 -3
- package/dist/core/src/index.d.ts.map +1 -1
- package/dist/core/src/logging/config.d.ts +9 -1
- package/dist/core/src/logging/config.d.ts.map +1 -1
- package/dist/core/src/manifest.d.ts +11 -1
- package/dist/core/src/manifest.d.ts.map +1 -1
- package/dist/core/src/models.d.ts +14 -6
- package/dist/core/src/models.d.ts.map +1 -1
- package/dist/core/src/repo-manager.d.ts +41 -6
- package/dist/core/src/repo-manager.d.ts.map +1 -1
- package/dist/core/src/store.d.ts +16 -2
- package/dist/core/src/store.d.ts.map +1 -1
- package/dist/core/src/workspace-config.d.ts +10 -1
- package/dist/core/src/workspace-config.d.ts.map +1 -1
- package/dist/core/store.js +1 -1
- package/dist/core/workspace-config.js +4 -4
- package/dist/deploy/index.js +8 -8
- package/dist/discovery/index.js +5 -5
- package/dist/{ensure-sources-277VI7R3.js → ensure-sources-SRC2DVR5.js} +18 -18
- package/dist/{ensure-sources-277VI7R3.js.map → ensure-sources-SRC2DVR5.js.map} +1 -1
- package/dist/factory-assets/connectors/box.js +25 -26
- package/dist/factory-assets/connectors/deploy.js +25 -26
- package/dist/factory-assets/connectors/devserver.js +25 -26
- package/dist/factory-assets/connectors/flow/adapter.d.ts +6 -0
- package/dist/factory-assets/connectors/flow/adapter.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/adapter.js +25 -26
- package/dist/factory-assets/connectors/flow/contract/expression.d.ts +3 -0
- package/dist/factory-assets/connectors/flow/contract/expression.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/contract/output-fields.d.ts +1 -1
- package/dist/factory-assets/connectors/flow/contract/output-fields.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/contract/schema.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/contract.js +4 -4
- package/dist/factory-assets/connectors/flow/engine/flow-output.d.ts +4 -3
- package/dist/factory-assets/connectors/flow/engine/flow-output.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/engine/output-schema.d.ts +6 -1
- package/dist/factory-assets/connectors/flow/engine/output-schema.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/engine.js +12 -12
- package/dist/factory-assets/connectors/flow/inline-sub-flow-host.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/prompt-fragments.js +3 -3
- package/dist/factory-assets/connectors/flow/run-flow.d.ts.map +1 -1
- package/dist/factory-assets/connectors/flow/run-flow.js +27 -28
- package/dist/factory-assets/connectors/flow.js +25 -26
- package/dist/factory-assets/connectors/git/config.d.ts.map +1 -1
- package/dist/factory-assets/connectors/git.js +25 -26
- package/dist/factory-assets/connectors/gmail.js +25 -26
- package/dist/factory-assets/connectors/googledrive.js +25 -26
- package/dist/factory-assets/connectors/local.js +25 -26
- package/dist/factory-assets/connectors/mattermost.js +25 -26
- package/dist/factory-assets/connectors/memory.js +25 -26
- package/dist/factory-assets/connectors/minio.js +25 -26
- package/dist/factory-assets/connectors/postgres.js +25 -26
- package/dist/factory-assets/connectors/s3.js +25 -26
- package/dist/factory-assets/connectors/sharepoint.js +25 -26
- package/dist/factory-assets/connectors/sqlite.js +25 -26
- package/dist/factory-assets/connectors/static-server.js +25 -26
- package/dist/factory-assets/connectors/tunnel.js +25 -26
- package/dist/factory-assets/connectors/webdav.js +25 -26
- package/dist/factory-assets/connectors/xstate-store.js +25 -26
- package/dist/factory-assets/connectors/xstate.js +25 -26
- package/dist/factory-assets/skills/skaile-author-asset/SKILL.md +10 -7
- package/dist/{flows-J2UEU2QM.js → flows-CBYRSAGS.js} +13 -13
- package/dist/{flows-J2UEU2QM.js.map → flows-CBYRSAGS.js.map} +1 -1
- package/dist/{helpers-KC5O7CML.js → helpers-XAEKCZKT.js} +18 -18
- package/dist/{helpers-KC5O7CML.js.map → helpers-XAEKCZKT.js.map} +1 -1
- package/dist/library/index.js +12 -12
- package/dist/library/install.js +3 -3
- package/dist/library/src/index.d.ts +3 -1
- package/dist/library/src/index.d.ts.map +1 -1
- package/dist/library/src/local/scan-authoring-libraries.d.ts +43 -0
- package/dist/library/src/local/scan-authoring-libraries.d.ts.map +1 -0
- package/dist/library/src/manifest-writer.d.ts +26 -3
- package/dist/library/src/manifest-writer.d.ts.map +1 -1
- package/dist/library/src/sync/git-driver.d.ts.map +1 -1
- package/dist/{library-publish-FGXF5TJO.js → library-publish-VJSWMOLH.js} +73 -37
- package/dist/library-publish-VJSWMOLH.js.map +1 -0
- package/dist/open-library-DB2PNL2X.js +40 -0
- package/dist/{open-library-P3D337NH.js.map → open-library-DB2PNL2X.js.map} +1 -1
- package/dist/open-registry-ZUZJ7MS7.js +32 -0
- package/dist/{open-registry-Z3P2X2AB.js.map → open-registry-ZUZJ7MS7.js.map} +1 -1
- package/dist/paths-FQ64OLJG.js +22 -0
- package/dist/{paths-JKEKXM52.js.map → paths-FQ64OLJG.js.map} +1 -1
- package/dist/{plugin-store-WI4MZJLP.js → plugin-store-MPAMD5OT.js} +10 -10
- package/dist/{plugin-store-WI4MZJLP.js.map → plugin-store-MPAMD5OT.js.map} +1 -1
- package/dist/project-I6NX3NFB.js +41 -0
- package/dist/{project-WFUDVYNN.js.map → project-I6NX3NFB.js.map} +1 -1
- package/dist/resolver/index.js +9 -9
- package/dist/runner/index.js +40 -41
- package/dist/runner/src/context-usage/compose.d.ts.map +1 -1
- package/dist/runner/src/logging-bootstrap.d.ts +6 -0
- package/dist/runner/src/logging-bootstrap.d.ts.map +1 -1
- package/dist/runner/src/platform-blocks.d.ts +55 -0
- package/dist/runner/src/platform-blocks.d.ts.map +1 -0
- package/dist/runner/src/reconfigure-handler.d.ts +38 -17
- package/dist/runner/src/reconfigure-handler.d.ts.map +1 -1
- package/dist/runner/src/serve.d.ts.map +1 -1
- package/dist/runner/src/session-builder.d.ts.map +1 -1
- package/dist/runner/src/session-capability-wiring.d.ts +0 -2
- package/dist/runner/src/session-capability-wiring.d.ts.map +1 -1
- package/dist/sdk/asset-manager.js +15 -15
- package/dist/sdk/bridge.js +16 -17
- package/dist/sdk/client.js +1 -1
- package/dist/sdk/core.js +8 -8
- package/dist/sdk/flow.js +12 -12
- package/dist/sdk/index.js +69 -46
- package/dist/sdk/index.js.map +1 -1
- package/dist/sdk/resolver.js +9 -9
- package/dist/sdk/runner.js +40 -41
- package/dist/sdk/session.js +2 -2
- package/dist/sdk/src/agent-session.d.ts +8 -0
- package/dist/sdk/src/agent-session.d.ts.map +1 -1
- package/dist/sdk/store.js +2 -1
- package/dist/sdk/types.js +1 -1
- package/dist/session/index.js +2 -2
- package/dist/session/src/dispatcher.d.ts +25 -4
- package/dist/session/src/dispatcher.d.ts.map +1 -1
- package/dist/session/src/index.d.ts +1 -1
- package/dist/session/src/index.d.ts.map +1 -1
- package/dist/{setup-RAMLTORM.js → setup-B7JUHYJW.js} +26 -27
- package/dist/setup-B7JUHYJW.js.map +1 -0
- package/dist/skills-TVO26Y4V.js +26 -0
- package/dist/{skills-EOHZ2DZ4.js.map → skills-TVO26Y4V.js.map} +1 -1
- package/dist/source-PJBMDCKX.js +41 -0
- package/dist/{source-FYVSFYEI.js.map → source-PJBMDCKX.js.map} +1 -1
- package/dist/{source-manifest-publish-4FPIPPLV.js → source-manifest-publish-LLJWXGID.js} +27 -27
- package/dist/{source-manifest-publish-4FPIPPLV.js.map → source-manifest-publish-LLJWXGID.js.map} +1 -1
- package/dist/store/index.js +2 -1
- package/dist/store/src/store.d.ts +8 -5
- package/dist/store/src/store.d.ts.map +1 -1
- package/dist/tui/index.js +40 -41
- 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/ask-slots.d.ts +68 -0
- package/dist/types/src/ask-slots.d.ts.map +1 -0
- package/dist/types/src/delivery.d.ts.map +1 -1
- package/dist/types/src/events.d.ts +30 -2
- package/dist/types/src/events.d.ts.map +1 -1
- package/dist/types/src/index.d.ts +3 -3
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/manifests/index.d.ts +1 -1
- package/dist/types/src/manifests/index.d.ts.map +1 -1
- package/dist/types/src/manifests/preset.d.ts +4 -0
- package/dist/types/src/manifests/preset.d.ts.map +1 -1
- package/dist/types/src/protocol.d.ts +43 -1
- package/dist/types/src/protocol.d.ts.map +1 -1
- package/dist/types/src/version.d.ts +28 -1
- package/dist/types/src/version.d.ts.map +1 -1
- package/dist/workspace-plugin/adapters/mcp.js +32 -33
- package/dist/workspace-plugin/adapters/omp.js +14 -14
- package/dist/workspace-plugin/index.js +2 -2
- package/package.json +1 -1
- package/dist/asset-feeds-K36CR52Q.js.map +0 -1
- package/dist/chunk-47ZD34KB.js.map +0 -1
- package/dist/chunk-6C654TFI.js.map +0 -1
- package/dist/chunk-74EEFB52.js.map +0 -1
- package/dist/chunk-BTK7ECLH.js.map +0 -1
- package/dist/chunk-CWM3MYGX.js.map +0 -1
- package/dist/chunk-D5HOETOB.js.map +0 -1
- package/dist/chunk-DFFD4BFG.js.map +0 -1
- package/dist/chunk-DMLDYFDS.js.map +0 -1
- package/dist/chunk-EINLFFP6.js +0 -59
- package/dist/chunk-EINLFFP6.js.map +0 -1
- package/dist/chunk-EU3Q5AQ4.js.map +0 -1
- package/dist/chunk-FRHE7FFB.js.map +0 -1
- package/dist/chunk-G67BOI2J.js.map +0 -1
- package/dist/chunk-GIC3G5YG.js.map +0 -1
- package/dist/chunk-IZLQ4GDO.js.map +0 -1
- package/dist/chunk-JMKB7IB4.js.map +0 -1
- package/dist/chunk-LBQ4BBX4.js.map +0 -1
- package/dist/chunk-LCU5U5IW.js.map +0 -1
- package/dist/chunk-LXY4BUA3.js.map +0 -1
- package/dist/chunk-MKLBK7HI.js.map +0 -1
- package/dist/chunk-O7VPNKYN.js.map +0 -1
- package/dist/chunk-OJ4N4T4H.js.map +0 -1
- package/dist/chunk-OKGUDNDT.js.map +0 -1
- package/dist/chunk-QCI6D7E4.js.map +0 -1
- package/dist/chunk-SZWRPEF7.js.map +0 -1
- package/dist/chunk-TTPSDC2G.js.map +0 -1
- package/dist/chunk-VOOI7B2L.js.map +0 -1
- package/dist/chunk-XBSQ4KMC.js.map +0 -1
- package/dist/connectors-SSOTIDHT.js +0 -45
- package/dist/library-publish-FGXF5TJO.js.map +0 -1
- package/dist/open-library-P3D337NH.js +0 -40
- package/dist/open-registry-Z3P2X2AB.js +0 -32
- package/dist/paths-JKEKXM52.js +0 -22
- package/dist/project-WFUDVYNN.js +0 -41
- package/dist/setup-RAMLTORM.js.map +0 -1
- package/dist/skills-EOHZ2DZ4.js +0 -26
- package/dist/source-FYVSFYEI.js +0 -41
|
@@ -332,7 +332,7 @@ function ownValue(value, segment, position, path) {
|
|
|
332
332
|
}
|
|
333
333
|
return value[segment];
|
|
334
334
|
}
|
|
335
|
-
function
|
|
335
|
+
function parsePathShape(raw, position) {
|
|
336
336
|
const segments = raw.split(".");
|
|
337
337
|
if (segments.length > FLOW_EXPRESSION_LIMITS.maxPathSegments) {
|
|
338
338
|
throw expressionError(
|
|
@@ -345,43 +345,45 @@ function resolvePath(raw, context, position, traverse) {
|
|
|
345
345
|
}
|
|
346
346
|
const forbidden = segments.find((segment) => FORBIDDEN_PATH_SEGMENTS.has(segment));
|
|
347
347
|
if (forbidden) throw expressionError(`contains forbidden path segment ${forbidden}`, position);
|
|
348
|
-
let value;
|
|
349
|
-
let remaining;
|
|
350
|
-
let skippedProducer;
|
|
351
348
|
if (segments[0] === "flow" && segments[1] === "input") {
|
|
352
349
|
if (segments.length === 2) {
|
|
353
350
|
throw expressionError("path requires a JSON property suffix", position);
|
|
354
351
|
}
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
352
|
+
return { root: "input", remaining: segments.slice(2) };
|
|
353
|
+
}
|
|
354
|
+
if (segments[0] === "defaults" && segments.length >= 2) {
|
|
355
|
+
return { root: "defaults", remaining: segments.slice(1) };
|
|
356
|
+
}
|
|
357
|
+
if (segments[0] === "nodes" && segments.length === 3 && segments[2] === "status") {
|
|
358
|
+
return { root: "nodes", remaining: segments.slice(1) };
|
|
359
|
+
}
|
|
360
|
+
if (segments[0] === "nodes" && segments.length >= 4 && segments[2] === "output" && segments[3] === "fields") {
|
|
364
361
|
if (segments.length === 4) {
|
|
365
362
|
throw expressionError("path requires a JSON property suffix", position);
|
|
366
363
|
}
|
|
367
|
-
|
|
368
|
-
skippedProducer = segments[1];
|
|
369
|
-
}
|
|
370
|
-
value = context.nodes;
|
|
371
|
-
remaining = segments.slice(1);
|
|
372
|
-
} else {
|
|
373
|
-
throw expressionError(`contains unsupported path ${raw}`, position);
|
|
364
|
+
return { root: "nodes", remaining: segments.slice(1), outputProducer: segments[1] };
|
|
374
365
|
}
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
366
|
+
throw expressionError(`contains unsupported path ${raw}`, position);
|
|
367
|
+
}
|
|
368
|
+
function readPath(shape, raw, context, position) {
|
|
369
|
+
let value;
|
|
370
|
+
if (shape.root === "input") {
|
|
371
|
+
value = context.flow.input;
|
|
372
|
+
} else if (shape.root === "defaults") {
|
|
373
|
+
value = context.defaults ?? {};
|
|
374
|
+
} else {
|
|
375
|
+
value = context.nodes;
|
|
376
|
+
const producer = shape.outputProducer;
|
|
377
|
+
if (producer !== void 0 && Object.hasOwn(context.nodes, producer) && context.nodes[producer].status === "skipped") {
|
|
378
|
+
throw expressionError(
|
|
379
|
+
`cannot read ${raw}: producer node ${producer} was skipped and produced no output`,
|
|
380
|
+
position,
|
|
381
|
+
raw,
|
|
382
|
+
producer
|
|
383
|
+
);
|
|
384
|
+
}
|
|
383
385
|
}
|
|
384
|
-
for (const segment of remaining) value = ownValue(value, segment, position, raw);
|
|
386
|
+
for (const segment of shape.remaining) value = ownValue(value, segment, position, raw);
|
|
385
387
|
return value;
|
|
386
388
|
}
|
|
387
389
|
function compare(operator, left, right, position) {
|
|
@@ -418,35 +420,16 @@ function isBooleanOperand(value) {
|
|
|
418
420
|
function assertBooleanOperand(value, position) {
|
|
419
421
|
if (!isBooleanOperand(value)) throw expressionError("requires boolean operands", position);
|
|
420
422
|
}
|
|
421
|
-
var
|
|
422
|
-
|
|
423
|
+
var COMPARISON_OPERATORS = ["==", "!=", "<", "<=", ">", ">=", "in"];
|
|
424
|
+
var ExpressionBuilder = class {
|
|
425
|
+
constructor(tokens) {
|
|
423
426
|
this.tokens = tokens;
|
|
424
|
-
this.context = context;
|
|
425
|
-
this.onPath = onPath;
|
|
426
|
-
this.onBooleanPath = onBooleanPath;
|
|
427
|
-
this.onEvaluatedPath = onEvaluatedPath;
|
|
428
|
-
this.onComparison = onComparison;
|
|
429
427
|
}
|
|
430
428
|
tokens;
|
|
431
|
-
context;
|
|
432
|
-
onPath;
|
|
433
|
-
onBooleanPath;
|
|
434
|
-
onEvaluatedPath;
|
|
435
|
-
onComparison;
|
|
436
429
|
index = 0;
|
|
437
430
|
nesting = 0;
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
/**
|
|
441
|
-
* Guards the operand {@link parseComparison} just parsed establishes when true:
|
|
442
|
-
* its own path for a literal `path == true`, or every guard of a parenthesized
|
|
443
|
-
* `&&` group, which is true only when all its conjuncts are.
|
|
444
|
-
*/
|
|
445
|
-
lastGuards = [];
|
|
446
|
-
/** Guards of the `&&` / `||` chain that just finished; empty once a `||` joined it. */
|
|
447
|
-
lastChainGuards = [];
|
|
448
|
-
parse(evaluate2 = true) {
|
|
449
|
-
const value = this.parseOr(evaluate2);
|
|
431
|
+
build() {
|
|
432
|
+
const root = this.parseOr();
|
|
450
433
|
const trailing = this.peek();
|
|
451
434
|
if (trailing.kind !== "eof") {
|
|
452
435
|
throw expressionError(
|
|
@@ -454,7 +437,7 @@ var Parser = class {
|
|
|
454
437
|
trailing.position
|
|
455
438
|
);
|
|
456
439
|
}
|
|
457
|
-
return
|
|
440
|
+
return root;
|
|
458
441
|
}
|
|
459
442
|
peek() {
|
|
460
443
|
return this.tokens[this.index];
|
|
@@ -466,105 +449,79 @@ var Parser = class {
|
|
|
466
449
|
if (this.peek().value !== value) return void 0;
|
|
467
450
|
return this.take();
|
|
468
451
|
}
|
|
469
|
-
parseOr(
|
|
470
|
-
|
|
471
|
-
|
|
452
|
+
parseOr() {
|
|
453
|
+
const operands = [this.parseAnd()];
|
|
454
|
+
const positions = [];
|
|
472
455
|
while (this.peek().value === "||") {
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
const evaluateRight = evaluate2 && value === false;
|
|
478
|
-
const right = this.parseAnd(evaluateRight);
|
|
479
|
-
assertBooleanOperand(right, operator.position);
|
|
480
|
-
if (isStaticPath(right)) this.onBooleanPath?.(right.path);
|
|
481
|
-
value = evaluate2 ? value === true || right === true : STATIC_BOOLEAN;
|
|
482
|
-
}
|
|
483
|
-
if (disjunction) this.lastChainGuards = [];
|
|
484
|
-
return value;
|
|
456
|
+
positions.push(this.take().position);
|
|
457
|
+
operands.push(this.parseAnd());
|
|
458
|
+
}
|
|
459
|
+
return { kind: "or", operands, positions };
|
|
485
460
|
}
|
|
486
|
-
parseAnd(
|
|
487
|
-
const
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
while (this.peek().value === "&&") {
|
|
493
|
-
const operator = this.take();
|
|
494
|
-
assertBooleanOperand(value, operator.position);
|
|
495
|
-
if (isStaticPath(value)) this.onBooleanPath?.(value.path);
|
|
496
|
-
const evaluateRight = evaluate2 && value === true;
|
|
497
|
-
const right = this.parseComparison(evaluateRight);
|
|
498
|
-
guards.push(...this.lastGuards);
|
|
499
|
-
assertBooleanOperand(right, operator.position);
|
|
500
|
-
if (isStaticPath(right)) this.onBooleanPath?.(right.path);
|
|
501
|
-
value = evaluate2 ? value === true && right === true : STATIC_BOOLEAN;
|
|
502
|
-
}
|
|
503
|
-
this.lastChainGuards = [...guards];
|
|
504
|
-
return value;
|
|
505
|
-
} finally {
|
|
506
|
-
this.guardFrames.pop();
|
|
461
|
+
parseAnd() {
|
|
462
|
+
const operands = [this.parseComparison()];
|
|
463
|
+
const positions = [];
|
|
464
|
+
while (this.peek().value === "&&") {
|
|
465
|
+
positions.push(this.take().position);
|
|
466
|
+
operands.push(this.parseComparison());
|
|
507
467
|
}
|
|
468
|
+
return { kind: "and", operands, positions };
|
|
508
469
|
}
|
|
509
|
-
parseComparison(
|
|
510
|
-
const
|
|
511
|
-
const left = this.parseUnary(evaluate2);
|
|
470
|
+
parseComparison() {
|
|
471
|
+
const left = this.parseUnary();
|
|
512
472
|
const token = this.peek();
|
|
513
|
-
if (token.kind !== "operator" || !
|
|
514
|
-
this.lastGuards = group ? this.lastChainGuards : [];
|
|
473
|
+
if (token.kind !== "operator" || !COMPARISON_OPERATORS.includes(String(token.value))) {
|
|
515
474
|
return left;
|
|
516
475
|
}
|
|
517
476
|
this.take();
|
|
518
|
-
const right = this.parseUnary(
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
operator,
|
|
522
|
-
left
|
|
523
|
-
right
|
|
524
|
-
|
|
525
|
-
}
|
|
526
|
-
this.lastGuards = operator === "==" && isStaticPath(left) && right === true ? [left.path] : [];
|
|
527
|
-
return evaluate2 ? compare(operator, left, right, token.position) : STATIC_BOOLEAN;
|
|
477
|
+
const right = this.parseUnary();
|
|
478
|
+
return {
|
|
479
|
+
kind: "compare",
|
|
480
|
+
operator: String(token.value),
|
|
481
|
+
left,
|
|
482
|
+
right,
|
|
483
|
+
position: token.position
|
|
484
|
+
};
|
|
528
485
|
}
|
|
529
|
-
parseUnary(
|
|
486
|
+
parseUnary() {
|
|
530
487
|
const operator = this.accept("!");
|
|
531
488
|
if (operator) {
|
|
532
|
-
|
|
533
|
-
assertBooleanOperand(value, operator.position);
|
|
534
|
-
if (isStaticPath(value)) this.onBooleanPath?.(value.path);
|
|
535
|
-
return evaluate2 ? value === false : STATIC_BOOLEAN;
|
|
489
|
+
return { kind: "not", operand: this.parseUnary(), position: operator.position };
|
|
536
490
|
}
|
|
537
|
-
return this.parsePrimary(
|
|
491
|
+
return this.parsePrimary();
|
|
538
492
|
}
|
|
539
|
-
parsePrimary(
|
|
493
|
+
parsePrimary() {
|
|
540
494
|
const token = this.take();
|
|
541
|
-
if (token.kind === "value") return token.value;
|
|
495
|
+
if (token.kind === "value") return { kind: "literal", value: token.value };
|
|
542
496
|
if (token.kind === "word") {
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
497
|
+
const path = String(token.value);
|
|
498
|
+
return {
|
|
499
|
+
kind: "path",
|
|
500
|
+
path,
|
|
501
|
+
position: token.position,
|
|
502
|
+
shape: parsePathShape(path, token.position)
|
|
503
|
+
};
|
|
547
504
|
}
|
|
548
505
|
if (token.value === "(") {
|
|
549
506
|
this.enterNesting(token.position);
|
|
550
|
-
const
|
|
507
|
+
const inner = this.parseOr();
|
|
551
508
|
if (!this.accept(")"))
|
|
552
509
|
throw expressionError("is missing a closing parenthesis", token.position);
|
|
553
510
|
this.nesting--;
|
|
554
|
-
return
|
|
511
|
+
return { kind: "group", inner };
|
|
555
512
|
}
|
|
556
513
|
if (token.value === "[") {
|
|
557
514
|
this.enterNesting(token.position);
|
|
558
|
-
const
|
|
515
|
+
const items = [];
|
|
559
516
|
if (!this.accept("]")) {
|
|
560
517
|
do
|
|
561
|
-
|
|
518
|
+
items.push(this.parsePrimary());
|
|
562
519
|
while (this.accept(","));
|
|
563
520
|
if (!this.accept("]"))
|
|
564
521
|
throw expressionError("is missing a closing bracket", token.position);
|
|
565
522
|
}
|
|
566
523
|
this.nesting--;
|
|
567
|
-
return
|
|
524
|
+
return { kind: "list", items };
|
|
568
525
|
}
|
|
569
526
|
throw expressionError(`contains unexpected token ${String(token.value)}`, token.position);
|
|
570
527
|
}
|
|
@@ -578,44 +535,185 @@ var Parser = class {
|
|
|
578
535
|
}
|
|
579
536
|
}
|
|
580
537
|
};
|
|
581
|
-
|
|
538
|
+
var ExpressionAnalyzer = class {
|
|
539
|
+
references = /* @__PURE__ */ new Map();
|
|
540
|
+
comparisons = [];
|
|
541
|
+
/** Literal `path == true` conjuncts already analyzed, one frame per enclosing `&&` chain. */
|
|
542
|
+
guardFrames = [];
|
|
543
|
+
/**
|
|
544
|
+
* Guards the operand {@link analyzeOperand} just analyzed establishes when true:
|
|
545
|
+
* its own path for a literal `path == true`, or every guard of a parenthesized
|
|
546
|
+
* `&&` group, which is true only when all its conjuncts are.
|
|
547
|
+
*/
|
|
548
|
+
lastGuards = [];
|
|
549
|
+
/** Guards of the `&&` / `||` chain that just finished; empty once a `||` joined it. */
|
|
550
|
+
lastChainGuards = [];
|
|
551
|
+
record(path, booleanOperand) {
|
|
552
|
+
this.references.set(path, (this.references.get(path) ?? false) || booleanOperand);
|
|
553
|
+
}
|
|
554
|
+
booleanOperand(value, position) {
|
|
555
|
+
assertBooleanOperand(value, position);
|
|
556
|
+
if (isStaticPath(value)) this.record(value.path, true);
|
|
557
|
+
}
|
|
558
|
+
/** Static value of a node: literals as themselves, paths as markers, computed booleans as one marker. */
|
|
559
|
+
analyze(node) {
|
|
560
|
+
switch (node.kind) {
|
|
561
|
+
case "literal":
|
|
562
|
+
return node.value;
|
|
563
|
+
case "path":
|
|
564
|
+
this.record(node.path, false);
|
|
565
|
+
return { marker: STATIC_PATH, path: node.path };
|
|
566
|
+
case "list":
|
|
567
|
+
return node.items.map((item) => this.analyze(item));
|
|
568
|
+
case "group":
|
|
569
|
+
return this.analyze(node.inner);
|
|
570
|
+
case "not": {
|
|
571
|
+
const value = this.analyze(node.operand);
|
|
572
|
+
this.booleanOperand(value, node.position);
|
|
573
|
+
return STATIC_BOOLEAN;
|
|
574
|
+
}
|
|
575
|
+
case "compare": {
|
|
576
|
+
const left = this.analyze(node.left);
|
|
577
|
+
const right = this.analyze(node.right);
|
|
578
|
+
this.comparisons.push({
|
|
579
|
+
operator: node.operator,
|
|
580
|
+
left: isStaticPath(left) ? { path: left.path } : { literal: left },
|
|
581
|
+
right: isStaticPath(right) ? { path: right.path } : { literal: right },
|
|
582
|
+
guards: this.guardFrames.flat()
|
|
583
|
+
});
|
|
584
|
+
this.lastGuards = node.operator === "==" && isStaticPath(left) && right === true ? [left.path] : [];
|
|
585
|
+
return STATIC_BOOLEAN;
|
|
586
|
+
}
|
|
587
|
+
case "and":
|
|
588
|
+
return this.analyzeAnd(node);
|
|
589
|
+
case "or":
|
|
590
|
+
return this.analyzeOr(node);
|
|
591
|
+
}
|
|
592
|
+
}
|
|
593
|
+
analyzeOperand(node) {
|
|
594
|
+
if (node.kind === "compare") return this.analyze(node);
|
|
595
|
+
const value = this.analyze(node);
|
|
596
|
+
this.lastGuards = node.kind === "group" ? this.lastChainGuards : [];
|
|
597
|
+
return value;
|
|
598
|
+
}
|
|
599
|
+
analyzeAnd(node) {
|
|
600
|
+
const guards = [];
|
|
601
|
+
this.guardFrames.push(guards);
|
|
602
|
+
try {
|
|
603
|
+
let value = this.analyzeOperand(node.operands[0]);
|
|
604
|
+
guards.push(...this.lastGuards);
|
|
605
|
+
for (let index = 1; index < node.operands.length; index++) {
|
|
606
|
+
const position = node.positions[index - 1];
|
|
607
|
+
this.booleanOperand(value, position);
|
|
608
|
+
const right = this.analyzeOperand(node.operands[index]);
|
|
609
|
+
guards.push(...this.lastGuards);
|
|
610
|
+
this.booleanOperand(right, position);
|
|
611
|
+
value = STATIC_BOOLEAN;
|
|
612
|
+
}
|
|
613
|
+
this.lastChainGuards = [...guards];
|
|
614
|
+
return value;
|
|
615
|
+
} finally {
|
|
616
|
+
this.guardFrames.pop();
|
|
617
|
+
}
|
|
618
|
+
}
|
|
619
|
+
analyzeOr(node) {
|
|
620
|
+
let value = this.analyze(node.operands[0]);
|
|
621
|
+
for (let index = 1; index < node.operands.length; index++) {
|
|
622
|
+
const position = node.positions[index - 1];
|
|
623
|
+
this.booleanOperand(value, position);
|
|
624
|
+
const right = this.analyze(node.operands[index]);
|
|
625
|
+
this.booleanOperand(right, position);
|
|
626
|
+
value = STATIC_BOOLEAN;
|
|
627
|
+
}
|
|
628
|
+
if (node.operands.length > 1) this.lastChainGuards = [];
|
|
629
|
+
return value;
|
|
630
|
+
}
|
|
631
|
+
};
|
|
632
|
+
function assertBooleanValue(value, position) {
|
|
633
|
+
if (typeof value !== "boolean") throw expressionError("requires boolean operands", position);
|
|
634
|
+
}
|
|
635
|
+
function evaluateNode(node, context, onPath) {
|
|
636
|
+
switch (node.kind) {
|
|
637
|
+
case "literal":
|
|
638
|
+
return node.value;
|
|
639
|
+
case "path":
|
|
640
|
+
onPath?.(node.path);
|
|
641
|
+
return readPath(node.shape, node.path, context, node.position);
|
|
642
|
+
case "list":
|
|
643
|
+
return node.items.map((item) => evaluateNode(item, context, onPath));
|
|
644
|
+
case "group":
|
|
645
|
+
return evaluateNode(node.inner, context, onPath);
|
|
646
|
+
case "not": {
|
|
647
|
+
const value = evaluateNode(node.operand, context, onPath);
|
|
648
|
+
assertBooleanValue(value, node.position);
|
|
649
|
+
return value === false;
|
|
650
|
+
}
|
|
651
|
+
case "compare":
|
|
652
|
+
return compare(
|
|
653
|
+
node.operator,
|
|
654
|
+
evaluateNode(node.left, context, onPath),
|
|
655
|
+
evaluateNode(node.right, context, onPath),
|
|
656
|
+
node.position
|
|
657
|
+
);
|
|
658
|
+
case "and":
|
|
659
|
+
case "or": {
|
|
660
|
+
const continueOn = node.kind === "and";
|
|
661
|
+
let value = evaluateNode(node.operands[0], context, onPath);
|
|
662
|
+
for (let index = 1; index < node.operands.length; index++) {
|
|
663
|
+
const position = node.positions[index - 1];
|
|
664
|
+
assertBooleanValue(value, position);
|
|
665
|
+
if (value !== continueOn) continue;
|
|
666
|
+
value = evaluateNode(node.operands[index], context, onPath);
|
|
667
|
+
assertBooleanValue(value, position);
|
|
668
|
+
}
|
|
669
|
+
return value;
|
|
670
|
+
}
|
|
671
|
+
}
|
|
672
|
+
}
|
|
673
|
+
var COMPILED_EXPRESSION_LIMIT = 512;
|
|
674
|
+
var compiledExpressions = /* @__PURE__ */ new Map();
|
|
675
|
+
function compileExpression(expression) {
|
|
676
|
+
const cached = compiledExpressions.get(expression);
|
|
677
|
+
if (cached) return cached;
|
|
582
678
|
const tokens = tokenize(expression);
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
tokens
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
679
|
+
let compiled;
|
|
680
|
+
if (expression.trim() === "default") {
|
|
681
|
+
compiled = { references: [], comparisons: [], booleanResult: true };
|
|
682
|
+
} else {
|
|
683
|
+
const root = new ExpressionBuilder(tokens).build();
|
|
684
|
+
const analyzer = new ExpressionAnalyzer();
|
|
685
|
+
const result = analyzer.analyze(root);
|
|
686
|
+
compiled = {
|
|
687
|
+
root,
|
|
688
|
+
references: Array.from(analyzer.references, ([path, booleanOperand]) => ({
|
|
689
|
+
path,
|
|
690
|
+
booleanOperand
|
|
691
|
+
})),
|
|
692
|
+
comparisons: analyzer.comparisons,
|
|
693
|
+
booleanResult: typeof result === "boolean" || result === STATIC_BOOLEAN
|
|
694
|
+
};
|
|
695
|
+
}
|
|
696
|
+
if (compiledExpressions.size >= COMPILED_EXPRESSION_LIMIT) {
|
|
697
|
+
const oldest = compiledExpressions.keys().next();
|
|
698
|
+
if (!oldest.done) compiledExpressions.delete(oldest.value);
|
|
699
|
+
}
|
|
700
|
+
compiledExpressions.set(expression, compiled);
|
|
701
|
+
return compiled;
|
|
702
|
+
}
|
|
703
|
+
function inspectFlowExpressionComparisons(expression) {
|
|
704
|
+
return [...compileExpression(expression).comparisons];
|
|
595
705
|
}
|
|
596
706
|
function inspectFlowExpression(expression, requireBoolean = true) {
|
|
597
|
-
const
|
|
598
|
-
if (
|
|
599
|
-
const references = /* @__PURE__ */ new Map();
|
|
600
|
-
const record2 = (path, booleanOperand) => {
|
|
601
|
-
references.set(path, (references.get(path) ?? false) || booleanOperand);
|
|
602
|
-
};
|
|
603
|
-
const context = { flow: { input: {} }, nodes: {} };
|
|
604
|
-
const result = new Parser(
|
|
605
|
-
tokens,
|
|
606
|
-
context,
|
|
607
|
-
(path) => record2(path, false),
|
|
608
|
-
(path) => record2(path, true)
|
|
609
|
-
).parse(false);
|
|
610
|
-
if (requireBoolean && typeof result !== "boolean" && result !== STATIC_BOOLEAN) {
|
|
707
|
+
const compiled = compileExpression(expression);
|
|
708
|
+
if (requireBoolean && !compiled.booleanResult) {
|
|
611
709
|
throw expressionError("must evaluate to a boolean");
|
|
612
710
|
}
|
|
613
|
-
return
|
|
711
|
+
return [...compiled.references];
|
|
614
712
|
}
|
|
615
713
|
function evaluateFlowExpression(expression, context) {
|
|
616
|
-
const
|
|
617
|
-
if (
|
|
618
|
-
const result =
|
|
714
|
+
const { root } = compileExpression(expression);
|
|
715
|
+
if (root === void 0) return true;
|
|
716
|
+
const result = evaluateNode(root, context);
|
|
619
717
|
if (typeof result !== "boolean") {
|
|
620
718
|
throw expressionError("must evaluate to a boolean");
|
|
621
719
|
}
|
|
@@ -625,16 +723,10 @@ function evaluate(expression, context) {
|
|
|
625
723
|
return evaluateFlowExpression(expression, context);
|
|
626
724
|
}
|
|
627
725
|
function evaluateFlowExpressionValue(expression, context) {
|
|
628
|
-
const
|
|
629
|
-
if (
|
|
726
|
+
const { root } = compileExpression(expression);
|
|
727
|
+
if (root === void 0) return { value: true, paths: [] };
|
|
630
728
|
const paths = [];
|
|
631
|
-
const value =
|
|
632
|
-
tokens,
|
|
633
|
-
context,
|
|
634
|
-
void 0,
|
|
635
|
-
void 0,
|
|
636
|
-
(path) => paths.push(path)
|
|
637
|
-
).parse();
|
|
729
|
+
const value = evaluateNode(root, context, (path) => paths.push(path));
|
|
638
730
|
return { value, paths };
|
|
639
731
|
}
|
|
640
732
|
function originsForPath(path, nodeOutputOrigin, flowInputOrigins) {
|
|
@@ -779,11 +871,6 @@ function resolveFlowBindings(bindings, context, nodeOutputOrigin = {}, flowInput
|
|
|
779
871
|
const values = {};
|
|
780
872
|
const origins = {};
|
|
781
873
|
const entries = Object.entries(bindings ?? {});
|
|
782
|
-
for (const [name] of entries) {
|
|
783
|
-
if (!FLOW_BINDING_NAME_PATTERN.test(name)) {
|
|
784
|
-
throw expressionError(`contains reserved binding name input.${name}`);
|
|
785
|
-
}
|
|
786
|
-
}
|
|
787
874
|
for (const [name, authored] of entries) {
|
|
788
875
|
const resolved = resolveBindingValue(
|
|
789
876
|
authored,
|
|
@@ -912,6 +999,15 @@ var FlowOutputContractSchema = z2.strictObject({
|
|
|
912
999
|
message: `output binding ${name} has no property in output.schema`
|
|
913
1000
|
});
|
|
914
1001
|
}
|
|
1002
|
+
try {
|
|
1003
|
+
compileOutputFieldsSchema(output.schema);
|
|
1004
|
+
} catch (error) {
|
|
1005
|
+
context.addIssue({
|
|
1006
|
+
code: "custom",
|
|
1007
|
+
path: ["schema"],
|
|
1008
|
+
message: `output.schema: ${invalidOutputFieldsSchemaMessage(error)}`
|
|
1009
|
+
});
|
|
1010
|
+
}
|
|
915
1011
|
});
|
|
916
1012
|
var PreconditionSchema = z2.strictObject({
|
|
917
1013
|
expr: nonEmptyString,
|
|
@@ -1448,6 +1544,6 @@ function validateClassifierRules(flow, context) {
|
|
|
1448
1544
|
}
|
|
1449
1545
|
}
|
|
1450
1546
|
|
|
1451
|
-
export { FLOW_CAPTURE_CHANNELS, FLOW_CAPTURE_DESTINATION_PATTERN, FLOW_EXPRESSION_LIMITS, FlowDefinitionSchema, FlowExpressionError, InputSchema, MISSING_FIELD, RESERVED_CLASSIFIER_FIELDS, captureDestinationFieldName, checkClassifierShape, classifierDecision, compileOutputFieldsSchema, consumedOutputFieldPaths, declaredFieldSchema, declaresReservedClassifierField, duplicateCaptureDestinationMessage, evaluate, evaluateFlowExpression, getConsumedOutputSchema, hasConstantlyFalsePrecondition, inspectFlowExpressionComparisons, invalidCaptureDestinationMessage,
|
|
1452
|
-
//# sourceMappingURL=chunk-
|
|
1453
|
-
//# sourceMappingURL=chunk-
|
|
1547
|
+
export { FLOW_CAPTURE_CHANNELS, FLOW_CAPTURE_DESTINATION_PATTERN, FLOW_EXPRESSION_LIMITS, FlowDefinitionSchema, FlowExpressionError, InputSchema, MISSING_FIELD, RESERVED_CLASSIFIER_FIELDS, captureDestinationFieldName, checkClassifierShape, classifierDecision, compileOutputFieldsSchema, consumedOutputFieldPaths, declaredFieldSchema, declaresReservedClassifierField, duplicateCaptureDestinationMessage, evaluate, evaluateFlowExpression, getConsumedOutputSchema, hasConstantlyFalsePrecondition, inspectFlowExpressionComparisons, invalidCaptureDestinationMessage, parseFlowDefinitionStructure, resolveFlowBindings, stableFlowJson, withoutReservedClassifierFields };
|
|
1548
|
+
//# sourceMappingURL=chunk-NUELZWCF.js.map
|
|
1549
|
+
//# sourceMappingURL=chunk-NUELZWCF.js.map
|