nolo-cli 0.243.0-alpha.2 → 0.243.0-alpha.4

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 (72) hide show
  1. package/{_executeModel-OO3WNJZJ.js → _executeModel-EKTVBHP5.js} +25 -25
  2. package/{action-4V2UISXC.js → action-R2EIXR7I.js} +3 -3
  3. package/{addContentAction-5MZDMGI6.js → addContentAction-W6JVLQ6H.js} +6 -6
  4. package/{addDialogAgentAction-ONVFHUOL.js → addDialogAgentAction-LVNKMXKZ.js} +5 -5
  5. package/{agentDeleteCommand-XLYICAHH.js → agentDeleteCommand-PLATQ4WQ.js} +22 -22
  6. package/{agentEmailCommands-Q4LFOXQC.js → agentEmailCommands-3ZLROASQ.js} +23 -23
  7. package/{agentMachineCommands-7QQM6RU6.js → agentMachineCommands-DW2HS6KZ.js} +1 -1
  8. package/{agentRecordCommands-FXP672SS.js → agentRecordCommands-NAYFUYXR.js} +23 -23
  9. package/{agentRunCommand-FGEYVKIG.js → agentRunCommand-DFNC6HMT.js} +23 -23
  10. package/{agentSlice-R6BN2FOL.js → agentSlice-UTV4ZFTX.js} +6 -6
  11. package/{chunk-YO4DCVD2.js → chunk-2IPR4PBB.js} +1 -1
  12. package/{chunk-GKZHJD7O.js → chunk-2QXYFYLP.js} +2 -2
  13. package/{chunk-U3PDJ6EI.js → chunk-5BVGJKIA.js} +10 -10
  14. package/{chunk-DEOPZE4S.js → chunk-5VVP7DW3.js} +1 -1
  15. package/{chunk-G3SJCNHX.js → chunk-76HAJUOJ.js} +1 -1
  16. package/{chunk-TRN54YTP.js → chunk-AVSZ6PBM.js} +2 -2
  17. package/{chunk-ONXCCILE.js → chunk-AZUPMHRN.js} +19 -19
  18. package/{chunk-OPZBKP4X.js → chunk-BW6QATP2.js} +5 -5
  19. package/{chunk-GKZGOSZE.js → chunk-C2QLXFUP.js} +8 -8
  20. package/{chunk-SGI2FIGK.js → chunk-CJQBWHNM.js} +2 -2
  21. package/{chunk-ZGHHY2PV.js → chunk-FMYNIAI6.js} +1 -1
  22. package/{chunk-TCY22W2Y.js → chunk-HJHZVSTB.js} +3 -3
  23. package/{chunk-SSTQPNS5.js → chunk-I2NBEUPD.js} +8 -8
  24. package/{chunk-SEDJEJBH.js → chunk-IFWXH7LH.js} +1 -1
  25. package/{chunk-QE6U2BKG.js → chunk-IMDKBSUH.js} +2 -2
  26. package/{chunk-WIRH2ZLI.js → chunk-KMDHRVS7.js} +20 -1
  27. package/{chunk-3IQ5GP5Y.js → chunk-LC5CVWP2.js} +2 -2
  28. package/{chunk-7DVJO4J5.js → chunk-LPGHK4JN.js} +7 -7
  29. package/{chunk-AUBXID4I.js → chunk-MKOAAPH7.js} +5 -5
  30. package/{chunk-VTB6V4UF.js → chunk-PDAXMBLW.js} +6 -6
  31. package/{chunk-T3CUXNV4.js → chunk-QOURTDZL.js} +84 -5
  32. package/{chunk-WXZZQRAH.js → chunk-RXTZB2DH.js} +1 -1
  33. package/{chunk-YDTLGWBU.js → chunk-SESKIWB4.js} +1 -1
  34. package/{chunk-G3Y56RZA.js → chunk-TVUBURX7.js} +3 -3
  35. package/{chunk-FUG2L353.js → chunk-UDHBVOLK.js} +2 -2
  36. package/{chunk-7AI3MC6I.js → chunk-UL4PV44O.js} +1 -1
  37. package/{chunk-37NO3AYF.js → chunk-VSZWCZM6.js} +2 -2
  38. package/{chunk-AGQ6WAB2.js → chunk-W3FHUZEK.js} +6 -6
  39. package/{chunk-GRVQJNSR.js → chunk-XZKFM7KO.js} +22 -22
  40. package/{chunk-LCPP65AH.js → chunk-ZGEFT7GW.js} +4 -4
  41. package/{chunk-BRZFJQTW.js → chunk-ZJ5HDNS2.js} +5 -5
  42. package/{commandRegistry-GBAVYSJE.js → commandRegistry-FHMIUCZO.js} +15 -15
  43. package/{contentThunks-IRJERA32.js → contentThunks-3SB44C7X.js} +12 -12
  44. package/{createAgentAutomationAction-EKJMTIUX.js → createAgentAutomationAction-5HZTYLFU.js} +12 -12
  45. package/{createDialogAction-SI5EKEF6.js → createDialogAction-BEWLUGTZ.js} +13 -13
  46. package/{createPageAction-OAQ2Z73C.js → createPageAction-YQJNM7WK.js} +13 -13
  47. package/{dbSlice-JBLCCYKC.js → dbSlice-5MQ3ELID.js} +5 -5
  48. package/{deleteFile-KV5VTKAT.js → deleteFile-VCCHS72Y.js} +3 -3
  49. package/{dialogSlice-PRXHSZKA.js → dialogSlice-35ZHIKXV.js} +10 -10
  50. package/{docStore-ISD6RJ4Q.js → docStore-YAQ2NUEU.js} +6 -6
  51. package/{handleSendMessageAction-53ZRMHZI.js → handleSendMessageAction-TGD2MREV.js} +20 -20
  52. package/{hostCredentialCreate-CE7VH3QY.js → hostCredentialCreate-JOEH42E2.js} +23 -23
  53. package/index.js +3 -3
  54. package/{localRuntimeAdapter-HFSSPXSN.js → localRuntimeAdapter-LGCTOJKO.js} +22 -22
  55. package/{machineCommands-RD3VAUXS.js → machineCommands-UKDQ54ZP.js} +23 -23
  56. package/{machineWsRunDispatch-4F57JVF5.js → machineWsRunDispatch-VYB4BESM.js} +23 -23
  57. package/{memberThunks-TWB77UHJ.js → memberThunks-KC3WJGL3.js} +7 -7
  58. package/package.json +1 -1
  59. package/{projectArchive-NSWHU25G.js → projectArchive-KAR4AVYU.js} +13 -13
  60. package/{read-CO6HMH5W.js → read-T7VU2IMO.js} +3 -3
  61. package/{readDocTool-P4MDVRNW.js → readDocTool-BPQ3QJSD.js} +1 -1
  62. package/{readlineWorkspace-5DBAVNUP.js → readlineWorkspace-NO3Z5SRR.js} +26 -26
  63. package/{removeDialogAgentAction-D3R3QNPD.js → removeDialogAgentAction-FEUUVMYC.js} +7 -7
  64. package/{runAgentClientLoop-RJ7KEUWO.js → runAgentClientLoop-RKQUAOW5.js} +23 -23
  65. package/{setDialogExtraReferencesAction-VORDLM57.js → setDialogExtraReferencesAction-JSTQJPXL.js} +6 -6
  66. package/{setPrimaryDialogAgentAction-P5A65M32.js → setPrimaryDialogAgentAction-Z2BQE3IY.js} +7 -7
  67. package/{settingThunks-JGBSDOC6.js → settingThunks-C2YWCNYI.js} +5 -5
  68. package/{streamAgentChatTurn-FRPZ7DE2.js → streamAgentChatTurn-EY7XVVDV.js} +25 -25
  69. package/{switchDialogAgentAction-DMMWH5FG.js → switchDialogAgentAction-G7XVAOGH.js} +5 -5
  70. package/{tools-7JMKOJPW.js → tools-5MVR3NQI.js} +20 -20
  71. package/{updateDialogTitleAction-BQH24I5O.js → updateDialogTitleAction-4PLYOEJM.js} +12 -12
  72. package/{webapi-24RZDIIQ.js → webapi-QVV65DQF.js} +12 -13
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  patch
3
- } from "./chunk-VTB6V4UF.js";
3
+ } from "./chunk-PDAXMBLW.js";
4
4
  import {
5
5
  selectCurrentServer
6
- } from "./chunk-G3SJCNHX.js";
6
+ } from "./chunk-76HAJUOJ.js";
7
7
  import {
8
8
  getIsDesktopApp
9
9
  } from "./chunk-5PASH2MB.js";
