nolo-cli 0.16.0-alpha.12 → 0.16.0-alpha.14
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-LGHYA5XS.js → _executeModel-UU2JO5OB.js} +16 -15
- package/{agentDeleteCommand-PBIUC4FT.js → agentDeleteCommand-L6JRXPYK.js} +10 -10
- package/{agentEmailCommands-KC2QCPQV.js → agentEmailCommands-FE3GY3T5.js} +19 -18
- package/{agentListCommands-N64PHBXM.js → agentListCommands-ZWSAIC4W.js} +11 -11
- package/{agentMachineCommands-P7S5WAVA.js → agentMachineCommands-VWQ2GZBY.js} +10 -10
- package/{agentRecordCommands-JKZR2TZJ.js → agentRecordCommands-PYVZMRZM.js} +19 -18
- package/{agentRunCommand-2ELKCBWR.js → agentRunCommand-3ADJ2J5U.js} +24 -20
- package/{agentRunControl-6ADXVYMR.js → agentRunControl-YVLQ4BW5.js} +24 -1
- package/{agentRuntimeLocal-T6YECTNF.js → agentRuntimeLocal-LXTR6SAU.js} +7 -7
- package/{agentSlice-NXLMDKR7.js → agentSlice-TI6ECUGN.js} +1 -1
- package/{appDeleteCommands-D6B6Z4ZQ.js → appDeleteCommands-QIS37SXE.js} +11 -11
- package/{appDeployCommands-YMO5FK4T.js → appDeployCommands-WBHB7T5B.js} +11 -11
- package/{appDeployStatusCommands-EO5DWWPQ.js → appDeployStatusCommands-A3OUV6GO.js} +11 -11
- package/{appGetCommands-6SMZ3URQ.js → appGetCommands-LCVYIH63.js} +11 -11
- package/{appListCommands-RZXSWR2G.js → appListCommands-PC7QOBUO.js} +11 -11
- package/{chunk-4LXOVZ4W.js → chunk-2OK7P5XF.js} +54 -13
- package/{chunk-MSA4JAOZ.js → chunk-2ZLEOGS5.js} +1 -1
- package/{chunk-KKY4B2Q2.js → chunk-4PWB7JRR.js} +4 -1
- package/{chunk-VHXXRWNL.js → chunk-5QJFYG2N.js} +15 -5
- package/{chunk-F3UOACU4.js → chunk-64IEIMN4.js} +1 -1
- package/{chunk-XEWUC53Z.js → chunk-6IGLIDDE.js} +21 -9
- package/{chunk-AS3ZQ3O2.js → chunk-7OBMZCRD.js} +1 -1
- package/{chunk-QLUFR47U.js → chunk-AL2V7U3E.js} +1 -1
- package/{chunk-22NGXGN3.js → chunk-BOBNE3XT.js} +2 -2
- package/{chunk-MYMMNKYL.js → chunk-E5CLOOG5.js} +153 -6
- package/{chunk-ZXQ52OY2.js → chunk-ECGTEOC2.js} +3 -3
- package/chunk-FKXFCYVO.js +221 -0
- package/{chunk-6KBBMW4D.js → chunk-FTNTMGXT.js} +1 -1
- package/{chunk-6CRACQXW.js → chunk-GFPESFS6.js} +2 -2
- package/{chunk-47QUPRHO.js → chunk-GM37ZF7R.js} +2 -2
- package/{chunk-A7O4KKLZ.js → chunk-HGDFFA6T.js} +2 -2
- package/{chunk-C4MMO7W4.js → chunk-NZBK3ZET.js} +1 -1
- package/{chunk-JTMNCCWF.js → chunk-OSIJVBXP.js} +2 -2
- package/{chunk-OVBVEXZ7.js → chunk-PFW2ZEON.js} +53 -1
- package/{chunk-BXXECNBU.js → chunk-Q6B6XJBG.js} +15 -6
- package/{chunk-GPELDE6I.js → chunk-SOW2GCA5.js} +1 -1
- package/{chunk-HSASSW4L.js → chunk-TUWPYUVR.js} +7 -7
- package/{chunk-EQTZPEID.js → chunk-U3DCTSPN.js} +31 -49
- package/{chunk-D4NCEGGR.js → chunk-URVWRKFU.js} +166 -242
- package/{chunk-WBA6SIBB.js → chunk-UUDRNDC7.js} +1 -1
- package/{chunk-2WXMU64E.js → chunk-W63ZTRQU.js} +3 -3
- package/{chunk-ZH62XNZE.js → chunk-W6OKITU6.js} +678 -39
- package/{chunk-PU4LXVAC.js → chunk-XG7CSGP3.js} +1 -1
- package/{chunk-XRSPI6CP.js → chunk-YZXEEGKV.js} +1 -1
- package/{chunk-RIF3XLXK.js → chunk-ZDDHKIWB.js} +8 -4
- package/{createAgentAutomationAction-RKWIMKHW.js → createAgentAutomationAction-N4ZB7VX2.js} +3 -3
- package/{createDialogAction-VN7MEBS3.js → createDialogAction-KF6HXCCZ.js} +4 -4
- package/{createPageAction-JBUWBHHC.js → createPageAction-FXWSJONZ.js} +3 -3
- package/{dialogCommands-DFY5HJ6M.js → dialogCommands-ULS6HV5V.js} +11 -11
- package/{dialogSlice-NNYBU35K.js → dialogSlice-K32QLYS7.js} +3 -3
- package/{docCreateCommands-5L76YTI2.js → docCreateCommands-RZTRTRU4.js} +10 -10
- package/{docDeleteCommands-3GASP3VR.js → docDeleteCommands-FU36A663.js} +11 -11
- package/{docReadCommands-ALA77AZM.js → docReadCommands-IX4JXD4X.js} +10 -10
- package/{docStore-DR22GGF3.js → docStore-L6HBNJ3R.js} +4 -4
- package/{docUpdateCommands-6AZGXE5M.js → docUpdateCommands-W4OCR55Z.js} +10 -10
- package/{handleSendMessageAction-FHITDM7H.js → handleSendMessageAction-MFKKZXV7.js} +3 -3
- package/index.js +45 -45
- package/{machineCommands-3B4IHHVK.js → machineCommands-4MFLZERH.js} +18 -17
- package/{machineWsRunDispatch-AXZ6OL3V.js → machineWsRunDispatch-AAHRNKIR.js} +18 -17
- package/package.json +1 -1
- package/{readlineWorkspace-DBZCXS7Y.js → readlineWorkspace-7OPITHTN.js} +38 -29
- package/{runAgentClientLoop-AB7PQ3TB.js → runAgentClientLoop-HRWV7KE2.js} +12 -11
- package/{setPrimaryDialogAgentAction-IIVDCY5C.js → setPrimaryDialogAgentAction-57GRIGX5.js} +16 -8
- package/{skillDiscovery-6M2BZUFN.js → skillDiscovery-KJWT7JBU.js} +3 -3
- package/{spaceCommands-AB2D7A2R.js → spaceCommands-GMMQTMHK.js} +10 -10
- package/{spaceSlice-TEJDCU6A.js → spaceSlice-V2P5TTQU.js} +3 -3
- package/{streamAgentChatTurn-NZ3HLAXS.js → streamAgentChatTurn-ZANOYOUR.js} +64 -43
- package/{tools-M4USUF3R.js → tools-YHZP6NXU.js} +8 -7
- package/{updateDialogTitleAction-SMPQVKWT.js → updateDialogTitleAction-IKTPGPPE.js} +3 -3
|
@@ -1,47 +1,47 @@
|
|
|
1
1
|
import {
|
|
2
2
|
fetchAgentContexts
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-UUDRNDC7.js";
|
|
4
4
|
import {
|
|
5
5
|
generateRequestBody,
|
|
6
6
|
mergeReferences,
|
|
7
7
|
performFetchRequest
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-6IGLIDDE.js";
|
|
9
9
|
import "./chunk-L6NVTGI7.js";
|
|
10
10
|
import {
|
|
11
11
|
findToolExecutor,
|
|
12
12
|
getToolResultErrorData
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-URVWRKFU.js";
|
|
14
14
|
import "./chunk-RQSOAMPJ.js";
|
|
15
15
|
import "./chunk-XJITGCTM.js";
|
|
16
16
|
import "./chunk-KQHGZWSV.js";
|
|
17
|
-
import "./chunk-
|
|
17
|
+
import "./chunk-GFPESFS6.js";
|
|
18
18
|
import "./chunk-6N4KODMN.js";
|
|
19
19
|
import "./chunk-3LY4F7SV.js";
|
|
20
20
|
import "./chunk-VP4WJWKW.js";
|
|
21
21
|
import "./chunk-63W5N6P3.js";
|
|
22
22
|
import "./chunk-VF4K2QE6.js";
|
|
23
|
-
import "./chunk-
|
|
23
|
+
import "./chunk-Q6B6XJBG.js";
|
|
24
24
|
import "./chunk-VC6OZXO5.js";
|
|
25
25
|
import {
|
|
26
26
|
updateTokensAction
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-2OK7P5XF.js";
|
|
28
28
|
import "./chunk-XOIF2TNF.js";
|
|
29
29
|
import "./chunk-MRC4Q34M.js";
|
|
30
30
|
import "./chunk-MTU75CZ2.js";
|
|
31
31
|
import "./chunk-CWMSB67P.js";
|
|
32
|
-
import "./chunk-
|
|
32
|
+
import "./chunk-ECGTEOC2.js";
|
|
33
33
|
import "./chunk-RPDGJO4D.js";
|
|
34
34
|
import "./chunk-SOTZ6RDN.js";
|
|
35
35
|
import "./chunk-Z4NR32XR.js";
|
|
36
36
|
import "./chunk-M76ECQRD.js";
|
|
37
37
|
import "./chunk-WZSRQNQG.js";
|
|
38
|
-
import "./chunk-
|
|
38
|
+
import "./chunk-SOW2GCA5.js";
|
|
39
39
|
import "./chunk-KFEVY3ST.js";
|
|
40
40
|
import "./chunk-MUCU6ATG.js";
|
|
41
41
|
import {
|
|
42
42
|
canonicalizeToolName
|
|
43
|
-
} from "./chunk-
|
|
44
|
-
import "./chunk-
|
|
43
|
+
} from "./chunk-OSIJVBXP.js";
|
|
44
|
+
import "./chunk-PFW2ZEON.js";
|
|
45
45
|
import "./chunk-5MMAK75Q.js";
|
|
46
46
|
import {
|
|
47
47
|
getApiEndpoint
|
|
@@ -49,13 +49,14 @@ import {
|
|
|
49
49
|
import "./chunk-5CS33IBL.js";
|
|
50
50
|
import "./chunk-JZPBVBIY.js";
|
|
51
51
|
import "./chunk-ZHXJ6M7T.js";
|
|
52
|
-
import "./chunk-
|
|
52
|
+
import "./chunk-4PWB7JRR.js";
|
|
53
53
|
import "./chunk-5MIDPSSK.js";
|
|
54
54
|
import {
|
|
55
55
|
extractCustomId
|
|
56
56
|
} from "./chunk-DFFIZ25G.js";
|
|
57
57
|
import "./chunk-3ASDTTEI.js";
|
|
58
58
|
import "./chunk-DWLEOOGR.js";
|
|
59
|
+
import "./chunk-FKXFCYVO.js";
|
|
59
60
|
import "./chunk-HNMXYYJR.js";
|
|
60
61
|
import "./chunk-RK5NYQEL.js";
|
|
61
62
|
import "./chunk-O6W2O2DA.js";
|
|
@@ -48,7 +48,7 @@ var setPrimaryDialogAgentAction = async (agentId, thunkApi) => {
|
|
|
48
48
|
if (!currentDialogKey) {
|
|
49
49
|
throw new Error("No current dialog selected");
|
|
50
50
|
}
|
|
51
|
-
if (
|
|
51
|
+
if (typeof agentId !== "string") {
|
|
52
52
|
throw new Error("No valid agent ID provided");
|
|
53
53
|
}
|
|
54
54
|
const dialogConfig = selectById(
|
|
@@ -62,16 +62,24 @@ var setPrimaryDialogAgentAction = async (agentId, thunkApi) => {
|
|
|
62
62
|
if (currentPrimaryAgentId && currentPrimaryAgentId !== agentId) {
|
|
63
63
|
await cleanupCliSessionForDialog({ dispatch, getState }, dialogConfig);
|
|
64
64
|
}
|
|
65
|
+
const changes = agentId ? {
|
|
66
|
+
agentMode: "fixed",
|
|
67
|
+
primaryAgentKey: agentId,
|
|
68
|
+
cybots: replacePrimaryDialogAgentId(
|
|
69
|
+
dialogConfig.cybots || [],
|
|
70
|
+
agentId
|
|
71
|
+
),
|
|
72
|
+
updatedAt: (0, import_date_fns.formatISO)(/* @__PURE__ */ new Date())
|
|
73
|
+
} : {
|
|
74
|
+
agentMode: "auto",
|
|
75
|
+
primaryAgentKey: void 0,
|
|
76
|
+
cybots: [],
|
|
77
|
+
updatedAt: (0, import_date_fns.formatISO)(/* @__PURE__ */ new Date())
|
|
78
|
+
};
|
|
65
79
|
return await dispatch(
|
|
66
80
|
patch({
|
|
67
81
|
dbKey: currentDialogKey,
|
|
68
|
-
changes
|
|
69
|
-
cybots: replacePrimaryDialogAgentId(
|
|
70
|
-
dialogConfig.cybots || [],
|
|
71
|
-
agentId
|
|
72
|
-
),
|
|
73
|
-
updatedAt: (0, import_date_fns.formatISO)(/* @__PURE__ */ new Date())
|
|
74
|
-
}
|
|
82
|
+
changes
|
|
75
83
|
})
|
|
76
84
|
).unwrap();
|
|
77
85
|
};
|
|
@@ -3,10 +3,10 @@ import {
|
|
|
3
3
|
discoverSkills,
|
|
4
4
|
parseSkillFrontmatter,
|
|
5
5
|
resolveSkillByName
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-7OBMZCRD.js";
|
|
7
7
|
import "./chunk-WZSRQNQG.js";
|
|
8
|
-
import "./chunk-
|
|
9
|
-
import "./chunk-
|
|
8
|
+
import "./chunk-AL2V7U3E.js";
|
|
9
|
+
import "./chunk-4PWB7JRR.js";
|
|
10
10
|
import "./chunk-4VNS5WPM.js";
|
|
11
11
|
export {
|
|
12
12
|
buildSkillDiscoveryContextBlock,
|
|
@@ -1,34 +1,34 @@
|
|
|
1
1
|
import {
|
|
2
2
|
readLiveDbRecordAfterTombstoneMerge
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-2ZLEOGS5.js";
|
|
4
4
|
import {
|
|
5
5
|
readDbRecord,
|
|
6
6
|
writeAgentRecord
|
|
7
|
-
} from "./chunk-
|
|
8
|
-
import "./chunk-
|
|
7
|
+
} from "./chunk-NZBK3ZET.js";
|
|
8
|
+
import "./chunk-XG7CSGP3.js";
|
|
9
9
|
import "./chunk-VHBWHNVT.js";
|
|
10
10
|
import "./chunk-KQHGZWSV.js";
|
|
11
11
|
import {
|
|
12
12
|
authRoutes
|
|
13
13
|
} from "./chunk-MRC4Q34M.js";
|
|
14
|
-
import "./chunk-
|
|
14
|
+
import "./chunk-5QJFYG2N.js";
|
|
15
15
|
import "./chunk-AAODAAUQ.js";
|
|
16
16
|
import "./chunk-ZNFJWEN4.js";
|
|
17
17
|
import "./chunk-OIQPORYI.js";
|
|
18
|
-
import "./chunk-
|
|
18
|
+
import "./chunk-ZDDHKIWB.js";
|
|
19
19
|
import "./chunk-LSFAWXKC.js";
|
|
20
|
-
import "./chunk-
|
|
20
|
+
import "./chunk-SOW2GCA5.js";
|
|
21
21
|
import "./chunk-KFEVY3ST.js";
|
|
22
22
|
import "./chunk-MUCU6ATG.js";
|
|
23
|
-
import "./chunk-
|
|
24
|
-
import "./chunk-
|
|
23
|
+
import "./chunk-OSIJVBXP.js";
|
|
24
|
+
import "./chunk-PFW2ZEON.js";
|
|
25
25
|
import "./chunk-5MMAK75Q.js";
|
|
26
26
|
import "./chunk-HQPG2PIV.js";
|
|
27
27
|
import "./chunk-5CS33IBL.js";
|
|
28
28
|
import "./chunk-JZPBVBIY.js";
|
|
29
29
|
import "./chunk-ZHXJ6M7T.js";
|
|
30
|
-
import "./chunk-
|
|
31
|
-
import "./chunk-
|
|
30
|
+
import "./chunk-AL2V7U3E.js";
|
|
31
|
+
import "./chunk-4PWB7JRR.js";
|
|
32
32
|
import "./chunk-DWLEOOGR.js";
|
|
33
33
|
import "./chunk-HNMXYYJR.js";
|
|
34
34
|
import "./chunk-IDZTNRP2.js";
|
|
@@ -52,17 +52,17 @@ import {
|
|
|
52
52
|
updateContentTitle,
|
|
53
53
|
updateSpace,
|
|
54
54
|
uploadAndAddFileToSpace
|
|
55
|
-
} from "./chunk-
|
|
55
|
+
} from "./chunk-2OK7P5XF.js";
|
|
56
56
|
import "./chunk-XOIF2TNF.js";
|
|
57
57
|
import "./chunk-MRC4Q34M.js";
|
|
58
58
|
import "./chunk-MTU75CZ2.js";
|
|
59
59
|
import "./chunk-CWMSB67P.js";
|
|
60
|
-
import "./chunk-
|
|
60
|
+
import "./chunk-ECGTEOC2.js";
|
|
61
61
|
import "./chunk-RPDGJO4D.js";
|
|
62
62
|
import "./chunk-SOTZ6RDN.js";
|
|
63
63
|
import "./chunk-Z4NR32XR.js";
|
|
64
64
|
import "./chunk-M76ECQRD.js";
|
|
65
|
-
import "./chunk-
|
|
65
|
+
import "./chunk-PFW2ZEON.js";
|
|
66
66
|
import "./chunk-5MMAK75Q.js";
|
|
67
67
|
import "./chunk-HQPG2PIV.js";
|
|
68
68
|
import "./chunk-5CS33IBL.js";
|
|
@@ -17,11 +17,11 @@ import {
|
|
|
17
17
|
sanitizeOutboundResponsesInput,
|
|
18
18
|
sendOpenAICompletionsRequest,
|
|
19
19
|
updateTotalUsage
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-TUWPYUVR.js";
|
|
21
21
|
import "./chunk-JEXVIMYZ.js";
|
|
22
22
|
import {
|
|
23
23
|
prepareTools
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-GM37ZF7R.js";
|
|
25
25
|
import {
|
|
26
26
|
fetchReferenceContents,
|
|
27
27
|
generateRequestBody,
|
|
@@ -35,7 +35,7 @@ import {
|
|
|
35
35
|
resolveToolsFromKeys,
|
|
36
36
|
selectResponsesConversationState,
|
|
37
37
|
updateResponsesConversationState
|
|
38
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-6IGLIDDE.js";
|
|
39
39
|
import "./chunk-L6NVTGI7.js";
|
|
40
40
|
import {
|
|
41
41
|
TOOL_PACKS,
|
|
@@ -50,13 +50,13 @@ import {
|
|
|
50
50
|
resolveEffectiveEnabledPacks,
|
|
51
51
|
shouldBlockForGptPro,
|
|
52
52
|
waitForAbortableDelay
|
|
53
|
-
} from "./chunk-
|
|
53
|
+
} from "./chunk-URVWRKFU.js";
|
|
54
54
|
import "./chunk-RQSOAMPJ.js";
|
|
55
55
|
import "./chunk-XJITGCTM.js";
|
|
56
56
|
import "./chunk-KQHGZWSV.js";
|
|
57
57
|
import {
|
|
58
58
|
getDocState
|
|
59
|
-
} from "./chunk-
|
|
59
|
+
} from "./chunk-GFPESFS6.js";
|
|
60
60
|
import {
|
|
61
61
|
getFinalPrice,
|
|
62
62
|
getModelPricing,
|
|
@@ -74,7 +74,7 @@ import {
|
|
|
74
74
|
} from "./chunk-VP4WJWKW.js";
|
|
75
75
|
import "./chunk-63W5N6P3.js";
|
|
76
76
|
import "./chunk-VF4K2QE6.js";
|
|
77
|
-
import "./chunk-
|
|
77
|
+
import "./chunk-Q6B6XJBG.js";
|
|
78
78
|
import "./chunk-VC6OZXO5.js";
|
|
79
79
|
import {
|
|
80
80
|
PERSONALIZATION_DIALOG_CATEGORY,
|
|
@@ -97,12 +97,12 @@ import {
|
|
|
97
97
|
selectTableRows,
|
|
98
98
|
selectViewMode,
|
|
99
99
|
updateTokens
|
|
100
|
-
} from "./chunk-
|
|
100
|
+
} from "./chunk-2OK7P5XF.js";
|
|
101
101
|
import "./chunk-XOIF2TNF.js";
|
|
102
102
|
import "./chunk-MRC4Q34M.js";
|
|
103
103
|
import "./chunk-MTU75CZ2.js";
|
|
104
104
|
import "./chunk-CWMSB67P.js";
|
|
105
|
-
import "./chunk-
|
|
105
|
+
import "./chunk-ECGTEOC2.js";
|
|
106
106
|
import {
|
|
107
107
|
createCliChatTurnStream,
|
|
108
108
|
getCliChatSession,
|
|
@@ -120,9 +120,9 @@ import {
|
|
|
120
120
|
import {
|
|
121
121
|
projectToolMessageContent,
|
|
122
122
|
resolveAgentImageInputSupport
|
|
123
|
-
} from "./chunk-
|
|
123
|
+
} from "./chunk-ZDDHKIWB.js";
|
|
124
124
|
import "./chunk-LSFAWXKC.js";
|
|
125
|
-
import "./chunk-
|
|
125
|
+
import "./chunk-SOW2GCA5.js";
|
|
126
126
|
import {
|
|
127
127
|
extractImagePartsFromResponseOutput,
|
|
128
128
|
extractTextFromResponseOutput,
|
|
@@ -133,13 +133,13 @@ import {
|
|
|
133
133
|
canonicalizeToolNames,
|
|
134
134
|
prioritizeToolNames,
|
|
135
135
|
resolveRuntimeToolSurfaceForAgent
|
|
136
|
-
} from "./chunk-
|
|
136
|
+
} from "./chunk-OSIJVBXP.js";
|
|
137
137
|
import {
|
|
138
138
|
estimateTokenCount,
|
|
139
139
|
getModelContextWindow,
|
|
140
140
|
getModelInfo,
|
|
141
141
|
planContextUsage
|
|
142
|
-
} from "./chunk-
|
|
142
|
+
} from "./chunk-PFW2ZEON.js";
|
|
143
143
|
import "./chunk-5MMAK75Q.js";
|
|
144
144
|
import {
|
|
145
145
|
getApiEndpoint,
|
|
@@ -152,8 +152,8 @@ import "./chunk-ZHXJ6M7T.js";
|
|
|
152
152
|
import {
|
|
153
153
|
buildLinkedSpacesSection,
|
|
154
154
|
buildSpaceContextLayer
|
|
155
|
-
} from "./chunk-
|
|
156
|
-
import "./chunk-
|
|
155
|
+
} from "./chunk-AL2V7U3E.js";
|
|
156
|
+
import "./chunk-4PWB7JRR.js";
|
|
157
157
|
import {
|
|
158
158
|
resolveToolBaseUrl
|
|
159
159
|
} from "./chunk-5MIDPSSK.js";
|
|
@@ -171,6 +171,7 @@ import {
|
|
|
171
171
|
tokenUsageLiveUpdate
|
|
172
172
|
} from "./chunk-3ASDTTEI.js";
|
|
173
173
|
import "./chunk-DWLEOOGR.js";
|
|
174
|
+
import "./chunk-FKXFCYVO.js";
|
|
174
175
|
import {
|
|
175
176
|
buildCliPrompt
|
|
176
177
|
} from "./chunk-ATNTHIZI.js";
|
|
@@ -420,10 +421,10 @@ var difference = (arrA, arrB) => {
|
|
|
420
421
|
const exclude = new Set(arrB);
|
|
421
422
|
return arrA.filter((item) => !exclude.has(item));
|
|
422
423
|
};
|
|
423
|
-
var getFullChatContextKeys = async (state, dispatch, agentConfig, userInput,
|
|
424
|
+
var getFullChatContextKeys = async (state, dispatch, agentConfig, userInput, dialogConfig2) => {
|
|
424
425
|
const msgs = selectAllMsgs(
|
|
425
426
|
state,
|
|
426
|
-
|
|
427
|
+
dialogConfig2?.dbKey ? extractCustomId(dialogConfig2.dbKey) : dialogConfig2?.id
|
|
427
428
|
);
|
|
428
429
|
const botInstructionKeys = /* @__PURE__ */ new Set();
|
|
429
430
|
const botKnowledgeKeys = /* @__PURE__ */ new Set();
|
|
@@ -445,7 +446,7 @@ var getFullChatContextKeys = async (state, dispatch, agentConfig, userInput, dia
|
|
|
445
446
|
}
|
|
446
447
|
}
|
|
447
448
|
const historyKeys = /* @__PURE__ */ new Set();
|
|
448
|
-
const savedKeys =
|
|
449
|
+
const savedKeys = dialogConfig2?.referenceKeys;
|
|
449
450
|
if (Array.isArray(savedKeys)) {
|
|
450
451
|
savedKeys.forEach((k) => historyKeys.add(k));
|
|
451
452
|
}
|
|
@@ -456,7 +457,7 @@ var getFullChatContextKeys = async (state, dispatch, agentConfig, userInput, dia
|
|
|
456
457
|
}
|
|
457
458
|
};
|
|
458
459
|
if (msgs && msgs.length > 0) {
|
|
459
|
-
const summarizedBeforeId =
|
|
460
|
+
const summarizedBeforeId = dialogConfig2?.summarizedBeforeId;
|
|
460
461
|
if (!summarizedBeforeId) {
|
|
461
462
|
for (const msg of msgs) scanContentParts(msg);
|
|
462
463
|
} else {
|
|
@@ -515,7 +516,7 @@ var deduplicateContextKeys = (keys) => {
|
|
|
515
516
|
};
|
|
516
517
|
|
|
517
518
|
// packages/ai/chat/streamRetry.ts
|
|
518
|
-
var MAX_INITIAL_STREAM_RETRIES =
|
|
519
|
+
var MAX_INITIAL_STREAM_RETRIES = 3;
|
|
519
520
|
var DEFAULT_INITIAL_STREAM_RETRY_AFTER_MS = 1500;
|
|
520
521
|
var normalizeInitialStreamRetryAfterMs = (value) => {
|
|
521
522
|
const parsed = Number(value);
|
|
@@ -904,7 +905,23 @@ var sendOpenAIResponseRequest = async ({
|
|
|
904
905
|
currentServer: selectRuntimeCurrentServer(getState()),
|
|
905
906
|
signal,
|
|
906
907
|
token: token ?? "",
|
|
907
|
-
dialogId
|
|
908
|
+
dialogId,
|
|
909
|
+
onRetry: (info) => {
|
|
910
|
+
dispatch(
|
|
911
|
+
messageStreaming({
|
|
912
|
+
id: messageId,
|
|
913
|
+
dialogId,
|
|
914
|
+
dbKey: msgKey,
|
|
915
|
+
content: "",
|
|
916
|
+
role: "assistant",
|
|
917
|
+
agentKey: agentConfig.dbKey,
|
|
918
|
+
cybotKey: agentConfig.dbKey,
|
|
919
|
+
...activeMessageMetadata ?? {},
|
|
920
|
+
isStreaming: true,
|
|
921
|
+
retryProgress: info
|
|
922
|
+
})
|
|
923
|
+
);
|
|
924
|
+
}
|
|
908
925
|
});
|
|
909
926
|
logQuickChatPerfStage(quickChatPerfStartedAt, "openai-response-fetch-response", {
|
|
910
927
|
ok: response.ok,
|
|
@@ -1891,7 +1908,7 @@ var validateAccessAndBalance = (agentConfig, state) => {
|
|
|
1891
1908
|
}
|
|
1892
1909
|
return null;
|
|
1893
1910
|
};
|
|
1894
|
-
var fetchMemoryOverlayContext = async (state, agentConfig, userInput,
|
|
1911
|
+
var fetchMemoryOverlayContext = async (state, agentConfig, userInput, dialogConfig2, memorySubjectId) => {
|
|
1895
1912
|
const token = typeof state?.auth?.currentToken === "string" ? state.auth.currentToken : null;
|
|
1896
1913
|
const currentServer = typeof state?.settings?.currentServer === "string" ? state.settings.currentServer : null;
|
|
1897
1914
|
const agentKey = asOptionalTrimmedString(agentConfig.dbKey) ?? "";
|
|
@@ -1899,7 +1916,7 @@ var fetchMemoryOverlayContext = async (state, agentConfig, userInput, dialogConf
|
|
|
1899
1916
|
const baseUrl = resolveToolBaseUrl(currentServer);
|
|
1900
1917
|
if (!baseUrl) return null;
|
|
1901
1918
|
const inputText = typeof userInput === "string" ? userInput : JSON.stringify(userInput ?? "");
|
|
1902
|
-
const spaceId = asOptionalTrimmedString(
|
|
1919
|
+
const spaceId = asOptionalTrimmedString(dialogConfig2?.spaceId) ?? (state?.space?.viewMode === "all" ? void 0 : asOptionalTrimmedString(state?.space?.currentSpaceId));
|
|
1903
1920
|
try {
|
|
1904
1921
|
const response = await fetch(`${baseUrl}/api/memory/query`, {
|
|
1905
1922
|
method: "POST",
|
|
@@ -1909,6 +1926,7 @@ var fetchMemoryOverlayContext = async (state, agentConfig, userInput, dialogConf
|
|
|
1909
1926
|
},
|
|
1910
1927
|
body: JSON.stringify({
|
|
1911
1928
|
agentKey,
|
|
1929
|
+
...asOptionalTrimmedString(memorySubjectId) ? { memorySubjectId: asOptionalTrimmedString(memorySubjectId) } : {},
|
|
1912
1930
|
userInput: inputText,
|
|
1913
1931
|
...spaceId ? { spaceId } : {}
|
|
1914
1932
|
})
|
|
@@ -1920,7 +1938,7 @@ var fetchMemoryOverlayContext = async (state, agentConfig, userInput, dialogConf
|
|
|
1920
1938
|
return null;
|
|
1921
1939
|
}
|
|
1922
1940
|
};
|
|
1923
|
-
var buildStaticContexts = async (state, dispatch, agentConfig,
|
|
1941
|
+
var buildStaticContexts = async (state, dispatch, agentConfig, dialogConfig2, referenceContentCache) => {
|
|
1924
1942
|
const keySets = await getFullChatContextKeys(
|
|
1925
1943
|
state,
|
|
1926
1944
|
dispatch,
|
|
@@ -1954,7 +1972,7 @@ var buildStaticContexts = async (state, dispatch, agentConfig, dialogConfig, ref
|
|
|
1954
1972
|
if (spaceContextLevel > 1) {
|
|
1955
1973
|
const spaceLayer = await buildSpaceContextLayer({
|
|
1956
1974
|
source: turnContextSource,
|
|
1957
|
-
spaceId:
|
|
1975
|
+
spaceId: dialogConfig2?.spaceId,
|
|
1958
1976
|
recentContentLimit: recentLimit
|
|
1959
1977
|
});
|
|
1960
1978
|
spaceContext = spaceLayer ? spaceLayer.content.trim() : null;
|
|
@@ -1971,7 +1989,7 @@ var buildStaticContexts = async (state, dispatch, agentConfig, dialogConfig, ref
|
|
|
1971
1989
|
${linkedSection}`;
|
|
1972
1990
|
}
|
|
1973
1991
|
}
|
|
1974
|
-
const dialogPolicyContext =
|
|
1992
|
+
const dialogPolicyContext = dialogConfig2?.category === PERSONALIZATION_DIALOG_CATEGORY ? buildPersonalizationDialogPolicyContext() : null;
|
|
1975
1993
|
return {
|
|
1976
1994
|
botInstructionsContext: joinMapValues(botInstructionsMap),
|
|
1977
1995
|
botKnowledgeContext: joinMapValues(botKnowledgeMap),
|
|
@@ -1993,11 +2011,11 @@ ${linkedSection}`;
|
|
|
1993
2011
|
};
|
|
1994
2012
|
var buildDynamicContexts = async (state, dispatch, agentConfig, userInput, runtimeOptions, referenceContentCache, dialogKey) => {
|
|
1995
2013
|
let dialogSummary = null;
|
|
1996
|
-
let
|
|
2014
|
+
let dialogConfig2;
|
|
1997
2015
|
if (dialogKey) {
|
|
1998
|
-
|
|
1999
|
-
if (
|
|
2000
|
-
dialogSummary =
|
|
2016
|
+
dialogConfig2 = selectById(state, dialogKey);
|
|
2017
|
+
if (dialogConfig2?.summary) {
|
|
2018
|
+
dialogSummary = dialogConfig2.summary;
|
|
2001
2019
|
}
|
|
2002
2020
|
}
|
|
2003
2021
|
const keySets = await getFullChatContextKeys(
|
|
@@ -2005,7 +2023,7 @@ var buildDynamicContexts = async (state, dispatch, agentConfig, userInput, runti
|
|
|
2005
2023
|
dispatch,
|
|
2006
2024
|
agentConfig,
|
|
2007
2025
|
userInput,
|
|
2008
|
-
|
|
2026
|
+
dialogConfig2
|
|
2009
2027
|
);
|
|
2010
2028
|
const finalKeys = deduplicateContextKeys(keySets);
|
|
2011
2029
|
const fetchReferences = (keys) => fetchReferenceContents(keys, dispatch, {
|
|
@@ -2022,7 +2040,7 @@ var buildDynamicContexts = async (state, dispatch, agentConfig, userInput, runti
|
|
|
2022
2040
|
pendingFiles,
|
|
2023
2041
|
currentInputMap
|
|
2024
2042
|
);
|
|
2025
|
-
const dialogId =
|
|
2043
|
+
const dialogId = dialogConfig2?.id ?? null;
|
|
2026
2044
|
const currentDialogMessages = selectAllMsgs(state, dialogId);
|
|
2027
2045
|
const currentDialogMessageIds = new Set(currentDialogMessages.map((msg) => msg.id));
|
|
2028
2046
|
const currentDialogToolRuns = getAllToolRuns().filter(
|
|
@@ -2037,7 +2055,8 @@ var buildDynamicContexts = async (state, dispatch, agentConfig, userInput, runti
|
|
|
2037
2055
|
state,
|
|
2038
2056
|
agentConfig,
|
|
2039
2057
|
userInput,
|
|
2040
|
-
|
|
2058
|
+
dialogConfig2,
|
|
2059
|
+
runtimeOptions?.memorySubjectId
|
|
2041
2060
|
);
|
|
2042
2061
|
return {
|
|
2043
2062
|
currentInputContext: formattedCurrentInputContext.trim() || null,
|
|
@@ -2046,7 +2065,7 @@ var buildDynamicContexts = async (state, dispatch, agentConfig, userInput, runti
|
|
|
2046
2065
|
appWorkingMemory,
|
|
2047
2066
|
memoryOverlay,
|
|
2048
2067
|
dialogSummary,
|
|
2049
|
-
referenceKeys:
|
|
2068
|
+
referenceKeys: dialogConfig2?.referenceKeys || []
|
|
2050
2069
|
};
|
|
2051
2070
|
};
|
|
2052
2071
|
var mergeContexts = (staticCtx, dynamicCtx) => ({
|
|
@@ -2821,22 +2840,22 @@ var isSimpleTextInput = (userInput) => {
|
|
|
2821
2840
|
(part) => part && typeof part === "object" && part.type === "text" && typeof part.text === "string"
|
|
2822
2841
|
);
|
|
2823
2842
|
};
|
|
2824
|
-
var canUseQuickChatEmptyDynamicContexts = (quickChatPerfStartedAt, userInput, runtimeOptions,
|
|
2843
|
+
var canUseQuickChatEmptyDynamicContexts = (quickChatPerfStartedAt, userInput, runtimeOptions, dialogConfig2, agentConfig) => {
|
|
2825
2844
|
if (!quickChatPerfStartedAt) return false;
|
|
2826
2845
|
if (runtimeOptions) return false;
|
|
2827
2846
|
if (agentConfig?.tools?.includes("rememberMemory")) return false;
|
|
2828
2847
|
if (!isSimpleTextInput(userInput)) return false;
|
|
2829
|
-
if (
|
|
2848
|
+
if (dialogConfig2?.referenceKeys?.length) return false;
|
|
2830
2849
|
return true;
|
|
2831
2850
|
};
|
|
2832
2851
|
var QUICK_CHAT_DIRECT_ANSWER_PATTERN = /(只回复|只输出|只回答|直接回复|直接回答|不要解释|无需解释|不用解释|简短回答|一句话)/i;
|
|
2833
2852
|
var QUICK_CHAT_TOOL_INTENT_PATTERN = /(调用|转交|agent|助手|应用|网页|页面|图表|图片|生成图|画图|删除|清理|空间|商品|链接|https?:\/\/|www\.|@)/i;
|
|
2834
|
-
var shouldDisableQuickChatToolsForDirectAnswer = (quickChatPerfStartedAt, userInput, runtimeOptions,
|
|
2853
|
+
var shouldDisableQuickChatToolsForDirectAnswer = (quickChatPerfStartedAt, userInput, runtimeOptions, dialogConfig2) => {
|
|
2835
2854
|
if (!canUseQuickChatEmptyDynamicContexts(
|
|
2836
2855
|
quickChatPerfStartedAt,
|
|
2837
2856
|
userInput,
|
|
2838
2857
|
runtimeOptions,
|
|
2839
|
-
|
|
2858
|
+
dialogConfig2,
|
|
2840
2859
|
void 0
|
|
2841
2860
|
)) {
|
|
2842
2861
|
return false;
|
|
@@ -3141,11 +3160,11 @@ var streamAgentChatTurnHandler = async (args, thunkApi) => {
|
|
|
3141
3160
|
if (w2) w2.__LOOP_STOP_REASON__ = null;
|
|
3142
3161
|
const userText = extractAgentRunUserText(userInput);
|
|
3143
3162
|
const prompt = buildCliPrompt(agentConfig.prompt, userText);
|
|
3144
|
-
const
|
|
3145
|
-
if (!
|
|
3163
|
+
const dialogConfig2 = selectDialogConfigByKey(currentState, explicitDialogKey) ?? selectCurrentDialogConfig(currentState);
|
|
3164
|
+
if (!dialogConfig2) {
|
|
3146
3165
|
return rejectWithValue("Dialog config not found");
|
|
3147
3166
|
}
|
|
3148
|
-
const dialogKey2 = explicitDialogKey ||
|
|
3167
|
+
const dialogKey2 = explicitDialogKey || dialogConfig2.dbKey;
|
|
3149
3168
|
if (!dialogKey2) {
|
|
3150
3169
|
return rejectWithValue("\u5F53\u524D\u5BF9\u8BDD\u4E0D\u5B58\u5728\uFF0C\u65E0\u6CD5\u53D1\u9001\u6D88\u606F\u3002");
|
|
3151
3170
|
}
|
|
@@ -3225,7 +3244,7 @@ var streamAgentChatTurnHandler = async (args, thunkApi) => {
|
|
|
3225
3244
|
entrypoint: "chat-dialog",
|
|
3226
3245
|
capabilities: ["streaming", "dialog-ui", "machine-bound-cli"]
|
|
3227
3246
|
},
|
|
3228
|
-
...
|
|
3247
|
+
...dialogConfig2?.spaceId ? { spaceId: dialogConfig2.spaceId } : {}
|
|
3229
3248
|
}),
|
|
3230
3249
|
signal: loopController.signal
|
|
3231
3250
|
});
|
|
@@ -3334,7 +3353,7 @@ var streamAgentChatTurnHandler = async (args, thunkApi) => {
|
|
|
3334
3353
|
usage: totalTurnUsage2 ?? void 0
|
|
3335
3354
|
};
|
|
3336
3355
|
}
|
|
3337
|
-
let cliSessionId =
|
|
3356
|
+
let cliSessionId = dialogConfig2.cliSessionId ?? null;
|
|
3338
3357
|
dispatch(messageStreaming({
|
|
3339
3358
|
id: messageId,
|
|
3340
3359
|
dialogId: dialogId2,
|
|
@@ -4032,7 +4051,9 @@ var streamAgentChatTurnHandler = async (args, thunkApi) => {
|
|
|
4032
4051
|
host: "browser",
|
|
4033
4052
|
runtime: "react",
|
|
4034
4053
|
entrypoint: "chat-dialog",
|
|
4035
|
-
capabilities: ["streaming", "dialog-ui", "tool-cards"]
|
|
4054
|
+
capabilities: ["streaming", "dialog-ui", "tool-cards"],
|
|
4055
|
+
...runtimeOptions?.memorySubjectId ? { memorySubjectId: runtimeOptions.memorySubjectId } : {},
|
|
4056
|
+
...dialogConfig?.agentMode ? { dialogAgentMode: dialogConfig.agentMode } : {}
|
|
4036
4057
|
},
|
|
4037
4058
|
...runtimeOptions?.quickChatReasoningEffort ? {
|
|
4038
4059
|
runtimeOptions: {
|
|
@@ -11,31 +11,31 @@ import {
|
|
|
11
11
|
toolQueryFunc,
|
|
12
12
|
toolQueryFunctionSchema,
|
|
13
13
|
toolRegistry
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-URVWRKFU.js";
|
|
15
15
|
import "./chunk-RQSOAMPJ.js";
|
|
16
16
|
import "./chunk-XJITGCTM.js";
|
|
17
17
|
import "./chunk-KQHGZWSV.js";
|
|
18
|
-
import "./chunk-
|
|
18
|
+
import "./chunk-GFPESFS6.js";
|
|
19
19
|
import "./chunk-6N4KODMN.js";
|
|
20
20
|
import "./chunk-3LY4F7SV.js";
|
|
21
21
|
import "./chunk-VP4WJWKW.js";
|
|
22
22
|
import "./chunk-63W5N6P3.js";
|
|
23
23
|
import "./chunk-VF4K2QE6.js";
|
|
24
|
-
import "./chunk-
|
|
24
|
+
import "./chunk-Q6B6XJBG.js";
|
|
25
25
|
import "./chunk-VC6OZXO5.js";
|
|
26
|
-
import "./chunk-
|
|
26
|
+
import "./chunk-2OK7P5XF.js";
|
|
27
27
|
import "./chunk-XOIF2TNF.js";
|
|
28
28
|
import "./chunk-MRC4Q34M.js";
|
|
29
29
|
import "./chunk-MTU75CZ2.js";
|
|
30
30
|
import "./chunk-CWMSB67P.js";
|
|
31
|
-
import "./chunk-
|
|
31
|
+
import "./chunk-ECGTEOC2.js";
|
|
32
32
|
import "./chunk-RPDGJO4D.js";
|
|
33
33
|
import "./chunk-SOTZ6RDN.js";
|
|
34
34
|
import "./chunk-Z4NR32XR.js";
|
|
35
35
|
import "./chunk-M76ECQRD.js";
|
|
36
36
|
import "./chunk-WZSRQNQG.js";
|
|
37
|
-
import "./chunk-
|
|
38
|
-
import "./chunk-
|
|
37
|
+
import "./chunk-OSIJVBXP.js";
|
|
38
|
+
import "./chunk-PFW2ZEON.js";
|
|
39
39
|
import "./chunk-5MMAK75Q.js";
|
|
40
40
|
import "./chunk-HQPG2PIV.js";
|
|
41
41
|
import "./chunk-5CS33IBL.js";
|
|
@@ -45,6 +45,7 @@ import "./chunk-5MIDPSSK.js";
|
|
|
45
45
|
import "./chunk-DFFIZ25G.js";
|
|
46
46
|
import "./chunk-3ASDTTEI.js";
|
|
47
47
|
import "./chunk-DWLEOOGR.js";
|
|
48
|
+
import "./chunk-FKXFCYVO.js";
|
|
48
49
|
import "./chunk-HNMXYYJR.js";
|
|
49
50
|
import "./chunk-RK5NYQEL.js";
|
|
50
51
|
import "./chunk-O6W2O2DA.js";
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
isAssistantToolStub,
|
|
7
7
|
selectAllMsgs,
|
|
8
8
|
updateContentTitle
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-2OK7P5XF.js";
|
|
10
10
|
import {
|
|
11
11
|
BUILTIN_TITLE_LLM_CONFIG
|
|
12
12
|
} from "./chunk-XOIF2TNF.js";
|
|
@@ -15,7 +15,7 @@ import "./chunk-MTU75CZ2.js";
|
|
|
15
15
|
import "./chunk-CWMSB67P.js";
|
|
16
16
|
import {
|
|
17
17
|
runLlm
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-ECGTEOC2.js";
|
|
19
19
|
import "./chunk-RPDGJO4D.js";
|
|
20
20
|
import "./chunk-SOTZ6RDN.js";
|
|
21
21
|
import "./chunk-Z4NR32XR.js";
|
|
@@ -24,7 +24,7 @@ import {
|
|
|
24
24
|
} from "./chunk-M76ECQRD.js";
|
|
25
25
|
import {
|
|
26
26
|
serializeMessageContent
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-PFW2ZEON.js";
|
|
28
28
|
import "./chunk-5MMAK75Q.js";
|
|
29
29
|
import "./chunk-HQPG2PIV.js";
|
|
30
30
|
import "./chunk-5CS33IBL.js";
|