nolo-cli 0.31.0-alpha.9 → 0.32.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.
Files changed (62) hide show
  1. package/{_executeModel-6FRIQJJC.js → _executeModel-LTMSIBS4.js} +14 -14
  2. package/{agentDeleteCommand-MD3266WY.js → agentDeleteCommand-D3MYZK6E.js} +11 -11
  3. package/{agentEmailCommands-P4Z57QRY.js → agentEmailCommands-6BXS574I.js} +16 -16
  4. package/{agentListCommands-S4J6EYVS.js → agentListCommands-SF3HEUTT.js} +13 -13
  5. package/{agentMachineCommands-IMWA26SD.js → agentMachineCommands-YARVXRR6.js} +11 -11
  6. package/{agentRecordCommands-KEA6IXKP.js → agentRecordCommands-JFZRQJQ4.js} +16 -16
  7. package/{agentRunCommand-JECNTAJA.js → agentRunCommand-NOX5FLKO.js} +16 -16
  8. package/{agentRuntimeLocal-HKJKTCW4.js → agentRuntimeLocal-ATGJY6WC.js} +8 -8
  9. package/{agentSlice-7ELXNOJA.js → agentSlice-4XWW344Y.js} +1 -1
  10. package/{appDeleteCommands-EZRWLQSL.js → appDeleteCommands-63JO7RXS.js} +12 -12
  11. package/{appDeployCommands-G3JQ5UXL.js → appDeployCommands-Y7EWYUGM.js} +12 -12
  12. package/{appDeployStatusCommands-ZADWE6HA.js → appDeployStatusCommands-ZBEY3DWB.js} +12 -12
  13. package/{appGetCommands-G6YN7F2Z.js → appGetCommands-QSSOSEYL.js} +12 -12
  14. package/{appListCommands-E3TGPLEB.js → appListCommands-PH3XWNDX.js} +12 -12
  15. package/{chunk-GPKB5TIJ.js → chunk-2HXKAPH7.js} +2 -2
  16. package/{chunk-PKB24CKO.js → chunk-2ZRP5RUG.js} +4 -4
  17. package/{chunk-2UFKPJJI.js → chunk-3FCNXC2J.js} +2 -2
  18. package/{chunk-OYACR5WZ.js → chunk-3GZT3L6F.js} +8 -8
  19. package/{chunk-7I44EILD.js → chunk-3UGKATZQ.js} +2 -2
  20. package/{chunk-ILQALSPF.js → chunk-4PNU7W7K.js} +7 -7
  21. package/{chunk-WCZ6NCQN.js → chunk-AYMOSAHE.js} +8 -10
  22. package/{chunk-THJJUY7I.js → chunk-D2BPX6DQ.js} +3 -3
  23. package/{chunk-2UX66SH3.js → chunk-DLWCWUNW.js} +3 -3
  24. package/{chunk-JNU5ISIG.js → chunk-EEF23OOK.js} +2 -2
  25. package/{chunk-CNTHYPHP.js → chunk-GAF5X6B7.js} +96 -144
  26. package/{chunk-5LZTGR74.js → chunk-MITD7CON.js} +9 -9
  27. package/{chunk-ZW6KKTYZ.js → chunk-O3JR45Q2.js} +8 -8
  28. package/{chunk-RZN2YWPC.js → chunk-O5OMJPPF.js} +3 -3
  29. package/{chunk-AROB24VV.js → chunk-ODS2MVMU.js} +3 -3
  30. package/{chunk-ZLMXXZVX.js → chunk-OWHNFZNW.js} +1 -1
  31. package/{chunk-Q6U2SGFX.js → chunk-Q76I4SXI.js} +1 -1
  32. package/{chunk-VQREJRUO.js → chunk-RH53LMEJ.js} +2 -2
  33. package/{chunk-OFGTZ35R.js → chunk-RXVX5LFR.js} +1 -1
  34. package/{chunk-3K55GMMW.js → chunk-TA6EA2A3.js} +2 -2
  35. package/{chunk-Z6V33HCT.js → chunk-TEYN42N3.js} +1 -1
  36. package/{chunk-NXLUGU6X.js → chunk-UOJRKY5J.js} +2 -2
  37. package/{chunk-7RP2PSIN.js → chunk-V42OE5HT.js} +1 -1
  38. package/{chunk-AWKR4MMR.js → chunk-VVEH6XUE.js} +1 -1
  39. package/{chunk-TVBDE6LJ.js → chunk-W367V5CH.js} +5 -5
  40. package/{chunk-NBWOCRU3.js → chunk-XDHHF73Q.js} +1 -1
  41. package/{createAgentAutomationAction-ZLJRVATF.js → createAgentAutomationAction-WLRNE7C4.js} +3 -3
  42. package/{createDialogAction-CFYGC6NF.js → createDialogAction-Y6YV64QB.js} +4 -4
  43. package/{createPageAction-Y2H5GYJU.js → createPageAction-7YROVZ3W.js} +3 -3
  44. package/{dialogCommands-4DYAWH6L.js → dialogCommands-XLO5CAHZ.js} +12 -12
  45. package/{dialogSlice-23SPNP3O.js → dialogSlice-N4HPG6HM.js} +2 -2
  46. package/{docCreateCommands-OXEKIA6S.js → docCreateCommands-GRA5BHSA.js} +11 -11
  47. package/{docDeleteCommands-P3PR6NS7.js → docDeleteCommands-ONIJM5MD.js} +12 -12
  48. package/{docReadCommands-MS2WXJIA.js → docReadCommands-H55VQ2US.js} +11 -11
  49. package/{docStore-2DWKYPQO.js → docStore-B5AHDNW5.js} +4 -4
  50. package/{docUpdateCommands-N54A2KBE.js → docUpdateCommands-ZQIQVGC2.js} +11 -11
  51. package/{handleSendMessageAction-RL25MK5X.js → handleSendMessageAction-IN5XX5U7.js} +2 -2
  52. package/index.js +40 -40
  53. package/{machineCommands-DVMG4LQ2.js → machineCommands-H3UMKE76.js} +15 -15
  54. package/{machineWsRunDispatch-5R4FV3HQ.js → machineWsRunDispatch-HONRUK3R.js} +15 -15
  55. package/package.json +1 -1
  56. package/{readlineWorkspace-3BJXQE3S.js → readlineWorkspace-XVJZDCSC.js} +19 -19
  57. package/{runAgentClientLoop-GNDHLSYM.js → runAgentClientLoop-H7U53QB6.js} +11 -11
  58. package/{spaceCommands-BXG3LHG4.js → spaceCommands-7VVKJBDV.js} +11 -11
  59. package/{spaceSlice-4JKOTPHQ.js → spaceSlice-T6YK6D34.js} +3 -3
  60. package/{streamAgentChatTurn-VJ4JB3MV.js → streamAgentChatTurn-RQ63QFQ7.js} +13 -13
  61. package/{tools-ISIPHXWB.js → tools-KYZX3BGO.js} +8 -8
  62. package/{updateDialogTitleAction-HRSMYRLK.js → updateDialogTitleAction-BBDSWHNG.js} +3 -3
