nolo-cli 0.156.0-alpha.2 → 0.156.0
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-5WS2PA62.js → _executeModel-3FMHTHSS.js} +55 -55
- package/{accountResolver-7RYB4D2P.js → accountResolver-55EDKEIK.js} +1 -1
- package/{action-ZJYUBXFC.js → action-GPPJC5TI.js} +5 -5
- package/{addContentAction-TVHB4526.js → addContentAction-XJQEJ4XW.js} +8 -8
- package/{addDialogAgentAction-FDPBU6K6.js → addDialogAgentAction-5WZX5CAY.js} +7 -7
- package/{agentDeleteCommand-MDC7OS3I.js → agentDeleteCommand-VRHLJZKX.js} +75 -76
- package/{agentEmailCommands-WN4EOPKQ.js → agentEmailCommands-YGBQXOL3.js} +78 -79
- package/{agentListCommands-G36AMSBR.js → agentListCommands-GOCGOQUB.js} +36 -36
- package/{agentMachineCommands-63GXO27A.js → agentMachineCommands-FBAWZYHI.js} +35 -32
- package/{agentProviderCommands-X2HQE6HY.js → agentProviderCommands-CXBHNONN.js} +5 -5
- package/{agentPullCommand-FA43RBRU.js → agentPullCommand-GXXEDOSA.js} +4 -4
- package/{agentRecordCommands-X4WJRHDW.js → agentRecordCommands-KAK2G56H.js} +72 -73
- package/{agentRunCommand-4YMIVVHF.js → agentRunCommand-62P3AGJA.js} +75 -75
- package/{agentRunControl-2C5GM3BW.js → agentRunControl-XBSNHHZE.js} +7 -7
- package/{agentRuntimeLocal-Q7ZOMZC7.js → agentRuntimeLocal-J6I63NZC.js} +21 -19
- package/{agentSlice-E3XS5FTQ.js → agentSlice-IZFU3WWH.js} +8 -8
- package/{appDeleteCommands-MMWT54BR.js → appDeleteCommands-KKLAK2UR.js} +31 -29
- package/{appDeployCommands-OIFXVDOF.js → appDeployCommands-PXWK4FAX.js} +31 -29
- package/{appDeployStatusCommands-OTXMSDFB.js → appDeployStatusCommands-3NGWDZTX.js} +31 -29
- package/{appGetCommands-JPY36ANL.js → appGetCommands-APWYPEO3.js} +31 -29
- package/{appListCommands-IHJGN36O.js → appListCommands-OP7IRALO.js} +31 -29
- package/{authCommand-J3XILHWW.js → authCommand-3Z52KJID.js} +22 -302
- package/{authCommands-77CHYBGF.js → authCommands-QOCKVPX3.js} +5 -5
- package/{builtinSkillRegistry-A6VSPJEJ.js → builtinSkillRegistry-LJV7FHNI.js} +4 -4
- package/{chromeCommands-OBBNJCLS.js → chromeCommands-IY4NVSXZ.js} +17 -10
- package/{chunk-SW4S4XYB.js → chunk-2AB2HA4M.js} +84 -34
- package/{chunk-H4KACZMG.js → chunk-2QQ7D3P5.js} +271 -138
- package/{chunk-C5VPAHIU.js → chunk-32ZKZET7.js} +1 -1
- package/{chunk-FPWT3RH2.js → chunk-36IWXF25.js} +22 -22
- package/{chunk-XPWGOTBQ.js → chunk-3L2WKC3W.js} +1 -8
- package/{chunk-3XZKV7QQ.js → chunk-3L5MSPWX.js} +1 -1
- package/{chunk-QLQ573SU.js → chunk-3M52COK5.js} +120 -0
- package/{chunk-Z6KQDSZW.js → chunk-43OFVLWJ.js} +6 -6
- package/{chunk-7A4LJCDR.js → chunk-4FDDVVCE.js} +5 -5
- package/{chunk-TJ2VPCBE.js → chunk-4JCAW7TO.js} +2 -2
- package/{chunk-6TF64IF2.js → chunk-4L4K6YR7.js} +16 -2
- package/{chunk-ZG73GDYU.js → chunk-5E5VB7PS.js} +332 -59
- package/{chunk-HKT6QXP3.js → chunk-5IKRTRRR.js} +5 -5
- package/{chunk-P5QACQDK.js → chunk-62TBKWTV.js} +1 -1
- package/{chunk-TRW43TSC.js → chunk-6EQD4AQL.js} +41 -1
- package/{chunk-RUNKPFM5.js → chunk-6QIBWOPT.js} +12 -8
- package/{chunk-YLMMECCH.js → chunk-6XIE5ZGI.js} +1 -1
- package/{chunk-7GC3EKUG.js → chunk-7PDNSQZC.js} +3 -3
- package/{chunk-DW7MGLMG.js → chunk-7YQQXP42.js} +35 -207
- package/{chunk-WZ6OU4NX.js → chunk-BAWAKW7X.js} +2 -2
- package/{chunk-UUPR3TD7.js → chunk-BL4HFN6L.js} +2 -4
- package/{chunk-2GGXHQIW.js → chunk-BLVSFYQ3.js} +4 -2
- package/{chunk-HP6O6LTV.js → chunk-CDLP56BS.js} +9 -9
- package/{chunk-4LRK5Q2Z.js → chunk-CI6YDDL2.js} +18 -17
- package/{chunk-5MM7NNO6.js → chunk-CNWKLQRL.js} +8 -3
- package/{chunk-UTIMX333.js → chunk-DJ2BOPJY.js} +1 -1
- package/{chunk-36OMEXXR.js → chunk-DLV3H464.js} +8 -8
- package/{chunk-X5SUT4CN.js → chunk-EDJND3FK.js} +6 -6
- package/{chunk-CE7PIHQD.js → chunk-ESMZW5PE.js} +3 -3
- package/{chunk-PSJWPSKS.js → chunk-EWO77ZGF.js} +9 -43
- package/{chunk-ZWG3C7VI.js → chunk-F3SOW2EU.js} +81 -1
- package/{chunk-FY4SDK2E.js → chunk-FDLDMJTM.js} +1 -1
- package/chunk-FTHF2P2I.js +2685 -0
- package/{chunk-7KYVUFDG.js → chunk-G3VYRPTV.js} +5 -267
- package/{chunk-NQ64VVAI.js → chunk-GXZZOTDM.js} +826 -689
- package/{chunk-6MJNEXUU.js → chunk-HGDKT2D6.js} +4 -0
- package/{chunk-6KVZAZJA.js → chunk-HRZW3SQN.js} +7 -7
- package/{chunk-B2EGWZJG.js → chunk-I7S63QUU.js} +1 -1
- package/{chunk-ROPSATAB.js → chunk-IF7V3CBU.js} +1 -1
- package/{chunk-T6CBQ6BN.js → chunk-INFHX73M.js} +1 -1
- package/{chunk-YBNHPX4S.js → chunk-IW64YHXL.js} +155 -31
- package/{chunk-VSOWPETY.js → chunk-JIAZK434.js} +10 -10
- package/{chunk-K43ZF2C3.js → chunk-JPPQ3GUO.js} +1 -1
- package/{chunk-TZTWMGE3.js → chunk-JWEXJ573.js} +3 -3
- package/{chunk-OH2M7WEU.js → chunk-K3N2DWLT.js} +3 -3
- package/{chunk-I2ZMGXXF.js → chunk-KFHREHUQ.js} +1 -1
- package/{chunk-3C2QLERX.js → chunk-KMDDG73K.js} +1 -1
- package/{chunk-EM3YOZJ4.js → chunk-L2JMH4I5.js} +3 -3
- package/{chunk-D4OWHT5Y.js → chunk-MAYW6V3E.js} +2 -2
- package/{chunk-IPAW7XLD.js → chunk-MFVOJ6KF.js} +2 -2
- package/{chunk-CBHGZRCE.js → chunk-MYOH447Z.js} +1 -1
- package/{chunk-6MPAEODB.js → chunk-NHEWV5FD.js} +17 -3
- package/{chunk-SUKSWFLP.js → chunk-PIG2IUVZ.js} +1 -1
- package/{chunk-WP6RXNE6.js → chunk-PNACBSRF.js} +134 -126
- package/{chunk-SEJ5OS6F.js → chunk-PXYBUFDB.js} +4 -0
- package/{chunk-SKPPKHD3.js → chunk-Q5LVXPGT.js} +2 -2
- package/{chunk-2MTE2PEH.js → chunk-QA2C5NKI.js} +5 -739
- package/{chunk-XFKZ3MCV.js → chunk-QFL42TMV.js} +251 -77
- package/{chunk-L6EQV5OC.js → chunk-QXZH5UDF.js} +3 -3
- package/{chunk-TNIX77YM.js → chunk-R5GO3YZP.js} +34 -1
- package/{chunk-4Z245KOA.js → chunk-SH3XD4E2.js} +8 -4
- package/{chunk-MM3662RS.js → chunk-SNAWGDXT.js} +263 -4
- package/{chunk-JGRPBIZZ.js → chunk-SQX235S2.js} +1 -1
- package/chunk-TT644UJD.js +188 -0
- package/{chunk-IYBIRCQV.js → chunk-U34KT53V.js} +29 -11
- package/{chunk-KOB75UNU.js → chunk-U5U4WAFS.js} +19 -3
- package/{chunk-ANJTRG52.js → chunk-ULQAD7ZY.js} +18 -43
- package/{chunk-FDT27L7S.js → chunk-UUPXTEZA.js} +19 -17
- package/{chunk-QDA4Y5O6.js → chunk-V67W64OY.js} +21 -17
- package/{chunk-I2RMFLLH.js → chunk-V7PCFWX3.js} +1 -1
- package/{chunk-HXHSTRGH.js → chunk-VYNMQ6HW.js} +0 -27
- package/{chunk-G47IPDOK.js → chunk-W7FGZRLK.js} +1 -1
- package/{chunk-7BSQK2UC.js → chunk-WRCZXJ4N.js} +2 -2
- package/{chunk-KX6LPG7W.js → chunk-WYJTNSVL.js} +9 -9
- package/chunk-Y5GCAMGP.js +9 -0
- package/{chunk-JZX2XLKC.js → chunk-YCRROBDY.js} +1 -1
- package/{chunk-SCJD2PNK.js → chunk-YPG7TUQD.js} +3 -3
- package/{chunk-YANF2RR4.js → chunk-ZPKUJROL.js} +1 -1
- package/{chunk-TYND6RDQ.js → chunk-ZZDVBZOP.js} +74 -3
- package/{commandRegistry-NE2JOCQT.js → commandRegistry-2DDDET7G.js} +88 -96
- package/{contentThunks-B3FRQGP7.js → contentThunks-5DNEHJ2Z.js} +21 -21
- package/{createAgentAutomationAction-T2YFJ6MY.js → createAgentAutomationAction-4SUS2EFX.js} +21 -21
- package/{createDialogAction-2NFGFBXW.js → createDialogAction-JSFXX6JE.js} +25 -25
- package/{createPageAction-LDAVZDN7.js → createPageAction-37HHOXZ2.js} +24 -25
- package/{dbSlice-5QGKMQLO.js → dbSlice-6PVPY44C.js} +7 -7
- package/{deleteFile-EW6QNRRT.js → deleteFile-YM6NDPAR.js} +5 -5
- package/{dialogCommands-H3K7PTF6.js → dialogCommands-ZJRMCP4S.js} +35 -32
- package/{dialogSlice-64S3J6CP.js → dialogSlice-2Z66AWEW.js} +20 -20
- package/{dist-NJC2W7I4.js → dist-Q2JSMAKA.js} +7 -361
- package/{docCreateCommands-KP64KMVL.js → docCreateCommands-KQHQNLRX.js} +32 -30
- package/{docDeleteCommands-C3F4SZSR.js → docDeleteCommands-O3DWFX2W.js} +33 -31
- package/{docReadCommands-7H6BDOUR.js → docReadCommands-2U2BUONC.js} +32 -30
- package/{docStore-NIP7OO4I.js → docStore-XMTUF3GX.js} +8 -8
- package/{docUpdateCommands-JDW4BRBH.js → docUpdateCommands-MF3C52XI.js} +32 -30
- package/{getPricing-TX35D7PI.js → getPricing-XQ3N3RBP.js} +2 -2
- package/{handleSendMessageAction-TOKA7ED7.js → handleSendMessageAction-4VFVXTF2.js} +43 -39
- package/index.js +8 -8
- package/{localRuntimeAdapter-OPPDLUG3.js → localRuntimeAdapter-KKIVRYVN.js} +70 -69
- package/{localRuntimeAuthority-JDAD7CB6.js → localRuntimeAuthority-BPN5OAQG.js} +2 -2
- package/{localRuntimeDb-CVC62PM5.js → localRuntimeDb-QIVAXMUL.js} +1 -1
- package/{machineCommands-OPLQR7XY.js → machineCommands-UHQVCOD3.js} +80 -79
- package/{machineWsRunDispatch-PTS42QDK.js → machineWsRunDispatch-TX4X7TOJ.js} +70 -71
- package/{memberThunks-KRV5YXOB.js → memberThunks-AZINUM4S.js} +10 -10
- package/package.json +6 -2
- package/{profileConfig-ZGOFORWV.js → profileConfig-KN3N2BLF.js} +7 -1
- package/{providerPresetApply-CRZFMQD5.js → providerPresetApply-PKUOHQJT.js} +5 -5
- package/{providerRegistry-7IS43D3X.js → providerRegistry-HNQLIFN2.js} +5 -5
- package/{read-5KAZHHDM.js → read-7JPIWRBQ.js} +5 -5
- package/{readDocTool-5QO34OSX.js → readDocTool-AAQTB2Y3.js} +1 -1
- package/{readlineWorkspace-3XC7SEMZ.js → readlineWorkspace-BFVB2ON5.js} +375 -200
- package/{removeDialogAgentAction-6X63HMI3.js → removeDialogAgentAction-RMVRILLK.js} +9 -9
- package/{runAgentClientLoop-5QIGEALK.js → runAgentClientLoop-HHLHNMBE.js} +59 -54
- package/{runtimeDoctorCommands-56NWKNON.js → runtimeDoctorCommands-MMCP4B4U.js} +12 -12
- package/{secretCommands-ZXZRLR3R.js → secretCommands-DNY56NSU.js} +11 -1
- package/{setDialogExtraReferencesAction-4MAYKKYW.js → setDialogExtraReferencesAction-L3V7JTMG.js} +8 -8
- package/{setPrimaryDialogAgentAction-EGBAMREH.js → setPrimaryDialogAgentAction-X52JQGTJ.js} +9 -9
- package/settingThunks-N6XFWPOU.js +923 -0
- package/{spaceCommands-JQN7D4FE.js → spaceCommands-NDPGHDMD.js} +29 -27
- package/{streamAgentChatTurn-456DWXNY.js → streamAgentChatTurn-KNPOLET7.js} +154 -95
- package/{switchDialogAgentAction-YBKTD6DO.js → switchDialogAgentAction-ZJ5CGU7J.js} +7 -7
- package/{tableCommands-U3QDY4L6.js → tableCommands-IVC5S7Y3.js} +11 -11
- package/{toolApiClient-7WSJJJBV.js → toolApiClient-HGNO53TC.js} +2 -2
- package/{tools-IWNXKK4Y.js → tools-ULA7XJQT.js} +43 -44
- package/{tuiSummaryLlmCaller-KLK6K3Q3.js → tuiSummaryLlmCaller-FESHBDTT.js} +7 -7
- package/{updateCommands-NQXAGFM7.js → updateCommands-FJHGWD3Q.js} +5 -3
- package/{updateDialogTitleAction-SX53FZWO.js → updateDialogTitleAction-VUIVBDAS.js} +21 -21
- package/{workloadLifecycle-36DXRZKU.js → workloadLifecycle-6O6PMISX.js} +2 -2
- package/chunk-IA7TRNNR.js +0 -11
- package/chunk-UKZX3NHN.js +0 -48
- package/chunk-VAZHH6FO.js +0 -7012
- package/chunk-W4S6OTSC.js +0 -35
- package/clipboardy-GCO3GT3I.js +0 -11793
- package/settingThunks-FTDRZNSJ.js +0 -1371
- package/{agentGrantCommands-HOJ3JBBQ.js → agentGrantCommands-5DPHYEKP.js} +3 -3
- package/{chromeOpsCommands-3Z34RKSE.js → chromeOpsCommands-GZVVK7HU.js} +4 -4
- package/{chunk-XETG4RIX.js → chunk-AETZ7AD6.js} +4 -4
- package/{chunk-2IXDJNZI.js → chunk-GAGGEA7D.js} +3 -3
- package/{memoryCommands-CUNBFRVS.js → memoryCommands-ZS3VQJAL.js} +3 -3
- package/{offlineMarxistsAgentCommand-2QTHJCHV.js → offlineMarxistsAgentCommand-3GLX4QQY.js} +3 -3
|
@@ -1,7 +1,13 @@
|
|
|
1
|
+
import {
|
|
2
|
+
resolveAgentCallPlan
|
|
3
|
+
} from "./chunk-TT644UJD.js";
|
|
4
|
+
import {
|
|
5
|
+
SUBSCRIPTION_OAUTH_PROVIDERS
|
|
6
|
+
} from "./chunk-EWO77ZGF.js";
|
|
1
7
|
import {
|
|
2
8
|
findModelConfig,
|
|
3
9
|
getProviderByModelName
|
|
4
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-6EQD4AQL.js";
|
|
5
11
|
import {
|
|
6
12
|
asOptionalTrimmedString
|
|
7
13
|
} from "./chunk-G3SUCT4W.js";
|
|
@@ -90,16 +96,18 @@ var lookupKnownModelVision = (provider, model) => {
|
|
|
90
96
|
if (provider && provider !== "custom") {
|
|
91
97
|
const direct = findModelConfig(provider, candidate);
|
|
92
98
|
if (direct && typeof direct.hasVision === "boolean") return direct.hasVision;
|
|
93
|
-
}
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
99
|
+
} else {
|
|
100
|
+
const detected = getProviderByModelName(candidate);
|
|
101
|
+
if (detected) {
|
|
102
|
+
const found = findModelConfig(detected, candidate)?.hasVision;
|
|
103
|
+
if (found !== void 0) return found;
|
|
104
|
+
}
|
|
98
105
|
}
|
|
99
106
|
if (candidate.includes("/")) {
|
|
100
107
|
const slash = candidate.indexOf("/");
|
|
101
108
|
const modelProvider = candidate.slice(0, slash).toLowerCase();
|
|
102
109
|
const modelName = candidate.slice(slash + 1);
|
|
110
|
+
if (provider && provider !== "custom" && provider !== modelProvider) continue;
|
|
103
111
|
const nested = findModelConfig(modelProvider, modelName);
|
|
104
112
|
if (nested && typeof nested.hasVision === "boolean") return nested.hasVision;
|
|
105
113
|
}
|
|
@@ -108,12 +116,22 @@ var lookupKnownModelVision = (provider, model) => {
|
|
|
108
116
|
};
|
|
109
117
|
var resolveAgentImageInputSupport = (agent) => {
|
|
110
118
|
if (!agent) return true;
|
|
111
|
-
const provider = asTrimmedLowercaseString(agent.provider) || null;
|
|
119
|
+
const provider = asTrimmedLowercaseString(agent.provider) || asTrimmedLowercaseString(agent.apiSource) || null;
|
|
112
120
|
const model = asOptionalTrimmedString(agent.model) ?? "";
|
|
113
|
-
const
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
121
|
+
const { authMethod } = resolveAgentCallPlan({
|
|
122
|
+
key: "",
|
|
123
|
+
provider: agent.provider ?? void 0,
|
|
124
|
+
apiSource: agent.apiSource ?? void 0,
|
|
125
|
+
cliProvider: agent.cliProvider ?? void 0,
|
|
126
|
+
model,
|
|
127
|
+
apiKeyRef: agent.apiKeyRef ?? void 0,
|
|
128
|
+
customProviderUrl: agent.customProviderUrl ?? void 0,
|
|
129
|
+
apiKey: agent.apiKey ?? void 0,
|
|
130
|
+
useServerProxy: agent.useServerProxy ?? void 0
|
|
131
|
+
});
|
|
132
|
+
const catalogHasVision = authMethod.kind === "oauth" ? SUBSCRIPTION_OAUTH_PROVIDERS.find((entry) => entry.apiKeyRef === authMethod.ref)?.modelOptions.find(
|
|
133
|
+
(entry) => [model, stripEffortSuffix(model), stripPreviewSuffix(model)].includes(entry.id)
|
|
134
|
+
)?.hasVision : lookupKnownModelVision(provider, model);
|
|
117
135
|
if (catalogHasVision !== void 0) {
|
|
118
136
|
return catalogHasVision;
|
|
119
137
|
}
|
|
@@ -5,10 +5,10 @@ import {
|
|
|
5
5
|
} from "./chunk-NBTY7YJF.js";
|
|
6
6
|
import {
|
|
7
7
|
resolveCliLocalRuntimeKeyCapability
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-QFL42TMV.js";
|
|
9
9
|
import {
|
|
10
10
|
HIGH_RISK_MUTATION_TOOL_NAMES
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-3M52COK5.js";
|
|
12
12
|
import {
|
|
13
13
|
DEFAULT_NOLO_SERVER_URL
|
|
14
14
|
} from "./chunk-OLZBQWZU.js";
|
|
@@ -150,7 +150,7 @@ function writeUsage(output, commandPath) {
|
|
|
150
150
|
return;
|
|
151
151
|
}
|
|
152
152
|
output.write(
|
|
153
|
-
"Usage: nolo agent run <agent> <message> [--local|--server|--auto] [--runtime-key <key>] [--ephemeral|--memory-only] [--continue <dialogId>] [--cwd <path>]\n nolo agent run --agent <agent> (--msg <message>|--msg-file <path>) [--image <url-or-path>] [--space <spaceId>] [--category <name>] [--inherit-from-dialog <dialog>] [--parent-dialog <dialog>] [--subject-dialog <dialog>] [--subject-ref <kind:id[:role]>] [--task-row-dbkey <key>] [--fallback-agent <agent>] (suggestions for agent to decide on quota) [--allowed-tool <tool>] [--blocked-tool <tool>] [--read-only] [--runtime-key <key>] [--machine-shell] [--dod <cmd>] [--bg] [--timeout-ms <n>] [--events jsonl] [--no-stream] [--skill <dbKey-or-md-path>]\n"
|
|
153
|
+
"Usage: nolo agent run <agent> <message> [--local|--server|--auto] [--runtime-key <key>] [--docker-workspace-mode git|empty] [--ephemeral|--memory-only] [--continue <dialogId>] [--cwd <path>]\n nolo agent run --agent <agent> (--msg <message>|--msg-file <path>) [--image <url-or-path>] [--space <spaceId>] [--category <name>] [--inherit-from-dialog <dialog>] [--parent-dialog <dialog>] [--subject-dialog <dialog>] [--subject-ref <kind:id[:role]>] [--task-row-dbkey <key>] [--fallback-agent <agent>] (suggestions for agent to decide on quota) [--allowed-tool <tool>] [--blocked-tool <tool>] [--read-only] [--runtime-key <key>] [--docker-workspace-mode git|empty] [--machine-shell] [--dod <cmd>] [--bg] [--timeout-ms <n>] [--events jsonl] [--no-stream] [--skill <dbKey-or-md-path>]\n"
|
|
154
154
|
);
|
|
155
155
|
}
|
|
156
156
|
function parseAgentRunArgs(args, options = {}) {
|
|
@@ -166,6 +166,21 @@ function parseAgentRunArgs(args, options = {}) {
|
|
|
166
166
|
const message = rawMessage.trim();
|
|
167
167
|
const rawRuntimeKey = readFlagValue(args, "--runtime-key");
|
|
168
168
|
const runtimeKey = rawRuntimeKey?.trim();
|
|
169
|
+
const rawDockerWorkspaceMode = readFlagValue(args, "--docker-workspace-mode")?.trim();
|
|
170
|
+
if (args.includes("--docker-workspace-mode") && rawDockerWorkspaceMode !== "git" && rawDockerWorkspaceMode !== "empty") {
|
|
171
|
+
throw new Error("--docker-workspace-mode \u5FC5\u987B\u662F git \u6216 empty");
|
|
172
|
+
}
|
|
173
|
+
const dockerWorkspaceMode = rawDockerWorkspaceMode;
|
|
174
|
+
if (dockerWorkspaceMode && !/^docker(:.+)?$/.test(runtimeKey ?? "")) {
|
|
175
|
+
throw new Error("--docker-workspace-mode \u4EC5\u9002\u7528\u4E8E --runtime-key docker[:runtimeId]");
|
|
176
|
+
}
|
|
177
|
+
const dockerWorkspaceModeRuntimeMode = runtimeModeFromArgs(args);
|
|
178
|
+
const dockerWorkspaceModeImplicitLocal = !dockerWorkspaceModeRuntimeMode && (isFullstackCodingAgentRef(rawAgentKey, agentKey) || isLocalCliAgentKey(agentKey) || args.includes("--dangerously-allow-shell"));
|
|
179
|
+
if (dockerWorkspaceMode && dockerWorkspaceModeRuntimeMode !== "local" && !dockerWorkspaceModeImplicitLocal) {
|
|
180
|
+
throw new Error(
|
|
181
|
+
"--docker-workspace-mode \u9700\u8981\u672C\u673A\u6267\u884C\u8DEF\u5F84\uFF1A\u4E0D\u5E26 --local \u65F6 runtimeMode \u89E3\u6790\u4E3A auto\uFF0C\u8BE5\u53C2\u6570\u4F1A\u88AB\u9759\u9ED8\u4E22\u5F03\u5E76\u6539\u8D70\u670D\u52A1\u7AEF\u6D3E\u53D1\u3002\u8BF7\u52A0 --local\uFF1B\u9690\u5F0F local\uFF08fullstack / local-cli agent / --dangerously-allow-shell\uFF09\u540C\u6837\u88AB\u63A5\u53D7\u3002"
|
|
182
|
+
);
|
|
183
|
+
}
|
|
169
184
|
if (args.includes("--runtime-key") && !runtimeKey) {
|
|
170
185
|
throw new Error(
|
|
171
186
|
"runtimeKey \u5FC5\u987B\u662F\u975E\u7A7A\u7684 listRuntimes key\uFF08local | server | machine:<machineId> | docker | docker:<runtimeId> | instabox | gcp\uFF09"
|
|
@@ -244,6 +259,7 @@ function parseAgentRunArgs(args, options = {}) {
|
|
|
244
259
|
} : {},
|
|
245
260
|
...runtimeMode ? { runtimeMode } : !runtimeKey && (fullstackLocalWorkspaceDefault || explicitLocalCliAgentDefault || args.includes("--dangerously-allow-shell")) ? { runtimeMode: "local" } : {},
|
|
246
261
|
...runtimeKey ? { runtimeKey } : {},
|
|
262
|
+
...dockerWorkspaceMode ? { dockerWorkspaceMode } : {},
|
|
247
263
|
background: args.includes("--bg"),
|
|
248
264
|
noStream: args.includes("--no-stream"),
|
|
249
265
|
machineShell: args.includes("--machine-shell"),
|
|
@@ -1,12 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
isDevinOAuthAgent
|
|
3
|
-
} from "./chunk-5ZUL4CUO.js";
|
|
4
1
|
import {
|
|
5
2
|
resolveAgentImageInputSupport
|
|
6
|
-
} from "./chunk-
|
|
7
|
-
import {
|
|
8
|
-
getModelContextWindow
|
|
9
|
-
} from "./chunk-2MTE2PEH.js";
|
|
3
|
+
} from "./chunk-U34KT53V.js";
|
|
10
4
|
import {
|
|
11
5
|
asOptionalFiniteNumber
|
|
12
6
|
} from "./chunk-WWC7I6TA.js";
|
|
@@ -39,9 +33,13 @@ function hasImageInRuntimeMessages(messages) {
|
|
|
39
33
|
var IMAGE_OMITTED_PLACEHOLDER = "[Image content omitted: model does not support image input]";
|
|
40
34
|
function stripImagePartsFromContent(content) {
|
|
41
35
|
if (!Array.isArray(content)) return content;
|
|
42
|
-
const
|
|
43
|
-
if (
|
|
44
|
-
|
|
36
|
+
const hasImage = content.some((part) => part && typeof part === "object" && part.type === "image_url");
|
|
37
|
+
if (!hasImage) return content;
|
|
38
|
+
const hasNonImage = content.some((part) => part && typeof part === "object" && part.type !== "image_url");
|
|
39
|
+
if (!hasNonImage) return IMAGE_OMITTED_PLACEHOLDER;
|
|
40
|
+
return content.map(
|
|
41
|
+
(part) => part && typeof part === "object" && part.type === "image_url" ? { type: "text", text: IMAGE_OMITTED_PLACEHOLDER } : part
|
|
42
|
+
);
|
|
45
43
|
}
|
|
46
44
|
function stripImagePartsFromMessages(messages) {
|
|
47
45
|
return messages.map((msg) => ({
|
|
@@ -51,39 +49,17 @@ function stripImagePartsFromMessages(messages) {
|
|
|
51
49
|
}
|
|
52
50
|
async function stripImagePartsForTextOnlyAgent(messages, agentConfig) {
|
|
53
51
|
const supportsVision = resolveAgentImageInputSupport(agentConfig);
|
|
54
|
-
const
|
|
55
|
-
|
|
52
|
+
const runtimeMessages = messages;
|
|
53
|
+
const hasImages = hasImageInRuntimeMessages(runtimeMessages);
|
|
54
|
+
const shouldStrip = !supportsVision && hasImages;
|
|
55
|
+
const omittedImageCount = shouldStrip ? extractImageUrlsFromMessages(runtimeMessages).length : 0;
|
|
56
|
+
return {
|
|
57
|
+
messages: shouldStrip ? stripImagePartsFromMessages(messages) : messages,
|
|
58
|
+
downgraded: shouldStrip,
|
|
59
|
+
omittedImageCount
|
|
60
|
+
};
|
|
56
61
|
}
|
|
57
62
|
|
|
58
|
-
// packages/agent-runtime/devin/devinChannelWindows.ts
|
|
59
|
-
var DEVIN_CHANNEL_CONTEXT_WINDOWS = {
|
|
60
|
-
// SWE-2 家族(catalog 无裸 swe-2 selector;旧点号/裸写法如 swe-2、
|
|
61
|
-
// swe-1.7 实测均 permission_denied,已不是可用 selector)。
|
|
62
|
-
"swe-2-max": 262e3,
|
|
63
|
-
"swe-2-high": 262e3,
|
|
64
|
-
"swe-2-medium": 262e3,
|
|
65
|
-
// SWE-1.7 家族。
|
|
66
|
-
"swe-1-7": 262e3,
|
|
67
|
-
"swe-1-7-medium": 262e3,
|
|
68
|
-
"swe-1-7-lightning": 202752,
|
|
69
|
-
// SWE-1.6 家族(免费档默认)。
|
|
70
|
-
"swe-1-6": 2e5,
|
|
71
|
-
"swe-1-6-fast": 2e5,
|
|
72
|
-
// 经 devin 通道转售、且与厂商原生窗口不同的模型(catalog 枚举型 selector)。
|
|
73
|
-
"MODEL_GPT_5_2_LOW": 384e3,
|
|
74
|
-
"MODEL_GPT_5_2_MEDIUM": 384e3,
|
|
75
|
-
"MODEL_GPT_5_2_HIGH": 384e3,
|
|
76
|
-
"MODEL_GPT_5_2_XHIGH": 384e3
|
|
77
|
-
};
|
|
78
|
-
var devinChannelContextWindow = (model) => {
|
|
79
|
-
const raw = model?.trim();
|
|
80
|
-
if (!raw) return void 0;
|
|
81
|
-
return DEVIN_CHANNEL_CONTEXT_WINDOWS[raw];
|
|
82
|
-
};
|
|
83
|
-
var resolveAgentContextWindow = (agent) => (isDevinOAuthAgent(agent) ? devinChannelContextWindow(agent.model) : void 0) ?? // provider 透传给全局解析:平台托管通道(CF)与 Codex OAuth 等通道对同一 id
|
|
84
|
-
// 窗口不同,按通道取真值,不做全局取大/取小。
|
|
85
|
-
getModelContextWindow(agent.model ?? "", agent.provider);
|
|
86
|
-
|
|
87
63
|
// packages/agent-runtime/agentRecordConfig.ts
|
|
88
64
|
function stringField(record, key) {
|
|
89
65
|
const value = record[key];
|
|
@@ -449,11 +425,10 @@ function assertDesktopAgentRuntimeTurnBodyHasNoRawSecrets(body) {
|
|
|
449
425
|
}
|
|
450
426
|
|
|
451
427
|
export {
|
|
428
|
+
extractImageUrlsFromMessages,
|
|
452
429
|
hasImageInRuntimeMessages,
|
|
453
430
|
stripImagePartsFromMessages,
|
|
454
431
|
stripImagePartsForTextOnlyAgent,
|
|
455
|
-
devinChannelContextWindow,
|
|
456
|
-
resolveAgentContextWindow,
|
|
457
432
|
resolveAgentRuntimeConfigFromRecord,
|
|
458
433
|
buildDesktopAgentRuntimeAgentConfigSnapshot,
|
|
459
434
|
buildDesktopAgentRuntimeDialogHistorySnapshot,
|
|
@@ -7,15 +7,17 @@ import {
|
|
|
7
7
|
listUserRecordsFromServers,
|
|
8
8
|
readDbRecordFromServers,
|
|
9
9
|
readLiveDbRecordAfterTombstoneMerge
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-W7FGZRLK.js";
|
|
11
|
+
import {
|
|
12
|
+
parsePositiveFiniteNumberOrFallback
|
|
13
|
+
} from "./chunk-Y5GCAMGP.js";
|
|
11
14
|
import {
|
|
12
15
|
fetchWithTransientRetry
|
|
13
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-KFHREHUQ.js";
|
|
14
17
|
import {
|
|
15
18
|
DRAIN_EXHAUSTED_USER_MESSAGE,
|
|
16
|
-
isDrainExhaustedResponse
|
|
17
|
-
|
|
18
|
-
} from "./chunk-XPWGOTBQ.js";
|
|
19
|
+
isDrainExhaustedResponse
|
|
20
|
+
} from "./chunk-3L2WKC3W.js";
|
|
19
21
|
import {
|
|
20
22
|
buildDialogAttachmentPlan,
|
|
21
23
|
extractFileContentIds
|
|
@@ -30,7 +32,7 @@ import {
|
|
|
30
32
|
boundSummaryText,
|
|
31
33
|
buildDialogReadEnvelope,
|
|
32
34
|
projectDialogReadForAgent
|
|
33
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-3M52COK5.js";
|
|
34
36
|
import {
|
|
35
37
|
asRecordOrEmpty
|
|
36
38
|
} from "./chunk-KX6YBIHG.js";
|
|
@@ -40,22 +42,13 @@ import {
|
|
|
40
42
|
} from "./chunk-I42VC5KR.js";
|
|
41
43
|
import {
|
|
42
44
|
resolveRunsDir
|
|
43
|
-
} from "./chunk-
|
|
44
|
-
import {
|
|
45
|
-
isRecord
|
|
46
|
-
} from "./chunk-KUG52IAP.js";
|
|
47
|
-
import {
|
|
48
|
-
asTrimmedString
|
|
49
|
-
} from "./chunk-3EUW3WEO.js";
|
|
45
|
+
} from "./chunk-SNAWGDXT.js";
|
|
50
46
|
import {
|
|
51
47
|
getDefaultCliLocalRuntimeDb
|
|
52
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-GAGGEA7D.js";
|
|
53
49
|
import {
|
|
54
50
|
isLevelLockError
|
|
55
51
|
} from "./chunk-AWVFQMOV.js";
|
|
56
|
-
import {
|
|
57
|
-
toErrorMessage
|
|
58
|
-
} from "./chunk-HNMXYYJR.js";
|
|
59
52
|
import {
|
|
60
53
|
resolveLocalDialogDbCandidates,
|
|
61
54
|
resolveNoloHome,
|
|
@@ -69,6 +62,15 @@ import {
|
|
|
69
62
|
resolveServerCandidates,
|
|
70
63
|
resolveServerUrl
|
|
71
64
|
} from "./chunk-A7GB5UGH.js";
|
|
65
|
+
import {
|
|
66
|
+
isRecord
|
|
67
|
+
} from "./chunk-KUG52IAP.js";
|
|
68
|
+
import {
|
|
69
|
+
asTrimmedString
|
|
70
|
+
} from "./chunk-3EUW3WEO.js";
|
|
71
|
+
import {
|
|
72
|
+
toErrorMessage
|
|
73
|
+
} from "./chunk-HNMXYYJR.js";
|
|
72
74
|
import {
|
|
73
75
|
DEFAULT_LOCAL_API_ORIGIN
|
|
74
76
|
} from "./chunk-4SN6J65J.js";
|
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
inlineImageUrlsForCustomProvider,
|
|
6
6
|
prepareTools,
|
|
7
7
|
shouldInlineImageUrlsForAgent
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-Q5LVXPGT.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-7YQQXP42.js";
|
|
18
18
|
import {
|
|
19
19
|
findToolExecutor,
|
|
20
20
|
toolDefinitionsByName
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-QFL42TMV.js";
|
|
22
22
|
import {
|
|
23
23
|
classifyApiError,
|
|
24
24
|
classifyGenerationError,
|
|
25
25
|
extractErrorDiagnostics
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-JIAZK434.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-6QIBWOPT.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-2QQ7D3P5.js";
|
|
46
46
|
import {
|
|
47
47
|
streamAgentChatTurn
|
|
48
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-EDJND3FK.js";
|
|
49
49
|
import {
|
|
50
50
|
getCurrentSpaceId
|
|
51
51
|
} from "./chunk-ZJ7UHBJS.js";
|
|
@@ -56,16 +56,16 @@ import {
|
|
|
56
56
|
} from "./chunk-OWYYDMGJ.js";
|
|
57
57
|
import {
|
|
58
58
|
selectCurrentServer
|
|
59
|
-
} from "./chunk-
|
|
59
|
+
} from "./chunk-32ZKZET7.js";
|
|
60
60
|
import {
|
|
61
61
|
write
|
|
62
|
-
} from "./chunk-
|
|
62
|
+
} from "./chunk-CDLP56BS.js";
|
|
63
63
|
import {
|
|
64
64
|
createAsyncThunk
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-WRCZXJ4N.js";
|
|
66
66
|
import {
|
|
67
67
|
selectIdentityToken
|
|
68
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-PXYBUFDB.js";
|
|
69
69
|
import {
|
|
70
70
|
classifyOutboundErrorCategory,
|
|
71
71
|
createOutboundDiagnosticCall,
|
|
@@ -85,13 +85,13 @@ import {
|
|
|
85
85
|
} from "./chunk-56GBUMO5.js";
|
|
86
86
|
import {
|
|
87
87
|
normalizeChatCompletionsBodyForProvider
|
|
88
|
-
} from "./chunk-
|
|
88
|
+
} from "./chunk-4L4K6YR7.js";
|
|
89
89
|
import {
|
|
90
90
|
EMPTY_ASSISTANT_REPAIR_PROMPT
|
|
91
|
-
} from "./chunk-
|
|
91
|
+
} from "./chunk-F3SOW2EU.js";
|
|
92
92
|
import {
|
|
93
93
|
getModelInfo
|
|
94
|
-
} from "./chunk-
|
|
94
|
+
} from "./chunk-QA2C5NKI.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-6EQD4AQL.js";
|
|
109
109
|
import {
|
|
110
110
|
isRecord
|
|
111
111
|
} from "./chunk-KUG52IAP.js";
|
|
@@ -573,7 +573,10 @@ var processToolData = createAsyncThunk(
|
|
|
573
573
|
const toolResult = await found.executor(executionToolArgs, thunkApi, {
|
|
574
574
|
parentMessageId,
|
|
575
575
|
toolRunId,
|
|
576
|
-
agentKey
|
|
576
|
+
agentKey,
|
|
577
|
+
// 定档信号:这里是前台对话流式路径,来源恒为 chat;对话 id 用于数历史搜索。
|
|
578
|
+
...args.dialogId ? { dialogId: args.dialogId } : {},
|
|
579
|
+
origin: "chat"
|
|
577
580
|
});
|
|
578
581
|
const rawData = toolResult?.rawData ?? toolResult;
|
|
579
582
|
const llmContext = asOptionalTrimmedString(toolResult?.llmContext);
|
|
@@ -750,7 +753,8 @@ var handleToolCalls = createAsyncThunk(
|
|
|
750
753
|
toolCall: { ...toolCall, id: toolCallId },
|
|
751
754
|
parentMessageId: messageId,
|
|
752
755
|
toolRunId,
|
|
753
|
-
agentKey: agentConfig.dbKey
|
|
756
|
+
agentKey: agentConfig.dbKey,
|
|
757
|
+
dialogId
|
|
754
758
|
})
|
|
755
759
|
).unwrap();
|
|
756
760
|
const toolName = result.toolName;
|
|
@@ -4,32 +4,6 @@ import {
|
|
|
4
4
|
import {
|
|
5
5
|
normalizeServerOrigin
|
|
6
6
|
} from "./chunk-CF7PE763.js";
|
|
7
|
-
import {
|
|
8
|
-
asTrimmedLowercaseString
|
|
9
|
-
} from "./chunk-QSJ3HFEF.js";
|
|
10
|
-
|
|
11
|
-
// packages/app/theme/fontPreference.ts
|
|
12
|
-
var FONT_PRESET_ALIASES = {
|
|
13
|
-
system: "system",
|
|
14
|
-
default: "system",
|
|
15
|
-
hei: "hei",
|
|
16
|
-
heiti: "hei",
|
|
17
|
-
sans: "hei",
|
|
18
|
-
song: "song",
|
|
19
|
-
songti: "song",
|
|
20
|
-
serif: "song",
|
|
21
|
-
kai: "kai",
|
|
22
|
-
kaiti: "kai",
|
|
23
|
-
"kai-ti": "kai",
|
|
24
|
-
"fang-song": "fang-song",
|
|
25
|
-
fangsong: "fang-song",
|
|
26
|
-
"fang song": "fang-song"
|
|
27
|
-
};
|
|
28
|
-
var normalizeFontPreset = (value) => {
|
|
29
|
-
const normalized = asTrimmedLowercaseString(value);
|
|
30
|
-
if (!Object.hasOwn(FONT_PRESET_ALIASES, normalized)) return void 0;
|
|
31
|
-
return FONT_PRESET_ALIASES[normalized];
|
|
32
|
-
};
|
|
33
7
|
|
|
34
8
|
// packages/ai/policy/types.ts
|
|
35
9
|
var DEFAULT_AGENT_BASE_POLICY = {
|
|
@@ -147,7 +121,6 @@ var normalizeAgentUpdateFieldList = (value, fallback = DEFAULT_AUTO_APPROVED_SEL
|
|
|
147
121
|
};
|
|
148
122
|
|
|
149
123
|
export {
|
|
150
|
-
normalizeFontPreset,
|
|
151
124
|
DEFAULT_AGENT_BASE_POLICY,
|
|
152
125
|
DEFAULT_USER_PREFERENCE_PROFILE,
|
|
153
126
|
AGENT_UPDATE_FIELD_NAMES,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
selectIdentityToken
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-PXYBUFDB.js";
|
|
4
4
|
import {
|
|
5
5
|
isAbortError
|
|
6
6
|
} from "./chunk-7DPNBQSV.js";
|
|
@@ -996,7 +996,7 @@ function peek(draft, prop) {
|
|
|
996
996
|
return source[prop];
|
|
997
997
|
}
|
|
998
998
|
function isRelocatedBaseRef(state, prop, value) {
|
|
999
|
-
if (state.type_ !== 1 || !state.allIndicesReassigned_ ||
|
|
999
|
+
if (state.type_ !== 1 || !state.allIndicesReassigned_ || !isDraftable(value) || value[DRAFT_STATE]) {
|
|
1000
1000
|
return false;
|
|
1001
1001
|
}
|
|
1002
1002
|
return state.baseRefs_.has(value);
|
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import {
|
|
2
|
-
isOAuthApiKeyRef
|
|
3
|
-
} from "./chunk-UKZX3NHN.js";
|
|
4
1
|
import {
|
|
5
2
|
fnv1a32Hex
|
|
6
3
|
} from "./chunk-UEILX4EV.js";
|
|
7
4
|
import {
|
|
8
5
|
compareAgentSelection
|
|
9
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-3M52COK5.js";
|
|
10
7
|
import {
|
|
11
8
|
isAgentUnavailableNow
|
|
12
9
|
} from "./chunk-3MZAGMYY.js";
|
|
10
|
+
import {
|
|
11
|
+
isOAuthApiKeyRef
|
|
12
|
+
} from "./chunk-F3SOW2EU.js";
|
|
13
13
|
import {
|
|
14
14
|
isOwnedAgentKey,
|
|
15
15
|
ownedAgentKey,
|
|
16
16
|
publicAgentKey
|
|
17
17
|
} from "./chunk-M2EJHDJP.js";
|
|
18
|
+
import {
|
|
19
|
+
getModelAbility
|
|
20
|
+
} from "./chunk-FYYSDHVQ.js";
|
|
18
21
|
import {
|
|
19
22
|
isSubscriptionEndpoint,
|
|
20
23
|
isSubscriptionOAuthCredential
|
|
21
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-EWO77ZGF.js";
|
|
22
25
|
import {
|
|
23
26
|
isAntigravityOAuthAgent
|
|
24
|
-
} from "./chunk-
|
|
25
|
-
import {
|
|
26
|
-
getModelAbility
|
|
27
|
-
} from "./chunk-FYYSDHVQ.js";
|
|
27
|
+
} from "./chunk-SQX235S2.js";
|
|
28
28
|
|
|
29
29
|
// packages/ai/agent/agentBilling.ts
|
|
30
30
|
function resolveBillingSource(candidate) {
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
// packages/core/positiveFiniteNumberOrFallback.ts
|
|
2
|
+
function parsePositiveFiniteNumberOrFallback(value, fallback) {
|
|
3
|
+
const parsed = Number(value);
|
|
4
|
+
return Number.isFinite(parsed) && parsed > 0 ? parsed : fallback;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
export {
|
|
8
|
+
parsePositiveFiniteNumberOrFallback
|
|
9
|
+
};
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
selectCurrentServer,
|
|
3
3
|
selectRemoteServers
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-32ZKZET7.js";
|
|
5
5
|
import {
|
|
6
6
|
noloDeleteRequest,
|
|
7
7
|
noloWriteRequest
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-WRCZXJ4N.js";
|
|
9
9
|
import {
|
|
10
10
|
normalizeTimeFields
|
|
11
11
|
} from "./chunk-6Q7UTJKR.js";
|
|
12
12
|
import {
|
|
13
13
|
selectIdentityUser,
|
|
14
14
|
selectIdentityUserId
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-PXYBUFDB.js";
|
|
16
16
|
import {
|
|
17
17
|
createUserKey,
|
|
18
18
|
extractAgentInfo,
|