nolo-cli 0.157.0-alpha.1 → 0.158.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 (126) hide show
  1. package/{_executeModel-5WS2PA62.js → _executeModel-6BMU3URY.js} +35 -35
  2. package/{accountResolver-7RYB4D2P.js → accountResolver-55EDKEIK.js} +1 -1
  3. package/{action-ZJYUBXFC.js → action-GPPJC5TI.js} +4 -4
  4. package/{addContentAction-TVHB4526.js → addContentAction-BI6RDRTQ.js} +7 -7
  5. package/{addDialogAgentAction-FDPBU6K6.js → addDialogAgentAction-4RJYUSIK.js} +6 -6
  6. package/{agentDeleteCommand-Q6M4F3U6.js → agentDeleteCommand-Q2XWGBC2.js} +42 -42
  7. package/{agentEmailCommands-FNH6FEHS.js → agentEmailCommands-XFBE2A3F.js} +44 -44
  8. package/{agentListCommands-JUNMFS6E.js → agentListCommands-OROMT4P3.js} +12 -12
  9. package/{agentMachineCommands-VNLDEKNT.js → agentMachineCommands-ULK5YKKJ.js} +11 -10
  10. package/{agentProviderCommands-X2HQE6HY.js → agentProviderCommands-MKG2OOEY.js} +2 -2
  11. package/{agentRecordCommands-47XXRVPI.js → agentRecordCommands-3VHBLS6P.js} +42 -42
  12. package/{agentRunCommand-QEXFJUXQ.js → agentRunCommand-LCIMEAQY.js} +44 -43
  13. package/{agentRuntimeLocal-O5GDAFTN.js → agentRuntimeLocal-NPJS2QDP.js} +5 -5
  14. package/{agentSlice-E3XS5FTQ.js → agentSlice-VRAPG6CH.js} +7 -7
  15. package/{appDeleteCommands-C2J5RQ3I.js → appDeleteCommands-AZ3KS4HK.js} +10 -10
  16. package/{appDeployCommands-3YRK7PSU.js → appDeployCommands-BTV22ICJ.js} +10 -10
  17. package/{appDeployStatusCommands-FPAX7MOK.js → appDeployStatusCommands-JSW3HPIW.js} +10 -10
  18. package/{appGetCommands-XAC2V766.js → appGetCommands-5KTTFIMV.js} +10 -10
  19. package/{appListCommands-ZJL2W5O7.js → appListCommands-3BJPAE2U.js} +10 -10
  20. package/{authCommand-J3XILHWW.js → authCommand-NIV3DKPF.js} +7 -287
  21. package/{authCommands-77CHYBGF.js → authCommands-AMNIAKEG.js} +2 -2
  22. package/{builtinSkillRegistry-A6VSPJEJ.js → builtinSkillRegistry-H3AY27TR.js} +1 -1
  23. package/{chromeCommands-OBBNJCLS.js → chromeCommands-IY4NVSXZ.js} +17 -10
  24. package/{chunk-SW4S4XYB.js → chunk-2AB2HA4M.js} +84 -34
  25. package/{chunk-VSOWPETY.js → chunk-2BKUVRC5.js} +7 -7
  26. package/{chunk-Z6KQDSZW.js → chunk-2SGAI64X.js} +2 -2
  27. package/{chunk-KOB75UNU.js → chunk-2SOS7OSQ.js} +18 -2
  28. package/{chunk-C5VPAHIU.js → chunk-32ZKZET7.js} +1 -1
  29. package/{chunk-XPWGOTBQ.js → chunk-3L2WKC3W.js} +1 -8
  30. package/{chunk-PEO24UB5.js → chunk-3TBHZPNG.js} +33 -6
  31. package/{chunk-YBNHPX4S.js → chunk-4RJJDA57.js} +1 -1
  32. package/{chunk-X5SUT4CN.js → chunk-4UOEOHY3.js} +6 -6
  33. package/{chunk-UUPR3TD7.js → chunk-7RF4O6AT.js} +1 -3
  34. package/{chunk-FPWT3RH2.js → chunk-AJ4V34SG.js} +10 -10
  35. package/{chunk-2GGXHQIW.js → chunk-BLVSFYQ3.js} +4 -2
  36. package/{chunk-SKPPKHD3.js → chunk-BYQOCH75.js} +2 -2
  37. package/{chunk-UTIMX333.js → chunk-C3OK72G3.js} +1 -1
  38. package/{chunk-ZWG3C7VI.js → chunk-C6FY7HWI.js} +35 -0
  39. package/{chunk-RUNKPFM5.js → chunk-CDWHHLK5.js} +12 -8
  40. package/{chunk-ROPSATAB.js → chunk-CON6SI7N.js} +1 -1
  41. package/{chunk-4Z245KOA.js → chunk-DC3SZCRR.js} +6 -2
  42. package/{chunk-OH2M7WEU.js → chunk-EQGFFDNA.js} +3 -3
  43. package/{chunk-ANJTRG52.js → chunk-G2WP7VPD.js} +0 -37
  44. package/{chunk-7A4LJCDR.js → chunk-G476FQ7Q.js} +4 -4
  45. package/{chunk-DW7MGLMG.js → chunk-GAVUTXM5.js} +21 -17
  46. package/{chunk-PSJWPSKS.js → chunk-HB4XPBC7.js} +0 -32
  47. package/{chunk-6MJNEXUU.js → chunk-HGDKT2D6.js} +4 -0
  48. package/{chunk-EM3YOZJ4.js → chunk-ICRRXBRN.js} +3 -3
  49. package/{chunk-7KYVUFDG.js → chunk-IE5PXKVU.js} +1 -263
  50. package/{chunk-T6CBQ6BN.js → chunk-INFHX73M.js} +1 -1
  51. package/{chunk-CE7PIHQD.js → chunk-IRTOYSA2.js} +3 -3
  52. package/{chunk-WZ6OU4NX.js → chunk-J2ATF74A.js} +2 -2
  53. package/{chunk-TJ2VPCBE.js → chunk-JPJGMOIM.js} +2 -2
  54. package/{chunk-I2ZMGXXF.js → chunk-KFHREHUQ.js} +1 -1
  55. package/{chunk-7GC3EKUG.js → chunk-KKKHAF3P.js} +2 -2
  56. package/{chunk-KX6LPG7W.js → chunk-KLA62VVE.js} +1 -1
  57. package/{chunk-TYND6RDQ.js → chunk-LV4LV2B4.js} +72 -1
  58. package/{chunk-TZTWMGE3.js → chunk-M2P3OGXZ.js} +3 -3
  59. package/{chunk-CBHGZRCE.js → chunk-MYOH447Z.js} +1 -1
  60. package/{chunk-6MPAEODB.js → chunk-NDZOXXIM.js} +17 -3
  61. package/{chunk-MVJVF4ED.js → chunk-NKPAHRMA.js} +7 -6
  62. package/{chunk-ZD2BLOY6.js → chunk-O4ZERG3M.js} +3 -3
  63. package/{chunk-36OMEXXR.js → chunk-OON4OBWI.js} +1 -1
  64. package/{chunk-SEJ5OS6F.js → chunk-PXYBUFDB.js} +4 -0
  65. package/{chunk-G47IPDOK.js → chunk-QPY264HO.js} +1 -1
  66. package/{chunk-TNIX77YM.js → chunk-R5GO3YZP.js} +34 -1
  67. package/{chunk-EJU23ST5.js → chunk-S72LMV7T.js} +670 -627
  68. package/{chunk-D4OWHT5Y.js → chunk-SPKLALBU.js} +2 -2
  69. package/{chunk-FDT27L7S.js → chunk-UCLSOLX4.js} +7 -5
  70. package/{chunk-B2EGWZJG.js → chunk-UFYBYB26.js} +1 -1
  71. package/{chunk-3XZKV7QQ.js → chunk-US6MKPE7.js} +1 -1
  72. package/{chunk-VAZHH6FO.js → chunk-VDEVDGEM.js} +18 -12
  73. package/{chunk-HXHSTRGH.js → chunk-VYNMQ6HW.js} +0 -27
  74. package/{chunk-7BSQK2UC.js → chunk-WRCZXJ4N.js} +2 -2
  75. package/{chunk-H4KACZMG.js → chunk-WTFRBJT5.js} +261 -126
  76. package/{chunk-QDA4Y5O6.js → chunk-WXFZ4P6O.js} +18 -14
  77. package/chunk-Y5GCAMGP.js +9 -0
  78. package/{chunk-SCJD2PNK.js → chunk-YPG7TUQD.js} +3 -3
  79. package/{chunk-XFKZ3MCV.js → chunk-YTXQ2U2X.js} +221 -65
  80. package/{chunk-ZEHTARJA.js → chunk-ZBXIKCZ4.js} +38 -92
  81. package/{chunk-HKT6QXP3.js → chunk-ZEY4NJRE.js} +2 -2
  82. package/{chunk-HP6O6LTV.js → chunk-ZVQHBIWV.js} +6 -6
  83. package/{commandRegistry-OUBQIF62.js → commandRegistry-D6JTVYKG.js} +73 -81
  84. package/{contentThunks-B3FRQGP7.js → contentThunks-DYQO4CTI.js} +14 -13
  85. package/{createAgentAutomationAction-T2YFJ6MY.js → createAgentAutomationAction-LW26KIBP.js} +14 -13
  86. package/{createDialogAction-2NFGFBXW.js → createDialogAction-VLLBRD52.js} +15 -14
  87. package/{createPageAction-LDAVZDN7.js → createPageAction-PDACOLI6.js} +14 -13
  88. package/{dbSlice-5QGKMQLO.js → dbSlice-DC2J53RC.js} +6 -6
  89. package/{deleteFile-EW6QNRRT.js → deleteFile-KYWEMNFX.js} +4 -4
  90. package/{dialogCommands-ZLBEAQHE.js → dialogCommands-F3Y4KCPZ.js} +12 -11
  91. package/{dialogSlice-64S3J6CP.js → dialogSlice-ERMZYMS6.js} +13 -12
  92. package/{docCreateCommands-XOG5BBFQ.js → docCreateCommands-YMWZLW64.js} +8 -8
  93. package/{docDeleteCommands-NCW3BBRX.js → docDeleteCommands-6KJ3ESK4.js} +9 -9
  94. package/{docReadCommands-OT7X44Y3.js → docReadCommands-YQGFVLWI.js} +8 -8
  95. package/{docStore-NIP7OO4I.js → docStore-HXKI6W5D.js} +7 -7
  96. package/{docUpdateCommands-JW7OWW2J.js → docUpdateCommands-QLSGXUEX.js} +8 -8
  97. package/{handleSendMessageAction-TOKA7ED7.js → handleSendMessageAction-2XCOZPXY.js} +25 -24
  98. package/index.js +6 -6
  99. package/{localRuntimeAdapter-EQM6LFYC.js → localRuntimeAdapter-VOFUPXNF.js} +42 -40
  100. package/{machineCommands-WJ7FZ67T.js → machineCommands-IN5O7CIO.js} +46 -44
  101. package/{machineWsRunDispatch-BQT4DEA2.js → machineWsRunDispatch-TH3GMSR3.js} +41 -41
  102. package/{memberThunks-KRV5YXOB.js → memberThunks-2DWKLE6W.js} +7 -7
  103. package/package.json +1 -1
  104. package/{profileConfig-ZGOFORWV.js → profileConfig-KN3N2BLF.js} +7 -1
  105. package/{providerPresetApply-CRZFMQD5.js → providerPresetApply-GSJI4JBJ.js} +1 -1
  106. package/{providerRegistry-7IS43D3X.js → providerRegistry-TSSTPGWF.js} +1 -1
  107. package/{read-5KAZHHDM.js → read-L7QEJETH.js} +4 -4
  108. package/{readDocTool-5QO34OSX.js → readDocTool-QELXV2GW.js} +1 -1
  109. package/{readlineWorkspace-JHJSU5DS.js → readlineWorkspace-EIEQUTEZ.js} +317 -104
  110. package/{removeDialogAgentAction-6X63HMI3.js → removeDialogAgentAction-376XSUP2.js} +8 -8
  111. package/{runAgentClientLoop-5QIGEALK.js → runAgentClientLoop-3KHKKBZI.js} +39 -34
  112. package/{secretCommands-ZXZRLR3R.js → secretCommands-DNY56NSU.js} +11 -1
  113. package/{setDialogExtraReferencesAction-4MAYKKYW.js → setDialogExtraReferencesAction-QBDSH63D.js} +7 -7
  114. package/{setPrimaryDialogAgentAction-EGBAMREH.js → setPrimaryDialogAgentAction-537QFGW3.js} +8 -8
  115. package/settingThunks-4Z43ZSAT.js +923 -0
  116. package/{spaceCommands-ZWDPTURU.js → spaceCommands-T5Z4U7HP.js} +8 -8
  117. package/{streamAgentChatTurn-456DWXNY.js → streamAgentChatTurn-DMXXSEVX.js} +39 -39
  118. package/{switchDialogAgentAction-YBKTD6DO.js → switchDialogAgentAction-CSO6AKRL.js} +6 -6
  119. package/{tableCommands-U3QDY4L6.js → tableCommands-LBH3QPPO.js} +1 -1
  120. package/{toolApiClient-7WSJJJBV.js → toolApiClient-HGNO53TC.js} +2 -2
  121. package/{tools-IWNXKK4Y.js → tools-RMT7NAMC.js} +29 -28
  122. package/{updateCommands-NQXAGFM7.js → updateCommands-LXZLG44Y.js} +2 -2
  123. package/{updateDialogTitleAction-SX53FZWO.js → updateDialogTitleAction-Z4WNUH6Y.js} +14 -13
  124. package/{workloadLifecycle-36DXRZKU.js → workloadLifecycle-6O6PMISX.js} +2 -2
  125. package/chunk-W4S6OTSC.js +0 -35
  126. package/settingThunks-FTDRZNSJ.js +0 -1371
