nolo-cli 0.153.0-alpha.1 → 0.153.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.
Files changed (152) hide show
  1. package/{_executeModel-4KHFMQT4.js → _executeModel-NID5KIUZ.js} +46 -48
  2. package/{accountResolver-7RYB4D2P.js → accountResolver-55EDKEIK.js} +1 -1
  3. package/{action-SXJD5N5R.js → action-GPPJC5TI.js} +4 -4
  4. package/{addContentAction-ZV774PHH.js → addContentAction-BI6RDRTQ.js} +8 -8
  5. package/{addDialogAgentAction-A6SMKAGH.js → addDialogAgentAction-4RJYUSIK.js} +7 -7
  6. package/{agentDeleteCommand-EKFV5FC7.js → agentDeleteCommand-6HYGISLC.js} +59 -60
  7. package/{agentEmailCommands-MNV3MUH5.js → agentEmailCommands-Q7UW4SRL.js} +61 -62
  8. package/{agentListCommands-E6FYKXC3.js → agentListCommands-MM5OLPBY.js} +23 -23
  9. package/{agentMachineCommands-2GFUU7GF.js → agentMachineCommands-V5TSZ2QN.js} +22 -21
  10. package/{agentProviderCommands-HL6MBLCL.js → agentProviderCommands-MKG2OOEY.js} +2 -2
  11. package/{agentRecordCommands-LPHHTEPM.js → agentRecordCommands-P2YXZEWY.js} +59 -60
  12. package/{agentRunCommand-JSPW7W32.js → agentRunCommand-B2MBD56K.js} +61 -61
  13. package/{agentRunControl-IFM7IGMG.js → agentRunControl-2C5GM3BW.js} +5 -5
  14. package/{agentRuntimeLocal-ARS4TV77.js → agentRuntimeLocal-RJKTDWNN.js} +16 -16
  15. package/{agentSlice-IP4DZNNV.js → agentSlice-636W6M5A.js} +8 -8
  16. package/{appDeleteCommands-JHTLKQSX.js → appDeleteCommands-7EOM274T.js} +21 -21
  17. package/{appDeployCommands-5V26M2KA.js → appDeployCommands-2I3QYJ5G.js} +21 -21
  18. package/{appDeployStatusCommands-SBSPS627.js → appDeployStatusCommands-LEML7FPR.js} +21 -21
  19. package/{appGetCommands-NKPD2L45.js → appGetCommands-ZQSVHGQM.js} +21 -21
  20. package/{appListCommands-ZOGRZFYY.js → appListCommands-BVA7XKQO.js} +21 -21
  21. package/{authCommand-QYN47CQD.js → authCommand-NIV3DKPF.js} +13 -293
  22. package/{authCommands-77CHYBGF.js → authCommands-AMNIAKEG.js} +2 -2
  23. package/{builtinSkillRegistry-TDQ6JB2E.js → builtinSkillRegistry-H3AY27TR.js} +3 -3
  24. package/{chromeCommands-OBBNJCLS.js → chromeCommands-IY4NVSXZ.js} +17 -10
  25. package/{chunk-SW4S4XYB.js → chunk-2AB2HA4M.js} +84 -34
  26. package/{chunk-4PXHOOFA.js → chunk-2MTE2PEH.js} +3 -3
  27. package/{chunk-4YRTZIVN.js → chunk-2SGAI64X.js} +2 -2
  28. package/{chunk-QFEW2ULV.js → chunk-32ZKZET7.js} +1 -1
  29. package/{chunk-GQV5KHJU.js → chunk-3C2QLERX.js} +1 -1
  30. package/{chunk-XPWGOTBQ.js → chunk-3L2WKC3W.js} +1 -8
  31. package/{chunk-WD4XYDYC.js → chunk-3WIXU4XO.js} +224 -1
  32. package/{chunk-6LIKQYG4.js → chunk-42QZQ6QG.js} +21 -23
  33. package/{chunk-YBNHPX4S.js → chunk-4RJJDA57.js} +1 -1
  34. package/{chunk-PFBIXTFB.js → chunk-6CTXMBXD.js} +56 -30
  35. package/{chunk-HL3O3PCQ.js → chunk-6TF64IF2.js} +2 -2
  36. package/{chunk-PMYAE4OZ.js → chunk-7HVMGI5M.js} +3 -3
  37. package/{chunk-BNDETALN.js → chunk-7NSQJKGA.js} +45 -13
  38. package/{chunk-UUPR3TD7.js → chunk-7RF4O6AT.js} +1 -3
  39. package/{chunk-HSJPKBLC.js → chunk-ANJTRG52.js} +2 -2
  40. package/{chunk-2GGXHQIW.js → chunk-BLVSFYQ3.js} +4 -2
  41. package/{chunk-ISQL4V7C.js → chunk-C3OK72G3.js} +1 -1
  42. package/{chunk-CHCS6XPJ.js → chunk-CGFNDIKK.js} +65 -0
  43. package/{chunk-5MM7NNO6.js → chunk-CNWKLQRL.js} +8 -3
  44. package/{chunk-F32Z66T4.js → chunk-CON6SI7N.js} +1 -1
  45. package/{chunk-AHYBQP3M.js → chunk-CQFBGOKS.js} +3 -3
  46. package/{chunk-HIQ4GF53.js → chunk-DC3SZCRR.js} +7 -3
  47. package/{chunk-RVWMAFIT.js → chunk-FYYSDHVQ.js} +1 -1
  48. package/{chunk-TYYRSFBG.js → chunk-HB4XPBC7.js} +3 -35
  49. package/{chunk-6MJNEXUU.js → chunk-HGDKT2D6.js} +4 -0
  50. package/{chunk-KMM2X7LP.js → chunk-HHNNUPAB.js} +3 -3
  51. package/{chunk-JWTSWUPS.js → chunk-HSPGMGTN.js} +7 -6
  52. package/{chunk-UBUH2TCC.js → chunk-I2RMFLLH.js} +2 -2
  53. package/{chunk-VJXHL6MH.js → chunk-ICRRXBRN.js} +3 -3
  54. package/{chunk-XS47QOFV.js → chunk-IE5PXKVU.js} +2 -264
  55. package/{chunk-T5BHHWA5.js → chunk-IJVJUAHF.js} +7 -7
  56. package/{chunk-KFHQQ3NO.js → chunk-INFHX73M.js} +1 -1
  57. package/{chunk-XRUSXPCQ.js → chunk-IPAW7XLD.js} +57 -4
  58. package/{chunk-PLSVXHSA.js → chunk-IRTOYSA2.js} +3 -3
  59. package/{chunk-RQ6E3G5L.js → chunk-IUMO3L46.js} +18 -2
  60. package/{chunk-GCKHQECX.js → chunk-IYBIRCQV.js} +1 -1
  61. package/{chunk-ILU2NPWY.js → chunk-J2ATF74A.js} +2 -2
  62. package/{chunk-XZNCX52W.js → chunk-JGRPBIZZ.js} +1 -1
  63. package/{chunk-E2AKSW7L.js → chunk-JPJGMOIM.js} +2 -2
  64. package/{chunk-44WXLHFI.js → chunk-K43ZF2C3.js} +1 -1
  65. package/{chunk-I2ZMGXXF.js → chunk-KFHREHUQ.js} +1 -1
  66. package/{chunk-MZHOLWW5.js → chunk-KKQAAL57.js} +3 -3
  67. package/{chunk-JKMLSTZK.js → chunk-KLA62VVE.js} +3 -3
  68. package/{chunk-EHFS4XZO.js → chunk-KXFN2UYT.js} +12 -8
  69. package/{chunk-DYYMIUN4.js → chunk-L6EQV5OC.js} +4 -4
  70. package/{chunk-EZVK3N5L.js → chunk-LOEO7LRC.js} +56 -0
  71. package/{chunk-EDX5XSJM.js → chunk-M2P3OGXZ.js} +3 -3
  72. package/{chunk-LC23WBCU.js → chunk-M3KPY3TH.js} +6 -6
  73. package/{chunk-YVLQXTUB.js → chunk-MM3662RS.js} +1 -1
  74. package/{chunk-CBHGZRCE.js → chunk-MYOH447Z.js} +1 -1
  75. package/{chunk-A4MW3YZL.js → chunk-NDZOXXIM.js} +18 -4
  76. package/{chunk-I5V3V2H4.js → chunk-OAVSTXC7.js} +37 -25
  77. package/{chunk-36OMEXXR.js → chunk-OON4OBWI.js} +1 -1
  78. package/{chunk-VNP54NZL.js → chunk-P42RHYS3.js} +14 -14
  79. package/chunk-PLQYH5XK.js +2685 -0
  80. package/{chunk-SEJ5OS6F.js → chunk-PXYBUFDB.js} +4 -0
  81. package/{chunk-USHQX6VT.js → chunk-QPY264HO.js} +1 -1
  82. package/{chunk-XCA6HQGS.js → chunk-QQ72PAGR.js} +5 -5
  83. package/{chunk-TNIX77YM.js → chunk-R5GO3YZP.js} +34 -1
  84. package/{chunk-AIZE5TDM.js → chunk-SPKLALBU.js} +2 -2
  85. package/{chunk-PPU323UE.js → chunk-SRGKEBQ6.js} +184 -67
  86. package/{chunk-64PFYIAY.js → chunk-STAG2AHQ.js} +677 -640
  87. package/{chunk-K2AER7RX.js → chunk-SUKSWFLP.js} +2 -2
  88. package/{chunk-I4SN4NUQ.js → chunk-TRW43TSC.js} +1 -1
  89. package/{chunk-D2QN6CTI.js → chunk-UCLSOLX4.js} +8 -6
  90. package/{chunk-TYJ5XFEA.js → chunk-UFYBYB26.js} +1 -1
  91. package/{chunk-SCMHQUMK.js → chunk-US6MKPE7.js} +1 -1
  92. package/{chunk-ZIWPQEFU.js → chunk-VYNMQ6HW.js} +1 -28
  93. package/{chunk-IJERIUXS.js → chunk-WRCZXJ4N.js} +6 -3
  94. package/chunk-Y5GCAMGP.js +9 -0
  95. package/{chunk-XTWDF6RU.js → chunk-Y5NUMYMH.js} +21 -17
  96. package/{chunk-GKXCHNTE.js → chunk-Y6ORVLSS.js} +1 -1
  97. package/{chunk-RSHPU4PD.js → chunk-YANF2RR4.js} +2 -2
  98. package/{chunk-EYWJT7A2.js → chunk-YPG7TUQD.js} +3 -3
  99. package/{chunk-ZF6526IQ.js → chunk-ZEY4NJRE.js} +2 -2
  100. package/{chunk-74RAWNQN.js → chunk-ZVQHBIWV.js} +6 -6
  101. package/{chunk-DTODXBHK.js → chunk-ZWG3C7VI.js} +2 -2
  102. package/{commandRegistry-VBALU4Q4.js → commandRegistry-6MVZTG5Y.js} +79 -87
  103. package/{contentThunks-HPY2QNWZ.js → contentThunks-F7XJS5WV.js} +21 -21
  104. package/{createAgentAutomationAction-6ADGPGY6.js → createAgentAutomationAction-Z2AW4ZPK.js} +21 -21
  105. package/{createDialogAction-6ABMSEW2.js → createDialogAction-PWG7C7VG.js} +22 -22
  106. package/{createPageAction-OC4NNRPC.js → createPageAction-2L5Q2KOB.js} +22 -23
  107. package/{dbSlice-J37OGIXH.js → dbSlice-DC2J53RC.js} +7 -7
  108. package/{deleteFile-6JWDDRVP.js → deleteFile-KYWEMNFX.js} +4 -4
  109. package/{dialogCommands-EIGBRSQP.js → dialogCommands-MUFYPVMP.js} +24 -23
  110. package/{dialogSlice-SI45KJOH.js → dialogSlice-G5EIKHJA.js} +20 -20
  111. package/{docCreateCommands-3JDBBMU5.js → docCreateCommands-OPWOKG62.js} +19 -19
  112. package/{docDeleteCommands-5M6C7UUB.js → docDeleteCommands-IBV3WMKI.js} +20 -20
  113. package/{docReadCommands-DUB57F6V.js → docReadCommands-LVALHMLZ.js} +19 -19
  114. package/{docStore-L43MDEK4.js → docStore-CUFUJQGC.js} +8 -8
  115. package/{docUpdateCommands-WF7MAMPK.js → docUpdateCommands-Z5OUEAK7.js} +19 -19
  116. package/{getPricing-FKK3F5EJ.js → getPricing-TX35D7PI.js} +3 -3
  117. package/{handleSendMessageAction-BSMU7SVS.js → handleSendMessageAction-26HUY2ZV.js} +34 -34
  118. package/index.js +7 -7
  119. package/{localRuntimeAdapter-N5PDR26F.js → localRuntimeAdapter-SV22ZUP3.js} +59 -58
  120. package/{machineCommands-TMXJKZCE.js → machineCommands-2G5ESGDC.js} +63 -62
  121. package/{machineWsRunDispatch-25H63KEH.js → machineWsRunDispatch-NXKGHYPP.js} +58 -59
  122. package/{memberThunks-66DH6ABQ.js → memberThunks-2DWKLE6W.js} +8 -8
  123. package/{models-LAS4B2B5.js → models-PZQC7VV4.js} +2 -2
  124. package/package.json +4 -2
  125. package/{profileConfig-ZGOFORWV.js → profileConfig-KN3N2BLF.js} +7 -1
  126. package/{providerPresetApply-MY66I6NT.js → providerPresetApply-GSJI4JBJ.js} +6 -6
  127. package/{providerRegistry-QOE2FT57.js → providerRegistry-TSSTPGWF.js} +6 -6
  128. package/{read-DC4NUGN6.js → read-L7QEJETH.js} +5 -5
  129. package/{readDocTool-NCJ5NT25.js → readDocTool-QELXV2GW.js} +1 -1
  130. package/{readlineWorkspace-BS7WVCL2.js → readlineWorkspace-AYCWJVXF.js} +334 -123
  131. package/{removeDialogAgentAction-E2H3OZU6.js → removeDialogAgentAction-376XSUP2.js} +9 -9
  132. package/{runAgentClientLoop-BVKRI4SY.js → runAgentClientLoop-SJQUUBEC.js} +50 -47
  133. package/{runtimeDoctorCommands-GIOGC5SC.js → runtimeDoctorCommands-56NWKNON.js} +5 -5
  134. package/{secretCommands-ZXZRLR3R.js → secretCommands-DNY56NSU.js} +11 -1
  135. package/{setDialogExtraReferencesAction-SITRPMYU.js → setDialogExtraReferencesAction-QBDSH63D.js} +8 -8
  136. package/{setPrimaryDialogAgentAction-U7N45TGC.js → setPrimaryDialogAgentAction-537QFGW3.js} +9 -9
  137. package/settingThunks-4Z43ZSAT.js +923 -0
  138. package/{spaceCommands-5EWREUWS.js → spaceCommands-AWIIP7J5.js} +19 -19
  139. package/{streamAgentChatTurn-B4VFUV52.js → streamAgentChatTurn-OITCT4FF.js} +55 -106
  140. package/{switchDialogAgentAction-OMGBD3N2.js → switchDialogAgentAction-CSO6AKRL.js} +7 -7
  141. package/{tableCommands-U3QDY4L6.js → tableCommands-LBH3QPPO.js} +1 -1
  142. package/{toolApiClient-7WSJJJBV.js → toolApiClient-HGNO53TC.js} +2 -2
  143. package/{tools-5WYAUKMK.js → tools-KH4MMAFG.js} +39 -40
  144. package/{tuiSummaryLlmCaller-PPU7YDBG.js → tuiSummaryLlmCaller-KLK6K3Q3.js} +8 -8
  145. package/{updateCommands-NQXAGFM7.js → updateCommands-LXZLG44Y.js} +2 -2
  146. package/{updateDialogTitleAction-YJHDKHFX.js → updateDialogTitleAction-PDJUW7Z7.js} +22 -22
  147. package/{workloadLifecycle-36DXRZKU.js → workloadLifecycle-6O6PMISX.js} +2 -2
  148. package/chunk-IA7TRNNR.js +0 -11
  149. package/chunk-OFVFQYIE.js +0 -7012
  150. package/chunk-W4S6OTSC.js +0 -35
  151. package/clipboardy-GCO3GT3I.js +0 -11793
  152. package/settingThunks-Y7SVJOMZ.js +0 -1371