@@ -10,10 +10,10 @@ import {
10
10
  } from "./chunk-523DITKR.js";
11
11
  import {
12
12
  runLlm
13
- } from "./chunk-AGQ6WAB2.js";
13
+ } from "./chunk-W3FHUZEK.js";
14
14
  import {
15
15
  cleanupCliSessionForDialog
16
- } from "./chunk-TRN54YTP.js";
16
+ } from "./chunk-AVSZ6PBM.js";
17
17
  import {
18
18
  getActiveDialogAgentId,
19
19
  getDialogAgentIds,
@@ -21,7 +21,7 @@ import {
21
21
  } from "./chunk-5RGU3J7P.js";
22
22
  import {
23
23
  addContentAction
24
- } from "./chunk-SGI2FIGK.js";
24
+ } from "./chunk-CJQBWHNM.js";
25
25
  import {
26
26
  patch,
27
27
  read,
@@ -29,7 +29,7 @@ import {
29
29
  selectById,
30
30
  upload,
31
31
  write
32
- } from "./chunk-VTB6V4UF.js";
32
+ } from "./chunk-PDAXMBLW.js";
33
33
  import {
34
34
  fetchMessages
35
35
  } from "./chunk-HXER7YJF.js";
@@ -66,14 +66,14 @@ import {
66
66
  resolveUserAuthorityServer,
67
67
  scheduleDeleteReplication,
68
68
  waitForWriteAck
69
- } from "./chunk-ZGHHY2PV.js";
69
+ } from "./chunk-FMYNIAI6.js";
70
70
  import {
71
71
  asyncThunkCreator,
72
72
  buildCreateSlice,
73
73
  createAsyncThunk,
74
74
  createEntityAdapter,
75
75
  createSelector
76
- } from "./chunk-T3CUXNV4.js";
76
+ } from "./chunk-QOURTDZL.js";
77
77
  import {
78
78
  googleSessionRequestToken,
79
79
  isGoogleAuthoritySession,
@@ -14669,7 +14669,7 @@ var messageSlice = createSliceWithThunks({
14669
14669
  runtimeOptions: args.runtimeOptions
14670
14670
  });
14671
14671
  if (agentKeyToUse) {
14672
- const { streamAgentChatTurn } = await import("./agentSlice-R6BN2FOL.js");
14672
+ const { streamAgentChatTurn } = await import("./agentSlice-UTV4ZFTX.js");
14673
14673
  await dispatch(
14674
14674
  streamAgentChatTurn({
14675
14675
  agentKey: agentKeyToUse,
@@ -15740,7 +15740,7 @@ var deleteOwnedDialogAttachments = async (args) => {
15740
15740
  metadataReadFailures
15741
15741
  });
15742
15742
  if (!plan.deleteCandidates.length) return plan;
15743
- const { deleteFileAction } = await import("./deleteFile-KV5VTKAT.js");
15743
+ const { deleteFileAction } = await import("./deleteFile-VCCHS72Y.js");
15744
15744
  for (const candidate of plan.deleteCandidates) {
15745
15745
  if (candidate.fileDbKey) {
15746
15746
  await deleteFileAction(candidate.fileDbKey, args.thunkApi);
@@ -15802,7 +15802,7 @@ var deleteDialogThunk = async (payload, thunkApi) => {
15802
15802
  }
15803
15803
  if (isCurrentDialog) {
15804
15804
  await thunkApi.dispatch(resetMsgs());
15805
- const { clearPendingAttachments: clearPendingAttachments2 } = await import("./dialogSlice-PRXHSZKA.js");
15805
+ const { clearPendingAttachments: clearPendingAttachments2 } = await import("./dialogSlice-35ZHIKXV.js");
15806
15806
  dispatch(clearPendingAttachments2());
15807
15807
  }
15808
15808
  return { dialogKey, isCurrentDialog, attachmentPlan };
@@ -15810,39 +15810,39 @@ var deleteDialogThunk = async (payload, thunkApi) => {
15810
15810
 
15811
15811
  // packages/chat/dialog/dialogSlice.ts
15812
15812
  var runCreateDialogAction = async (args, thunkApi) => {
15813
- const { createDialogAction } = await import("./createDialogAction-SI5EKEF6.js");
15813
+ const { createDialogAction } = await import("./createDialogAction-BEWLUGTZ.js");
15814
15814
  return createDialogAction(args, thunkApi);
15815
15815
  };
15816
15816
  var runCreateAgentAutomationAction = async (args, thunkApi) => {
15817
- const { createAgentAutomationAction } = await import("./createAgentAutomationAction-EKJMTIUX.js");
15817
+ const { createAgentAutomationAction } = await import("./createAgentAutomationAction-5HZTYLFU.js");
15818
15818
  return createAgentAutomationAction(args, thunkApi);
15819
15819
  };
15820
15820
  var runUpdateDialogTitleAction = async (args, thunkApi) => {
15821
- const { updateDialogTitleAction } = await import("./updateDialogTitleAction-BQH24I5O.js");
15821
+ const { updateDialogTitleAction } = await import("./updateDialogTitleAction-4PLYOEJM.js");
15822
15822
  return updateDialogTitleAction(args, thunkApi);
15823
15823
  };
15824
15824
  var runAddDialogAgentAction = async (args, thunkApi) => {
15825
- const { addDialogAgentAction } = await import("./addDialogAgentAction-ONVFHUOL.js");
15825
+ const { addDialogAgentAction } = await import("./addDialogAgentAction-LVNKMXKZ.js");
15826
15826
  return addDialogAgentAction(args, thunkApi);
15827
15827
  };
15828
15828
  var runRemoveDialogAgentAction = async (args, thunkApi) => {
15829
- const { removeDialogAgentAction } = await import("./removeDialogAgentAction-D3R3QNPD.js");
15829
+ const { removeDialogAgentAction } = await import("./removeDialogAgentAction-FEUUVMYC.js");
15830
15830
  return removeDialogAgentAction(args, thunkApi);
15831
15831
  };
15832
15832
  var runSetPrimaryDialogAgentAction = async (args, thunkApi) => {
15833
- const { setPrimaryDialogAgentAction } = await import("./setPrimaryDialogAgentAction-P5A65M32.js");
15833
+ const { setPrimaryDialogAgentAction } = await import("./setPrimaryDialogAgentAction-Z2BQE3IY.js");
15834
15834
  return setPrimaryDialogAgentAction(args, thunkApi);
15835
15835
  };
15836
15836
  var runSwitchDialogAgentAction = async (args, thunkApi) => {
15837
- const { switchDialogAgentAction } = await import("./switchDialogAgentAction-DMMWH5FG.js");
15837
+ const { switchDialogAgentAction } = await import("./switchDialogAgentAction-G7XVAOGH.js");
15838
15838
  return switchDialogAgentAction(args, thunkApi);
15839
15839
  };
15840
15840
  var runSetDialogExtraReferencesAction = async (args, thunkApi) => {
15841
- const { setDialogExtraReferencesAction } = await import("./setDialogExtraReferencesAction-VORDLM57.js");
15841
+ const { setDialogExtraReferencesAction } = await import("./setDialogExtraReferencesAction-JSTQJPXL.js");
15842
15842
  return setDialogExtraReferencesAction(args, thunkApi);
15843
15843
  };
15844
15844
  var runHandleSendMessageAction = async (args, thunkApi) => {
15845
- const { handleSendMessageAction } = await import("./handleSendMessageAction-53ZRMHZI.js");
15845
+ const { handleSendMessageAction } = await import("./handleSendMessageAction-TGD2MREV.js");
15846
15846
  return handleSendMessageAction(args, thunkApi);
15847
15847
  };
15848
15848
  function clearDialogState() {
@@ -15855,7 +15855,7 @@ var createPageAndAddReference = createAsyncThunk(
15855
15855
  async (payload, { dispatch, getState, rejectWithValue }) => {
15856
15856
  const { slateData, jsonData, title, type, fileId, groupId, dialogKey } = payload;
15857
15857
  try {
15858
- const { createDocState } = await import("./docStore-ISD6RJ4Q.js");
15858
+ const { createDocState } = await import("./docStore-YAQ2NUEU.js");
15859
15859
  const pageKey = await createDocState(
15860
15860
  { slateData, title },
15861
15861
  { dispatch, getState }
@@ -2,26 +2,26 @@ import {
2
2
  clipMultilineText,
3
3
  fetchAndSerializeTable,
4
4
  waitForAbortableDelay
5
- } from "./chunk-SSTQPNS5.js";
5
+ } from "./chunk-I2NBEUPD.js";
6
6
  import {
7
7
  isGatewayHttpStatus
8
8
  } from "./chunk-NF64D32W.js";
9
9
  import {
10
10
  resolvePageReadMarkdown,
11
11
  slateToSimplifiedMarkdown
12
- } from "./chunk-SEDJEJBH.js";
12
+ } from "./chunk-IFWXH7LH.js";
13
13
  import {
14
14
  extractCategorizedMentions
15
15
  } from "./chunk-AGIM7IMJ.js";
16
16
  import {
17
17
  fetchAndCacheMessages
18
- } from "./chunk-ONXCCILE.js";
18
+ } from "./chunk-AZUPMHRN.js";
19
19
  import {
20
20
  createSpaceKey
21
21
  } from "./chunk-UAD2WT54.js";
22
22
  import {
23
23
  read
24
- } from "./chunk-VTB6V4UF.js";
24
+ } from "./chunk-PDAXMBLW.js";
25
25
  import {
26
26
  createDrainExhaustedResponse,
27
27
  isCoreDrainingBody,
@@ -30,7 +30,7 @@ import {
30
30
  } from "./chunk-3L2WKC3W.js";
31
31
  import {
32
32
  getRuntimeServerContext
33
- } from "./chunk-ZGHHY2PV.js";
33
+ } from "./chunk-FMYNIAI6.js";
34
34
  import {
35
35
  classifyGenerationError
36
36
  } from "./chunk-TLE77UJ5.js";
@@ -2,13 +2,13 @@ import {
2
2
  deleteDialog,
3
3
  runtime_default,
4
4
  toast
5
- } from "./chunk-ONXCCILE.js";
5
+ } from "./chunk-AZUPMHRN.js";
6
6
  import {
7
7
  getAllMemberSpaces,
8
8
  getCurrentSpaceId,
9
9
  getCurrentSpaceIdRaw,
10
10
  updateCurrentSpaceIfMatch
11
- } from "./chunk-WXZZQRAH.js";
11
+ } from "./chunk-RXTZB2DH.js";
12
12
  import {
13
13
  require_formatISO
14
14
  } from "./chunk-UVLYNWIE.js";
@@ -23,7 +23,7 @@ import {
23
23
  patchIndividualContentRecord,
24
24
  readContentRecordForSpaceSync,
25
25
  syncContentRecordSpaceId
26
- } from "./chunk-SGI2FIGK.js";
26
+ } from "./chunk-CJQBWHNM.js";
27
27
  import {
28
28
  createSpaceKey,
29
29
  normalizeSpaceId
@@ -36,7 +36,7 @@ import {
36
36
  uploadFileAction,
37
37
  upsertSSREntity,
38
38
  write
39
- } from "./chunk-VTB6V4UF.js";
39
+ } from "./chunk-PDAXMBLW.js";
40
40
  import {
41
41
  resolveFileCategory
42
42
  } from "./chunk-3PVYUPXK.js";
@@ -50,10 +50,10 @@ import {
50
50
  resolveReplicationServers,
51
51
  scheduleDeleteReplication,
52
52
  scheduleWriteReplication
53
- } from "./chunk-ZGHHY2PV.js";
53
+ } from "./chunk-FMYNIAI6.js";
54
54
  import {
55
55
  createAsyncThunk
56
- } from "./chunk-T3CUXNV4.js";
56
+ } from "./chunk-QOURTDZL.js";
57
57
  import {
58
58
  getIsDesktopApp
59
59
  } from "./chunk-5PASH2MB.js";
@@ -1513,11 +1513,11 @@ var ENTITY_DELETE_STRATEGIES = {
1513
1513
  await dispatch(deleteTable({ dbKey: key })).unwrap();
1514
1514
  },
1515
1515
  file: async (key, { thunkAPI }) => {
1516
- const { deleteFileAction } = await import("./deleteFile-KV5VTKAT.js");
1516
+ const { deleteFileAction } = await import("./deleteFile-VCCHS72Y.js");
1517
1517
  await deleteFileAction(key, thunkAPI);
1518
1518
  },
1519
1519
  image: async (key, { thunkAPI }) => {
1520
- const { deleteFileAction } = await import("./deleteFile-KV5VTKAT.js");
1520
+ const { deleteFileAction } = await import("./deleteFile-VCCHS72Y.js");
1521
1521
  await deleteFileAction(key, thunkAPI);
1522
1522
  },
1523
1523
  agent: async (key, { dispatch, userId, sourceServerOrigin }) => {
@@ -5,11 +5,11 @@ import {
5
5
  import {
6
6
  patch,
7
7
  read
8
- } from "./chunk-VTB6V4UF.js";
8
+ } from "./chunk-PDAXMBLW.js";
9
9
  import {
10
10
  DEVICE_LOCAL_OWNER_ID,
11
11
  isDeviceLocalSpaceBody
12
- } from "./chunk-ZGHHY2PV.js";
12
+ } from "./chunk-FMYNIAI6.js";
13
13
  import {
14
14
  selectIdentityUserId
15
15
  } from "./chunk-PXYBUFDB.js";
@@ -8,7 +8,7 @@ import {
8
8
  noloUploadRequest,
9
9
  noloWriteRequest,
10
10
  syncWithServers
11
- } from "./chunk-T3CUXNV4.js";
11
+ } from "./chunk-QOURTDZL.js";
12
12
  import {
13
13
  getAllServers,
14
14
  getIsDesktopApp,
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  addContentToSpace
3
- } from "./chunk-GKZGOSZE.js";
3
+ } from "./chunk-C2QLXFUP.js";
4
4
  import {
5
5
  prepareAndPersistMessage
6
- } from "./chunk-ONXCCILE.js";
6
+ } from "./chunk-AZUPMHRN.js";
7
7
  import {
8
8
  require_format
9
9
  } from "./chunk-BUDVRYES.js";
