nolo-cli 0.226.0-alpha.1 → 0.226.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 +3 -5
- package/{_executeModel-UE2NJPZD.js → _executeModel-IZ2MCXHO.js} +89 -83
- package/{action-CK64LS6S.js → action-VDEW6WLI.js} +9 -6
- package/{addContentAction-EQXMFNPR.js → addContentAction-7YVXHIPQ.js} +15 -14
- package/{addDialogAgentAction-RSDZDASD.js → addDialogAgentAction-BX7B47HF.js} +18 -17
- package/{agentDeleteCommand-SOI25WK7.js → agentDeleteCommand-N7ELXPLD.js} +145 -138
- package/{agentEmailCommands-UGWQQNKM.js → agentEmailCommands-OFS477PV.js} +144 -133
- package/{agentFavoriteCommands-2LKGKSUD.js → agentFavoriteCommands-7LOP3HUD.js} +5 -5
- package/{agentGrantCommands-QQV4N4JW.js → agentGrantCommands-L6O2HVJI.js} +5 -5
- package/agentListCommands-IQQHJSXP.js +644 -0
- package/{agentMachineCommands-M6IKO7XE.js → agentMachineCommands-NS65BEW7.js} +75 -66
- package/{agentProviderCommands-7BSJH7TO.js → agentProviderCommands-SS6M6VGY.js} +6 -6
- package/{agentPullCommand-XN6ZPBUW.js → agentPullCommand-QQQZSC6S.js} +6 -6
- package/agentRecordCommands-4VE7CNLC.js +188 -0
- package/agentRunCommand-2MUXHKNW.js +223 -0
- package/{agentRunControl-DFEEOFC7.js → agentRunControl-55GL6Q3M.js} +23 -15
- package/{agentRuntimeLocal-GSTYFEX4.js → agentRuntimeLocal-5DB2P4MU.js} +63 -49
- package/{agentSlice-7PTNWEED.js → agentSlice-5VTAFG43.js} +19 -18
- package/{appDeleteCommands-L7HL4AWF.js → appDeleteCommands-EDKUPHJM.js} +67 -58
- package/{appDeployCommands-SGSUNFZR.js → appDeployCommands-JO74GW4L.js} +67 -58
- package/{appDeployStatusCommands-AAA3XD54.js → appDeployStatusCommands-U77ZUHX7.js} +67 -58
- package/{appGetCommands-LN72GAOA.js → appGetCommands-QCMHBYPX.js} +67 -58
- package/{appListCommands-IJQQ3VND.js → appListCommands-ZQJYEXI6.js} +67 -58
- package/{authCommand-7JXW54U4.js → authCommand-W4KXRZLI.js} +33 -28
- package/{authCommands-YDNAIDEY.js → authCommands-6AUYO65N.js} +15 -10
- package/{builtinSkillRegistry-PXH7EGQB.js → builtinSkillRegistry-GHE3RD3V.js} +8 -8
- package/{chromeCommands-G5UDKVSV.js → chromeCommands-S7AW3AOD.js} +383 -6
- package/{chromeOpsCommands-YKX2QX3A.js → chromeOpsCommands-TBPM6MR4.js} +6 -6
- package/{chunk-7Z6EW7AH.js → chunk-247AAJRK.js} +13 -6
- package/{chunk-P2ZLUIW2.js → chunk-2BSLGODA.js} +350 -25
- package/{chunk-4HFTBHBF.js → chunk-2N4UBHUU.js} +8 -8
- package/chunk-2SXN7LAY.js +15 -0
- package/{chunk-GSAS72AN.js → chunk-2T5BHLID.js} +2871 -1565
- package/{chunk-XI2BWJM5.js → chunk-324FWHUA.js} +20 -3
- package/{chunk-VFBVA3U2.js → chunk-3OQFXODL.js} +131 -40
- package/{chunk-BGGHA5DV.js → chunk-3ORFJP2Z.js} +1 -1
- package/{chunk-OWH2BLNU.js → chunk-3UNAGTBW.js} +32 -95
- package/{chunk-LM2PS3YS.js → chunk-4F7SWSWO.js} +26 -13
- package/{chunk-SBVTHMEG.js → chunk-4FE3IWRE.js} +1 -1
- package/{chunk-GOAPXKQU.js → chunk-4UK6UBXF.js} +4 -4
- package/{chunk-4JVNURX4.js → chunk-4YFC3DWW.js} +68 -16
- package/chunk-4ZCTKB27.js +31 -0
- package/chunk-53W5BXLN.js +340 -0
- package/{chunk-TD6QCQ5G.js → chunk-5GRWWUB4.js} +4 -4
- package/{chunk-JWXITTQB.js → chunk-5HUO7SEX.js} +9 -107
- package/{chunk-ZH6MUQEO.js → chunk-6326DRQY.js} +1 -1
- package/{chunk-AVHRSJUH.js → chunk-6MQWGA5F.js} +31 -24
- package/{chunk-67BE44IS.js → chunk-6MX6S6TE.js} +3 -3
- package/chunk-6RSNVJGO.js +279 -0
- package/{chunk-BRW24CTE.js → chunk-6S6CZUXK.js} +42 -33
- package/{chunk-PDCV7P5W.js → chunk-6XIE5ZGI.js} +1 -1
- package/{chunk-CVS5IMJ5.js → chunk-6XLWUNZB.js} +25 -25
- package/{chunk-YGMBIXCF.js → chunk-6XRPBZRS.js} +4 -2
- package/{chunk-62HXNQVV.js → chunk-776CXKMX.js} +1 -1
- package/{chunk-6J4TTPS2.js → chunk-7AWKDRXG.js} +5 -5
- package/{chunk-3KNEE64G.js → chunk-7GTXPS3D.js} +16 -16
- package/{chunk-FS3RA7D2.js → chunk-7HUHOCIY.js} +147 -162
- package/{chunk-PWTNI4N7.js → chunk-ANUP75N2.js} +22 -0
- package/chunk-BEM6LPD2.js +734 -0
- package/{chunk-AGP3YSEC.js → chunk-BH7CEVOH.js} +46 -1
- package/chunk-BIDSIRTS.js +307 -0
- package/{chunk-VTW7VKZX.js → chunk-C4KX626C.js} +15 -15
- package/chunk-C5A54QS7.js +108 -0
- package/{chunk-4PMZVBDU.js → chunk-CHYYSFFM.js} +6 -6
- package/{chunk-VREDDN25.js → chunk-CJTB3OYB.js} +14 -9
- package/{chunk-YFLVRVYK.js → chunk-DLT2DN4M.js} +1 -1
- package/{chunk-LKA64WH4.js → chunk-DMPZMYH4.js} +37 -1
- package/{chunk-EOWLBDY6.js → chunk-DOK7GDRU.js} +1 -1
- package/{chunk-5NC6A2RZ.js → chunk-DPAIQLAL.js} +105 -102
- package/{chunk-KFHREHUQ.js → chunk-DXWGFL2Z.js} +89 -1
- package/{chunk-XN23AUVU.js → chunk-EKXPHL7M.js} +8 -5
- package/{chunk-DISQCYPE.js → chunk-ENYTIRIO.js} +6 -6
- package/{chunk-2TIQO6TC.js → chunk-ER3P6MBT.js} +206 -308
- package/{chunk-M3JEW6N6.js → chunk-F26GAEH3.js} +10 -0
- package/{chunk-JM5C4EUA.js → chunk-F4MCAOWN.js} +6 -6
- package/chunk-FDZ2GBWO.js +166 -0
- package/{chunk-PMDVQBGA.js → chunk-GAHJLSDO.js} +14 -7
- package/{chunk-N5PQJKCY.js → chunk-GES5GIAU.js} +14 -13
- package/{chunk-HYHIAM6T.js → chunk-HQVNO7FH.js} +66 -35
- package/chunk-HSWEFHFS.js +103 -0
- package/{chunk-S2NTVGA2.js → chunk-I2OYPD3Y.js} +1 -1
- package/{chunk-F7DU25CE.js → chunk-IIG3TT73.js} +460 -123
- package/{chunk-AK5O76CC.js → chunk-IZJFTY4R.js} +3 -3
- package/{chunk-2VA6TU4I.js → chunk-J25ESVUW.js} +22 -19
- package/{chunk-TUIWP2LF.js → chunk-J2XZZXIH.js} +4 -4
- package/{chunk-JVRQ6YVK.js → chunk-JBWXPACD.js} +1 -1
- package/{chunk-D726I5AZ.js → chunk-JVJ53XCH.js} +2 -2
- package/{chunk-TXGQ4O5S.js → chunk-KC2QVCI7.js} +20 -174
- package/{chunk-UKS7D2NL.js → chunk-KF2DWSAH.js} +113 -28
- package/chunk-KK3FCYZM.js +647 -0
- package/{chunk-ZZ4M2I3R.js → chunk-KLD7K5FD.js} +349 -16
- package/{chunk-JIADJPUV.js → chunk-KMW5CRRM.js} +1564 -2955
- package/{chunk-N5Z2V73W.js → chunk-LELADM5Q.js} +1 -1
- package/{chunk-4NA3YTBC.js → chunk-LMFMV5UC.js} +8 -8
- package/{chunk-KZU52OJ5.js → chunk-LZOOUQAZ.js} +6 -6
- package/{chunk-VV7TXWOC.js → chunk-M5EA44QU.js} +6 -6
- package/{chunk-UYOICCYG.js → chunk-MEDPR36J.js} +64 -89
- package/chunk-MFXJY44K.js +133 -0
- package/chunk-MVOZ22RZ.js +26 -0
- package/{chunk-3QFLXA24.js → chunk-N6EN3HK3.js} +3 -3
- package/{chunk-SOF4OWDM.js → chunk-NEG5LYK5.js} +1 -3
- package/{chunk-HJAO2NAL.js → chunk-ODGSLWLO.js} +593 -370
- package/{chunk-OB6DVWPF.js → chunk-OGZE6BZG.js} +331 -99
- package/{chunk-KYH7XW3K.js → chunk-OJRTTERA.js} +77 -2
- package/{chunk-2VUZSVAS.js → chunk-OKPC4QNX.js} +57 -20
- package/{chunk-SOG7OEXX.js → chunk-ONFFUQYM.js} +1 -1
- package/{chunk-KNIIRXHF.js → chunk-P244EH4W.js} +46 -8
- package/chunk-P27E22MA.js +203 -0
- package/{chunk-YDBMZ7FV.js → chunk-PK7VT4ZU.js} +3 -3
- package/{chunk-EUCFKKDM.js → chunk-PVFYPUIM.js} +40 -10
- package/{chunk-HOCHUZQ7.js → chunk-QJTZ76CP.js} +24 -6
- package/{chunk-5RKUPJYL.js → chunk-QLUYDJST.js} +11 -3
- package/{chunk-EVPIBQ5I.js → chunk-QUJKDFZW.js} +17 -17
- package/{chunk-C4VAR65S.js → chunk-QXUVCIPB.js} +204 -124
- package/{chunk-X4OVEYPX.js → chunk-QYNABNNQ.js} +13 -13
- package/{chunk-MK2Q7ZJD.js → chunk-R7XWZDOH.js} +58 -24
- package/{chunk-5FUN7EG4.js → chunk-RD3QLZQV.js} +83 -47
- package/{chunk-KC4SCKXO.js → chunk-RGUWOMXU.js} +1234 -1451
- package/{chunk-IZIN2UNJ.js → chunk-RH44TIHX.js} +206 -27
- package/{chunk-GNHMRBYZ.js → chunk-RIMFTQMC.js} +282 -58
- package/{chunk-VQUWV3YR.js → chunk-S25VJYXV.js} +9 -3
- package/{chunk-X7YC2OHB.js → chunk-SBRJOYND.js} +723 -355
- package/{chunk-UEKXWO7A.js → chunk-SBRSXY67.js} +18 -7
- package/chunk-SR4FE5VD.js +9 -0
- package/{chunk-4WVJLODK.js → chunk-T23G6PXQ.js} +8 -3
- package/chunk-T3WSFTBS.js +62 -0
- package/{chunk-KEN3N2TN.js → chunk-TB5KTLNB.js} +15 -12
- package/{chunk-VP3BINY7.js → chunk-TOK555CQ.js} +31 -1
- package/{chunk-OBSEKCVK.js → chunk-U4VSBDO5.js} +88 -0
- package/{chunk-PPJYZRSQ.js → chunk-U5LOKQ2R.js} +30 -14
- package/{chunk-GGKNJ42M.js → chunk-UDT4SI37.js} +18 -108
- package/{chunk-CKT6QUE2.js → chunk-UHW6SCVK.js} +1 -1
- package/{chunk-GVGOEMNV.js → chunk-UQXOORR3.js} +5 -5
- package/{chunk-GS4OTYCH.js → chunk-UR7555FE.js} +9 -9
- package/{chunk-QLFCTYRH.js → chunk-UWOCASVL.js} +20 -13
- package/{chunk-C4WTX5TU.js → chunk-V2V5Q6DU.js} +2 -2
- package/{chunk-2ZKFCIJJ.js → chunk-VCU5GV42.js} +1 -1
- package/{chunk-FTQWYWUI.js → chunk-VMWY7TUA.js} +1 -1
- package/chunk-VNALJT32.js +33394 -0
- package/{chunk-HGDKT2D6.js → chunk-VTHWBTRE.js} +177 -1
- package/chunk-WBSJAIZP.js +170 -0
- package/chunk-WDWZPASX.js +29 -0
- package/chunk-WFGNWWJI.js +326 -0
- package/{chunk-UJKTI5PG.js → chunk-WRKMXMU7.js} +2 -1
- package/chunk-WVOZ35E4.js +1438 -0
- package/{chunk-FIYSMXHY.js → chunk-WWTSEBDF.js} +1 -1
- package/{chunk-E2BESSAW.js → chunk-X4O7FJF5.js} +2 -0
- package/{chunk-GIABSSWQ.js → chunk-XDNXKFWF.js} +6 -6
- package/{chunk-GBZ4YKEO.js → chunk-XLN2GD6Z.js} +7 -7
- package/{chunk-45LZIYXB.js → chunk-XNEDFWT4.js} +2 -2
- package/{chunk-EWPDMS4N.js → chunk-Y22P6ASC.js} +32 -17
- package/{chunk-LJSNEV7M.js → chunk-Y3DOUQQQ.js} +8 -8
- package/{chunk-KOXKKHFE.js → chunk-Y5EBOURK.js} +10 -5
- package/{chunk-L5I543VB.js → chunk-YGDYYFRX.js} +20 -24
- package/{chunk-6OVNSQHN.js → chunk-YLAHYLDQ.js} +5 -0
- package/{chunk-PVZY6P3S.js → chunk-YTEY27GN.js} +2 -2
- package/chunk-YUZ2DAIH.js +34 -0
- package/chunk-Z6YTCDU4.js +24 -0
- package/{chunk-MOMR7NMG.js → chunk-ZCVBIIUE.js} +4 -4
- package/{chunk-AZQZ5XPM.js → chunk-ZCZLTJEW.js} +98 -57
- package/{chunk-KN3HEZIQ.js → chunk-ZVOL2MAJ.js} +1 -1
- package/{cliAgentConfigHelpers-KICKKNYQ.js → cliAgentConfigHelpers-6OFDHJFT.js} +13 -13
- package/{cliAuthorityBrokerClient-XHH7MH2P.js → cliAuthorityBrokerClient-SFPC3WVK.js} +1 -1
- package/{cliEnvHelpers-VPSJ4XWC.js → cliEnvHelpers-CNMP3RDX.js} +1 -1
- package/{cliExecutor-4MAX3PZL.js → cliExecutor-K6FDZTQ2.js} +3 -1
- package/cliLocalAgentRecordReader-FHIMCBUK.js +102 -0
- package/{commandRegistry-XSMTI5PG.js → commandRegistry-OKIWAJIS.js} +113 -101
- package/{contentThunks-S4NNC7R2.js → contentThunks-VF2DCU46.js} +41 -38
- package/{cooldownCommands-X7P5M2V5.js → cooldownCommands-QL6DWGVU.js} +4 -4
- package/{createAgentAutomationAction-TH7ZEACJ.js → createAgentAutomationAction-BGET7Q6K.js} +41 -38
- package/{createDialogAction-SYZAYIIQ.js → createDialogAction-XYDQZETK.js} +42 -40
- package/{createPageAction-7Y4U6TXO.js → createPageAction-74S5RO7U.js} +46 -43
- package/{db-CS4ZJQKV.js → db-6NRZLEW2.js} +10 -7
- package/{dbSlice-ZJPDIFER.js → dbSlice-FI7VNDR5.js} +14 -13
- package/{deleteFile-Q3YDB4ML.js → deleteFile-GD62MPZW.js} +10 -7
- package/{dialogCommands-V5IYEOQP.js → dialogCommands-Y6DHZUAM.js} +71 -64
- package/dialogMessageRecord-OAV77LT7.js +7 -0
- package/{dialogNotifyCommand-77B57PL6.js → dialogNotifyCommand-MKXL4NGL.js} +15 -15
- package/{dialogSlice-O3RHDAWK.js → dialogSlice-XAUKSWZ4.js} +41 -38
- package/{dialogUsageCommand-HTVPR2CX.js → dialogUsageCommand-BZPKR3DW.js} +6 -6
- package/{docCreateCommands-36WS33BK.js → docCreateCommands-PHDFOQBM.js} +66 -57
- package/{docDeleteCommands-C4CS4XLF.js → docDeleteCommands-OSHJM67Y.js} +69 -60
- package/{docReadCommands-QZMSFMPN.js → docReadCommands-E6QYCFMS.js} +66 -57
- package/{docStore-PYNEODAH.js → docStore-ZZT2BEBU.js} +16 -15
- package/{docUpdateCommands-BYI64HVV.js → docUpdateCommands-DHIOPK2C.js} +66 -57
- package/fetchMessages-TQEUZD7H.js +2 -2
- package/{getPricing-VNGFM4PN.js → getPricing-RNRITFOP.js} +6 -6
- package/{handleSendMessageAction-Z43FP2E2.js → handleSendMessageAction-ARUU6CNF.js} +83 -78
- package/{hostCredentialCreate-Y7YIGKP4.js → hostCredentialCreate-SNQT73H4.js} +131 -119
- package/index.js +56 -18
- package/keys-RWF7UCB4.js +1 -1
- package/{lib-OT5OTXRU.js → lib-62SWPXNF.js} +3 -7
- package/{localDialogRead-SVTPA5GY.js → localDialogRead-3T2KMCRC.js} +1 -1
- package/{localRuntimeAdapter-ZLJONQZS.js → localRuntimeAdapter-MHI6Y2IZ.js} +143 -130
- package/{localRuntimeAuthority-IBJAT62G.js → localRuntimeAuthority-7DKIT7UH.js} +4 -2
- package/{localRuntimeDb-N7KHDXS2.js → localRuntimeDb-5WZ4RJJO.js} +1 -1
- package/{machineCommands-4ZLMRIA3.js → machineCommands-3O6Y27R4.js} +283 -348
- package/machineWsRunDispatch-5PFLR5XC.js +203 -0
- package/markdownToSlate-KIYM7B3P.js +8 -0
- package/mcpLocalAuthorizeCommand-BQCQ2KRJ.js +106 -0
- package/{memberThunks-JRYNONYV.js → memberThunks-TU6A6OBV.js} +24 -19
- package/{memoryCommands-5WC3T66U.js → memoryCommands-BC6REPQB.js} +4 -4
- package/{models-H5NNZRLH.js → models-CINY5UZR.js} +2 -2
- package/{overlay-THLKYIWY.js → overlay-JA3SPVUS.js} +7 -3
- package/package.json +1 -1
- package/{projectArchive-JBX6HNK6.js → projectArchive-X2EVXU3N.js} +47 -44
- package/{providerPresetApply-J3WMRPD2.js → providerPresetApply-HUWNV2NI.js} +7 -7
- package/{providerRegistry-KJGB5XWS.js → providerRegistry-7FWKDKZJ.js} +7 -7
- package/{read-Q7GOHGNP.js → read-QAHEQID5.js} +9 -8
- package/{readDocTool-Z5OQ6422.js → readDocTool-KG5DP6EM.js} +1 -1
- package/{readlineWorkspace-WFPIAAAT.js → readlineWorkspace-SO3APHVP.js} +8125 -6196
- package/rememberExplicit-CPAPONSI.js +15 -0
- package/{removeDialogAgentAction-U3F2MNAY.js → removeDialogAgentAction-QZCCVK2G.js} +20 -19
- package/{runAgentClientLoop-STI5TKDJ.js → runAgentClientLoop-FLHHCOVH.js} +106 -81
- package/{runtimeDoctorCommands-UXKXYBW6.js → runtimeDoctorCommands-DN3I52C6.js} +17 -17
- package/{secretCommands-LJXOOYA7.js → secretCommands-36BCE3UE.js} +4 -4
- package/{setDialogExtraReferencesAction-G3WSJ7EM.js → setDialogExtraReferencesAction-PDPTYSEW.js} +17 -16
- package/{setPrimaryDialogAgentAction-6FHAHZBB.js → setPrimaryDialogAgentAction-DOUIPR66.js} +20 -19
- package/{settingThunks-AXTBX3Q5.js → settingThunks-MHGGP6UE.js} +186 -67
- package/{skillDiscovery-B5V23AXP.js → skillDiscovery-MDDKPTW3.js} +4 -3
- package/{spaceCommands-GUKMDRWN.js → spaceCommands-JH7UYE3K.js} +70 -61
- package/{store-JRVN62NM.js → store-Z53ICFL3.js} +3 -1
- package/{streamAgentChatTurn-A2WL5OOF.js → streamAgentChatTurn-VDDA2TX6.js} +200 -195
- package/{switchDialogAgentAction-UOFIAGPL.js → switchDialogAgentAction-7USK3DAP.js} +18 -17
- package/{tableCommands-HITDSLHS.js → tableCommands-UONBFC7L.js} +15 -12
- package/{toolApiClient-OGQEBQVX.js → toolApiClient-53YMJ2G6.js} +8 -6
- package/{tools-6NU5E6BN.js → tools-MIOCXKMG.js} +72 -68
- package/tuiRestart-ET3QISZ5.js +41 -0
- package/{tuiSummaryLlmCaller-7WLUKNP2.js → tuiSummaryLlmCaller-MSINBP3M.js} +21 -20
- package/{updateCommands-RJVCRSBP.js → updateCommands-5OYND6EF.js} +8 -6
- package/{updateDialogTitleAction-VMKU2Y67.js → updateDialogTitleAction-2L4CC4YO.js} +43 -40
- package/{usageCommand-YPJ2ZI2F.js → usageCommand-JTKDAG6I.js} +3 -3
- package/{usageRebuildCommand-FERQO74C.js → usageRebuildCommand-4TFZCKXM.js} +4 -4
- package/webapi-24RZDIIQ.js +2488 -0
- package/{windowsSelfUpdate-KERHIAB4.js → windowsSelfUpdate-HIYNL3VR.js} +2 -2
- package/workContext-Y3ADAPZU.js +14 -0
- package/workContextAccess-UZHDLBUR.js +11 -0
- package/workContextWriteNotice-YCSSMHN4.js +7 -0
- package/{workloadLifecycle-O2I3NZ2Q.js → workloadLifecycle-ZCSQCHG3.js} +9 -9
- package/agentListCommands-YBNOQ5T3.js +0 -991
- package/agentRecordCommands-3HL7Z4X6.js +0 -177
- package/agentRunCommand-C64A6MPL.js +0 -208
- package/chunk-2THCNKE4.js +0 -147
- package/chunk-2WZXXAQD.js +0 -57
- package/chunk-5ZMIIR23.js +0 -265
- package/chunk-652XYZGP.js +0 -352
- package/chunk-BJF2MHJ3.js +0 -118
- package/chunk-KEPOVMF4.js +0 -91
- package/chunk-QVBXJNZ2.js +0 -81
- package/chunk-QZI44GWV.js +0 -776
- package/cliLocalAgentRecordReader-6FXGFBI3.js +0 -90
- package/machineWsRunDispatch-L7Z3ULDF.js +0 -192
- package/{accountResolver-EK2S4PWF.js → accountResolver-QETKNC7T.js} +3 -3
- package/{chunk-W6RFEDN4.js → chunk-AETZ7AD6.js} +3 -3
- package/{chunk-BLVSFYQ3.js → chunk-LISC7BD4.js} +3 -3
- package/{chunk-SNBZZPYH.js → chunk-OQHIVPG4.js} +3 -3
- package/{chunk-47ITIXO7.js → chunk-USGHJSGO.js} +3 -3
- package/{chunk-FJ23FZXF.js → chunk-VIYVRPMJ.js} +0 -0
- package/{offlineMarxistsAgentCommand-4IC3Y4C6.js → offlineMarxistsAgentCommand-XVXUE6G5.js} +3 -3
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
builtinAgentCatalogEntryById,
|
|
13
13
|
catalogReleasedAtMs,
|
|
14
14
|
isRetiredCatalogEntry
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-WRKMXMU7.js";
|
|
16
16
|
import {
|
|
17
17
|
parsePublicAgentId,
|
|
18
18
|
parseSystemAgentId,
|
|
@@ -20,17 +20,17 @@ import {
|
|
|
20
20
|
} from "./chunk-M2EJHDJP.js";
|
|
21
21
|
import {
|
|
22
22
|
getModelPricing
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-Y3DOUQQQ.js";
|
|
24
24
|
import {
|
|
25
25
|
getModelConfig
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-OJRTTERA.js";
|
|
27
27
|
import {
|
|
28
28
|
isRecord
|
|
29
29
|
} from "./chunk-KUG52IAP.js";
|
|
30
30
|
import {
|
|
31
31
|
isNoloHostedProvider,
|
|
32
32
|
isPlatformHostedImageModel
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-U4VSBDO5.js";
|
|
34
34
|
|
|
35
35
|
// packages/core/publicAgentSeeds.ts
|
|
36
36
|
var AGENT_SEED_DEFAULTS = {
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
} from "./chunk-QYPE3TS3.js";
|
|
4
4
|
import {
|
|
5
5
|
getActiveDialogKey
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-I2OYPD3Y.js";
|
|
7
7
|
import {
|
|
8
8
|
selectIdentityToken
|
|
9
9
|
} from "./chunk-PXYBUFDB.js";
|
|
@@ -11,8 +11,8 @@ import {
|
|
|
11
11
|
compactWhitespace
|
|
12
12
|
} from "./chunk-DWLEOOGR.js";
|
|
13
13
|
import {
|
|
14
|
-
|
|
15
|
-
} from "./chunk-
|
|
14
|
+
splitDialogKeyIdentity
|
|
15
|
+
} from "./chunk-YZMNK53S.js";
|
|
16
16
|
import {
|
|
17
17
|
isRecord
|
|
18
18
|
} from "./chunk-KUG52IAP.js";
|
|
@@ -42,6 +42,54 @@ var selectCurrentTokenFromState = (state) => {
|
|
|
42
42
|
return typeof token === "string" ? token : null;
|
|
43
43
|
};
|
|
44
44
|
var selectCurrentDialogKeyFromState = (_state) => getActiveDialogKey();
|
|
45
|
+
var CONTROL_OR_WHITESPACE_RE = /[\u0000-\u001f\u007f\s]/;
|
|
46
|
+
var hasSuppliedDialogValue = (value) => value != null && (typeof value !== "string" || value.trim().length > 0);
|
|
47
|
+
var normalizeToolDialogId = (value) => {
|
|
48
|
+
if (typeof value !== "string") return null;
|
|
49
|
+
if (/[\u0000-\u001f\u007f]/.test(value)) return null;
|
|
50
|
+
const trimmed = value.trim();
|
|
51
|
+
if (!trimmed || CONTROL_OR_WHITESPACE_RE.test(trimmed)) return null;
|
|
52
|
+
if (trimmed.includes("-msg-")) return null;
|
|
53
|
+
if (trimmed.startsWith("dialog-")) {
|
|
54
|
+
const identity = splitDialogKeyIdentity(trimmed);
|
|
55
|
+
const parsedId = identity?.dialogId?.trim();
|
|
56
|
+
if (!parsedId || CONTROL_OR_WHITESPACE_RE.test(parsedId) || parsedId.includes("-msg-")) {
|
|
57
|
+
return null;
|
|
58
|
+
}
|
|
59
|
+
return parsedId;
|
|
60
|
+
}
|
|
61
|
+
return trimmed;
|
|
62
|
+
};
|
|
63
|
+
var resolveToolDialogId = (thunkApi, options = {}) => {
|
|
64
|
+
if (hasSuppliedDialogValue(options?.dialogId)) {
|
|
65
|
+
return normalizeToolDialogId(options.dialogId);
|
|
66
|
+
}
|
|
67
|
+
if (hasSuppliedDialogValue(options?.dialogKey)) {
|
|
68
|
+
return normalizeToolDialogId(options.dialogKey);
|
|
69
|
+
}
|
|
70
|
+
if (hasSuppliedDialogValue(thunkApi?.extra?.dialogId)) {
|
|
71
|
+
return normalizeToolDialogId(thunkApi.extra.dialogId);
|
|
72
|
+
}
|
|
73
|
+
if (hasSuppliedDialogValue(thunkApi?.extra?.dialogKey)) {
|
|
74
|
+
return normalizeToolDialogId(thunkApi.extra.dialogKey);
|
|
75
|
+
}
|
|
76
|
+
if (hasSuppliedDialogValue(thunkApi?.dialogId)) {
|
|
77
|
+
return normalizeToolDialogId(thunkApi.dialogId);
|
|
78
|
+
}
|
|
79
|
+
if (hasSuppliedDialogValue(thunkApi?.dialogKey)) {
|
|
80
|
+
return normalizeToolDialogId(thunkApi.dialogKey);
|
|
81
|
+
}
|
|
82
|
+
let state;
|
|
83
|
+
try {
|
|
84
|
+
state = typeof thunkApi?.getState === "function" ? thunkApi.getState() : void 0;
|
|
85
|
+
} catch {
|
|
86
|
+
state = void 0;
|
|
87
|
+
}
|
|
88
|
+
if (hasSuppliedDialogValue(state?.dialog?.currentDialogKey)) {
|
|
89
|
+
return normalizeToolDialogId(state.dialog.currentDialogKey);
|
|
90
|
+
}
|
|
91
|
+
return normalizeToolDialogId(selectCurrentDialogKeyFromState(state));
|
|
92
|
+
};
|
|
45
93
|
var resolveToolBaseUrl = (currentServer) => {
|
|
46
94
|
const _window = globalThis.window;
|
|
47
95
|
if (!_window) return (currentServer || "").replace(/\/+$/, "");
|
|
@@ -102,18 +150,6 @@ var getToolRequestContext = (thunkApi) => {
|
|
|
102
150
|
baseUrl
|
|
103
151
|
};
|
|
104
152
|
};
|
|
105
|
-
var maybeAttachDialogId = (thunkApi, body) => {
|
|
106
|
-
if (!isRecord(body)) return body;
|
|
107
|
-
if ("dialogId" in body) return body;
|
|
108
|
-
const state = thunkApi.getState();
|
|
109
|
-
const currentDialogKey = selectCurrentDialogKeyFromState(state);
|
|
110
|
-
const dialogId = currentDialogKey ? extractCustomId(currentDialogKey) : null;
|
|
111
|
-
if (!dialogId) return body;
|
|
112
|
-
return {
|
|
113
|
-
...body,
|
|
114
|
-
dialogId
|
|
115
|
-
};
|
|
116
|
-
};
|
|
117
153
|
var ToolApiError = class extends Error {
|
|
118
154
|
status;
|
|
119
155
|
code;
|
|
@@ -149,11 +185,26 @@ var buildToolRequestHeaders = (thunkApi, options = {}) => {
|
|
|
149
185
|
if (agentKey && typeof agentKey === "string" && agentKey.trim()) {
|
|
150
186
|
headers["X-Nolo-Agent-Key"] = agentKey.trim();
|
|
151
187
|
}
|
|
188
|
+
const dialogId = resolveToolDialogId(thunkApi, options);
|
|
189
|
+
if (dialogId) {
|
|
190
|
+
headers["X-Nolo-Dialog-Id"] = dialogId;
|
|
191
|
+
}
|
|
152
192
|
if (typeof window !== "undefined" && window.__NOLO_DESKTOP__) {
|
|
153
193
|
headers["X-Nolo-Desktop-Tool"] = "1";
|
|
154
194
|
}
|
|
155
195
|
return headers;
|
|
156
196
|
};
|
|
197
|
+
var buildToolRequestBody = (thunkApi, body, options) => {
|
|
198
|
+
if (!options.injectDialogId) return body;
|
|
199
|
+
if (!isRecord(body)) return body;
|
|
200
|
+
if ("dialogId" in body) return body;
|
|
201
|
+
const dialogId = resolveToolDialogId(thunkApi, options);
|
|
202
|
+
if (!dialogId) return body;
|
|
203
|
+
return {
|
|
204
|
+
...body,
|
|
205
|
+
dialogId
|
|
206
|
+
};
|
|
207
|
+
};
|
|
157
208
|
var buildResponsePreview = (text) => compactWhitespace(text).slice(0, 240);
|
|
158
209
|
var looksLikeHtmlResponse = (text, contentType) => {
|
|
159
210
|
if (contentType?.toLowerCase().includes("text/html")) return true;
|
|
@@ -171,7 +222,7 @@ async function callToolApi(thunkApi, path, body, options = {}) {
|
|
|
171
222
|
method,
|
|
172
223
|
headers,
|
|
173
224
|
...options.signal ? { signal: options.signal } : {},
|
|
174
|
-
...method === "GET" ? {} : { body: JSON.stringify(
|
|
225
|
+
...method === "GET" ? {} : { body: JSON.stringify(buildToolRequestBody(thunkApi, body, options)) }
|
|
175
226
|
});
|
|
176
227
|
const contentType = response.headers.get("content-type");
|
|
177
228
|
const responseText = await response.text();
|
|
@@ -226,6 +277,7 @@ async function callToolApi(thunkApi, path, body, options = {}) {
|
|
|
226
277
|
}
|
|
227
278
|
|
|
228
279
|
export {
|
|
280
|
+
resolveToolDialogId,
|
|
229
281
|
resolveToolBaseUrl,
|
|
230
282
|
resolveToolApiBaseUrl,
|
|
231
283
|
getRequestConfig,
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
// packages/agent-runtime/dialogMessageRecord.ts
|
|
2
|
+
function dialogMessageRecordToAgentRuntimeMessage(record) {
|
|
3
|
+
if (!record || typeof record !== "object") return null;
|
|
4
|
+
if (record.role !== "user" && record.role !== "assistant" && record.role !== "tool") return null;
|
|
5
|
+
return {
|
|
6
|
+
...typeof record.id === "string" ? { id: record.id } : {},
|
|
7
|
+
role: record.role,
|
|
8
|
+
...Number.isFinite(record.metadata?.cliHistoryOrder) ? { cliHistoryOrder: record.metadata.cliHistoryOrder } : {},
|
|
9
|
+
content: record.content ?? "",
|
|
10
|
+
...record.contextReference !== void 0 ? { context_reference: record.contextReference } : {},
|
|
11
|
+
...typeof record.reasoning_content === "string" ? { reasoning_content: record.reasoning_content } : {},
|
|
12
|
+
...typeof record.toolCallId === "string" ? { tool_call_id: record.toolCallId } : {},
|
|
13
|
+
...Array.isArray(record.tool_calls) ? { tool_calls: record.tool_calls } : {},
|
|
14
|
+
...record.toolPayload !== void 0 ? { toolPayload: record.toolPayload } : {},
|
|
15
|
+
...typeof record.toolName === "string" ? { toolName: record.toolName } : {},
|
|
16
|
+
// 写侧(dialogWritePlan)把 tool_result_metadata 以 `metadata` 字段落库;
|
|
17
|
+
// 回读必须还原,否则跨 turn 投影丢失 metadata 后缀,同一 tool 消息的字节
|
|
18
|
+
// 在 turn 边界漂移 → provider 前缀缓存断裂(stable projection 契约,
|
|
19
|
+
// 见 docs/plans/2026-09-05-tool-output-cache-stability.md)。
|
|
20
|
+
...record.metadata && typeof record.metadata === "object" ? { tool_result_metadata: record.metadata } : {},
|
|
21
|
+
...(() => {
|
|
22
|
+
const raw = record.createdAt;
|
|
23
|
+
const ms = typeof raw === "number" ? raw : typeof raw === "string" ? Date.parse(raw) : NaN;
|
|
24
|
+
return Number.isFinite(ms) ? { createdAt: ms } : {};
|
|
25
|
+
})()
|
|
26
|
+
};
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export {
|
|
30
|
+
dialogMessageRecordToAgentRuntimeMessage
|
|
31
|
+
};
|
|
@@ -0,0 +1,340 @@
|
|
|
1
|
+
import {
|
|
2
|
+
applyMemoryInterpreterMutation
|
|
3
|
+
} from "./chunk-6RSNVJGO.js";
|
|
4
|
+
import {
|
|
5
|
+
getMemoryEntityVNext,
|
|
6
|
+
getMemoryEvidenceVNextStrict,
|
|
7
|
+
getMemoryStateVNext,
|
|
8
|
+
listMemoryStatesForEntityVNext
|
|
9
|
+
} from "./chunk-324FWHUA.js";
|
|
10
|
+
import {
|
|
11
|
+
normalizeTopicKey
|
|
12
|
+
} from "./chunk-MVOZ22RZ.js";
|
|
13
|
+
import {
|
|
14
|
+
sha256Hex
|
|
15
|
+
} from "./chunk-SR4FE5VD.js";
|
|
16
|
+
|
|
17
|
+
// packages/ai/memory/vnext/rememberExplicit.ts
|
|
18
|
+
async function rememberExplicitVNext(db, item) {
|
|
19
|
+
const ownerId = `${item.ownerType}:${encodeURIComponent(item.ownerId)}`;
|
|
20
|
+
const topicKey = normalizeTopicKey(item.topicKey);
|
|
21
|
+
if (!topicKey) {
|
|
22
|
+
const digest = sha256Hex(
|
|
23
|
+
JSON.stringify([
|
|
24
|
+
ownerId,
|
|
25
|
+
item.subjectType,
|
|
26
|
+
item.subjectId,
|
|
27
|
+
item.kind,
|
|
28
|
+
item.content
|
|
29
|
+
])
|
|
30
|
+
);
|
|
31
|
+
const entityId2 = `explicit-${digest}`;
|
|
32
|
+
const stateId = `explicit-${digest}`;
|
|
33
|
+
let saved2;
|
|
34
|
+
await applyMemoryInterpreterMutation(db, ownerId, async () => {
|
|
35
|
+
const existing = await getMemoryStateVNext(db, ownerId, stateId);
|
|
36
|
+
if (existing?.retiredAt)
|
|
37
|
+
throw new Error("Explicit memory conflicts with a retired state");
|
|
38
|
+
const entity = await getMemoryEntityVNext(db, ownerId, entityId2);
|
|
39
|
+
const createdAt = existing?.createdAt ?? item.createdAt;
|
|
40
|
+
const oldValue = existing?.value && typeof existing.value === "object" ? existing.value : {};
|
|
41
|
+
const confidence = Math.max(
|
|
42
|
+
Number(oldValue.confidence) || 0,
|
|
43
|
+
item.confidence ?? 0
|
|
44
|
+
);
|
|
45
|
+
const resident = oldValue.resident === true || item.resident === true;
|
|
46
|
+
const evidenceId = `explicit-${digest}-${sha256Hex(
|
|
47
|
+
JSON.stringify([
|
|
48
|
+
item.confidence,
|
|
49
|
+
item.sourceDialogId ?? null,
|
|
50
|
+
item.provenance ?? null
|
|
51
|
+
])
|
|
52
|
+
).slice(0, 24)}`;
|
|
53
|
+
const evidence = await getMemoryEvidenceVNextStrict(
|
|
54
|
+
db,
|
|
55
|
+
ownerId,
|
|
56
|
+
evidenceId
|
|
57
|
+
);
|
|
58
|
+
saved2 = {
|
|
59
|
+
...item,
|
|
60
|
+
id: `vnext-state-${stateId}`,
|
|
61
|
+
createdAt,
|
|
62
|
+
confidence,
|
|
63
|
+
...resident ? { resident: true } : {}
|
|
64
|
+
};
|
|
65
|
+
return {
|
|
66
|
+
action: existing ? "update" : "create",
|
|
67
|
+
reason: "Explicit memory save",
|
|
68
|
+
entities: entity ? [] : [
|
|
69
|
+
{
|
|
70
|
+
id: entityId2,
|
|
71
|
+
ownerId,
|
|
72
|
+
type: "concept",
|
|
73
|
+
name: item.content,
|
|
74
|
+
createdAt,
|
|
75
|
+
updatedAt: createdAt
|
|
76
|
+
}
|
|
77
|
+
],
|
|
78
|
+
evidence: evidence ? [] : [
|
|
79
|
+
{
|
|
80
|
+
id: evidenceId,
|
|
81
|
+
ownerId,
|
|
82
|
+
text: item.content,
|
|
83
|
+
confidence: item.confidence,
|
|
84
|
+
...item.provenance ? { provenance: item.provenance } : {},
|
|
85
|
+
sourceRef: item.sourceDialogId ? `dialog:${item.sourceDialogId}` : `explicit:${digest}`,
|
|
86
|
+
createdAt
|
|
87
|
+
}
|
|
88
|
+
],
|
|
89
|
+
states: [
|
|
90
|
+
{
|
|
91
|
+
id: stateId,
|
|
92
|
+
ownerId,
|
|
93
|
+
entityId: entityId2,
|
|
94
|
+
facet: "explicit-memory",
|
|
95
|
+
text: item.content,
|
|
96
|
+
value: {
|
|
97
|
+
...oldValue,
|
|
98
|
+
kind: item.kind,
|
|
99
|
+
subjectType: item.subjectType,
|
|
100
|
+
subjectId: item.subjectId,
|
|
101
|
+
confidence,
|
|
102
|
+
resident,
|
|
103
|
+
visibility: item.visibility,
|
|
104
|
+
tags: item.tags,
|
|
105
|
+
importance: item.importance,
|
|
106
|
+
patternKey: item.patternKey,
|
|
107
|
+
recurrenceEvidence: item.recurrenceEvidence,
|
|
108
|
+
provenance: item.provenance,
|
|
109
|
+
sourceKind: item.sourceKind,
|
|
110
|
+
sourceDialogId: item.sourceDialogId
|
|
111
|
+
},
|
|
112
|
+
evidenceIds: [
|
|
113
|
+
.../* @__PURE__ */ new Set([...existing?.evidenceIds ?? [], evidenceId])
|
|
114
|
+
],
|
|
115
|
+
createdAt,
|
|
116
|
+
updatedAt: item.createdAt
|
|
117
|
+
}
|
|
118
|
+
]
|
|
119
|
+
};
|
|
120
|
+
});
|
|
121
|
+
return saved2;
|
|
122
|
+
}
|
|
123
|
+
const topicDigest = sha256Hex(
|
|
124
|
+
JSON.stringify([
|
|
125
|
+
ownerId,
|
|
126
|
+
item.subjectType,
|
|
127
|
+
item.subjectId,
|
|
128
|
+
item.kind,
|
|
129
|
+
topicKey
|
|
130
|
+
])
|
|
131
|
+
);
|
|
132
|
+
const entityId = `explicit-topic-${topicDigest}`;
|
|
133
|
+
const contentDigest = sha256Hex(
|
|
134
|
+
JSON.stringify([
|
|
135
|
+
ownerId,
|
|
136
|
+
item.subjectType,
|
|
137
|
+
item.subjectId,
|
|
138
|
+
item.kind,
|
|
139
|
+
item.content
|
|
140
|
+
])
|
|
141
|
+
);
|
|
142
|
+
let saved;
|
|
143
|
+
await applyMemoryInterpreterMutation(db, ownerId, async () => {
|
|
144
|
+
const entity = await getMemoryEntityVNext(db, ownerId, entityId);
|
|
145
|
+
const entityStates = (await listMemoryStatesForEntityVNext(db, ownerId, entityId)).filter((state) => state.facet === "explicit-memory");
|
|
146
|
+
const activeStates = entityStates.filter((state) => !state.retiredAt);
|
|
147
|
+
const matchingCurrent = activeStates.find(
|
|
148
|
+
(state) => state.text === item.content
|
|
149
|
+
);
|
|
150
|
+
if (matchingCurrent) {
|
|
151
|
+
const stateId2 = matchingCurrent.id;
|
|
152
|
+
const createdAt2 = matchingCurrent.createdAt;
|
|
153
|
+
const oldValue = matchingCurrent.value && typeof matchingCurrent.value === "object" ? matchingCurrent.value : {};
|
|
154
|
+
const confidence2 = Math.max(
|
|
155
|
+
Number(oldValue.confidence) || 0,
|
|
156
|
+
item.confidence ?? 0
|
|
157
|
+
);
|
|
158
|
+
const resident2 = oldValue.resident === true || item.resident === true;
|
|
159
|
+
const existingSupersedes = Array.isArray(oldValue.supersedesStateIds) ? oldValue.supersedesStateIds.map(String) : void 0;
|
|
160
|
+
const evidenceId2 = `${stateId2}-${sha256Hex(
|
|
161
|
+
JSON.stringify([
|
|
162
|
+
item.confidence,
|
|
163
|
+
item.sourceDialogId ?? null,
|
|
164
|
+
item.provenance ?? null
|
|
165
|
+
])
|
|
166
|
+
).slice(0, 24)}`;
|
|
167
|
+
const evidence2 = await getMemoryEvidenceVNextStrict(
|
|
168
|
+
db,
|
|
169
|
+
ownerId,
|
|
170
|
+
evidenceId2
|
|
171
|
+
);
|
|
172
|
+
saved = {
|
|
173
|
+
...item,
|
|
174
|
+
topicKey,
|
|
175
|
+
...existingSupersedes?.length ? { supersedesStateIds: existingSupersedes } : {},
|
|
176
|
+
id: `vnext-state-${stateId2}`,
|
|
177
|
+
createdAt: createdAt2,
|
|
178
|
+
confidence: confidence2,
|
|
179
|
+
...resident2 ? { resident: true } : {}
|
|
180
|
+
};
|
|
181
|
+
return {
|
|
182
|
+
action: "update",
|
|
183
|
+
reason: "Explicit memory save (topicKey idempotent update)",
|
|
184
|
+
entities: entity ? [] : [
|
|
185
|
+
{
|
|
186
|
+
id: entityId,
|
|
187
|
+
ownerId,
|
|
188
|
+
type: "concept",
|
|
189
|
+
subtype: "explicit-topic",
|
|
190
|
+
name: topicKey,
|
|
191
|
+
createdAt: createdAt2,
|
|
192
|
+
updatedAt: createdAt2
|
|
193
|
+
}
|
|
194
|
+
],
|
|
195
|
+
evidence: evidence2 ? [] : [
|
|
196
|
+
{
|
|
197
|
+
id: evidenceId2,
|
|
198
|
+
ownerId,
|
|
199
|
+
text: item.content,
|
|
200
|
+
confidence: item.confidence,
|
|
201
|
+
...item.provenance ? { provenance: item.provenance } : {},
|
|
202
|
+
sourceRef: item.sourceDialogId ? `dialog:${item.sourceDialogId}` : `explicit:${topicDigest}`,
|
|
203
|
+
createdAt: item.createdAt
|
|
204
|
+
}
|
|
205
|
+
],
|
|
206
|
+
states: [
|
|
207
|
+
{
|
|
208
|
+
id: stateId2,
|
|
209
|
+
ownerId,
|
|
210
|
+
entityId,
|
|
211
|
+
facet: "explicit-memory",
|
|
212
|
+
text: item.content,
|
|
213
|
+
value: {
|
|
214
|
+
...oldValue,
|
|
215
|
+
kind: item.kind,
|
|
216
|
+
subjectType: item.subjectType,
|
|
217
|
+
subjectId: item.subjectId,
|
|
218
|
+
confidence: confidence2,
|
|
219
|
+
resident: resident2,
|
|
220
|
+
visibility: item.visibility,
|
|
221
|
+
tags: item.tags,
|
|
222
|
+
importance: item.importance,
|
|
223
|
+
patternKey: item.patternKey,
|
|
224
|
+
recurrenceEvidence: item.recurrenceEvidence,
|
|
225
|
+
provenance: item.provenance,
|
|
226
|
+
sourceKind: item.sourceKind,
|
|
227
|
+
sourceDialogId: item.sourceDialogId,
|
|
228
|
+
topicKey,
|
|
229
|
+
...existingSupersedes?.length ? { supersedesStateIds: existingSupersedes } : {}
|
|
230
|
+
},
|
|
231
|
+
evidenceIds: [
|
|
232
|
+
.../* @__PURE__ */ new Set([...matchingCurrent.evidenceIds, evidenceId2])
|
|
233
|
+
],
|
|
234
|
+
createdAt: createdAt2,
|
|
235
|
+
updatedAt: item.createdAt
|
|
236
|
+
}
|
|
237
|
+
]
|
|
238
|
+
};
|
|
239
|
+
}
|
|
240
|
+
const supersededIds = activeStates.map((state) => state.id);
|
|
241
|
+
const isSupersede = supersededIds.length > 0;
|
|
242
|
+
const version = entityStates.length + 1;
|
|
243
|
+
const stateId = `explicit-topic-${topicDigest.slice(0, 24)}-v${version}-${contentDigest.slice(0, 16)}`;
|
|
244
|
+
const createdAt = item.createdAt;
|
|
245
|
+
const confidence = item.confidence ?? 0;
|
|
246
|
+
const resident = item.resident === true;
|
|
247
|
+
const evidenceId = `${stateId}-${sha256Hex(
|
|
248
|
+
JSON.stringify([
|
|
249
|
+
item.confidence,
|
|
250
|
+
item.sourceDialogId ?? null,
|
|
251
|
+
item.provenance ?? null
|
|
252
|
+
])
|
|
253
|
+
).slice(0, 24)}`;
|
|
254
|
+
const evidence = await getMemoryEvidenceVNextStrict(
|
|
255
|
+
db,
|
|
256
|
+
ownerId,
|
|
257
|
+
evidenceId
|
|
258
|
+
);
|
|
259
|
+
const relations = supersededIds.map(
|
|
260
|
+
(oldId, idx) => ({
|
|
261
|
+
id: `rel-supersedes-${stateId}-${idx}`,
|
|
262
|
+
ownerId,
|
|
263
|
+
from: stateId,
|
|
264
|
+
type: "supersedes",
|
|
265
|
+
to: oldId,
|
|
266
|
+
createdAt
|
|
267
|
+
})
|
|
268
|
+
);
|
|
269
|
+
saved = {
|
|
270
|
+
...item,
|
|
271
|
+
topicKey,
|
|
272
|
+
...isSupersede ? { supersedesStateIds: supersededIds } : {},
|
|
273
|
+
id: `vnext-state-${stateId}`,
|
|
274
|
+
createdAt,
|
|
275
|
+
confidence,
|
|
276
|
+
...resident ? { resident: true } : {}
|
|
277
|
+
};
|
|
278
|
+
return {
|
|
279
|
+
action: isSupersede ? "supersede" : "create",
|
|
280
|
+
reason: isSupersede ? "Explicit memory topicKey supersede" : "Explicit memory save (topicKey)",
|
|
281
|
+
entities: entity ? [] : [
|
|
282
|
+
{
|
|
283
|
+
id: entityId,
|
|
284
|
+
ownerId,
|
|
285
|
+
type: "concept",
|
|
286
|
+
subtype: "explicit-topic",
|
|
287
|
+
name: topicKey,
|
|
288
|
+
createdAt,
|
|
289
|
+
updatedAt: createdAt
|
|
290
|
+
}
|
|
291
|
+
],
|
|
292
|
+
evidence: evidence ? [] : [
|
|
293
|
+
{
|
|
294
|
+
id: evidenceId,
|
|
295
|
+
ownerId,
|
|
296
|
+
text: item.content,
|
|
297
|
+
confidence: item.confidence,
|
|
298
|
+
...item.provenance ? { provenance: item.provenance } : {},
|
|
299
|
+
sourceRef: item.sourceDialogId ? `dialog:${item.sourceDialogId}` : `explicit:${topicDigest}`,
|
|
300
|
+
createdAt
|
|
301
|
+
}
|
|
302
|
+
],
|
|
303
|
+
states: [
|
|
304
|
+
{
|
|
305
|
+
id: stateId,
|
|
306
|
+
ownerId,
|
|
307
|
+
entityId,
|
|
308
|
+
facet: "explicit-memory",
|
|
309
|
+
text: item.content,
|
|
310
|
+
value: {
|
|
311
|
+
kind: item.kind,
|
|
312
|
+
subjectType: item.subjectType,
|
|
313
|
+
subjectId: item.subjectId,
|
|
314
|
+
confidence,
|
|
315
|
+
resident,
|
|
316
|
+
visibility: item.visibility,
|
|
317
|
+
tags: item.tags,
|
|
318
|
+
importance: item.importance,
|
|
319
|
+
patternKey: item.patternKey,
|
|
320
|
+
recurrenceEvidence: item.recurrenceEvidence,
|
|
321
|
+
provenance: item.provenance,
|
|
322
|
+
sourceKind: item.sourceKind,
|
|
323
|
+
sourceDialogId: item.sourceDialogId,
|
|
324
|
+
topicKey,
|
|
325
|
+
...isSupersede ? { supersedesStateIds: supersededIds } : {}
|
|
326
|
+
},
|
|
327
|
+
evidenceIds: [evidenceId],
|
|
328
|
+
createdAt,
|
|
329
|
+
updatedAt: item.createdAt
|
|
330
|
+
}
|
|
331
|
+
],
|
|
332
|
+
...isSupersede ? { supersededStateIds: supersededIds, relations } : {}
|
|
333
|
+
};
|
|
334
|
+
});
|
|
335
|
+
return saved;
|
|
336
|
+
}
|
|
337
|
+
|
|
338
|
+
export {
|
|
339
|
+
rememberExplicitVNext
|
|
340
|
+
};
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
fetchReferenceContents,
|
|
3
3
|
resolveReferenceAssets
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-6S6CZUXK.js";
|
|
5
5
|
import {
|
|
6
6
|
updateTokensAction
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-ODGSLWLO.js";
|
|
8
8
|
import {
|
|
9
9
|
applyUpdateTokensFulfilled
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-I2OYPD3Y.js";
|
|
11
11
|
import {
|
|
12
12
|
extractReasoningFromResponseOutput,
|
|
13
13
|
extractTextFromResponseOutput,
|
|
14
14
|
extractToolCallsFromResponseOutput
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-F4MCAOWN.js";
|
|
16
16
|
import {
|
|
17
17
|
isRecord
|
|
18
18
|
} from "./chunk-KUG52IAP.js";
|