@@ -11,7 +11,7 @@ import {
11
11
  getAntigravityUserAgent,
12
12
  normalizeAntigravityTokenPayload,
13
13
  refreshAntigravityToken
14
- } from "./chunk-XZNCX52W.js";
14
+ } from "./chunk-JGRPBIZZ.js";
15
15
  import {
16
16
  asOptionalFiniteNumber
17
17
  } from "./chunk-WWC7I6TA.js";
@@ -27,7 +27,7 @@ import {
27
27
  import {
28
28
  buildEnvFromProfile,
29
29
  loadProfileConfig
30
- } from "./chunk-TNIX77YM.js";
30
+ } from "./chunk-R5GO3YZP.js";
31
31
  import {
32
32
  writeOAuthCredential
33
33
  } from "./chunk-ZWQUWF6W.js";
@@ -868,257 +868,6 @@ function resolveServerSyncConfig() {
868
868
  return null;
869
869
  }
870
870
 
871
- // packages/agent-runtime/workbuddyOAuth.ts
872
- var WORKBUDDY_APP_VERSION = "2.0.0";
873
- var WORKBUDDY_UA_VERSION = "5.5.6";
874
- var WORKBUDDY_POLL_INTERVAL_MS = 1e3;
875
- var WORKBUDDY_SIGN_IN_TIMEOUT_MS = 5 * 60 * 1e3;
876
- var WORKBUDDY_EARLY_REFRESH_SKEW_MS = 60 * 1e3;
877
- var WORKBUDDY_KEEP_RENEWED_MS = 60 * 1e3;
878
- var WORKBUDDY_REQUEST_TIMEOUT_MS = 3e4;
879
- var WORKBUDDY_SITES = {
880
- workbuddy: {
881
- id: "workbuddy",
882
- name: "WorkBuddy",
883
- endpoint: "https://copilot.tencent.com",
884
- authId: "workbuddy-desktop",
885
- platform: "workbuddy",
886
- ai: false
887
- },
888
- "workbuddy-ai": {
889
- id: "workbuddy-ai",
890
- name: "WorkBuddy AI",
891
- endpoint: "https://www.workbuddy.ai",
892
- authId: "workbuddy-desktop-ai",
893
- platform: "workbuddy-ai",
894
- ai: true
895
- }
896
- };
897
- function getWorkBuddySite(site) {
898
- if (site === "workbuddy" || site === "workbuddy-ai") {
899
- return WORKBUDDY_SITES[site];
900
- }
901
- throw new Error(`Unknown WorkBuddy site: "${String(site)}". Expected "workbuddy" or "workbuddy-ai".`);
902
- }
903
- function sanitizeWorkBuddyError(message) {
904
- return message.replace(/Bearer\s+[A-Za-z0-9._~+/-]+=*/gi, "Bearer [REDACTED]").replace(/([?&]|\b)(state|token|accessToken|refreshToken)=[^&\s]+/gi, "$1$2=[REDACTED]").replace(/(["']?(?:accessToken|refreshToken|state|token)["']?\s*:\s*["'])[^"']+["']/gi, '$1[REDACTED]"');
905
- }
906
- function sanitizeWorkBuddyDomain(rawDomain, defaultHost) {
907
- if (typeof rawDomain !== "string" || !rawDomain.trim()) {
908
- return defaultHost;
909
- }
910
- let domain = rawDomain.trim();
911
- if (domain.startsWith("https://") || domain.startsWith("http://")) {
912
- try {
913
- domain = new URL(domain).host;
914
- } catch {
915
- return defaultHost;
916
- }
917
- }
918
- const slashIdx = domain.indexOf("/");
919
- if (slashIdx !== -1) domain = domain.slice(0, slashIdx);
920
- const qIdx = domain.indexOf("?");
921
- if (qIdx !== -1) domain = domain.slice(0, qIdx);
922
- if (!/^[a-zA-Z0-9.-]+(?::[0-9]+)?$/.test(domain)) {
923
- return defaultHost;
924
- }
925
- return domain;
926
- }
927
- function normalizeWorkBuddyTokenPayload(siteOrArgs, payloadArg, baseCredentialArg, nowArg) {
928
- let site;
929
- let payload;
930
- let baseCredential;
931
- let now;
932
- if (typeof siteOrArgs === "object" && siteOrArgs !== null && "site" in siteOrArgs) {
933
- site = siteOrArgs.site;
934
- payload = siteOrArgs.payload ?? {};
935
- baseCredential = siteOrArgs.baseCredential;
936
- now = siteOrArgs.now ?? Date.now();
937
- } else {
938
- site = siteOrArgs;
939
- payload = payloadArg ?? {};
940
- baseCredential = baseCredentialArg;
941
- now = nowArg ?? Date.now();
942
- }
943
- const siteConfig = getWorkBuddySite(site);
944
- if (typeof payload.accessToken !== "string" || !payload.accessToken.trim()) {
945
- throw new Error("WorkBuddy token response missing accessToken");
946
- }
947
- const accessToken = payload.accessToken.trim();
948
- let expiresAt;
949
- const rawExpiresAt = Number(payload.expiresAt);
950
- const rawExpiresIn = Number(payload.expiresIn);
951
- if (Number.isFinite(rawExpiresAt) && rawExpiresAt > 0) {
952
- expiresAt = rawExpiresAt;
953
- } else if (Number.isFinite(rawExpiresIn) && rawExpiresIn > 0) {
954
- expiresAt = now + rawExpiresIn * 1e3;
955
- } else if (typeof baseCredential?.expiresAt === "number") {
956
- expiresAt = baseCredential.expiresAt;
957
- } else {
958
- expiresAt = now + 3600 * 1e3;
959
- }
960
- let refreshExpiresAt;
961
- const rawRefExpAt = Number(payload.refreshExpiresAt);
962
- const rawRefExpIn = Number(payload.refreshExpiresIn);
963
- if (Number.isFinite(rawRefExpAt) && rawRefExpAt > 0) {
964
- refreshExpiresAt = rawRefExpAt;
965
- } else if (Number.isFinite(rawRefExpIn) && rawRefExpIn > 0) {
966
- refreshExpiresAt = now + rawRefExpIn * 1e3;
967
- } else if (typeof baseCredential?.metadata?.refreshExpiresAt === "number") {
968
- refreshExpiresAt = baseCredential.metadata.refreshExpiresAt;
969
- }
970
- const refreshToken = typeof payload.refreshToken === "string" && payload.refreshToken.trim() ? payload.refreshToken.trim() : baseCredential?.refreshToken;
971
- const uid = typeof payload.uid === "string" && payload.uid.trim() ? payload.uid.trim() : typeof baseCredential?.metadata?.uid === "string" && baseCredential.metadata.uid.trim() ? baseCredential.metadata.uid.trim() : baseCredential?.accountId ?? "";
972
- const defaultHost = new URL(siteConfig.endpoint).host;
973
- const domain = sanitizeWorkBuddyDomain(
974
- payload.domain ?? baseCredential?.metadata?.domain,
975
- defaultHost
976
- );
977
- const rawEnterpriseId = typeof payload.enterpriseId === "string" ? payload.enterpriseId : typeof baseCredential?.metadata?.enterpriseId === "string" ? baseCredential.metadata.enterpriseId : "";
978
- const enterpriseId = rawEnterpriseId.trim();
979
- const nickname = typeof payload.nickname === "string" && payload.nickname.trim() ? payload.nickname.trim() : typeof payload.phoneNumber === "string" && payload.phoneNumber.trim() ? payload.phoneNumber.trim() : typeof baseCredential?.metadata?.nickname === "string" ? baseCredential.metadata.nickname : void 0;
980
- return {
981
- ...baseCredential ?? {},
982
- provider: site,
983
- accessToken,
984
- ...refreshToken ? { refreshToken } : {},
985
- expiresAt,
986
- obtainedAt: now,
987
- accountId: uid || nickname || siteConfig.name,
988
- metadata: {
989
- site,
990
- uid,
991
- domain,
992
- ...enterpriseId ? { enterpriseId } : {},
993
- ...refreshExpiresAt ? { refreshExpiresAt } : {},
994
- ...nickname ? { nickname } : {}
995
- }
996
- };
997
- }
998
- var renewing = /* @__PURE__ */ new Map();
999
- var renewed = /* @__PURE__ */ new Map();
1000
- function getWorkBuddyRefreshKey(site, credential) {
1001
- const accountOrUid = credential.accountId || credential.metadata?.uid || "";
1002
- const token = credential.refreshToken || "";
1003
- return `${site}
1004
- ${accountOrUid}
1005
- ${token}`;
1006
- }
1007
- async function refreshWorkBuddyToken(credential, deps = {}) {
1008
- if (!credential.refreshToken) {
1009
- throw new Error("WorkBuddy credential has no refresh_token");
1010
- }
1011
- const now = deps.now?.() ?? Date.now();
1012
- const refreshExpiresAt = credential.metadata?.refreshExpiresAt;
1013
- if (typeof refreshExpiresAt === "number" && now >= refreshExpiresAt) {
1014
- throw new Error("this WorkBuddy account is signed out; sign in again");
1015
- }
1016
- const site = credential.metadata?.site === "workbuddy-ai" || credential.provider === "workbuddy-ai" ? "workbuddy-ai" : "workbuddy";
1017
- const siteConfig = getWorkBuddySite(site);
1018
- const key = getWorkBuddyRefreshKey(site, credential);
1019
- const cached = renewed.get(key);
1020
- if (cached && now - cached.at < WORKBUDDY_KEEP_RENEWED_MS) {
1021
- return cached.credential;
1022
- }
1023
- const inflight = renewing.get(key);
1024
- if (inflight) {
1025
- return inflight;
1026
- }
1027
- const fetchImpl = deps.fetchImpl ?? fetch;
1028
- const refreshPromise = (async () => {
1029
- const defaultHost = new URL(siteConfig.endpoint).host;
1030
- const domain = sanitizeWorkBuddyDomain(credential.metadata?.domain, defaultHost);
1031
- const enterpriseId = typeof credential.metadata?.enterpriseId === "string" ? credential.metadata.enterpriseId.trim() : "";
1032
- const headers = {
1033
- "Content-Type": "application/json",
1034
- Accept: "application/json",
1035
- "User-Agent": `WorkBuddy/${WORKBUDDY_UA_VERSION}`,
1036
- "X-Refresh-Token": credential.refreshToken,
1037
- "X-Auth-Refresh-Source": "plugin",
1038
- "X-Domain": domain,
1039
- ...enterpriseId ? { "X-Enterprise-Id": enterpriseId, "X-Tenant-Id": enterpriseId } : {}
1040
- };
1041
- let response;
1042
- try {
1043
- response = await fetchImpl(`${siteConfig.endpoint}/v2/plugin/auth/token/refresh`, {
1044
- method: "POST",
1045
- headers,
1046
- body: "{}",
1047
- signal: AbortSignal.timeout(WORKBUDDY_REQUEST_TIMEOUT_MS)
1048
- });
1049
- } catch (error) {
1050
- throw new Error(sanitizeWorkBuddyError(`WorkBuddy token refresh failed: ${toErrorMessage(error)}`));
1051
- }
1052
- let text = "";
1053
- try {
1054
- text = await response.text();
1055
- } catch {
1056
- }
1057
- let env = {};
1058
- try {
1059
- env = JSON.parse(text);
1060
- } catch {
1061
- }
1062
- const code = typeof env.code === "number" ? env.code : Number.parseInt(String(env.code ?? ""), 10) || 0;
1063
- if (!response.ok) {
1064
- const why = String(env.msg || env.message || text.slice(0, 200) || response.statusText);
1065
- throw new Error(
1066
- sanitizeWorkBuddyError(
1067
- `${siteConfig.name} token refresh failed: ${why} (HTTP ${response.status}${code ? `, code ${code}` : ""})`
1068
- )
1069
- );
1070
- }
1071
- if (code !== 0) {
1072
- const why = String(env.msg || env.message || "error");
1073
- throw new Error(
1074
- sanitizeWorkBuddyError(`${siteConfig.name} token refresh failed: ${why} (${code})`)
1075
- );
1076
- }
1077
- const data = env.data && typeof env.data === "object" ? env.data : env;
1078
- if (typeof data.accessToken !== "string" || !data.accessToken.trim()) {
1079
- throw new Error("WorkBuddy gave no refreshed token");
1080
- }
1081
- const nextCredential = normalizeWorkBuddyTokenPayload(site, data, credential, now);
1082
- renewed.set(key, { credential: nextCredential, at: now });
1083
- return nextCredential;
1084
- })().finally(() => {
1085
- renewing.delete(key);
1086
- });
1087
- renewing.set(key, refreshPromise);
1088
- return refreshPromise;
1089
- }
1090
- var workbuddyRefresh = refreshWorkBuddyToken;
1091
- function getWorkBuddyHeaders(credential) {
1092
- const site = credential.metadata?.site === "workbuddy-ai" || credential.provider === "workbuddy-ai" ? "workbuddy-ai" : "workbuddy";
1093
- const siteConfig = getWorkBuddySite(site);
1094
- const defaultHost = new URL(siteConfig.endpoint).host;
1095
- const domain = sanitizeWorkBuddyDomain(credential.metadata?.domain, defaultHost);
1096
- const uid = typeof credential.metadata?.uid === "string" ? credential.metadata.uid.trim() : credential.accountId ?? "";
1097
- const rawEnterpriseId = typeof credential.metadata?.enterpriseId === "string" ? credential.metadata.enterpriseId.trim() : "";
1098
- const headers = {
1099
- Authorization: `Bearer ${credential.accessToken}`,
1100
- "X-User-Id": uid,
1101
- "X-Domain": domain,
1102
- "X-Product": "SaaS",
1103
- "X-IDE-Type": "WorkBuddy",
1104
- "User-Agent": `WorkBuddy/${WORKBUDDY_UA_VERSION}`,
1105
- "X-Requested-With": "XMLHttpRequest",
1106
- "X-Agent-Intent": "craft",
1107
- "X-Agent-Purpose": "conversation",
1108
- "X-IDE-Name": "WorkBuddy",
1109
- "X-IDE-Version": WORKBUDDY_UA_VERSION
1110
- };
1111
- if (rawEnterpriseId) {
1112
- const cleanEnterpriseId = rawEnterpriseId.replace(/[\r\n]/g, "");
1113
- headers["X-Enterprise-Id"] = cleanEnterpriseId;
1114
- headers["X-Tenant-Id"] = cleanEnterpriseId;
1115
- }
1116
- if (siteConfig.ai) {
1117
- headers["X-Agent-Type"] = "main";
1118
- }
1119
- return headers;
1120
- }
1121
-
1122
871
  // packages/agent-runtime/xaiOAuth.ts
1123
872
  var XAI_OAUTH_ISSUER = "https://auth.x.ai";
1124
873
  var XAI_OAUTH_DISCOVERY_URL = `${XAI_OAUTH_ISSUER}/.well-known/openid-configuration`;
@@ -1497,17 +1246,6 @@ async function refreshCursorToken(credential, deps = {}) {
1497
1246
  var cursorRefresh = refreshCursorToken;
1498
1247
 
1499
1248
  export {
1500
- WORKBUDDY_APP_VERSION,
1501
- WORKBUDDY_UA_VERSION,
1502
- WORKBUDDY_POLL_INTERVAL_MS,
1503
- WORKBUDDY_SIGN_IN_TIMEOUT_MS,
1504
- WORKBUDDY_REQUEST_TIMEOUT_MS,
1505
- getWorkBuddySite,
1506
- sanitizeWorkBuddyError,
1507
- sanitizeWorkBuddyDomain,
1508
- normalizeWorkBuddyTokenPayload,
1509
- workbuddyRefresh,
1510
- getWorkBuddyHeaders,
1511
1249
  startCallbackServer,
1512
1250
  runAntigravityOAuthLogin,
1513
1251
  refreshAntigravityOAuthToken,
@@ -2,7 +2,7 @@ import {
2
2
  clipMultilineText,
3
3
  fetchAndSerializeTable,
4
4
  waitForAbortableDelay
5
- } from "./chunk-EHFS4XZO.js";
5
+ } from "./chunk-KXFN2UYT.js";
6
6
  import {
7
7
  isGatewayHttpStatus
8
8
  } from "./chunk-NF64D32W.js";
@@ -11,31 +11,31 @@ import {
11
11
  isCoreDrainingBody,
12
12
  normalizeNonNegativeMs,
13
13
  parseRetryAfterHeaderMs
14
- } from "./chunk-XPWGOTBQ.js";
14
+ } from "./chunk-3L2WKC3W.js";
15
15
  import {
16
16
  resolvePageReadMarkdown,
17
17
  slateToSimplifiedMarkdown
18
- } from "./chunk-SCMHQUMK.js";
18
+ } from "./chunk-US6MKPE7.js";
19
19
  import {
20
20
  extractCategorizedMentions
21
21
  } from "./chunk-AGIM7IMJ.js";
22
22
  import {
23
23
  fetchAndCacheMessages
24
- } from "./chunk-PFBIXTFB.js";
24
+ } from "./chunk-6CTXMBXD.js";
25
25
  import {
26
26
  createSpaceKey
27
27
  } from "./chunk-UAD2WT54.js";