@@ -16,7 +16,7 @@ import {
16
16
  removeCachedEntity,
17
17
  upsertSSREntity,
18
18
  write
19
- } from "./chunk-VTB6V4UF.js";
19
+ } from "./chunk-PDAXMBLW.js";
20
20
  import {
21
21
  isDevelopment
22
22
  } from "./chunk-5PASH2MB.js";
@@ -3,28 +3,28 @@ import {
3
3
  } from "./chunk-VF4K2QE6.js";
4
4
  import {
5
5
  setDialogExtraReferencesAction
6
- } from "./chunk-YDTLGWBU.js";
6
+ } from "./chunk-SESKIWB4.js";
7
7
  import {
8
8
  fetchAndCacheTableRows
9
- } from "./chunk-GKZGOSZE.js";
9
+ } from "./chunk-C2QLXFUP.js";
10
10
  import {
11
11
  resolveDialogRuntimeAgentKey
12
- } from "./chunk-ONXCCILE.js";
12
+ } from "./chunk-AZUPMHRN.js";
13
13
  import {
14
14
  createSpaceKey
15
15
  } from "./chunk-UAD2WT54.js";
16
16
  import {
17
17
  selectById
18
- } from "./chunk-VTB6V4UF.js";
18
+ } from "./chunk-PDAXMBLW.js";
19
19
  import {
20
20
  require_react
21
21
  } from "./chunk-RD3QLZQV.js";
