nolo-cli 0.172.0-alpha.2 → 0.173.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-IABRBGAE.js → _executeModel-KT7NUYZC.js} +22 -21
- package/{accountResolver-JS7QDNNL.js → accountResolver-YGMLY3WW.js} +2 -1
- package/{agentDeleteCommand-ATU2HZT2.js → agentDeleteCommand-SVGYPFU5.js} +30 -28
- package/{agentEmailCommands-YTKUTNLR.js → agentEmailCommands-TBZJC37X.js} +32 -30
- package/{agentListCommands-ZBA5JTWP.js → agentListCommands-CD7CLGH4.js} +20 -18
- package/{agentMachineCommands-ZSKWBVPO.js → agentMachineCommands-DQBUP3I5.js} +18 -16
- package/{agentProviderCommands-TWVILNAN.js → agentProviderCommands-FXEMNSZ2.js} +2 -2
- package/{agentRecordCommands-KVN6OF4P.js → agentRecordCommands-4PY33TAJ.js} +30 -28
- package/{agentRunCommand-CC6JZOGT.js → agentRunCommand-P7BC5M3Z.js} +31 -29
- package/{agentRuntimeLocal-JA2Q6UBJ.js → agentRuntimeLocal-XGBQ7JK2.js} +15 -13
- package/{agentSlice-RVJDFNRB.js → agentSlice-NL7LRTLO.js} +1 -1
- package/{appDeleteCommands-4XONJLO7.js → appDeleteCommands-VBH3YLIO.js} +19 -17
- package/{appDeployCommands-SDGJMAUG.js → appDeployCommands-3MZXLEKN.js} +19 -17
- package/{appDeployStatusCommands-A6O3FEEW.js → appDeployStatusCommands-FAWWEEOT.js} +19 -17
- package/{appGetCommands-U4Z5HSNF.js → appGetCommands-VMMCATHU.js} +19 -17
- package/{appListCommands-T4HVTIUC.js → appListCommands-NHM6PAIX.js} +19 -17
- package/{authCommand-BSOLJFPV.js → authCommand-KQ7GWCXK.js} +8 -4
- package/{chromeCommands-IY4NVSXZ.js → chromeCommands-Z5LDHMYN.js} +2 -1
- package/{chromeOpsCommands-6JHNTKXU.js → chromeOpsCommands-CHBIUDJD.js} +2 -1
- package/{chunk-ZB4JKLJM.js → chunk-25A6K2YP.js} +3 -3
- package/{chunk-6J227QXV.js → chunk-2GRXE3YJ.js} +21 -0
- package/{chunk-74PQM3XI.js → chunk-3TAVX6CD.js} +75 -39
- package/{chunk-BW3LCST7.js → chunk-4RYUMDOM.js} +2 -2
- package/{chunk-MYZHJKLG.js → chunk-64MLOS7B.js} +1 -1
- package/{chunk-CZLO63PE.js → chunk-73NYJAJS.js} +10 -10
- package/{chunk-I33CJERI.js → chunk-7QQOOHDG.js} +2 -2
- package/{chunk-BKCR2JHG.js → chunk-7ZGMQZ5D.js} +0 -45
- package/{chunk-X7KVZ2OK.js → chunk-AFFHPBEU.js} +7 -7
- package/{chunk-AKXKBNLQ.js → chunk-ASGIXFB6.js} +2 -2
- package/{chunk-UG3UI4Z7.js → chunk-AV67EUU4.js} +13 -13
- package/{chunk-EWLPIR2S.js → chunk-BAXCQF6H.js} +1 -1
- package/{chunk-FZSVCJUU.js → chunk-BGQZLBMJ.js} +4 -101
- package/{chunk-2EC6FNS4.js → chunk-BYNWE72R.js} +29 -91
- package/{chunk-WKF6C3X5.js → chunk-CLY56QIC.js} +3 -3
- package/{chunk-AJ52EA72.js → chunk-D2J22QSE.js} +1 -1
- package/{chunk-BU2YQBV4.js → chunk-DPQYIS6D.js} +41 -1
- package/{chunk-TYQZRSL6.js → chunk-ENIQIEAF.js} +1 -1
- package/{chunk-TCWK2EQX.js → chunk-FJ76E5ZM.js} +2 -2
- package/chunk-FX33MFLW.js +103 -0
- package/{chunk-UA4VAUQL.js → chunk-GXFAZGZ6.js} +2 -2
- package/{chunk-5WOL7BUP.js → chunk-J33JIJK7.js} +2 -2
- package/{chunk-WW5MNBTZ.js → chunk-JDWJ64VG.js} +5 -5
- package/{chunk-OQ3DOBYB.js → chunk-JOUFPRE4.js} +178 -2
- package/{chunk-6BDTSKUT.js → chunk-KBGWPSY6.js} +4 -4
- package/{chunk-BE42X662.js → chunk-KPSNHLFI.js} +4 -6
- package/{chunk-O4H4HD4X.js → chunk-N2N63HTQ.js} +2 -2
- package/{chunk-R2RDXNEE.js → chunk-O2LB346J.js} +3 -3
- package/{chunk-XWX5ZGWR.js → chunk-O3OJRN5Z.js} +89 -24
- package/{chunk-OPNHKULV.js → chunk-P34IX26T.js} +2 -2
- package/{chunk-ISMHFI2Y.js → chunk-QWNMFO5E.js} +3 -3
- package/{chunk-PJVGNB4L.js → chunk-RPZNVBA5.js} +1 -1
- package/{chunk-SUBKVXFM.js → chunk-RUKAOMXD.js} +1 -1
- package/chunk-SRZ6BQIP.js +68 -0
- package/{chunk-7TBARDLF.js → chunk-T7HBI3WZ.js} +1 -1
- package/{chunk-SDAIVJZG.js → chunk-TLBTPKDD.js} +11 -11
- package/chunk-UKZX3NHN.js +48 -0
- package/{chunk-ULE7ABRN.js → chunk-VETQRONK.js} +13 -11
- package/{chunk-ORKQ3T5D.js → chunk-W7S5CUGI.js} +3 -3
- package/{chunk-F3F3ARBN.js → chunk-WBA4HAFS.js} +2 -2
- package/{chunk-XBJIESNS.js → chunk-XAFCJN32.js} +2 -2
- package/{chunk-CAAH5LNN.js → chunk-Y3BUTWUJ.js} +2 -2
- package/{chunk-KNDA4K34.js → chunk-YBTP3PUM.js} +1 -1
- package/{chunk-RATR6VCP.js → chunk-ZEOR6XPJ.js} +1 -1
- package/{commandRegistry-ICL67WF7.js → commandRegistry-UVXIFHUI.js} +53 -53
- package/{contentThunks-SM5FP7FM.js → contentThunks-I4HNLTQY.js} +6 -5
- package/{createAgentAutomationAction-ECWLREQU.js → createAgentAutomationAction-GS5LQ52L.js} +6 -5
- package/{createDialogAction-LROHLFQ2.js → createDialogAction-5WNACKWC.js} +7 -6
- package/{createPageAction-KUQVLZMZ.js → createPageAction-S7MGYSMU.js} +6 -5
- package/{dialogCommands-T5JYBPS6.js → dialogCommands-OK3L6SAI.js} +19 -17
- package/{dialogSlice-2FWQCZDB.js → dialogSlice-R62QV2OE.js} +5 -4
- package/{docCreateCommands-7F4ICTJQ.js → docCreateCommands-NMCMJPQX.js} +18 -16
- package/{docDeleteCommands-4INN7EWS.js → docDeleteCommands-46FMFRZU.js} +19 -17
- package/{docReadCommands-7PZZR3C3.js → docReadCommands-6NPY5P67.js} +18 -16
- package/{docStore-WUR5MNKF.js → docStore-X5P4UGTZ.js} +1 -1
- package/{docUpdateCommands-H2YXAGOV.js → docUpdateCommands-UDT4QLPL.js} +18 -16
- package/{handleSendMessageAction-DVXNAQ2V.js → handleSendMessageAction-IVQMBROO.js} +13 -13
- package/index.js +4 -4
- package/{localRuntimeAdapter-M64P55I7.js → localRuntimeAdapter-LY5MOJN4.js} +28 -26
- package/{machineCommands-2H7QW35Q.js → machineCommands-KYTNSAIN.js} +29 -27
- package/{machineWsRunDispatch-4L2DSIMF.js → machineWsRunDispatch-ZR3GCQMH.js} +29 -27
- package/package.json +1 -1
- package/{providerPresetApply-5K4PBX4J.js → providerPresetApply-MBMGCNKZ.js} +1 -2
- package/{providerRegistry-K5MSZ3Y5.js → providerRegistry-P4KYS6SE.js} +1 -2
- package/{readlineWorkspace-KNE2THUN.js → readlineWorkspace-SNA6I5UK.js} +34 -32
- package/{runAgentClientLoop-34ME2HDT.js → runAgentClientLoop-6G7JORHJ.js} +20 -19
- package/{spaceCommands-HAVZ3PQN.js → spaceCommands-SEWFBY53.js} +18 -16
- package/{streamAgentChatTurn-YXFJ3UWD.js → streamAgentChatTurn-EJDRXKAQ.js} +26 -24
- package/{tools-M7H7Z44Z.js → tools-K3IZ7U5G.js} +13 -13
- package/{tuiSummaryLlmCaller-KVAXEH7O.js → tuiSummaryLlmCaller-2MC6SXZT.js} +8 -7
- package/{updateDialogTitleAction-YXQ2AJVK.js → updateDialogTitleAction-YO67K72J.js} +6 -5
- package/chunk-TSCI6X6C.js +0 -185
|
@@ -5,41 +5,44 @@ import {
|
|
|
5
5
|
pickDefined,
|
|
6
6
|
printCliError,
|
|
7
7
|
resolveCliContext
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-ENIQIEAF.js";
|
|
9
9
|
import {
|
|
10
10
|
hasFlag,
|
|
11
11
|
hasHelpArg
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-BAXCQF6H.js";
|
|
13
13
|
import {
|
|
14
14
|
t
|
|
15
15
|
} from "./chunk-TDX2L4W2.js";
|
|
16
|
-
import "./chunk-
|
|
17
|
-
import "./chunk-
|
|
16
|
+
import "./chunk-P34IX26T.js";
|
|
17
|
+
import "./chunk-RPZNVBA5.js";
|
|
18
18
|
import "./chunk-NBTY7YJF.js";
|
|
19
19
|
import "./chunk-VF4K2QE6.js";
|
|
20
20
|
import "./chunk-UAD2WT54.js";
|
|
21
|
-
import "./chunk-
|
|
22
|
-
import "./chunk-
|
|
21
|
+
import "./chunk-BYNWE72R.js";
|
|
22
|
+
import "./chunk-O3OJRN5Z.js";
|
|
23
23
|
import "./chunk-ZNFJWEN4.js";
|
|
24
|
-
import "./chunk-
|
|
24
|
+
import "./chunk-O2LB346J.js";
|
|
25
25
|
import "./chunk-HNUWUO75.js";
|
|
26
26
|
import "./chunk-CHOZJMJS.js";
|
|
27
27
|
import "./chunk-PWTNI4N7.js";
|
|
28
|
-
import "./chunk-
|
|
28
|
+
import "./chunk-SRZ6BQIP.js";
|
|
29
|
+
import "./chunk-J33JIJK7.js";
|
|
29
30
|
import "./chunk-2WZXXAQD.js";
|
|
30
|
-
import "./chunk-
|
|
31
|
+
import "./chunk-7QQOOHDG.js";
|
|
31
32
|
import "./chunk-G6OOUQWJ.js";
|
|
32
33
|
import "./chunk-56GBUMO5.js";
|
|
33
34
|
import "./chunk-WJZOQR2J.js";
|
|
34
|
-
import "./chunk-
|
|
35
|
-
import "./chunk-
|
|
36
|
-
import "./chunk-
|
|
35
|
+
import "./chunk-ZEOR6XPJ.js";
|
|
36
|
+
import "./chunk-BGQZLBMJ.js";
|
|
37
|
+
import "./chunk-FX33MFLW.js";
|
|
38
|
+
import "./chunk-2GRXE3YJ.js";
|
|
37
39
|
import "./chunk-JLR5NWP2.js";
|
|
38
|
-
import "./chunk-
|
|
40
|
+
import "./chunk-XAFCJN32.js";
|
|
39
41
|
import "./chunk-2MBTWINN.js";
|
|
40
|
-
import "./chunk-
|
|
42
|
+
import "./chunk-T7HBI3WZ.js";
|
|
41
43
|
import "./chunk-5ZUL4CUO.js";
|
|
42
|
-
import "./chunk-
|
|
44
|
+
import "./chunk-7ZGMQZ5D.js";
|
|
45
|
+
import "./chunk-UKZX3NHN.js";
|
|
43
46
|
import "./chunk-5MMAK75Q.js";
|
|
44
47
|
import "./chunk-DWLEOOGR.js";
|
|
45
48
|
import "./chunk-LIQJTQRN.js";
|
|
@@ -64,8 +67,7 @@ import "./chunk-OLZBQWZU.js";
|
|
|
64
67
|
import "./chunk-LCBAMY2M.js";
|
|
65
68
|
import "./chunk-Y6ROFCZO.js";
|
|
66
69
|
import "./chunk-HLAL63BZ.js";
|
|
67
|
-
import "./chunk-
|
|
68
|
-
import "./chunk-TSCI6X6C.js";
|
|
70
|
+
import "./chunk-JOUFPRE4.js";
|
|
69
71
|
import "./chunk-WWC7I6TA.js";
|
|
70
72
|
import "./chunk-I2QHI2XM.js";
|
|
71
73
|
import "./chunk-TVGX5QIN.js";
|
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
parseFlagWithOptionalValue,
|
|
4
4
|
runCloudflareOAuthLogin,
|
|
5
5
|
upsertEnvVariable
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-YBTP3PUM.js";
|
|
7
7
|
import {
|
|
8
8
|
ANTHROPIC_OAUTH_AUTHORIZE_URL,
|
|
9
9
|
ANTHROPIC_OAUTH_CALLBACK_PORT,
|
|
@@ -45,7 +45,7 @@ import {
|
|
|
45
45
|
startCallbackServer,
|
|
46
46
|
validateXAIEndpoint,
|
|
47
47
|
xaiOAuthDiscovery
|
|
48
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-D2J22QSE.js";
|
|
49
49
|
import {
|
|
50
50
|
t
|
|
51
51
|
} from "./chunk-TDX2L4W2.js";
|
|
@@ -65,9 +65,13 @@ import {
|
|
|
65
65
|
detectLocalDevinCredentials,
|
|
66
66
|
extractDevinToken,
|
|
67
67
|
fetchAntigravityCloudCodeCompletion
|
|
68
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-O3OJRN5Z.js";
|
|
69
69
|
import "./chunk-HNUWUO75.js";
|
|
70
|
+
import "./chunk-7QQOOHDG.js";
|
|
71
|
+
import "./chunk-FX33MFLW.js";
|
|
72
|
+
import "./chunk-XAFCJN32.js";
|
|
70
73
|
import "./chunk-5ZUL4CUO.js";
|
|
74
|
+
import "./chunk-UKZX3NHN.js";
|
|
71
75
|
import {
|
|
72
76
|
createOAuthTokenStore,
|
|
73
77
|
resolveFreshAccessToken
|
|
@@ -86,7 +90,7 @@ import {
|
|
|
86
90
|
getProfileOAuthSync,
|
|
87
91
|
saveProfileOAuthSync
|
|
88
92
|
} from "./chunk-R5GO3YZP.js";
|
|
89
|
-
import "./chunk-
|
|
93
|
+
import "./chunk-JOUFPRE4.js";
|
|
90
94
|
import {
|
|
91
95
|
asOptionalFiniteNumber
|
|
92
96
|
} from "./chunk-WWC7I6TA.js";
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
fetchReferenceContents,
|
|
3
3
|
resolveReferenceAssets
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-FJ76E5ZM.js";
|
|
5
5
|
import {
|
|
6
6
|
updateTokensAction
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-VETQRONK.js";
|
|
8
8
|
import {
|
|
9
9
|
applyUpdateTokensFulfilled
|
|
10
10
|
} from "./chunk-OWYYDMGJ.js";
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
extractReasoningFromResponseOutput,
|
|
13
13
|
extractTextFromResponseOutput,
|
|
14
14
|
extractToolCallsFromResponseOutput
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-BGQZLBMJ.js";
|
|
16
16
|
import {
|
|
17
17
|
isRecord
|
|
18
18
|
} from "./chunk-KUG52IAP.js";
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
asRecordOrEmpty
|
|
3
3
|
} from "./chunk-KX6YBIHG.js";
|
|
4
|
+
import {
|
|
5
|
+
canonicalizeToolName
|
|
6
|
+
} from "./chunk-5EBLANFT.js";
|
|
4
7
|
import {
|
|
5
8
|
isOwnedAgentKey,
|
|
6
9
|
ownedAgentKey,
|
|
@@ -103,6 +106,23 @@ function applyToolSurfaceConstraints(surface, constraints) {
|
|
|
103
106
|
finalToolNames: narrow(surface.finalToolNames)
|
|
104
107
|
};
|
|
105
108
|
}
|
|
109
|
+
function resolveRequestToolSurface(args) {
|
|
110
|
+
const normalize = (name) => canonicalizeToolName(name.trim().replace(/^functions\./i, ""));
|
|
111
|
+
const names = (values) => new Set(values.map(normalize));
|
|
112
|
+
const allowed = args.profile?.allowedToolNames == null ? null : names(args.profile.allowedToolNames);
|
|
113
|
+
const blocked = names(args.profile?.blockedToolNames ?? []);
|
|
114
|
+
const supported = args.backend ? names(args.backend.toolNames) : null;
|
|
115
|
+
const scope = args.backend?.scopedToolNames ? names(args.backend.scopedToolNames) : null;
|
|
116
|
+
const filteredTools = [];
|
|
117
|
+
const finalToolNames = args.requestedToolNames.filter((toolName) => {
|
|
118
|
+
const name = normalize(toolName);
|
|
119
|
+
const reason = allowed && !allowed.has(name) ? "profile-not-allowed" : blocked.has(name) ? "profile-blocked" : supported && (!scope || scope.has(name)) && !supported.has(name) ? "backend-unsupported" : null;
|
|
120
|
+
if (!reason) return true;
|
|
121
|
+
filteredTools.push({ toolName, reason });
|
|
122
|
+
return false;
|
|
123
|
+
});
|
|
124
|
+
return { finalToolNames, filteredTools };
|
|
125
|
+
}
|
|
106
126
|
function uniqueToolNames(values) {
|
|
107
127
|
return [...new Set(asTrimmedNonEmptyStringArray(values))];
|
|
108
128
|
}
|
|
@@ -1484,6 +1504,7 @@ export {
|
|
|
1484
1504
|
HIGH_RISK_MUTATION_TOOL_NAMES,
|
|
1485
1505
|
resolveReadOnlyToolConstraints,
|
|
1486
1506
|
applyToolSurfaceConstraints,
|
|
1507
|
+
resolveRequestToolSurface,
|
|
1487
1508
|
resolveRuntimeToolSurfaceForAgent,
|
|
1488
1509
|
redactAgentRecordForWorkspaceTool,
|
|
1489
1510
|
DEFAULT_READ_DIALOG_MAX_RESPONSE_CHARS,
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
refreshOpenAiCodexToken,
|
|
6
6
|
resolveServerSyncConfig,
|
|
7
7
|
xaiRefresh
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-D2J22QSE.js";
|
|
9
9
|
import {
|
|
10
10
|
clearCredentialAvailability,
|
|
11
11
|
markCredentialUnavailable,
|
|
@@ -23,7 +23,7 @@ import {
|
|
|
23
23
|
import {
|
|
24
24
|
OAUTH_PROVIDER_REFS,
|
|
25
25
|
buildLocalAgentLookupKeys
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-RPZNVBA5.js";
|
|
27
27
|
import {
|
|
28
28
|
LOCAL_CODEX_AGENT_ID,
|
|
29
29
|
LOCAL_CODEX_AGENT_KEY,
|
|
@@ -51,7 +51,7 @@ import {
|
|
|
51
51
|
createChromeConnectorClientResolver,
|
|
52
52
|
createVerifiedChromeConnectorClient,
|
|
53
53
|
executeChromeConnectorTool
|
|
54
|
-
} from "./chunk-
|
|
54
|
+
} from "./chunk-DPQYIS6D.js";
|
|
55
55
|
import {
|
|
56
56
|
applyPublicAgentCatalogOverride
|
|
57
57
|
} from "./chunk-W6E5IXIP.js";
|
|
@@ -64,7 +64,7 @@ import {
|
|
|
64
64
|
import {
|
|
65
65
|
inlineImageUrlsForCustomProvider,
|
|
66
66
|
prepareTools
|
|
67
|
-
} from "./chunk-
|
|
67
|
+
} from "./chunk-4RYUMDOM.js";
|
|
68
68
|
import {
|
|
69
69
|
getServerProviderSecret
|
|
70
70
|
} from "./chunk-HS7MLR74.js";
|
|
@@ -86,18 +86,18 @@ import {
|
|
|
86
86
|
resolveCliLocalRuntimeKeyCapability,
|
|
87
87
|
resolveCliLocalSpawnDispatch,
|
|
88
88
|
resolveStartAgentRunCwd
|
|
89
|
-
} from "./chunk-
|
|
89
|
+
} from "./chunk-TLBTPKDD.js";
|
|
90
90
|
import {
|
|
91
91
|
deriveCredentialGroup,
|
|
92
92
|
deriveCustomProviderCredentialGroup
|
|
93
|
-
} from "./chunk-
|
|
93
|
+
} from "./chunk-KPSNHLFI.js";
|
|
94
94
|
import {
|
|
95
95
|
fetchWithTransientRetry,
|
|
96
96
|
isTransientFetchError
|
|
97
97
|
} from "./chunk-KFHREHUQ.js";
|
|
98
98
|
import {
|
|
99
99
|
resolveAgentRequiredPackIds
|
|
100
|
-
} from "./chunk-
|
|
100
|
+
} from "./chunk-GXFAZGZ6.js";
|
|
101
101
|
import {
|
|
102
102
|
applyBuiltinAgentRuntimeOverride,
|
|
103
103
|
applyTokenUsageToDayStats,
|
|
@@ -106,14 +106,14 @@ import {
|
|
|
106
106
|
resolveBuiltinPlatformAgentConfig,
|
|
107
107
|
runKeyed,
|
|
108
108
|
validateAskChoiceInput
|
|
109
|
-
} from "./chunk-
|
|
109
|
+
} from "./chunk-VETQRONK.js";
|
|
110
110
|
import {
|
|
111
111
|
BUILTIN_DIALOG_LLM_CHAT_FALLBACK_MODEL,
|
|
112
112
|
BUILTIN_TITLE_LLM_CONFIG
|
|
113
113
|
} from "./chunk-523DITKR.js";
|
|
114
114
|
import {
|
|
115
115
|
fetchServerSyncedCredential
|
|
116
|
-
} from "./chunk-
|
|
116
|
+
} from "./chunk-W7S5CUGI.js";
|
|
117
117
|
import {
|
|
118
118
|
isTombstoneRecord
|
|
119
119
|
} from "./chunk-D2MDMY2M.js";
|
|
@@ -170,7 +170,7 @@ import {
|
|
|
170
170
|
runExecShellGates,
|
|
171
171
|
validateConfiguredRootExecutionLease,
|
|
172
172
|
verifyOwnerRouteAck
|
|
173
|
-
} from "./chunk-
|
|
173
|
+
} from "./chunk-BYNWE72R.js";
|
|
174
174
|
import {
|
|
175
175
|
accumulateGeminiChunks,
|
|
176
176
|
buildGeminiGenerateContentRequest,
|
|
@@ -182,7 +182,7 @@ import {
|
|
|
182
182
|
resolveAntigravityFinishReason,
|
|
183
183
|
resolveGeminiModelQuirks,
|
|
184
184
|
shouldUseGeminiNativeToolRoute
|
|
185
|
-
} from "./chunk-
|
|
185
|
+
} from "./chunk-O3OJRN5Z.js";
|
|
186
186
|
import {
|
|
187
187
|
PlatformStreamInterruptedError,
|
|
188
188
|
buildPlatformChatCompletionRequest,
|
|
@@ -193,36 +193,39 @@ import {
|
|
|
193
193
|
readPlatformChatSseCompletion,
|
|
194
194
|
resolvePlatformChatProviderConfig,
|
|
195
195
|
shouldUsePlatformChatProvider
|
|
196
|
-
} from "./chunk-
|
|
196
|
+
} from "./chunk-O2LB346J.js";
|
|
197
197
|
import {
|
|
198
198
|
readSseDataValues,
|
|
199
199
|
readSseFrames
|
|
200
200
|
} from "./chunk-HNUWUO75.js";
|
|
201
201
|
import {
|
|
202
202
|
resolveAgentRuntimeConfigFromRecord
|
|
203
|
-
} from "./chunk-
|
|
203
|
+
} from "./chunk-J33JIJK7.js";
|
|
204
204
|
import {
|
|
205
205
|
resolveHistoricalToolContentCap
|
|
206
206
|
} from "./chunk-2WZXXAQD.js";
|
|
207
207
|
import {
|
|
208
208
|
resolveAgentImageInputSupport
|
|
209
|
-
} from "./chunk-
|
|
209
|
+
} from "./chunk-7QQOOHDG.js";
|
|
210
210
|
import {
|
|
211
|
-
EMPTY_TOOL_RESULT_TEXT,
|
|
212
211
|
collectStablePromptPrefix,
|
|
213
212
|
convertMessagesToResponsesInput,
|
|
214
213
|
findAgentStatePairingIssues,
|
|
215
|
-
hadToolImages,
|
|
216
214
|
stablePromptCacheKey,
|
|
217
|
-
toResponsesTools
|
|
215
|
+
toResponsesTools
|
|
216
|
+
} from "./chunk-BGQZLBMJ.js";
|
|
217
|
+
import {
|
|
218
|
+
EMPTY_TOOL_RESULT_TEXT,
|
|
219
|
+
hadToolImages,
|
|
218
220
|
toolImages
|
|
219
|
-
} from "./chunk-
|
|
221
|
+
} from "./chunk-FX33MFLW.js";
|
|
220
222
|
import {
|
|
221
223
|
buildNoloWorkspaceOpenAiTools,
|
|
222
224
|
filterClientNoloWorkspaceToolNames,
|
|
223
225
|
parseNoloWorkspaceToolArguments,
|
|
226
|
+
resolveRequestToolSurface,
|
|
224
227
|
resolveRuntimeToolSurfaceForAgent
|
|
225
|
-
} from "./chunk-
|
|
228
|
+
} from "./chunk-2GRXE3YJ.js";
|
|
226
229
|
import {
|
|
227
230
|
isCapacitySaturatedRateLimit,
|
|
228
231
|
mergeAvailabilityDeadline,
|
|
@@ -236,18 +239,20 @@ import {
|
|
|
236
239
|
} from "./chunk-2MBTWINN.js";
|
|
237
240
|
import {
|
|
238
241
|
normalizeUsage
|
|
239
|
-
} from "./chunk-
|
|
242
|
+
} from "./chunk-T7HBI3WZ.js";
|
|
240
243
|
import {
|
|
241
244
|
isDevinOAuthAgent
|
|
242
245
|
} from "./chunk-5ZUL4CUO.js";
|
|
243
246
|
import {
|
|
244
247
|
createProviderCallTimingTracker,
|
|
245
248
|
finalizeProviderCallTiming,
|
|
246
|
-
isOAuthApiKeyRef,
|
|
247
249
|
observeMeaningfulProviderResponse,
|
|
248
250
|
observeMeaningfulProviderResponseAt,
|
|
249
251
|
withProviderCallTimingFields
|
|
250
|
-
} from "./chunk-
|
|
252
|
+
} from "./chunk-7ZGMQZ5D.js";
|
|
253
|
+
import {
|
|
254
|
+
isOAuthApiKeyRef
|
|
255
|
+
} from "./chunk-UKZX3NHN.js";
|
|
251
256
|
import {
|
|
252
257
|
clipCompactText
|
|
253
258
|
} from "./chunk-5MMAK75Q.js";
|
|
@@ -352,7 +357,7 @@ import {
|
|
|
352
357
|
} from "./chunk-LCBAMY2M.js";
|
|
353
358
|
import {
|
|
354
359
|
isAntigravityOAuthAgent
|
|
355
|
-
} from "./chunk-
|
|
360
|
+
} from "./chunk-JOUFPRE4.js";
|
|
356
361
|
import {
|
|
357
362
|
buildProviderSessionHeaders,
|
|
358
363
|
resolvePlatformAuthToken
|
|
@@ -1059,7 +1064,17 @@ function isAnthropicOAuthAgent(agent) {
|
|
|
1059
1064
|
|
|
1060
1065
|
// packages/cli/client/localRuntimeDiagnostics.ts
|
|
1061
1066
|
import { ulid } from "ulid";
|
|
1062
|
-
var
|
|
1067
|
+
var PREPARED_AGENT_RUNTIME_CACHE_LIMIT = 128;
|
|
1068
|
+
var PreparedAgentRuntimeCache = class extends Map {
|
|
1069
|
+
set(key, value) {
|
|
1070
|
+
super.set(key, value);
|
|
1071
|
+
while (this.size > PREPARED_AGENT_RUNTIME_CACHE_LIMIT) {
|
|
1072
|
+
super.delete(this.keys().next().value);
|
|
1073
|
+
}
|
|
1074
|
+
return this;
|
|
1075
|
+
}
|
|
1076
|
+
};
|
|
1077
|
+
var preparedAgentRuntimeCache = new PreparedAgentRuntimeCache();
|
|
1063
1078
|
var hybridStoreCache = /* @__PURE__ */ new Map();
|
|
1064
1079
|
function normalizeRuntimeCacheCwd(cwd) {
|
|
1065
1080
|
return (cwd?.trim() || process.cwd()).replace(/\/+$/, "") || ".";
|
|
@@ -1069,7 +1084,15 @@ function buildPreparedAgentCacheKey(args) {
|
|
|
1069
1084
|
Object.keys(args.systemBuiltinSkills).sort().map((key) => [key, args.systemBuiltinSkills?.[key]])
|
|
1070
1085
|
) : "default";
|
|
1071
1086
|
const wakeKey = args.wake !== void 0 ? args.wake ? "wake:1" : "wake:0" : "";
|
|
1072
|
-
|
|
1087
|
+
const policyKey = JSON.stringify([
|
|
1088
|
+
args.env?.NOLO_LOCAL_WORKSPACE_TOOLSET ?? "",
|
|
1089
|
+
args.env?.NOLO_LOCAL_TOOLSET_MODE ?? "",
|
|
1090
|
+
args.env?.NOLO_AGENT_RUN_CHILD ?? "",
|
|
1091
|
+
args.env?.NOLO_LOCAL_TOOL_MODE ?? "",
|
|
1092
|
+
args.env?.NOLO_LOCAL_ALLOWED_TOOLS ?? "",
|
|
1093
|
+
args.env?.NOLO_LOCAL_ALLOW_UNDECLARED_TOOLS ?? ""
|
|
1094
|
+
]);
|
|
1095
|
+
return `${policyKey}\0${args.userId}\0${args.agentRef}\0${args.cwd}\0${systemBuiltinSkillsKey}${wakeKey ? `\0${wakeKey}` : ""}`;
|
|
1073
1096
|
}
|
|
1074
1097
|
function clearCliLocalRuntimePreparedAgentCache() {
|
|
1075
1098
|
preparedAgentRuntimeCache.clear();
|
|
@@ -2952,7 +2975,13 @@ function buildGeminiCustomNativeProvider(p) {
|
|
|
2952
2975
|
return { ok: true, mimeType: image.headers.get("content-type") ?? "application/octet-stream", bytes: new Uint8Array(await image.arrayBuffer()) };
|
|
2953
2976
|
}
|
|
2954
2977
|
});
|
|
2955
|
-
const
|
|
2978
|
+
const supportsToolImages = resolveAgentImageInputSupport({
|
|
2979
|
+
...agentConfig,
|
|
2980
|
+
provider: agentConfig.provider ?? "google",
|
|
2981
|
+
model,
|
|
2982
|
+
hasVision: agentConfig.hasVision ?? false
|
|
2983
|
+
});
|
|
2984
|
+
const body = buildGeminiGenerateContentRequest({ messages: inlineResult.messages, tools, maxTokens: typeof agentConfig.max_tokens === "number" ? agentConfig.max_tokens : void 0, temperature: typeof agentConfig.temperature === "number" ? agentConfig.temperature : void 0, attachSkipThoughtSignature: resolveGeminiModelQuirks(model).allowsThoughtSignatureSentinel, supportsToolImages });
|
|
2956
2985
|
log("provider.request.start", { agentKey: agentConfig.key, transport, requestUrl: nativeEndpoint, model, messageCount: messages.length, toolCount: tools.length, requestedToolNames });
|
|
2957
2986
|
const response = await fetchImpl(nativeEndpoint, { method: "POST", headers: { "Content-Type": "application/json", ...customNativeAuthHeaders("gemini", apiKey, apiKeyHeader), ...buildProviderSessionHeaders({ endpoint, sessionId: options?.dialogId ?? fallbackSessionId }) }, body: JSON.stringify(body), signal: options?.signal ? AbortSignal.any([options.signal, AbortSignal.timeout(options.timeoutMs ?? 12e4)]) : AbortSignal.timeout(options?.timeoutMs ?? 12e4) });
|
|
2958
2987
|
if (!response.ok) {
|
|
@@ -3495,12 +3524,19 @@ var resolveGeminiNativeToolTransport = async (ctx) => {
|
|
|
3495
3524
|
model: providerConfig.model,
|
|
3496
3525
|
complete: async (messages, options) => {
|
|
3497
3526
|
const model = providerConfig.model;
|
|
3527
|
+
const supportsToolImages = resolveAgentImageInputSupport({
|
|
3528
|
+
provider: providerConfig.usageProvider ?? providerConfig.provider,
|
|
3529
|
+
model: providerConfig.model,
|
|
3530
|
+
customProviderUrl: providerConfig.endpoint,
|
|
3531
|
+
hasVision: agentConfig.hasVision ?? false
|
|
3532
|
+
});
|
|
3498
3533
|
const requestBody = buildGeminiGenerateContentRequest({
|
|
3499
3534
|
messages,
|
|
3500
3535
|
tools,
|
|
3501
3536
|
maxTokens: typeof agentConfig.max_tokens === "number" ? agentConfig.max_tokens : void 0,
|
|
3502
3537
|
temperature: typeof agentConfig.temperature === "number" ? agentConfig.temperature : void 0,
|
|
3503
|
-
attachSkipThoughtSignature: resolveGeminiModelQuirks(model).allowsThoughtSignatureSentinel
|
|
3538
|
+
attachSkipThoughtSignature: resolveGeminiModelQuirks(model).allowsThoughtSignatureSentinel,
|
|
3539
|
+
supportsToolImages
|
|
3504
3540
|
});
|
|
3505
3541
|
const url = `https://generativelanguage.googleapis.com/v1beta/models/${model}:streamGenerateContent?alt=sse`;
|
|
3506
3542
|
logLocalRuntimeDiagnostic("provider.request.start", {
|
|
@@ -9597,7 +9633,7 @@ async function createLocalDockerWorkload(args) {
|
|
|
9597
9633
|
const createLifecycle = args.createLifecycle ?? (async () => {
|
|
9598
9634
|
const [{ DockerWorkloadLifecycle, createDockerBindingAuthorizer }, accounts] = await Promise.all([
|
|
9599
9635
|
import("./workloadLifecycle-MZ2V5L43.js"),
|
|
9600
|
-
import("./accountResolver-
|
|
9636
|
+
import("./accountResolver-YGMLY3WW.js")
|
|
9601
9637
|
]);
|
|
9602
9638
|
const resolveAccount = args.resolveAccount ?? accounts.createDockerAccountResolver({
|
|
9603
9639
|
env: args.env,
|
|
@@ -12393,7 +12429,8 @@ function createCliLocalRuntimeAdapter(deps) {
|
|
|
12393
12429
|
agentRef,
|
|
12394
12430
|
cwd: normalizeRuntimeCacheCwd(workspaceRoot),
|
|
12395
12431
|
systemBuiltinSkills,
|
|
12396
|
-
wake: hasRunWakeChannel(deps.env)
|
|
12432
|
+
wake: hasRunWakeChannel(deps.env),
|
|
12433
|
+
env: deps.env
|
|
12397
12434
|
})}:${dockerRuntimeEnabled ? "docker" : instaboxRuntimeEnabled ? "instabox" : "host"}`;
|
|
12398
12435
|
const cached = deps.pastedTextStore ? void 0 : preparedAgentRuntimeCache.get(cacheKey);
|
|
12399
12436
|
if (cached) {
|
|
@@ -12418,17 +12455,16 @@ function createCliLocalRuntimeAdapter(deps) {
|
|
|
12418
12455
|
deps.env,
|
|
12419
12456
|
systemBuiltinSkills
|
|
12420
12457
|
) : [];
|
|
12421
|
-
let effectiveToolNames = [...requestedToolNames, ...additionalToolNames];
|
|
12422
12458
|
const backendExecutionToolNames = dockerRuntimeEnabled ? dockerExecutionToolNames : instaboxRuntimeEnabled ? LOCAL_INSTABOX_TOOL_NAMES : null;
|
|
12423
|
-
|
|
12424
|
-
|
|
12425
|
-
|
|
12426
|
-
|
|
12427
|
-
|
|
12428
|
-
|
|
12429
|
-
|
|
12430
|
-
|
|
12431
|
-
|
|
12459
|
+
const requestSurface = resolveRequestToolSurface({
|
|
12460
|
+
requestedToolNames: [...requestedToolNames, ...additionalToolNames],
|
|
12461
|
+
profile: { allowedToolNames: [...requestedToolNames, ...additionalToolNames] },
|
|
12462
|
+
backend: backendExecutionToolNames ? {
|
|
12463
|
+
toolNames: backendExecutionToolNames,
|
|
12464
|
+
scopedToolNames: WORKSPACE_TOOL_NAMES
|
|
12465
|
+
} : null
|
|
12466
|
+
});
|
|
12467
|
+
const effectiveToolNames = requestSurface.finalToolNames;
|
|
12432
12468
|
activeAgentToolNames = buildLocalPolicyToolNames({
|
|
12433
12469
|
agentKey: agentConfig?.key,
|
|
12434
12470
|
toolNames: effectiveToolNames,
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
inlineImageUrlsForCustomProvider,
|
|
6
6
|
prepareTools,
|
|
7
7
|
shouldInlineImageUrlsForAgent
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-4RYUMDOM.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-JDWJ64VG.js";
|
|
18
18
|
import {
|
|
19
19
|
findToolExecutor,
|
|
20
20
|
toolDefinitionsByName
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-TLBTPKDD.js";
|
|
22
22
|
import {
|
|
23
23
|
classifyApiError,
|
|
24
24
|
classifyGenerationError,
|
|
25
25
|
extractErrorDiagnostics
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-FJ76E5ZM.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-GXFAZGZ6.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-VETQRONK.js";
|
|
46
46
|
import {
|
|
47
47
|
streamAgentChatTurn
|
|
48
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-W7S5CUGI.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-BGQZLBMJ.js";
|
|
89
89
|
import {
|
|
90
90
|
EMPTY_ASSISTANT_REPAIR_PROMPT
|
|
91
|
-
} from "./chunk-
|
|
91
|
+
} from "./chunk-T7HBI3WZ.js";
|
|
92
92
|
import {
|
|
93
93
|
getModelInfo
|
|
94
|
-
} from "./chunk-
|
|
94
|
+
} from "./chunk-7ZGMQZ5D.js";
|
|
95
95
|
import {
|
|
96
96
|
isAbortError
|
|
97
97
|
} from "./chunk-7DPNBQSV.js";
|
|
@@ -10,49 +10,6 @@ import {
|
|
|
10
10
|
import {
|
|
11
11
|
isPlatformManagedProvider
|
|
12
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
|
-
}
|
|
56
13
|
|
|
57
14
|
// packages/core/chat/messageContentSerialize.ts
|
|
58
15
|
var serializeMessageContent = (content, imagePlaceholder = "[\u56FE\u7247]") => {
|
|
@@ -1062,8 +1019,6 @@ export {
|
|
|
1062
1019
|
findModelContextWindow,
|
|
1063
1020
|
getModelContextWindow,
|
|
1064
1021
|
getModelInfo,
|
|
1065
|
-
isOAuthApiKeyRef,
|
|
1066
|
-
shouldUseServerProxy,
|
|
1067
1022
|
sha256Hex,
|
|
1068
1023
|
serializeMessageContent,
|
|
1069
1024
|
resolveCompressionTriggerRatio,
|