28
28
  import {
29
29
  read
30
- } from "./chunk-74RAWNQN.js";
30
+ } from "./chunk-ZVQHBIWV.js";
31
31
  import {
32
32
  getRuntimeServerContext
33
- } from "./chunk-4YRTZIVN.js";
33
+ } from "./chunk-2SGAI64X.js";
34
34
  import {
35
35
  extractRuntimePageCapabilities,
36
36
  resolveBuiltinSkillPage,
37
37
  resolveSkillGraphFromRoots
38
- } from "./chunk-HIQ4GF53.js";
38
+ } from "./chunk-DC3SZCRR.js";
39
39
  import {
40
40
  isAbortError
41
41
  } from "./chunk-7DPNBQSV.js";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  DEFAULT_AGENT_BASE_POLICY,
3
3
  DEFAULT_USER_PREFERENCE_PROFILE
4
- } from "./chunk-ZIWPQEFU.js";
4
+ } from "./chunk-VYNMQ6HW.js";
5
5
 
6
6
  // packages/ai/policy/runtimePolicy.ts
7
7
  var clampLevel = (value, fallback) => {
@@ -1,18 +1,21 @@
1
1
  import {
2
2
  getModelPricing
3
- } from "./chunk-RSHPU4PD.js";
3
+ } from "./chunk-YANF2RR4.js";
4
4
  import {
5
5
  PUBLIC_DEEPSEEK_V4_FLASH_AGENT_ID,
6
6
  PUBLIC_DEEPSEEK_V4_PRO_AGENT_ID,
7
7
  PUBLIC_GLM_53_FLASH_AGENT_ID,
8
+ PUBLIC_GPT_61_SOL_AGENT_ID,
9
+ PUBLIC_GPT_6_ASTRA_AGENT_ID,
8
10
  PUBLIC_GPT_IMAGE_2_CONTINUOUS_AGENT_ID,
9
11
  PUBLIC_GPT_IMAGE_2_EDITOR_AGENT_ID,
10
12
  PUBLIC_GPT_IMAGE_2_GENERATOR_AGENT_ID,
13
+ PUBLIC_KIMI_K3_AGENT_ID,
11
14
  PUBLIC_NANO_BANANA_2_LITE_AGENT_ID,
12
15
  builtinAgentCatalogEntryById,
13
16
  catalogReleasedAtMs,
14
17
  isRetiredCatalogEntry
15
- } from "./chunk-EZVK3N5L.js";
18
+ } from "./chunk-LOEO7LRC.js";
16
19
  import {
17
20
  parsePublicAgentId,
18
21
  parseSystemAgentId,
@@ -20,14 +23,14 @@ import {
20
23
  } from "./chunk-M2EJHDJP.js";
21
24
  import {
22
25
  getModelConfig
23
- } from "./chunk-I4SN4NUQ.js";
26
+ } from "./chunk-TRW43TSC.js";
24
27
  import {
25
28
  isRecord
26
29
  } from "./chunk-KUG52IAP.js";