22
22
  import {
23
23
  selectRuntimeSnapshot
24
- } from "./chunk-ZGHHY2PV.js";
24
+ } from "./chunk-FMYNIAI6.js";
25
25
  import {
26
26
  createAsyncThunk
27
- } from "./chunk-T3CUXNV4.js";
27
+ } from "./chunk-QOURTDZL.js";
28
28
  import {
29
29
  selectIdentityUserId
30
30
  } from "./chunk-PXYBUFDB.js";
@@ -791,7 +791,7 @@ var executeToolRun = createAsyncThunk(
791
791
  if (!executionInput) {
792
792
  throw new Error(`ToolRun ${id} has no input to execute with.`);
793
793
  }
794
- const { findToolExecutor } = await import("./tools-7JMKOJPW.js");
794
+ const { findToolExecutor } = await import("./tools-5MVR3NQI.js");
795
795
  const { executor } = findToolExecutor(run.toolName);
796
796
  toolRunStarted({
797
797
  id: run.id,
@@ -815,7 +815,7 @@ var executeToolRun = createAsyncThunk(
815
815
  const latestState = thunkApi.getState();
816
816
  const userId = selectIdentityUserId(latestState);
817
817
  if (userId) {
818
- const { fetchUserSpaceMemberships } = await import("./memberThunks-TWB77UHJ.js");
818
+ const { fetchUserSpaceMemberships } = await import("./memberThunks-KC3WJGL3.js");
819
819
  await thunkApi.dispatch(fetchUserSpaceMemberships(userId));
820
820
  }
821
821
  }
@@ -206,7 +206,7 @@ async function readDocFunc(args, thunkApi) {
206
206
  throw new Error(`\u65E0\u6548\u7684\u9875\u9762 ID: ${id}\u3002\u9875\u9762 ID \u901A\u5E38\u4EE5 "page-" \u5F00\u5934\u3002`);
207
207
  }
208
208
  try {
209
- const { readAction } = await import("./read-CO6HMH5W.js");
209
+ const { readAction } = await import("./read-T7VU2IMO.js");
210
210
  const pageData = await readAction({ dbKey: id }, thunkApi);
211
211
  if (!pageData) {
212
212
  throw new Error(`\u672A\u627E\u5230 ID \u4E3A ${id} \u7684\u9875\u9762\u3002`);
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  createCliLocalRuntimeAdapter,
3
3
  summarizeEndpoint
4
- } from "./chunk-BRZFJQTW.js";
4
+ } from "./chunk-ZJ5HDNS2.js";
5
5
  import {
6
6
  clipMultilineText
7
- } from "./chunk-SSTQPNS5.js";
7
+ } from "./chunk-I2NBEUPD.js";
8
8
  import {
9
9
  runLocalAgentTurn
10
10
  } from "./chunk-SYWYGUPT.js";
@@ -2,7 +2,7 @@ import {
2
2
  getCurrentSpaceIdRaw,
3
3
  setCurrentSpaceBoth,
4
4
  setSpaceInitialized
5
- } from "./chunk-WXZZQRAH.js";
5
+ } from "./chunk-RXTZB2DH.js";
6
6
  import {
7
7
  createSpaceKey,
8
8
  normalizeSpaceId
@@ -41,6 +41,22 @@ var spaceListsUser = (spaceData, userId) => {
41
41
  var membershipBelongsToUser = (membership, userId) => !membership.userId || membership.userId === userId;
42
42
  var membershipFetchCache = /* @__PURE__ */ new Map();
43
43
  var MEMBERSHIP_FETCH_CACHE_TTL_MS = 3e4;
44
+ var resolveDesktopShellRuntime = () => {
45
+ if (typeof window === "undefined") return { isEmbeddedRuntime: false };
46
+ const shellWindow = window;
47
+ return {
48
+ isEmbeddedRuntime: shellWindow.__NOLO_EMBEDDED_RUNTIME__ === true,
49
+ runtimeOrigin: shellWindow.location?.origin
50
+ };
51
+ };
52
+ var isEmbeddedRuntimeServer = (server, runtime = resolveDesktopShellRuntime()) => {
53
+ if (!runtime.isEmbeddedRuntime || !runtime.runtimeOrigin) return false;
54
+ try {
55
+ return new URL(server).origin === runtime.runtimeOrigin;
56
+ } catch {
57
+ return false;
58
+ }
59
+ };
44
60
  async function fetchMembershipsFromServer(server, token, userId, timeoutMs) {
45
61
  if (!token) return { ok: false, memberships: [] };
46
62
  googleSessionRequestToken(token, server);
@@ -77,6 +93,9 @@ async function fetchMembershipsFromServer(server, token, userId, timeoutMs) {
77
93
  }
78
94
  }
79
95
  var fetchRemoteUserSpaceMemberships = (server, token, userId, timeoutMs = 5e3) => {
96
+ if (isEmbeddedRuntimeServer(server)) {
97
+ return Promise.resolve({ ok: false, memberships: [] });
98
+ }
80
99
  const cacheKey = `${server}|${userId}`;
81
100
  const cached = membershipFetchCache.get(cacheKey);
82
101
  if (cached) return cached;
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  selectCurrentServer,
3
3
  selectRemoteServers
4
- } from "./chunk-G3SJCNHX.js";
4
+ } from "./chunk-76HAJUOJ.js";
5
5
  import {
6
6
  noloDeleteRequest,
7
7
  noloWriteRequest
8
- } from "./chunk-T3CUXNV4.js";
8
+ } from "./chunk-QOURTDZL.js";
9
9
  import {
10
10
  normalizeTimeFields
11
11
  } from "./chunk-5PASH2MB.js";
@@ -3,29 +3,29 @@ import {
3
3
  mergeReferences,
4
4
  resolveReferenceAssets,
5
5
  resolveToolsFromKeys
6
- } from "./chunk-OPZBKP4X.js";
6
+ } from "./chunk-BW6QATP2.js";
7
7
  import {
8
8
  UI_CARD_ENVELOPE_MAX_BYTES,
9
9
  getAllToolRuns,
10
10
  parseUiCard,
11
11
  uiCardFallback
12
- } from "./chunk-SSTQPNS5.js";
12
+ } from "./chunk-I2NBEUPD.js";
13
13
  import {
14
14
  getDocState
15
- } from "./chunk-G3Y56RZA.js";
15
+ } from "./chunk-TVUBURX7.js";
16
16
  import {
17
17
  getTableState
18
- } from "./chunk-GKZGOSZE.js";
18
+ } from "./chunk-C2QLXFUP.js";
19
19
  import {
20
20
  selectAllMsgs
21
- } from "./chunk-ONXCCILE.js";
21
+ } from "./chunk-AZUPMHRN.js";
22
22
  import {
23
23
  getCurrentSpaceIdRaw,
24
24
  getViewMode
25
- } from "./chunk-WXZZQRAH.js";
25
+ } from "./chunk-RXTZB2DH.js";
26
26
  import {
27
27
  selectById
28
- } from "./chunk-VTB6V4UF.js";
28
+ } from "./chunk-PDAXMBLW.js";
29
29
  import {
30
30
  resolveToolBaseUrl
31
31
  } from "./chunk-KQHEGELM.js";
