nolo-cli 0.33.0-alpha.9 → 0.34.0-alpha.3
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/{_executeModel-2WR4RTZZ.js → _executeModel-TMUXL7J5.js} +64 -65
- package/{action-OQWPNKAH.js → action-KMBZ3LCZ.js} +12 -12
- package/{addContentAction-YVINZQTF.js → addContentAction-KQ44UT2U.js} +10 -10
- package/{addDialogAgentAction-6IOCIEPI.js → addDialogAgentAction-ILSDCMYL.js} +9 -9
- package/{agentDeleteCommand-H22WRYC6.js → agentDeleteCommand-KA2IQAPG.js} +40 -39
- package/{agentEmailCommands-DGJVCMCG.js → agentEmailCommands-UIYBGCZW.js} +74 -75
- package/{agentListCommands-6NWMLIMQ.js → agentListCommands-L6JNUOLH.js} +47 -37
- package/{agentMachineCommands-5MUO6RDI.js → agentMachineCommands-5CQW5NZR.js} +37 -36
- package/agentProviderCommands-65ZC2WB4.js +122 -0
- package/{agentPullCommand-YH5GEBK4.js → agentPullCommand-TSWAJPS2.js} +1 -1
- package/agentRecordCommands-VUDJQIZH.js +112 -0
- package/agentRunCommand-EJWYF3BL.js +132 -0
- package/{agentRunControl-SCIVRZWX.js → agentRunControl-7MUPSYDQ.js} +7 -1
- package/{agentRuntimeLocal-PRAR3NCW.js → agentRuntimeLocal-XXBMDMBU.js} +33 -33
- package/{agentSlice-AMDSTXP5.js → agentSlice-HTIEYKIU.js} +12 -12
- package/agentSuperviseCommands-MKWW3ICX.js +640 -0
- package/{appDeleteCommands-L5PKC42V.js → appDeleteCommands-OUBL6VHB.js} +35 -34
- package/{appDeployCommands-3J7Z4XWV.js → appDeployCommands-BZSS2MX4.js} +35 -34
- package/{appDeployStatusCommands-YTRPXE72.js → appDeployStatusCommands-P2ZQOY5X.js} +35 -34
- package/{appGetCommands-JVXV5WXD.js → appGetCommands-WCFWQZZM.js} +35 -34
- package/{appListCommands-7KDEOJSO.js → appListCommands-FVJ3QNL7.js} +35 -34
- package/{authCommand-6Y5LTMZB.js → authCommand-B2XRHNJH.js} +19 -19
- package/{authCommands-EAPFGNHN.js → authCommands-GWABTFMR.js} +6 -6
- package/{chatQueueReduxAdapter-ZKSS6XRV.js → chatQueueReduxAdapter-ZP2ZS63U.js} +28 -28
- package/{chunk-UM4H3URE.js → chunk-23KKIMD5.js} +7 -7
- package/chunk-2BWU4ORW.js +2574 -0
- package/{chunk-2UECQ7RE.js → chunk-3AOLVADY.js} +1 -1
- package/{chunk-M2YMQOLC.js → chunk-4APLX2RT.js} +75 -10
- package/{chunk-ZHYK3N56.js → chunk-4AWH4LQA.js} +3 -1
- package/{chunk-3GZXL6FM.js → chunk-4DMPISV6.js} +7 -3
- package/{chunk-BQ3OHLR5.js → chunk-5GQ6XCJY.js} +1217 -691
- package/{chunk-GOIDVXK5.js → chunk-5LDKQUOT.js} +21 -8
- package/{chunk-OIQPORYI.js → chunk-64KIQZA2.js} +175 -2
- package/{chunk-6XIE5ZGI.js → chunk-6HIGYUBQ.js} +1 -1
- package/chunk-6XG52ZQ6.js +146 -0
- package/{chunk-FMEVI5TG.js → chunk-7CH6U3FL.js} +1 -1
- package/chunk-AA2YUJNV.js +54 -0
- package/{chunk-7INB7NXF.js → chunk-AE5GVFMG.js} +294 -54
- package/{chunk-UNOTBWZZ.js → chunk-B6H5XCT2.js} +8 -8
- package/{chunk-NNWHHCVP.js → chunk-BMB563Y6.js} +10 -4
- package/{chunk-DFUPZE6V.js → chunk-C6ELZQ7H.js} +249 -34
- package/{chunk-7KNERA53.js → chunk-E2OQ5N2F.js} +87 -13
- package/{chunk-6HYVJV7B.js → chunk-ESHYE7WU.js} +2 -1
- package/{chunk-KHCLMKZZ.js → chunk-EY7V7REW.js} +280 -6
- package/{chunk-JZPBVBIY.js → chunk-FD36SCCD.js} +19 -8
- package/{chunk-DKMOY3QI.js → chunk-FGLKRJDI.js} +54 -3
- package/{chunk-MQWVAOIU.js → chunk-FT4XBCK4.js} +33 -158
- package/{chunk-2QTEYCR7.js → chunk-FTM4KUOZ.js} +17 -17
- package/{chunk-U4TRT5V4.js → chunk-GEPHJJW4.js} +1 -1
- package/{chunk-7YYHKBJP.js → chunk-GKHV4UH5.js} +1 -1
- package/{chunk-2IVEXF7P.js → chunk-GUYMR3JL.js} +6 -33
- package/{chunk-YDTYDA5W.js → chunk-GZRMWK5R.js} +6 -4
- package/{chunk-X664KVEV.js → chunk-HHBXCRJS.js} +204 -123
- package/{chunk-AN7DGYMW.js → chunk-I7VDDN45.js} +4579 -3131
- package/{chunk-DSBGWT2C.js → chunk-IEEEWIVO.js} +10 -10
- package/{chunk-75U775RZ.js → chunk-IFS5CUEH.js} +1 -1
- package/{chunk-WLH5BAKX.js → chunk-IIOHYLIG.js} +9 -4
- package/{chunk-UEAUAXYS.js → chunk-ILZY5B4U.js} +2063 -214
- package/chunk-IMHO5LC6.js +370 -0
- package/{chunk-ADLYMQB6.js → chunk-IZCHPD7T.js} +52 -3
- package/{chunk-ITIA6OAQ.js → chunk-IZNJDUJ4.js} +5 -5
- package/{chunk-X2DAEZ3X.js → chunk-J5NMOM35.js} +1 -1
- package/{chunk-RPRRIFXV.js → chunk-JI2TIPLP.js} +1 -1
- package/{chunk-EGRJC4ZN.js → chunk-JIADXJYU.js} +1 -1
- package/{chunk-IHEC7VBF.js → chunk-K4KIFRIN.js} +1 -1
- package/{chunk-WJSW43QZ.js → chunk-L3JWI7WX.js} +0 -1
- package/{chunk-3RUW3ONU.js → chunk-LD6Y6RJY.js} +4 -4
- package/chunk-M3JQWYBC.js +387 -0
- package/{chunk-GM6PU7B6.js → chunk-MEYIRKDN.js} +0 -1
- package/{chunk-6YXDOOSH.js → chunk-MGIHZ5CJ.js} +4 -4
- package/{chunk-4F5M2MW5.js → chunk-MJWX4JQO.js} +2 -2
- package/{chunk-Q5ITEGIN.js → chunk-N4XRDM26.js} +1 -1
- package/{chunk-5CS33IBL.js → chunk-NQ4N4IGO.js} +11 -12
- package/{chunk-ZZ2MH7LE.js → chunk-O6OSWFZQ.js} +0 -1
- package/{chunk-RJKIB55Y.js → chunk-OSCSEJJR.js} +15 -8
- package/{chunk-HUCT7HID.js → chunk-P2I7ELDC.js} +3 -3
- package/{chunk-BXPBZVRE.js → chunk-PILJX4DH.js} +285 -251
- package/{chunk-SCUETSRP.js → chunk-PV734VZX.js} +1 -1
- package/{chunk-XLLTJXAD.js → chunk-QI3CHZUT.js} +39 -2672
- package/{chunk-WNHST4IE.js → chunk-RKRXAL3V.js} +5451 -5013
- package/{chunk-7E72JMBB.js → chunk-SMPAUSX5.js} +46 -5
- package/{chunk-5X4GQ53C.js → chunk-TLBZMLLJ.js} +7 -7
- package/{chunk-ASDXPOJH.js → chunk-U6QQLXWI.js} +1 -1
- package/{chunk-NUO3QFWD.js → chunk-UNHKVD2N.js} +1 -1
- package/{chunk-GE6IWA5N.js → chunk-UNZDCI3O.js} +126 -1
- package/{chunk-CPYYM4RJ.js → chunk-V5GA74HI.js} +19 -5
- package/{chunk-FXFGNOT2.js → chunk-VFVCYIRQ.js} +1 -1
- package/{chunk-G7E4NWFE.js → chunk-W445DPVT.js} +1 -1
- package/{chunk-EMW55KKX.js → chunk-WBZE7C6S.js} +1 -1
- package/{chunk-3UG2IIZ3.js → chunk-WN5AJG5I.js} +1 -1
- package/{chunk-KSRFVP36.js → chunk-WRN7L5CS.js} +1 -1
- package/{chunk-GJXRIOLS.js → chunk-WRP5TTM6.js} +4 -84
- package/chunk-X2K2JSO4.js +163 -0
- package/{chunk-OR2HNLVO.js → chunk-X6EN3KJX.js} +279 -477
- package/{chunk-VWY2CZD2.js → chunk-XMFDQYWA.js} +3 -3
- package/{chunk-IKWTTKWG.js → chunk-XQES6LXQ.js} +2 -2
- package/{chunk-IR6W62Q6.js → chunk-XT73C4VH.js} +18 -21
- package/{chunk-7L5CQQIT.js → chunk-Y5W623XU.js} +15 -15
- package/{chunk-RY57GLGW.js → chunk-YPREESF4.js} +42 -5
- package/{chunk-BQXOGBFN.js → chunk-YZ2WE6CW.js} +2 -2
- package/{chunk-DNQK7M7K.js → chunk-Z7COG62J.js} +4 -4
- package/{chunk-3WXRAHCG.js → chunk-ZBB3MZR3.js} +3 -3
- package/{cliExecutor-DW3PHGEL.js → cliExecutor-BBUVQU4L.js} +2 -2
- package/{clipboardy-MMBYVRLF.js → clipboardy-PRUHGPGC.js} +4 -3
- package/{codingSkills-DY5MINPG.js → codingSkills-6F4EQFCM.js} +4 -5
- package/cooldownCommands-C2SZLEEO.js +90 -0
- package/{createAgentAutomationAction-GVSJL2CI.js → createAgentAutomationAction-TGUXUZCY.js} +28 -30
- package/createDialogAction-FD5AEOUF.js +58 -0
- package/{createPageAction-M2VDKBYS.js → createPageAction-NPC3LYNK.js} +31 -34
- package/{dbSlice-UI2VCBLG.js → dbSlice-PIQGICNM.js} +9 -9
- package/{deleteFile-XQXPBFFB.js → deleteFile-NPZ64DFN.js} +4 -4
- package/{dialogCommands-26DBYNBT.js → dialogCommands-ZF2RSNCG.js} +37 -36
- package/{dialogSlice-FFGLRCBL.js → dialogSlice-6BINHWQT.js} +27 -27
- package/dist-VODFSGNG.js +7442 -0
- package/{docCreateCommands-F2ASWG6B.js → docCreateCommands-4VQ5MOHP.js} +36 -36
- package/{docDeleteCommands-A4URDZPI.js → docDeleteCommands-M7WLNVPB.js} +37 -37
- package/{docReadCommands-DO6VHDZD.js → docReadCommands-6LU6P2WT.js} +36 -36
- package/{docStore-EDAE7RNT.js → docStore-SIUFLABN.js} +29 -31
- package/{docUpdateCommands-ZTXZ3RTP.js → docUpdateCommands-S2LX4ENL.js} +39 -39
- package/{fetchMessages-7QRCCRYK.js → fetchMessages-CUEFN4GQ.js} +4 -4
- package/{getPricing-L2ENXWHV.js → getPricing-P3E2WRIH.js} +5 -5
- package/{handleSendMessageAction-CIRLGHOC.js → handleSendMessageAction-QVG5YNZY.js} +29 -29
- package/index.js +92 -77
- package/{localDialogRead-SLMPV5SK.js → localDialogRead-P7CHFMIC.js} +1 -1
- package/{localRuntimeAuthority-E3R24J4T.js → localRuntimeAuthority-S77B5QVB.js} +6 -2
- package/{localRuntimeDb-DDZCJFQZ.js → localRuntimeDb-N3H3HQ7G.js} +1 -1
- package/{machineCommands-NIQNCYJV.js → machineCommands-OSEBN7BZ.js} +76 -77
- package/{machineInfo-M6KB6HZN.js → machineInfo-66ZFUMLE.js} +1 -1
- package/{machineWsRunDispatch-EMTSQGAR.js → machineWsRunDispatch-NTJQCIIF.js} +68 -69
- package/{models-OX2S5C6Q.js → models-L7S2EKPM.js} +2 -2
- package/package.json +1 -1
- package/{read-2VHEHCAN.js → read-6C2XD3YZ.js} +5 -5
- package/{readDocTool-CSWD6NPC.js → readDocTool-Y7AB365O.js} +1 -1
- package/{readlineWorkspace-A2JBJWLI.js → readlineWorkspace-JPME5S7A.js} +4860 -3476
- package/{removeDialogAgentAction-2T7BPM3T.js → removeDialogAgentAction-KG5WMJRZ.js} +13 -13
- package/{runAgentClientLoop-BV4736ED.js → runAgentClientLoop-SOKEXCUF.js} +61 -61
- package/{runtimeDoctorCommands-KIKM6BIO.js → runtimeDoctorCommands-HT4O2PXL.js} +6 -6
- package/{setDialogExtraReferencesAction-GPT37HTW.js → setDialogExtraReferencesAction-O2NLXMSM.js} +10 -10
- package/{setPrimaryDialogAgentAction-3746P7IW.js → setPrimaryDialogAgentAction-FYYUY7PB.js} +13 -13
- package/{settingSlice-FIFOQ6OR.js → settingSlice-GPLI6E3M.js} +11 -11
- package/{skillDiscovery-KLLKXPUO.js → skillDiscovery-GPUDHDTZ.js} +3 -4
- package/{slateUtils-VO2FU36K.js → slateUtils-RIZES3PV.js} +1 -1
- package/{spaceCommands-AYZQHDB3.js → spaceCommands-Z5JLMFFJ.js} +223 -37
- package/{spaceSlice-43BNF22B.js → spaceSlice-Z3BGCLGX.js} +28 -30
- package/{streamAgentChatTurn-OLLRSITV.js → streamAgentChatTurn-INF5RGK4.js} +115 -129
- package/{switchDialogAgentAction-MQTUTQHL.js → switchDialogAgentAction-GH5P6Q3Z.js} +9 -9
- package/{chunk-IDAU4UFS.js → syncMapping-N6RGXGBW.js} +11 -11
- package/{tableCommands-QE47K72R.js → tableCommands-PQUJ55AS.js} +3 -3
- package/{tools-2SI3FXLL.js → tools-ZELMSJZ3.js} +45 -47
- package/{tuiSummaryLlmCaller-EAWQ3IZX.js → tuiSummaryLlmCaller-LH7F2SP7.js} +18 -18
- package/{updateCommands-AK2RDOFR.js → updateCommands-MNDUIKN7.js} +2 -2
- package/{updateDialogTitleAction-YJEQFYOA.js → updateDialogTitleAction-EDUCIB7G.js} +31 -33
- package/agentRecordCommands-YMGKT2WF.js +0 -113
- package/agentRunCommand-LYEMVQJH.js +0 -131
- package/chunk-AETZ7AD6.js +0 -274
- package/chunk-D5JI6VDM.js +0 -1800
- package/chunk-M3JEW6N6.js +0 -193
- package/chunk-ZURFOV5J.js +0 -105
- package/chunk-ZWS6DUHX.js +0 -480
- package/createDialogAction-VVR46Q2A.js +0 -61
- package/syncMapping-RK2MANUX.js +0 -43
- package/{chunk-KMSZPTM6.js → chunk-2WKUUY2E.js} +3 -3
- package/{chunk-CWMSB67P.js → chunk-AGGIDPCZ.js} +0 -0
- package/{chunk-SAQQLJZ5.js → chunk-JDSUTNYY.js} +3 -3
|
@@ -7,11 +7,11 @@ import {
|
|
|
7
7
|
listUserRecordsFromServers,
|
|
8
8
|
readDbRecordFromServers,
|
|
9
9
|
readLiveDbRecordAfterTombstoneMerge
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-K4KIFRIN.js";
|
|
11
11
|
import {
|
|
12
12
|
buildDialogAttachmentPlan,
|
|
13
13
|
extractFileContentIds
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-JIADXJYU.js";
|
|
15
15
|
import {
|
|
16
16
|
isLevelLockError
|
|
17
17
|
} from "./chunk-URMS4XY2.js";
|
|
@@ -36,6 +36,9 @@ import {
|
|
|
36
36
|
asNonEmptyStringArray,
|
|
37
37
|
asTrimmedNonEmptyStringArray
|
|
38
38
|
} from "./chunk-I42VC5KR.js";
|
|
39
|
+
import {
|
|
40
|
+
isRecord
|
|
41
|
+
} from "./chunk-KUG52IAP.js";
|
|
39
42
|
import {
|
|
40
43
|
isLevelNotFoundError
|
|
41
44
|
} from "./chunk-OW765XBU.js";
|
|
@@ -43,8 +46,8 @@ import {
|
|
|
43
46
|
asTrimmedString
|
|
44
47
|
} from "./chunk-3EUW3WEO.js";
|
|
45
48
|
import {
|
|
46
|
-
|
|
47
|
-
} from "./chunk-
|
|
49
|
+
DEFAULT_LOCAL_API_ORIGIN
|
|
50
|
+
} from "./chunk-4SN6J65J.js";
|
|
48
51
|
import {
|
|
49
52
|
asOptionalTrimmedString
|
|
50
53
|
} from "./chunk-G3SUCT4W.js";
|
|
@@ -545,6 +548,7 @@ async function readDialogOverHttp(args) {
|
|
|
545
548
|
Authorization: `Bearer ${args.authToken}`,
|
|
546
549
|
"Content-Type": "application/json"
|
|
547
550
|
};
|
|
551
|
+
const buildGetConvMsgsBody = () => JSON.stringify({ dialogId: args.dialogId, dialogKey: args.dialogKey, limit: args.limit });
|
|
548
552
|
const readViaBridge = async () => {
|
|
549
553
|
const bridgeRes = await args.fetchImpl(`${args.base}/api/dialog-read`, {
|
|
550
554
|
method: "POST",
|
|
@@ -574,6 +578,21 @@ async function readDialogOverHttp(args) {
|
|
|
574
578
|
source: "http"
|
|
575
579
|
};
|
|
576
580
|
};
|
|
581
|
+
if (args.messagesOnly) {
|
|
582
|
+
const msgsOnlyRes = await args.fetchImpl(`${args.base}/rpc/getConvMsgs`, {
|
|
583
|
+
method: "POST",
|
|
584
|
+
headers: authHeaders,
|
|
585
|
+
body: buildGetConvMsgsBody()
|
|
586
|
+
});
|
|
587
|
+
if (!msgsOnlyRes.ok) {
|
|
588
|
+
if (msgsOnlyRes.status === 401 || msgsOnlyRes.status === 403) return readViaBridge();
|
|
589
|
+
throw Object.assign(new Error(`read dialog messages failed: HTTP ${msgsOnlyRes.status}`), {
|
|
590
|
+
status: msgsOnlyRes.status,
|
|
591
|
+
base: args.base
|
|
592
|
+
});
|
|
593
|
+
}
|
|
594
|
+
return { meta: null, msgs: await msgsOnlyRes.json(), source: "http" };
|
|
595
|
+
}
|
|
577
596
|
const metaRes = await args.fetchImpl(
|
|
578
597
|
`${args.base}/api/v1/db/read/${encodeURIComponent(args.dialogKey)}`,
|
|
579
598
|
{ headers: { Authorization: `Bearer ${args.authToken}` } }
|
|
@@ -589,7 +608,7 @@ async function readDialogOverHttp(args) {
|
|
|
589
608
|
const msgsRes = await args.fetchImpl(`${args.base}/rpc/getConvMsgs`, {
|
|
590
609
|
method: "POST",
|
|
591
610
|
headers: authHeaders,
|
|
592
|
-
body:
|
|
611
|
+
body: buildGetConvMsgsBody()
|
|
593
612
|
});
|
|
594
613
|
if (!msgsRes.ok) {
|
|
595
614
|
if (msgsRes.status === 401 || msgsRes.status === 403) return readViaBridge();
|
|
@@ -623,7 +642,7 @@ async function tryHttpDialogCandidates(args) {
|
|
|
623
642
|
throw Object.assign(new Error("All HTTP dialog reads failed"), { attempts });
|
|
624
643
|
}
|
|
625
644
|
async function readDialogFromLocalDb(dialogKey, dialogId, limit, readLocalDialog) {
|
|
626
|
-
const reader = readLocalDialog ?? (await import("./localDialogRead-
|
|
645
|
+
const reader = readLocalDialog ?? (await import("./localDialogRead-P7CHFMIC.js")).readDialogFromLocalDb;
|
|
627
646
|
const result = await reader({ dialogKey, dialogId, limit });
|
|
628
647
|
return {
|
|
629
648
|
...result,
|
|
@@ -631,7 +650,10 @@ async function readDialogFromLocalDb(dialogKey, dialogId, limit, readLocalDialog
|
|
|
631
650
|
};
|
|
632
651
|
}
|
|
633
652
|
async function readDialogSnapshot(args) {
|
|
634
|
-
const candidateBases =
|
|
653
|
+
const candidateBases = [
|
|
654
|
+
...resolveServerCandidates({ NOLO_SERVER: args.base }, args.base),
|
|
655
|
+
DEFAULT_LOCAL_API_ORIGIN
|
|
656
|
+
].filter((value, index, all) => all.indexOf(value) === index);
|
|
635
657
|
try {
|
|
636
658
|
const local = await readDialogFromLocalDb(
|
|
637
659
|
args.dialogKey,
|
|
@@ -662,7 +684,8 @@ async function readDialogSnapshot(args) {
|
|
|
662
684
|
dialogId: args.dialogId,
|
|
663
685
|
limit: args.limit,
|
|
664
686
|
authToken: args.authToken,
|
|
665
|
-
fetchImpl: args.fetchImpl
|
|
687
|
+
fetchImpl: args.fetchImpl,
|
|
688
|
+
messagesOnly: args.messagesOnly
|
|
666
689
|
});
|
|
667
690
|
return { ...result, candidateBases };
|
|
668
691
|
}
|
|
@@ -899,6 +922,48 @@ async function readSpaceDialogRecords(args) {
|
|
|
899
922
|
const failures = [...spaceRead.failures, ...dialogResult.failures];
|
|
900
923
|
return { spaceId, records, failures };
|
|
901
924
|
}
|
|
925
|
+
var MAX_ATTEMPT_LINES = 5;
|
|
926
|
+
function formatDialogReadFailure(error) {
|
|
927
|
+
const message = toErrorMessage(error);
|
|
928
|
+
const attempts = typeof error === "object" && error !== null && Array.isArray(error.attempts) ? error.attempts : [];
|
|
929
|
+
const lines = [`[nolo] dialog read failed: ${message}`];
|
|
930
|
+
if (attempts.length > 0) {
|
|
931
|
+
const seen = /* @__PURE__ */ new Set();
|
|
932
|
+
const deduped = [];
|
|
933
|
+
for (const attempt of attempts) {
|
|
934
|
+
const key = `${attempt.base}|${attempt.status ?? ""}|${attempt.message ?? ""}`;
|
|
935
|
+
if (seen.has(key)) continue;
|
|
936
|
+
seen.add(key);
|
|
937
|
+
deduped.push(attempt);
|
|
938
|
+
if (deduped.length >= MAX_ATTEMPT_LINES) break;
|
|
939
|
+
}
|
|
940
|
+
lines.push(" attempts:");
|
|
941
|
+
for (const attempt of deduped) {
|
|
942
|
+
const status = attempt.status != null ? ` HTTP ${attempt.status}` : "";
|
|
943
|
+
const detail = attempt.message ? ` \u2014 ${attempt.message}` : "";
|
|
944
|
+
lines.push(` - ${attempt.base}${status}${detail}`);
|
|
945
|
+
}
|
|
946
|
+
if (attempts.length > deduped.length) {
|
|
947
|
+
lines.push(` \u2026 and ${attempts.length - deduped.length} more`);
|
|
948
|
+
}
|
|
949
|
+
}
|
|
950
|
+
const allNotFound = attempts.length > 0 && attempts.every((attempt) => attempt.status === 404);
|
|
951
|
+
const hasConnRefusedOrTimeout = attempts.some((attempt) => {
|
|
952
|
+
const text = `${attempt.status ?? ""} ${attempt.message ?? ""}`.toLowerCase();
|
|
953
|
+
return text.includes("connection refused") || text.includes("econnrefused") || text.includes("enotfound") || text.includes("getaddrinfo") || text.includes("timeout") || text.includes("timed out") || text.includes("fetch failed") || // bun fetch 对连接失败的真实文案(无 refused/timeout 关键词)。
|
|
954
|
+
text.includes("unable to connect");
|
|
955
|
+
});
|
|
956
|
+
if (allNotFound) {
|
|
957
|
+
lines.push(
|
|
958
|
+
" next-step: \u76EE\u6807 dialog \u53EF\u80FD\u4E0D\u5728\u8FD9\u4E9B server \u4E0A\uFF1B\u672C\u5730 run \u7684\u5BF9\u8BDD\u5728\u672C\u5730\u5E93\uFF08<cwd>/data/leveldb\uFF09\uFF0C\u8BF7\u7528\u5B58\u50A8\u65B9\u5BF9\u5E94\u73AF\u5883/\u670D\u52A1\u8BFB\u53D6\uFF0C\u8FD0\u884C\u4E2D run \u53EF\u7528 `nolo agent status <runId|pid>` \u6216 dialog \u7684 status \u6A21\u5F0F\u67E5\u6458\u8981\u3002"
|
|
959
|
+
);
|
|
960
|
+
} else if (hasConnRefusedOrTimeout) {
|
|
961
|
+
lines.push(
|
|
962
|
+
" next-step: \u5B58\u5728\u8FDE\u63A5\u62D2\u7EDD/\u8D85\u65F6\uFF0C\u8BF7\u68C0\u67E5 NOLO_SERVER/--server \u6307\u5411\u7684 server \u662F\u5426\u53EF\u8FBE\u3001\u662F\u5426\u5728\u8FD0\u884C\u3002"
|
|
963
|
+
);
|
|
964
|
+
}
|
|
965
|
+
return lines.join("\n");
|
|
966
|
+
}
|
|
902
967
|
async function runDialogReadCommand(args, deps = {}) {
|
|
903
968
|
const env = deps.env ?? process.env;
|
|
904
969
|
const output = deps.output ?? process.stdout;
|
|
@@ -915,7 +980,7 @@ async function runDialogReadCommand(args, deps = {}) {
|
|
|
915
980
|
try {
|
|
916
981
|
target = resolveDialogReadTarget(args, env, authToken);
|
|
917
982
|
} catch (error) {
|
|
918
|
-
output.write(
|
|
983
|
+
output.write(`${formatDialogReadFailure(error)}
|
|
919
984
|
`);
|
|
920
985
|
return 1;
|
|
921
986
|
}
|
|
@@ -992,7 +1057,7 @@ async function runDialogReadCommand(args, deps = {}) {
|
|
|
992
1057
|
output.write("\n");
|
|
993
1058
|
return 0;
|
|
994
1059
|
} catch (error) {
|
|
995
|
-
output.write(
|
|
1060
|
+
output.write(`${formatDialogReadFailure(error)}
|
|
996
1061
|
`);
|
|
997
1062
|
return 1;
|
|
998
1063
|
}
|
|
@@ -138,7 +138,7 @@ function writeUsage(output, commandPath) {
|
|
|
138
138
|
return;
|
|
139
139
|
}
|
|
140
140
|
output.write(
|
|
141
|
-
"Usage: nolo agent run <agent> <message> [--local|--server|--auto] [--ephemeral|--memory-only] [--continue <dialogId>] [--cwd <path>]\n nolo agent run --agent <agent> (--msg <message>|--msg-file <path>) [--image <url-or-path>] [--space <spaceId>] [--category <name>] [--inherit-from-dialog <dialog>] [--parent-dialog <dialog>] [--subject-dialog <dialog>] [--subject-ref <kind:id[:role]>] [--task-row-dbkey <key>] [--allowed-child-agent <agent>] [--fallback-agent <agent>] (suggestions for agent to decide on quota) [--allowed-tool <tool>] [--blocked-tool <tool>] [--bg] [--timeout-ms <n>] [--events jsonl] [--no-stream] [--skill <dbKey-or-md-path>]\n"
|
|
141
|
+
"Usage: nolo agent run <agent> <message> [--local|--server|--auto] [--ephemeral|--memory-only] [--continue <dialogId>] [--cwd <path>]\n nolo agent run --agent <agent> (--msg <message>|--msg-file <path>) [--image <url-or-path>] [--space <spaceId>] [--category <name>] [--inherit-from-dialog <dialog>] [--parent-dialog <dialog>] [--subject-dialog <dialog>] [--subject-ref <kind:id[:role]>] [--task-row-dbkey <key>] [--allowed-child-agent <agent>] [--fallback-agent <agent>] (suggestions for agent to decide on quota) [--allowed-tool <tool>] [--blocked-tool <tool>] [--dod <cmd>] [--bg] [--timeout-ms <n>] [--events jsonl] [--no-stream] [--skill <dbKey-or-md-path>]\n"
|
|
142
142
|
);
|
|
143
143
|
}
|
|
144
144
|
function parseAgentRunArgs(args, options = {}) {
|
|
@@ -180,6 +180,7 @@ function parseAgentRunArgs(args, options = {}) {
|
|
|
180
180
|
const ephemeral = args.includes("--ephemeral") || args.includes("--memory-only");
|
|
181
181
|
const workflowRef = readFlagValue(args, "--workflow");
|
|
182
182
|
const skillRefs = readRepeatedFlagValues(args, "--skill").map((v) => v.trim()).filter(Boolean);
|
|
183
|
+
const dodCommands = readRepeatedFlagValues(args, "--dod").map((v) => v.trim()).filter(Boolean);
|
|
183
184
|
const taskRowDbKey = readFlagValue(args, "--task-row-dbkey");
|
|
184
185
|
const artifactIds = readFlagValue(args, "--artifact-ids")?.split(",").map((item) => item.trim()).filter(Boolean);
|
|
185
186
|
return {
|
|
@@ -215,6 +216,7 @@ function parseAgentRunArgs(args, options = {}) {
|
|
|
215
216
|
...allowedToolNames.length ? { allowedToolNames } : {},
|
|
216
217
|
...cwd ? { cwd } : {},
|
|
217
218
|
...blockedToolNames.length ? { blockedToolNames } : {},
|
|
219
|
+
...dodCommands.length ? { dodCommands } : {},
|
|
218
220
|
...typeof timeoutMs === "number" ? { timeoutMs } : {}
|
|
219
221
|
};
|
|
220
222
|
}
|
|
@@ -3,10 +3,13 @@ import {
|
|
|
3
3
|
} from "./chunk-VIDPVFP3.js";
|
|
4
4
|
import {
|
|
5
5
|
getApproxPricePerImage
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-AGGIDPCZ.js";
|
|
7
7
|
import {
|
|
8
8
|
getModelConfig
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-C6ELZQ7H.js";
|
|
10
|
+
import {
|
|
11
|
+
isPlatformHostedImageModel
|
|
12
|
+
} from "./chunk-X6EN3KJX.js";
|
|
10
13
|
import {
|
|
11
14
|
asOptionalFiniteNumber
|
|
12
15
|
} from "./chunk-WWC7I6TA.js";
|
|
@@ -66,7 +69,8 @@ var getAgentPriceHint = (agent) => {
|
|
|
66
69
|
const imagePriceModel = agent.imageModel ?? agent.model;
|
|
67
70
|
if (agent.imageConfig?.enabled && agent.provider && imagePriceModel) {
|
|
68
71
|
try {
|
|
69
|
-
const
|
|
72
|
+
const imageModelProvider = isPlatformHostedImageModel(imagePriceModel) ? "nolo" : agent.provider;
|
|
73
|
+
const model = getModelConfig(imageModelProvider, imagePriceModel);
|
|
70
74
|
const mode = agent.imageWorkflow;
|
|
71
75
|
if (mode === "generate") {
|
|
72
76
|
const defaultProfile = getPublicImageAgentDefaultProfile("generate");
|