27
30
  import {
28
31
  isNoloHostedProvider,
29
32
  isPlatformHostedImageModel
30
- } from "./chunk-CHCS6XPJ.js";
33
+ } from "./chunk-CGFNDIKK.js";
31
34
 
32
35
  // packages/core/publicAgentSeeds.ts
33
36
  var AGENT_SEED_DEFAULTS = {
@@ -230,6 +233,52 @@ var CLAUDE_SONNET_5_5_DEF = defineAgentSeed({
230
233
  tools: [],
231
234
  tags: ["anthropic", "claude", "sonnet"]
232
235
  });
236
+ var GPT_6_ASTRA_DEF = defineAgentSeed({
237
+ id: PUBLIC_GPT_6_ASTRA_AGENT_ID,
238
+ presetKey: "gpt-6-astra",
239
+ name: "GPT-6 Astra",
240
+ provider: "nolo",
241
+ model: "gpt-6-astra",
242
+ isPublic: true,
243
+ // 出自平台模型目录:gpt-6-astra hasVision: true、supportsTool: true。
244
+ hasVision: true,
245
+ introduction: "GPT-6 Astra \u516C\u5F00\u52A9\u624B\uFF0COpenAI \u91CD\u7B97\u529B\u65D7\u8230\u6863\uFF0C\u9002\u5408\u6700\u96BE\u7684\u63A8\u7406\u3001\u957F\u94FE\u8DEF\u5206\u6790\u3001\u4EE3\u7801\u653B\u5173\u548C\u56FE\u7247\u7406\u89E3\u3002\u5355\u4EF7\u9AD8\u4E8E\u5E38\u89C4\u6863\uFF0C\u9002\u5408\u771F\u6B63\u5361\u4F4F\u7684\u95EE\u9898\u3002\u9700\u5F00\u901A 199 \u79EF\u5206\u6863\u4F4D\u6216\u8D26\u6237\u4FDD\u6301\u6709\u6548\u4F59\u989D\uFF08\u2265 19 \u79EF\u5206\uFF09\u3002",
246
+ greeting: "\u4F60\u597D\uFF0C\u6211\u662F GPT-6 Astra\u3002\u9002\u5408\u6700\u96BE\u7684\u63A8\u7406\u3001\u590D\u6742\u4EE3\u7801\u548C\u591A\u6A21\u6001\u5206\u6790\uFF1B\u6211\u4F1A\u5148\u786E\u8BA4\u76EE\u6807\u4E0E\u7EA6\u675F\uFF0C\u518D\u7ED9\u7ED3\u8BBA\u548C\u4F9D\u636E\u3002\u9700\u5F00\u901A 199 \u79EF\u5206\u6863\u4F4D\u6216\u8D26\u6237\u4FDD\u6301\u6709\u6548\u4F59\u989D\uFF08\u2265 19 \u79EF\u5206\uFF09\u3002",
247
+ prompt: "\u5B9A\u4F4D\uFF1A\u91CD\u7B97\u529B\u65D7\u8230\u6863\uFF0C\u7528\u6765\u89E3\u51B3\u975E\u5E38\u89C4\u96BE\u5EA6\u7684\u4EFB\u52A1\u3002\n\u4F7F\u7528\u524D\u63D0\uFF1A\u9700\u5F00\u901A 199 \u79EF\u5206\u6863\u4F4D\u6216\u8D26\u6237\u4FDD\u6301\u6709\u6548\u4F59\u989D\uFF08\u2265 19 \u79EF\u5206\uFF09\u3002\n\u5DE5\u4F5C\u65B9\u5F0F\uFF1A\n- \u5148\u660E\u786E\u76EE\u6807\u3001\u7EA6\u675F\u548C\u5DF2\u77E5\u4E8B\u5B9E\uFF0C\u518D\u62C6\u89E3\u51FA\u53EF\u9A8C\u8BC1\u7684\u4E2D\u95F4\u7ED3\u8BBA\u3002\n- \u8BC1\u636E\u4E0D\u8DB3\u65F6\u8BF4\u660E\u7F3A\u4EC0\u4E48\u3001\u600E\u6837\u8865\u9F50\uFF0C\u4E0D\u7F16\u9020\u4E8B\u5B9E\u6216 API\u3002\n- \u6D89\u53CA\u4EE3\u7801\u65F6\u7ED9\u51FA\u6539\u52A8\u70B9\u3001\u8FB9\u754C\u6761\u4EF6\u548C\u9A8C\u8BC1\u65B9\u5F0F\u3002\n\u56DE\u590D\u65B9\u5F0F\uFF1A\u7ED3\u8BBA\u5148\u884C\uFF0C\u5173\u952E\u63A8\u65AD\u9644\u4F9D\u636E\uFF1B\u98CE\u9669\u4E0E\u4E0D\u786E\u5B9A\u9879\u5355\u72EC\u6807\u6CE8\u3002",
248
+ tools: [],
249
+ tags: ["openai", "gpt", "astra"]
250
+ });
251
+ var GPT_61_SOL_DEF = defineAgentSeed({
252
+ id: PUBLIC_GPT_61_SOL_AGENT_ID,
253
+ presetKey: "gpt-6-1-sol",
254
+ name: "GPT-6.1 Sol",
255
+ provider: "nolo",
256
+ model: "gpt-6.1-sol",
257
+ isPublic: true,
258
+ // 出自平台模型目录:gpt-6.1-sol 显式 hasVision: false(官方页无图像输入声明),
259
+ // 且未声明 supportsTool —— 不要在这里把它写成会看图/能动手的模型。
260
+ hasVision: false,
261
+ introduction: "GPT-6.1 Sol \u516C\u5F00\u52A9\u624B\uFF0C\u5F3A\u63A8\u7406\u5FEB\u6863\uFF0C\u9002\u5408\u590D\u6742\u5206\u6790\u3001\u4EE3\u7801\u4E0E\u957F\u6587\u6863\u4EFB\u52A1\u3002\u9700\u5F00\u901A 199 \u79EF\u5206\u6863\u4F4D\u6216\u8D26\u6237\u4FDD\u6301\u6709\u6548\u4F59\u989D\uFF08\u2265 19 \u79EF\u5206\uFF09\u3002",
262
+ greeting: "\u4F60\u597D\uFF0C\u6211\u662F GPT-6.1 Sol\u3002\u9002\u5408\u590D\u6742\u63A8\u7406\u3001\u4EE3\u7801\u5206\u6790\u548C\u957F\u6587\u6863\u5904\u7406\uFF1B\u4F7F\u7528\u524D\u8BF7\u786E\u4FDD\u8D26\u6237\u5F00\u901A\u9AD8\u9636\u6863\u4F4D\u6216\u6709\u5145\u8DB3\u53EF\u7528\u4F59\u989D\u3002",
263
+ prompt: "\u5148\u786E\u8BA4\u7528\u6237\u8981\u89E3\u51B3\u7684\u5177\u4F53\u95EE\u9898\u4E0E\u7EA6\u675F\uFF0C\u518D\u7ED9\u51FA\u53EF\u9760\u3001\u53EF\u6267\u884C\u7684\u7ED3\u679C\u3002\n\u6D89\u53CA\u4EE3\u7801\u65F6\u8BF4\u660E\u6539\u52A8\u70B9\u3001\u8FB9\u754C\u6761\u4EF6\u4E0E\u9A8C\u8BC1\u65B9\u5F0F\uFF1B\u6D89\u53CA\u957F\u6587\u6863\u65F6\u5148\u5B9A\u4F4D\u5173\u952E\u6BB5\u843D\u518D\u4E0B\u7ED3\u8BBA\u3002\n\u4E0D\u786E\u5B9A\u7684\u5185\u5BB9\u660E\u786E\u8BF4\u660E\uFF0C\u4E0D\u7F16\u9020\u3002",
264
+ tools: [],
265
+ tags: ["openai", "gpt", "sol"]
266
+ });
267
+ var KIMI_K3_DEF = defineAgentSeed({
268
+ id: PUBLIC_KIMI_K3_AGENT_ID,
269
+ presetKey: "kimi-k3",
270
+ name: "Kimi K3",
271
+ provider: "nolo",
272
+ model: "kimi-k3",
273
+ isPublic: true,
274
+ // 出自平台模型目录:kimi-k3 hasVision: true、supportsTool: true、1M 上下文。
275
+ hasVision: true,
276
+ introduction: "Kimi K3 \u516C\u5F00\u52A9\u624B\uFF0C\u8D85\u957F\u4E0A\u4E0B\u6587\u5F3A\u63A8\u7406\u6863\uFF0C\u9002\u5408\u6574\u4EFD\u6587\u6863/\u4EE3\u7801\u5E93\u5206\u6790\u3001\u591A\u6B65\u4EFB\u52A1\u548C\u56FE\u7247\u7406\u89E3\u3002\u9700\u5F00\u901A 199 \u79EF\u5206\u6863\u4F4D\u6216\u8D26\u6237\u4FDD\u6301\u6709\u6548\u4F59\u989D\uFF08\u2265 19 \u79EF\u5206\uFF09\u3002",
277
+ greeting: "\u4F60\u597D\uFF0C\u6211\u662F Kimi K3\u3002\u9002\u5408\u8D85\u957F\u6587\u6863\u3001\u4EE3\u7801\u5E93\u5206\u6790\u548C\u591A\u6B65\u63A8\u7406\uFF1B\u4F7F\u7528\u524D\u8BF7\u786E\u4FDD\u8D26\u6237\u5F00\u901A\u9AD8\u9636\u6863\u4F4D\u6216\u6709\u5145\u8DB3\u53EF\u7528\u4F59\u989D\u3002",
278
+ prompt: "\u5B9A\u4F4D\uFF1A\u8D85\u957F\u4E0A\u4E0B\u6587\u5F3A\u63A8\u7406\u6863\u3002\n\u5DE5\u4F5C\u65B9\u5F0F\uFF1A\u5148\u5728\u6D77\u91CF\u6750\u6599\u91CC\u5B9A\u4F4D\u4E0E\u95EE\u9898\u76F8\u5173\u7684\u90E8\u5206\uFF0C\u518D\u9010\u6B65\u6536\u7A84\u7ED3\u8BBA\uFF1B\u5F15\u7528\u6750\u6599\u65F6\u8BF4\u660E\u51FA\u81EA\u54EA\u4E00\u6BB5\uFF0C\u4E0D\u81C6\u6D4B\u672A\u8BFB\u5230\u7684\u5185\u5BB9\u3002\n\u6D89\u53CA\u4EE3\u7801\u65F6\u7ED9\u51FA\u6539\u52A8\u70B9\u4E0E\u9A8C\u8BC1\u65B9\u5F0F\u3002\n\u56DE\u590D\u65B9\u5F0F\uFF1A\u7ED3\u8BBA\u5148\u884C\uFF0C\u5FC5\u8981\u65F6\u5206\u5C42\u7ED9\u8981\u70B9\u3002",
279
+ tools: [],
280
+ tags: ["moonshot", "kimi", "long-context"]
281
+ });
233
282
  var GROK_4_6_DEF = defineAgentSeed({
234
283
  id: deterministicId("01GROK46PLAZ", "shared-space-xai-grok-4-6"),
235
284
  presetKey: "grok-4.6",
@@ -411,6 +460,10 @@ var PUBLIC_AGENT_DEFS = [
411
460
  CLAUDE_FABLE_5_1_DEF,
412
461
  CLAUDE_OPUS_5_5_DEF,
413
462
  CLAUDE_SONNET_5_5_DEF,
463
+ // 顾问档(求助模式升级目标,2026-10-20)
464
+ GPT_6_ASTRA_DEF,
465
+ GPT_61_SOL_DEF,
466
+ KIMI_K3_DEF,
414
467
  GROK_4_6_DEF,
415
468
  GEMINI_3_8_FLASH_DEF,
416
469
  GEMINI_4_ARGON_DEF,
@@ -1,15 +1,15 @@
1
1
  import {
2
2
  selectCurrentServer
3
- } from "./chunk-QFEW2ULV.js";
3
+ } from "./chunk-32ZKZET7.js";
4
4
  import {
5
5
  patch
6
- } from "./chunk-74RAWNQN.js";
6
+ } from "./chunk-ZVQHBIWV.js";
7
7
  import {
8
8
  getIsDesktopApp
9
9
  } from "./chunk-6Q7UTJKR.js";
10
10
  import {
11
11
  selectIdentityToken
12
- } from "./chunk-SEJ5OS6F.js";
12
+ } from "./chunk-PXYBUFDB.js";
13
13
 
14
14
  // packages/ai/agent/cliChatClient.ts
15
15
  function getCliChatRequestConfig(thunkApi) {
@@ -5,7 +5,7 @@ import {
5
5
  } from "./chunk-NBTY7YJF.js";
6
6
  import {
7
7
  resolveCliLocalRuntimeKeyCapability
8
- } from "./chunk-PPU323UE.js";
8
+ } from "./chunk-SRGKEBQ6.js";
9
9
  import {
10
10
  HIGH_RISK_MUTATION_TOOL_NAMES
11
11
  } from "./chunk-QLQ573SU.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,7 +1,7 @@
1
1
  import {
2
2
  findModelConfig,
3
3
  getProviderByModelName
4
- } from "./chunk-I4SN4NUQ.js";
4
+ } from "./chunk-TRW43TSC.js";
5
5
  import {
6
6
  asOptionalTrimmedString
7
7
  } from "./chunk-G3SUCT4W.js";