@@ -33,7 +33,7 @@ import {
33
33
  resolveServerUrl,
34
34
  validateInstaboxWorkspaceSelection,
35
35
  writeUsage
36
- } from "./chunk-BRZFJQTW.js";
36
+ } from "./chunk-ZJ5HDNS2.js";
37
37
  import {
38
38
  boxGlyphs,
39
39
  displayWidth,
@@ -86,14 +86,14 @@ import {
86
86
  } from "./chunk-S73EPYNC.js";
87
87
  import {
88
88
  resolveCliLocalRuntimeKeyCapability
89
- } from "./chunk-GRVQJNSR.js";
89
+ } from "./chunk-XZKFM7KO.js";
90
90
  import {
91
91
  extractGoogleValidationLink
92
92
  } from "./chunk-BMQ2MJUK.js";
93
93
  import {
94
94
  parseUiCard,
95
95
  uiCardFallback
96
- } from "./chunk-SSTQPNS5.js";
96
+ } from "./chunk-I2NBEUPD.js";
97
97
  import {
98
98
  isGatewayHttpStatus
99
99
  } from "./chunk-NF64D32W.js";
@@ -104,7 +104,7 @@ import {
104
104
  loadOwnerItemsFromDb,
105
105
  parseUiAskChoiceContent,
106
106
  resolveAgentMemoryPolicy
107
- } from "./chunk-TCY22W2Y.js";
107
+ } from "./chunk-HJHZVSTB.js";
108
108
  import {
109
109
  API_REPORTED_COST_MULTIPLIER,
110
110
  estimateMessagesTokens,
@@ -113,7 +113,7 @@ import {
113
113
  resolveAgentContextWindow,
114
114
  resolveOccupancy,
115
115
  resolveOccupancyWindow
116
- } from "./chunk-ONXCCILE.js";
116
+ } from "./chunk-AZUPMHRN.js";
117
117
  import {
118
118
  parsePositiveFiniteNumberOrFallback
119
119
  } from "./chunk-Y5GCAMGP.js";
