nolo-cli 0.54.0 → 0.61.0-alpha.3

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 (158) hide show
  1. package/README.md +3 -3
  2. package/{_executeModel-OPTKYHJA.js → _executeModel-R26QYY66.js} +50 -46
  3. package/{action-ORXWW2ZG.js → action-76JX3JX3.js} +7 -6
  4. package/{addContentAction-53BZ34AE.js → addContentAction-V3NAZRTJ.js} +6 -5
  5. package/{addDialogAgentAction-JRYUS54Y.js → addDialogAgentAction-RZOAF46K.js} +5 -4
  6. package/{agentDeleteCommand-FJIWU2BS.js → agentDeleteCommand-6GNQA4J4.js} +30 -27
  7. package/{agentEmailCommands-CE32L43B.js → agentEmailCommands-HH67CYKD.js} +61 -57
  8. package/{agentGrantCommands-2LEZDADN.js → agentGrantCommands-R3VQEZJR.js} +1 -1
  9. package/{agentListCommands-VJNKULIK.js → agentListCommands-23XW3OPZ.js} +61 -31
  10. package/{agentMachineCommands-HCJ3WQXL.js → agentMachineCommands-HXHASEWO.js} +31 -28
  11. package/{agentPullCommand-M552CYSI.js → agentPullCommand-N7L2CT7L.js} +2 -2
  12. package/{agentRecordCommands-QFWERED4.js → agentRecordCommands-UHTQJVGC.js} +59 -55
  13. package/{agentRunCommand-G3GQMUNN.js → agentRunCommand-OAMT77EX.js} +63 -59
  14. package/{agentRunControl-INKFDXDA.js → agentRunControl-WECMOO6O.js} +11 -6
  15. package/{agentRuntimeLocal-K327ELSL.js → agentRuntimeLocal-QBK4H3T2.js} +26 -23
  16. package/{agentSlice-ODKF4J6M.js → agentSlice-7XJH5WQF.js} +8 -7
  17. package/{appDeleteCommands-XUXMFDI4.js → appDeleteCommands-AX2O6VDV.js} +30 -27
  18. package/{appDeployCommands-37F4GPCU.js → appDeployCommands-L5ZR26CB.js} +30 -27
  19. package/{appDeployStatusCommands-WSPU7TUK.js → appDeployStatusCommands-5HQHELRA.js} +30 -27
  20. package/{appGetCommands-YLOBA3EM.js → appGetCommands-HVSYOS57.js} +30 -27
  21. package/{appListCommands-UD62R5ME.js → appListCommands-XV2FPTWX.js} +30 -27
  22. package/{authCommand-OK6HLHGS.js → authCommand-WOTWLJNF.js} +35 -29
  23. package/{authCommands-2DUIUEMT.js → authCommands-ILTBI6JV.js} +7 -5
  24. package/{chatQueueReduxAdapter-TV2TUOQS.js → chatQueueReduxAdapter-F3R253JE.js} +20 -18
  25. package/{chunk-HPW5MNDQ.js → chunk-22BTGNSP.js} +113 -57
  26. package/{chunk-UNZDCI3O.js → chunk-2KDR4CWE.js} +35 -4
  27. package/{chunk-3ZTR7ZO4.js → chunk-2PGGC63K.js} +1 -1
  28. package/{chunk-EA5OYZVD.js → chunk-37XDGCY7.js} +1 -1
  29. package/chunk-3BLB7QKO.js +433 -0
  30. package/{chunk-CS6TCJ7E.js → chunk-3JQ2NRYU.js} +30 -7
  31. package/{chunk-3LKZRP7E.js → chunk-3QGUVVX5.js} +2 -2
  32. package/{chunk-SSXTSPSG.js → chunk-45YO6H7P.js} +71 -30
  33. package/{chunk-YLCUU3WM.js → chunk-4NJEIGBQ.js} +5 -5
  34. package/{chunk-K4NISKOR.js → chunk-5ZYA4JJ3.js} +47 -17
  35. package/{chunk-6HIGYUBQ.js → chunk-6XIE5ZGI.js} +1 -1
  36. package/{chunk-3Y2K5O2R.js → chunk-7A3RRUCQ.js} +125 -40
  37. package/{chunk-6COJEAYH.js → chunk-7KELZLC2.js} +44 -37
  38. package/chunk-AETZ7AD6.js +274 -0
  39. package/chunk-BFU6C242.js +66 -0
  40. package/{chunk-IA3A5373.js → chunk-C3FZR5EC.js} +1 -1
  41. package/{chunk-IWUMSAQF.js → chunk-CJCJF5XB.js} +26 -3
  42. package/{chunk-UGBHDMHI.js → chunk-CP7VIDZ7.js} +1 -1
  43. package/{chunk-TR4DXUYX.js → chunk-CQ2OZMLQ.js} +1181 -737
  44. package/{chunk-JON2PHYT.js → chunk-CTCW7U7N.js} +1 -1
  45. package/{chunk-7NYDJAQ7.js → chunk-DNNSCSA2.js} +5 -5
  46. package/{chunk-NI2BS6UD.js → chunk-DWUCB2A3.js} +1 -1
  47. package/{chunk-FJHMLRDQ.js → chunk-DWYSDNOH.js} +22 -28
  48. package/{chunk-AA564GBL.js → chunk-E3YVTQWT.js} +2 -2
  49. package/chunk-E4MARS3Q.js +114 -0
  50. package/{chunk-75MSWWUE.js → chunk-E6RGHPDR.js} +5 -3
  51. package/chunk-EDKF7RX4.js +30 -0
  52. package/{chunk-TC6P4NDR.js → chunk-F44FAXP2.js} +6 -6
  53. package/{chunk-SYYUU7EV.js → chunk-FHAGENAS.js} +2 -3
  54. package/{chunk-NJUQBYFJ.js → chunk-FKFMIBTT.js} +3 -1
  55. package/{chunk-INZZJSQF.js → chunk-FZGV4FGK.js} +24 -12
  56. package/{chunk-6HDYSFLO.js → chunk-GSXDRMDO.js} +3 -3
  57. package/{chunk-AUVFJGPC.js → chunk-JX5PJCWS.js} +7 -5
  58. package/{chunk-LYGNQHUW.js → chunk-JYYZCK2Z.js} +2 -4
  59. package/{chunk-EY7V7REW.js → chunk-KHCLMKZZ.js} +6 -280
  60. package/{chunk-EJE33XNR.js → chunk-KSCXMC6U.js} +1521 -565
  61. package/{chunk-XOJRZUPF.js → chunk-KWSQR2KK.js} +14 -29
  62. package/{chunk-2WBFJHQA.js → chunk-L7B47JXR.js} +34 -39
  63. package/{chunk-EICIFHVS.js → chunk-LAFC3B2I.js} +1 -1
  64. package/{chunk-N4JKMCY3.js → chunk-LJKICKVC.js} +2 -2
  65. package/chunk-M3JEW6N6.js +193 -0
  66. package/{chunk-LRGKOI5Y.js → chunk-MBOEV4L2.js} +7 -3
  67. package/{chunk-SVDMVX4G.js → chunk-MMZ6ZTVO.js} +112 -73
  68. package/{chunk-JDSUTNYY.js → chunk-MP64VFGD.js} +2 -2
  69. package/{chunk-NFLA6GSU.js → chunk-MXUDQZXQ.js} +44 -5
  70. package/chunk-N4G4PKQ6.js +23 -0
  71. package/{chunk-WQHGJHAL.js → chunk-N6HLMLKE.js} +732 -726
  72. package/{chunk-YQBXOHE6.js → chunk-NO42UD73.js} +1 -1
  73. package/{chunk-MLEZPE3U.js → chunk-NRRPKMM7.js} +4 -4
  74. package/{chunk-KXKQO4Q6.js → chunk-NTW5GWDM.js} +58 -1
  75. package/chunk-ONXOABJR.js +215 -0
  76. package/{chunk-TY3ADTX5.js → chunk-OZX2IPKM.js} +7 -2
  77. package/{chunk-Q4XZVZPN.js → chunk-P7OOB7QP.js} +1 -1
  78. package/{chunk-XIJZOCSP.js → chunk-PEZJEQAO.js} +1 -1
  79. package/{chunk-SWJGJMTW.js → chunk-PQDIDWGX.js} +1 -1
  80. package/chunk-PSCNXBYA.js +11 -0
  81. package/{chunk-BY2FF2C4.js → chunk-QEFJJS2I.js} +55 -73
  82. package/{chunk-BG7J6Y5X.js → chunk-QEW2MFDQ.js} +1 -1
  83. package/{chunk-KLIBF3BY.js → chunk-RDBARW6T.js} +8 -3
  84. package/{chunk-ZVOHVJI3.js → chunk-RJ2SAFB5.js} +82 -35
  85. package/{chunk-MYMBBB6Q.js → chunk-RVWRKFUB.js} +5 -3
  86. package/{chunk-43CXXVJD.js → chunk-RXX4GDIH.js} +1 -1
  87. package/chunk-SEJ5OS6F.js +49 -0
  88. package/{chunk-JXIP6ZWH.js → chunk-SKIRVYEI.js} +18 -5
  89. package/{chunk-SAJSBPI2.js → chunk-SOJM57FX.js} +5 -2
  90. package/{chunk-EKLRRZIN.js → chunk-SPAQ4PVV.js} +0 -5
  91. package/{chunk-RHMDMTDK.js → chunk-SYNKICCB.js} +2 -2
  92. package/{chunk-YBFJQC2M.js → chunk-TBHAHL33.js} +65 -42
  93. package/{chunk-L7NG2M6H.js → chunk-TRV2MIDW.js} +89 -74
  94. package/{chunk-5UAYZEXO.js → chunk-UZPQSVM6.js} +1 -1
  95. package/{chunk-7FAS3NEF.js → chunk-VAKVNHK5.js} +19 -15
  96. package/{chunk-UOWXD4VN.js → chunk-VHO3TMQZ.js} +336 -244
  97. package/{chunk-SVC3GGUA.js → chunk-VMWYBIXG.js} +7 -5
  98. package/{chunk-ZHXJ6M7T.js → chunk-W7XHHYWM.js} +4 -0
  99. package/{chunk-UR66XPVF.js → chunk-XAVSS3KE.js} +21 -3
  100. package/{chunk-A65UV3M5.js → chunk-XOKOSO35.js} +10 -19
  101. package/{chunk-VZMUOPYG.js → chunk-XTJTN3RW.js} +46 -3
  102. package/{chunk-T5HJEUQN.js → chunk-YCDWJX45.js} +1 -1
  103. package/{chunk-BBTN4NQD.js → chunk-Z4QSJILV.js} +85 -13
  104. package/{chunk-5FCIPEKT.js → chunk-Z5MHFBJZ.js} +1051 -926
  105. package/{chunk-O5FLGN2L.js → chunk-ZRSJ3JEH.js} +6 -2
  106. package/{cliExecutor-BBUVQU4L.js → cliExecutor-HG3S345O.js} +1 -1
  107. package/{codingSkills-BCQXRZOI.js → codingSkills-TKROLCBA.js} +4 -3
  108. package/{contentThunks-KNI6VXLT.js → contentThunks-OZPK5B4Z.js} +21 -19
  109. package/{cooldownCommands-GI5NNWGL.js → cooldownCommands-BSCH2W7P.js} +2 -2
  110. package/{createAgentAutomationAction-OK4L33KF.js → createAgentAutomationAction-LCIBGE5T.js} +23 -21
  111. package/{createDialogAction-JDSMY4AY.js → createDialogAction-JPJZMHJE.js} +25 -22
  112. package/{createPageAction-T7RA3HCG.js → createPageAction-6P2WLNHO.js} +26 -23
  113. package/{dbSlice-TVX6SN2T.js → dbSlice-IBVOBVMS.js} +5 -4
  114. package/{deleteFile-JYKRT7C3.js → deleteFile-FWP2PSBG.js} +3 -2
  115. package/{dialogCommands-UQZYWOOV.js → dialogCommands-WAFKC3KK.js} +30 -27
  116. package/{dialogSlice-TYW2G7IL.js → dialogSlice-R5RZHFTU.js} +20 -18
  117. package/{docCreateCommands-OA6HZBWO.js → docCreateCommands-GHGB42S7.js} +32 -28
  118. package/{docDeleteCommands-KBB3YQI2.js → docDeleteCommands-Y5I7ZEX4.js} +33 -29
  119. package/{docReadCommands-ZLMFVC67.js → docReadCommands-BMXM6J7T.js} +32 -28
  120. package/{docStore-2URPBVCS.js → docStore-DKWZ6XJ5.js} +6 -5
  121. package/{docUpdateCommands-HMH5KUON.js → docUpdateCommands-QNABH3M2.js} +32 -28
  122. package/{getPricing-RFOPUWHY.js → getPricing-NM3NUTAS.js} +4 -4
  123. package/handleSendMessageAction-UQGKM4UX.js +675 -0
  124. package/index.js +79 -88
  125. package/{lib-2ZTNRXR4.js → lib-FRRS27KN.js} +63 -28
  126. package/{localRuntimeAuthority-KQDAE64E.js → localRuntimeAuthority-R5UBODT3.js} +6 -4
  127. package/{localRuntimeDb-PF7CFKDL.js → localRuntimeDb-P37ZTX55.js} +1 -1
  128. package/{machineCommands-RK6L7ZWL.js → machineCommands-YDAIPYU5.js} +298 -80
  129. package/{machineWsRunDispatch-3X64DW2Z.js → machineWsRunDispatch-O6RM2ECT.js} +57 -53
  130. package/{memberThunks-THZYZFSN.js → memberThunks-VZI6G7YZ.js} +10 -8
  131. package/{models-JVKUEER5.js → models-FAMINFZ7.js} +2 -2
  132. package/package.json +3 -2
  133. package/{read-K4JU4MQC.js → read-2BYWW7AA.js} +3 -2
  134. package/{readDocTool-LQGR6FUN.js → readDocTool-LC3A7QTB.js} +1 -1
  135. package/{readlineWorkspace-XUFJV3RS.js → readlineWorkspace-5DP3AJWN.js} +4367 -2796
  136. package/{removeDialogAgentAction-ECHCFB7N.js → removeDialogAgentAction-SFYZXHNK.js} +8 -7
  137. package/{runAgentClientLoop-24GQ2AW6.js → runAgentClientLoop-Y6HWP2PT.js} +51 -46
  138. package/{runtimeDoctorCommands-JKTTN723.js → runtimeDoctorCommands-CROTMULY.js} +7 -5
  139. package/{setDialogExtraReferencesAction-KCVJNGMB.js → setDialogExtraReferencesAction-Q32RGFTA.js} +6 -5
  140. package/{setPrimaryDialogAgentAction-VDOBOMKC.js → setPrimaryDialogAgentAction-BFYJHUJS.js} +8 -7
  141. package/{settingSlice-VR2IJSXC.js → settingSlice-IRUU4VFB.js} +6 -5
  142. package/{skillDiscovery-2QTZINON.js → skillDiscovery-CYUCJMAG.js} +2 -1
  143. package/{spaceCommands-S5YJJXL7.js → spaceCommands-CLN45IE3.js} +33 -215
  144. package/{streamAgentChatTurn-QHKP3ABO.js → streamAgentChatTurn-6WFQJ4DY.js} +107 -74
  145. package/{switchDialogAgentAction-5L4UP7VI.js → switchDialogAgentAction-L2KOKCGG.js} +5 -4
  146. package/{tableCommands-R6WFRDYF.js → tableCommands-SUNTHAYX.js} +1 -1
  147. package/{toolApiClient-53U4UDFF.js → toolApiClient-VGYUB4P5.js} +2 -1
  148. package/{tools-SSXSTC3O.js → tools-RR53D65Q.js} +39 -35
  149. package/{tuiSummaryLlmCaller-URFJHFC5.js → tuiSummaryLlmCaller-F3DPFFZM.js} +15 -13
  150. package/{updateCommands-IYKLF3JX.js → updateCommands-AJYSD73Y.js} +2 -2
  151. package/{updateDialogTitleAction-YFYAEW3T.js → updateDialogTitleAction-WXS3AKOL.js} +23 -21
  152. package/agentSuperviseCommands-5AR3DKNN.js +0 -640
  153. package/chunk-6IGD47IC.js +0 -19
  154. package/chunk-FD36SCCD.js +0 -105
  155. package/chunk-GRFK2XP4.js +0 -230
  156. package/chunk-HJTAGT3W.js +0 -370
  157. package/chunk-SUEIAK5N.js +0 -2574
  158. package/handleSendMessageAction-GO53TY7U.js +0 -409
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  buildAgentRuntimeAgentLookupKeys,
3
3
  shouldFetchAgentRuntimeRecordRemotely