@@ -7,7 +7,7 @@ import {
7
7
  } from "./chunk-UAD2WT54.js";
8
8
  import {
9
9
  toTimestampMs
10
- } from "./chunk-74RAWNQN.js";
10
+ } from "./chunk-ZVQHBIWV.js";
11
11
  import {
12
12
  fetchFromServer,
13
13
  getAllServers
@@ -15,7 +15,7 @@ import {
15
15
  import {
16
16
  selectIdentityToken,
17
17
  selectIdentityUserId
18
- } from "./chunk-SEJ5OS6F.js";
18
+ } from "./chunk-PXYBUFDB.js";
19
19
  import {
20
20
  isTombstoneRecord
21
21
  } from "./chunk-D2MDMY2M.js";
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-WWC7I6TA.js";
4
4
  import {
5
5
  trimTrailingSlash
6
- } from "./chunk-K2AER7RX.js";
6
+ } from "./chunk-SUKSWFLP.js";
7
7
  import {
8
8
  toErrorMessage
9
9
  } from "./chunk-HNMXYYJR.js";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  requireTokenUser
3
- } from "./chunk-ISQL4V7C.js";
3
+ } from "./chunk-C3OK72G3.js";
4
4
  import {
5
5
  t
6
- } from "./chunk-SW4S4XYB.js";
6
+ } from "./chunk-2AB2HA4M.js";
7
7
  import {
8
8
  resolveServerUrl
9
9
  } from "./chunk-A7GB5UGH.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  resolvePlatformAuthToken