@@ -6,12 +6,12 @@ import {
6
6
  loadFileFromIndexedDb,
7
7
  removeAction,
8
8
  saveFileToIndexedDb
9
- } from "./chunk-YO4DCVD2.js";
9
+ } from "./chunk-2IPR4PBB.js";
10
10
  import {
11
11
  readAction,
12
12
  readRequestManager,
13
13
  resolveAgentReadServers
14
- } from "./chunk-DEOPZE4S.js";
14
+ } from "./chunk-5VVP7DW3.js";
15
15
  import {
16
16
  beginWriteAck,
17
17
  compareRemoteRecordsByComparableTime,
@@ -29,13 +29,13 @@ import {
29
29
  shouldReplaceLocalWithRemoteRecord,
30
30
  shouldReplicateLocalRecord,
31
31
  uploadToCurrentServer
32
- } from "./chunk-ZGHHY2PV.js";
32
+ } from "./chunk-FMYNIAI6.js";
33
33
  import {
34
34
  asyncThunkCreator,
35
35
  buildCreateSlice,
36
36
  createEntityAdapter,
37
37
  noloDeleteRequest
38
- } from "./chunk-T3CUXNV4.js";
38
+ } from "./chunk-QOURTDZL.js";
39
39
  import {
40
40
  fetchFromClientDb,
41
41
  fetchFromServer,
@@ -1494,7 +1494,7 @@ var dbSlice = createSliceWithThunks({
1494
1494
  // 动态 import 在调用期解析,避开 TDZ/求值顺序问题(同下方 share)。
1495
1495
  read: create.asyncThunk(
1496
1496
  async (payload, thunkApi) => {
1497
- const { readAction: readAction2 } = await import("./read-CO6HMH5W.js");
1497
+ const { readAction: readAction2 } = await import("./read-T7VU2IMO.js");
1498
1498
  return readAction2(payload, thunkApi);
1499
1499
  },
1500
1500
  {
@@ -1568,7 +1568,7 @@ var dbSlice = createSliceWithThunks({
1568
1568
  // 这里改成动态 import,运行期才解析,彻底断开这条边。
1569
1569
  share: create.asyncThunk(
1570
1570
  async (config, thunkApi) => {
1571
- const { shareResourceAction } = await import("./action-4V2UISXC.js");
1571
+ const { shareResourceAction } = await import("./action-R2EIXR7I.js");
1572
1572
  return shareResourceAction(config, thunkApi);
1573
1573
  }
1574
1574
  ),
@@ -1983,7 +1983,14 @@ function createUnsortedStateAdapter(selectId) {
1983
1983
  });
1984
1984
  updates = Object.values(updatesPerEntity);
1985
1985
  if (updates.length > 0) {
1986
- if (updates.filter((update) => takeNewKey(newKeys, update, state)).length > 0) state.ids = Object.values(state.entities).map((e) => selectIdValue(e, selectId));
1986
+ if (updates.filter((update) => takeNewKey(newKeys, update, state)).length > 0) {
1987
+ const ids = /* @__PURE__ */ new Set();
1988
+ for (const id of state.ids) {
1989
+ const newId = newKeys[id] ?? id;
1990
+ if (newId in state.entities) ids.add(newId);
1991
+ }
1992
+ state.ids = Array.from(ids);
1993
+ }
1987
1994
  }
1988
1995
  }
1989
1996
  function upsertOneMutably(entity, state) {
@@ -2194,6 +2201,78 @@ var logRequestFailure = (level, message) => {
2194
2201
  }
2195
2202
  console.error(message);
2196
2203
  };
2204
+ var mutationFailureIdentifiers = /* @__PURE__ */ new Set([
2205
+ "AUTHORITY_HOME_CONTROLLED",
2206
+ "AUTHORITY_MISMATCH",
2207
+ "USER_BATCH_AUTHORITY_CONTROLLED",
2208
+ "SPACE_OWNER_AGENT_FORBIDDEN",
2209
+ "APP_WRITE_FORBIDDEN",
2210
+ "INCOMPLETE_APP_PAYLOAD",
2211
+ "REVISION_CONFLICT",
2212
+ "tombstone_conflict",
2213
+ "INVALID_REQUEST",
2214
+ "FORBIDDEN",
2215
+ "TOKEN_STATS_SERVER_MANAGED",
2216
+ "PATCH_PERMISSION_DENIED",
2217
+ "WRITE_PERMISSION_DENIED",
2218
+ "UNSUPPORTED_OAUTH_PROVIDER",
2219
+ "INVALID_AGENT_SKILL_MODE",
2220
+ "AUTOMATION_OWNER_AGENT_FORBIDDEN",
2221
+ "PROTOCOL_UNAVAILABLE",
2222
+ "INVALID_IF_MATCH",
2223
+ "provider_model_mismatch"
2224
+ ]);
2225
+ var DIAGNOSTIC_READ_TIMEOUT_MS = 1200;
2226
+ var DIAGNOSTIC_MAX_BYTES = 8 * 1024;
2227
+ var readBoundedJson = async (response) => {
2228
+ const body = response.body;
2229
+ if (!body) return null;
2230
+ const reader = body.getReader();
2231
+ const deadline = Date.now() + DIAGNOSTIC_READ_TIMEOUT_MS;
2232
+ const chunks = [];
2233
+ let received = 0;
2234
+ try {
2235
+ for (; ; ) {
2236
+ const remainingMs = deadline - Date.now();
2237
+ if (remainingMs <= 0) throw new Error("diagnostic read timed out");
2238
+ let timer;
2239
+ const timeout = new Promise((_, reject) => {
2240
+ timer = setTimeout(() => reject(new Error("diagnostic read timed out")), remainingMs);
2241
+ });
2242
+ const { done, value } = await Promise.race([reader.read(), timeout]).finally(() => {
2243
+ if (timer !== void 0) clearTimeout(timer);
2244
+ });
2245
+ if (done) break;
2246
+ received += value.byteLength;
2247
+ if (received > DIAGNOSTIC_MAX_BYTES) throw new Error("diagnostic read too large");
2248
+ chunks.push(value);
2249
+ }
2250
+ } finally {
2251
+ void reader.cancel().catch(() => {
2252
+ });
2253
+ }
2254
+ const total = chunks.reduce((sum, chunk) => sum + chunk.byteLength, 0);
2255
+ const merged = new Uint8Array(total);
2256
+ let offset = 0;
2257
+ for (const chunk of chunks) {
2258
+ merged.set(chunk, offset);
2259
+ offset += chunk.byteLength;
2260
+ }
2261
+ return JSON.parse(new TextDecoder().decode(merged));
2262
+ };
2263
+ var describeMutationFailure = async (response) => {
2264
+ const status = `HTTP ${response.status}`;
2265
+ try {
2266
+ const body = await readBoundedJson(response);
2267
+ const fields = ["error", "code", "message"].flatMap((field) => {
2268
+ const value = body?.[field];
2269
+ return typeof value === "string" && mutationFailureIdentifiers.has(value) ? [`${field}=${value}`] : [];
2270
+ });
2271
+ return fields.length ? `${status} (${fields.join(", ")})` : status;
2272
+ } catch {
2273
+ return status;
2274
+ }
2275
+ };
2197
2276
  var noloRequest = async (server, config, state, signal) => {
2198
2277
  const headers = { ...config.headers || { "Content-Type": "application/json" } };
2199
2278
  const token = selectIdentityToken(state) ?? null;
@@ -2224,10 +2303,10 @@ var noloPatchRequest = async (server, dbKey, updates, state, signal, options) =>
2224
2303
  state,
2225
2304
  signal
2226
2305
  );
2227
- if (!response.ok) {
2306
+ if (!response.ok && failureLogLevel !== "silent") {
2228
2307
  logRequestFailure(
2229
2308
  failureLogLevel,
2230
- `PATCH request failed for ${dbKey} on ${server}: HTTP ${response.status}`
2309
+ `PATCH request failed for ${dbKey} on ${server}: ${await describeMutationFailure(response)}`
2231
2310
  );
2232
2311
  }
2233
2312
  return response.ok;
@@ -2255,10 +2334,10 @@ var noloWriteRequest = async (server, writeConfig, state, signal, options) => {
2255
2334
  state,
2256
2335
  signal
2257
2336
  );
2258
- if (!response.ok) {
2337
+ if (!response.ok && failureLogLevel !== "silent") {
2259
2338
  logRequestFailure(
2260
2339
  failureLogLevel,
2261
- `Write request failed for ${customKey} on ${server}: HTTP ${response.status}`
2340
+ `Write request failed for ${customKey} on ${server}: ${await describeMutationFailure(response)}`
2262
2341
  );
2263
2342
  }
2264
2343
  return response.ok;