nolo-cli 0.170.1 → 0.172.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-7J6IIHWQ.js → _executeModel-PVY4AXG4.js} +29 -29
- package/{agentDeleteCommand-F66NIWCF.js → agentDeleteCommand-QYNICESQ.js} +38 -37
- package/{agentEmailCommands-M4SHODDA.js → agentEmailCommands-QEJHRESH.js} +42 -41
- package/{agentListCommands-4BBFWXHX.js → agentListCommands-MGMBNFAS.js} +24 -23
- package/{agentMachineCommands-R55P5SZY.js → agentMachineCommands-SKOAHGVC.js} +22 -21
- package/{agentProviderCommands-4USYTCL3.js → agentProviderCommands-TWVILNAN.js} +2 -2
- package/{agentRecordCommands-PDWACZFR.js → agentRecordCommands-2NVWBDQN.js} +38 -37
- package/{agentRunCommand-U2F74LTS.js → agentRunCommand-2LHV37FZ.js} +39 -38
- package/{agentRunControl-EI3BGJFM.js → agentRunControl-SBHIICUQ.js} +5 -5
- package/{agentRuntimeLocal-7EZYBR6X.js → agentRuntimeLocal-K3777H5R.js} +20 -19
- package/{agentSlice-UN7ZHCAM.js → agentSlice-QMOFHPJR.js} +3 -3
- package/{appDeleteCommands-WS3UFMCB.js → appDeleteCommands-3HZNWZ2V.js} +23 -22
- package/{appDeployCommands-W5B7I73P.js → appDeployCommands-Q5BIBQE2.js} +23 -22
- package/{appDeployStatusCommands-UEHNV2GU.js → appDeployStatusCommands-ZZFFVM3W.js} +23 -22
- package/{appGetCommands-XJOBVREN.js → appGetCommands-7AAOXZQK.js} +23 -22
- package/{appListCommands-BISQV6BQ.js → appListCommands-H76IX2X5.js} +23 -22
- package/{authCommand-H35CPF25.js → authCommand-BSOLJFPV.js} +12 -12
- package/{builtinSkillRegistry-LJV7FHNI.js → builtinSkillRegistry-V76JTNCJ.js} +2 -2
- package/{chunk-DHNQA4VI.js → chunk-2FAQDT6E.js} +1 -1
- package/chunk-2WZXXAQD.js +57 -0
- package/{chunk-SH3XD4E2.js → chunk-3LNVSFTH.js} +2 -1
- package/{chunk-WC7UXON2.js → chunk-3XUE7WJA.js} +95 -38
- package/{chunk-XLBQQ5SB.js → chunk-54YLFF7P.js} +4 -4
- package/{chunk-O2AY3CVI.js → chunk-7OQ7IDU3.js} +19 -17
- package/{chunk-HEC32F3G.js → chunk-7TBARDLF.js} +1 -46
- package/{chunk-G3VYRPTV.js → chunk-AJ52EA72.js} +4 -4
- package/{chunk-JPPQ3GUO.js → chunk-APB44JID.js} +3 -3
- package/{chunk-XITIONPS.js → chunk-BE42X662.js} +4 -4
- package/{chunk-ASSNAASW.js → chunk-BKCR2JHG.js} +48 -3
- package/{chunk-IMMA7QFE.js → chunk-CAAH5LNN.js} +2 -2
- package/{chunk-45IOFLGH.js → chunk-CFLYUFMA.js} +11 -11
- package/{chunk-URW5UM6Y.js → chunk-CI5DVWU7.js} +1 -1
- package/{chunk-CMRP4XHV.js → chunk-DNQ55DHN.js} +13 -13
- package/{chunk-CEQFVBI2.js → chunk-EK3LIELB.js} +3 -3
- package/{chunk-IOFLVIKF.js → chunk-EWLPIR2S.js} +1 -1
- package/{chunk-6EQD4AQL.js → chunk-GC64WGMD.js} +1 -1
- package/{chunk-CEXJ6Y3C.js → chunk-HBUKJB3W.js} +9 -1
- package/{chunk-FYYSDHVQ.js → chunk-HLAL63BZ.js} +1 -1
- package/{chunk-PIG2IUVZ.js → chunk-I2QHI2XM.js} +2 -2
- package/{chunk-BSKTDOGA.js → chunk-I33CJERI.js} +3 -58
- package/{chunk-7VWWGKEQ.js → chunk-ISMHFI2Y.js} +3 -3
- package/{chunk-3ELX6JK5.js → chunk-JCILHZJZ.js} +10 -10
- package/{chunk-FQU23S3P.js → chunk-JIGBVOHH.js} +11 -11
- package/{chunk-I7S63QUU.js → chunk-KNDA4K34.js} +1 -1
- package/{chunk-Z6HR75HX.js → chunk-KUA3PPFK.js} +3 -3
- package/{chunk-2DXGW4UO.js → chunk-ME7N4YHG.js} +142 -30
- package/{chunk-WLPUUBFR.js → chunk-MOOQN57G.js} +3 -3
- package/{chunk-URO44BCD.js → chunk-MTAWQNSU.js} +1 -1
- package/{chunk-KJETBEEN.js → chunk-OPNHKULV.js} +1 -1
- package/{chunk-EWO77ZGF.js → chunk-OQ3DOBYB.js} +3 -3
- package/{chunk-2AZSL4GL.js → chunk-PPR6G2U2.js} +3 -3
- package/{chunk-TOUKACDK.js → chunk-RATR6VCP.js} +1 -1
- package/{chunk-DI7ZFGDQ.js → chunk-SHPY7A3P.js} +102 -3
- package/{chunk-LEZLJTQ4.js → chunk-SUBKVXFM.js} +1 -1
- package/{chunk-ZPKUJROL.js → chunk-TDNAAXUQ.js} +2 -2
- package/{chunk-3USFOET4.js → chunk-TI7ZIWYR.js} +3 -3
- package/{chunk-SQX235S2.js → chunk-TSCI6X6C.js} +1 -1
- package/{chunk-V7PCFWX3.js → chunk-TVGX5QIN.js} +2 -2
- package/{chunk-XLQFVHNX.js → chunk-TYQZRSL6.js} +1 -1
- package/{chunk-QW6SSF7V.js → chunk-UMVEB5QT.js} +15 -15
- package/{chunk-WVREKHHJ.js → chunk-UU4TLYRZ.js} +3 -3
- package/{chunk-HZMWJUSD.js → chunk-VAQ3EGPC.js} +2 -2
- package/{chunk-MFVOJ6KF.js → chunk-W6E5IXIP.js} +3 -3
- package/{chunk-YCRROBDY.js → chunk-WXOKJP3W.js} +2 -1
- package/{chunk-SAZSXMTR.js → chunk-XBJIESNS.js} +4 -4
- package/{chunk-46OQD3AP.js → chunk-XUZQCRSA.js} +4 -4
- package/{chunk-KMDDG73K.js → chunk-XWX5ZGWR.js} +1 -1
- package/{chunk-7NKZA46B.js → chunk-YEOFTC2H.js} +10 -4
- package/{commandRegistry-3XBG7JHS.js → commandRegistry-D3V6AB3G.js} +56 -56
- package/{contentThunks-OO3MJAED.js → contentThunks-P2GNXUKN.js} +11 -11
- package/{createAgentAutomationAction-F3O6FJ5W.js → createAgentAutomationAction-PQA43W2W.js} +11 -11
- package/{createDialogAction-UBQKDUK5.js → createDialogAction-ITOZ5TAM.js} +13 -13
- package/{createPageAction-RDEDO4GF.js → createPageAction-IKB3LOMU.js} +11 -11
- package/{dialogCommands-P5HSDZ7T.js → dialogCommands-IZAQB6GY.js} +24 -23
- package/{dialogSlice-WZCWWYR3.js → dialogSlice-Y6WIZWTC.js} +10 -10
- package/{docCreateCommands-B2M3MGX7.js → docCreateCommands-U25MRSOL.js} +22 -21
- package/{docDeleteCommands-NHCUX4XL.js → docDeleteCommands-F46A6FJZ.js} +23 -22
- package/{docReadCommands-FOLST4JD.js → docReadCommands-DITPVWA3.js} +22 -21
- package/{docStore-PTSCGC6T.js → docStore-HRNZKKVS.js} +1 -1
- package/{docUpdateCommands-YZT2PQP2.js → docUpdateCommands-O447KO7Z.js} +22 -21
- package/{getPricing-XQ3N3RBP.js → getPricing-2UPNNW3Y.js} +3 -3
- package/{handleSendMessageAction-3YMQS6XO.js → handleSendMessageAction-4OVVUVJ4.js} +24 -23
- package/index.js +4 -4
- package/{localRuntimeAdapter-ZIAOTUBE.js → localRuntimeAdapter-CL3QW3OJ.js} +36 -35
- package/{machineCommands-3LSEP24P.js → machineCommands-T3VQCFHT.js} +37 -36
- package/{machineWsRunDispatch-7A3TSH4Q.js → machineWsRunDispatch-IGX4UK4C.js} +37 -36
- package/{models-PZQC7VV4.js → models-UUNO6DOL.js} +2 -2
- package/package.json +1 -1
- package/{providerPresetApply-PKUOHQJT.js → providerPresetApply-5K4PBX4J.js} +6 -6
- package/{providerRegistry-HNQLIFN2.js → providerRegistry-K5MSZ3Y5.js} +6 -6
- package/{readlineWorkspace-OFBP6OA7.js → readlineWorkspace-3IZBF57U.js} +45 -44
- package/{runAgentClientLoop-F6EQK26A.js → runAgentClientLoop-RUBF4JIP.js} +27 -27
- package/{runtimeDoctorCommands-LYMJEM4F.js → runtimeDoctorCommands-DXJH5HIB.js} +6 -6
- package/{secretCommands-DNY56NSU.js → secretCommands-7S6REMJV.js} +2 -2
- package/{spaceCommands-XESXH5CW.js → spaceCommands-FSATGIKW.js} +22 -21
- package/{streamAgentChatTurn-KXELVHFR.js → streamAgentChatTurn-N7UJ6FFK.js} +36 -35
- package/{tools-FMNDEVTZ.js → tools-Z7EJ6KIM.js} +21 -21
- package/{tuiSummaryLlmCaller-FQOEF4IE.js → tuiSummaryLlmCaller-ZETARZOH.js} +14 -8
- package/{updateDialogTitleAction-65R3Y22L.js → updateDialogTitleAction-CEFNJE4T.js} +11 -11
- package/{chunk-CGFNDIKK.js → chunk-5KTQVMCX.js} +0 -0
- package/{chunk-UHTDNB5Y.js → chunk-76YUTLOT.js} +3 -3
|
@@ -3,13 +3,56 @@ import {
|
|
|
3
3
|
} from "./chunk-PSCNXBYA.js";
|
|
4
4
|
import {
|
|
5
5
|
ALL_MODELS
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-HLAL63BZ.js";
|
|
7
7
|
import {
|
|
8
8
|
MODEL_LOOKUP_MAP
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-GC64WGMD.js";
|
|
10
10
|
import {
|
|
11
11
|
isPlatformManagedProvider
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-5KTQVMCX.js";
|
|
13
|
+
import {
|
|
14
|
+
asTrimmedLowercaseString
|
|
15
|
+
} from "./chunk-QSJ3HFEF.js";
|
|
16
|
+
|
|
17
|
+
// packages/agent-runtime/serverProxyPolicy.ts
|
|
18
|
+
var OAUTH_APIKEY_REFS = /* @__PURE__ */ new Set([
|
|
19
|
+
"antigravity",
|
|
20
|
+
"xai",
|
|
21
|
+
"chatgpt",
|
|
22
|
+
"claude",
|
|
23
|
+
"cursor"
|
|
24
|
+
]);
|
|
25
|
+
function isGoogleFamilyProvider(provider) {
|
|
26
|
+
const normalized = asTrimmedLowercaseString(provider);
|
|
27
|
+
return normalized === "google" || normalized.startsWith("google-");
|
|
28
|
+
}
|
|
29
|
+
function isOAuthApiKeyRef(value) {
|
|
30
|
+
const ref = asTrimmedLowercaseString(value);
|
|
31
|
+
return ref.length > 0 && OAUTH_APIKEY_REFS.has(ref);
|
|
32
|
+
}
|
|
33
|
+
function shouldUseServerProxy(agentConfig, requestProvider) {
|
|
34
|
+
const effectiveProvider = (requestProvider || agentConfig.provider || "").toLowerCase();
|
|
35
|
+
if (isGoogleFamilyProvider(effectiveProvider)) {
|
|
36
|
+
return true;
|
|
37
|
+
}
|
|
38
|
+
if (isOAuthApiKeyRef(agentConfig.apiKeyRef)) {
|
|
39
|
+
return true;
|
|
40
|
+
}
|
|
41
|
+
if (agentConfig.apiSource === "custom" && isRemoteCustomEndpoint(agentConfig.customProviderUrl)) {
|
|
42
|
+
return true;
|
|
43
|
+
}
|
|
44
|
+
return !!agentConfig.useServerProxy;
|
|
45
|
+
}
|
|
46
|
+
var LOCAL_HOSTS = /* @__PURE__ */ new Set(["127.0.0.1", "localhost", "::1", "0.0.0.0"]);
|
|
47
|
+
function isRemoteCustomEndpoint(url) {
|
|
48
|
+
if (typeof url !== "string") return false;
|
|
49
|
+
try {
|
|
50
|
+
const host = new URL(url).hostname.toLowerCase().replace(/^\[|\]$/g, "");
|
|
51
|
+
return !LOCAL_HOSTS.has(host);
|
|
52
|
+
} catch {
|
|
53
|
+
return false;
|
|
54
|
+
}
|
|
55
|
+
}
|
|
13
56
|
|
|
14
57
|
// packages/core/chat/messageContentSerialize.ts
|
|
15
58
|
var serializeMessageContent = (content, imagePlaceholder = "[\u56FE\u7247]") => {
|
|
@@ -1019,6 +1062,8 @@ export {
|
|
|
1019
1062
|
findModelContextWindow,
|
|
1020
1063
|
getModelContextWindow,
|
|
1021
1064
|
getModelInfo,
|
|
1065
|
+
isOAuthApiKeyRef,
|
|
1066
|
+
shouldUseServerProxy,
|
|
1022
1067
|
sha256Hex,
|
|
1023
1068
|
serializeMessageContent,
|
|
1024
1069
|
resolveCompressionTriggerRatio,
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
listUserRecordsFromServers,
|
|
8
8
|
readDbRecordFromServers,
|
|
9
9
|
readLiveDbRecordAfterTombstoneMerge
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-SUBKVXFM.js";
|
|
11
11
|
import {
|
|
12
12
|
parsePositiveFiniteNumberOrFallback
|
|
13
13
|
} from "./chunk-Y5GCAMGP.js";
|
|
@@ -42,7 +42,7 @@ import {
|
|
|
42
42
|
} from "./chunk-I42VC5KR.js";
|
|
43
43
|
import {
|
|
44
44
|
resolveRunsDir
|
|
45
|
-
} from "./chunk-
|
|
45
|
+
} from "./chunk-CI5DVWU7.js";
|
|
46
46
|
import {
|
|
47
47
|
getDefaultCliLocalRuntimeDb
|
|
48
48
|
} from "./chunk-GAGGEA7D.js";
|
|
@@ -7,7 +7,7 @@ import {
|
|
|
7
7
|
mergeReferences,
|
|
8
8
|
resolveReferenceAssets,
|
|
9
9
|
resolveToolsFromKeys
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-EK3LIELB.js";
|
|
11
11
|
import {
|
|
12
12
|
UI_CARD_ENVELOPE_MAX_BYTES,
|
|
13
13
|
getAllToolRuns,
|
|
@@ -20,7 +20,7 @@ import {
|
|
|
20
20
|
selectSpaceContextLevel,
|
|
21
21
|
selectUserTonePreset,
|
|
22
22
|
uiCardFallback
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-MOOQN57G.js";
|
|
24
24
|
import {
|
|
25
25
|
resolveToolBaseUrl
|
|
26
26
|
} from "./chunk-MYOH447Z.js";
|
|
@@ -29,18 +29,18 @@ import {
|
|
|
29
29
|
getModelPricing,
|
|
30
30
|
getPrices,
|
|
31
31
|
hasExplicitAgentPricing
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-TDNAAXUQ.js";
|
|
33
33
|
import {
|
|
34
34
|
getDocState
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-VAQ3EGPC.js";
|
|
36
36
|
import {
|
|
37
37
|
getTableState
|
|
38
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-MTAWQNSU.js";
|
|
39
39
|
import {
|
|
40
40
|
PERSONALIZATION_DIALOG_CATEGORY,
|
|
41
41
|
buildPersonalizationDialogPolicyContext,
|
|
42
42
|
selectAllMsgs
|
|
43
|
-
} from "./chunk-
|
|
43
|
+
} from "./chunk-DNQ55DHN.js";
|
|
44
44
|
import {
|
|
45
45
|
getCurrentSpaceIdRaw,
|
|
46
46
|
getViewMode
|
|
@@ -66,21 +66,21 @@ import {
|
|
|
66
66
|
expandEnabledPackPromptPatches,
|
|
67
67
|
expandEnabledPacks,
|
|
68
68
|
resolveEffectiveEnabledPacks
|
|
69
|
-
} from "./chunk-
|
|
69
|
+
} from "./chunk-WXOKJP3W.js";
|
|
70
70
|
import {
|
|
71
71
|
projectToolMessageContent
|
|
72
|
-
} from "./chunk-
|
|
72
|
+
} from "./chunk-2WZXXAQD.js";
|
|
73
73
|
import {
|
|
74
74
|
attachmentKind,
|
|
75
75
|
normalizeAttachmentPart
|
|
76
76
|
} from "./chunk-WJZOQR2J.js";
|
|
77
77
|
import {
|
|
78
78
|
extractReferenceKeysFromMessage
|
|
79
|
-
} from "./chunk-
|
|
79
|
+
} from "./chunk-7TBARDLF.js";
|
|
80
80
|
import {
|
|
81
81
|
getModelContextWindow,
|
|
82
82
|
planContextUsage
|
|
83
|
-
} from "./chunk-
|
|
83
|
+
} from "./chunk-BKCR2JHG.js";
|
|
84
84
|
import {
|
|
85
85
|
asRecordOrEmpty
|
|
86
86
|
} from "./chunk-KX6YBIHG.js";
|
|
@@ -113,7 +113,7 @@ import {
|
|
|
113
113
|
import {
|
|
114
114
|
getModelConfig,
|
|
115
115
|
getProviderByModelName
|
|
116
|
-
} from "./chunk-
|
|
116
|
+
} from "./chunk-GC64WGMD.js";
|
|
117
117
|
import {
|
|
118
118
|
isRecord
|
|
119
119
|
} from "./chunk-KUG52IAP.js";
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
} from "./chunk-QYPE3TS3.js";
|
|
12
12
|
import {
|
|
13
13
|
runLlm
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-54YLFF7P.js";
|
|
15
15
|
import {
|
|
16
16
|
getApproxPricePerImage
|
|
17
17
|
} from "./chunk-4JH2UMJR.js";
|
|
@@ -101,10 +101,9 @@ import {
|
|
|
101
101
|
asOptionalJsonRecord,
|
|
102
102
|
devinChannelContextWindow,
|
|
103
103
|
extractReferenceKeysFromMessage,
|
|
104
|
-
isOAuthApiKeyRef,
|
|
105
104
|
normalizeUsage,
|
|
106
105
|
resolveAutoExecutionProfile
|
|
107
|
-
} from "./chunk-
|
|
106
|
+
} from "./chunk-7TBARDLF.js";
|
|
108
107
|
import {
|
|
109
108
|
isDevinOAuthAgent
|
|
110
109
|
} from "./chunk-5ZUL4CUO.js";
|
|
@@ -119,9 +118,10 @@ import {
|
|
|
119
118
|
formatFileOperationsFromMessages,
|
|
120
119
|
formatMessagesForSummaryWithTruncation,
|
|
121
120
|
getModelInfo,
|
|
121
|
+
isOAuthApiKeyRef,
|
|
122
122
|
planCompression,
|
|
123
123
|
serializeMessageContent
|
|
124
|
-
} from "./chunk-
|
|
124
|
+
} from "./chunk-BKCR2JHG.js";
|
|
125
125
|
import {
|
|
126
126
|
asRecordOrEmpty
|
|
127
127
|
} from "./chunk-KX6YBIHG.js";
|
|
@@ -160,7 +160,7 @@ import {
|
|
|
160
160
|
import {
|
|
161
161
|
findModelConfig,
|
|
162
162
|
getModelConfig
|
|
163
|
-
} from "./chunk-
|
|
163
|
+
} from "./chunk-GC64WGMD.js";
|
|
164
164
|
import {
|
|
165
165
|
isRecord
|
|
166
166
|
} from "./chunk-KUG52IAP.js";
|
|
@@ -193,7 +193,7 @@ import {
|
|
|
193
193
|
isPlatformManagedProvider,
|
|
194
194
|
resolvePlatformEffectiveModel,
|
|
195
195
|
resolvePlatformHostedRouting
|
|
196
|
-
} from "./chunk-
|
|
196
|
+
} from "./chunk-5KTQVMCX.js";
|
|
197
197
|
import {
|
|
198
198
|
asTrimmedLowercaseString
|
|
199
199
|
} from "./chunk-QSJ3HFEF.js";
|
|
@@ -11062,7 +11062,7 @@ var messageSlice = createSliceWithThunks({
|
|
|
11062
11062
|
runtimeOptions: args.runtimeOptions
|
|
11063
11063
|
});
|
|
11064
11064
|
if (agentKeyToUse) {
|
|
11065
|
-
const { streamAgentChatTurn } = await import("./agentSlice-
|
|
11065
|
+
const { streamAgentChatTurn } = await import("./agentSlice-QMOFHPJR.js");
|
|
11066
11066
|
await dispatch(
|
|
11067
11067
|
streamAgentChatTurn({
|
|
11068
11068
|
agentKey: agentKeyToUse,
|
|
@@ -13879,7 +13879,7 @@ var deleteDialogThunk = async (payload, thunkApi) => {
|
|
|
13879
13879
|
}
|
|
13880
13880
|
if (isCurrentDialog) {
|
|
13881
13881
|
await thunkApi.dispatch(resetMsgs());
|
|
13882
|
-
const { clearPendingAttachments: clearPendingAttachments2 } = await import("./dialogSlice-
|
|
13882
|
+
const { clearPendingAttachments: clearPendingAttachments2 } = await import("./dialogSlice-Y6WIZWTC.js");
|
|
13883
13883
|
dispatch(clearPendingAttachments2());
|
|
13884
13884
|
}
|
|
13885
13885
|
return { dialogKey, isCurrentDialog, attachmentPlan };
|
|
@@ -13887,15 +13887,15 @@ var deleteDialogThunk = async (payload, thunkApi) => {
|
|
|
13887
13887
|
|
|
13888
13888
|
// packages/chat/dialog/dialogSlice.ts
|
|
13889
13889
|
var runCreateDialogAction = async (args, thunkApi) => {
|
|
13890
|
-
const { createDialogAction } = await import("./createDialogAction-
|
|
13890
|
+
const { createDialogAction } = await import("./createDialogAction-ITOZ5TAM.js");
|
|
13891
13891
|
return createDialogAction(args, thunkApi);
|
|
13892
13892
|
};
|
|
13893
13893
|
var runCreateAgentAutomationAction = async (args, thunkApi) => {
|
|
13894
|
-
const { createAgentAutomationAction } = await import("./createAgentAutomationAction-
|
|
13894
|
+
const { createAgentAutomationAction } = await import("./createAgentAutomationAction-PQA43W2W.js");
|
|
13895
13895
|
return createAgentAutomationAction(args, thunkApi);
|
|
13896
13896
|
};
|
|
13897
13897
|
var runUpdateDialogTitleAction = async (args, thunkApi) => {
|
|
13898
|
-
const { updateDialogTitleAction } = await import("./updateDialogTitleAction-
|
|
13898
|
+
const { updateDialogTitleAction } = await import("./updateDialogTitleAction-CEFNJE4T.js");
|
|
13899
13899
|
return updateDialogTitleAction(args, thunkApi);
|
|
13900
13900
|
};
|
|
13901
13901
|
var runAddDialogAgentAction = async (args, thunkApi) => {
|
|
@@ -13919,7 +13919,7 @@ var runSetDialogExtraReferencesAction = async (args, thunkApi) => {
|
|
|
13919
13919
|
return setDialogExtraReferencesAction(args, thunkApi);
|
|
13920
13920
|
};
|
|
13921
13921
|
var runHandleSendMessageAction = async (args, thunkApi) => {
|
|
13922
|
-
const { handleSendMessageAction } = await import("./handleSendMessageAction-
|
|
13922
|
+
const { handleSendMessageAction } = await import("./handleSendMessageAction-4OVVUVJ4.js");
|
|
13923
13923
|
return handleSendMessageAction(args, thunkApi);
|
|
13924
13924
|
};
|
|
13925
13925
|
function clearDialogState() {
|
|
@@ -13932,7 +13932,7 @@ var createPageAndAddReference = createAsyncThunk(
|
|
|
13932
13932
|
async (payload, { dispatch, getState, rejectWithValue }) => {
|
|
13933
13933
|
const { slateData, jsonData, title, type, fileId, groupId, dialogKey } = payload;
|
|
13934
13934
|
try {
|
|
13935
|
-
const { createDocState } = await import("./docStore-
|
|
13935
|
+
const { createDocState } = await import("./docStore-HRNZKKVS.js");
|
|
13936
13936
|
const pageKey = await createDocState(
|
|
13937
13937
|
{ slateData, title },
|
|
13938
13938
|
{ dispatch, getState }
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
clipMultilineText,
|
|
3
3
|
fetchAndSerializeTable,
|
|
4
4
|
waitForAbortableDelay
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-MOOQN57G.js";
|
|
6
6
|
import {
|
|
7
7
|
isGatewayHttpStatus
|
|
8
8
|
} from "./chunk-NF64D32W.js";
|
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
} from "./chunk-AGIM7IMJ.js";
|
|
22
22
|
import {
|
|
23
23
|
fetchAndCacheMessages
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-DNQ55DHN.js";
|
|
25
25
|
import {
|
|
26
26
|
createSpaceKey
|
|
27
27
|
} from "./chunk-UAD2WT54.js";
|
|
@@ -35,7 +35,7 @@ import {
|
|
|
35
35
|
extractRuntimePageCapabilities,
|
|
36
36
|
resolveBuiltinSkillPage,
|
|
37
37
|
resolveSkillGraphFromRoots
|
|
38
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-3LNVSFTH.js";
|
|
39
39
|
import {
|
|
40
40
|
isAbortError
|
|
41
41
|
} from "./chunk-7DPNBQSV.js";
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
resolveAgentImageInputSupport
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-I33CJERI.js";
|
|
4
|
+
import {
|
|
5
|
+
TOOL_HAD_IMAGES,
|
|
6
|
+
hadToolImages
|
|
7
|
+
} from "./chunk-SHPY7A3P.js";
|
|
4
8
|
import {
|
|
5
9
|
asOptionalFiniteNumber
|
|
6
10
|
} from "./chunk-WWC7I6TA.js";
|
|
@@ -375,6 +379,10 @@ function sanitizeChatMessage(value) {
|
|
|
375
379
|
};
|
|
376
380
|
const toolCallId = asOptionalTrimmedString(value.tool_call_id) ?? asOptionalTrimmedString(value.toolCallId);
|
|
377
381
|
if (toolCallId) message.tool_call_id = toolCallId;
|
|
382
|
+
const metadata = isRecord(value.tool_result_metadata) ? value.tool_result_metadata : value.metadata;
|
|
383
|
+
if (role === "tool" && (hadToolImages(value) || isRecord(metadata) && metadata[TOOL_HAD_IMAGES] === true)) {
|
|
384
|
+
message.tool_result_metadata = { [TOOL_HAD_IMAGES]: true };
|
|
385
|
+
}
|
|
378
386
|
const toolCalls = sanitizeToolCalls(value.tool_calls);
|
|
379
387
|
if (toolCalls) message.tool_calls = toolCalls;
|
|
380
388
|
if (typeof value.reasoning_content === "string" && value.reasoning_content) {
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
resolvePlatformHostedCredentialProvider,
|
|
5
5
|
resolvePlatformProxyChatGatewayEndpoint,
|
|
6
6
|
resolvePlatformResponsesEndpoint
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-TVGX5QIN.js";
|
|
8
8
|
import {
|
|
9
9
|
CLI_PROVIDER_VALUES
|
|
10
10
|
} from "./chunk-5BHQICF2.js";
|
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
CLIENT_VERSION_TOO_OLD_CODE,
|
|
22
22
|
buildClientVersionGateErrorDetail,
|
|
23
23
|
evaluatePlatformHostedClientVersionGate
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-5KTQVMCX.js";
|
|
25
25
|
import {
|
|
26
26
|
asTrimmedLowercaseString
|
|
27
27
|
} from "./chunk-QSJ3HFEF.js";
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
resolveAgentCallPlan
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-XBJIESNS.js";
|
|
4
4
|
import {
|
|
5
5
|
SUBSCRIPTION_OAUTH_PROVIDERS
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-OQ3DOBYB.js";
|
|
7
7
|
import {
|
|
8
8
|
findModelConfig,
|
|
9
9
|
getProviderByModelName
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-GC64WGMD.js";
|
|
11
11
|
import {
|
|
12
12
|
asOptionalTrimmedString
|
|
13
13
|
} from "./chunk-G3SUCT4W.js";
|
|
@@ -15,57 +15,6 @@ import {
|
|
|
15
15
|
asTrimmedLowercaseString
|
|
16
16
|
} from "./chunk-QSJ3HFEF.js";
|
|
17
17
|
|
|
18
|
-
// packages/ai/agent/toolOutputPolicy.ts
|
|
19
|
-
var MAX_IN_TURN_TOOL_CONTENT_CHARS = 4e3;
|
|
20
|
-
var DEFAULT_TOOL_OUTPUT_PROFILE = {
|
|
21
|
-
maxChars: MAX_IN_TURN_TOOL_CONTENT_CHARS,
|
|
22
|
-
headRatio: 0.5
|
|
23
|
-
};
|
|
24
|
-
var TOOL_OUTPUT_PROFILES = {
|
|
25
|
-
readFile: { maxChars: 4800, headRatio: 0.68, historicalMaxChars: 4800 },
|
|
26
|
-
read_file: { maxChars: 4800, headRatio: 0.68, historicalMaxChars: 4800 },
|
|
27
|
-
readWorkspaceFile: { maxChars: 4800, headRatio: 0.68, historicalMaxChars: 4800 },
|
|
28
|
-
globFiles: { maxChars: 2800, headRatio: 0.85 },
|
|
29
|
-
execShell: { maxChars: 4e3, headRatio: 0.35 },
|
|
30
|
-
runCommand: { maxChars: 4e3, headRatio: 0.35 },
|
|
31
|
-
launchProcess: { maxChars: 2800, headRatio: 0.35 },
|
|
32
|
-
editFile: { maxChars: 1200, headRatio: 0.62 },
|
|
33
|
-
writeFile: { maxChars: 1e3, headRatio: 0.62 },
|
|
34
|
-
readPastedText: { maxChars: 4800, headRatio: 0.5, historicalMaxChars: 4800 },
|
|
35
|
-
// loadSkill 内联的是文档正文(SKILL.md 全文),与 readFile 同类,不该因为工具名未登记就退回
|
|
36
|
-
// DEFAULT 的 4000。历史事故(nolo-plan omitted middle)正是 headRatio 0.5 掐掉中段,把
|
|
37
|
-
// 「MUST / 禁止」所在的中段静默省略。取 4800(与 readFile 同级),不激进放大;headRatio 同 DEFAULT。
|
|
38
|
-
loadSkill: { maxChars: 4800, headRatio: 0.5 }
|
|
39
|
-
};
|
|
40
|
-
function resolveToolOutputProfile(toolName) {
|
|
41
|
-
return (toolName ? TOOL_OUTPUT_PROFILES[toolName] : void 0) ?? DEFAULT_TOOL_OUTPUT_PROFILE;
|
|
42
|
-
}
|
|
43
|
-
function resolveHistoricalToolContentCap(toolName, historicalMaxChars) {
|
|
44
|
-
const profile = toolName ? TOOL_OUTPUT_PROFILES[toolName] : void 0;
|
|
45
|
-
return profile?.historicalMaxChars !== void 0 ? Math.max(historicalMaxChars, profile.historicalMaxChars) : historicalMaxChars;
|
|
46
|
-
}
|
|
47
|
-
function projectToolMessageContent(input) {
|
|
48
|
-
const { content, toolName } = input;
|
|
49
|
-
const maxChars = resolveToolOutputProfile(toolName).maxChars;
|
|
50
|
-
if (content.length <= maxChars) return content;
|
|
51
|
-
return clipToolText(
|
|
52
|
-
content,
|
|
53
|
-
maxChars,
|
|
54
|
-
resolveToolOutputProfile(toolName).headRatio,
|
|
55
|
-
`
|
|
56
|
-
\u2026[\u622A\u65AD\uFF0C\u539F\u59CB\u957F\u5EA6 ${content.length} \u5B57\u7B26]`
|
|
57
|
-
);
|
|
58
|
-
}
|
|
59
|
-
function clipToolText(content, maxChars, headRatio, marker = "\n\n[... tool output middle omitted; head/tail preserved ...]\n\n") {
|
|
60
|
-
const normalized = content.replace(/\r\n/g, "\n").trim();
|
|
61
|
-
if (normalized.length <= maxChars) return normalized;
|
|
62
|
-
if (maxChars <= marker.length + 2) return normalized.slice(0, maxChars);
|
|
63
|
-
const available = maxChars - marker.length;
|
|
64
|
-
const headChars = Math.max(1, Math.floor(available * headRatio));
|
|
65
|
-
const tailChars = Math.max(1, available - headChars);
|
|
66
|
-
return `${normalized.slice(0, headChars)}${marker}${normalized.slice(-tailChars)}`;
|
|
67
|
-
}
|
|
68
|
-
|
|
69
18
|
// packages/ai/llm/agentCapabilities.ts
|
|
70
19
|
var ANTIGRAVITY_EFFORT_SUFFIXES = [
|
|
71
20
|
"-tiered",
|
|
@@ -146,9 +95,5 @@ var resolveAgentImageInputSupport = (agent) => {
|
|
|
146
95
|
};
|
|
147
96
|
|
|
148
97
|
export {
|
|
149
|
-
resolveToolOutputProfile,
|
|
150
|
-
resolveHistoricalToolContentCap,
|
|
151
|
-
projectToolMessageContent,
|
|
152
|
-
clipToolText,
|
|
153
98
|
resolveAgentImageInputSupport
|
|
154
99
|
};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
listUserRecordsFromServers,
|
|
3
3
|
readLiveDbRecordAfterTombstoneMerge
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-SUBKVXFM.js";
|
|
5
5
|
import {
|
|
6
6
|
agentRecordHasConfiguredCredential
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-OPNHKULV.js";
|
|
8
8
|
import {
|
|
9
9
|
deriveCredentialGroup
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-BE42X662.js";
|
|
11
11
|
import {
|
|
12
12
|
isTombstoneRecord
|
|
13
13
|
} from "./chunk-D2MDMY2M.js";
|
|
@@ -3,13 +3,13 @@ import {
|
|
|
3
3
|
} from "./chunk-HS7MLR74.js";
|
|
4
4
|
import {
|
|
5
5
|
performServerProxyFetchWithRetry
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-EK3LIELB.js";
|
|
7
7
|
import {
|
|
8
8
|
fetchServerSyncedCredential
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-54YLFF7P.js";
|
|
10
10
|
import {
|
|
11
11
|
buildSkillGuidancePromptBlock
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-3LNVSFTH.js";
|
|
13
13
|
import {
|
|
14
14
|
CREDENTIAL_HYGIENE_RULE,
|
|
15
15
|
DELETE_SAFETY_RED_LINE,
|
|
@@ -23,7 +23,7 @@ import {
|
|
|
23
23
|
compileContextLayers,
|
|
24
24
|
detectDispatchIntentFromMessages,
|
|
25
25
|
resolveToolGuidedSections
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-RATR6VCP.js";
|
|
27
27
|
import {
|
|
28
28
|
convertMessagesToResponsesInput,
|
|
29
29
|
getUsageRequestOptions,
|
|
@@ -32,14 +32,14 @@ import {
|
|
|
32
32
|
resolveReasoningReplayOptions,
|
|
33
33
|
shouldStripReasoningContentForOutbound,
|
|
34
34
|
stablePromptCacheKey
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-SHPY7A3P.js";
|
|
36
36
|
import {
|
|
37
37
|
resolveAgentCallPlan,
|
|
38
38
|
resolveClientWire
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-XBJIESNS.js";
|
|
40
40
|
import {
|
|
41
41
|
createFileCredentialBroker
|
|
42
|
-
} from "./chunk-
|
|
42
|
+
} from "./chunk-76YUTLOT.js";
|
|
43
43
|
import {
|
|
44
44
|
MEMORY_USE_GUIDANCE,
|
|
45
45
|
buildUserResponseLanguageContext,
|
|
@@ -53,12 +53,12 @@ import {
|
|
|
53
53
|
} from "./chunk-LCBAMY2M.js";
|
|
54
54
|
import {
|
|
55
55
|
buildProviderAuthHeaders
|
|
56
|
-
} from "./chunk-
|
|
56
|
+
} from "./chunk-I2QHI2XM.js";
|
|
57
57
|
import {
|
|
58
58
|
clampReasoningEffort,
|
|
59
59
|
getModelConfig,
|
|
60
60
|
isModelSupportReasoningEffort
|
|
61
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-GC64WGMD.js";
|
|
62
62
|
import {
|
|
63
63
|
isRecord
|
|
64
64
|
} from "./chunk-KUG52IAP.js";
|
|
@@ -79,7 +79,7 @@ import {
|
|
|
79
79
|
isFireworksKimiModel,
|
|
80
80
|
isPlatformMimoProviderModel,
|
|
81
81
|
resolveFireworksKimiModel
|
|
82
|
-
} from "./chunk-
|
|
82
|
+
} from "./chunk-5KTQVMCX.js";
|
|
83
83
|
|
|
84
84
|
// packages/agent-runtime/responsesConversationState.ts
|
|
85
85
|
function supportsResponsesConversationState(agent) {
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
inlineImageUrlsForCustomProvider,
|
|
6
6
|
prepareTools,
|
|
7
7
|
shouldInlineImageUrlsForAgent
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-PPR6G2U2.js";
|
|
9
9
|
import {
|
|
10
10
|
CONFIRMATION_INPUT_KEYS,
|
|
11
11
|
INVALID_TOOL_ARGS_REPLACEMENT,
|
|
@@ -14,16 +14,16 @@ import {
|
|
|
14
14
|
performFetchRequest,
|
|
15
15
|
sanitizeOutboundMessages,
|
|
16
16
|
stripModelToolArgs
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-JCILHZJZ.js";
|
|
18
18
|
import {
|
|
19
19
|
findToolExecutor,
|
|
20
20
|
toolDefinitionsByName
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-UMVEB5QT.js";
|
|
22
22
|
import {
|
|
23
23
|
classifyApiError,
|
|
24
24
|
classifyGenerationError,
|
|
25
25
|
extractErrorDiagnostics
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-EK3LIELB.js";
|
|
27
27
|
import {
|
|
28
28
|
createSSEParser,
|
|
29
29
|
createToolRunId,
|
|
@@ -32,7 +32,7 @@ import {
|
|
|
32
32
|
toolRunSetPending,
|
|
33
33
|
toolRunStarted,
|
|
34
34
|
toolRunSucceeded
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-MOOQN57G.js";
|
|
36
36
|
import {
|
|
37
37
|
getPublicImageAgentMode
|
|
38
38
|
} from "./chunk-VIDPVFP3.js";
|
|
@@ -42,10 +42,10 @@ import {
|
|
|
42
42
|
messageStreaming,
|
|
43
43
|
toolResultNeedsUserConfirmation,
|
|
44
44
|
updateToolMessage
|
|
45
|
-
} from "./chunk-
|
|
45
|
+
} from "./chunk-DNQ55DHN.js";
|
|
46
46
|
import {
|
|
47
47
|
streamAgentChatTurn
|
|
48
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-54YLFF7P.js";
|
|
49
49
|
import {
|
|
50
50
|
getCurrentSpaceId
|
|
51
51
|
} from "./chunk-ZJ7UHBJS.js";
|
|
@@ -85,13 +85,13 @@ import {
|
|
|
85
85
|
} from "./chunk-56GBUMO5.js";
|
|
86
86
|
import {
|
|
87
87
|
normalizeChatCompletionsBodyForProvider
|
|
88
|
-
} from "./chunk-
|
|
88
|
+
} from "./chunk-SHPY7A3P.js";
|
|
89
89
|
import {
|
|
90
90
|
EMPTY_ASSISTANT_REPAIR_PROMPT
|
|
91
|
-
} from "./chunk-
|
|
91
|
+
} from "./chunk-7TBARDLF.js";
|
|
92
92
|
import {
|
|
93
93
|
getModelInfo
|
|
94
|
-
} from "./chunk-
|
|
94
|
+
} from "./chunk-BKCR2JHG.js";
|
|
95
95
|
import {
|
|
96
96
|
isAbortError
|
|
97
97
|
} from "./chunk-7DPNBQSV.js";
|
|
@@ -105,7 +105,7 @@ import {
|
|
|
105
105
|
} from "./chunk-5EMSBTQ6.js";
|
|
106
106
|
import {
|
|
107
107
|
getApiEndpoint
|
|
108
|
-
} from "./chunk-
|
|
108
|
+
} from "./chunk-GC64WGMD.js";
|
|
109
109
|
import {
|
|
110
110
|
isRecord
|
|
111
111
|
} from "./chunk-KUG52IAP.js";
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import {
|
|
2
2
|
createCliLocalRuntimeAdapter,
|
|
3
3
|
summarizeEndpoint
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-3XUE7WJA.js";
|
|
5
5
|
import {
|
|
6
6
|
t
|
|
7
7
|
} from "./chunk-TDX2L4W2.js";
|
|
8
8
|
import {
|
|
9
9
|
clipMultilineText
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-MOOQN57G.js";
|
|
11
11
|
import {
|
|
12
12
|
runLocalAgentTurn
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-ME7N4YHG.js";
|
|
14
14
|
import {
|
|
15
15
|
applyToolSurfaceConstraints
|
|
16
16
|
} from "./chunk-6J227QXV.js";
|