3
- } from "./chunk-K2AER7RX.js";
3
+ } from "./chunk-SUKSWFLP.js";
4
4
  import {
5
5
  getCredentialsDir
6
6
  } from "./chunk-ZWQUWF6W.js";
@@ -3,7 +3,7 @@ import {
3
3
  isCoreDrainingBody,
4
4
  normalizeNonNegativeMs,
5
5
  parseRetryAfterHeaderMs
6
- } from "./chunk-XPWGOTBQ.js";
6
+ } from "./chunk-3L2WKC3W.js";
7
7
  import {
8
8
  toErrorMessage
9
9
  } from "./chunk-HNMXYYJR.js";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  toolRegistry
3
- } from "./chunk-PPU323UE.js";
3
+ } from "./chunk-SRGKEBQ6.js";
4
4
  import {
5
5
  runtime_default
6
- } from "./chunk-PFBIXTFB.js";
6
+ } from "./chunk-6CTXMBXD.js";
7
7
  import {
8
8
  canonicalizeToolNames
9
9
  } from "./chunk-5EBLANFT.js";
@@ -12,7 +12,7 @@ import {
12
12
  } from "./chunk-KUG52IAP.js";
13
13
  import {
14
14
  isNoloHostedProvider
15
- } from "./chunk-CHCS6XPJ.js";
15
+ } from "./chunk-CGFNDIKK.js";
16
16
  import {
17
17
  asTrimmedLowercaseString
18
18
  } from "./chunk-QSJ3HFEF.js";
@@ -18,13 +18,13 @@ import {
18
18
  import {
19
19
  isSubscriptionEndpoint,
20
20
  isSubscriptionOAuthCredential
21
- } from "./chunk-TYYRSFBG.js";
21
+ } from "./chunk-HB4XPBC7.js";
22
22
  import {
23
23
  isAntigravityOAuthAgent
24
- } from "./chunk-XZNCX52W.js";
24
+ } from "./chunk-JGRPBIZZ.js";
25
25
  import {
26
26
  getModelAbility
27
- } from "./chunk-RVWMAFIT.js";
27
+ } from "./chunk-FYYSDHVQ.js";
28
28
 
29
29
  // packages/ai/agent/agentBilling.ts
30
30
  function resolveBillingSource(candidate) {