@@ -27,7 +27,7 @@ import {
27
27
  } from "./chunk-Q3CSL43H.js";
28
28
  import {
29
29
  buildLocalAgentLookupKeys
30
- } from "./chunk-AWKR4MMR.js";
30
+ } from "./chunk-VVEH6XUE.js";
31
31
  import {
32
32
  LOCAL_CODEX_AGENT_ID,
33
33
  LOCAL_CODEX_AGENT_KEY,
@@ -54,7 +54,7 @@ import {
54
54
  readOpenAiCompatibleSseCompletion,
55
55
  resolveAgentNextAvailableAt,
56
56
  resolveOpenAiCompatibleProviderConfig
57
- } from "./chunk-2UX66SH3.js";
57
+ } from "./chunk-DLWCWUNW.js";
58
58
  import {
59
59
  buildPlatformChatCompletionRequest,
60
60
  canUsePlatformChatProvider,
@@ -74,12 +74,12 @@ import {
74
74
  import {
75
75
  inlineImageUrlsForCustomProvider,
76
76
  prepareTools
77
- } from "./chunk-NBWOCRU3.js";
77
+ } from "./chunk-XDHHF73Q.js";
78
78
  import {
79
79
  inferCaptureIntent,
80
80
  resolveHistoricalToolContentCap,
81
81
  summarizeToolArguments
82
- } from "./chunk-WCZ6NCQN.js";
82
+ } from "./chunk-AYMOSAHE.js";
83
83
  import {
84
84
  getAntigravityUserAgent,
85
85
  isAntigravityOAuthAgent,
@@ -104,7 +104,7 @@ import {
104
104
  readXhsProfileFunctionSchema,
105
105
  rememberMemoryFunctionSchema,
106
106
  setTodoListFunc
107
- } from "./chunk-5LZTGR74.js";
107
+ } from "./chunk-MITD7CON.js";
108
108
  import {
109
109
  createDrainExhaustedResponse,
110
110
  isCoreDrainingBody,
@@ -128,13 +128,13 @@ import {
128
128
  parseNoloWorkspaceToolArguments,
129
129
  resolveAgentRequiredPackIds,
130
130
  resolveRuntimeToolSurfaceForAgent
131
- } from "./chunk-THJJUY7I.js";
131
+ } from "./chunk-D2BPX6DQ.js";
132
132
  import {
133
133
  applyTokenUsageToDayStats,
134
134
  prepareTokenUsageData,
135
135
  resolveBuiltinPlatformAgentConfig,
136
136
  runKeyed
137
- } from "./chunk-OYACR5WZ.js";
137
+ } from "./chunk-3GZT3L6F.js";
138
138
  import {
139
139
  BUILTIN_TITLE_LLM_CONFIG,
140
140
  clipCompactText
@@ -145,7 +145,7 @@ import {
145
145
  resolveCurrentRunRuntimeToolPolicy,
146
146
  resolveLocalWorkspaceExecutorOptionsFromPolicy,
147
147
  resolveRequestedRuntimeToolNames
148
- } from "./chunk-AROB24VV.js";
148
+ } from "./chunk-ODS2MVMU.js";
149
149
  import {
150
150
  createOAuthTokenStore,
151
151
  isTokenExpired,
@@ -10622,62 +10622,8 @@ function isRemoteAuthEndpoint(endpoint) {
10622
10622
  return false;
10623
10623
  }
10624
10624
 
10625
- // packages/core/concurrencyLimiter.ts
10626
- function createConcurrencyLimiter(maxConcurrent) {
10627
- if (!Number.isInteger(maxConcurrent) || maxConcurrent < 1) {
10628
- throw new RangeError("maxConcurrent must be a positive integer");
10629
- }
10630
- let active = 0;
10631
- const pending = [];
10632
- function drain() {
10633
- while (active < maxConcurrent && pending.length > 0) {
10634
- const entry = pending.shift();
10635
- active += 1;
10636
- Promise.resolve().then(() => entry.task()).then(
10637
- (value) => entry.resolve(value),
10638
- (error) => entry.reject(error)
10639
- ).finally(() => {
10640
- active -= 1;
10641
- drain();
10642
- });
10643
- }
10644
- }
10645
- return {
10646
- run(task) {
10647
- return new Promise((resolve, reject) => {
10648
- pending.push({ task, resolve, reject });
10649
- drain();
10650
- });
10651
- },
10652
- get activeCount() {
10653
- return active;
10654
- },
10655
- get pendingCount() {
10656
- return pending.length;
10657
- }
10658
- };
10659
- }
10660
-
10661
10625
  // packages/cli/client/localRuntimeDialog.ts
10662
10626
  var import_date_fns = __toESM(require_date_fns(), 1);
10663
- var MAX_TITLE_PATCH_CONCURRENT = 2;
10664
- var MAX_REMOTE_SYNC_CONCURRENT = 3;
10665
- var titlePatchLimiter = createConcurrencyLimiter(MAX_TITLE_PATCH_CONCURRENT);
10666
- var remoteSyncLimiter = createConcurrencyLimiter(MAX_REMOTE_SYNC_CONCURRENT);
10667
- function createPerfTracker(env) {
10668
- const enabled = env?.NOLO_CLI_PERF === "1";
10669
- const t0 = enabled ? performance.now() : 0;
10670
- return {
10671
- enabled,
10672
- mark(label, since) {
10673
- if (!enabled) return;
10674
- const ms = (performance.now() - (since ?? t0)).toFixed(1);
10675
- process.stderr.write(`[nolo-perf] writeDialog ${label}: ${ms}ms
10676
- `);
10677
- },
10678
- t0
10679
- };
10680
- }
10681
10627
  async function resolveStore(deps) {
10682
10628
  if (deps.store) return deps.store;
10683
10629
  return createCliHybridRecordStore({
@@ -10742,66 +10688,6 @@ function createLocalDialogTitleGenerator(deps, ctx) {
10742
10688
  return result.source === "llm" ? result.title : null;
10743
10689
  };
10744
10690
  }
10745
- function patchDialogTitleInBackground(args) {
10746
- return args.titlePromise.then(async (resolvedTitle) => {
10747
- if (!resolvedTitle) return;
10748
- const limiter = args.limiter ?? titlePatchLimiter;
10749
- await limiter.run(async () => {
10750
- try {
10751
- const existing = await args.store.read(args.dialogKey);
10752
- if (!existing || typeof existing !== "object") return;
10753
- if (existing?.titleSource === "manual") return;
10754
- const existingTitleUpdatedAtMs = parseTitleUpdatedAtMs(existing);
10755
- if (existingTitleUpdatedAtMs > args.nowMs) return;
10756
- await args.store.write(args.dialogKey, {
10757
- ...existing,
10758
- title: resolvedTitle,
10759
- titleSource: "auto",
10760
- titleUpdatedAt: new Date(args.nowMs).toISOString()
10761
- });
10762
- } catch {
10763
- }
10764
- });
10765
- });
10766
- }
10767
- function syncDialogEvidence(args) {
10768
- const syncArgs = {
10769
- env: args.env,
10770
- fetchImpl: args.fetchImpl,
10771
- input: args.input,
10772
- ops: args.ops,
10773
- output: args.output,
10774
- userId: args.userId
10775
- };
10776
- if (args.hasSubjectRefs) {
10777
- return (async () => {
10778
- const syncResult = await syncLocalDialogEvidenceToRemote(syncArgs);
10779
- if (!syncResult.attempted) {
10780
- args.output?.write(
10781
- "[nolo] Local dialog evidence is local-only; set NOLO_SERVER and AUTH_TOKEN to make subjectRefs remotely queryable.\n"
10782
- );
10783
- }
10784
- })();
10785
- }
10786
- const limiter = args.limiter ?? remoteSyncLimiter;
10787
- return limiter.run(() => syncLocalDialogEvidenceToRemote(syncArgs)).catch((error) => {
10788
- args.output?.write(
10789
- `[nolo] Remote dialog evidence sync failed; local dialog only: ${toErrorMessage(error)}
10790
- `
10791
- );
10792
- });
10793
- }
10794
- function shouldRegenerateTitle(existingDialog, nowMs) {
10795
- const existingTitle = typeof existingDialog?.title === "string" ? existingDialog.title.trim() : "";
10796
- const existingTitleSource = existingDialog?.titleSource;
10797
- if (existingTitleSource === "manual") return false;
10798
- if (!existingTitle) return true;
10799
- const titleUpdatedAtMs = parseTitleUpdatedAtMs(existingDialog);
10800
- if (titleUpdatedAtMs > 0) {
10801
- return nowMs - titleUpdatedAtMs >= 30 * 60 * 1e3;
10802
- }
10803
- return false;
10804
- }
10805
10691
  async function writeLocalTokenRecord(args) {
10806
10692
  const usageRecords = args.input.usageRecords?.length ? args.input.usageRecords : args.input.result.usage ? [{
10807
10693
  callId: typeof args.input.result.usage?.provider_call_id === "string" && args.input.result.usage.provider_call_id.trim() ? args.input.result.usage.provider_call_id.trim() : args.createId(),
@@ -10870,15 +10756,36 @@ async function writeLocalTokenRecord(args) {
10870
10756
  return ops;
10871
10757
  }
10872
10758
  async function writeDialog(args) {
10873
- const perf = createPerfTracker(args.env);
10759
+ const __perfEnabled = args.env?.NOLO_CLI_PERF === "1";
10760
+ const __perfT0 = __perfEnabled ? performance.now() : 0;
10874
10761
  let existingDialog = null;
10875
10762
  if (args.input.continueDialogId) {
10876
10763
  const dialogKey = `dialog-${args.userId}-${args.input.continueDialogId}`;
10877
- existingDialog = await args.store.read(dialogKey, { remote: false });
10764
+ existingDialog = await args.store.read(dialogKey);
10765
+ }
10766
+ if (__perfEnabled) {
10767
+ const ms = (performance.now() - __perfT0).toFixed(1);
10768
+ process.stderr.write(`[nolo-perf] writeDialog A:read-dialog: ${ms}ms
10769
+ `);
10878
10770
  }
10879
- perf.mark("A:read-dialog");
10880
10771
  const nowMs = args.now();
10881
- const needsTitleUpdate = shouldRegenerateTitle(existingDialog, nowMs);
10772
+ const existingTitle = typeof existingDialog?.title === "string" ? existingDialog.title.trim() : "";
10773
+ const existingTitleSource = existingDialog?.titleSource;
10774
+ let needsTitleUpdate = false;
10775
+ if (existingTitleSource === "manual") {
10776
+ needsTitleUpdate = false;
10777
+ } else if (!existingTitle) {
10778
+ needsTitleUpdate = true;
10779
+ } else {
10780
+ const titleUpdatedAtMs = parseTitleUpdatedAtMs(existingDialog);
10781
+ if (titleUpdatedAtMs > 0) {
10782
+ if (nowMs - titleUpdatedAtMs >= 30 * 60 * 1e3) {
10783
+ needsTitleUpdate = true;
10784
+ }
10785
+ } else {
10786
+ needsTitleUpdate = false;
10787
+ }
10788
+ }
10882
10789
  let titlePromise;
10883
10790
  if (needsTitleUpdate && args.titleGenerator) {
10884
10791
  const rawLastUserText = extractLastUserText(args.input.messages);
@@ -10894,7 +10801,11 @@ async function writeDialog(args) {
10894
10801
  cwd: args.cwd
10895
10802
  });
10896
10803
  await args.store.batch(plan.ops);
10897
- perf.mark("C:store-batch (cumulative)");
10804
+ if (__perfEnabled) {
10805
+ const ms = (performance.now() - __perfT0).toFixed(1);
10806
+ process.stderr.write(`[nolo-perf] writeDialog C:store-batch (cumulative): ${ms}ms
10807
+ `);
10808
+ }
10898
10809
  let tokenOps = [];
10899
10810
  try {
10900
10811
  tokenOps = await writeLocalTokenRecord({
@@ -10912,33 +10823,74 @@ async function writeDialog(args) {
10912
10823
  `
10913
10824
  );
10914
10825
  }
10915
- perf.mark("D:token-record (cumulative)");
10826
+ if (__perfEnabled) {
10827
+ const ms = (performance.now() - __perfT0).toFixed(1);
10828
+ process.stderr.write(`[nolo-perf] writeDialog D:token-record (cumulative): ${ms}ms
10829
+ `);
10830
+ }
10916
10831
  const hasSubjectRefs = localTurnHasSubjectRefs(args.input);
10917
10832
  const isLocalUser = args.userId === "local";
10918
10833
  let remoteSyncPromise;
10919
10834
  if (!isLocalUser) {
10920
- remoteSyncPromise = syncDialogEvidence({
10921
- env: args.env,
10922
- fetchImpl: args.fetchImpl,
10923
- input: args.input,
10924
- ops: [...plan.ops, ...tokenOps],
10925
- output: args.output,
10926
- userId: args.userId,
10927
- hasSubjectRefs
10928
- });
10929
- if (hasSubjectRefs) await remoteSyncPromise;
10835
+ if (hasSubjectRefs) {
10836
+ remoteSyncPromise = (async () => {
10837
+ const syncResult = await syncLocalDialogEvidenceToRemote({
10838
+ env: args.env,
10839
+ fetchImpl: args.fetchImpl,
10840
+ input: args.input,
10841
+ ops: [...plan.ops, ...tokenOps],
10842
+ output: args.output,
10843
+ userId: args.userId
10844
+ });
10845
+ if (!syncResult.attempted) {
10846
+ args.output?.write(
10847
+ "[nolo] Local dialog evidence is local-only; set NOLO_SERVER and AUTH_TOKEN to make subjectRefs remotely queryable.\n"
10848
+ );
10849
+ }
10850
+ })();
10851
+ await remoteSyncPromise;
10852
+ } else {
10853
+ remoteSyncPromise = syncLocalDialogEvidenceToRemote({
10854
+ env: args.env,
10855
+ fetchImpl: args.fetchImpl,
10856
+ input: args.input,
10857
+ ops: [...plan.ops, ...tokenOps],
10858
+ output: args.output,
10859
+ userId: args.userId
10860
+ }).catch((error) => {
10861
+ args.output?.write(
10862
+ `[nolo] Remote dialog evidence sync failed; local dialog only: ${toErrorMessage(error)}
10863
+ `
10864
+ );
10865
+ });
10866
+ }
10930
10867
  }
10931
10868
  let titlePatchPromise;
10932
10869
  if (titlePromise) {
10933
10870
  const dialogKey = `dialog-${args.userId}-${plan.dialogId}`;
10934
- titlePatchPromise = patchDialogTitleInBackground({
10935
- store: args.store,
10936
- dialogKey,
10937
- titlePromise,
10938
- nowMs
10871
+ titlePatchPromise = titlePromise.then(async (resolvedTitle) => {
10872
+ if (!resolvedTitle) return;
10873
+ try {
10874
+ const existing = await args.store.read(dialogKey);
10875
+ if (!existing || typeof existing !== "object") return;
10876
+ if (existing?.titleSource === "manual") return;
10877
+ const existingTitleUpdatedAtMs = parseTitleUpdatedAtMs(existing);
10878
+ if (existingTitleUpdatedAtMs > nowMs) return;
10879
+ await args.store.write(dialogKey, {
10880
+ ...existing,
10881
+ title: resolvedTitle,
10882
+ titleSource: "auto",
10883
+ titleUpdatedAt: new Date(nowMs).toISOString()
10884
+ });
10885
+ } catch {
10886
+ }
10939
10887
  });
10940
10888
  }
10941
- perf.mark("total (blocking)");
10889
+ if (__perfEnabled) {
10890
+ const ms = (performance.now() - __perfT0).toFixed(1);
10891
+ process.stderr.write(`[nolo-perf] writeDialog total (blocking): ${ms}ms
10892
+ `);
10893
+ }
10942
10894
  return { dialogId: plan.dialogId, title: plan.title, titlePatchPromise, remoteSyncPromise };
10943
10895
  }
10944
10896
  function resolveCliDialogRecordKey(userId, dialogId) {
@@ -17,7 +17,7 @@ import {
17
17
  import {
18
18
  sortSafeAgentSummaries,
19
19
  toSafeAgentSummary
20
- } from "./chunk-Z6V33HCT.js";
20
+ } from "./chunk-TEYN42N3.js";
21
21
  import {
22
22
  getUserDataItemTimestamp,
23
23
  mergeAndDedupUserData
@@ -43,10 +43,10 @@ import {
43
43
  resolveNoloDialogInput,
44
44
  toolRunUpdated,
45
45
  verifyNoloDialogSubjectRefQuery
46
- } from "./chunk-THJJUY7I.js";
46
+ } from "./chunk-D2BPX6DQ.js";
47
47
  import {
48
48
  createDocState
49
- } from "./chunk-JNU5ISIG.js";
49
+ } from "./chunk-EEF23OOK.js";
50
50
  import {
51
51
  setDialogExtraReferencesAction
52
52
  } from "./chunk-43EPBPZ2.js";
@@ -69,7 +69,7 @@ import {
69
69
  } from "./chunk-44HACRCK.js";
70
70
  import {
71
71
  createDialogAction
72
- } from "./chunk-3K55GMMW.js";
72
+ } from "./chunk-TA6EA2A3.js";
73
73
  import {
74
74
  markdownToSlate
75
75
  } from "./chunk-3LY4F7SV.js";
@@ -89,7 +89,7 @@ import {
89
89
  selectCurrentSpaceId,
90
90
  updateContentCategory,
91
91
  updateContentTitle
92
- } from "./chunk-2UFKPJJI.js";
92
+ } from "./chunk-3FCNXC2J.js";
93
93
  import {
94
94
  incrementFailedSteps,
95
95
  incrementStepsExecuted,
@@ -103,7 +103,7 @@ import {
103
103
  uiAskChoiceFunc,
104
104
  uiAskChoiceFunctionSchema,
105
105
  updateStep
106
- } from "./chunk-OYACR5WZ.js";
106
+ } from "./chunk-3GZT3L6F.js";
107
107
  import {
108
108
  buildDatabaseFileContentUrl
109
109
  } from "./chunk-BGTUGS3T.js";
@@ -112,7 +112,7 @@ import {
112
112
  runLlm,
113
113
  streamAgentChatTurn,
114
114
  updateAgent
115
- } from "./chunk-AROB24VV.js";
115
+ } from "./chunk-ODS2MVMU.js";
116
116
  import {
117
117
  toErrorMessage
118
118
  } from "./chunk-HNMXYYJR.js";
@@ -13929,7 +13929,7 @@ async function deleteDialogsFunc(args, thunkApi) {
13929
13929
  const deletedDialogIds = [];
13930
13930
  const deletedDialogKeys = [];
13931
13931
  const failures = [];
13932
- const { deleteDialog } = await import("./dialogSlice-23SPNP3O.js");
13932
+ const { deleteDialog } = await import("./dialogSlice-N4HPG6HM.js");
13933
13933
  for (const target of targets) {
13934
13934
  try {
13935
13935
  await thunkApi.dispatch(deleteDialog(target.dbKey)).unwrap();
@@ -25684,7 +25684,7 @@ async function updateDocFunc(args, thunkApi) {
25684
25684
  updated_at: (/* @__PURE__ */ new Date()).toISOString()
25685
25685
  };
25686
25686
  await dispatch(write({ data: updatedPageData, customKey: id })).unwrap();
25687
- const { getDocState, applyExternalDocUpdate } = await import("./docStore-2DWKYPQO.js");
25687
+ const { getDocState, applyExternalDocUpdate } = await import("./docStore-B5AHDNW5.js");
25688
25688
  if (getDocState().pageKey === id) {
25689
25689
  applyExternalDocUpdate({
25690
25690
  slateData: finalSlateData,
@@ -5,10 +5,10 @@ import {
5
5
  inlineImageUrlsForCustomProvider,
6
6
  prepareTools,
7
7
  shouldInlineImageUrlsForAgent
8
- } from "./chunk-NBWOCRU3.js";
8
+ } from "./chunk-XDHHF73Q.js";
9
9
  import {
10
10
  EMPTY_ASSISTANT_REPAIR_PROMPT
11
- } from "./chunk-WCZ6NCQN.js";
11
+ } from "./chunk-AYMOSAHE.js";
12
12
  import {
13
13
  accumulateToolCallDelta,
14
14
  createThinkParserState,
@@ -20,12 +20,12 @@ import {
20
20
  } from "./chunk-N7J63Q6C.js";
21
21
  import {
22
22
  performFetchRequest
23
- } from "./chunk-TVBDE6LJ.js";
23
+ } from "./chunk-W367V5CH.js";
24
24
  import {
25
25
  createSSEParser,
26
26
  findToolExecutor,
27
27
  toolDefinitionsByName
28
- } from "./chunk-5LZTGR74.js";
28
+ } from "./chunk-MITD7CON.js";
29
29
  import {
30
30
  createToolRunId,
31
31
  getToolResultErrorData,
@@ -33,23 +33,23 @@ import {
33
33
  toolRunSetPending,
34
34
  toolRunStarted,
35
35
  toolRunSucceeded
36
- } from "./chunk-THJJUY7I.js";
36
+ } from "./chunk-D2BPX6DQ.js";
37
37
  import {
38
38
  getPublicImageAgentMode
39
39
  } from "./chunk-E3APEOIM.js";
40
40
  import {
41
41
  selectCurrentSpaceId
42
- } from "./chunk-2UFKPJJI.js";
42
+ } from "./chunk-3FCNXC2J.js";
43
43
  import {
44
44
  addToolMessage,
45
45
  getModelInfo,
46
46
  messageStreamEnd,
47
47
  messageStreaming,
48
48
  updateToolMessage
49
- } from "./chunk-OYACR5WZ.js";
49
+ } from "./chunk-3GZT3L6F.js";
50
50
  import {
51
51
  streamAgentChatTurn
52
- } from "./chunk-AROB24VV.js";
52
+ } from "./chunk-ODS2MVMU.js";
53
53
  import {
54
54
  toErrorMessage
55
55
  } from "./chunk-HNMXYYJR.js";
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  listUserRecordsFromServers,
3
3
  readLiveDbRecordAfterTombstoneMerge
4
- } from "./chunk-Q6U2SGFX.js";
4
+ } from "./chunk-Q76I4SXI.js";
5
5
  import {
6
6
  agentRecordHasConfiguredCredential
7
- } from "./chunk-7RP2PSIN.js";
7
+ } from "./chunk-V42OE5HT.js";
8
8
  import {
9
9
  toSafeAgentSummary
10
- } from "./chunk-Z6V33HCT.js";
10
+ } from "./chunk-TEYN42N3.js";
11
11
  import {
12
12
  PUBLIC_AGENT_KEY_PREFIX,
13
13
  isOwnedAgentKey,
@@ -583,7 +583,7 @@ var slice = createSliceWithThunks({
583
583
  const overrides = {};
584
584
  if (args.systemPromptOverride !== void 0) overrides.prompt = args.systemPromptOverride;
585
585
  if (args.toolsOverride !== void 0) overrides.tools = args.toolsOverride;
586
- const { _executeModel } = await import("./_executeModel-6FRIQJJC.js");
586
+ const { _executeModel } = await import("./_executeModel-LTMSIBS4.js");
587
587
  return _executeModel(
588
588
  {
589
589
  isStreaming: args.isStreaming ?? false,
@@ -604,7 +604,7 @@ var slice = createSliceWithThunks({
604
604
  * - 循环直到无工具调用或触发其他运行时停止条件
605
605
  */
606
606
  runAgent: create.asyncThunk(async (args, thunkApi) => {
607
- const { runAgentClientLoop } = await import("./runAgentClientLoop-GNDHLSYM.js");
607
+ const { runAgentClientLoop } = await import("./runAgentClientLoop-H7U53QB6.js");
608
608
  const { content: loopContent, toolCallCount } = await runAgentClientLoop(
609
609
  {
610
610
  agentKey: args.agentKey,
@@ -620,7 +620,7 @@ var slice = createSliceWithThunks({
620
620
  * 聊天轮次流式 Agent 调用
621
621
  */
622
622
  streamAgentChatTurn: create.asyncThunk(async (args, thunkApi) => {
623
- const { streamAgentChatTurnHandler } = await import("./streamAgentChatTurn-VJ4JB3MV.js");
623
+ const { streamAgentChatTurnHandler } = await import("./streamAgentChatTurn-RQ63QFQ7.js");
624
624
  return streamAgentChatTurnHandler(args, thunkApi);
625
625
  }),
626
626
  /**
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  readDbRecord,
3
3
  writeAgentRecord
4
- } from "./chunk-7RP2PSIN.js";
4
+ } from "./chunk-V42OE5HT.js";
5
5
  import {
6
6
  createSpaceKey
7
7
  } from "./chunk-V54H24CQ.js";
@@ -2,7 +2,7 @@ import {
2
2
  deleteDbRecord,
3
3
  queryUserRecords,
4
4
  readDbRecord
5
- } from "./chunk-7RP2PSIN.js";
5
+ } from "./chunk-V42OE5HT.js";
6
6
  import {
7
7
  mergeAndDedupUserData
8
8
  } from "./chunk-KQHGZWSV.js";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  resolveReferenceAssets
3
- } from "./chunk-TVBDE6LJ.js";
3
+ } from "./chunk-W367V5CH.js";
4
4
  import {
5
5
  fetchReferenceContents
6
- } from "./chunk-7I44EILD.js";
6
+ } from "./chunk-3UGKATZQ.js";
7
7
 
8
8
  // packages/ai/agent/fetchAgentContexts.ts
9
9
  async function fetchAgentContexts(references, dispatch) {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  requireTokenUser
3
- } from "./chunk-ZLMXXZVX.js";
3
+ } from "./chunk-OWHNFZNW.js";
4
4
  import {
5
5
  resolveServerUrl
6
6
  } from "./chunk-A7GB5UGH.js";
@@ -3,12 +3,12 @@ import {
3
3
  } from "./chunk-DCDL3GC4.js";
4
4
  import {
5
5
  addContentToSpace
6
- } from "./chunk-2UFKPJJI.js";
6
+ } from "./chunk-3FCNXC2J.js";
7
7
  import {
8
8
  prepareAndPersistMessage,
9
9
  uiAskChoiceFunc,
10
10
  uiAskChoiceFunctionSchema
11
- } from "./chunk-OYACR5WZ.js";
11
+ } from "./chunk-3GZT3L6F.js";
12
12
  import {
13
13
  require_date_fns
14
14
  } from "./chunk-M76ECQRD.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  isOAuthApiKeyRef
3
- } from "./chunk-OYACR5WZ.js";
3
+ } from "./chunk-3GZT3L6F.js";
4
4
  import {
5
5
  getModelAbility
6
6
  } from "./chunk-WTGCTVJG.js";
@@ -7,11 +7,11 @@ import {
7
7
  listUserRecordsFromServers,
8
8
  readDbRecordFromServers,
9
9
  readLiveDbRecordAfterTombstoneMerge
10
- } from "./chunk-Q6U2SGFX.js";
10
+ } from "./chunk-Q76I4SXI.js";
11
11
  import {
12
12
  buildDialogAttachmentPlan,
13
13
  extractFileContentIds
14
- } from "./chunk-OYACR5WZ.js";
14
+ } from "./chunk-3GZT3L6F.js";
15
15
  import {
16
16
  toErrorMessage
17
17
  } from "./chunk-HNMXYYJR.js";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  buildLocalAgentLookupKeys,
3
3
  shouldReadAgentKeyRemotely
4
- } from "./chunk-AWKR4MMR.js";
4
+ } from "./chunk-VVEH6XUE.js";
5
5
  import {
6
6
  resolveCliAgentKeyInput
7
7
  } from "./chunk-K6QEHQZ3.js";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  buildAgentRuntimeAgentLookupKeys,
3
3
  shouldFetchAgentRuntimeRecordRemotely
4
- } from "./chunk-THJJUY7I.js";
4
+ } from "./chunk-D2BPX6DQ.js";
5
5
 
6
6
  // packages/cli/client/localAgentRecords.ts
7
7
  var buildLocalAgentLookupKeys = buildAgentRuntimeAgentLookupKeys;
@@ -9,7 +9,7 @@ import {
9
9
  requiresBareImageUrl,
10
10
  resolveToolGuidedSections,
11
11
  toBareImageUrlMessages
12
- } from "./chunk-7I44EILD.js";
12
+ } from "./chunk-3UGKATZQ.js";
13
13
  import {
14
14
  convertMessagesToResponsesInput,
15
15
  preserveAgentStateFields
@@ -26,7 +26,7 @@ import {
26
26
  } from "./chunk-XFG3BAKN.js";
27
27
  import {
28
28
  waitForAbortableDelay
29
- } from "./chunk-5LZTGR74.js";
29
+ } from "./chunk-MITD7CON.js";
30
30
  import {
31
31
  createDrainExhaustedResponse,
32
32
  isCoreDrainingBody,
@@ -36,17 +36,17 @@ import {
36
36
  } from "./chunk-Z5MXSEOJ.js";
37
37
  import {
38
38
  resolveBuiltinSkillPage
39
- } from "./chunk-THJJUY7I.js";
39
+ } from "./chunk-D2BPX6DQ.js";
40
40
  import {
41
41
  shouldUseServerProxy
42
- } from "./chunk-OYACR5WZ.js";
42
+ } from "./chunk-3GZT3L6F.js";
43
43
  import {
44
44
  estimateTokenCount
45
45
  } from "./chunk-BGTUGS3T.js";
46
46
  import {
47
47
  createFileCredentialBroker,
48
48
  fetchServerSyncedCredential
49
- } from "./chunk-AROB24VV.js";
49
+ } from "./chunk-ODS2MVMU.js";
50
50
  import {
51
51
  toErrorMessage
52
52
  } from "./chunk-HNMXYYJR.js";
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  i18n_default,
3
3
  toolRegistry
4
- } from "./chunk-5LZTGR74.js";
4
+ } from "./chunk-MITD7CON.js";
5
5
  import {
6
6
  isNoloHostedProvider
7
7
  } from "./chunk-CAENRKNJ.js";
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  addContentToSpace
3
- } from "./chunk-2UFKPJJI.js";
4
- import "./chunk-OYACR5WZ.js";
3
+ } from "./chunk-3FCNXC2J.js";
4
+ import "./chunk-3GZT3L6F.js";
5
5
  import "./chunk-BGTUGS3T.js";
6
6
  import "./chunk-ATK5WJOA.js";
7
- import "./chunk-AROB24VV.js";
7
+ import "./chunk-ODS2MVMU.js";
8
8
  import "./chunk-JZPBVBIY.js";
9
9
  import "./chunk-5RGU3J7P.js";
10
10
  import "./chunk-M76ECQRD.js";