@@ -14,13 +14,13 @@ import {
14
14
  } from "./chunk-QYPE3TS3.js";
15
15
  import {
16
16
  runLlm
17
- } from "./chunk-X5SUT4CN.js";
17
+ } from "./chunk-4UOEOHY3.js";
18
18
  import {
19
19
  getApproxPricePerImage
20
20
  } from "./chunk-4JH2UMJR.js";
21
21
  import {
22
22
  cleanupCliSessionForDialog
23
- } from "./chunk-CE7PIHQD.js";
23
+ } from "./chunk-IRTOYSA2.js";
24
24
  import {
25
25
  getActiveDialogAgentId,
26
26
  getDialogAgentIds,
@@ -56,7 +56,7 @@ import {
56
56
  } from "./chunk-XI7DGLUK.js";
57
57
  import {
58
58
  addContentAction
59
- } from "./chunk-TZTWMGE3.js";
59
+ } from "./chunk-M2P3OGXZ.js";
60
60
  import {
61
61
  patch,
62
62
  read,
@@ -64,19 +64,19 @@ import {
64
64
  selectById,
65
65
  upload,
66
66
  write
67
- } from "./chunk-HP6O6LTV.js";
67
+ } from "./chunk-ZVQHBIWV.js";
68
68
  import {
69
69
  getRuntimeServerContext,
70
70
  parseOwnerUserIdFromDbKey,
71
71
  scheduleDeleteReplication
72
- } from "./chunk-Z6KQDSZW.js";
72
+ } from "./chunk-2SGAI64X.js";
73
73
  import {
74
74
  asyncThunkCreator,
75
75
  buildCreateSlice,
76
76
  createAsyncThunk,
77
77
  createEntityAdapter,
78
78
  createSelector
79
- } from "./chunk-7BSQK2UC.js";
79
+ } from "./chunk-WRCZXJ4N.js";
80
80
  import {
81
81
  createClientLogger
82
82
  } from "./chunk-QQ56R7KS.js";