4
- } from "./chunk-ZVOHVJI3.js";
4
+ } from "./chunk-RJ2SAFB5.js";
5
5
 
6
6
  // packages/cli/client/localAgentRecords.ts
7
7
  var buildLocalAgentLookupKeys = buildAgentRuntimeAgentLookupKeys;
@@ -7,12 +7,12 @@ import {
7
7
  loadFileFromIndexedDb,
8
8
  removeAction,
9
9
  saveFileToIndexedDb
10
- } from "./chunk-SAJSBPI2.js";
10
+ } from "./chunk-SOJM57FX.js";
11
11
  import {
12
12
  readAction,
13
13
  readRequestManager,
14
14
  resolveAgentReadServers
15
- } from "./chunk-2WBFJHQA.js";
15
+ } from "./chunk-L7B47JXR.js";
16
16
  import {
17
17
  asyncThunkCreator,
18
18
  buildCreateSlice,
@@ -32,7 +32,7 @@ import {
32
32
  shouldReplaceLocalWithRemoteRecord,
33
33
  shouldReplicateLocalRecord,
34
34
  uploadToCurrentServer
35
- } from "./chunk-XOJRZUPF.js";
35
+ } from "./chunk-KWSQR2KK.js";
36
36
  import {
37
37
  fetchFromClientDb,
38
38
  fetchFromServer,
@@ -712,7 +712,7 @@ var dbSlice = createSliceWithThunks({
712
712
  // 动态 import 在调用期解析,避开 TDZ/求值顺序问题(同下方 share)。
713
713
  read: create.asyncThunk(
714
714
  async (payload, thunkApi) => {
715
- const { readAction: readAction2 } = await import("./read-K4JU4MQC.js");
715
+ const { readAction: readAction2 } = await import("./read-2BYWW7AA.js");
716
716
  return readAction2(payload, thunkApi);
717
717
  },
718
718
  {
@@ -786,7 +786,7 @@ var dbSlice = createSliceWithThunks({
786
786
  // 这里改成动态 import,运行期才解析,彻底断开这条边。
787
787
  share: create.asyncThunk(
788
788
  async (config, thunkApi) => {
789
- const { shareResourceAction } = await import("./action-ORXWW2ZG.js");
789
+ const { shareResourceAction } = await import("./action-76JX3JX3.js");
790
790
  return shareResourceAction(config, thunkApi);
791
791
  }
792
792
  ),
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  mergeAvailabilityDeadline
3
- } from "./chunk-IWUMSAQF.js";
3
+ } from "./chunk-CJCJF5XB.js";
4
4
 
5
5
  // packages/cli/credentialAvailability.ts
6
6
  import { homedir } from "node:os";
@@ -1,31 +1,31 @@
1
1
  import {
2
2
  addContentToSpace
3
- } from "./chunk-WQHGJHAL.js";
3
+ } from "./chunk-N6HLMLKE.js";
4
4
  import {
5
5
  prepareAndPersistMessage,
6
6
  uiAskChoiceFunc,
7
7
  uiAskChoiceFunctionSchema
8
- } from "./chunk-YBFJQC2M.js";
8
+ } from "./chunk-TBHAHL33.js";
9
9
  import {
10
10
  require_date_fns
11
11
  } from "./chunk-M76ECQRD.js";
12
12
  import {
13
13
  TOOL_PACKS
14
- } from "./chunk-O5FLGN2L.js";
14
+ } from "./chunk-ZRSJ3JEH.js";
15
15
  import {
16
16
  buildSkillDocMarkdown
17
- } from "./chunk-EY7V7REW.js";
17
+ } from "./chunk-AETZ7AD6.js";
18
18
  import {
19
19
  PLATFORM_HOSTED_DEEPSEEK_FLASH_MODEL,
20
20
  PLATFORM_HOSTED_KIMI_PROVIDER
21
- } from "./chunk-HPW5MNDQ.js";
21
+ } from "./chunk-22BTGNSP.js";
22
22
  import {
23
23
  read,
24
24
  readAndWait,
25
25
  removeCachedEntity,
26
26
  upsertSSREntity,
27
27
  write
28
- } from "./chunk-7NYDJAQ7.js";
28
+ } from "./chunk-DNNSCSA2.js";
29
29
  import {
30
30
  createAgentKey,
31
31
  createDialogKey,
@@ -38,12 +38,12 @@ import {
38
38
  import {
39
39
  extractCustomId
40
40
  } from "./chunk-BJIRLHJR.js";
41
- import {
42
- selectIdentityUserId
43
- } from "./chunk-XOJRZUPF.js";
44
41
  import {
45
42
  isDevelopment
46
43
  } from "./chunk-QOKAKDPE.js";
44
+ import {
45
+ selectIdentityUserId
46
+ } from "./chunk-SEJ5OS6F.js";
47
47
  import {
48
48
  asTrimmedString
49
49
  } from "./chunk-3EUW3WEO.js";
@@ -582,6 +582,7 @@ var loadMemoryCandidatesFromDb = async (db, input) => {
582
582
  const kinds = input.kinds ?? ["episodic", "semantic", "procedural"];
583
583
  const ownerLimit = input.ownerLimit ?? 12;
584
584
  const ownerFallback = input.ownerFallback ?? "onSubjectMiss";
585
+ const reserve = Math.max(0, input.corroboratedProceduralReserve ?? 0);
585
586
  const ownerKeySet = new Set(
586
587
  input.owners.filter((owner) => owner.ownerId).map((owner) => `${owner.ownerType}:${owner.ownerId}`)
587
588
  );
@@ -603,6 +604,18 @@ var loadMemoryCandidatesFromDb = async (db, input) => {
603
604
  ...input.owners.map((owner) => loadOwnerItemsFromDb(db, owner, ownerLimit))
604
605
  ]
605
606
  ) : subjectResults;
607
+ if (reserve > 0 && kinds.includes("procedural")) {
608
+ const probeLimit = ownerLimit * 2;
609
+ const reserveResults = await Promise.all(
610
+ subjects.map(
611
+ (subject) => loadSubjectKindItemsFromDb(db, subject, "procedural", probeLimit)
612
+ )
613
+ );
614
+ const corroborated = reserveResults.flat().filter((item) => item && item.recurrenceEvidence).sort((a, b) => b.createdAt.localeCompare(a.createdAt)).slice(0, reserve);
615
+ for (const item of corroborated) {
616
+ results.push([item]);
617
+ }
618
+ }
606
619
  const kindSet = new Set(kinds);
607
620
  const seen = /* @__PURE__ */ new Set();
608
621
  const merged = [];
@@ -964,9 +977,6 @@ var createDialogAction = async (args, thunkApi) => {
964
977
  let referenceKeys;
965
978
  let inheritedFromDialogKey;
966
979
  let inheritedFromDialogTitle;
967
- let inheritedSummary;
968
- let inheritedSummarizedBeforeId;
969
- let inheritedCompressionCount;
970
980
  if (inheritFromDialogKey) {
971
981
  inheritedFromDialogKey = inheritFromDialogKey;
972
982
  const sourceDialog = await dispatch(
@@ -989,18 +999,6 @@ var createDialogAction = async (args, thunkApi) => {
989
999
  if (Array.isArray(candidate) && candidate.every((key) => typeof key === "string")) {
990
1000
  referenceKeys = candidate;
991
1001
  }
992
- const sourceSummary = sourceDialog.summary;
993
- if (typeof sourceSummary === "string" && sourceSummary.trim()) {
994
- inheritedSummary = sourceSummary.trim();
995
- }
996
- const sourceSummarizedBeforeId = sourceDialog.summarizedBeforeId;
997
- if (typeof sourceSummarizedBeforeId === "string" && sourceSummarizedBeforeId.trim()) {
998
- inheritedSummarizedBeforeId = sourceSummarizedBeforeId.trim();
999
- }
1000
- const sourceCompressionCount = sourceDialog.compressionCount;
1001
- if (typeof sourceCompressionCount === "number") {
1002
- inheritedCompressionCount = sourceCompressionCount;
1003
- }
1004
1002
  }
1005
1003
  }
1006
1004
  const dialogData = {
@@ -1017,10 +1015,6 @@ var createDialogAction = async (args, thunkApi) => {
1017
1015
  ...spaceId && { spaceId },
1018
1016
  category,
1019
1017
  referenceKeys,
1020
- // 压缩状态继承
1021
- ...inheritedSummary && { summary: inheritedSummary },
1022
- ...inheritedSummarizedBeforeId && { summarizedBeforeId: inheritedSummarizedBeforeId },
1023
- ...inheritedCompressionCount !== void 0 && { compressionCount: inheritedCompressionCount },
1024
1018
  ...args.extraReferences && args.extraReferences.length > 0 && { extraReferences: args.extraReferences },
1025
1019
  ...inheritedFromDialogKey && { inheritedFromDialogKey },
1026
1020
  ...inheritedFromDialogTitle && { inheritedFromDialogTitle },
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  TOOL_PACKS,
3
3
  buildCodeWorkDiscipline
4
- } from "./chunk-O5FLGN2L.js";
4
+ } from "./chunk-ZRSJ3JEH.js";
5
5
  import {
6
6
  buildSkillDocMarkdown,
7
7
  resolvePageSkillMetadata
8
- } from "./chunk-EY7V7REW.js";
8
+ } from "./chunk-AETZ7AD6.js";
9
9
  import {
10
10
  canonicalizeToolNames
11
11
  } from "./chunk-O6OSWFZQ.js";
@@ -0,0 +1,114 @@
1
+ import {
2
+ load
3
+ } from "./chunk-KHCLMKZZ.js";
4
+ import {
5
+ buildSkillDiscoveryLayer
6
+ } from "./chunk-DVINR3PL.js";
7
+
8
+ // packages/agent-runtime/skillDiscovery.ts
9
+ import { existsSync, readFileSync, readdirSync, statSync } from "node:fs";
10
+ import { join } from "node:path";
11
+ var SKILL_SCAN_DIRS = [".agents/skills"];
12
+ var MAX_DISCOVERED_SKILLS = 50;
13
+ var MAX_DISCOVERY_DESC_BUDGET = 4e3;
14
+ var MIN_DESC_LENGTH = 80;
15
+ function parseSkillFrontmatter(filePath) {
16
+ try {
17
+ const content = readFileSync(filePath, "utf8").slice(0, 2048);
18
+ const fmMatch = content.match(/^---\n([\s\S]*?)\n---/);
19
+ if (!fmMatch) return {};
20
+ const fm = (() => {
21
+ try {
22
+ return load(fmMatch[1]);
23
+ } catch (err) {
24
+ console.warn(
25
+ `[skillDiscovery] failed to parse frontmatter: ${filePath}: ${err.message}`
26
+ );
27
+ throw err;
28
+ }
29
+ })();
30
+ if (!fm || typeof fm !== "object") return {};
31
+ const name = typeof fm.name === "string" ? fm.name : void 0;
32
+ const rawDesc = fm.description;
33
+ const description = typeof rawDesc === "string" ? rawDesc : rawDesc == null ? void 0 : String(rawDesc);
34
+ const sanitizeName = (s) => s?.trim().replace(/^["']|["']$/g, "").replace(/[\n\r]+/g, " ").slice(0, 200);
35
+ const sanitizeDesc = (s) => s?.trim().replace(/^["']|["']$/g, "").replace(/[\n\r]+/g, " ").slice(0, 200);
36
+ return { name: sanitizeName(name), description: sanitizeDesc(description) };
37
+ } catch {
38
+ return {};
39
+ }
40
+ }
41
+ function discoverSkills(cwd) {
42
+ const skills = [];
43
+ for (const dir of SKILL_SCAN_DIRS) {
44
+ if (skills.length >= MAX_DISCOVERED_SKILLS) break;
45
+ const absDir = join(cwd, dir);
46
+ if (!existsSync(absDir) || !statSync(absDir).isDirectory()) continue;
47
+ try {
48
+ for (const entry of readdirSync(absDir)) {
49
+ if (skills.length >= MAX_DISCOVERED_SKILLS) break;
50
+ const skillMdPath = join(absDir, entry, "SKILL.md");
51
+ if (existsSync(skillMdPath)) {
52
+ const { name, description } = parseSkillFrontmatter(skillMdPath);
53
+ skills.push({ name: name ?? entry, description: description ?? "", relativePath: join(dir, entry, "SKILL.md") });
54
+ continue;
55
+ }
56
+ }
57
+ } catch {
58
+ }
59
+ }
60
+ const totalDescLen = skills.reduce((sum, s) => sum + s.description.length, 0);
61
+ if (totalDescLen > MAX_DISCOVERY_DESC_BUDGET && skills.length > 0) {
62
+ const scale = MAX_DISCOVERY_DESC_BUDGET / totalDescLen;
63
+ for (const s of skills) {
64
+ const targetLen = Math.max(MIN_DESC_LENGTH, Math.floor(s.description.length * scale));
65
+ if (s.description.length > targetLen) {
66
+ s.description = s.description.slice(0, targetLen).trimEnd();
67
+ }
68
+ }
69
+ }
70
+ return skills;
71
+ }
72
+ function resolveSkillByName(cwd, name) {
73
+ const trimmed = name.trim();
74
+ if (!trimmed || trimmed.includes("/") || trimmed.includes("\\") || trimmed.includes("..")) {
75
+ return null;
76
+ }
77
+ const agentsDir = join(cwd, ".agents", "skills", trimmed);
78
+ const agentsSkillMd = join(agentsDir, "SKILL.md");
79
+ if (existsSync(agentsSkillMd)) return agentsSkillMd;
80
+ const agentsParent = join(cwd, ".agents", "skills");
81
+ if (existsSync(agentsParent) && statSync(agentsParent).isDirectory()) {
82
+ try {
83
+ for (const entry of readdirSync(agentsParent)) {
84
+ const candidate = join(agentsParent, entry, "SKILL.md");
85
+ if (!existsSync(candidate)) continue;
86
+ try {
87
+ const { name: fmName } = parseSkillFrontmatter(candidate);
88
+ if (fmName && fmName === trimmed) return candidate;
89
+ } catch {
90
+ }
91
+ }
92
+ } catch {
93
+ }
94
+ }
95
+ return null;
96
+ }
97
+ function buildSkillDiscoveryContextLayer(cwd) {
98
+ try {
99
+ return buildSkillDiscoveryLayer(discoverSkills(cwd), cwd);
100
+ } catch {
101
+ return null;
102
+ }
103
+ }
104
+ function buildSkillDiscoveryContextBlock(cwd) {
105
+ return buildSkillDiscoveryContextLayer(cwd)?.content ?? null;
106
+ }
107
+
108
+ export {
109
+ parseSkillFrontmatter,
110
+ discoverSkills,
111
+ resolveSkillByName,
112
+ buildSkillDiscoveryContextLayer,
113
+ buildSkillDiscoveryContextBlock
114
+ };
@@ -3,15 +3,16 @@ import {
3
3
  } from "./chunk-ESHYE7WU.js";
4
4
  import {
5
5
  getDefaultCliLocalRuntimeDb
6
- } from "./chunk-IA3A5373.js";
6
+ } from "./chunk-C3FZR5EC.js";
7
7
  import {
8
8
  buildCliRuntimeEnv,
9
9
  clearProfileAuthToken,
10
10
  getCurrentProfile,
11
11
  getDefaultProfileConfigPath,
12
+ getProfileTokens,
12
13
  loadProfileConfig,
13
14
  saveDefaultProfile
14
- } from "./chunk-UNZDCI3O.js";
15
+ } from "./chunk-2KDR4CWE.js";
15
16
  import {
16
17
  resolveAuthTokenFromEnv
17
18
  } from "./chunk-A7GB5UGH.js";
@@ -458,7 +459,7 @@ function runWhoamiCommand(deps = {}) {
458
459
  const env = deps.env ?? process.env;
459
460
  const config = loadProfileConfig(deps.configPath);
460
461
  const profile = getCurrentProfile(config);
461
- const profileToken = profile?.authToken?.trim() ?? "";
462
+ const profileToken = getProfileTokens(config)[0]?.trim() ?? "";
462
463
  const envToken = resolveAuthTokenFromEnv(env);
463
464
  if (!profileToken && !envToken) {
464
465
  output2.log("Not logged in. Run: nolo login");
@@ -517,6 +518,7 @@ export {
517
518
  LOGOUT_HELP_TEXT,
518
519
  WHOAMI_HELP_TEXT,
519
520
  defaultOpenBrowser,
521
+ saveTokenLogin,
520
522
  runLoginCommand,
521
523
  runWhoamiCommand,
522
524
  runLogoutCommand
@@ -0,0 +1,30 @@
1
+ // packages/agent-runtime/responseGuidelines.ts
2
+ var RESPONSE_BEHAVIOR_GUIDELINES = `--- \u56DE\u590D\u884C\u4E3A\u51C6\u5219\uFF08\u8DE8\u7AEF\u901A\u7528\uFF09 ---
3
+ \u4EE5\u4E0B\u662F\u6240\u6709\u56DE\u590D\u5171\u4EAB\u7684\u884C\u4E3A\u57FA\u7EBF\uFF0C\u4E0E\u5F53\u524D\u89C6\u53E3\u3001\u6392\u7248\u65E0\u5173\uFF1A
4
+ - **\u4FE1\u606F\u4F18\u5148\u7EA7**\uFF1A\u5148\u7ED9\u5F53\u524D\u6700\u6709\u7528\u7684\u4FE1\u606F\u2014\u2014\u7ED3\u8BBA\u3001\u7ED3\u679C\u3001\u72B6\u6001\u6216\u4E0B\u4E00\u6B65\u52A8\u4F5C\uFF0C\u6309\u4EFB\u52A1\u7C7B\u578B\u9009\u5176\u4E00\uFF1B\u4E0D\u7528\u5BD2\u6684\u3001\u94FA\u57AB\u6216\u300C\u8BA9\u6211\u5206\u6790\u4E00\u4E0B\u300D\u5F00\u573A\u3002
5
+ - **\u4EFB\u52A1\u8FDE\u7EED\u6027**\uFF1A\u591A\u6B65\u9AA4\u4EFB\u52A1\u4FDD\u6301\u5F53\u524D\u72B6\u6001\u4E0E\u4E0B\u4E00\u6B65\u53EF\u89C1\uFF1B\u4EC5\u5728\u72B6\u6001\u53D8\u5316\u3001\u4ECE\u4E2D\u65AD/\u540E\u53F0\u4EFB\u52A1\u6062\u590D\u6216\u4E0A\u4E0B\u6587\u53EF\u80FD\u4E22\u5931\u65F6\u91CD\u8FF0\u8FDB\u5EA6\uFF0C\u4E0D\u673A\u68B0\u91CD\u590D\u3002
6
+ - **\u4E13\u6CE8\u4E3B\u7EBF**\uFF1A\u53D1\u73B0\u6B21\u8981\u95EE\u9898\u4E0D\u5207\u6362\u4E3B\u7EBF\uFF0C\u9664\u975E\u5B83\u963B\u585E\u6B63\u786E\u6027\u3001\u5B89\u5168\u6027\u6216\u5F53\u524D\u4EFB\u52A1\u672C\u8EAB\uFF1B\u503C\u5F97\u5904\u7406\u7684\u6B21\u8981\u9879\uFF0C\u5728\u4E3B\u7EBF\u5B8C\u6210\u540E\u7B80\u77ED\u6307\u51FA\u3002
7
+ - **\u9519\u8BEF\u4E8B\u5B9E\u5316**\uFF1A\u51FA\u9519\u65F6\u76F4\u63A5\u8BF4\u660E\u53D1\u751F\u4E86\u4EC0\u4E48\u3001\u5DF2\u77E5\u539F\u56E0\u6216\u4ECD\u4E0D\u786E\u5B9A\u4E4B\u5904\u3001\u5F53\u524D\u5F71\u54CD\u4E0E\u4E0B\u4E00\u6B65\uFF1B\u4E0D\u7528\u65E0\u4FE1\u606F\u91CF\u7684\u60C5\u7EEA\u5316\u63AA\u8F9E\uFF0C\u4E5F\u4E0D\u628A\u4E0D\u786E\u5B9A\u6027\u5305\u88C5\u6210\u7ED3\u8BBA\u3002
8
+ - **\u7406\u89E3\u5931\u8D25\u6062\u590D**\uFF1A\u7528\u6237\u8868\u793A\u6CA1\u61C2\u3001\u6CA1\u8DDF\u4E0A\u6216\u8981\u6C42\u6362\u79CD\u8BF4\u6CD5\u65F6\uFF0C\u56DE\u9000\u5230\u6700\u53EF\u80FD\u7F3A\u5931\u7684\u524D\u63D0\u91CD\u65B0\u89E3\u91CA\uFF0C\u800C\u4E0D\u662F\u53EA\u7F29\u77ED\u6216\u91CD\u590D\u4E0A\u4E00\u6761\uFF1B\u4F18\u5148\u590D\u7528\u5BF9\u8BDD\u4E0E\u9879\u76EE\u8D44\u6599\u4E2D\u5DF2\u5EFA\u7ACB\u7684\u672F\u8BED\uFF0C\u672F\u8BED\u672C\u8EAB\u53EF\u80FD\u9020\u6210\u56F0\u60D1\u65F6\u5148\u7B80\u77ED\u5B9A\u4E49\u3002`;
9
+ var buildResponseGuidelines = (isMobile) => {
10
+ if (isMobile) {
11
+ return `${RESPONSE_BEHAVIOR_GUIDELINES}
12
+
13
+ --- \u54CD\u5E94\u5C55\u793A\u6307\u5357\uFF08\u7A84\u5C4F / TUI / \u79FB\u52A8\u7AEF\uFF09 ---
14
+ \u5F53\u524D\u5904\u4E8E\u7A84\u5C4F\u6216\u7EC8\u7AEF\u89C6\u56FE\uFF0C\u91C7\u7528\u7D27\u51D1\u3001\u9AD8\u626B\u63CF\u7387\u6392\u7248\uFF1A\u7ED3\u8BBA/\u5173\u952E\u72B6\u6001\u7F6E\u9876\uFF0C\u77ED\u6BB5\u843D\uFF082-4 \u53E5\uFF09\u5E76\u4FDD\u6301\u7A7A\u884C\uFF0C\u62D2\u7EDD\u6587\u5B57\u5899\u3002
15
+ - \u5217\u8868\u9879\u7528\u300C- **\u6838\u5FC3\u8BCD**\uFF1A\u8BF4\u660E\u300D\uFF1B\u5D4C\u5957\u6700\u591A 2 \u5C42\uFF0C\u5B50\u5217\u8868\u7F29\u8FDB 2 \u7A7A\u683C\uFF1B\u5E76\u5217\u7528\u65E0\u5E8F\u5217\u8868\uFF0C\u6B65\u9AA4\u7528\u6709\u5E8F\u5217\u8868\u3002
16
+ - **\u8868\u683C\u964D\u7EA7**\uFF1A\u4E25\u7981\u4F7F\u7528 \u22654 \u5217\u7684\u5927\u5BBD\u8868\uFF08\u7A84\u5C4F/\u7EC8\u7AEF\u6298\u884C\u4E25\u91CD\u9519\u4F4D\uFF09\uFF0C\u6539\u7528\u952E\u503C\u6E05\u5355\u6216\u7EB5\u5411\u5361\u7247\u3002
17
+ - \u514B\u5236\u5206\u5272\u7EBF\uFF08\u4EC5\u5927\u4E3B\u9898\u5207\u6362\u6216\u7ED3\u8BBA\u524D\uFF0C\u524D\u540E\u7559\u7A7A\u884C\uFF09\uFF1B\u8DEF\u5F84\u3001\u547D\u4EE4\u4E0E\u53C2\u6570\u7528\u53CD\u5F15\u53F7 \` \` \u5305\u88F9\uFF1B\u4EE3\u7801\u5757\u6807\u660E\u8BED\u8A00\u4E14\u907F\u514D\u6A2A\u5411\u8D85\u957F\u884C\uFF1B\u514B\u5236 Emoji\u3002`;
18
+ }
19
+ return `${RESPONSE_BEHAVIOR_GUIDELINES}
20
+
21
+ --- \u54CD\u5E94\u5C55\u793A\u6307\u5357\uFF08\u5BBD\u5C4F / \u684C\u9762\u7AEF\uFF09 ---
22
+ \u5F53\u524D\u5904\u4E8E\u5927\u5C4F\u89C6\u56FE\uFF1A\u5C42\u6B21\u6E05\u6670\u7684\u5168\u666F\u7ED3\u6784\uFF0C\u91CD\u8981\u6A21\u5757\u7528\u4E8C\u7EA7/\u4E09\u7EA7\u6807\u9898\u5212\u5206\uFF1B\u6BB5\u843D 2-4 \u53E5\u5E76\u7559\u7A7A\u884C\uFF0C\u76F4\u5954\u4E3B\u9898\u3002
23
+ - \u5217\u8868\u9879\u7528\u300C- **\u6838\u5FC3\u8BCD**\uFF1A\u8BF4\u660E\u300D\uFF1B\u5D4C\u5957\u6700\u591A 2 \u5C42\uFF0C\u5B50\u5217\u8868\u7F29\u8FDB 2 \u7A7A\u683C\uFF1B\u5E76\u5217\u7528\u65E0\u5E8F\u5217\u8868\uFF0C\u6B65\u9AA4\u7528\u6709\u5E8F\u5217\u8868\u3002
24
+ - **\u8868\u683C\u4E0E\u5BF9\u6BD4**\uFF1A\u5BBD\u5C4F\u4E0B\u53EF\u9002\u5EA6\u4F7F\u7528 Markdown \u591A\u5217\u8868\u683C\u505A\u65B9\u6848\u5BF9\u6BD4\u3001\u53C2\u6570\u6C47\u603B\u6216\u77E9\u9635\u5206\u6790\u3002
25
+ - \u53EF\u5C55\u793A\u66F4\u5B8C\u6574\u7684\u4EE3\u7801\u4E0A\u4E0B\u6587\u4E0E\u591A\u6B65\u6267\u884C\u793A\u4F8B\uFF1B\u8DEF\u5F84\u3001\u547D\u4EE4\u4E0E\u53C2\u6570\u7528\u53CD\u5F15\u53F7 \` \` \u5305\u88F9\uFF0C\u4EE3\u7801\u5757\u6807\u660E\u8BED\u8A00\uFF1B\u514B\u5236\u5206\u5272\u7EBF\u4E0E Emoji\u3002`;
26
+ };
27
+
28
+ export {
29
+ buildResponseGuidelines
30
+ };
@@ -3,7 +3,7 @@ import {
3
3
  createFileCredentialBroker,
4
4
  migrateAgentSecrets,
5
5
  normalizeAgentRuntimeToolPolicy
6
- } from "./chunk-CS6TCJ7E.js";
6
+ } from "./chunk-3JQ2NRYU.js";
7
7
  import {
8
8
  asRecordOrEmpty
9
9
  } from "./chunk-KX6YBIHG.js";
@@ -11,7 +11,7 @@ import {
11
11
  patch,
12
12
  remove,
13
13
  write
14
- } from "./chunk-7NYDJAQ7.js";
14
+ } from "./chunk-DNNSCSA2.js";
15
15
  import {
16
16
  createAgentKey,
17
17
  toTrimmedString
@@ -20,7 +20,7 @@ import {
20
20
  asyncThunkCreator,
21
21
  buildCreateSlice,
22
22
  getRuntimeServerContext
23
- } from "./chunk-XOJRZUPF.js";
23
+ } from "./chunk-KWSQR2KK.js";
24
24
  import {
25
25
  asTrimmedString
26
26
  } from "./chunk-3EUW3WEO.js";
@@ -304,7 +304,7 @@ var slice = createSliceWithThunks({
304
304
  const overrides = {};
305
305
  if (args.systemPromptOverride !== void 0) overrides.prompt = args.systemPromptOverride;
306
306
  if (args.toolsOverride !== void 0) overrides.tools = args.toolsOverride;
307
- const { _executeModel } = await import("./_executeModel-OPTKYHJA.js");
307
+ const { _executeModel } = await import("./_executeModel-R26QYY66.js");
308
308
  return _executeModel(
309
309
  {
310
310
  isStreaming: args.isStreaming ?? false,
@@ -325,7 +325,7 @@ var slice = createSliceWithThunks({
325
325
  * - 循环直到无工具调用或触发其他运行时停止条件
326
326
  */
327
327
  runAgent: create.asyncThunk(async (args, thunkApi) => {
328
- const { runAgentClientLoop } = await import("./runAgentClientLoop-24GQ2AW6.js");
328
+ const { runAgentClientLoop } = await import("./runAgentClientLoop-Y6HWP2PT.js");
329
329
  const { content: loopContent, toolCallCount } = await runAgentClientLoop(
330
330
  {
331
331
  agentKey: args.agentKey,
@@ -341,7 +341,7 @@ var slice = createSliceWithThunks({
341
341
  * 聊天轮次流式 Agent 调用
342
342
  */
343
343
  streamAgentChatTurn: create.asyncThunk(async (args, thunkApi) => {
344
- const { streamAgentChatTurnHandler } = await import("./streamAgentChatTurn-QHKP3ABO.js");
344
+ const { streamAgentChatTurnHandler } = await import("./streamAgentChatTurn-6WFQJ4DY.js");
345
345
  return streamAgentChatTurnHandler(args, thunkApi);
346
346
  }),
347
347
  /**
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  buildLocalAgentLookupKeys,
3
3
  shouldReadAgentKeyRemotely
4
- } from "./chunk-JON2PHYT.js";
4
+ } from "./chunk-CTCW7U7N.js";
5
5
  import {
6
6
  resolveCliAgentKeyInput
7
- } from "./chunk-EKLRRZIN.js";
7
+ } from "./chunk-SPAQ4PVV.js";
8
8
  import {
9
9
  toErrorMessage
10
10
  } from "./chunk-HNMXYYJR.js";
@@ -620,7 +620,6 @@ async function buildUpdatedAgentRecord(args) {
620
620
  }
621
621
 
622
622
  export {
623
- normalizeAgentHandle,
624
623
  fetchWithTransportFallback,
625
624
  readAgentRecord,
626
625
  readDbRecord,
@@ -4,11 +4,12 @@ import {
4
4
  openrouterModels,
5
5
  platformHostedModels,
6
6
  zaiModels
7
- } from "./chunk-HPW5MNDQ.js";
7
+ } from "./chunk-22BTGNSP.js";
8
8
 
9
9
  // packages/ai/llm/modelAbility.ts
10
10
  var MODEL_ABILITY_TABLE = {
11
11
  "claude-opus-5": { passAt1: 74, benchmarkScore: 61, writingScore: 82 },
12
+ "gpt-6-astra": { passAt1: 85, benchmarkScore: 90, writingScore: 92 },
12
13
  "claude-opus-4-6": { passAt1: 65, benchmarkScore: 68, writingScore: 78 },
13
14
  "gpt-5.6-sol": { passAt1: 73, benchmarkScore: 59, writingScore: 80 },
14
15
  "claude-fable-5": { passAt1: 70 },
@@ -22,6 +23,7 @@ var MODEL_ABILITY_TABLE = {
22
23
  "muse-spark-1.2": { passAt1: 55 },
23
24
  "grok-4.5": { passAt1: 54, benchmarkScore: 54 },
24
25
  "claude-sonnet-5": { passAt1: 54, benchmarkScore: 53 },
26
+ "deepseek-flash": { passAt1: 53 },
25
27
  "deepseek-v4-flash": { passAt1: 53 },
26
28
  "gemini-3.7-flash": { passAt1: 58, benchmarkScore: 65, writingScore: 88 },
27
29
  // TODO(benchmark): gemini-3.8-flash 官方基准快照未出,暂沿用 3.7 分数占位,确认后更新。
@@ -8314,14 +8314,19 @@ var EditMap = class {
8314
8314
  */
8315
8315
  constructor() {
8316
8316
  this.map = [];
8317
+ this.index = /* @__PURE__ */ new Map();
8317
8318
  }
8318
8319
  /**
8319
8320
  * Create an edit: a remove and/or add at a certain place.
8320
8321
  *
8321
8322
  * @param {number} index
8323
+ * Index at which to apply the edit.
8322
8324
  * @param {number} remove
8325
+ * Count of items to remove at the index.
8323
8326
  * @param {Array<Event>} add
8327
+ * Items to add at the index.
8324
8328
  * @returns {undefined}
8329
+ * Nothing.
8325
8330
  */
8326
8331
  add(index2, remove, add) {
8327
8332
  addImplementation(this, index2, remove, add);
@@ -8342,7 +8347,9 @@ var EditMap = class {
8342
8347
  * Done, change the events.
8343
8348
  *
8344
8349
  * @param {Array<Event>} events
8350
+ * List of events to apply the edits to.
8345
8351
  * @returns {undefined}
8352
+ * Nothing.
8346
8353
  */
8347
8354
  consume(events) {
8348
8355
  this.map.sort(function(a, b) {
@@ -8368,22 +8375,22 @@ var EditMap = class {
8368
8375
  slice = vecs.pop();
8369
8376
  }
8370
8377
  this.map.length = 0;
8378
+ this.index.clear();
8371
8379
  }
8372
8380
  };
8373
8381
  function addImplementation(editMap, at, remove, add) {
8374
- let index2 = 0;
8375
8382
  if (remove === 0 && add.length === 0) {
8376
8383
  return;
8377
8384
  }
8378
- while (index2 < editMap.map.length) {
8379
- if (editMap.map[index2][0] === at) {
8380
- editMap.map[index2][1] += remove;
8381
- editMap.map[index2][2].push(...add);
8382
- return;
8383
- }
8384
- index2 += 1;
8385
+ const existing = editMap.index.get(at);
8386
+ if (existing) {
8387
+ existing[1] += remove;
8388
+ existing[2].push(...add);
8389
+ return;
8385
8390
  }
8386
- editMap.map.push([at, remove, add]);
8391
+ const change = [at, remove, add];
8392
+ editMap.map.push(change);
8393
+ editMap.index.set(at, change);
8387
8394
  }
8388
8395
 
8389
8396
  // node_modules/micromark-extension-gfm-table/lib/infer.js
@@ -8434,10 +8441,15 @@ function tokenizeTable(effects, ok3, nok) {
8434
8441
  function start(code2) {
8435
8442
  let index2 = self.events.length - 1;
8436
8443
  while (index2 > -1) {
8437
- const type = self.events[index2][1].type;
8444
+ const {
8445
+ type
8446
+ } = self.events[index2][1];
8438
8447
  if (type === "lineEnding" || // Note: markdown-rs uses `whitespace` instead of `linePrefix`
8439
- type === "linePrefix") index2--;
8440
- else break;
8448
+ type === "linePrefix") {
8449
+ index2--;
8450
+ } else {
8451
+ break;
8452
+ }
8441
8453
  }
8442
8454
  const tail = index2 > -1 ? self.events[index2][1].type : null;
8443
8455
  const next = tail === "tableHead" || tail === "tableRow" ? bodyRowStart : headRowBefore;
@@ -10,7 +10,7 @@ import {
10
10
  import {
11
11
  patch,
12
12
  readAndWait
13
- } from "./chunk-7NYDJAQ7.js";
13
+ } from "./chunk-DNNSCSA2.js";
14
14
  import {
15
15
  asOptionalTrimmedString
16
16
  } from "./chunk-G3SUCT4W.js";
@@ -326,7 +326,7 @@ async function saveDocState(arg, { dispatch, getState }) {
326
326
  ).unwrap();
327
327
  if (dbSpaceId) {
328
328
  try {
329
- const { updateContentTitle } = await import("./contentThunks-KNI6VXLT.js");
329
+ const { updateContentTitle } = await import("./contentThunks-OZPK5B4Z.js");
330
330
  await dispatch(
331
331
  updateContentTitle({
332
332
  spaceId: dbSpaceId,
@@ -365,7 +365,7 @@ async function saveDocState(arg, { dispatch, getState }) {
365
365
  }
366
366
  }
367
367
  async function createDocState(args, thunkApi) {
368
- const { createPageAction } = await import("./createPageAction-T7RA3HCG.js");
368
+ const { createPageAction } = await import("./createPageAction-6P2WLNHO.js");
369
369
  return createPageAction(args, thunkApi);
370
370
  }
371
371
  function subscribe(listener) {
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  selectCurrentServer,
3
3
  selectRemoteServers
4
- } from "./chunk-SVC3GGUA.js";
4
+ } from "./chunk-VMWYBIXG.js";
5
5
  import {
6
6
  createUserKey,
7
7
  extractAgentInfo,
@@ -13,13 +13,15 @@ import {
13
13
  } from "./chunk-NHRQCXIQ.js";
14
14
  import {
15
15
  noloDeleteRequest,
16
- noloWriteRequest,
17
- selectIdentityUser,
18
- selectIdentityUserId
19
- } from "./chunk-XOJRZUPF.js";
16
+ noloWriteRequest
17
+ } from "./chunk-KWSQR2KK.js";
20
18
  import {
21
19
  normalizeTimeFields
22
20
  } from "./chunk-QOKAKDPE.js";
21
+ import {
22
+ selectIdentityUser,
23
+ selectIdentityUserId
24
+ } from "./chunk-SEJ5OS6F.js";
23
25
 
24
26
  // packages/share/action.ts
25
27
  var generateToken = () => {
@@ -2,7 +2,7 @@ import {
2
2
  LOCAL_CODEX_AGENT_KEY,
3
3
  isLocalCliAgentKey,
4
4
  resolveCliAgentKeyInput
5
- } from "./chunk-EKLRRZIN.js";
5
+ } from "./chunk-SPAQ4PVV.js";
6
6
  import {
7
7
  DEFAULT_NOLO_SERVER_URL
8
8
  } from "./chunk-OLZBQWZU.js";
@@ -138,7 +138,7 @@ function writeUsage(output, commandPath) {
138
138
  return;
139
139
  }
140
140
  output.write(
141
- "Usage: nolo agent run <agent> <message> [--local|--server|--auto] [--ephemeral|--memory-only] [--continue <dialogId>] [--cwd <path>]\n nolo agent run --agent <agent> (--msg <message>|--msg-file <path>) [--image <url-or-path>] [--space <spaceId>] [--category <name>] [--inherit-from-dialog <dialog>] [--parent-dialog <dialog>] [--subject-dialog <dialog>] [--subject-ref <kind:id[:role]>] [--task-row-dbkey <key>] [--allowed-child-agent <agent>] [--fallback-agent <agent>] (suggestions for agent to decide on quota) [--allowed-tool <tool>] [--blocked-tool <tool>] [--dod <cmd>] [--bg] [--timeout-ms <n>] [--events jsonl] [--no-stream] [--skill <dbKey-or-md-path>]\n"
141
+ "Usage: nolo agent run <agent> <message> [--local|--server|--auto] [--ephemeral|--memory-only] [--continue <dialogId>] [--cwd <path>]\n nolo agent run --agent <agent> (--msg <message>|--msg-file <path>) [--image <url-or-path>] [--space <spaceId>] [--category <name>] [--inherit-from-dialog <dialog>] [--parent-dialog <dialog>] [--subject-dialog <dialog>] [--subject-ref <kind:id[:role]>] [--task-row-dbkey <key>] [--fallback-agent <agent>] (suggestions for agent to decide on quota) [--allowed-tool <tool>] [--blocked-tool <tool>] [--dod <cmd>] [--bg] [--timeout-ms <n>] [--events jsonl] [--no-stream] [--skill <dbKey-or-md-path>]\n"
142
142
  );
143
143
  }
144
144
  function parseAgentRunArgs(args, options = {}) {
@@ -160,7 +160,6 @@ function parseAgentRunArgs(args, options = {}) {
160
160
  const subjectDialog = readFlagValue(args, "--subject-dialog") ?? readFlagValue(args, "--reference-dialog");
161
161
  const subjectDialogKey = subjectDialog?.trim();
162
162
  const subjectRefs = readRepeatedFlagValues(args, "--subject-ref").map(parseSubjectRef).filter((ref) => Boolean(ref));
163
- const allowedChildAgentKeys = readRepeatedFlagValues(args, "--allowed-child-agent").map((value) => resolveCliAgentKeyInput(value.trim())).filter(Boolean);
164
163
  const fallbackAgentKeys = readRepeatedFlagValues(args, "--fallback-agent").map((value) => resolveCliAgentKeyInput(value.trim())).filter(Boolean);
165
164
  const allowedToolNames = readRepeatedFlagValues(args, "--allowed-tool").map((value) => value.trim()).filter(Boolean);
166
165
  const cwd = readFlagValue(args, "--cwd");
@@ -212,7 +211,6 @@ function parseAgentRunArgs(args, options = {}) {
212
211
  ...parentDialogRef?.dialogId ? { parentWakeOnTerminal: true } : {},
213
212
  ...subjectDialogKey ? { subjectDialogKey } : {},
214
213
  ...subjectRefs.length ? { subjectRefs } : {},
215
- ...allowedChildAgentKeys.length ? { allowedChildAgentKeys } : {},
216
214
  ...fallbackAgentKeys.length ? { fallbackAgentKeys } : {},
217
215
  ...allowedToolNames.length ? { allowedToolNames } : {},
218
216
  ...cwd ? { cwd } : {},