nolo-cli 0.108.0-alpha.2 → 0.108.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/README.md +1 -1
- package/{_executeModel-BY3P5LBB.js → _executeModel-RVAKYU4J.js} +128 -83
- package/action-RHUT4OHH.js +23 -0
- package/{addContentAction-MB2HHMDZ.js → addContentAction-BQ3LJLUW.js} +19 -13
- package/{addDialogAgentAction-MCEABSBA.js → addDialogAgentAction-B6X7BXR4.js} +24 -20
- package/{agentDeleteCommand-66KXCSRR.js → agentDeleteCommand-T5MDAOE7.js} +154 -68
- package/{agentEmailCommands-63UTONDK.js → agentEmailCommands-UWBQSKLI.js} +125 -105
- package/{agentGrantCommands-M3XFO6EN.js → agentGrantCommands-HOJ3JBBQ.js} +3 -3
- package/agentListCommands-2Q456VYS.js +800 -0
- package/{agentMachineCommands-Z6RGPZSG.js → agentMachineCommands-FPJJ4DCF.js} +54 -58
- package/{agentProviderCommands-X3UNW77C.js → agentProviderCommands-7PCGR77I.js} +97 -2
- package/{agentPullCommand-O5MPVJ5E.js → agentPullCommand-7GCDM4BK.js} +7 -7
- package/agentRecordCommands-3JGDR4NN.js +149 -0
- package/agentRunCommand-3NQOP3SD.js +179 -0
- package/{agentRunControl-AVJR4JW4.js → agentRunControl-2CDZNHXV.js} +10 -2
- package/{agentRuntimeLocal-E67CTV45.js → agentRuntimeLocal-SQUDRZWE.js} +41 -46
- package/{agentSlice-DG5TIQHE.js → agentSlice-R4W6MCEW.js} +22 -16
- package/{appDeleteCommands-Z36CLGUK.js → appDeleteCommands-CLLYGEBC.js} +55 -56
- package/{appDeployCommands-ECMUWG6S.js → appDeployCommands-HY2NBNDQ.js} +64 -60
- package/{appDeployStatusCommands-CL24TDMA.js → appDeployStatusCommands-SGO5GEXH.js} +53 -53
- package/{appGetCommands-ITHGOYGJ.js → appGetCommands-ZPYK2N5D.js} +53 -53
- package/{appListCommands-EEOSI6RC.js → appListCommands-O2BHIMKS.js} +54 -56
- package/{authCommand-HGP2XTKC.js → authCommand-GUIREPHK.js} +132 -83
- package/{authCommands-RGOGCPP6.js → authCommands-K3BDSTJ4.js} +10 -7
- package/{builtinSkillRegistry-FUAVTRVZ.js → builtinSkillRegistry-MUOUTRNJ.js} +13 -10
- package/{chromeCommands-FZYAU75D.js → chromeCommands-Z2WRJB7O.js} +290 -38
- package/{chromeOpsCommands-62P2Q2YB.js → chromeOpsCommands-YWYXZTIR.js} +157 -23
- package/{chunk-RVE4DCV3.js → chunk-26UZ2Y4Z.js} +26 -31
- package/{chunk-2F7RJC6L.js → chunk-2C47W7IJ.js} +1 -1
- package/{chunk-VLTIYV3X.js → chunk-2ECUZDEL.js} +37 -11
- package/{chunk-ALXHV7NK.js → chunk-2GGXHQIW.js} +43 -4
- package/{chunk-AHAHBQMU.js → chunk-2OMUAIKR.js} +2 -2
- package/{chunk-DHDMC6FO.js → chunk-3CZM6HGQ.js} +53 -23
- package/{chunk-BNGW5ASC.js → chunk-3LI5UCTU.js} +23 -3
- package/{chunk-FDTR4QJ6.js → chunk-3MZAGMYY.js} +48 -1
- package/chunk-3PVYUPXK.js +40 -0
- package/{chunk-FV3JEYR3.js → chunk-3SK3J3IF.js} +69 -10
- package/chunk-4LCOCOR5.js +50 -0
- package/{chunk-V7E4PXQD.js → chunk-4MSYSHZD.js} +15 -7
- package/{chunk-2GRGFCF6.js → chunk-4VJAC32I.js} +2 -1
- package/{chunk-MP64VFGD.js → chunk-4XEYAFLY.js} +60 -18
- package/chunk-4YRTZIVN.js +871 -0
- package/{chunk-MC4XLIJ7.js → chunk-523DITKR.js} +1 -1
- package/{chunk-N7J63Q6C.js → chunk-56GBUMO5.js} +10 -1
- package/chunk-5MMAK75Q.js +15 -0
- package/{chunk-KZJP33ZK.js → chunk-5WLADF62.js} +90 -36
- package/chunk-5XN3OSCT.js +164 -0
- package/chunk-6CCAXGFK.js +1712 -0
- package/{chunk-42V6BK2E.js → chunk-6MXDOUMH.js} +18 -36
- package/{chunk-QOKAKDPE.js → chunk-6Q7UTJKR.js} +6 -94
- package/{chunk-J4MOO56S.js → chunk-6VRWNU5J.js} +10 -2
- package/{chunk-IQPFGYO3.js → chunk-726TCFLQ.js} +5 -5
- package/chunk-7DPNBQSV.js +9 -0
- package/chunk-7YVPCIEN.js +1858 -0
- package/{chunk-LWKP7AWH.js → chunk-A337PRRR.js} +41 -17
- package/chunk-AGIM7IMJ.js +147 -0
- package/{chunk-ABQYVJBJ.js → chunk-AIZE5TDM.js} +3 -3
- package/{chunk-LJ5VW2UJ.js → chunk-ALKCVCA5.js} +4 -4
- package/{chunk-5UTFL4QJ.js → chunk-APO5TOXO.js} +1 -1
- package/{chunk-E4MARS3Q.js → chunk-AU7AXHUL.js} +1 -1
- package/{chunk-PBA4UJBK.js → chunk-BFYDNHYW.js} +12 -12
- package/{chunk-QTGQ2LTL.js → chunk-BIAETTOB.js} +5 -9
- package/{chunk-OIVSQH2O.js → chunk-CGEK73JN.js} +311 -12
- package/chunk-CHOZJMJS.js +78 -0
- package/{chunk-GBRG75BQ.js → chunk-D2MDMY2M.js} +1 -0
- package/chunk-DGDGNYI5.js +593 -0
- package/{chunk-TRV2MIDW.js → chunk-EXAJ6DCR.js} +1 -0
- package/{chunk-YTLRHRH3.js → chunk-EXR4XCFE.js} +17 -15
- package/chunk-EYLGAEB4.js +784 -0
- package/{chunk-3BMYXEUW.js → chunk-F2UJW3EK.js} +1 -1
- package/{chunk-P5EVSOPA.js → chunk-FWY6BHIJ.js} +363 -248
- package/{chunk-4MK3I7Y4.js → chunk-G23MQWLJ.js} +7 -128
- package/chunk-G6OOUQWJ.js +417 -0
- package/{chunk-WV42OMV7.js → chunk-GHZ2H2HJ.js} +11 -15
- package/chunk-I42VC5KR.js +15 -0
- package/{chunk-H4AHY5BU.js → chunk-IFALJPEX.js} +69 -20
- package/{chunk-O6OSWFZQ.js → chunk-IHPDK6UD.js} +6 -0
- package/{chunk-UKWGR5SS.js → chunk-IJERIUXS.js} +242 -1146
- package/chunk-IRG4OKY6.js +843 -0
- package/{chunk-PWBDVI4R.js → chunk-IUTHWIZQ.js} +269 -141
- package/{chunk-QDSINZM3.js → chunk-IXH3HKY2.js} +1 -22
- package/chunk-JJM3WS6W.js +132 -0
- package/{chunk-RZGLXO2B.js → chunk-KN6MKCS5.js} +1715 -451
- package/{chunk-SH43IESU.js → chunk-KQ7DAEZ7.js} +202 -32
- package/{chunk-6OZ36FXI.js → chunk-KY6GPQ7O.js} +36 -12
- package/{chunk-MRIHM22T.js → chunk-LAVSW2C2.js} +77 -144
- package/{chunk-HSSRGGXJ.js → chunk-LNEKN523.js} +10 -7
- package/chunk-LWLNLZC5.js +265 -0
- package/{chunk-I3TQJXQ7.js → chunk-MHD5JBSS.js} +131 -10
- package/{chunk-QU7KDSZX.js → chunk-MW533QT3.js} +190 -8
- package/{chunk-4NNTATRH.js → chunk-NLEJWKF5.js} +10394 -8549
- package/{chunk-BFU6C242.js → chunk-NMFV26UG.js} +1 -1
- package/{chunk-GQBOR3G6.js → chunk-NN4UUYGB.js} +18 -4
- package/{chunk-FZGV4FGK.js → chunk-NUHHBEJC.js} +378 -187
- package/chunk-OKARGYFT.js +15 -0
- package/{chunk-KQHGZWSV.js → chunk-OXME3PEE.js} +1 -1
- package/{chunk-Z5625XML.js → chunk-OYBAT7RT.js} +113 -17
- package/chunk-P3SFAHIL.js +134 -0
- package/{chunk-DOTZ5GTO.js → chunk-P6KLYCL3.js} +310 -95
- package/{chunk-XD2MJFUG.js → chunk-PBGO5AFD.js} +1 -1
- package/{chunk-EYAQT56M.js → chunk-PFEK4SA2.js} +13 -10
- package/{chunk-Z77CRGTW.js → chunk-PHHFVGOJ.js} +1 -1
- package/{chunk-3VNWWVKB.js → chunk-PJNFNEJE.js} +114 -28
- package/{chunk-G4VIHCGJ.js → chunk-PS6XSDHW.js} +35 -30
- package/{chunk-HVURBGF3.js → chunk-PWRS2SU2.js} +27 -9
- package/chunk-QFEW2ULV.js +42 -0
- package/chunk-QH2QSBGP.js +7546 -0
- package/{chunk-IIVGDG4I.js → chunk-QLQ573SU.js} +124 -77
- package/chunk-QQ56R7KS.js +88 -0
- package/chunk-QYPE3TS3.js +43 -0
- package/{chunk-VMFTFOWF.js → chunk-RLRYVSCD.js} +31 -14
- package/{chunk-VRTTFDBM.js → chunk-RNNWTMKT.js} +56 -63
- package/chunk-ROXFUKKL.js +13941 -0
- package/{chunk-SYXOBWOC.js → chunk-RRPT5CGT.js} +124 -703
- package/{chunk-JRQFUXY7.js → chunk-RRQQAG7W.js} +93 -24
- package/chunk-SJ3QFSQS.js +1147 -0
- package/chunk-SP4WCECG.js +95 -0
- package/{chunk-Q67DOFOO.js → chunk-SZC4REES.js} +212 -105
- package/{chunk-BYMV6QZG.js → chunk-TNIX77YM.js} +4 -0
- package/{chunk-GNCCNNZD.js → chunk-TSBCYK5F.js} +7 -7
- package/chunk-TY3TIUJK.js +89 -0
- package/chunk-U4STABYN.js +81 -0
- package/chunk-UEILX4EV.js +15 -0
- package/{chunk-YYLHWIW6.js → chunk-UKZX3NHN.js} +1 -1
- package/{chunk-AODJ7WSF.js → chunk-UPFOOGHU.js} +90 -79
- package/{chunk-7S4YWN7P.js → chunk-V2UPLOXT.js} +4 -4
- package/{chunk-2OASQKU2.js → chunk-V5DCOM6G.js} +185 -16
- package/{chunk-LS2ZANRJ.js → chunk-V6WXGTUJ.js} +1 -1
- package/{chunk-6YTOJY35.js → chunk-VBG7GWWR.js} +253 -8
- package/{chunk-DVINR3PL.js → chunk-VEA7H5FG.js} +3 -3
- package/chunk-VIWDGTDA.js +8 -0
- package/chunk-VJVNU77E.js +83 -0
- package/{chunk-EADNWBAZ.js → chunk-VP3BINY7.js} +13 -0
- package/{chunk-HKNXJGEC.js → chunk-VSPO4S33.js} +47 -192
- package/{chunk-PHXD6JTX.js → chunk-W2N3ZC4P.js} +7 -7
- package/{chunk-EOARMOVD.js → chunk-W4S6OTSC.js} +6 -3
- package/{chunk-6Z7MY3V7.js → chunk-WCQNEMXG.js} +3 -3
- package/chunk-WJZOQR2J.js +151 -0
- package/{chunk-T3GEOSRJ.js → chunk-WVES4PHL.js} +69 -57
- package/{chunk-BFDFRLLQ.js → chunk-WW2USJ3C.js} +3 -3
- package/{chunk-TR22GEUU.js → chunk-X2VPXJZC.js} +20 -11
- package/chunk-X5BIY654.js +29 -0
- package/{chunk-Q554LLSI.js → chunk-XETG4RIX.js} +5 -5
- package/{chunk-3L2WKC3W.js → chunk-XPWGOTBQ.js} +8 -1
- package/{chunk-JEDZAO7L.js → chunk-YBNHPX4S.js} +257 -37
- package/{chunk-JPGCXHNM.js → chunk-YLMMECCH.js} +1 -1
- package/{chunk-CW67PN7L.js → chunk-YSZQSZR2.js} +61 -11
- package/{chunk-6D6VBVEW.js → chunk-YVTZMLXZ.js} +96 -25
- package/{chunk-LPIYPEME.js → chunk-YZZLKXCQ.js} +1449 -1094
- package/chunk-ZRAU6T47.js +56 -0
- package/{chunk-ONXOABJR.js → chunk-ZWQUWF6W.js} +36 -1
- package/{cliExecutor-HG3S345O.js → cliExecutor-AWYR3T33.js} +1 -1
- package/commandRegistry-C25O2ARU.js +839 -0
- package/contentThunks-UWODFKX6.js +83 -0
- package/{cooldownCommands-REAWYVTY.js → cooldownCommands-JFKTYS2D.js} +2 -2
- package/{createAgentAutomationAction-7HX7KBES.js → createAgentAutomationAction-SA4IA4CR.js} +51 -43
- package/createDialogAction-EDK5IMRG.js +75 -0
- package/{createPageAction-QWNMGO3O.js → createPageAction-VYVF5EIZ.js} +60 -51
- package/{chunk-UDIIVXKA.js → cursorProvider-YGGNMVWX.js} +2822 -10269
- package/{dbSlice-A6C6H32X.js → dbSlice-JQFBMJ55.js} +18 -12
- package/{deleteFile-YG6QMJLU.js → deleteFile-6JWDDRVP.js} +9 -5
- package/dialogCommands-K734RXEQ.js +108 -0
- package/{dialogSlice-P2K47T3P.js → dialogSlice-EEDP6PJ3.js} +66 -41
- package/{dist-VODFSGNG.js → dist-NJC2W7I4.js} +61 -54
- package/{docCreateCommands-43JKQEIH.js → docCreateCommands-N3KPGP4A.js} +51 -54
- package/{docDeleteCommands-RL6D46XE.js → docDeleteCommands-4CR4TXZ7.js} +53 -55
- package/{docReadCommands-TOEUEQDG.js → docReadCommands-62XK57VS.js} +50 -53
- package/{docStore-3AHKTJRI.js → docStore-RB7YBD4Y.js} +24 -15
- package/{docUpdateCommands-FWU5G2XB.js → docUpdateCommands-DRAAWIDC.js} +51 -54
- package/{fetchMessages-EIU7UFFK.js → fetchMessages-LM6OMMQQ.js} +5 -4
- package/{getPricing-LUSEABA6.js → getPricing-XDF4OLTC.js} +6 -6
- package/handleSendMessageAction-TYDPIC6O.js +1849 -0
- package/index.js +91 -884
- package/{lib-FRRS27KN.js → lib-PU2G2MSO.js} +523 -191
- package/{localDialogRead-BTFJ4V2I.js → localDialogRead-BOETO2TD.js} +2 -2
- package/localRuntimeAdapter-VYB2QTU3.js +239 -0
- package/{localRuntimeAuthority-6IR6BBXE.js → localRuntimeAuthority-YSE6NH7B.js} +12 -9
- package/{localRuntimeDb-SYQGUF4U.js → localRuntimeDb-7FBKDEQY.js} +1 -1
- package/{machineCommands-TTKK4F7C.js → machineCommands-IQRRLSYP.js} +493 -152
- package/machineWsRunDispatch-LIMM5CYE.js +164 -0
- package/{memberThunks-P2ECUJ56.js → memberThunks-Y3Q7GZTG.js} +24 -17
- package/{models-T3SG6MJ5.js → models-6V4ZCHEE.js} +2 -2
- package/node_modules/abstract-level/CHANGELOG.md +150 -0
- package/node_modules/abstract-level/LICENSE +21 -0
- package/node_modules/abstract-level/README.md +1957 -0
- package/node_modules/abstract-level/UPGRADING.md +669 -0
- package/node_modules/abstract-level/abstract-chained-batch.js +397 -0
- package/node_modules/abstract-level/abstract-iterator.js +404 -0
- package/node_modules/abstract-level/abstract-level.js +1127 -0
- package/node_modules/abstract-level/abstract-snapshot.js +84 -0
- package/node_modules/abstract-level/index.d.ts +52 -0
- package/node_modules/abstract-level/index.js +9 -0
- package/node_modules/abstract-level/lib/abstract-sublevel-iterator.js +141 -0
- package/node_modules/abstract-level/lib/abstract-sublevel.js +290 -0
- package/node_modules/abstract-level/lib/common.js +33 -0
- package/node_modules/abstract-level/lib/default-chained-batch.js +29 -0
- package/node_modules/abstract-level/lib/default-kv-iterator.js +74 -0
- package/node_modules/abstract-level/lib/deferred-iterator.js +110 -0
- package/node_modules/abstract-level/lib/deferred-queue.js +84 -0
- package/node_modules/abstract-level/lib/errors.js +21 -0
- package/node_modules/abstract-level/lib/event-monitor.js +30 -0
- package/node_modules/abstract-level/lib/hooks.js +78 -0
- package/node_modules/abstract-level/lib/prefixes.js +21 -0
- package/node_modules/abstract-level/lib/prewrite-batch.js +96 -0
- package/node_modules/abstract-level/lib/range-options.js +26 -0
- package/node_modules/abstract-level/package.json +66 -0
- package/node_modules/abstract-level/test/async-iterator-test.js +132 -0
- package/node_modules/abstract-level/test/batch-test.js +214 -0
- package/node_modules/abstract-level/test/chained-batch-test.js +315 -0
- package/node_modules/abstract-level/test/clear-range-test.js +262 -0
- package/node_modules/abstract-level/test/clear-test.js +110 -0
- package/node_modules/abstract-level/test/common.js +90 -0
- package/node_modules/abstract-level/test/deferred-open-test.js +209 -0
- package/node_modules/abstract-level/test/del-test.js +65 -0
- package/node_modules/abstract-level/test/encoding-buffer-test.js +336 -0
- package/node_modules/abstract-level/test/encoding-custom-test.js +92 -0
- package/node_modules/abstract-level/test/encoding-decode-error-test.js +85 -0
- package/node_modules/abstract-level/test/encoding-json-test.js +75 -0
- package/node_modules/abstract-level/test/encoding-test.js +130 -0
- package/node_modules/abstract-level/test/events/write.js +132 -0
- package/node_modules/abstract-level/test/factory-test.js +36 -0
- package/node_modules/abstract-level/test/get-many-test.js +157 -0
- package/node_modules/abstract-level/test/get-sync-test.js +61 -0
- package/node_modules/abstract-level/test/get-test.js +83 -0
- package/node_modules/abstract-level/test/has-many-test.js +144 -0
- package/node_modules/abstract-level/test/has-test.js +81 -0
- package/node_modules/abstract-level/test/hooks/newsub.js +57 -0
- package/node_modules/abstract-level/test/hooks/postopen.js +229 -0
- package/node_modules/abstract-level/test/hooks/prewrite.js +816 -0
- package/node_modules/abstract-level/test/hooks/shared.js +38 -0
- package/node_modules/abstract-level/test/index.js +86 -0
- package/node_modules/abstract-level/test/iterator-explicit-snapshot-test.js +393 -0
- package/node_modules/abstract-level/test/iterator-no-snapshot-test.js +49 -0
- package/node_modules/abstract-level/test/iterator-range-test.js +277 -0
- package/node_modules/abstract-level/test/iterator-seek-test.js +335 -0
- package/node_modules/abstract-level/test/iterator-snapshot-test.js +56 -0
- package/node_modules/abstract-level/test/iterator-test.js +621 -0
- package/node_modules/abstract-level/test/manifest-test.js +21 -0
- package/node_modules/abstract-level/test/open-create-if-missing-test.js +39 -0
- package/node_modules/abstract-level/test/open-error-if-exists-test.js +25 -0
- package/node_modules/abstract-level/test/open-test.js +263 -0
- package/node_modules/abstract-level/test/put-get-del-test.js +97 -0
- package/node_modules/abstract-level/test/put-test.js +70 -0
- package/node_modules/abstract-level/test/self/abstract-iterator-test.js +182 -0
- package/node_modules/abstract-level/test/self/async-iterator-test.js +242 -0
- package/node_modules/abstract-level/test/self/attach-resource-test.js +74 -0
- package/node_modules/abstract-level/test/self/defer-test.js +140 -0
- package/node_modules/abstract-level/test/self/deferred-iterator-test.js +314 -0
- package/node_modules/abstract-level/test/self/deferred-operations-test.js +86 -0
- package/node_modules/abstract-level/test/self/deferred-queue-test.js +93 -0
- package/node_modules/abstract-level/test/self/encoding-test.js +391 -0
- package/node_modules/abstract-level/test/self/errors-test.js +11 -0
- package/node_modules/abstract-level/test/self/iterator-test.js +1050 -0
- package/node_modules/abstract-level/test/self/sublevel-test.js +1039 -0
- package/node_modules/abstract-level/test/self.js +905 -0
- package/node_modules/abstract-level/test/sublevel-test.js +209 -0
- package/node_modules/abstract-level/test/traits/closed.js +42 -0
- package/node_modules/abstract-level/test/traits/index.js +4 -0
- package/node_modules/abstract-level/test/traits/open.js +62 -0
- package/node_modules/abstract-level/test/util.js +275 -0
- package/node_modules/abstract-level/types/abstract-chained-batch.d.ts +124 -0
- package/node_modules/abstract-level/types/abstract-iterator.d.ts +241 -0
- package/node_modules/abstract-level/types/abstract-level.d.ts +636 -0
- package/node_modules/abstract-level/types/abstract-snapshot.d.ts +30 -0
- package/node_modules/abstract-level/types/abstract-sublevel.d.ts +76 -0
- package/node_modules/abstract-level/types/interfaces.d.ts +43 -0
- package/node_modules/base64-js/LICENSE +21 -0
- package/node_modules/base64-js/README.md +34 -0
- package/node_modules/base64-js/base64js.min.js +1 -0
- package/node_modules/base64-js/index.d.ts +3 -0
- package/node_modules/base64-js/index.js +150 -0
- package/node_modules/base64-js/package.json +47 -0
- package/node_modules/browser-level/CHANGELOG.md +44 -0
- package/node_modules/browser-level/LICENSE +21 -0
- package/node_modules/browser-level/README.md +124 -0
- package/node_modules/browser-level/UPGRADING.md +143 -0
- package/node_modules/browser-level/index.d.ts +108 -0
- package/node_modules/browser-level/index.js +323 -0
- package/node_modules/browser-level/iterator.js +239 -0
- package/node_modules/browser-level/package.json +48 -0
- package/node_modules/browser-level/util/clear.js +38 -0
- package/node_modules/browser-level/util/deserialize.js +17 -0
- package/node_modules/browser-level/util/key-range.js +20 -0
- package/node_modules/buffer/AUTHORS.md +73 -0
- package/node_modules/buffer/LICENSE +21 -0
- package/node_modules/buffer/README.md +410 -0
- package/node_modules/buffer/index.d.ts +194 -0
- package/node_modules/buffer/index.js +2106 -0
- package/node_modules/buffer/package.json +93 -0
- package/node_modules/classic-level/CHANGELOG.md +115 -0
- package/node_modules/classic-level/LICENSE +21 -0
- package/node_modules/classic-level/README.md +274 -0
- package/node_modules/classic-level/UPGRADING.md +131 -0
- package/node_modules/classic-level/binding.cc +2652 -0
- package/node_modules/classic-level/binding.gyp +71 -0
- package/node_modules/classic-level/binding.js +1 -0
- package/node_modules/classic-level/chained-batch.js +35 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/LICENSE +27 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/Makefile +424 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/build_detect_platform +256 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/autocompact_test.cc +118 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/builder.cc +88 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/builder.h +34 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/c.cc +595 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/c_test.c +390 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/corruption_test.cc +374 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_bench.cc +1020 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_impl.cc +1568 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_impl.h +212 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_iter.cc +317 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_iter.h +28 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/db_test.cc +2158 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/dbformat.cc +140 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/dbformat.h +230 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/dbformat_test.cc +112 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/dumpfile.cc +225 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/fault_injection_test.cc +554 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/filename.cc +144 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/filename.h +85 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/filename_test.cc +123 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/leveldbutil.cc +64 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_format.h +35 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_reader.cc +284 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_reader.h +113 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_test.cc +591 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_writer.cc +112 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/log_writer.h +54 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/memtable.cc +145 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/memtable.h +89 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/recovery_test.cc +324 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/repair.cc +461 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/skiplist.h +384 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/skiplist_test.cc +378 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/snapshot.h +67 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/table_cache.cc +127 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/table_cache.h +61 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_edit.cc +266 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_edit.h +107 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_edit_test.cc +46 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_set.cc +1535 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_set.h +399 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/version_set_test.cc +179 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/write_batch.cc +147 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/write_batch_internal.h +50 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/db/write_batch_test.cc +120 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/helpers/memenv/memenv.cc +398 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/helpers/memenv/memenv.h +20 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/helpers/memenv/memenv_test.cc +241 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/c.h +290 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/cache.h +110 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/comparator.h +63 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/db.h +164 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/dumpfile.h +25 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/env.h +351 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/filter_policy.h +70 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/iterator.h +100 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/options.h +213 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/slice.h +109 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/status.h +112 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/table.h +85 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/table_builder.h +92 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/value_sink.h +26 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/include/leveldb/write_batch.h +64 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/issues/issue178_test.cc +92 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/issues/issue200_test.cc +59 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/atomic_pointer.h +242 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/port.h +21 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/port_example.h +141 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/port_posix.cc +53 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/port_posix.h +156 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/port_posix_sse.cc +129 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/thread_annotations.h +60 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/port/win/stdint.h +24 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/block.cc +268 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/block.h +44 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/block_builder.cc +109 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/block_builder.h +57 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/filter_block.cc +111 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/filter_block.h +68 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/filter_block_test.cc +128 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/format.cc +144 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/format.h +108 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/iterator.cc +67 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/iterator_wrapper.h +66 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/merger.cc +197 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/merger.h +26 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/table.cc +285 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/table_builder.cc +270 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/table_test.cc +876 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/two_level_iterator.cc +182 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/table/two_level_iterator.h +34 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/arena.cc +68 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/arena.h +68 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/arena_test.cc +68 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/bloom.cc +95 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/bloom_test.cc +162 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/cache.cc +405 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/cache_test.cc +226 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/coding.cc +194 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/coding.h +104 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/coding_test.cc +196 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/comparator.cc +81 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/crc32c.cc +350 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/crc32c.h +45 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/crc32c_test.cc +72 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/env.cc +100 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/env_posix.cc +695 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/env_posix_test.cc +66 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/env_posix_test_helper.h +28 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/env_test.cc +106 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/filter_policy.cc +11 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/hash.cc +52 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/hash.h +19 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/hash_test.cc +54 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/histogram.cc +139 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/histogram.h +42 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/logging.cc +72 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/logging.h +43 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/mutexlock.h +41 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/options.cc +30 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/posix_logger.h +98 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/random.h +64 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/status.cc +75 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/testharness.cc +77 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/testharness.h +138 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/testutil.cc +51 -0
- package/node_modules/classic-level/deps/leveldb/leveldb-1.20/util/testutil.h +63 -0
- package/node_modules/classic-level/deps/leveldb/leveldb.gyp +282 -0
- package/node_modules/classic-level/deps/leveldb/patches/001-value-sink.patch +164 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/atomic_pointer_win.h +48 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/env_win.cc +692 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/port_uv.cc +36 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/port_uv.h +157 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/port_uv.h.bak +153 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/stdint-msvc2008.h +247 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/uv_condvar.h +45 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/uv_condvar_posix.cc +139 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/win_logger.cc +79 -0
- package/node_modules/classic-level/deps/leveldb/port-libuv/win_logger.h +28 -0
- package/node_modules/classic-level/deps/snappy/freebsd/config.h +135 -0
- package/node_modules/classic-level/deps/snappy/freebsd/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/deps/snappy/linux/config.h +135 -0
- package/node_modules/classic-level/deps/snappy/linux/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/deps/snappy/mac/config.h +137 -0
- package/node_modules/classic-level/deps/snappy/mac/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/deps/snappy/openbsd/config.h +135 -0
- package/node_modules/classic-level/deps/snappy/openbsd/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/deps/snappy/snappy/COPYING +54 -0
- package/node_modules/classic-level/deps/snappy/snappy/cmake/SnappyConfig.cmake +1 -0
- package/node_modules/classic-level/deps/snappy/snappy/cmake/config.h.in +62 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-c.cc +90 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-c.h +138 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-internal.h +224 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-sinksource.cc +104 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-sinksource.h +182 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-stubs-internal.cc +42 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-stubs-internal.h +561 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-stubs-public.h.in +94 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-test.cc +612 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy-test.h +573 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy.cc +1515 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy.h +203 -0
- package/node_modules/classic-level/deps/snappy/snappy/snappy_unittest.cc +1410 -0
- package/node_modules/classic-level/deps/snappy/snappy.gyp +119 -0
- package/node_modules/classic-level/deps/snappy/solaris/config.h +135 -0
- package/node_modules/classic-level/deps/snappy/solaris/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/deps/snappy/win32/config.h +29 -0
- package/node_modules/classic-level/deps/snappy/win32/snappy-stubs-public.h +100 -0
- package/node_modules/classic-level/index.d.ts +343 -0
- package/node_modules/classic-level/index.js +311 -0
- package/node_modules/classic-level/iterator.js +122 -0
- package/node_modules/classic-level/package.json +70 -0
- package/node_modules/classic-level/prebuilds/android-arm/classic-level.armv7.node +0 -0
- package/node_modules/classic-level/prebuilds/android-arm64/classic-level.armv8.node +0 -0
- package/node_modules/classic-level/prebuilds/darwin-x64+arm64/classic-level.node +0 -0
- package/node_modules/classic-level/prebuilds/linux-arm/classic-level.armv6.node +0 -0
- package/node_modules/classic-level/prebuilds/linux-arm/classic-level.armv7.node +0 -0
- package/node_modules/classic-level/prebuilds/linux-arm64/classic-level.armv8.node +0 -0
- package/node_modules/classic-level/prebuilds/linux-x64/classic-level.musl.node +0 -0
- package/node_modules/classic-level/prebuilds/linux-x64/classic-level.node +0 -0
- package/node_modules/classic-level/prebuilds/win32-ia32/classic-level.node +0 -0
- package/node_modules/classic-level/prebuilds/win32-x64/classic-level.node +0 -0
- package/node_modules/ieee754/LICENSE +11 -0
- package/node_modules/ieee754/README.md +51 -0
- package/node_modules/ieee754/index.d.ts +10 -0
- package/node_modules/ieee754/index.js +85 -0
- package/node_modules/ieee754/package.json +52 -0
- package/node_modules/is-buffer/LICENSE +21 -0
- package/node_modules/is-buffer/README.md +54 -0
- package/node_modules/is-buffer/index.d.ts +2 -0
- package/node_modules/is-buffer/index.js +11 -0
- package/node_modules/is-buffer/package.json +65 -0
- package/node_modules/level/CHANGELOG.md +532 -0
- package/node_modules/level/LICENSE +21 -0
- package/node_modules/level/README.md +107 -0
- package/node_modules/level/UPGRADING.md +413 -0
- package/node_modules/level/browser.js +1 -0
- package/node_modules/level/index.d.ts +75 -0
- package/node_modules/level/index.js +1 -0
- package/node_modules/level/package.json +62 -0
- package/node_modules/level-supports/CHANGELOG.md +140 -0
- package/node_modules/level-supports/LICENSE +21 -0
- package/node_modules/level-supports/README.md +276 -0
- package/node_modules/level-supports/index.d.ts +137 -0
- package/node_modules/level-supports/index.js +26 -0
- package/node_modules/level-supports/package.json +46 -0
- package/node_modules/level-supports/test/cloneable.js +26 -0
- package/node_modules/level-supports/test/index.js +24 -0
- package/node_modules/level-supports/test/self.js +86 -0
- package/node_modules/level-supports/test/shape.js +23 -0
- package/node_modules/level-transcoder/CHANGELOG.md +15 -0
- package/node_modules/level-transcoder/LICENSE +21 -0
- package/node_modules/level-transcoder/README.md +214 -0
- package/node_modules/level-transcoder/UPGRADING.md +13 -0
- package/node_modules/level-transcoder/index.d.ts +27 -0
- package/node_modules/level-transcoder/index.js +158 -0
- package/node_modules/level-transcoder/lib/encoding.d.ts +158 -0
- package/node_modules/level-transcoder/lib/encoding.js +105 -0
- package/node_modules/level-transcoder/lib/encodings.d.ts +9 -0
- package/node_modules/level-transcoder/lib/encodings.js +135 -0
- package/node_modules/level-transcoder/lib/formats.d.ts +13 -0
- package/node_modules/level-transcoder/lib/formats.js +111 -0
- package/node_modules/level-transcoder/lib/text-endec.d.ts +6 -0
- package/node_modules/level-transcoder/lib/text-endec.js +19 -0
- package/node_modules/level-transcoder/package.json +46 -0
- package/node_modules/maybe-combine-errors/LICENSE.md +21 -0
- package/node_modules/maybe-combine-errors/README.md +94 -0
- package/node_modules/maybe-combine-errors/index.js +60 -0
- package/node_modules/maybe-combine-errors/package.json +33 -0
- package/node_modules/module-error/CHANGELOG.md +23 -0
- package/node_modules/module-error/LICENSE +21 -0
- package/node_modules/module-error/README.md +89 -0
- package/node_modules/module-error/index.d.ts +18 -0
- package/node_modules/module-error/index.js +22 -0
- package/node_modules/module-error/package.json +36 -0
- package/node_modules/napi-macros/LICENSE +21 -0
- package/node_modules/napi-macros/README.md +277 -0
- package/node_modules/napi-macros/index.js +1 -0
- package/node_modules/napi-macros/napi-macros.h +255 -0
- package/node_modules/napi-macros/package.json +22 -0
- package/node_modules/node-gyp-build/LICENSE +21 -0
- package/node_modules/node-gyp-build/README.md +58 -0
- package/node_modules/node-gyp-build/SECURITY.md +5 -0
- package/node_modules/node-gyp-build/bin.js +84 -0
- package/node_modules/node-gyp-build/build-test.js +19 -0
- package/node_modules/node-gyp-build/index.js +6 -0
- package/node_modules/node-gyp-build/node-gyp-build.js +207 -0
- package/node_modules/node-gyp-build/optional.js +7 -0
- package/node_modules/node-gyp-build/package.json +43 -0
- package/oauthTokenStore-PADKLNOC.js +23 -0
- package/package.json +6 -3
- package/processSpawn-SOAV3FEV.js +11 -0
- package/profileConfig-ZGOFORWV.js +43 -0
- package/{providerPresetApply-XI3WUPTI.js → providerPresetApply-HIPK67DU.js} +9 -9
- package/{providerRegistry-KEPWWGXD.js → providerRegistry-AI4U2FNM.js} +13 -9
- package/{read-COE3ZYR6.js → read-RNUQ7F34.js} +11 -7
- package/{readDocTool-5USN4A6V.js → readDocTool-6WIZHE6O.js} +5 -3
- package/{readlineWorkspace-KIMUDPPV.js → readlineWorkspace-P3I7ZJUP.js} +6947 -3879
- package/{removeDialogAgentAction-J6X5QMTA.js → removeDialogAgentAction-EFQ4O2IQ.js} +27 -26
- package/{runAgentClientLoop-AN4WIRPQ.js → runAgentClientLoop-AYNL3KMJ.js} +150 -90
- package/{runtimeDoctorCommands-X6WDBEQX.js → runtimeDoctorCommands-5CIWJEZ3.js} +36 -8
- package/runtimeModeArgs-2Y7BALTO.js +31 -0
- package/setDialogExtraReferencesAction-MXAH2KPV.js +37 -0
- package/{setPrimaryDialogAgentAction-FN22THHT.js → setPrimaryDialogAgentAction-7OPVNK4M.js} +28 -27
- package/{chunk-GP5LKBUZ.js → settingThunks-GHVLHABJ.js} +240 -945
- package/{skillDiscovery-CYUCJMAG.js → skillDiscovery-QC35EQY4.js} +3 -3
- package/{slateUtils-RIZES3PV.js → slateUtils-NGV2NMKM.js} +1 -1
- package/{spaceCommands-NA4JMIGT.js → spaceCommands-WZCLRGBO.js} +56 -56
- package/{streamAgentChatTurn-3TYTHZPJ.js → streamAgentChatTurn-O5T3B4B3.js} +325 -1557
- package/{switchDialogAgentAction-LVTEV3FR.js → switchDialogAgentAction-4PANDG3L.js} +24 -20
- package/{tableCommands-O6NWHFKV.js → tableCommands-U3QDY4L6.js} +19 -17
- package/{toolApiClient-QVJ6HDNN.js → toolApiClient-54CXTU7C.js} +5 -4
- package/tools-UMU2DYQX.js +122 -0
- package/{tuiSummaryLlmCaller-UFGFOIIW.js → tuiSummaryLlmCaller-ISODIW2O.js} +14 -29
- package/{updateCommands-2M74UL7P.js → updateCommands-NQXAGFM7.js} +3 -3
- package/{updateDialogTitleAction-RDHNT265.js → updateDialogTitleAction-TIS2SETN.js} +101 -57
- package/action-P4TNFGAD.js +0 -31
- package/agentListCommands-NXCOTTZL.js +0 -411
- package/agentRecordCommands-JP54ZWND.js +0 -129
- package/agentRunCommand-RMQWWSHF.js +0 -157
- package/browser-image-compression-MFDTD7K6.js +0 -1763
- package/chatQueueReduxAdapter-DKLWTT3G.js +0 -186
- package/chunk-ACTMNVHM.js +0 -93
- package/chunk-CQ3WA2NE.js +0 -299
- package/chunk-M76ECQRD.js +0 -13658
- package/chunk-MEYIRKDN.js +0 -8967
- package/chunk-N4G4PKQ6.js +0 -23
- package/chunk-P3GYTNDF.js +0 -34
- package/chunk-PUOC4YRO.js +0 -394
- package/chunk-S7Z2HMCN.js +0 -25
- package/chunk-Y5GCAMGP.js +0 -9
- package/chunk-YPREESF4.js +0 -225
- package/chunk-YWIEQS6H.js +0 -21409
- package/contentThunks-JHK6X2KU.js +0 -73
- package/createDialogAction-VUUUZL54.js +0 -65
- package/dialogCommands-EN7TYD3I.js +0 -100
- package/handleSendMessageAction-ID5IKXUE.js +0 -633
- package/machineWsRunDispatch-RX64L3ET.js +0 -145
- package/setDialogExtraReferencesAction-WX5VTY6O.js +0 -30
- package/settingSlice-P4ZW7K5X.js +0 -204
- package/syncMapping-N6RGXGBW.js +0 -437
- package/tools-34SEJSLQ.js +0 -110
- package/{chunk-SV5IJK6K.js → chunk-NBTY7YJF.js} +3 -3
- package/{chunk-X7HHHIOZ.js → chunk-Y6ROFCZO.js} +0 -0
- package/{db-WK5MDZVN.js → db-VQSAOWAO.js} +1 -1
- package/{offlineMarxistsAgentCommand-HGXZV4XJ.js → offlineMarxistsAgentCommand-2QTHJCHV.js} +4 -4
|
@@ -2,150 +2,173 @@ import {
|
|
|
2
2
|
buildMachinePermissionPromptBlock,
|
|
3
3
|
handleConnectorRunMessage,
|
|
4
4
|
resolveMachineRunPermissionPolicy
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-PS6XSDHW.js";
|
|
6
6
|
import {
|
|
7
|
+
MAX_CONNECTOR_TIMER_DELAY_MS,
|
|
8
|
+
clampConnectorTimerDelayMs,
|
|
7
9
|
isConnectorWebSocketAuthError,
|
|
8
10
|
isConnectorWebSocketRetryableError,
|
|
11
|
+
resolveConnectorProbeTimeoutMs,
|
|
9
12
|
resolveConnectorWebSocketTarget
|
|
10
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-2GGXHQIW.js";
|
|
11
14
|
import {
|
|
12
15
|
detectMachineInfo
|
|
13
16
|
} from "./chunk-ESHYE7WU.js";
|
|
14
|
-
import "./chunk-
|
|
15
|
-
import "./chunk-
|
|
16
|
-
import "./chunk-
|
|
17
|
-
import "./chunk-
|
|
18
|
-
import "./chunk-
|
|
19
|
-
import "./chunk-
|
|
20
|
-
import "./chunk-
|
|
21
|
-
import "./chunk-
|
|
22
|
-
import "./chunk-
|
|
17
|
+
import "./chunk-QH2QSBGP.js";
|
|
18
|
+
import "./chunk-OYBAT7RT.js";
|
|
19
|
+
import "./chunk-KQ7DAEZ7.js";
|
|
20
|
+
import "./chunk-6MXDOUMH.js";
|
|
21
|
+
import "./chunk-6CCAXGFK.js";
|
|
22
|
+
import "./chunk-VP3BINY7.js";
|
|
23
|
+
import "./chunk-PHHFVGOJ.js";
|
|
24
|
+
import "./chunk-NBTY7YJF.js";
|
|
25
|
+
import "./chunk-4XEYAFLY.js";
|
|
23
26
|
import "./chunk-JBTJAPUF.js";
|
|
24
|
-
import "./chunk-
|
|
27
|
+
import "./chunk-VIWDGTDA.js";
|
|
25
28
|
import "./chunk-ATNTHIZI.js";
|
|
26
|
-
import "./chunk-
|
|
29
|
+
import "./chunk-PBGO5AFD.js";
|
|
30
|
+
import "./chunk-WVES4PHL.js";
|
|
27
31
|
import "./chunk-HS7MLR74.js";
|
|
28
|
-
import "./chunk-
|
|
29
|
-
import "./chunk-
|
|
32
|
+
import "./chunk-YZZLKXCQ.js";
|
|
33
|
+
import "./chunk-V5DCOM6G.js";
|
|
34
|
+
import "./chunk-APO5TOXO.js";
|
|
35
|
+
import "./chunk-OXME3PEE.js";
|
|
36
|
+
import "./chunk-WCQNEMXG.js";
|
|
37
|
+
import "./chunk-DGDGNYI5.js";
|
|
30
38
|
import "./chunk-NF64D32W.js";
|
|
31
39
|
import {
|
|
32
|
-
CORE_DRAIN_REASON
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
import "./chunk-
|
|
36
|
-
import "./chunk-
|
|
37
|
-
import "./chunk-
|
|
38
|
-
import "./chunk-
|
|
39
|
-
import "./chunk-
|
|
40
|
+
CORE_DRAIN_REASON,
|
|
41
|
+
parsePositiveFiniteNumberOrFallback
|
|
42
|
+
} from "./chunk-XPWGOTBQ.js";
|
|
43
|
+
import "./chunk-5XN3OSCT.js";
|
|
44
|
+
import "./chunk-2ECUZDEL.js";
|
|
45
|
+
import "./chunk-BIAETTOB.js";
|
|
46
|
+
import "./chunk-6VRWNU5J.js";
|
|
47
|
+
import "./chunk-PFEK4SA2.js";
|
|
40
48
|
import "./chunk-VIDPVFP3.js";
|
|
41
|
-
import "./chunk-
|
|
42
|
-
import "./chunk-
|
|
43
|
-
import "./chunk-N4G4PKQ6.js";
|
|
44
|
-
import "./chunk-FZGV4FGK.js";
|
|
45
|
-
import "./chunk-MEYIRKDN.js";
|
|
49
|
+
import "./chunk-NUHHBEJC.js";
|
|
50
|
+
import "./chunk-AGIM7IMJ.js";
|
|
46
51
|
import "./chunk-63W5N6P3.js";
|
|
47
52
|
import "./chunk-VF4K2QE6.js";
|
|
48
|
-
import "./chunk-
|
|
49
|
-
import "./chunk-
|
|
50
|
-
import "./chunk-
|
|
53
|
+
import "./chunk-X2VPXJZC.js";
|
|
54
|
+
import "./chunk-26UZ2Y4Z.js";
|
|
55
|
+
import "./chunk-BFYDNHYW.js";
|
|
56
|
+
import "./chunk-P6KLYCL3.js";
|
|
51
57
|
import "./chunk-ZJ7UHBJS.js";
|
|
52
|
-
import "./chunk-
|
|
53
|
-
import "./chunk-
|
|
54
|
-
import "./chunk-
|
|
55
|
-
import "./chunk-
|
|
58
|
+
import "./chunk-ROXFUKKL.js";
|
|
59
|
+
import "./chunk-523DITKR.js";
|
|
60
|
+
import "./chunk-UKZX3NHN.js";
|
|
61
|
+
import "./chunk-F2UJW3EK.js";
|
|
62
|
+
import "./chunk-BYXBJQAS.js";
|
|
63
|
+
import "./chunk-QYPE3TS3.js";
|
|
64
|
+
import "./chunk-EXR4XCFE.js";
|
|
56
65
|
import "./chunk-AGGIDPCZ.js";
|
|
57
|
-
import "./chunk-
|
|
58
|
-
import "./chunk-BFDFRLLQ.js";
|
|
66
|
+
import "./chunk-WW2USJ3C.js";
|
|
59
67
|
import "./chunk-5RGU3J7P.js";
|
|
60
|
-
import "./chunk-
|
|
61
|
-
import "./chunk-
|
|
68
|
+
import "./chunk-VBG7GWWR.js";
|
|
69
|
+
import "./chunk-ZRAU6T47.js";
|
|
70
|
+
import "./chunk-4LCOCOR5.js";
|
|
62
71
|
import "./chunk-YDH3FDFQ.js";
|
|
63
|
-
import "./chunk-
|
|
64
|
-
import "./chunk-
|
|
65
|
-
import "./chunk-
|
|
66
|
-
import "./chunk-
|
|
67
|
-
import "./chunk-
|
|
68
|
-
import "./chunk-
|
|
72
|
+
import "./chunk-QFEW2ULV.js";
|
|
73
|
+
import "./chunk-V2UPLOXT.js";
|
|
74
|
+
import "./chunk-2OMUAIKR.js";
|
|
75
|
+
import "./chunk-UAD2WT54.js";
|
|
76
|
+
import "./chunk-RNNWTMKT.js";
|
|
77
|
+
import "./chunk-3PVYUPXK.js";
|
|
78
|
+
import "./chunk-GHZ2H2HJ.js";
|
|
79
|
+
import "./chunk-AIZE5TDM.js";
|
|
80
|
+
import "./chunk-4YRTZIVN.js";
|
|
81
|
+
import "./chunk-UEILX4EV.js";
|
|
82
|
+
import "./chunk-IJERIUXS.js";
|
|
83
|
+
import "./chunk-6Q7UTJKR.js";
|
|
84
|
+
import "./chunk-QQ56R7KS.js";
|
|
85
|
+
import "./chunk-OW765XBU.js";
|
|
86
|
+
import "./chunk-SEJ5OS6F.js";
|
|
87
|
+
import "./chunk-D2MDMY2M.js";
|
|
88
|
+
import "./chunk-RRQQAG7W.js";
|
|
89
|
+
import "./chunk-3CZM6HGQ.js";
|
|
90
|
+
import "./chunk-IXH3HKY2.js";
|
|
91
|
+
import "./chunk-XETG4RIX.js";
|
|
92
|
+
import "./chunk-OKARGYFT.js";
|
|
69
93
|
import {
|
|
94
|
+
NEW_TEXT_FIELD_ALIASES,
|
|
70
95
|
PATH_FIELD_ALIASES,
|
|
71
|
-
createLocalWorkspaceToolExecutors
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
import "./chunk-
|
|
75
|
-
import "./chunk-GMZLP5DV.js";
|
|
96
|
+
createLocalWorkspaceToolExecutors,
|
|
97
|
+
resolveRequestedWorkspacePath
|
|
98
|
+
} from "./chunk-NLEJWKF5.js";
|
|
99
|
+
import "./chunk-3SK3J3IF.js";
|
|
76
100
|
import "./chunk-ZNFJWEN4.js";
|
|
77
|
-
import "./chunk-
|
|
78
|
-
import "./chunk-
|
|
101
|
+
import "./chunk-IFALJPEX.js";
|
|
102
|
+
import "./chunk-GMZLP5DV.js";
|
|
103
|
+
import "./chunk-CHOZJMJS.js";
|
|
104
|
+
import "./chunk-G23MQWLJ.js";
|
|
79
105
|
import "./chunk-5ZUL4CUO.js";
|
|
80
|
-
import "./chunk-
|
|
81
|
-
import "./chunk-
|
|
82
|
-
import "./chunk-
|
|
83
|
-
import "./chunk-
|
|
84
|
-
import "./chunk-
|
|
85
|
-
import "./chunk-
|
|
86
|
-
import "./chunk-
|
|
106
|
+
import "./chunk-JJM3WS6W.js";
|
|
107
|
+
import "./chunk-G6OOUQWJ.js";
|
|
108
|
+
import "./chunk-56GBUMO5.js";
|
|
109
|
+
import "./chunk-WJZOQR2J.js";
|
|
110
|
+
import "./chunk-LAVSW2C2.js";
|
|
111
|
+
import "./chunk-SJ3QFSQS.js";
|
|
112
|
+
import "./chunk-QLQ573SU.js";
|
|
113
|
+
import "./chunk-3MZAGMYY.js";
|
|
87
114
|
import "./chunk-2MBTWINN.js";
|
|
88
|
-
import "./chunk-
|
|
89
|
-
import "./chunk-
|
|
90
|
-
import "./chunk-
|
|
91
|
-
import "./chunk-GQBOR3G6.js";
|
|
92
|
-
import "./chunk-BYXBJQAS.js";
|
|
93
|
-
import "./chunk-OIVSQH2O.js";
|
|
115
|
+
import "./chunk-VSPO4S33.js";
|
|
116
|
+
import "./chunk-FWY6BHIJ.js";
|
|
117
|
+
import "./chunk-5MMAK75Q.js";
|
|
94
118
|
import "./chunk-DWLEOOGR.js";
|
|
95
|
-
import "./chunk-
|
|
96
|
-
import "./chunk-
|
|
119
|
+
import "./chunk-PWRS2SU2.js";
|
|
120
|
+
import "./chunk-KX6YBIHG.js";
|
|
121
|
+
import "./chunk-7DPNBQSV.js";
|
|
122
|
+
import "./chunk-IHPDK6UD.js";
|
|
123
|
+
import "./chunk-LWLNLZC5.js";
|
|
124
|
+
import "./chunk-3LI5UCTU.js";
|
|
125
|
+
import "./chunk-M2EJHDJP.js";
|
|
126
|
+
import "./chunk-RLRYVSCD.js";
|
|
127
|
+
import "./chunk-I42VC5KR.js";
|
|
128
|
+
import "./chunk-U6VC4MU4.js";
|
|
129
|
+
import "./chunk-MW533QT3.js";
|
|
130
|
+
import "./chunk-TSBCYK5F.js";
|
|
131
|
+
import "./chunk-WWC7I6TA.js";
|
|
132
|
+
import "./chunk-MHD5JBSS.js";
|
|
133
|
+
import "./chunk-PJNFNEJE.js";
|
|
134
|
+
import "./chunk-PSCNXBYA.js";
|
|
135
|
+
import "./chunk-KY6GPQ7O.js";
|
|
136
|
+
import "./chunk-NN4UUYGB.js";
|
|
137
|
+
import "./chunk-CGEK73JN.js";
|
|
97
138
|
import "./chunk-W7XHHYWM.js";
|
|
139
|
+
import {
|
|
140
|
+
isRecord
|
|
141
|
+
} from "./chunk-KUG52IAP.js";
|
|
142
|
+
import {
|
|
143
|
+
asTrimmedString
|
|
144
|
+
} from "./chunk-3EUW3WEO.js";
|
|
98
145
|
import {
|
|
99
146
|
toErrorMessage
|
|
100
147
|
} from "./chunk-HNMXYYJR.js";
|
|
101
|
-
import "./chunk-
|
|
102
|
-
import "./chunk-
|
|
103
|
-
import "./chunk-
|
|
104
|
-
import "./chunk-7S4YWN7P.js";
|
|
105
|
-
import "./chunk-X7HHHIOZ.js";
|
|
148
|
+
import "./chunk-2C47W7IJ.js";
|
|
149
|
+
import "./chunk-GLKOYSRU.js";
|
|
150
|
+
import "./chunk-EYLGAEB4.js";
|
|
106
151
|
import {
|
|
107
152
|
isCompiledBinary
|
|
108
153
|
} from "./chunk-A7GB5UGH.js";
|
|
109
154
|
import {
|
|
110
155
|
DEFAULT_NOLO_SERVER_URL
|
|
111
156
|
} from "./chunk-OLZBQWZU.js";
|
|
112
|
-
import "./chunk-ACTMNVHM.js";
|
|
113
|
-
import "./chunk-Q67DOFOO.js";
|
|
114
|
-
import "./chunk-PBA4UJBK.js";
|
|
115
|
-
import "./chunk-GP5LKBUZ.js";
|
|
116
|
-
import {
|
|
117
|
-
parsePositiveFiniteNumberOrFallback
|
|
118
|
-
} from "./chunk-Y5GCAMGP.js";
|
|
119
|
-
import "./chunk-QDSINZM3.js";
|
|
120
|
-
import "./chunk-KX6YBIHG.js";
|
|
121
|
-
import "./chunk-AHAHBQMU.js";
|
|
122
|
-
import "./chunk-UAD2WT54.js";
|
|
123
|
-
import "./chunk-VRTTFDBM.js";
|
|
124
|
-
import "./chunk-VMFTFOWF.js";
|
|
125
|
-
import "./chunk-WWC7I6TA.js";
|
|
126
|
-
import "./chunk-ABQYVJBJ.js";
|
|
127
|
-
import "./chunk-QSJ3HFEF.js";
|
|
128
|
-
import "./chunk-WV42OMV7.js";
|
|
129
|
-
import "./chunk-BNGW5ASC.js";
|
|
130
|
-
import "./chunk-M2EJHDJP.js";
|
|
131
|
-
import "./chunk-UKWGR5SS.js";
|
|
132
|
-
import "./chunk-QOKAKDPE.js";
|
|
133
|
-
import "./chunk-OW765XBU.js";
|
|
134
|
-
import "./chunk-SEJ5OS6F.js";
|
|
135
|
-
import "./chunk-GBRG75BQ.js";
|
|
136
|
-
import {
|
|
137
|
-
isRecord
|
|
138
|
-
} from "./chunk-KUG52IAP.js";
|
|
139
|
-
import {
|
|
140
|
-
asTrimmedString
|
|
141
|
-
} from "./chunk-3EUW3WEO.js";
|
|
142
|
-
import "./chunk-U6VC4MU4.js";
|
|
143
157
|
import "./chunk-LCBAMY2M.js";
|
|
144
158
|
import "./chunk-4SN6J65J.js";
|
|
145
159
|
import {
|
|
146
160
|
normalizeServerOrigin
|
|
147
161
|
} from "./chunk-CF7PE763.js";
|
|
148
162
|
import "./chunk-G3SUCT4W.js";
|
|
163
|
+
import "./chunk-TNIX77YM.js";
|
|
164
|
+
import "./chunk-Y6ROFCZO.js";
|
|
165
|
+
import "./chunk-P3SFAHIL.js";
|
|
166
|
+
import "./chunk-SZC4REES.js";
|
|
167
|
+
import "./chunk-QSJ3HFEF.js";
|
|
168
|
+
import "./chunk-ZWQUWF6W.js";
|
|
169
|
+
import "./chunk-KHCLMKZZ.js";
|
|
170
|
+
import "./chunk-VEA7H5FG.js";
|
|
171
|
+
import "./chunk-4VJAC32I.js";
|
|
149
172
|
import "./chunk-4VNS5WPM.js";
|
|
150
173
|
|
|
151
174
|
// packages/connector-experimental/heartbeatLoop.ts
|
|
@@ -367,16 +390,104 @@ async function runMachineWatchCommand(deps) {
|
|
|
367
390
|
}
|
|
368
391
|
|
|
369
392
|
// packages/cli/machineToolInvokeDispatch.ts
|
|
370
|
-
import { lstat, realpath } from "node:fs/promises";
|
|
371
|
-
import {
|
|
372
|
-
|
|
393
|
+
import { appendFile, lstat, mkdir, realpath, stat } from "node:fs/promises";
|
|
394
|
+
import { homedir as homedir2 } from "node:os";
|
|
395
|
+
import { dirname as dirname2, isAbsolute as isAbsolute2, join as join2, relative as relative2, resolve as resolve2, sep } from "node:path";
|
|
396
|
+
|
|
397
|
+
// packages/agent-runtime/machineToolGrants.ts
|
|
398
|
+
function isRecord2(value) {
|
|
399
|
+
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
400
|
+
}
|
|
401
|
+
function normalizeMachineToolGrants(raw) {
|
|
402
|
+
if (!isRecord2(raw)) return void 0;
|
|
403
|
+
const grants = {};
|
|
404
|
+
for (const [rawKey, rawEntry] of Object.entries(raw)) {
|
|
405
|
+
const agentKey = rawKey.trim();
|
|
406
|
+
if (!agentKey) continue;
|
|
407
|
+
if (!isRecord2(rawEntry)) continue;
|
|
408
|
+
if (typeof rawEntry.write !== "boolean") continue;
|
|
409
|
+
grants[agentKey] = { write: rawEntry.write };
|
|
410
|
+
}
|
|
411
|
+
return Object.keys(grants).length > 0 ? grants : void 0;
|
|
412
|
+
}
|
|
413
|
+
|
|
414
|
+
// packages/cli/machineToolInvokeDispatch.ts
|
|
415
|
+
var MACHINE_TOOL_INVOKE_V1_READ_ONLY_TOOL_NAMES = ["readFile", "globFiles"];
|
|
416
|
+
var READ_ONLY_TOOL_NAME_SET = new Set(MACHINE_TOOL_INVOKE_V1_READ_ONLY_TOOL_NAMES);
|
|
417
|
+
var MACHINE_TOOL_INVOKE_V1_TOOL_NAMES = [
|
|
418
|
+
"readFile",
|
|
419
|
+
"globFiles",
|
|
420
|
+
"writeFile",
|
|
421
|
+
"editFile"
|
|
422
|
+
];
|
|
373
423
|
var V1_ALLOWED_TOOL_NAMES = new Set(MACHINE_TOOL_INVOKE_V1_TOOL_NAMES);
|
|
374
424
|
var DEFAULT_TOOL_INVOKE_TIMEOUT_MS = 3e4;
|
|
375
425
|
var TOOL_RESULT_MESSAGE_MAX_CHARS = 1e6;
|
|
376
|
-
var TOOL_NOT_ALLOWED_MESSAGE = "tool not allowed in v1 (read
|
|
426
|
+
var TOOL_NOT_ALLOWED_MESSAGE = "tool not allowed in v1 (allowlisted read/write file tools only)";
|
|
377
427
|
var TOOL_PAYLOAD_MALFORMED_MESSAGE = "malformed tool.invoke payload (payload object required)";
|
|
378
428
|
var TOOL_ARGS_MALFORMED_MESSAGE = "malformed tool.invoke args (args object required)";
|
|
429
|
+
var GRANT_DIMENSION_BY_TOOL = {
|
|
430
|
+
writeFile: "write",
|
|
431
|
+
editFile: "write"
|
|
432
|
+
};
|
|
433
|
+
var MACHINE_TOOL_INVOKE_V1_WRITE_TOOL_NAMES = Object.keys(GRANT_DIMENSION_BY_TOOL);
|
|
434
|
+
function grantDimensionForTool(toolName) {
|
|
435
|
+
return Object.hasOwn(GRANT_DIMENSION_BY_TOOL, toolName) ? GRANT_DIMENSION_BY_TOOL[toolName] : void 0;
|
|
436
|
+
}
|
|
437
|
+
var AUDIT_TARGET_MAX_CHARS = 200;
|
|
438
|
+
function machineToolNotGrantedMessage(toolName, agentKey) {
|
|
439
|
+
const dimension = grantDimensionForTool(toolName);
|
|
440
|
+
if (!dimension) {
|
|
441
|
+
return `tool not granted on this machine: ${toolName} is not a registered machine tool (no grant dimension) (NOLO_MACHINE_TOOL_GRANTS)`;
|
|
442
|
+
}
|
|
443
|
+
return agentKey ? `tool not granted on this machine: ${toolName} requires ${dimension} grant for agent ${agentKey} (NOLO_MACHINE_TOOL_GRANTS)` : `tool not granted on this machine: ${toolName} requires an agentKey with ${dimension} grant (NOLO_MACHINE_TOOL_GRANTS)`;
|
|
444
|
+
}
|
|
445
|
+
function isMachineToolGranted(grants, toolName, agentKey) {
|
|
446
|
+
if (READ_ONLY_TOOL_NAME_SET.has(toolName)) return true;
|
|
447
|
+
const dimension = grantDimensionForTool(toolName);
|
|
448
|
+
if (!dimension) return false;
|
|
449
|
+
const normalizedAgentKey = typeof agentKey === "string" ? agentKey.trim() : "";
|
|
450
|
+
if (!normalizedAgentKey || !grants) return false;
|
|
451
|
+
if (!Object.prototype.hasOwnProperty.call(grants, normalizedAgentKey)) return false;
|
|
452
|
+
const entry = grants[normalizedAgentKey];
|
|
453
|
+
if (!isRecord3(entry)) return false;
|
|
454
|
+
return Object.hasOwn(entry, dimension) && entry[dimension] === true;
|
|
455
|
+
}
|
|
456
|
+
function resolveMachineToolAuditLogPath() {
|
|
457
|
+
const noloHome = process.env.NOLO_HOME?.trim();
|
|
458
|
+
const base = noloHome ? noloHome : join2(homedir2(), ".nolo");
|
|
459
|
+
return join2(base, "logs", "machine-tool-audit.jsonl");
|
|
460
|
+
}
|
|
461
|
+
function auditTargetFor(executorArgs) {
|
|
462
|
+
const target = extractMachineToolRequestPath(executorArgs) ?? "";
|
|
463
|
+
return target.length > AUDIT_TARGET_MAX_CHARS ? target.slice(0, AUDIT_TARGET_MAX_CHARS) : target;
|
|
464
|
+
}
|
|
465
|
+
function machineToolOutcomeFailed(outcome) {
|
|
466
|
+
const metadata = outcome.metadata;
|
|
467
|
+
if (!isRecord3(metadata)) return false;
|
|
468
|
+
if (metadata.timedOut === true) return true;
|
|
469
|
+
if (metadata.aborted === true) return true;
|
|
470
|
+
const exitCode = metadata.exitCode;
|
|
471
|
+
return typeof exitCode === "number" && exitCode !== 0;
|
|
472
|
+
}
|
|
473
|
+
async function appendMachineToolAudit(entry) {
|
|
474
|
+
try {
|
|
475
|
+
const logPath = resolveMachineToolAuditLogPath();
|
|
476
|
+
await mkdir(dirname2(logPath), { recursive: true });
|
|
477
|
+
await appendFile(
|
|
478
|
+
logPath,
|
|
479
|
+
`${JSON.stringify({ ts: (/* @__PURE__ */ new Date()).toISOString(), agentKey: entry.agentKey ?? null, tool: entry.tool, target: entry.target, ok: entry.ok })}
|
|
480
|
+
`,
|
|
481
|
+
"utf8"
|
|
482
|
+
);
|
|
483
|
+
} catch (error) {
|
|
484
|
+
console.warn(`[nolo] machine tool audit write failed: ${toMessage(error)}`);
|
|
485
|
+
}
|
|
486
|
+
}
|
|
379
487
|
function createMachineToolInvokeHandlers(args) {
|
|
488
|
+
const grants = normalizeMachineToolGrants(
|
|
489
|
+
args.grants ?? readMachineToolGrants(args.env ?? process.env)
|
|
490
|
+
);
|
|
380
491
|
const executors = (args.createToolExecutors ?? createLocalWorkspaceToolExecutors)({
|
|
381
492
|
workspaceRoot: args.workspaceRoot,
|
|
382
493
|
// v1 硬 containment:localWorkspaceTools 在无确认回调时对工作区外路径
|
|
@@ -392,7 +503,7 @@ function createMachineToolInvokeHandlers(args) {
|
|
|
392
503
|
readFileNoLedger: true
|
|
393
504
|
});
|
|
394
505
|
const executorMap = executors;
|
|
395
|
-
const invokeWithTimeout = async (toolName, executorArgs, timeoutMs, workspaceRoot) => {
|
|
506
|
+
const invokeWithTimeout = async (toolName, executorArgs, timeoutMs, workspaceRoot, agentKey) => {
|
|
396
507
|
const call = {
|
|
397
508
|
id: "machine-tool-invoke",
|
|
398
509
|
name: toolName,
|
|
@@ -406,7 +517,11 @@ function createMachineToolInvokeHandlers(args) {
|
|
|
406
517
|
});
|
|
407
518
|
if (preflightError) return { error: preflightError };
|
|
408
519
|
}
|
|
520
|
+
const deleteGuardError = await machinePureDeleteGuard(toolName, executorArgs, workspaceRoot);
|
|
521
|
+
if (deleteGuardError) return { error: deleteGuardError };
|
|
409
522
|
let timer = null;
|
|
523
|
+
const audited = grantDimensionForTool(toolName) !== void 0;
|
|
524
|
+
let auditOk = false;
|
|
410
525
|
try {
|
|
411
526
|
const outcome = await Promise.race([
|
|
412
527
|
executorMap[toolName](call),
|
|
@@ -415,6 +530,7 @@ function createMachineToolInvokeHandlers(args) {
|
|
|
415
530
|
})
|
|
416
531
|
]);
|
|
417
532
|
const content = typeof outcome?.content === "string" ? outcome.content : "";
|
|
533
|
+
auditOk = !machineToolOutcomeFailed(outcome);
|
|
418
534
|
if (content.length > TOOL_RESULT_MESSAGE_MAX_CHARS) {
|
|
419
535
|
return {
|
|
420
536
|
result: content.slice(0, TOOL_RESULT_MESSAGE_MAX_CHARS) + `
|
|
@@ -427,14 +543,25 @@ function createMachineToolInvokeHandlers(args) {
|
|
|
427
543
|
return { error: toMessage(error) };
|
|
428
544
|
} finally {
|
|
429
545
|
if (timer) clearTimeout(timer);
|
|
546
|
+
if (audited) {
|
|
547
|
+
await appendMachineToolAudit({
|
|
548
|
+
agentKey,
|
|
549
|
+
tool: toolName,
|
|
550
|
+
target: auditTargetFor(executorArgs),
|
|
551
|
+
ok: auditOk
|
|
552
|
+
});
|
|
553
|
+
}
|
|
430
554
|
}
|
|
431
555
|
};
|
|
432
|
-
const invokeMachineTool = async (requestId, toolName, toolArgs, timeoutMs) => {
|
|
556
|
+
const invokeMachineTool = async (requestId, toolName, toolArgs, timeoutMs, agentKey) => {
|
|
433
557
|
if (!V1_ALLOWED_TOOL_NAMES.has(toolName)) {
|
|
434
558
|
return { error: TOOL_NOT_ALLOWED_MESSAGE };
|
|
435
559
|
}
|
|
560
|
+
if (!isMachineToolGranted(grants, toolName, agentKey)) {
|
|
561
|
+
return { error: machineToolNotGrantedMessage(toolName, agentKey) };
|
|
562
|
+
}
|
|
436
563
|
const resolvedTimeout = resolveTimeoutMs(timeoutMs);
|
|
437
|
-
return invokeWithTimeout(toolName, toolArgs, resolvedTimeout, args.workspaceRoot);
|
|
564
|
+
return invokeWithTimeout(toolName, toolArgs, resolvedTimeout, args.workspaceRoot, agentKey);
|
|
438
565
|
};
|
|
439
566
|
return {
|
|
440
567
|
handleToolInvokeMessage: async (message, send) => {
|
|
@@ -447,7 +574,7 @@ function createMachineToolInvokeHandlers(args) {
|
|
|
447
574
|
);
|
|
448
575
|
return JSON.stringify({ type: "tool.result", requestId, error: TOOL_PAYLOAD_MALFORMED_MESSAGE });
|
|
449
576
|
}
|
|
450
|
-
if (!
|
|
577
|
+
if (!isRecord3(payload.args)) {
|
|
451
578
|
send(
|
|
452
579
|
JSON.stringify({ type: "tool.result", requestId, error: TOOL_ARGS_MALFORMED_MESSAGE })
|
|
453
580
|
);
|
|
@@ -457,7 +584,8 @@ function createMachineToolInvokeHandlers(args) {
|
|
|
457
584
|
requestId,
|
|
458
585
|
payload.tool,
|
|
459
586
|
payload.args,
|
|
460
|
-
payload.timeoutMs
|
|
587
|
+
payload.timeoutMs,
|
|
588
|
+
payload.agentKey
|
|
461
589
|
);
|
|
462
590
|
send(
|
|
463
591
|
JSON.stringify(
|
|
@@ -486,7 +614,7 @@ function isLexicallyInsideRoot(root, targetPath) {
|
|
|
486
614
|
}
|
|
487
615
|
async function machinePathPreflight(args) {
|
|
488
616
|
const workspaceRoot = resolve2(args.workspaceRoot);
|
|
489
|
-
const lexicalPath =
|
|
617
|
+
const lexicalPath = resolveRequestedWorkspacePath(workspaceRoot, args.request);
|
|
490
618
|
if (!isLexicallyInsideRoot(workspaceRoot, lexicalPath)) {
|
|
491
619
|
return `path outside workspace root: ${args.request}`;
|
|
492
620
|
}
|
|
@@ -495,11 +623,19 @@ async function machinePathPreflight(args) {
|
|
|
495
623
|
while (true) {
|
|
496
624
|
const stats = await lstat(current).catch(() => void 0);
|
|
497
625
|
if (!stats) {
|
|
498
|
-
|
|
626
|
+
const parent = resolve2(current, "..");
|
|
627
|
+
if (parent === current) return null;
|
|
628
|
+
return await ancestorContainmentPreflight({
|
|
629
|
+
workspaceRoot,
|
|
630
|
+
ancestor: parent,
|
|
631
|
+
request: args.request
|
|
632
|
+
});
|
|
499
633
|
}
|
|
500
634
|
if (!stats.isSymbolicLink()) break;
|
|
501
635
|
const target = await realpath(current).catch(() => void 0);
|
|
502
|
-
if (!target)
|
|
636
|
+
if (!target) {
|
|
637
|
+
return `path outside workspace root after symlink resolution: ${args.request}`;
|
|
638
|
+
}
|
|
503
639
|
symlinks.push({ link: current, target });
|
|
504
640
|
current = resolve2(current, "..");
|
|
505
641
|
if (current === dirname2(current)) break;
|
|
@@ -515,6 +651,76 @@ async function machinePathPreflight(args) {
|
|
|
515
651
|
}
|
|
516
652
|
return null;
|
|
517
653
|
}
|
|
654
|
+
async function ancestorContainmentPreflight(args) {
|
|
655
|
+
const workspaceRoot = resolve2(args.workspaceRoot);
|
|
656
|
+
let existing = args.ancestor;
|
|
657
|
+
while (true) {
|
|
658
|
+
const stats = await lstat(existing).catch(() => void 0);
|
|
659
|
+
if (stats) break;
|
|
660
|
+
const parent = resolve2(existing, "..");
|
|
661
|
+
if (parent === existing) return null;
|
|
662
|
+
existing = parent;
|
|
663
|
+
}
|
|
664
|
+
try {
|
|
665
|
+
const [realExisting, realRoot] = await Promise.all([realpath(existing), realpath(workspaceRoot)]);
|
|
666
|
+
if (!isLexicallyInsideRoot(realRoot, realExisting)) {
|
|
667
|
+
return `path outside workspace root after symlink resolution: ${args.request}`;
|
|
668
|
+
}
|
|
669
|
+
} catch {
|
|
670
|
+
return `path outside workspace root after symlink resolution: ${args.request}`;
|
|
671
|
+
}
|
|
672
|
+
return null;
|
|
673
|
+
}
|
|
674
|
+
var WRITEFILE_DELETE_GUARD_MESSAGE = "writeFile blocked: refusing to overwrite an existing non-empty file with empty content (data-deletion guard). Use editFile with the exact oldText to remove specific text, or write the intended content explicitly.";
|
|
675
|
+
var WRITEFILE_DIRECTORY_TARGET_MESSAGE = "writeFile blocked: target path is an existing directory, not a file (refusing to write; nothing was modified).";
|
|
676
|
+
var EDITFILE_DELETE_GUARD_MESSAGE = "editFile blocked: refusing to replace matched text with an empty newText (data-deletion guard). Provide the intended replacement text.";
|
|
677
|
+
function extractMachineToolStringField(executorArgs, aliases) {
|
|
678
|
+
const rawArgs = typeof executorArgs === "string" ? executorArgs : executorArgs !== void 0 && executorArgs !== null ? JSON.stringify(executorArgs) : null;
|
|
679
|
+
if (rawArgs === null) return void 0;
|
|
680
|
+
let parsed;
|
|
681
|
+
try {
|
|
682
|
+
parsed = JSON.parse(rawArgs);
|
|
683
|
+
} catch {
|
|
684
|
+
return void 0;
|
|
685
|
+
}
|
|
686
|
+
if (typeof parsed !== "object" || parsed === null || Array.isArray(parsed)) return void 0;
|
|
687
|
+
for (const key of aliases) {
|
|
688
|
+
const value = parsed[key];
|
|
689
|
+
if (typeof value === "string") return value;
|
|
690
|
+
}
|
|
691
|
+
return void 0;
|
|
692
|
+
}
|
|
693
|
+
function writeFileUninspectableTargetMessage(code) {
|
|
694
|
+
return `writeFile blocked: target cannot be inspected (${code}); refusing to write (fail closed \u2014 only a missing target counts as a new file).`;
|
|
695
|
+
}
|
|
696
|
+
function fsErrorCode(error) {
|
|
697
|
+
if (!error || typeof error !== "object") return void 0;
|
|
698
|
+
const code = error.code;
|
|
699
|
+
return typeof code === "string" ? code : void 0;
|
|
700
|
+
}
|
|
701
|
+
async function machinePureDeleteGuard(toolName, executorArgs, workspaceRoot) {
|
|
702
|
+
if (toolName === "writeFile") {
|
|
703
|
+
const content = extractMachineToolStringField(executorArgs, ["content"]);
|
|
704
|
+
if (content === void 0 || content.trim() !== "") return null;
|
|
705
|
+
const requestPath = extractMachineToolRequestPath(executorArgs);
|
|
706
|
+
if (requestPath === null) return null;
|
|
707
|
+
let stats;
|
|
708
|
+
try {
|
|
709
|
+
stats = await stat(resolveRequestedWorkspacePath(workspaceRoot, requestPath));
|
|
710
|
+
} catch (error) {
|
|
711
|
+
if (fsErrorCode(error) === "ENOENT") return null;
|
|
712
|
+
return writeFileUninspectableTargetMessage(fsErrorCode(error) ?? "unknown");
|
|
713
|
+
}
|
|
714
|
+
if (stats.isDirectory()) return WRITEFILE_DIRECTORY_TARGET_MESSAGE;
|
|
715
|
+
return stats.size > 0 ? WRITEFILE_DELETE_GUARD_MESSAGE : null;
|
|
716
|
+
}
|
|
717
|
+
if (toolName === "editFile") {
|
|
718
|
+
const newText = extractMachineToolStringField(executorArgs, NEW_TEXT_FIELD_ALIASES);
|
|
719
|
+
if (newText !== void 0 && newText.trim() === "") return EDITFILE_DELETE_GUARD_MESSAGE;
|
|
720
|
+
return null;
|
|
721
|
+
}
|
|
722
|
+
return null;
|
|
723
|
+
}
|
|
518
724
|
function extractMachineToolRequestPath(executorArgs) {
|
|
519
725
|
const rawArgs = typeof executorArgs === "string" ? executorArgs : executorArgs !== void 0 && executorArgs !== null ? JSON.stringify(executorArgs) : null;
|
|
520
726
|
if (rawArgs === null) return null;
|
|
@@ -538,9 +744,9 @@ function parseToolInvokeFrame(message) {
|
|
|
538
744
|
} catch {
|
|
539
745
|
return null;
|
|
540
746
|
}
|
|
541
|
-
if (!
|
|
747
|
+
if (!isRecord3(parsed) || parsed.type !== "tool.invoke") return null;
|
|
542
748
|
if (typeof parsed.requestId !== "string" || parsed.requestId.length === 0) return null;
|
|
543
|
-
if (!
|
|
749
|
+
if (!isRecord3(parsed.payload)) {
|
|
544
750
|
return {
|
|
545
751
|
requestId: parsed.requestId,
|
|
546
752
|
payload: { tool: "", args: {}, timeoutMs: void 0 },
|
|
@@ -553,23 +759,46 @@ function parseToolInvokeFrame(message) {
|
|
|
553
759
|
payload: {
|
|
554
760
|
tool: typeof payload.tool === "string" ? payload.tool : "",
|
|
555
761
|
args: payload.args,
|
|
556
|
-
timeoutMs: payload.timeoutMs
|
|
762
|
+
timeoutMs: payload.timeoutMs,
|
|
763
|
+
agentKey: typeof payload.agentKey === "string" && payload.agentKey.length > 0 ? payload.agentKey : void 0
|
|
557
764
|
}
|
|
558
765
|
};
|
|
559
766
|
}
|
|
560
|
-
function
|
|
767
|
+
function isRecord3(value) {
|
|
561
768
|
return typeof value === "object" && value !== null && !Array.isArray(value);
|
|
562
769
|
}
|
|
563
770
|
|
|
564
771
|
// packages/cli/machineWsSession.ts
|
|
565
772
|
var CONNECTOR_WS_KEEPALIVE_MS = 25e3;
|
|
773
|
+
var DEFAULT_CONNECTOR_TEARDOWN_TIMEOUT_MS = 2e3;
|
|
774
|
+
function resolveTeardownTimeoutMs(env) {
|
|
775
|
+
return clampConnectorTimerDelayMs(
|
|
776
|
+
parsePositiveFiniteNumberOrFallback(
|
|
777
|
+
env.NOLO_CONNECT_TEARDOWN_TIMEOUT_MS,
|
|
778
|
+
DEFAULT_CONNECTOR_TEARDOWN_TIMEOUT_MS
|
|
779
|
+
)
|
|
780
|
+
);
|
|
781
|
+
}
|
|
782
|
+
async function settleWithinTimeout(promises, timeoutMs) {
|
|
783
|
+
let timer = null;
|
|
784
|
+
try {
|
|
785
|
+
const outcome = await Promise.race([
|
|
786
|
+
Promise.allSettled(promises).then(() => "settled"),
|
|
787
|
+
new Promise((resolve3) => {
|
|
788
|
+
timer = setTimeout(() => resolve3("timeout"), timeoutMs);
|
|
789
|
+
})
|
|
790
|
+
]);
|
|
791
|
+
return { timedOut: outcome === "timeout" };
|
|
792
|
+
} finally {
|
|
793
|
+
if (timer) clearTimeout(timer);
|
|
794
|
+
}
|
|
795
|
+
}
|
|
566
796
|
function buildConnectorKeepaliveMessage() {
|
|
567
797
|
return JSON.stringify({ type: "connector.keepalive", sentAt: Date.now() });
|
|
568
798
|
}
|
|
569
799
|
function resolveHeartbeatIntervalMs2(env) {
|
|
570
|
-
return
|
|
571
|
-
env.NOLO_CONNECT_HEARTBEAT_MS,
|
|
572
|
-
3e4
|
|
800
|
+
return clampConnectorTimerDelayMs(
|
|
801
|
+
parsePositiveFiniteNumberOrFallback(env.NOLO_CONNECT_HEARTBEAT_MS, 3e4)
|
|
573
802
|
);
|
|
574
803
|
}
|
|
575
804
|
async function defaultConnectWebSocket(url, options) {
|
|
@@ -600,6 +829,7 @@ async function defaultConnectWebSocket(url, options) {
|
|
|
600
829
|
}
|
|
601
830
|
};
|
|
602
831
|
options.signal?.addEventListener("abort", handleAbort, { once: true });
|
|
832
|
+
options.teardownSignal?.addEventListener("abort", handleAbort, { once: true });
|
|
603
833
|
ws.addEventListener(
|
|
604
834
|
"open",
|
|
605
835
|
() => {
|
|
@@ -609,8 +839,13 @@ async function defaultConnectWebSocket(url, options) {
|
|
|
609
839
|
ws.send(buildConnectorKeepaliveMessage());
|
|
610
840
|
} catch {
|
|
611
841
|
clearKeepalive();
|
|
842
|
+
try {
|
|
843
|
+
ws.close();
|
|
844
|
+
} catch {
|
|
845
|
+
resolve3();
|
|
846
|
+
}
|
|
612
847
|
}
|
|
613
|
-
}, CONNECTOR_WS_KEEPALIVE_MS);
|
|
848
|
+
}, options.keepaliveMs ?? CONNECTOR_WS_KEEPALIVE_MS);
|
|
614
849
|
},
|
|
615
850
|
{ once: true }
|
|
616
851
|
);
|
|
@@ -644,8 +879,19 @@ async function defaultConnectWebSocket(url, options) {
|
|
|
644
879
|
async function runMachineWsSession(options) {
|
|
645
880
|
const sentMessages = [];
|
|
646
881
|
const heartbeatAbort = new AbortController();
|
|
882
|
+
const teardownAbort = new AbortController();
|
|
883
|
+
const teardownTimeoutMs = resolveTeardownTimeoutMs(options.env);
|
|
647
884
|
let heartbeatLoopPromise = null;
|
|
648
885
|
let websocketPromise = null;
|
|
886
|
+
const settleTeardown = async () => {
|
|
887
|
+
const { timedOut } = await settleWithinTimeout(
|
|
888
|
+
[websocketPromise, heartbeatLoopPromise].filter(Boolean),
|
|
889
|
+
teardownTimeoutMs
|
|
890
|
+
);
|
|
891
|
+
if (timedOut) {
|
|
892
|
+
teardownAbort.abort();
|
|
893
|
+
}
|
|
894
|
+
};
|
|
649
895
|
try {
|
|
650
896
|
if (options.signal?.aborted) {
|
|
651
897
|
return { exitCode: 0 };
|
|
@@ -669,11 +915,13 @@ async function runMachineWsSession(options) {
|
|
|
669
915
|
serverUrl: options.serverUrl,
|
|
670
916
|
machineId: options.machine.machineId,
|
|
671
917
|
connectorSurface: "cli",
|
|
672
|
-
headers: { Authorization: `Bearer ${options.authToken}` }
|
|
918
|
+
headers: { Authorization: `Bearer ${options.authToken}` },
|
|
919
|
+
probeTimeoutMs: resolveConnectorProbeTimeoutMs(options.env)
|
|
673
920
|
});
|
|
674
921
|
websocketPromise = options.connectWebSocket(wsTarget, {
|
|
675
922
|
headers: { Authorization: `Bearer ${options.authToken}` },
|
|
676
923
|
signal: options.signal,
|
|
924
|
+
teardownSignal: teardownAbort.signal,
|
|
677
925
|
sentMessages,
|
|
678
926
|
onMessage: (message) => options.onMessage(message, (response) => {
|
|
679
927
|
sentMessages.push(response);
|
|
@@ -690,16 +938,14 @@ async function runMachineWsSession(options) {
|
|
|
690
938
|
[websocketPromise, heartbeatMonitorPromise, abortPromise].filter(Boolean)
|
|
691
939
|
);
|
|
692
940
|
heartbeatAbort.abort();
|
|
693
|
-
await
|
|
941
|
+
await settleTeardown();
|
|
694
942
|
if (raceResult === "aborted") {
|
|
695
943
|
return { exitCode: 0 };
|
|
696
944
|
}
|
|
697
945
|
return { exitCode: 0 };
|
|
698
946
|
} catch (error) {
|
|
699
947
|
heartbeatAbort.abort();
|
|
700
|
-
await
|
|
701
|
-
[websocketPromise, heartbeatLoopPromise].filter(Boolean)
|
|
702
|
-
);
|
|
948
|
+
await settleTeardown();
|
|
703
949
|
if (isConnectorWebSocketAuthError(error)) {
|
|
704
950
|
options.output.write(
|
|
705
951
|
`[nolo] Connector websocket auth failed: ${error.message}. Re-register this machine or update NOLO_MACHINE_API_KEY.
|
|
@@ -802,6 +1048,43 @@ async function handleMachineWsMessageDemux(message, send, handlers, runConnector
|
|
|
802
1048
|
}
|
|
803
1049
|
await runConnectorMessage();
|
|
804
1050
|
}
|
|
1051
|
+
function readMachineToolGrants(env) {
|
|
1052
|
+
const raw = env.NOLO_MACHINE_TOOL_GRANTS?.trim();
|
|
1053
|
+
if (!raw) return void 0;
|
|
1054
|
+
let parsed;
|
|
1055
|
+
try {
|
|
1056
|
+
parsed = JSON.parse(raw);
|
|
1057
|
+
} catch (error) {
|
|
1058
|
+
warnMalformedMachineToolGrantsOnce(
|
|
1059
|
+
`json:${raw}`,
|
|
1060
|
+
`[nolo] NOLO_MACHINE_TOOL_GRANTS is not valid JSON, ignoring it: ${error instanceof Error ? error.message : String(error)}`
|
|
1061
|
+
);
|
|
1062
|
+
return void 0;
|
|
1063
|
+
}
|
|
1064
|
+
if (!isRecord(parsed)) {
|
|
1065
|
+
warnMalformedMachineToolGrantsOnce(
|
|
1066
|
+
`shape:${raw}`,
|
|
1067
|
+
"[nolo] NOLO_MACHINE_TOOL_GRANTS must be a JSON object, ignoring it"
|
|
1068
|
+
);
|
|
1069
|
+
return void 0;
|
|
1070
|
+
}
|
|
1071
|
+
return parsed;
|
|
1072
|
+
}
|
|
1073
|
+
var warnedMalformedMachineToolGrants = /* @__PURE__ */ new Set();
|
|
1074
|
+
function warnMalformedMachineToolGrantsOnce(dedupeKey, message) {
|
|
1075
|
+
if (warnedMalformedMachineToolGrants.has(dedupeKey)) return;
|
|
1076
|
+
warnedMalformedMachineToolGrants.add(dedupeKey);
|
|
1077
|
+
console.warn(message);
|
|
1078
|
+
}
|
|
1079
|
+
function __resetMalformedMachineToolGrantsWarningsForTests() {
|
|
1080
|
+
warnedMalformedMachineToolGrants.clear();
|
|
1081
|
+
}
|
|
1082
|
+
function appendToolGrantsToWsUrl(wsUrl, grants) {
|
|
1083
|
+
if (!grants) return wsUrl;
|
|
1084
|
+
const target = new URL(wsUrl);
|
|
1085
|
+
target.searchParams.set("toolGrants", JSON.stringify(grants));
|
|
1086
|
+
return target.toString();
|
|
1087
|
+
}
|
|
805
1088
|
function resolveAuthToken2(env) {
|
|
806
1089
|
return env.AUTH_TOKEN || env.AUTH || "";
|
|
807
1090
|
}
|
|
@@ -850,11 +1133,60 @@ async function sleepWithAbort(ms, sleep, signal) {
|
|
|
850
1133
|
]);
|
|
851
1134
|
}
|
|
852
1135
|
function resolveConnectorReconnectDelayMs(env) {
|
|
853
|
-
const
|
|
854
|
-
|
|
1136
|
+
const rawValue = env.NOLO_CONNECT_RECONNECT_MS;
|
|
1137
|
+
if (rawValue === void 0 || rawValue.trim() === "") return 5e3;
|
|
1138
|
+
const raw = Number(rawValue);
|
|
1139
|
+
if (!Number.isFinite(raw) || raw < 0) return 5e3;
|
|
1140
|
+
return Math.min(raw, MAX_CONNECTOR_TIMER_DELAY_MS);
|
|
1141
|
+
}
|
|
1142
|
+
var DEFAULT_CONNECTOR_HEARTBEAT_TIMEOUT_MS = 1e4;
|
|
1143
|
+
function resolveConnectorHeartbeatTimeoutMs(env) {
|
|
1144
|
+
return clampConnectorTimerDelayMs(
|
|
1145
|
+
parsePositiveFiniteNumberOrFallback(
|
|
1146
|
+
env.NOLO_CONNECT_HEARTBEAT_TIMEOUT_MS,
|
|
1147
|
+
DEFAULT_CONNECTOR_HEARTBEAT_TIMEOUT_MS
|
|
1148
|
+
)
|
|
1149
|
+
);
|
|
1150
|
+
}
|
|
1151
|
+
async function postMachineHeartbeat(args) {
|
|
1152
|
+
const { fetchImpl, serverUrl, authToken, machine, timeoutMs } = args;
|
|
1153
|
+
const controller = new AbortController();
|
|
1154
|
+
const startedAt = Date.now();
|
|
1155
|
+
let timer = null;
|
|
1156
|
+
const timeoutPromise = new Promise((_resolve, reject) => {
|
|
1157
|
+
timer = setTimeout(() => {
|
|
1158
|
+
controller.abort();
|
|
1159
|
+
reject(
|
|
1160
|
+
new Error(
|
|
1161
|
+
`heartbeat timed out after ${Date.now() - startedAt}ms (NOLO_CONNECT_HEARTBEAT_TIMEOUT_MS=${timeoutMs})`
|
|
1162
|
+
)
|
|
1163
|
+
);
|
|
1164
|
+
}, timeoutMs);
|
|
1165
|
+
});
|
|
1166
|
+
try {
|
|
1167
|
+
const res = await Promise.race([
|
|
1168
|
+
fetchImpl(`${serverUrl}/api/machines/heartbeat`, {
|
|
1169
|
+
method: "POST",
|
|
1170
|
+
headers: {
|
|
1171
|
+
Authorization: `Bearer ${authToken}`,
|
|
1172
|
+
"Content-Type": "application/json"
|
|
1173
|
+
},
|
|
1174
|
+
body: JSON.stringify(machine),
|
|
1175
|
+
signal: controller.signal
|
|
1176
|
+
}),
|
|
1177
|
+
timeoutPromise
|
|
1178
|
+
]);
|
|
1179
|
+
if (!res.ok) {
|
|
1180
|
+
const text = await res.text().catch(() => "");
|
|
1181
|
+
throw new Error(`HTTP ${res.status}
|
|
1182
|
+
${text}`);
|
|
1183
|
+
}
|
|
1184
|
+
} finally {
|
|
1185
|
+
if (timer) clearTimeout(timer);
|
|
1186
|
+
}
|
|
855
1187
|
}
|
|
856
1188
|
async function defaultExecuteCli(provider, prompt, options) {
|
|
857
|
-
const { executeCli } = await import("./cliExecutor-
|
|
1189
|
+
const { executeCli } = await import("./cliExecutor-AWYR3T33.js");
|
|
858
1190
|
return executeCli(provider, prompt, options);
|
|
859
1191
|
}
|
|
860
1192
|
function detectLaunchableMachineInfo() {
|
|
@@ -924,21 +1256,13 @@ async function runMachineConnectCommand(args, deps = {}) {
|
|
|
924
1256
|
});
|
|
925
1257
|
}
|
|
926
1258
|
const machine = (deps.machineInfo ?? detectLaunchableMachineInfo)();
|
|
927
|
-
const sendHeartbeat =
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
body: JSON.stringify(machine)
|
|
935
|
-
});
|
|
936
|
-
if (!res.ok) {
|
|
937
|
-
const text = await res.text().catch(() => "");
|
|
938
|
-
throw new Error(`HTTP ${res.status}
|
|
939
|
-
${text}`);
|
|
940
|
-
}
|
|
941
|
-
};
|
|
1259
|
+
const sendHeartbeat = () => postMachineHeartbeat({
|
|
1260
|
+
fetchImpl,
|
|
1261
|
+
serverUrl,
|
|
1262
|
+
authToken,
|
|
1263
|
+
machine,
|
|
1264
|
+
timeoutMs: resolveConnectorHeartbeatTimeoutMs(env)
|
|
1265
|
+
});
|
|
942
1266
|
if (hasFlag(args, "--ws")) {
|
|
943
1267
|
const validateWorkspaceLinks = deps.validateWorkspaceLinks ?? (() => []);
|
|
944
1268
|
if (!await checkConnectorWorkspaceLinks(process.cwd(), output, validateWorkspaceLinks)) {
|
|
@@ -947,8 +1271,15 @@ ${text}`);
|
|
|
947
1271
|
const maxAttempts = deps.maxConnectorAttempts ?? Infinity;
|
|
948
1272
|
const sleep = deps.sleep ?? defaultSleep2;
|
|
949
1273
|
const reconnectDelayMs = resolveConnectorReconnectDelayMs(env);
|
|
1274
|
+
const toolGrants = readMachineToolGrants(env);
|
|
950
1275
|
const toolInvokeHandlers = createMachineToolInvokeHandlers({
|
|
951
|
-
workspaceRoot: process.cwd()
|
|
1276
|
+
workspaceRoot: process.cwd(),
|
|
1277
|
+
// M2 修复:机器侧授权复核与握手上报共用同一来源——本次 `deps.env ??
|
|
1278
|
+
// process.env`。grants 快照与 WS URL 上报的那份逐字节相同;未配置时也
|
|
1279
|
+
// 显式传 env,工厂不再回落到 process.env(调用方经 deps.env 注入环境时
|
|
1280
|
+
// 两端曾不一致)。
|
|
1281
|
+
env,
|
|
1282
|
+
...toolGrants ? { grants: toolGrants } : {}
|
|
952
1283
|
});
|
|
953
1284
|
for (let attempt = 1; attempt <= maxAttempts; attempt += 1) {
|
|
954
1285
|
if (deps.signal?.aborted) {
|
|
@@ -965,10 +1296,13 @@ ${text}`);
|
|
|
965
1296
|
connectWebSocket: deps.connectWebSocket ?? defaultConnectWebSocket,
|
|
966
1297
|
serverUrl,
|
|
967
1298
|
authToken,
|
|
968
|
-
resolveConnectorWebSocketTarget: (options) =>
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
1299
|
+
resolveConnectorWebSocketTarget: async (options) => appendToolGrantsToWsUrl(
|
|
1300
|
+
await resolveConnectorWebSocketTarget({
|
|
1301
|
+
...options,
|
|
1302
|
+
fetchImpl
|
|
1303
|
+
}),
|
|
1304
|
+
toolGrants
|
|
1305
|
+
),
|
|
972
1306
|
onMessage: (message, send) => handleMachineWsMessageDemux(
|
|
973
1307
|
message,
|
|
974
1308
|
send,
|
|
@@ -998,7 +1332,10 @@ ${text}`);
|
|
|
998
1332
|
return 0;
|
|
999
1333
|
}
|
|
1000
1334
|
if (attempt >= maxAttempts) return exitCode;
|
|
1001
|
-
const retryDelayMs =
|
|
1335
|
+
const retryDelayMs = Math.min(
|
|
1336
|
+
sessionResult.retryAfterMs ?? reconnectDelayMs,
|
|
1337
|
+
MAX_CONNECTOR_TIMER_DELAY_MS
|
|
1338
|
+
);
|
|
1002
1339
|
const reconnectContext = sessionResult.reconnectReason === CORE_DRAIN_REASON ? " during core draining" : "";
|
|
1003
1340
|
output.write(
|
|
1004
1341
|
`[nolo] Connector websocket disconnected${reconnectContext}. Reconnecting in ${retryDelayMs}ms.
|
|
@@ -1024,7 +1361,11 @@ ${text}`);
|
|
|
1024
1361
|
});
|
|
1025
1362
|
}
|
|
1026
1363
|
export {
|
|
1364
|
+
__resetMalformedMachineToolGrantsWarningsForTests,
|
|
1027
1365
|
formatMachineStatus,
|
|
1366
|
+
postMachineHeartbeat,
|
|
1367
|
+
readMachineToolGrants,
|
|
1368
|
+
resolveConnectorHeartbeatTimeoutMs,
|
|
1028
1369
|
runMachineConnectCommand,
|
|
1029
1370
|
runMachineStatusCommand
|
|
1030
1371
|
};
|