@@ -84,7 +84,7 @@ import {
84
84
  selectIdentityToken,
85
85
  selectIdentityUser,
86
86
  selectIdentityUserId
87
- } from "./chunk-SEJ5OS6F.js";
87
+ } from "./chunk-PXYBUFDB.js";
88
88
  import {
89
89
  getRecordTimestamp,
90
90
  getTombstoneTimestamp,
@@ -102,20 +102,24 @@ import {
102
102
  STAGNANT_TOOL_CALLS_FALLBACK_MESSAGE,
103
103
  STREAM_TRUNCATED_FALLBACK_MESSAGE,
104
104
  asOptionalJsonRecord,
105
+ devinChannelContextWindow,
105
106
  extractReferenceKeysFromMessage,
106
107
  normalizeUsage,
107
108
  resolveAutoExecutionProfile
108
- } from "./chunk-ZWG3C7VI.js";
109
+ } from "./chunk-C6FY7HWI.js";
110
+ import {
111
+ isDevinOAuthAgent
112
+ } from "./chunk-5ZUL4CUO.js";
109
113
  import {
110
114
  COMPACTION_SUMMARY_SYSTEM_PROMPT,
111
115
  DEFAULT_CONTEXT_WINDOW,
112
116
  buildCompactionMetricsFromPlan,
113
117
  buildCompactionUserContent,
114
118
  computeSummarySourceMetadata,
119
+ findModelContextWindow,
115
120
  formatCompactionMetricsLog,
116
121
  formatFileOperationsFromMessages,
117
122
  formatMessagesForSummaryWithTruncation,
118
- getModelContextWindow,
119
123
  getModelInfo,
120
124
  planCompression,
121
125
  serializeMessageContent
@@ -149,6 +153,9 @@ import {
149
153
  import {
150
154
  asOptionalFiniteNumber
151
155
  } from "./chunk-WWC7I6TA.js";
156
+ import {
157
+ estimateTokenCount
158
+ } from "./chunk-PSCNXBYA.js";
152
159
  import {
153
160
  findModelConfig,
154
161
  getModelConfig
@@ -576,6 +583,8 @@ var fetchAndCacheMessagesLocalFirst = async ({
576
583
  const remotePromise = Promise.all(serverPromises).then(
577
584
  (results) => results.flat()
578
585
  );
586
+ void remotePromise.catch(() => {
587
+ });
579
588
  let localSettledAt = null;
580
589
  const localTimingPromise = localPromise.then((value) => {
581
590
  localSettledAt = typeof performance !== "undefined" ? performance.now() : Date.now();
@@ -694,6 +703,154 @@ var fetchAndCacheMessages = async (options) => {
694
703
  return remotePromise;
695
704
  };
696
705
 
706
+ // packages/ai/context/contextOccupancy.ts
707
+ function estimateMessagesTokens(messages) {
708
+ return messages.reduce((total, message) => {
709
+ const content = typeof message.content === "string" ? message.content : message.content == null ? "" : JSON.stringify(message.content);
710
+ return total + estimateTokenCount(content) + 4;
711
+ }, 0);
712
+ }
713
+ function historyTokensBeforeLatestAssistant(messages) {
714
+ const total = estimateMessagesTokens(messages);
715
+ const latest = messages[messages.length - 1];
716
+ if (latest?.role !== "assistant") return total;
717
+ return Math.max(0, total - estimateMessagesTokens([latest]));
718
+ }
719
+ function resolveOccupancy(input) {
720
+ if (input.authoritativeInput !== void 0 && input.authoritativeInput > 0) {
721
+ const generated = Math.max(0, input.generatedSinceAuthority ?? 0);
722
+ return {
723
+ tokens: input.authoritativeInput + generated,
724
+ estimated: generated > 0
725
+ };
726
+ }
727
+ return {
728
+ tokens: Math.max(0, input.baselineEstimate ?? 0),
729
+ estimated: true
730
+ };
731
+ }
732
+ function resolveOccupancyWindow(ref) {
733
+ if (!ref.model) return void 0;
734
+ if (isDevinOAuthAgent(ref)) {
735
+ return devinChannelContextWindow(ref.model) ?? findModelContextWindow(ref.model, ref.provider);
736
+ }
737
+ return findModelContextWindow(ref.model, ref.provider);
738
+ }
739
+
740
+ // packages/ai/context/agentContextWindow.ts
741
+ function resolveAgentContextWindow(ref) {
742
+ const byModel = resolveOccupancyWindow({ model: ref.model, provider: ref.provider });
743
+ if (byModel !== void 0) return byModel;
744
+ const byName = ref.agentName?.trim() ? resolveOccupancyWindow({ model: ref.agentName, provider: ref.provider }) : void 0;
745
+ if (byName !== void 0) return byName;
746
+ const candidates = [
747
+ ...modelSlugCandidates(ref.agentKey, 2),
748
+ ...modelSlugCandidates(ref.agentName, 1)
749
+ ];
750
+ for (const candidate of candidates) {
751
+ const window = resolveOccupancyWindow({ model: candidate, provider: ref.provider });
752
+ if (window !== void 0) return window;
753
+ }
754
+ return void 0;
755
+ }
756
+ var AGENT_KEY_PREFIX = /^agent-[a-z0-9]+-/i;
757
+ function modelSlugCandidates(source, maxDrop) {
758
+ const raw = source?.trim();
759
+ if (!raw) return [];
760
+ const base = raw.replace(/\s+/g, "-").toLowerCase();
761
+ const seed = base.replace(AGENT_KEY_PREFIX, "");
762
+ const out = [seed];
763
+ if (seed !== base) out.push(base);
764
+ const segments = seed.split("-");
765
+ for (let drop = 1; drop <= maxDrop && drop < segments.length; drop++) {
766
+ out.push(segments.slice(drop).join("-"));
767
+ }
768
+ return [...new Set(out.filter(Boolean))];
769
+ }
770
+
771
+ // packages/agent-runtime/builtinPlatformAgentRoute.ts
772
+ function resolveBuiltinAgentRuntimeFields(agentKey) {
773
+ if (!isBuiltinPlatformAgentKey(agentKey)) return null;
774
+ const entry = builtinAgentCatalogEntryById(parseBuiltinPlatformAgentId(agentKey));
775
+ if (!entry) return null;
776
+ return { provider: entry.provider, model: entry.model };
777
+ }
778
+
779
+ // packages/agent-runtime/builtinPlatformAgentConfigs.ts
780
+ function buildConfig(e2) {
781
+ const key = publicAgentKey(e2.id);
782
+ const rawRecord = {
783
+ dbKey: key,
784
+ isPublic: true,
785
+ provider: e2.provider,
786
+ model: e2.model,
787
+ apiSource: e2.apiSource ?? "platform",
788
+ useServerProxy: e2.useServerProxy ?? true
789
+ };
790
+ if (e2.hasImageOutput) rawRecord.hasImageOutput = true;
791
+ if (e2.imageModel) rawRecord.imageModel = e2.imageModel;
792
+ if (e2.imageWorkflow) rawRecord.imageWorkflow = e2.imageWorkflow;
793
+ if (e2.imageConfig) rawRecord.imageConfig = e2.imageConfig;
794
+ return {
795
+ key,
796
+ name: e2.name,
797
+ provider: e2.provider,
798
+ model: e2.model,
799
+ apiSource: e2.apiSource ?? "platform",
800
+ useServerProxy: e2.useServerProxy ?? true,
801
+ rawRecord
802
+ };
803
+ }
804
+ var BUILTIN_PLATFORM_AGENT_CONFIGS = Object.fromEntries(
805
+ builtinRuntimeFallbackEntries().map((e2) => [publicAgentKey(e2.id), buildConfig(e2)])
806
+ );
807
+ function resolveBuiltinPlatformAgentConfig(agentRef) {
808
+ return BUILTIN_PLATFORM_AGENT_CONFIGS[agentRef] ?? null;
809
+ }
810
+ function resolveBuiltinPlatformAgentRecord(agentRef) {
811
+ const config = resolveBuiltinPlatformAgentConfig(agentRef);
812
+ if (!config) return null;
813
+ return {
814
+ ...config.rawRecord,
815
+ dbKey: agentRef,
816
+ ...config.name ? { name: config.name } : {}
817
+ };
818
+ }
819
+ var BUILTIN_RUNTIME_EXTRA_OVERRIDES = {
820
+ [BUILTIN_NOLO_AGENT_KEY]: { reasoningEffort: "max" }
821
+ };
822
+ function applyBuiltinAgentRuntimeOverride(agentKey, record) {
823
+ const fields = resolveBuiltinAgentRuntimeFields(agentKey);
824
+ if (!fields) return record;
825
+ const extraFields = BUILTIN_RUNTIME_EXTRA_OVERRIDES[agentKey];
826
+ const extraNeedsOverride = (target) => {
827
+ if (extraFields == null || target == null || typeof target !== "object") {
828
+ return false;
829
+ }
830
+ const flat = target;
831
+ return Object.entries(extraFields).some(([key, value]) => flat[key] !== value);
832
+ };
833
+ const current = record;
834
+ const rawNeedsOverride = current.rawRecord != null && (current.rawRecord.provider !== fields.provider || current.rawRecord.model !== fields.model || extraNeedsOverride(current.rawRecord));
835
+ if (current.provider === fields.provider && current.model === fields.model && !rawNeedsOverride && !extraNeedsOverride(record)) {
836
+ return record;
837
+ }
838
+ return {
839
+ ...record,
840
+ provider: fields.provider,
841
+ model: fields.model,
842
+ ...extraFields ?? {},
843
+ ...current.rawRecord ? {
844
+ rawRecord: {
845
+ ...current.rawRecord,
846
+ provider: fields.provider,
847
+ model: fields.model,
848
+ ...extraFields ?? {}
849
+ }
850
+ } : {}
851
+ };
852
+ }
853
+
697
854
  // packages/render/web/ui/toastStore.ts
698
855
  var EXIT_MS = 320;
699
856
  var raf = typeof globalThis.requestAnimationFrame === "function" ? (cb) => globalThis.requestAnimationFrame(cb) : (cb) => {
@@ -4916,9 +5073,18 @@ var chat_locale_default = {
4916
5073
  usageInputLabel: "input",
4917
5074
  usageOutputLabel: "output",
4918
5075
  contextWindow: "Context window",
4919
- contextWindowUnknown: "Unknown context window",
4920
- contextOccupancyPercent: "Context occupancy {{percent}}%",
4921
- contextOccupancy: "Context occupancy",
5076
+ contextUsageKnownChip: "{{percent}}%",
5077
+ contextUsageEstimatedChip: "~{{percent}}%",
5078
+ contextUsageUnknownChip: "{{tokens}}",
5079
+ contextUsageUnknownChipEstimated: "\u2248{{tokens}}",
5080
+ contextUsageLoadingChip: "\u2014",
5081
+ contextUsageChipLabel: "Context occupancy {{usage}}",
5082
+ contextUsageKnownPanel: "{{tokens}} / {{window}} \xB7 {{percent}}%",
5083
+ contextUsageUnknownPanel: "{{tokens}} tokens \xB7 Window unknown",
5084
+ contextUsageUnknownPanelEstimated: "\u2248{{tokens}} tokens \xB7 Window unknown",
5085
+ contextUsageUnknownHint: "This model has no registered context window; occupancy percentage is unavailable.",
5086
+ contextUsageLoading: "Loading\u2026",
5087
+ contextUsageCompact: "Compact context",
4922
5088
  contextOccupancyEstimated: " (estimated)",
4923
5089
  dialogCumulative: "Conversation total",
4924
5090
  dialogUsageTokensSection: "Session tokens",
@@ -5447,9 +5613,18 @@ var chat_locale_default = {
5447
5613
  usageInputLabel: "\u8F93\u5165",
5448
5614
  usageOutputLabel: "\u8F93\u51FA",
5449
5615
  contextWindow: "\u4E0A\u4E0B\u6587\u7A97\u53E3",
5450
- contextWindowUnknown: "\u4E0A\u4E0B\u6587\u7A97\u53E3\u672A\u77E5",
5451
- contextOccupancyPercent: "\u4E0A\u4E0B\u6587\u5360\u7528 {{percent}}%",
5452
- contextOccupancy: "\u4E0A\u4E0B\u6587\u5360\u7528",
5616
+ contextUsageKnownChip: "{{percent}}%",
5617
+ contextUsageEstimatedChip: "~{{percent}}%",
5618
+ contextUsageUnknownChip: "{{tokens}}",
5619
+ contextUsageUnknownChipEstimated: "\u2248{{tokens}}",
5620
+ contextUsageLoadingChip: "\u2014",
5621
+ contextUsageChipLabel: "\u4E0A\u4E0B\u6587\u5360\u7528 {{usage}}",
5622
+ contextUsageKnownPanel: "{{tokens}} / {{window}} \xB7 {{percent}}%",
5623
+ contextUsageUnknownPanel: "{{tokens}} \xB7 \u7A97\u53E3\u672A\u77E5",
5624
+ contextUsageUnknownPanelEstimated: "\u2248{{tokens}} \xB7 \u7A97\u53E3\u672A\u77E5",
5625
+ contextUsageUnknownHint: "\u8BE5\u6A21\u578B\u672A\u767B\u8BB0\u4E0A\u4E0B\u6587\u7A97\u53E3\uFF0C\u65E0\u6CD5\u8BA1\u7B97\u5360\u6BD4",
5626
+ contextUsageLoading: "\u8BFB\u53D6\u4E2D\u2026",
5627
+ contextUsageCompact: "\u538B\u7F29\u4E0A\u4E0B\u6587",
5453
5628
  contextOccupancyEstimated: "\uFF08\u4F30\u7B97\uFF09",
5454
5629
  dialogCumulative: "\u672C\u5BF9\u8BDD\u7D2F\u8BA1",
5455
5630
  dialogUsageTokensSection: "\u672C\u4F1A\u8BDD token",
@@ -5967,9 +6142,18 @@ var chat_locale_default = {
5967
6142
  usageInputLabel: "\u8F38\u5165",
5968
6143
  usageOutputLabel: "\u8F38\u51FA",
5969
6144
  contextWindow: "\u4E0A\u4E0B\u6587\u8996\u7A97",
5970
- contextWindowUnknown: "\u4E0A\u4E0B\u6587\u8996\u7A97\u672A\u77E5",
5971
- contextOccupancyPercent: "\u4E0A\u4E0B\u6587\u4F54\u7528 {{percent}}%",
5972
- contextOccupancy: "\u4E0A\u4E0B\u6587\u4F54\u7528",
6145
+ contextUsageKnownChip: "{{percent}}%",
6146
+ contextUsageEstimatedChip: "~{{percent}}%",
6147
+ contextUsageUnknownChip: "{{tokens}}",
6148
+ contextUsageUnknownChipEstimated: "\u2248{{tokens}}",
6149
+ contextUsageLoadingChip: "\u2014",
6150
+ contextUsageChipLabel: "\u4E0A\u4E0B\u6587\u4F54\u7528 {{usage}}",
6151
+ contextUsageKnownPanel: "{{tokens}} / {{window}} \xB7 {{percent}}%",
6152
+ contextUsageUnknownPanel: "{{tokens}} \xB7 \u8996\u7A97\u672A\u77E5",
6153
+ contextUsageUnknownPanelEstimated: "\u2248{{tokens}} \xB7 \u8996\u7A97\u672A\u77E5",
6154
+ contextUsageUnknownHint: "\u8A72\u6A21\u578B\u672A\u767B\u8A18\u4E0A\u4E0B\u6587\u8996\u7A97\uFF0C\u7121\u6CD5\u8A08\u7B97\u4F54\u6BD4",
6155
+ contextUsageLoading: "\u8B80\u53D6\u4E2D\u2026",
6156
+ contextUsageCompact: "\u58D3\u7E2E\u4E0A\u4E0B\u6587",
5973
6157
  contextOccupancyEstimated: "\uFF08\u4F30\u7B97\uFF09",
5974
6158
  dialogCumulative: "\u672C\u5C0D\u8A71\u7D2F\u8A08",
5975
6159
  dialogUsageTokensSection: "\u672C\u6703\u8A71 token",
@@ -6486,9 +6670,18 @@ var chat_locale_default = {
6486
6670
  usageInputLabel: "\u5165\u529B",
6487
6671
  usageOutputLabel: "\u51FA\u529B",
6488
6672
  contextWindow: "\u30B3\u30F3\u30C6\u30AD\u30B9\u30C8\u30A6\u30A3\u30F3\u30C9\u30A6",
6489
- contextWindowUnknown: "\u30B3\u30F3\u30C6\u30AD\u30B9\u30C8\u30A6\u30A3\u30F3\u30C9\u30A6\u4E0D\u660E",
6490
- contextOccupancyPercent: "\u30B3\u30F3\u30C6\u30AD\u30B9\u30C8\u4F7F\u7528\u7387 {{percent}}%",
6491
- contextOccupancy: "\u30B3\u30F3\u30C6\u30AD\u30B9\u30C8\u4F7F\u7528\u91CF",
6673
+ contextUsageKnownChip: "{{percent}}%",
6674
+ contextUsageEstimatedChip: "~{{percent}}%",
6675
+ contextUsageUnknownChip: "{{tokens}}",
6676
+ contextUsageUnknownChipEstimated: "\u2248{{tokens}}",
6677
+ contextUsageLoadingChip: "\u2014",
6678
+ contextUsageChipLabel: "\u30B3\u30F3\u30C6\u30AD\u30B9\u30C8\u4F7F\u7528\u91CF {{usage}}",
6679
+ contextUsageKnownPanel: "{{tokens}} / {{window}} \xB7 {{percent}}%",
6680
+ contextUsageUnknownPanel: "{{tokens}} \xB7 \u30A6\u30A3\u30F3\u30C9\u30A6\u4E0D\u660E",
6681
+ contextUsageUnknownPanelEstimated: "\u2248{{tokens}} \xB7 \u30A6\u30A3\u30F3\u30C9\u30A6\u4E0D\u660E",
6682
+ contextUsageUnknownHint: "\u3053\u306E\u30E2\u30C7\u30EB\u306E\u30B3\u30F3\u30C6\u30AD\u30B9\u30C8\u30A6\u30A3\u30F3\u30C9\u30A6\u306F\u672A\u767B\u9332\u306E\u305F\u3081\u3001\u4F7F\u7528\u7387\u3092\u8A08\u7B97\u3067\u304D\u307E\u305B\u3093\u3002",
6683
+ contextUsageLoading: "\u8AAD\u307F\u8FBC\u307F\u4E2D\u2026",
6684
+ contextUsageCompact: "\u30B3\u30F3\u30C6\u30AD\u30B9\u30C8\u3092\u5727\u7E2E",
6492
6685
  contextOccupancyEstimated: "\uFF08\u63A8\u5B9A\uFF09",
6493
6686
  dialogCumulative: "\u3053\u306E\u4F1A\u8A71\u306E\u7D2F\u8A08",
6494
6687
  dialogUsageTokensSection: "\u30BB\u30C3\u30B7\u30E7\u30F3 token",
@@ -7029,6 +7222,10 @@ var space_locale_default = {
7029
7222
  unpin: "Unpin",
7030
7223
  favorite: "Favorite",
7031
7224
  unfavorite: "Unfavorite",
7225
+ quickAddToRail: "Add to Rail Shortcut",
7226
+ quickRemoveFromRail: "Remove from Rail Shortcut",
7227
+ quickMoveRailUp: "Move Rail Shortcut Up",
7228
+ quickMoveRailDown: "Move Rail Shortcut Down",
7032
7229
  pinUpdated: "Pin status updated",
7033
7230
  pinUpdateFailed: "Failed to update pin status",
7034
7231
  moveToSpace: "Move to Space",
@@ -7351,6 +7548,10 @@ var space_locale_default = {
7351
7548
  unpin: "\u53D6\u6D88\u7F6E\u9876",
7352
7549
  favorite: "\u6536\u85CF",
7353
7550
  unfavorite: "\u53D6\u6D88\u6536\u85CF",
7551
+ quickAddToRail: "\u52A0\u5165\u5FEB\u6377",
7552
+ quickRemoveFromRail: "\u4ECE\u5FEB\u6377\u79FB\u9664",
7553
+ quickMoveRailUp: "\u5FEB\u6377\u4E0A\u79FB",
7554
+ quickMoveRailDown: "\u5FEB\u6377\u4E0B\u79FB",
7354
7555
  pinUpdated: "\u7F6E\u9876\u72B6\u6001\u5DF2\u66F4\u65B0",
7355
7556
  pinUpdateFailed: "\u7F6E\u9876\u72B6\u6001\u66F4\u65B0\u5931\u8D25",
7356
7557
  moveToSpace: "\u79FB\u52A8\u5230\u7A7A\u95F4",
@@ -7672,6 +7873,10 @@ var space_locale_default = {
7672
7873
  unpin: "\u53D6\u6D88\u7F6E\u9802",
7673
7874
  favorite: "\u6536\u85CF",
7674
7875
  unfavorite: "\u53D6\u6D88\u6536\u85CF",
7876
+ quickAddToRail: "\u52A0\u5165\u5FEB\u6377",
7877
+ quickRemoveFromRail: "\u5F9E\u5FEB\u6377\u79FB\u9664",
7878
+ quickMoveRailUp: "\u5FEB\u6377\u4E0A\u79FB",
7879
+ quickMoveRailDown: "\u5FEB\u6377\u4E0B\u79FB",
7675
7880
  pinUpdated: "\u7F6E\u9802\u72C0\u614B\u5DF2\u66F4\u65B0",
7676
7881
  pinUpdateFailed: "\u7F6E\u9802\u72C0\u614B\u66F4\u65B0\u5931\u6557",
7677
7882
  moveToSpace: "\u79FB\u52D5\u5230\u7A7A\u9593",
@@ -7994,6 +8199,10 @@ var space_locale_default = {
7994
8199
  unpin: "\u30D4\u30F3\u7559\u3081\u89E3\u9664",
7995
8200
  favorite: "\u304A\u6C17\u306B\u5165\u308A",
7996
8201
  unfavorite: "\u304A\u6C17\u306B\u5165\u308A\u89E3\u9664",
8202
+ quickAddToRail: "\u30EC\u30FC\u30EB\u306B\u8FFD\u52A0",
8203
+ quickRemoveFromRail: "\u30EC\u30FC\u30EB\u304B\u3089\u524A\u9664",
8204
+ quickMoveRailUp: "\u30EC\u30FC\u30EB\u5185\u3067\u4E0A\u3078\u79FB\u52D5",
8205
+ quickMoveRailDown: "\u30EC\u30FC\u30EB\u5185\u3067\u4E0B\u3078\u79FB\u52D5",
7997
8206
  pinUpdated: "\u30D4\u30F3\u7559\u3081\u306E\u72B6\u614B\u3092\u66F4\u65B0\u3057\u307E\u3057\u305F",
7998
8207
  pinUpdateFailed: "\u30D4\u30F3\u7559\u3081\u306E\u72B6\u614B\u306E\u66F4\u65B0\u306B\u5931\u6557\u3057\u307E\u3057\u305F",
7999
8208
  moveToSpace: "\u30B9\u30DA\u30FC\u30B9\u306B\u79FB\u52D5",
@@ -8239,12 +8448,16 @@ var updateDialogSummaryAction = async (args, thunkApi) => {
8239
8448
  const dialogConfig = selectById(state, dialogKey);
8240
8449
  if (!dialogConfig) return;
8241
8450
  let contextWindow = DEFAULT_CONTEXT_WINDOW;
8242
- if (dialogConfig.cybots && dialogConfig.cybots.length > 0) {
8243
- const agentId = dialogConfig.cybots[0];
8244
- const agent = selectById(state, agentId);
8245
- if (agent?.model) {
8246
- contextWindow = getModelContextWindow(agent.model);
8247
- }
8451
+ {
8452
+ const agentId = getActiveDialogAgentId(dialogConfig);
8453
+ const agent = agentId ? selectById(state, agentId) : void 0;
8454
+ const resolvedAgent = agent && agentId ? applyBuiltinAgentRuntimeOverride(agentId, agent) : agent;
8455
+ contextWindow = resolveAgentContextWindow({
8456
+ model: resolvedAgent?.model,
8457
+ provider: resolvedAgent?.provider,
8458
+ agentKey: agentId,
8459
+ agentName: resolvedAgent?.name
8460
+ }) ?? DEFAULT_CONTEXT_WINDOW;
8248
8461
  }
8249
8462
  const allMsgs = preFetchedMessages || getMessagesForDialogFromState(state, dialogId);
8250
8463
  const plan = planCompression({
@@ -8900,89 +9113,6 @@ var buildPersonalizationDialogPolicyContext = () => [
8900
9113
  "\u9664\u975E\u7528\u6237\u660E\u786E\u8981\u6C42\uFF0C\u5426\u5219\u4E0D\u8981\u521B\u5EFA\u6587\u6863\uFF0C\u4E0D\u8981\u521B\u5EFA\u6216\u4FEE\u6539\u4EFB\u4F55 agent\u3002"
8901
9114
  ].join("\n");
8902
9115
 
8903
- // packages/agent-runtime/builtinPlatformAgentRoute.ts
8904
- function resolveBuiltinAgentRuntimeFields(agentKey) {
8905
- if (!isBuiltinPlatformAgentKey(agentKey)) return null;
8906
- const entry = builtinAgentCatalogEntryById(parseBuiltinPlatformAgentId(agentKey));
8907
- if (!entry) return null;
8908
- return { provider: entry.provider, model: entry.model };
8909
- }
8910
-
8911
- // packages/agent-runtime/builtinPlatformAgentConfigs.ts
8912
- function buildConfig(e2) {
8913
- const key = publicAgentKey(e2.id);
8914
- const rawRecord = {
8915
- dbKey: key,
8916
- isPublic: true,
8917
- provider: e2.provider,
8918
- model: e2.model,
8919
- apiSource: e2.apiSource ?? "platform",
8920
- useServerProxy: e2.useServerProxy ?? true
8921
- };
8922
- if (e2.hasImageOutput) rawRecord.hasImageOutput = true;
8923
- if (e2.imageModel) rawRecord.imageModel = e2.imageModel;
8924
- if (e2.imageWorkflow) rawRecord.imageWorkflow = e2.imageWorkflow;
8925
- if (e2.imageConfig) rawRecord.imageConfig = e2.imageConfig;
8926
- return {
8927
- key,
8928
- name: e2.name,
8929
- provider: e2.provider,
8930
- model: e2.model,
8931
- apiSource: e2.apiSource ?? "platform",
8932
- useServerProxy: e2.useServerProxy ?? true,
8933
- rawRecord
8934
- };
8935
- }
8936
- var BUILTIN_PLATFORM_AGENT_CONFIGS = Object.fromEntries(
8937
- builtinRuntimeFallbackEntries().map((e2) => [publicAgentKey(e2.id), buildConfig(e2)])
8938
- );
8939
- function resolveBuiltinPlatformAgentConfig(agentRef) {
8940
- return BUILTIN_PLATFORM_AGENT_CONFIGS[agentRef] ?? null;
8941
- }
8942
- function resolveBuiltinPlatformAgentRecord(agentRef) {
8943
- const config = resolveBuiltinPlatformAgentConfig(agentRef);
8944
- if (!config) return null;
8945
- return {
8946
- ...config.rawRecord,
8947
- dbKey: agentRef,
8948
- ...config.name ? { name: config.name } : {}
8949
- };
8950
- }
8951
- var BUILTIN_RUNTIME_EXTRA_OVERRIDES = {
8952
- [BUILTIN_NOLO_AGENT_KEY]: { reasoningEffort: "max" }
8953
- };
8954
- function applyBuiltinAgentRuntimeOverride(agentKey, record) {
8955
- const fields = resolveBuiltinAgentRuntimeFields(agentKey);
8956
- if (!fields) return record;
8957
- const extraFields = BUILTIN_RUNTIME_EXTRA_OVERRIDES[agentKey];
8958
- const extraNeedsOverride = (target) => {
8959
- if (extraFields == null || target == null || typeof target !== "object") {
8960
- return false;
8961
- }
8962
- const flat = target;
8963
- return Object.entries(extraFields).some(([key, value]) => flat[key] !== value);
8964
- };
8965
- const current = record;
8966
- const rawNeedsOverride = current.rawRecord != null && (current.rawRecord.provider !== fields.provider || current.rawRecord.model !== fields.model || extraNeedsOverride(current.rawRecord));
8967
- if (current.provider === fields.provider && current.model === fields.model && !rawNeedsOverride && !extraNeedsOverride(record)) {
8968
- return record;
8969
- }
8970
- return {
8971
- ...record,
8972
- provider: fields.provider,
8973
- model: fields.model,
8974
- ...extraFields ?? {},
8975
- ...current.rawRecord ? {
8976
- rawRecord: {
8977
- ...current.rawRecord,
8978
- provider: fields.provider,
8979
- model: fields.model,
8980
- ...extraFields ?? {}
8981
- }
8982
- } : {}
8983
- };
8984
- }
8985
-
8986
9116
  // packages/chat/dialog/dialogAgentPolicy.ts
8987
9117
  var resolveDialogAgentMode = (dialog) => {
8988
9118
  if (dialog?.agentMode === "auto") return "auto";
@@ -10934,7 +11064,7 @@ var messageSlice = createSliceWithThunks({
10934
11064
  runtimeOptions: args.runtimeOptions
10935
11065
  });
10936
11066
  if (agentKeyToUse) {
10937
- const { streamAgentChatTurn } = await import("./agentSlice-E3XS5FTQ.js");
11067
+ const { streamAgentChatTurn } = await import("./agentSlice-VRAPG6CH.js");
10938
11068
  await dispatch(
10939
11069
  streamAgentChatTurn({
10940
11070
  agentKey: agentKeyToUse,
@@ -13689,7 +13819,7 @@ var deleteOwnedDialogAttachments = async (args) => {
13689
13819
  metadataReadFailures
13690
13820
  });
13691
13821
  if (!plan.deleteCandidates.length) return plan;
13692
- const { deleteFileAction } = await import("./deleteFile-EW6QNRRT.js");
13822
+ const { deleteFileAction } = await import("./deleteFile-KYWEMNFX.js");
13693
13823
  for (const candidate of plan.deleteCandidates) {
13694
13824
  if (candidate.fileDbKey) {
13695
13825
  await deleteFileAction(candidate.fileDbKey, args.thunkApi);
@@ -13751,7 +13881,7 @@ var deleteDialogThunk = async (payload, thunkApi) => {
13751
13881
  }
13752
13882
  if (isCurrentDialog) {
13753
13883
  await thunkApi.dispatch(resetMsgs());
13754
- const { clearPendingAttachments: clearPendingAttachments2 } = await import("./dialogSlice-64S3J6CP.js");
13884
+ const { clearPendingAttachments: clearPendingAttachments2 } = await import("./dialogSlice-ERMZYMS6.js");
13755
13885
  dispatch(clearPendingAttachments2());
13756
13886
  }
13757
13887
  return { dialogKey, isCurrentDialog, attachmentPlan };
@@ -13759,39 +13889,39 @@ var deleteDialogThunk = async (payload, thunkApi) => {
13759
13889
 
13760
13890
  // packages/chat/dialog/dialogSlice.ts
13761
13891
  var runCreateDialogAction = async (args, thunkApi) => {
13762
- const { createDialogAction } = await import("./createDialogAction-2NFGFBXW.js");
13892
+ const { createDialogAction } = await import("./createDialogAction-VLLBRD52.js");
13763
13893
  return createDialogAction(args, thunkApi);
13764
13894
  };
13765
13895
  var runCreateAgentAutomationAction = async (args, thunkApi) => {
13766
- const { createAgentAutomationAction } = await import("./createAgentAutomationAction-T2YFJ6MY.js");
13896
+ const { createAgentAutomationAction } = await import("./createAgentAutomationAction-LW26KIBP.js");
13767
13897
  return createAgentAutomationAction(args, thunkApi);
13768
13898
  };
13769
13899
  var runUpdateDialogTitleAction = async (args, thunkApi) => {
13770
- const { updateDialogTitleAction } = await import("./updateDialogTitleAction-SX53FZWO.js");
13900
+ const { updateDialogTitleAction } = await import("./updateDialogTitleAction-Z4WNUH6Y.js");
13771
13901
  return updateDialogTitleAction(args, thunkApi);
13772
13902
  };
13773
13903
  var runAddDialogAgentAction = async (args, thunkApi) => {
13774
- const { addDialogAgentAction } = await import("./addDialogAgentAction-FDPBU6K6.js");
13904
+ const { addDialogAgentAction } = await import("./addDialogAgentAction-4RJYUSIK.js");
13775
13905
  return addDialogAgentAction(args, thunkApi);
13776
13906
  };
13777
13907
  var runRemoveDialogAgentAction = async (args, thunkApi) => {
13778
- const { removeDialogAgentAction } = await import("./removeDialogAgentAction-6X63HMI3.js");
13908
+ const { removeDialogAgentAction } = await import("./removeDialogAgentAction-376XSUP2.js");
13779
13909
  return removeDialogAgentAction(args, thunkApi);
13780
13910
  };
13781
13911
  var runSetPrimaryDialogAgentAction = async (args, thunkApi) => {
13782
- const { setPrimaryDialogAgentAction } = await import("./setPrimaryDialogAgentAction-EGBAMREH.js");
13912
+ const { setPrimaryDialogAgentAction } = await import("./setPrimaryDialogAgentAction-537QFGW3.js");
13783
13913
  return setPrimaryDialogAgentAction(args, thunkApi);
13784
13914
  };
13785
13915
  var runSwitchDialogAgentAction = async (args, thunkApi) => {
13786
- const { switchDialogAgentAction } = await import("./switchDialogAgentAction-YBKTD6DO.js");
13916
+ const { switchDialogAgentAction } = await import("./switchDialogAgentAction-CSO6AKRL.js");
13787
13917
  return switchDialogAgentAction(args, thunkApi);
13788
13918
  };
13789
13919
  var runSetDialogExtraReferencesAction = async (args, thunkApi) => {
13790
- const { setDialogExtraReferencesAction } = await import("./setDialogExtraReferencesAction-4MAYKKYW.js");
13920
+ const { setDialogExtraReferencesAction } = await import("./setDialogExtraReferencesAction-QBDSH63D.js");
13791
13921
  return setDialogExtraReferencesAction(args, thunkApi);
13792
13922
  };
13793
13923
  var runHandleSendMessageAction = async (args, thunkApi) => {
13794
- const { handleSendMessageAction } = await import("./handleSendMessageAction-TOKA7ED7.js");
13924
+ const { handleSendMessageAction } = await import("./handleSendMessageAction-2XCOZPXY.js");
13795
13925
  return handleSendMessageAction(args, thunkApi);
13796
13926
  };
13797
13927
  function clearDialogState() {
@@ -13804,7 +13934,7 @@ var createPageAndAddReference = createAsyncThunk(
13804
13934
  async (payload, { dispatch, getState, rejectWithValue }) => {
13805
13935
  const { slateData, jsonData, title, type, fileId, groupId, dialogKey } = payload;
13806
13936
  try {
13807
- const { createDocState } = await import("./docStore-NIP7OO4I.js");
13937
+ const { createDocState } = await import("./docStore-HXKI6W5D.js");
13808
13938
  const pageKey = await createDocState(
13809
13939
  { slateData, title },
13810
13940
  { dispatch, getState }
@@ -13974,18 +14104,23 @@ export {
13974
14104
  uiAskChoiceFunc,
13975
14105
  parseUiAskChoiceContent,
13976
14106
  API_REPORTED_COST_MULTIPLIER,
14107
+ estimateMessagesTokens,
14108
+ historyTokensBeforeLatestAssistant,
14109
+ resolveOccupancy,
14110
+ resolveOccupancyWindow,
14111
+ resolveAgentContextWindow,
13977
14112
  runtime_default,
13978
14113
  toolResultNeedsUserConfirmation,
13979
14114
  isAssistantToolStub,
13980
14115
  fetchAndCacheMessages,
14116
+ resolveBuiltinPlatformAgentConfig,
14117
+ resolveBuiltinPlatformAgentRecord,
14118
+ applyBuiltinAgentRuntimeOverride,
13981
14119
  toast,
13982
14120
  buildDatabaseFileContentUrl,
13983
14121
  normalizeAppRouteId,
13984
14122
  PERSONALIZATION_DIALOG_CATEGORY,
13985
14123
  buildPersonalizationDialogPolicyContext,
13986
- resolveBuiltinPlatformAgentConfig,
13987
- resolveBuiltinPlatformAgentRecord,
13988
- applyBuiltinAgentRuntimeOverride,
13989
14124
  resolveDialogRuntimeAgentKey,
13990
14125
  resolveHandleSendMessageContext,
13991
14126
  estimateMissingUsage,