nolo-cli 0.11.0 → 0.12.0-alpha.1
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-ZEDPX6OF.js → _executeModel-MWAY74HA.js} +51 -50
- package/{action-AA4IJ5K2.js → action-RAXNQQKC.js} +8 -9
- package/{addContentAction-QYVO4SYP.js → addContentAction-ZHI7TVV3.js} +7 -9
- package/{addDialogAgentAction-WVVKT5WQ.js → addDialogAgentAction-JWXPKXNC.js} +9 -10
- package/{agentDeleteCommand-RDPGYIWF.js → agentDeleteCommand-LXR5A5FV.js} +38 -28
- package/{agentEmailCommands-2HJJKS5F.js → agentEmailCommands-DXRAP7BB.js} +64 -62
- package/{agentListCommands-HFEVV3ZW.js → agentListCommands-ZFMS5ZLY.js} +127 -31
- package/{agentMachineCommands-25ZOENJU.js → agentMachineCommands-ZJLYVV52.js} +37 -26
- package/{agentPullCommand-GOL2S4W2.js → agentPullCommand-KRBRIFIY.js} +7 -7
- package/{agentRecordCommands-GTCOAM3L.js → agentRecordCommands-DFS626TB.js} +56 -54
- package/{agentRunCommand-YBS3JDLD.js → agentRunCommand-GWBIE2TS.js} +59 -59
- package/{agentRunControl-K4VKNEHF.js → agentRunControl-IX4F5W2C.js} +3 -3
- package/{agentRuntimeLocal-UQBMQI2M.js → agentRuntimeLocal-YNZSHMZC.js} +30 -15
- package/{agentSlice-6EKOBCCS.js → agentSlice-T2PXOEPQ.js} +8 -9
- package/{authCommand-O2OWACN4.js → authCommand-DMW336GT.js} +15 -15
- package/{authCommands-H7365TZP.js → authCommands-GH5T6RYV.js} +6 -6
- package/{chunk-7D3JY6C2.js → chunk-3HHTVM6G.js} +64 -5
- package/{chunk-AFON4QUU.js → chunk-3QKO4EHV.js} +3 -3
- package/{chunk-4SOKXIW4.js → chunk-43UD5ZP7.js} +8 -11
- package/{chunk-S3GS2PRL.js → chunk-4BTHUYMY.js} +597 -68
- package/{chunk-SV5MWASH.js → chunk-4EH7AR52.js} +12 -12
- package/{chunk-FXXSGWAJ.js → chunk-4GBNEA5B.js} +1 -1
- package/{chunk-PXZAAB4L.js → chunk-4LG74DRG.js} +4 -4
- package/{chunk-2FTTDCD4.js → chunk-4ON5AV72.js} +2 -1
- package/{chunk-IWX4UW2E.js → chunk-524BDL33.js} +89 -8
- package/{chunk-X2S7JTIG.js → chunk-5ITRDSHY.js} +1240 -136
- package/{chunk-ISNCLGUZ.js → chunk-5NBHQD4D.js} +4 -3
- package/{chunk-GBDSZATH.js → chunk-6LMFFG3K.js} +3 -3
- package/{chunk-OUI3ZHYD.js → chunk-6OVCRC72.js} +1 -1
- package/{chunk-CKOJQDKR.js → chunk-7JJCGV7N.js} +146 -3
- package/{chunk-MQI77IRB.js → chunk-7MYHLZ3F.js} +2 -2
- package/{chunk-5MOUAAMK.js → chunk-AM53Q2SD.js} +194 -2564
- package/chunk-BYXBJQAS.js +0 -0
- package/{chunk-LAX2JSTX.js → chunk-DE5BA4O6.js} +20 -2
- package/{chunk-BX6U3ETE.js → chunk-DRMGJFGQ.js} +293 -89
- package/{chunk-KJR5KAUQ.js → chunk-EBH7G34M.js} +20 -7
- package/{chunk-E4HNJSHC.js → chunk-G3B356GF.js} +16 -18
- package/{chunk-KQQVGRA3.js → chunk-GDBCUWQ3.js} +35 -29
- package/{chunk-Q3UKJVU4.js → chunk-GPZM7QH6.js} +10 -10
- package/chunk-IKXL2HZ3.js +70 -0
- package/{chunk-QNMFBBZK.js → chunk-IVAOVLM7.js} +1 -1
- package/{chunk-EVZKZF32.js → chunk-JUN3HFMN.js} +182 -75
- package/{chunk-NEM67FX7.js → chunk-JZDIW766.js} +1 -1
- package/{chunk-TACHTH5D.js → chunk-LHSJMY5V.js} +18 -18
- package/{chunk-XYZA7S7V.js → chunk-MEVCDATU.js} +6 -6
- package/{chunk-YOCHZD7D.js → chunk-NCGFB7NN.js} +5 -3
- package/{chunk-O26GI2JP.js → chunk-NITP2JDG.js} +39 -8
- package/{chunk-YPRZSPF3.js → chunk-OCDEWRE2.js} +1 -1
- package/{chunk-PNEW2Z3T.js → chunk-OHEKYYJF.js} +7 -7
- package/chunk-OOIN7HSO.js +146 -0
- package/{chunk-DWGAEFJL.js → chunk-OPKKB25T.js} +1 -1
- package/{chunk-AEZAORLG.js → chunk-QCA3EPYK.js} +5 -5
- package/{chunk-C4FTUXVF.js → chunk-QLUFR47U.js} +11 -1
- package/{chunk-C2MDQQ4O.js → chunk-RNQ5BLR2.js} +1 -1
- package/{chunk-L53FGHA4.js → chunk-RSEUHW6T.js} +1 -1
- package/{chunk-2W2VYVI5.js → chunk-RZ735TLX.js} +527 -176
- package/chunk-S3UTETIC.js +4885 -0
- package/chunk-S73OEOHH.js +2286 -0
- package/{chunk-YTBMA7NO.js → chunk-TSKWE74T.js} +58 -8
- package/{chunk-5OIFWVX7.js → chunk-UG3WOFU6.js} +1 -1
- package/{chunk-4ZDM73SD.js → chunk-V2J635L5.js} +1 -1
- package/{chunk-IPYUUY4E.js → chunk-WPHL6ALY.js} +1 -1
- package/{chunk-3NSIQZZ6.js → chunk-WTYKCU4W.js} +9 -9
- package/{chunk-LP65VRCI.js → chunk-WWU275LU.js} +6 -6
- package/{chunk-XFOLQLDN.js → chunk-XHQWJUW4.js} +2 -2
- package/{chunk-D6OQHXVG.js → chunk-YDCZVUFP.js} +7 -7
- package/{chunk-PXQN7IBQ.js → chunk-YTQLJYLB.js} +2 -2
- package/{chunk-ZEYDOXHF.js → chunk-ZPFRLGIZ.js} +1467 -869
- package/{chunk-ZPRK73XY.js → chunk-ZR4VHQ5D.js} +14 -13
- package/cliEnvHelpers-VYC2OPTB.js +30 -0
- package/{createAgentAutomationAction-LTI5QU35.js → createAgentAutomationAction-G32GKDGV.js} +25 -26
- package/{createDialogAction-OJJ7L3L3.js → createDialogAction-TISANRZK.js} +26 -27
- package/{createPageAction-5MXWVRGY.js → createPageAction-O7KOYNV4.js} +26 -27
- package/{dbSlice-RQFQQVHT.js → dbSlice-WDP2ZZHK.js} +6 -7
- package/{deleteFile-7XP5BGC7.js → deleteFile-M7UNIUOO.js} +4 -4
- package/{dialogCommands-JTJ3RPPW.js → dialogCommands-6JPB3YQY.js} +33 -23
- package/{dialogSlice-OWROKURJ.js → dialogSlice-PRHHYSP5.js} +26 -27
- package/{docCreateCommands-WJBEW2V7.js → docCreateCommands-75E6TZNN.js} +33 -23
- package/{docDeleteCommands-BVEHJOY5.js → docDeleteCommands-EJHLN7LW.js} +34 -25
- package/{docReadCommands-NEWOZIJV.js → docReadCommands-RJYBC4FS.js} +33 -23
- package/{docStore-3DXRYBMD.js → docStore-H5VWKT5D.js} +25 -26
- package/{docUpdateCommands-C7WHT7UU.js → docUpdateCommands-MG4CNISV.js} +33 -23
- package/fetchMessages-KTNM7QAR.js +1 -1
- package/{getPricing-3E6UNPKL.js → getPricing-6TOZXPAU.js} +7 -3
- package/{handleSendMessageAction-B5PRR7BE.js → handleSendMessageAction-QTUGICSZ.js} +29 -30
- package/index.js +77 -76
- package/{localDialogRead-YSKFFRTT.js → localDialogRead-2VRI24F4.js} +1 -1
- package/{machineCommands-IIIREAEK.js → machineCommands-MAV7M3TK.js} +63 -61
- package/{machineWsRunDispatch-3SIU6ILW.js → machineWsRunDispatch-ZOEGTKHC.js} +55 -53
- package/{memoryCommands-O4MIPIWQ.js → memoryCommands-AFMES3LN.js} +5 -5
- package/{models-4OPOOLFS.js → models-LSCRJJ6P.js} +2 -2
- package/package.json +1 -1
- package/{read-QJNKRROM.js → read-2MIMRBZ2.js} +4 -4
- package/{readDocTool-H6X6KO6X.js → readDocTool-QHVGQHUJ.js} +1 -1
- package/{readlineWorkspace-HGP3I3OC.js → readlineWorkspace-SWQKC7ZS.js} +1113 -678
- package/{removeDialogAgentAction-TCT35SOF.js → removeDialogAgentAction-GTX5AN54.js} +13 -13
- package/{runAgentClientLoop-EFM4PTVI.js → runAgentClientLoop-P25HACXX.js} +47 -47
- package/{runtimeDoctorCommands-ID43Z7VX.js → runtimeDoctorCommands-QNF3J3UV.js} +6 -6
- package/{setDialogExtraReferencesAction-CGYLZMFH.js → setDialogExtraReferencesAction-WFQ63KYO.js} +9 -10
- package/{setPrimaryDialogAgentAction-F6BFQDJU.js → setPrimaryDialogAgentAction-P57FXTSU.js} +13 -13
- package/{settingSlice-2I5HMG47.js → settingSlice-CK5YZGNI.js} +7 -8
- package/{skillDiscovery-UGSQGX2U.js → skillDiscovery-ZYHSX7VD.js} +3 -3
- package/{spaceCommands-MT7BWCIL.js → spaceCommands-6O5EFEM5.js} +37 -29
- package/{spaceSlice-BS5TSW3W.js → spaceSlice-4EXTYXS4.js} +28 -27
- package/{streamAgentChatTurn-I3VBFNR3.js → streamAgentChatTurn-Q3FJAHG2.js} +222 -128
- package/{toolApiClient-C7P7YSE4.js → toolApiClient-QI3YBNWB.js} +2 -2
- package/{tools-XSD2BOEN.js → tools-AHNQE4GP.js} +34 -34
- package/{tuiSummaryLlmCaller-32NRHTT2.js → tuiSummaryLlmCaller-TXLF4MEI.js} +8 -6
- package/{updateCommands-VOSPKXFF.js → updateCommands-XZDOOYFH.js} +13 -5
- package/{updateDialogTitleAction-7FYNJOGP.js → updateDialogTitleAction-XZDVLKVX.js} +29 -29
- package/chunk-5MMAK75Q.js +0 -15
- package/chunk-AZPCASRE.js +0 -36
- package/chunk-BBYVOSU2.js +0 -792
- package/chunk-DCOA4QSN.js +0 -105
- package/chunk-UAD2WT54.js +0 -64
- package/{chunk-JK7VW2FN.js → chunk-5MIDPSSK.js} +3 -3
- package/{chunk-5CS33IBL.js → chunk-PDL2AV3E.js} +3 -3
- package/{chunk-5MMZUWSG.js → chunk-TOILAPLH.js} +5 -5
- package/{chunk-OOM6SJNR.js → chunk-TSUJOM6N.js} +6 -6
- package/{db-6QED3ZVO.js → db-HCJ5PRB5.js} +3 -3
- package/{offlineMarxistsAgentCommand-BCPJITJL.js → offlineMarxistsAgentCommand-5OOWZLJI.js} +3 -3
- package/{tableCommands-M3DJUETS.js → tableCommands-E4SQWDOX.js} +6 -6
- package/{understanding-ZOESBLF3.js → understanding-3CUQQ6SV.js} +3 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
clearCliLocalRuntimePreparedAgentCache
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-5ITRDSHY.js";
|
|
4
4
|
import {
|
|
5
5
|
getReadableCliDb
|
|
6
6
|
} from "./chunk-W4NVOSFF.js";
|
|
@@ -12,17 +12,17 @@ import {
|
|
|
12
12
|
resolveAgentRecordFromHybridStore,
|
|
13
13
|
sanitizeAgentRecordForCliOutput,
|
|
14
14
|
writeAgentRecord
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-QCA3EPYK.js";
|
|
16
16
|
import {
|
|
17
17
|
resolveCliAgentKeyInput
|
|
18
18
|
} from "./chunk-VHBWHNVT.js";
|
|
19
|
-
import {
|
|
20
|
-
parseUserIdFromAuthToken,
|
|
21
|
-
resolveAuthToken
|
|
22
|
-
} from "./chunk-ISNCLGUZ.js";
|
|
23
19
|
import {
|
|
24
20
|
toErrorMessage
|
|
25
21
|
} from "./chunk-HNMXYYJR.js";
|
|
22
|
+
import {
|
|
23
|
+
parseUserIdFromAuthToken,
|
|
24
|
+
resolveAuthToken
|
|
25
|
+
} from "./chunk-5NBHQD4D.js";
|
|
26
26
|
|
|
27
27
|
// packages/cli/agentRecordCommands.ts
|
|
28
28
|
async function runAgentReadCommand(args, deps = {}) {
|
|
@@ -43,7 +43,7 @@ async function runAgentReadCommand(args, deps = {}) {
|
|
|
43
43
|
const fetchImpl = deps.fetchImpl ?? fetch;
|
|
44
44
|
const fallbackFetchImpl = deps.fallbackFetchImpl;
|
|
45
45
|
try {
|
|
46
|
-
|
|
46
|
+
let result = await resolveAgentRecordFromHybridStore({
|
|
47
47
|
agentInput,
|
|
48
48
|
cliArgs: args,
|
|
49
49
|
env,
|
|
@@ -51,6 +51,19 @@ async function runAgentReadCommand(args, deps = {}) {
|
|
|
51
51
|
fetchImpl,
|
|
52
52
|
fallbackFetchImpl
|
|
53
53
|
});
|
|
54
|
+
if (!result && agentKey.startsWith("agent-pub-")) {
|
|
55
|
+
const bareId = agentKey.slice("agent-pub-".length);
|
|
56
|
+
if (bareId) {
|
|
57
|
+
result = await resolveAgentRecordFromHybridStore({
|
|
58
|
+
agentInput: bareId,
|
|
59
|
+
cliArgs: args,
|
|
60
|
+
env,
|
|
61
|
+
db,
|
|
62
|
+
fetchImpl,
|
|
63
|
+
fallbackFetchImpl
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
}
|
|
54
67
|
if (!result) {
|
|
55
68
|
throw new Error(`agent not found: ${agentKey}`);
|
|
56
69
|
}
|
|
@@ -3,49 +3,47 @@ import {
|
|
|
3
3
|
prepareAndPersistMessage,
|
|
4
4
|
uiAskChoiceFunc,
|
|
5
5
|
uiAskChoiceFunctionSchema
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-AM53Q2SD.js";
|
|
7
7
|
import {
|
|
8
8
|
require_date_fns
|
|
9
9
|
} from "./chunk-M76ECQRD.js";
|
|
10
10
|
import {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
removeCachedEntity,
|
|
14
|
-
upsertSSREntity,
|
|
15
|
-
write
|
|
16
|
-
} from "./chunk-O26GI2JP.js";
|
|
11
|
+
extractCustomId
|
|
12
|
+
} from "./chunk-DFFIZ25G.js";
|
|
17
13
|
import {
|
|
18
14
|
chooseMemoryOwners,
|
|
19
15
|
loadMemoryCandidatesFromDb
|
|
20
16
|
} from "./chunk-XENYHRUE.js";
|
|
21
17
|
import {
|
|
22
18
|
PLATFORM_HOSTED_GLM_52_MODEL,
|
|
23
|
-
PLATFORM_HOSTED_GLM_PRICE
|
|
24
|
-
} from "./chunk-BBYVOSU2.js";
|
|
25
|
-
import {
|
|
19
|
+
PLATFORM_HOSTED_GLM_PRICE,
|
|
26
20
|
PLATFORM_HOSTED_KIMI_PROVIDER
|
|
27
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-524BDL33.js";
|
|
22
|
+
import {
|
|
23
|
+
read,
|
|
24
|
+
readAndWait,
|
|
25
|
+
removeCachedEntity,
|
|
26
|
+
upsertSSREntity,
|
|
27
|
+
write
|
|
28
|
+
} from "./chunk-NITP2JDG.js";
|
|
28
29
|
import {
|
|
29
30
|
createAgentKey,
|
|
30
31
|
createDialogKey,
|
|
31
32
|
createKey,
|
|
32
33
|
dialogMessageRange
|
|
33
34
|
} from "./chunk-O4BU24WZ.js";
|
|
34
|
-
import {
|
|
35
|
-
extractCustomId
|
|
36
|
-
} from "./chunk-DFFIZ25G.js";
|
|
37
35
|
import {
|
|
38
36
|
selectIdentityUserId
|
|
39
|
-
} from "./chunk-
|
|
37
|
+
} from "./chunk-TSUJOM6N.js";
|
|
38
|
+
import {
|
|
39
|
+
isRecord
|
|
40
|
+
} from "./chunk-KUG52IAP.js";
|
|
40
41
|
import {
|
|
41
42
|
asTrimmedString
|
|
42
43
|
} from "./chunk-3EUW3WEO.js";
|
|
43
44
|
import {
|
|
44
45
|
asOptionalPositiveFiniteNumber
|
|
45
46
|
} from "./chunk-U6VC4MU4.js";
|
|
46
|
-
import {
|
|
47
|
-
isRecord
|
|
48
|
-
} from "./chunk-KUG52IAP.js";
|
|
49
47
|
import {
|
|
50
48
|
asOptionalTrimmedString
|
|
51
49
|
} from "./chunk-G3SUCT4W.js";
|
|
@@ -3,13 +3,10 @@ import {
|
|
|
3
3
|
} from "./chunk-JEXVIMYZ.js";
|
|
4
4
|
import {
|
|
5
5
|
prepareTools
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-YTQLJYLB.js";
|
|
7
7
|
import {
|
|
8
8
|
performFetchRequest
|
|
9
|
-
} from "./chunk-
|
|
10
|
-
import {
|
|
11
|
-
getPublicImageAgentMode
|
|
12
|
-
} from "./chunk-VIDPVFP3.js";
|
|
9
|
+
} from "./chunk-JUN3HFMN.js";
|
|
13
10
|
import {
|
|
14
11
|
createSSEParser,
|
|
15
12
|
createToolRunId,
|
|
@@ -20,43 +17,34 @@ import {
|
|
|
20
17
|
toolRunSetPending,
|
|
21
18
|
toolRunStarted,
|
|
22
19
|
toolRunSucceeded
|
|
23
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-RZ735TLX.js";
|
|
21
|
+
import {
|
|
22
|
+
getPublicImageAgentMode
|
|
23
|
+
} from "./chunk-VIDPVFP3.js";
|
|
24
24
|
import {
|
|
25
25
|
addToolMessage,
|
|
26
|
-
getModelInfo,
|
|
27
26
|
messageStreamEnd,
|
|
28
27
|
messageStreaming,
|
|
29
28
|
selectCurrentSpaceId,
|
|
30
29
|
updateToolMessage
|
|
31
|
-
} from "./chunk-
|
|
30
|
+
} from "./chunk-AM53Q2SD.js";
|
|
32
31
|
import {
|
|
33
32
|
streamAgentChatTurn
|
|
34
|
-
} from "./chunk-
|
|
35
|
-
import {
|
|
36
|
-
selectCurrentServer
|
|
37
|
-
} from "./chunk-3NSIQZZ6.js";
|
|
38
|
-
import {
|
|
39
|
-
write
|
|
40
|
-
} from "./chunk-O26GI2JP.js";
|
|
33
|
+
} from "./chunk-GPZM7QH6.js";
|
|
41
34
|
import {
|
|
42
35
|
EMPTY_ASSISTANT_REPAIR_PROMPT
|
|
43
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-4BTHUYMY.js";
|
|
44
37
|
import {
|
|
45
38
|
createThinkParserState,
|
|
46
39
|
flushThinkParser,
|
|
47
40
|
processThinkChunk
|
|
48
41
|
} from "./chunk-OPZYGHUC.js";
|
|
49
42
|
import {
|
|
50
|
-
|
|
51
|
-
} from "./chunk-
|
|
43
|
+
getModelInfo
|
|
44
|
+
} from "./chunk-S73OEOHH.js";
|
|
52
45
|
import {
|
|
53
|
-
|
|
54
|
-
} from "./chunk-
|
|
55
|
-
import {
|
|
56
|
-
createDialogMessageKeyAndId,
|
|
57
|
-
dialogMessageKey,
|
|
58
|
-
toTrimmedString
|
|
59
|
-
} from "./chunk-O4BU24WZ.js";
|
|
46
|
+
getApiEndpoint
|
|
47
|
+
} from "./chunk-S3UTETIC.js";
|
|
60
48
|
import {
|
|
61
49
|
extractCustomId
|
|
62
50
|
} from "./chunk-DFFIZ25G.js";
|
|
@@ -68,19 +56,33 @@ import {
|
|
|
68
56
|
import {
|
|
69
57
|
toErrorMessage
|
|
70
58
|
} from "./chunk-HNMXYYJR.js";
|
|
59
|
+
import {
|
|
60
|
+
isNoloHostedProvider
|
|
61
|
+
} from "./chunk-524BDL33.js";
|
|
62
|
+
import {
|
|
63
|
+
selectCurrentServer
|
|
64
|
+
} from "./chunk-WTYKCU4W.js";
|
|
65
|
+
import {
|
|
66
|
+
write
|
|
67
|
+
} from "./chunk-NITP2JDG.js";
|
|
68
|
+
import {
|
|
69
|
+
createDialogMessageKeyAndId,
|
|
70
|
+
dialogMessageKey,
|
|
71
|
+
toTrimmedString
|
|
72
|
+
} from "./chunk-O4BU24WZ.js";
|
|
71
73
|
import {
|
|
72
74
|
createAsyncThunk,
|
|
73
75
|
selectIdentityToken
|
|
74
|
-
} from "./chunk-
|
|
76
|
+
} from "./chunk-TSUJOM6N.js";
|
|
75
77
|
import {
|
|
76
78
|
isAbortError
|
|
77
79
|
} from "./chunk-OOSFSFMA.js";
|
|
78
|
-
import {
|
|
79
|
-
asTrimmedString
|
|
80
|
-
} from "./chunk-3EUW3WEO.js";
|
|
81
80
|
import {
|
|
82
81
|
isRecord
|
|
83
82
|
} from "./chunk-KUG52IAP.js";
|
|
83
|
+
import {
|
|
84
|
+
asTrimmedString
|
|
85
|
+
} from "./chunk-3EUW3WEO.js";
|
|
84
86
|
import {
|
|
85
87
|
asOptionalTrimmedString
|
|
86
88
|
} from "./chunk-G3SUCT4W.js";
|
|
@@ -182,6 +184,10 @@ var toOpenAIMessage = (rawMsg) => {
|
|
|
182
184
|
if (role === "assistant" && toolCalls) {
|
|
183
185
|
cleaned.tool_calls = toolCalls;
|
|
184
186
|
}
|
|
187
|
+
if (role === "assistant") {
|
|
188
|
+
const reasoningContent = typeof msg.reasoning_content === "string" ? msg.reasoning_content : typeof msg.thinkContent === "string" ? msg.thinkContent : "";
|
|
189
|
+
if (reasoningContent) cleaned.reasoning_content = reasoningContent;
|
|
190
|
+
}
|
|
185
191
|
if (role === "tool") {
|
|
186
192
|
const toolCallId = extractToolCallId(msg);
|
|
187
193
|
if (toolCallId) cleaned.tool_call_id = toolCallId;
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import {
|
|
2
|
-
patch,
|
|
3
|
-
remove,
|
|
4
|
-
write
|
|
5
|
-
} from "./chunk-O26GI2JP.js";
|
|
6
1
|
import {
|
|
7
2
|
applyAgentSecretMigrationUpdates,
|
|
8
3
|
createFileCredentialBroker,
|
|
9
4
|
migrateAgentSecrets,
|
|
10
5
|
normalizeAgentRuntimeToolPolicy
|
|
11
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-PDL2AV3E.js";
|
|
12
7
|
import {
|
|
13
8
|
asRecordOrEmpty
|
|
14
9
|
} from "./chunk-KX6YBIHG.js";
|
|
10
|
+
import {
|
|
11
|
+
patch,
|
|
12
|
+
remove,
|
|
13
|
+
write
|
|
14
|
+
} from "./chunk-NITP2JDG.js";
|
|
15
15
|
import {
|
|
16
16
|
createAgentKey,
|
|
17
17
|
toTrimmedString
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
asyncThunkCreator,
|
|
21
21
|
buildCreateSlice,
|
|
22
22
|
getRuntimeServerContext
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-TSUJOM6N.js";
|
|
24
24
|
import {
|
|
25
25
|
asTrimmedString
|
|
26
26
|
} from "./chunk-3EUW3WEO.js";
|
|
@@ -300,7 +300,7 @@ var slice = createSliceWithThunks({
|
|
|
300
300
|
const overrides = {};
|
|
301
301
|
if (args.systemPromptOverride !== void 0) overrides.prompt = args.systemPromptOverride;
|
|
302
302
|
if (args.toolsOverride !== void 0) overrides.tools = args.toolsOverride;
|
|
303
|
-
const { _executeModel } = await import("./_executeModel-
|
|
303
|
+
const { _executeModel } = await import("./_executeModel-MWAY74HA.js");
|
|
304
304
|
return _executeModel(
|
|
305
305
|
{
|
|
306
306
|
isStreaming: args.isStreaming ?? false,
|
|
@@ -321,7 +321,7 @@ var slice = createSliceWithThunks({
|
|
|
321
321
|
* - 循环直到无工具调用或触发其他运行时停止条件
|
|
322
322
|
*/
|
|
323
323
|
runAgent: create.asyncThunk(async (args, thunkApi) => {
|
|
324
|
-
const { runAgentClientLoop } = await import("./runAgentClientLoop-
|
|
324
|
+
const { runAgentClientLoop } = await import("./runAgentClientLoop-P25HACXX.js");
|
|
325
325
|
const { content: loopContent, toolCallCount } = await runAgentClientLoop(
|
|
326
326
|
{
|
|
327
327
|
agentKey: args.agentKey,
|
|
@@ -337,7 +337,7 @@ var slice = createSliceWithThunks({
|
|
|
337
337
|
* 聊天轮次流式 Agent 调用
|
|
338
338
|
*/
|
|
339
339
|
streamAgentChatTurn: create.asyncThunk(async (args, thunkApi) => {
|
|
340
|
-
const { streamAgentChatTurnHandler } = await import("./streamAgentChatTurn-
|
|
340
|
+
const { streamAgentChatTurnHandler } = await import("./streamAgentChatTurn-Q3FJAHG2.js");
|
|
341
341
|
return streamAgentChatTurnHandler(args, thunkApi);
|
|
342
342
|
}),
|
|
343
343
|
/**
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
import {
|
|
2
|
+
cloudflareModels,
|
|
3
|
+
deepSeekModels,
|
|
4
|
+
deepinfraModels,
|
|
5
|
+
fireworksModels,
|
|
6
|
+
gmiModels,
|
|
7
|
+
googleModels,
|
|
8
|
+
openAIModels,
|
|
9
|
+
openrouterModels,
|
|
10
|
+
platformHostedModels,
|
|
11
|
+
xaiModels,
|
|
12
|
+
zaiModels
|
|
13
|
+
} from "./chunk-524BDL33.js";
|
|
14
|
+
|
|
15
|
+
// packages/ai/llm/modelAbility.ts
|
|
16
|
+
var MODEL_ABILITY_TABLE = {
|
|
17
|
+
"claude-opus-5": { passAt1: 74, benchmarkScore: 61 },
|
|
18
|
+
"gpt-5.6-sol": { passAt1: 73, benchmarkScore: 59 },
|
|
19
|
+
"gpt-5.6-terra": { passAt1: 70, benchmarkScore: 55 },
|
|
20
|
+
"kimi-k3": { passAt1: 69, benchmarkScore: 57 },
|
|
21
|
+
"grok-4.5": { passAt1: 54, benchmarkScore: 54 },
|
|
22
|
+
"claude-sonnet-5": { passAt1: 54, benchmarkScore: 53 },
|
|
23
|
+
"gpt-5.6-luna": { passAt1: 67, benchmarkScore: 51 },
|
|
24
|
+
"glm-5.2": { passAt1: 44, benchmarkScore: 51 },
|
|
25
|
+
"gemini-3.6-flash": { passAt1: 49, benchmarkScore: 50 }
|
|
26
|
+
};
|
|
27
|
+
var EFFORT_SUFFIXES = ["-extra-low", "-low", "-medium", "-high"];
|
|
28
|
+
function normalizeModelName(raw) {
|
|
29
|
+
let name = raw.trim().toLowerCase();
|
|
30
|
+
const slash = name.indexOf("/");
|
|
31
|
+
if (slash !== -1) name = name.slice(slash + 1);
|
|
32
|
+
for (const suffix of EFFORT_SUFFIXES) {
|
|
33
|
+
if (name.endsWith(suffix) && name.length > suffix.length) {
|
|
34
|
+
name = name.slice(0, -suffix.length);
|
|
35
|
+
break;
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
return name;
|
|
39
|
+
}
|
|
40
|
+
function getModelAbility(modelName) {
|
|
41
|
+
const entry = MODEL_ABILITY_TABLE[normalizeModelName(modelName)];
|
|
42
|
+
return entry ? { ...entry } : void 0;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
// packages/ai/llm/ollamaCloud.ts
|
|
46
|
+
var ollamaCloudModels = platformHostedModels;
|
|
47
|
+
|
|
48
|
+
// packages/ai/llm/models.ts
|
|
49
|
+
var withProvider = (provider) => (models) => models.map((model) => ({ ...model, provider }));
|
|
50
|
+
var ALL_MODELS = [
|
|
51
|
+
...withProvider("nolo")(ollamaCloudModels),
|
|
52
|
+
...withProvider("google")(googleModels),
|
|
53
|
+
...withProvider("openai")(openAIModels),
|
|
54
|
+
...withProvider("openrouter")(openrouterModels),
|
|
55
|
+
...withProvider("xai")(xaiModels),
|
|
56
|
+
...withProvider("deepseek")(deepSeekModels),
|
|
57
|
+
...withProvider("deepinfra")(deepinfraModels),
|
|
58
|
+
...withProvider("fireworks")(fireworksModels),
|
|
59
|
+
...withProvider("cloudflare")(cloudflareModels),
|
|
60
|
+
...withProvider("gmi")(gmiModels),
|
|
61
|
+
...withProvider("zai")(zaiModels)
|
|
62
|
+
].map((model) => {
|
|
63
|
+
const ability = getModelAbility(model.name);
|
|
64
|
+
return ability ? { ...model, ability } : model;
|
|
65
|
+
});
|
|
66
|
+
|
|
67
|
+
export {
|
|
68
|
+
getModelAbility,
|
|
69
|
+
ALL_MODELS
|
|
70
|
+
};
|
|
@@ -199,7 +199,7 @@ async function readDocFunc(args, thunkApi) {
|
|
|
199
199
|
throw new Error(`\u65E0\u6548\u7684\u9875\u9762 ID: ${id}\u3002\u9875\u9762 ID \u901A\u5E38\u4EE5 "page-" \u5F00\u5934\u3002`);
|
|
200
200
|
}
|
|
201
201
|
try {
|
|
202
|
-
const { readAction } = await import("./read-
|
|
202
|
+
const { readAction } = await import("./read-2MIMRBZ2.js");
|
|
203
203
|
const pageData = await readAction({ dbKey: id }, thunkApi);
|
|
204
204
|
if (!pageData) {
|
|
205
205
|
throw new Error(`\u672A\u627E\u5230 ID \u4E3A ${id} \u7684\u9875\u9762\u3002`);
|