pybao-cli 1.4.64 → 1.4.68

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 (147) hide show
  1. package/dist/REPL-6LXLSOII.js +46 -0
  2. package/dist/{acp-NNC74LVQ.js → acp-RBZLK5I5.js} +29 -29
  3. package/dist/{agentsValidate-N2PRTFSW.js → agentsValidate-4WPUQRIU.js} +7 -7
  4. package/dist/{ask-OMCYF7SB.js → ask-E7CHIPZA.js} +28 -28
  5. package/dist/{autoUpdater-KTJOOCBF.js → autoUpdater-VJML5LAO.js} +3 -3
  6. package/dist/{chunk-GN3ZKIK6.js → chunk-2EJTMBGJ.js} +1 -1
  7. package/dist/{chunk-OXHRDN5X.js → chunk-2V6NJ7DW.js} +2 -2
  8. package/dist/{chunk-OF4XXXQ3.js → chunk-3PPYB2AK.js} +3 -10
  9. package/dist/{chunk-OF4XXXQ3.js.map → chunk-3PPYB2AK.js.map} +2 -2
  10. package/dist/{chunk-MLDL3JF6.js → chunk-5AIERJLG.js} +1 -1
  11. package/dist/{chunk-CPIJT73E.js → chunk-5O3GVP7Z.js} +4 -4
  12. package/dist/{chunk-XJ7FTO4Q.js → chunk-7LDPOZZ6.js} +2 -2
  13. package/dist/{chunk-UHGE2VNM.js → chunk-7NCAJ2EJ.js} +2 -2
  14. package/dist/{chunk-OHJ6K3RB.js → chunk-BEQTINGU.js} +2 -2
  15. package/dist/{chunk-DSIEFOTV.js → chunk-C5LUBN6T.js} +2 -2
  16. package/dist/{chunk-OZ6NCAGV.js → chunk-DDHVXTMC.js} +2 -2
  17. package/dist/{chunk-EXRF6SQY.js → chunk-EE2HU2RS.js} +1 -1
  18. package/dist/{chunk-RBHDCD2Z.js → chunk-FQBUFFT7.js} +1 -1
  19. package/dist/{chunk-WEUXBNQB.js → chunk-GF57CLFI.js} +1 -1
  20. package/dist/{chunk-WEUXBNQB.js.map → chunk-GF57CLFI.js.map} +1 -1
  21. package/dist/{chunk-2CELXL5Z.js → chunk-HPWXOI2K.js} +17 -17
  22. package/dist/{chunk-2CELXL5Z.js.map → chunk-HPWXOI2K.js.map} +1 -1
  23. package/dist/{chunk-35JFWNXQ.js → chunk-ISBXNGQB.js} +1 -1
  24. package/dist/{chunk-7RRCPMNG.js → chunk-KLSIXVFM.js} +380 -750
  25. package/dist/chunk-KLSIXVFM.js.map +7 -0
  26. package/dist/{chunk-37BP5U6M.js → chunk-KVHO4FHL.js} +1 -1
  27. package/dist/{chunk-HJ5SZ4TA.js → chunk-LYA52DLL.js} +1 -1
  28. package/dist/{chunk-VBLYYT4L.js → chunk-NN2VFVIX.js} +3 -3
  29. package/dist/{chunk-CFPCW6W7.js → chunk-OGXQURMW.js} +4 -4
  30. package/dist/{chunk-6N2MGB6O.js → chunk-PYASW53S.js} +3 -3
  31. package/dist/{chunk-KZTHNPPI.js → chunk-QEV4V7JC.js} +3 -3
  32. package/dist/{chunk-VDHPWKZV.js → chunk-UDEREIRJ.js} +4 -4
  33. package/dist/{chunk-POWN423Y.js → chunk-XOSFFE2Y.js} +3 -3
  34. package/dist/{chunk-WVYOCUBS.js → chunk-XSR4HZ53.js} +3 -3
  35. package/dist/{chunk-LHNIA7TU.js → chunk-Y4PZVDDV.js} +4 -4
  36. package/dist/{chunk-IFDY7DTL.js → chunk-Y7FNVY2D.js} +1 -1
  37. package/dist/{chunk-V4VOZJWR.js → chunk-Z37IW5CA.js} +3 -5
  38. package/dist/chunk-Z37IW5CA.js.map +7 -0
  39. package/dist/{chunk-WKFRDCMK.js → chunk-ZHVCG35Z.js} +1 -1
  40. package/dist/{chunk-6WB73VIP.js → chunk-ZQCSH2AL.js} +3 -3
  41. package/dist/{cli-KSOAUNRJ.js → cli-F74NJUHW.js} +87 -87
  42. package/dist/commands-HL6HBYHQ.js +50 -0
  43. package/dist/{config-VMBOUVXO.js → config-U6OMMOIX.js} +4 -4
  44. package/dist/{context-2ZGOMAC7.js → context-SRTP4GIV.js} +6 -6
  45. package/dist/{customCommands-JSUSLJNY.js → customCommands-UQ7GWOJ4.js} +4 -4
  46. package/dist/{env-J2YKO3AW.js → env-RSGBO3MI.js} +2 -2
  47. package/dist/{file-AEJWH3BT.js → file-DDLPA2J4.js} +4 -4
  48. package/dist/index.js +3 -3
  49. package/dist/{llm-5RBAGTX5.js → llm-VY6RXJY7.js} +29 -29
  50. package/dist/{llmLazy-GBSYY2PZ.js → llmLazy-LQ6IPPZV.js} +1 -1
  51. package/dist/{loader-FJGRWSZ4.js → loader-WVZDAGRL.js} +4 -4
  52. package/dist/{lsp-PVK7EZJT.js → lsp-2PB45IFR.js} +6 -6
  53. package/dist/{lspAnchor-JS73KKBP.js → lspAnchor-FK5YBDE6.js} +6 -6
  54. package/dist/{mcp-YXM66Q2G.js → mcp-CDUXVXDY.js} +7 -7
  55. package/dist/{mentionProcessor-GOHXPZVX.js → mentionProcessor-5JPXBDX4.js} +5 -5
  56. package/dist/{messages-4AVBQONO.js → messages-ALZZJK3V.js} +1 -1
  57. package/dist/{model-ZVCXE44R.js → model-BVFVXXKO.js} +5 -5
  58. package/dist/{openai-XSMFEM5F.js → openai-OJOPD7MA.js} +5 -5
  59. package/dist/{outputStyles-KMLQ5API.js → outputStyles-HFX7LO4Y.js} +4 -4
  60. package/dist/{pluginRuntime-7URRA2OK.js → pluginRuntime-PWEYBXJ4.js} +6 -6
  61. package/dist/{pluginValidation-TZLMGK5Q.js → pluginValidation-UOPYDU5C.js} +6 -6
  62. package/dist/prompts-MGPNIHJM.js +52 -0
  63. package/dist/{pybAgentSessionLoad-HMCWFUZR.js → pybAgentSessionLoad-KL57MVY7.js} +4 -4
  64. package/dist/{pybAgentSessionResume-JT6W67ZR.js → pybAgentSessionResume-BR77W4UQ.js} +4 -4
  65. package/dist/{pybAgentStreamJsonSession-QFCZBOS4.js → pybAgentStreamJsonSession-4PNNMAVB.js} +1 -1
  66. package/dist/{pybHooks-LF6OM4KC.js → pybHooks-Z4C23UQN.js} +4 -4
  67. package/dist/query-SGRPX3AO.js +54 -0
  68. package/dist/{registry-OZAIBL65.js → registry-3YHU4UGY.js} +5 -5
  69. package/dist/{ripgrep-ZECM5W56.js → ripgrep-DU7WTPTQ.js} +3 -3
  70. package/dist/{skillMarketplace-CO2USHBI.js → skillMarketplace-D4I6ZI53.js} +3 -3
  71. package/dist/{state-QBXHDWLK.js → state-GH6RNHJT.js} +2 -2
  72. package/dist/{theme-2BHFZVXU.js → theme-GS3EV5EN.js} +5 -5
  73. package/dist/{toolPermissionSettings-VTA3XZ3G.js → toolPermissionSettings-X2E6BA4Z.js} +6 -6
  74. package/dist/tools-57A33JBX.js +51 -0
  75. package/dist/{userInput-24DBRUI7.js → userInput-H2LOGQOX.js} +30 -30
  76. package/package.json +1 -1
  77. package/dist/REPL-ADU4IURM.js +0 -46
  78. package/dist/chunk-7RRCPMNG.js.map +0 -7
  79. package/dist/chunk-V4VOZJWR.js.map +0 -7
  80. package/dist/commands-WM7IIR65.js +0 -50
  81. package/dist/prompts-KLR3QT24.js +0 -52
  82. package/dist/query-DD7PQZQM.js +0 -54
  83. package/dist/tools-WCNFHQ6U.js +0 -51
  84. /package/dist/{REPL-ADU4IURM.js.map → REPL-6LXLSOII.js.map} +0 -0
  85. /package/dist/{acp-NNC74LVQ.js.map → acp-RBZLK5I5.js.map} +0 -0
  86. /package/dist/{agentsValidate-N2PRTFSW.js.map → agentsValidate-4WPUQRIU.js.map} +0 -0
  87. /package/dist/{ask-OMCYF7SB.js.map → ask-E7CHIPZA.js.map} +0 -0
  88. /package/dist/{autoUpdater-KTJOOCBF.js.map → autoUpdater-VJML5LAO.js.map} +0 -0
  89. /package/dist/{chunk-GN3ZKIK6.js.map → chunk-2EJTMBGJ.js.map} +0 -0
  90. /package/dist/{chunk-OXHRDN5X.js.map → chunk-2V6NJ7DW.js.map} +0 -0
  91. /package/dist/{chunk-MLDL3JF6.js.map → chunk-5AIERJLG.js.map} +0 -0
  92. /package/dist/{chunk-CPIJT73E.js.map → chunk-5O3GVP7Z.js.map} +0 -0
  93. /package/dist/{chunk-XJ7FTO4Q.js.map → chunk-7LDPOZZ6.js.map} +0 -0
  94. /package/dist/{chunk-UHGE2VNM.js.map → chunk-7NCAJ2EJ.js.map} +0 -0
  95. /package/dist/{chunk-OHJ6K3RB.js.map → chunk-BEQTINGU.js.map} +0 -0
  96. /package/dist/{chunk-DSIEFOTV.js.map → chunk-C5LUBN6T.js.map} +0 -0
  97. /package/dist/{chunk-OZ6NCAGV.js.map → chunk-DDHVXTMC.js.map} +0 -0
  98. /package/dist/{chunk-EXRF6SQY.js.map → chunk-EE2HU2RS.js.map} +0 -0
  99. /package/dist/{chunk-RBHDCD2Z.js.map → chunk-FQBUFFT7.js.map} +0 -0
  100. /package/dist/{chunk-35JFWNXQ.js.map → chunk-ISBXNGQB.js.map} +0 -0
  101. /package/dist/{chunk-37BP5U6M.js.map → chunk-KVHO4FHL.js.map} +0 -0
  102. /package/dist/{chunk-HJ5SZ4TA.js.map → chunk-LYA52DLL.js.map} +0 -0
  103. /package/dist/{chunk-VBLYYT4L.js.map → chunk-NN2VFVIX.js.map} +0 -0
  104. /package/dist/{chunk-CFPCW6W7.js.map → chunk-OGXQURMW.js.map} +0 -0
  105. /package/dist/{chunk-6N2MGB6O.js.map → chunk-PYASW53S.js.map} +0 -0
  106. /package/dist/{chunk-KZTHNPPI.js.map → chunk-QEV4V7JC.js.map} +0 -0
  107. /package/dist/{chunk-VDHPWKZV.js.map → chunk-UDEREIRJ.js.map} +0 -0
  108. /package/dist/{chunk-POWN423Y.js.map → chunk-XOSFFE2Y.js.map} +0 -0
  109. /package/dist/{chunk-WVYOCUBS.js.map → chunk-XSR4HZ53.js.map} +0 -0
  110. /package/dist/{chunk-LHNIA7TU.js.map → chunk-Y4PZVDDV.js.map} +0 -0
  111. /package/dist/{chunk-IFDY7DTL.js.map → chunk-Y7FNVY2D.js.map} +0 -0
  112. /package/dist/{chunk-WKFRDCMK.js.map → chunk-ZHVCG35Z.js.map} +0 -0
  113. /package/dist/{chunk-6WB73VIP.js.map → chunk-ZQCSH2AL.js.map} +0 -0
  114. /package/dist/{cli-KSOAUNRJ.js.map → cli-F74NJUHW.js.map} +0 -0
  115. /package/dist/{commands-WM7IIR65.js.map → commands-HL6HBYHQ.js.map} +0 -0
  116. /package/dist/{config-VMBOUVXO.js.map → config-U6OMMOIX.js.map} +0 -0
  117. /package/dist/{context-2ZGOMAC7.js.map → context-SRTP4GIV.js.map} +0 -0
  118. /package/dist/{customCommands-JSUSLJNY.js.map → customCommands-UQ7GWOJ4.js.map} +0 -0
  119. /package/dist/{env-J2YKO3AW.js.map → env-RSGBO3MI.js.map} +0 -0
  120. /package/dist/{file-AEJWH3BT.js.map → file-DDLPA2J4.js.map} +0 -0
  121. /package/dist/{llm-5RBAGTX5.js.map → llm-VY6RXJY7.js.map} +0 -0
  122. /package/dist/{llmLazy-GBSYY2PZ.js.map → llmLazy-LQ6IPPZV.js.map} +0 -0
  123. /package/dist/{loader-FJGRWSZ4.js.map → loader-WVZDAGRL.js.map} +0 -0
  124. /package/dist/{lsp-PVK7EZJT.js.map → lsp-2PB45IFR.js.map} +0 -0
  125. /package/dist/{lspAnchor-JS73KKBP.js.map → lspAnchor-FK5YBDE6.js.map} +0 -0
  126. /package/dist/{mcp-YXM66Q2G.js.map → mcp-CDUXVXDY.js.map} +0 -0
  127. /package/dist/{mentionProcessor-GOHXPZVX.js.map → mentionProcessor-5JPXBDX4.js.map} +0 -0
  128. /package/dist/{messages-4AVBQONO.js.map → messages-ALZZJK3V.js.map} +0 -0
  129. /package/dist/{model-ZVCXE44R.js.map → model-BVFVXXKO.js.map} +0 -0
  130. /package/dist/{openai-XSMFEM5F.js.map → openai-OJOPD7MA.js.map} +0 -0
  131. /package/dist/{outputStyles-KMLQ5API.js.map → outputStyles-HFX7LO4Y.js.map} +0 -0
  132. /package/dist/{pluginRuntime-7URRA2OK.js.map → pluginRuntime-PWEYBXJ4.js.map} +0 -0
  133. /package/dist/{pluginValidation-TZLMGK5Q.js.map → pluginValidation-UOPYDU5C.js.map} +0 -0
  134. /package/dist/{prompts-KLR3QT24.js.map → prompts-MGPNIHJM.js.map} +0 -0
  135. /package/dist/{pybAgentSessionLoad-HMCWFUZR.js.map → pybAgentSessionLoad-KL57MVY7.js.map} +0 -0
  136. /package/dist/{pybAgentSessionResume-JT6W67ZR.js.map → pybAgentSessionResume-BR77W4UQ.js.map} +0 -0
  137. /package/dist/{pybAgentStreamJsonSession-QFCZBOS4.js.map → pybAgentStreamJsonSession-4PNNMAVB.js.map} +0 -0
  138. /package/dist/{pybHooks-LF6OM4KC.js.map → pybHooks-Z4C23UQN.js.map} +0 -0
  139. /package/dist/{query-DD7PQZQM.js.map → query-SGRPX3AO.js.map} +0 -0
  140. /package/dist/{registry-OZAIBL65.js.map → registry-3YHU4UGY.js.map} +0 -0
  141. /package/dist/{ripgrep-ZECM5W56.js.map → ripgrep-DU7WTPTQ.js.map} +0 -0
  142. /package/dist/{skillMarketplace-CO2USHBI.js.map → skillMarketplace-D4I6ZI53.js.map} +0 -0
  143. /package/dist/{state-QBXHDWLK.js.map → state-GH6RNHJT.js.map} +0 -0
  144. /package/dist/{theme-2BHFZVXU.js.map → theme-GS3EV5EN.js.map} +0 -0
  145. /package/dist/{toolPermissionSettings-VTA3XZ3G.js.map → toolPermissionSettings-X2E6BA4Z.js.map} +0 -0
  146. /package/dist/{tools-WCNFHQ6U.js.map → tools-57A33JBX.js.map} +0 -0
  147. /package/dist/{userInput-24DBRUI7.js.map → userInput-H2LOGQOX.js.map} +0 -0
@@ -3,18 +3,18 @@ const require = __pybCreateRequire(import.meta.url);
3
3
  import {
4
4
  formatValidationResult,
5
5
  validatePluginOrMarketplacePath
6
- } from "./chunk-KZTHNPPI.js";
6
+ } from "./chunk-QEV4V7JC.js";
7
7
  import {
8
8
  loadPybAgentSessionMessages
9
- } from "./chunk-IFDY7DTL.js";
9
+ } from "./chunk-Y7FNVY2D.js";
10
10
  import {
11
11
  listPybAgentSessions
12
- } from "./chunk-RBHDCD2Z.js";
12
+ } from "./chunk-FQBUFFT7.js";
13
13
  import {
14
14
  appendSessionCustomTitleRecord,
15
15
  appendSessionJsonlFromMessage,
16
16
  appendSessionTagRecord
17
- } from "./chunk-OZ6NCAGV.js";
17
+ } from "./chunk-DDHVXTMC.js";
18
18
  import {
19
19
  drainHookSystemPromptAdditions,
20
20
  getHookTranscriptPath,
@@ -26,7 +26,7 @@ import {
26
26
  runStopHooks,
27
27
  runUserPromptSubmitHooks,
28
28
  updateHookTranscriptForMessages
29
- } from "./chunk-VBLYYT4L.js";
29
+ } from "./chunk-NN2VFVIX.js";
30
30
  import {
31
31
  DEFAULT_OUTPUT_STYLE,
32
32
  getAvailableOutputStyles,
@@ -35,18 +35,17 @@ import {
35
35
  getOutputStyleSystemPromptAdditions,
36
36
  resolveOutputStyleName,
37
37
  setCurrentOutputStyle
38
- } from "./chunk-UHGE2VNM.js";
38
+ } from "./chunk-7NCAJ2EJ.js";
39
39
  import {
40
40
  fetchCustomModels,
41
41
  getModelFeatures,
42
- getSessionState,
43
- setSessionState
44
- } from "./chunk-OF4XXXQ3.js";
42
+ getSessionState
43
+ } from "./chunk-3PPYB2AK.js";
45
44
  import {
46
45
  queryLLM,
47
46
  queryQuick,
48
47
  verifyApiKey
49
- } from "./chunk-CPIJT73E.js";
48
+ } from "./chunk-5O3GVP7Z.js";
50
49
  import {
51
50
  DEFAULT_TIMEOUT_MS,
52
51
  FallbackToolUseRejectedMessage,
@@ -60,7 +59,7 @@ import {
60
59
  listMCPServers,
61
60
  loadMergedSettings,
62
61
  normalizeSandboxRuntimeConfigFromSettings
63
- } from "./chunk-CFPCW6W7.js";
62
+ } from "./chunk-OGXQURMW.js";
64
63
  import {
65
64
  addMarketplace,
66
65
  disableSkillPlugin,
@@ -73,11 +72,11 @@ import {
73
72
  refreshMarketplaceAsync,
74
73
  removeMarketplace,
75
74
  uninstallSkillPlugin
76
- } from "./chunk-37BP5U6M.js";
75
+ } from "./chunk-KVHO4FHL.js";
77
76
  import {
78
77
  loadToolPermissionContextFromDisk,
79
78
  persistToolPermissionUpdateToDisk
80
- } from "./chunk-POWN423Y.js";
79
+ } from "./chunk-XOSFFE2Y.js";
81
80
  import {
82
81
  applyToolPermissionContextUpdate,
83
82
  applyToolPermissionContextUpdates,
@@ -88,13 +87,13 @@ import {
88
87
  generateSystemReminders,
89
88
  resetReminderSession,
90
89
  systemReminderService
91
- } from "./chunk-DSIEFOTV.js";
90
+ } from "./chunk-C5LUBN6T.js";
92
91
  import {
93
92
  clearAgentCache,
94
93
  getActiveAgents,
95
94
  getAgentByType,
96
95
  getAllAgents
97
- } from "./chunk-XJ7FTO4Q.js";
96
+ } from "./chunk-7LDPOZZ6.js";
98
97
  import {
99
98
  API_ERROR_MESSAGE_PREFIX,
100
99
  CANCEL_MESSAGE,
@@ -125,7 +124,7 @@ import {
125
124
  processUserInput,
126
125
  reorderMessages,
127
126
  stripSystemMessages
128
- } from "./chunk-EXRF6SQY.js";
127
+ } from "./chunk-EE2HU2RS.js";
129
128
  import {
130
129
  getRequestStatus,
131
130
  setRequestStatus,
@@ -155,7 +154,7 @@ import {
155
154
  normalizeFilePath,
156
155
  readTextContent,
157
156
  writeTextContent
158
- } from "./chunk-OHJ6K3RB.js";
157
+ } from "./chunk-BEQTINGU.js";
159
158
  import {
160
159
  parseBlockEdits
161
160
  } from "./chunk-QWIBSCDN.js";
@@ -165,18 +164,18 @@ import {
165
164
  ParserRegistry,
166
165
  initParser,
167
166
  loadLanguage
168
- } from "./chunk-VDHPWKZV.js";
167
+ } from "./chunk-UDEREIRJ.js";
169
168
  import {
170
169
  getSettingsFileCandidates,
171
170
  loadSettingsWithLegacyFallback,
172
171
  readSettingsFile
173
- } from "./chunk-35JFWNXQ.js";
172
+ } from "./chunk-ISBXNGQB.js";
174
173
  import {
175
174
  getCustomCommandDirectories,
176
175
  hasCustomCommands,
177
176
  loadCustomCommands,
178
177
  reloadCustomCommands
179
- } from "./chunk-OXHRDN5X.js";
178
+ } from "./chunk-2V6NJ7DW.js";
180
179
  import {
181
180
  getSessionPlugins
182
181
  } from "./chunk-BJSWTHRM.js";
@@ -184,7 +183,7 @@ import {
184
183
  ModelManager,
185
184
  getModelManager,
186
185
  isDefaultSlowAndCapableModel
187
- } from "./chunk-6N2MGB6O.js";
186
+ } from "./chunk-PYASW53S.js";
188
187
  import {
189
188
  getCodeStyle,
190
189
  getContext,
@@ -192,13 +191,13 @@ import {
192
191
  getIsGit,
193
192
  getProjectDocs,
194
193
  getProjectStructureStatisticsBlock
195
- } from "./chunk-LHNIA7TU.js";
194
+ } from "./chunk-Y4PZVDDV.js";
196
195
  import {
197
196
  ripGrep
198
- } from "./chunk-GN3ZKIK6.js";
197
+ } from "./chunk-2EJTMBGJ.js";
199
198
  import {
200
199
  getTheme
201
- } from "./chunk-MLDL3JF6.js";
200
+ } from "./chunk-5AIERJLG.js";
202
201
  import {
203
202
  DEFAULT_GLOBAL_CONFIG,
204
203
  enableConfigs,
@@ -211,7 +210,7 @@ import {
211
210
  saveGlobalConfig,
212
211
  setAllPointersToModel,
213
212
  setModelPointer
214
- } from "./chunk-V4VOZJWR.js";
213
+ } from "./chunk-Z37IW5CA.js";
215
214
  import {
216
215
  AbortError
217
216
  } from "./chunk-RQVLBMP7.js";
@@ -220,7 +219,7 @@ import {
220
219
  getCurrentRequest,
221
220
  logUserFriendly,
222
221
  markPhase
223
- } from "./chunk-WKFRDCMK.js";
222
+ } from "./chunk-ZHVCG35Z.js";
224
223
  import {
225
224
  ASCII_LOGO,
226
225
  BunShell,
@@ -261,10 +260,10 @@ import {
261
260
  setCwd,
262
261
  shouldApplyToolOutputTruncation,
263
262
  truncateToolOutput
264
- } from "./chunk-HJ5SZ4TA.js";
263
+ } from "./chunk-LYA52DLL.js";
265
264
  import {
266
265
  MACRO
267
- } from "./chunk-WEUXBNQB.js";
266
+ } from "./chunk-GF57CLFI.js";
268
267
  import {
269
268
  __export
270
269
  } from "./chunk-I3J4JYES.js";
@@ -273,7 +272,7 @@ import {
273
272
  import { statSync as statSync13 } from "fs";
274
273
  import { EOL as EOL3 } from "os";
275
274
  import { isAbsolute as isAbsolute8, relative as relative12, resolve as resolve10 } from "path";
276
- import * as React111 from "react";
275
+ import * as React110 from "react";
277
276
  import { z as z15 } from "zod";
278
277
 
279
278
  // src/utils/commands/index.ts
@@ -445,7 +444,7 @@ var getCommandSubcommandPrefix = memoize(
445
444
  var getCommandPrefix = memoize(
446
445
  async (command4, abortSignal) => {
447
446
  const { systemPrompt, userPrompt } = buildBashCommandPrefixDetectionPrompt(command4);
448
- const { API_ERROR_MESSAGE_PREFIX: API_ERROR_MESSAGE_PREFIX2, queryQuick: queryQuick2 } = await import("./llm-5RBAGTX5.js");
447
+ const { API_ERROR_MESSAGE_PREFIX: API_ERROR_MESSAGE_PREFIX2, queryQuick: queryQuick2 } = await import("./llm-VY6RXJY7.js");
449
448
  const response = await queryQuick2({
450
449
  systemPrompt,
451
450
  userPrompt,
@@ -4247,7 +4246,7 @@ function formatParseError(error) {
4247
4246
  return error instanceof Error ? error.message : String(error);
4248
4247
  }
4249
4248
  async function defaultGateQuery(args) {
4250
- const { API_ERROR_MESSAGE_PREFIX: API_ERROR_MESSAGE_PREFIX2, queryLLM: queryLLM2 } = await import("./llm-5RBAGTX5.js");
4249
+ const { API_ERROR_MESSAGE_PREFIX: API_ERROR_MESSAGE_PREFIX2, queryLLM: queryLLM2 } = await import("./llm-VY6RXJY7.js");
4251
4250
  const queryLLMFn = args.queryLLMOverride ?? queryLLM2;
4252
4251
  const messages = [
4253
4252
  {
@@ -5266,8 +5265,8 @@ ${formatted}`;
5266
5265
  };
5267
5266
 
5268
5267
  // src/ui/components/permissions/web-fetch-permission-request/WebFetchPermissionRequest.tsx
5269
- import { Box as Box81, Text as Text85, useInput as useInput31 } from "ink";
5270
- import React110, { useMemo as useMemo28 } from "react";
5268
+ import { Box as Box80, Text as Text84, useInput as useInput31 } from "ink";
5269
+ import React109, { useMemo as useMemo28 } from "react";
5271
5270
  import chalk16 from "chalk";
5272
5271
 
5273
5272
  // src/ui/components/custom-select/select.tsx
@@ -6644,7 +6643,7 @@ var FileEditTool = {
6644
6643
  const originalFileContent = currentFileContent;
6645
6644
  let totalPatch = [];
6646
6645
  const { SmartEdit } = await import("./smart-edit-AWHJDSU6.js");
6647
- const { findLspAnchor } = await import("./lspAnchor-JS73KKBP.js");
6646
+ const { findLspAnchor } = await import("./lspAnchor-FK5YBDE6.js");
6648
6647
  for (const op of editOperations) {
6649
6648
  const normalizedSearch = normalizeLineEndings(op.search);
6650
6649
  const normalizedReplace = normalizeLineEndings(op.replace);
@@ -8910,7 +8909,7 @@ var WebSearchTool = {
8910
8909
 
8911
8910
  // src/tools/interaction/SlashCommandTool/SlashCommandTool.tsx
8912
8911
  import { z as z13 } from "zod";
8913
- import * as React108 from "react";
8912
+ import * as React107 from "react";
8914
8913
 
8915
8914
  // src/ui/components/Bug.tsx
8916
8915
  import { Box as Box17, Text as Text19, useInput as useInput5 } from "ink";
@@ -11279,7 +11278,7 @@ async function createAndStoreApiKey(accessToken) {
11279
11278
  }
11280
11279
  saveGlobalConfig(config2);
11281
11280
  try {
11282
- const { resetAnthropicClient } = await import("./llm-5RBAGTX5.js");
11281
+ const { resetAnthropicClient } = await import("./llm-VY6RXJY7.js");
11283
11282
  resetAnthropicClient();
11284
11283
  } catch {
11285
11284
  }
@@ -15646,7 +15645,7 @@ async function refreshPluginRuntimeFromInstalls() {
15646
15645
  const existingRoots = getSessionPlugins().map((p) => p.rootDir);
15647
15646
  const dirs = Array.from(/* @__PURE__ */ new Set([...existingRoots, ...installedRoots]));
15648
15647
  if (dirs.length === 0) return [];
15649
- const { configureSessionPlugins } = await import("./pluginRuntime-7URRA2OK.js");
15648
+ const { configureSessionPlugins } = await import("./pluginRuntime-PWEYBXJ4.js");
15650
15649
  const { errors } = await configureSessionPlugins({ pluginDirs: dirs });
15651
15650
  return errors;
15652
15651
  }
@@ -16315,7 +16314,7 @@ async function call(onDone, context) {
16315
16314
  ModelConfig,
16316
16315
  {
16317
16316
  onClose: () => {
16318
- import("./model-ZVCXE44R.js").then(({ reloadModelManager: reloadModelManager2 }) => {
16317
+ import("./model-BVFVXXKO.js").then(({ reloadModelManager: reloadModelManager2 }) => {
16319
16318
  reloadModelManager2();
16320
16319
  triggerModelConfigChange();
16321
16320
  onDone();
@@ -17449,14 +17448,14 @@ async function call2(onDone, context) {
17449
17448
  }
17450
17449
 
17451
17450
  // src/commands/resume.tsx
17452
- import * as React105 from "react";
17451
+ import * as React104 from "react";
17453
17452
 
17454
17453
  // src/ui/screens/ResumeConversation.tsx
17455
- import React104 from "react";
17454
+ import React103 from "react";
17456
17455
  import { render } from "ink";
17457
17456
 
17458
17457
  // src/ui/screens/REPL.tsx
17459
- import { Box as Box77, Newline as Newline4, Static as Static2 } from "ink";
17458
+ import { Box as Box76, Newline as Newline4, Static as Static2 } from "ink";
17460
17459
 
17461
17460
  // src/ui/components/CostThresholdDialog.tsx
17462
17461
  import { Box as Box37, Text as Text42, useInput as useInput17 } from "ink";
@@ -17509,7 +17508,7 @@ function CostThresholdDialog({ onDone }) {
17509
17508
  }
17510
17509
 
17511
17510
  // src/ui/screens/REPL.tsx
17512
- import * as React102 from "react";
17511
+ import * as React101 from "react";
17513
17512
  import { useEffect as useEffect26, useMemo as useMemo26, useRef as useRef13, useState as useState28, useCallback as useCallback16 } from "react";
17514
17513
 
17515
17514
  // src/ui/components/Message.tsx
@@ -19763,29 +19762,15 @@ function TaskPanel({
19763
19762
  }), hidden.length > 0 ? /* @__PURE__ */ React74.createElement(Text59, null, "\u2026 +", hiddenPending > 0 ? hiddenPending : hidden.length, " pending") : null);
19764
19763
  }
19765
19764
 
19766
- // src/ui/components/QueuedMessageList.tsx
19767
- import { Box as Box55, Text as Text60 } from "ink";
19768
- import React75 from "react";
19769
- function QueuedMessageList({ items }) {
19770
- if (items.length === 0) return null;
19771
- return /* @__PURE__ */ React75.createElement(Box55, { flexDirection: "column", width: "100%" }, items.map((item) => /* @__PURE__ */ React75.createElement(Box55, { key: item.id, width: "100%" }, /* @__PURE__ */ React75.createElement(Text60, { backgroundColor: "white", color: "black" }, item.content))));
19772
- }
19773
- function QueuedHintLine({
19774
- show
19775
- }) {
19776
- if (!show) return null;
19777
- return /* @__PURE__ */ React75.createElement(Box55, { paddingLeft: 2, paddingRight: 2 }, /* @__PURE__ */ React75.createElement(Text60, { dimColor: true }, "Press up to edit queued messages"));
19778
- }
19779
-
19780
19765
  // src/ui/components/permissions/PermissionRequest.tsx
19781
19766
  import { useInput as useInput25 } from "ink";
19782
- import * as React93 from "react";
19767
+ import * as React92 from "react";
19783
19768
 
19784
19769
  // src/ui/components/permissions/file-edit-permission-request/FileEditPermissionRequest.tsx
19785
19770
  import chalk7 from "chalk";
19786
- import { Box as Box58, Text as Text63, useInput as useInput19 } from "ink";
19771
+ import { Box as Box57, Text as Text62, useInput as useInput19 } from "ink";
19787
19772
  import { basename, dirname as dirname5, extname as extname6 } from "path";
19788
- import React78, { useCallback as useCallback8, useMemo as useMemo15 } from "react";
19773
+ import React77, { useCallback as useCallback8, useMemo as useMemo15 } from "react";
19789
19774
 
19790
19775
  // src/ui/hooks/usePermissionRequestLogging.ts
19791
19776
  import { useEffect as useEffect17 } from "react";
@@ -19813,8 +19798,8 @@ function usePermissionRequestLogging(toolUseConfirm, unaryEvent) {
19813
19798
  }
19814
19799
 
19815
19800
  // src/ui/components/permissions/PermissionRequestTitle.tsx
19816
- import * as React76 from "react";
19817
- import { Box as Box56, Text as Text61 } from "ink";
19801
+ import * as React75 from "react";
19802
+ import { Box as Box55, Text as Text60 } from "ink";
19818
19803
  function categoryForRiskScore(riskScore) {
19819
19804
  return riskScore >= 70 ? "high" : riskScore >= 30 ? "moderate" : "low";
19820
19805
  }
@@ -19849,20 +19834,20 @@ function PermissionRiskScore({
19849
19834
  riskScore
19850
19835
  }) {
19851
19836
  const category = categoryForRiskScore(riskScore);
19852
- return /* @__PURE__ */ React76.createElement(Text61, { color: textColorForRiskScore(riskScore) }, "Risk: ", category);
19837
+ return /* @__PURE__ */ React75.createElement(Text60, { color: textColorForRiskScore(riskScore) }, "Risk: ", category);
19853
19838
  }
19854
19839
  function PermissionRequestTitle({
19855
19840
  title,
19856
19841
  riskScore
19857
19842
  }) {
19858
- return /* @__PURE__ */ React76.createElement(Box56, { flexDirection: "column" }, /* @__PURE__ */ React76.createElement(Text61, { bold: true, color: getTheme().permission }, title), riskScore !== null && /* @__PURE__ */ React76.createElement(PermissionRiskScore, { riskScore }));
19843
+ return /* @__PURE__ */ React75.createElement(Box55, { flexDirection: "column" }, /* @__PURE__ */ React75.createElement(Text60, { bold: true, color: getTheme().permission }, title), riskScore !== null && /* @__PURE__ */ React75.createElement(PermissionRiskScore, { riskScore }));
19859
19844
  }
19860
19845
 
19861
19846
  // src/ui/components/permissions/file-edit-permission-request/FileEditToolDiff.tsx
19862
- import * as React77 from "react";
19847
+ import * as React76 from "react";
19863
19848
  import { existsSync as existsSync10, readFileSync as readFileSync7 } from "fs";
19864
19849
  import { useMemo as useMemo14 } from "react";
19865
- import { Box as Box57, Text as Text62 } from "ink";
19850
+ import { Box as Box56, Text as Text61 } from "ink";
19866
19851
  import { relative as relative10 } from "path";
19867
19852
  function FileEditToolDiff({
19868
19853
  file_path,
@@ -19885,17 +19870,17 @@ function FileEditToolDiff({
19885
19870
  }),
19886
19871
  [file_path, file, old_string, new_string]
19887
19872
  );
19888
- return /* @__PURE__ */ React77.createElement(Box57, { flexDirection: "column" }, /* @__PURE__ */ React77.createElement(
19889
- Box57,
19873
+ return /* @__PURE__ */ React76.createElement(Box56, { flexDirection: "column" }, /* @__PURE__ */ React76.createElement(
19874
+ Box56,
19890
19875
  {
19891
19876
  borderColor: getTheme().secondaryBorder,
19892
19877
  borderStyle: useBorder ? "round" : void 0,
19893
19878
  flexDirection: "column",
19894
19879
  paddingX: 1
19895
19880
  },
19896
- /* @__PURE__ */ React77.createElement(Box57, { paddingBottom: 1 }, /* @__PURE__ */ React77.createElement(Text62, { bold: true }, verbose ? file_path : relative10(getCwd(), file_path))),
19881
+ /* @__PURE__ */ React76.createElement(Box56, { paddingBottom: 1 }, /* @__PURE__ */ React76.createElement(Text61, { bold: true }, verbose ? file_path : relative10(getCwd(), file_path))),
19897
19882
  intersperse(
19898
- patch.map((_) => /* @__PURE__ */ React77.createElement(
19883
+ patch.map((_) => /* @__PURE__ */ React76.createElement(
19899
19884
  StructuredDiff,
19900
19885
  {
19901
19886
  key: _.newStart,
@@ -19904,7 +19889,7 @@ function FileEditToolDiff({
19904
19889
  width
19905
19890
  }
19906
19891
  )),
19907
- (i) => /* @__PURE__ */ React77.createElement(React77.Fragment, { key: `ellipsis-${i}` }, /* @__PURE__ */ React77.createElement(Text62, { color: getTheme().secondaryText }, "..."))
19892
+ (i) => /* @__PURE__ */ React76.createElement(React76.Fragment, { key: `ellipsis-${i}` }, /* @__PURE__ */ React76.createElement(Text61, { color: getTheme().secondaryText }, "..."))
19908
19893
  )
19909
19894
  ));
19910
19895
  }
@@ -20086,8 +20071,8 @@ function FileEditPermissionRequest({
20086
20071
  handleChoice("yes-session");
20087
20072
  return true;
20088
20073
  });
20089
- return /* @__PURE__ */ React78.createElement(
20090
- Box58,
20074
+ return /* @__PURE__ */ React77.createElement(
20075
+ Box57,
20091
20076
  {
20092
20077
  flexDirection: "column",
20093
20078
  borderStyle: "round",
@@ -20097,14 +20082,14 @@ function FileEditPermissionRequest({
20097
20082
  paddingRight: 1,
20098
20083
  paddingBottom: 1
20099
20084
  },
20100
- /* @__PURE__ */ React78.createElement(
20085
+ /* @__PURE__ */ React77.createElement(
20101
20086
  PermissionRequestTitle,
20102
20087
  {
20103
20088
  title: "Edit file",
20104
20089
  riskScore: toolUseConfirm.riskScore
20105
20090
  }
20106
20091
  ),
20107
- /* @__PURE__ */ React78.createElement(
20092
+ /* @__PURE__ */ React77.createElement(
20108
20093
  FileEditToolDiff,
20109
20094
  {
20110
20095
  file_path,
@@ -20114,7 +20099,7 @@ function FileEditPermissionRequest({
20114
20099
  width: columns - 12
20115
20100
  }
20116
20101
  ),
20117
- /* @__PURE__ */ React78.createElement(Box58, { flexDirection: "column" }, /* @__PURE__ */ React78.createElement(Text63, null, "Do you want to make this edit to", " ", /* @__PURE__ */ React78.createElement(Text63, { bold: true }, basename(file_path)), "?"), /* @__PURE__ */ React78.createElement(
20102
+ /* @__PURE__ */ React77.createElement(Box57, { flexDirection: "column" }, /* @__PURE__ */ React77.createElement(Text62, null, "Do you want to make this edit to", " ", /* @__PURE__ */ React77.createElement(Text62, { bold: true }, basename(file_path)), "?"), /* @__PURE__ */ React77.createElement(
20118
20103
  Select,
20119
20104
  {
20120
20105
  options: getOptions({
@@ -20138,8 +20123,8 @@ async function extractLanguageName(file_path) {
20138
20123
  }
20139
20124
 
20140
20125
  // src/ui/components/permissions/bash-permission-request/BashPermissionRequest.tsx
20141
- import { Box as Box59, Text as Text64 } from "ink";
20142
- import React79, { useMemo as useMemo16 } from "react";
20126
+ import { Box as Box58, Text as Text63 } from "ink";
20127
+ import React78, { useMemo as useMemo16 } from "react";
20143
20128
 
20144
20129
  // src/ui/components/permissions/hooks.ts
20145
20130
  import { useEffect as useEffect18 } from "react";
@@ -20244,8 +20229,8 @@ function BashPermissionRequest({
20244
20229
  []
20245
20230
  );
20246
20231
  usePermissionRequestLogging2(toolUseConfirm, unaryEvent);
20247
- return /* @__PURE__ */ React79.createElement(
20248
- Box59,
20232
+ return /* @__PURE__ */ React78.createElement(
20233
+ Box58,
20249
20234
  {
20250
20235
  flexDirection: "column",
20251
20236
  borderStyle: "round",
@@ -20255,19 +20240,19 @@ function BashPermissionRequest({
20255
20240
  paddingRight: 1,
20256
20241
  paddingBottom: 1
20257
20242
  },
20258
- /* @__PURE__ */ React79.createElement(
20243
+ /* @__PURE__ */ React78.createElement(
20259
20244
  PermissionRequestTitle,
20260
20245
  {
20261
20246
  title: "Bash command",
20262
20247
  riskScore: toolUseConfirm.riskScore
20263
20248
  }
20264
20249
  ),
20265
- /* @__PURE__ */ React79.createElement(Box59, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React79.createElement(Text64, null, BashTool.renderToolUseMessage({
20250
+ /* @__PURE__ */ React78.createElement(Box58, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React78.createElement(Text63, null, BashTool.renderToolUseMessage({
20266
20251
  command: command4,
20267
20252
  run_in_background,
20268
20253
  description: description3
20269
- })), /* @__PURE__ */ React79.createElement(Text64, { color: theme.secondaryText }, toolUseConfirm.description)),
20270
- /* @__PURE__ */ React79.createElement(Box59, { flexDirection: "column" }, /* @__PURE__ */ React79.createElement(Text64, null, "Do you want to proceed?"), /* @__PURE__ */ React79.createElement(
20254
+ })), /* @__PURE__ */ React78.createElement(Text63, { color: theme.secondaryText }, toolUseConfirm.description)),
20255
+ /* @__PURE__ */ React78.createElement(Box58, { flexDirection: "column" }, /* @__PURE__ */ React78.createElement(Text63, null, "Do you want to proceed?"), /* @__PURE__ */ React78.createElement(
20271
20256
  Select,
20272
20257
  {
20273
20258
  options: toolUseOptions({ toolUseConfirm, command: command4 }),
@@ -20335,8 +20320,8 @@ function BashPermissionRequest({
20335
20320
  }
20336
20321
 
20337
20322
  // src/ui/components/permissions/FallbackPermissionRequest.tsx
20338
- import { Box as Box60, Text as Text65 } from "ink";
20339
- import React80, { useMemo as useMemo17 } from "react";
20323
+ import { Box as Box59, Text as Text64 } from "ink";
20324
+ import React79, { useMemo as useMemo17 } from "react";
20340
20325
  import chalk9 from "chalk";
20341
20326
  function __getFallbackPermissionInputForTests(tool, input) {
20342
20327
  return tool === WebSearchTool ? { query: "" } : input;
@@ -20357,8 +20342,8 @@ function FallbackPermissionRequest({
20357
20342
  []
20358
20343
  );
20359
20344
  usePermissionRequestLogging(toolUseConfirm, unaryEvent);
20360
- return /* @__PURE__ */ React80.createElement(
20361
- Box60,
20345
+ return /* @__PURE__ */ React79.createElement(
20346
+ Box59,
20362
20347
  {
20363
20348
  flexDirection: "column",
20364
20349
  borderStyle: "round",
@@ -20368,18 +20353,18 @@ function FallbackPermissionRequest({
20368
20353
  paddingRight: 1,
20369
20354
  paddingBottom: 1
20370
20355
  },
20371
- /* @__PURE__ */ React80.createElement(
20356
+ /* @__PURE__ */ React79.createElement(
20372
20357
  PermissionRequestTitle,
20373
20358
  {
20374
20359
  title: "Tool use",
20375
20360
  riskScore: toolUseConfirm.riskScore
20376
20361
  }
20377
20362
  ),
20378
- /* @__PURE__ */ React80.createElement(Box60, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React80.createElement(Text65, null, userFacingName3, "(", toolUseConfirm.tool.renderToolUseMessage(
20363
+ /* @__PURE__ */ React79.createElement(Box59, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React79.createElement(Text64, null, userFacingName3, "(", toolUseConfirm.tool.renderToolUseMessage(
20379
20364
  toolUseConfirm.input,
20380
20365
  { verbose }
20381
- ), ")", originalUserFacingName.endsWith(" (MCP)") ? /* @__PURE__ */ React80.createElement(Text65, { color: theme.secondaryText }, " (MCP)") : ""), /* @__PURE__ */ React80.createElement(Text65, { color: theme.secondaryText }, toolUseConfirm.description)),
20382
- /* @__PURE__ */ React80.createElement(Box60, { flexDirection: "column" }, /* @__PURE__ */ React80.createElement(Text65, null, "Do you want to proceed?"), /* @__PURE__ */ React80.createElement(
20366
+ ), ")", originalUserFacingName.endsWith(" (MCP)") ? /* @__PURE__ */ React79.createElement(Text64, { color: theme.secondaryText }, " (MCP)") : ""), /* @__PURE__ */ React79.createElement(Text64, { color: theme.secondaryText }, toolUseConfirm.description)),
20367
+ /* @__PURE__ */ React79.createElement(Box59, { flexDirection: "column" }, /* @__PURE__ */ React79.createElement(Text64, null, "Do you want to proceed?"), /* @__PURE__ */ React79.createElement(
20383
20368
  Select,
20384
20369
  {
20385
20370
  options: [
@@ -20495,17 +20480,17 @@ function useNotifyAfterTimeout(message, timeout = DEFAULT_INTERACTION_THRESHOLD_
20495
20480
  }
20496
20481
 
20497
20482
  // src/ui/components/permissions/file-write-permission-request/FileWritePermissionRequest.tsx
20498
- import { Box as Box62, Text as Text67, useInput as useInput20 } from "ink";
20499
- import React82, { useCallback as useCallback9, useMemo as useMemo19 } from "react";
20483
+ import { Box as Box61, Text as Text66, useInput as useInput20 } from "ink";
20484
+ import React81, { useCallback as useCallback9, useMemo as useMemo19 } from "react";
20500
20485
  import { basename as basename2, dirname as dirname6, extname as extname8 } from "path";
20501
20486
  import { existsSync as existsSync12 } from "fs";
20502
20487
  import chalk10 from "chalk";
20503
20488
 
20504
20489
  // src/ui/components/permissions/file-write-permission-request/FileWriteToolDiff.tsx
20505
- import * as React81 from "react";
20490
+ import * as React80 from "react";
20506
20491
  import { existsSync as existsSync11, readFileSync as readFileSync8 } from "fs";
20507
20492
  import { useMemo as useMemo18 } from "react";
20508
- import { Box as Box61, Text as Text66 } from "ink";
20493
+ import { Box as Box60, Text as Text65 } from "ink";
20509
20494
  import { extname as extname7, relative as relative11 } from "path";
20510
20495
  function FileWriteToolDiff({
20511
20496
  file_path,
@@ -20532,17 +20517,17 @@ function FileWriteToolDiff({
20532
20517
  newStr: content
20533
20518
  });
20534
20519
  }, [fileExists, file_path, oldContent, content]);
20535
- return /* @__PURE__ */ React81.createElement(
20536
- Box61,
20520
+ return /* @__PURE__ */ React80.createElement(
20521
+ Box60,
20537
20522
  {
20538
20523
  borderColor: getTheme().secondaryBorder,
20539
20524
  borderStyle: "round",
20540
20525
  flexDirection: "column",
20541
20526
  paddingX: 1
20542
20527
  },
20543
- /* @__PURE__ */ React81.createElement(Box61, { paddingBottom: 1 }, /* @__PURE__ */ React81.createElement(Text66, { bold: true }, verbose ? file_path : relative11(getCwd(), file_path))),
20528
+ /* @__PURE__ */ React80.createElement(Box60, { paddingBottom: 1 }, /* @__PURE__ */ React80.createElement(Text65, { bold: true }, verbose ? file_path : relative11(getCwd(), file_path))),
20544
20529
  hunks ? intersperse(
20545
- hunks.map((_) => /* @__PURE__ */ React81.createElement(
20530
+ hunks.map((_) => /* @__PURE__ */ React80.createElement(
20546
20531
  StructuredDiff,
20547
20532
  {
20548
20533
  key: _.newStart,
@@ -20551,8 +20536,8 @@ function FileWriteToolDiff({
20551
20536
  width
20552
20537
  }
20553
20538
  )),
20554
- (i) => /* @__PURE__ */ React81.createElement(React81.Fragment, { key: `ellipsis-${i}` }, /* @__PURE__ */ React81.createElement(Text66, { color: getTheme().secondaryText }, "..."))
20555
- ) : /* @__PURE__ */ React81.createElement(
20539
+ (i) => /* @__PURE__ */ React80.createElement(React80.Fragment, { key: `ellipsis-${i}` }, /* @__PURE__ */ React80.createElement(Text65, { color: getTheme().secondaryText }, "..."))
20540
+ ) : /* @__PURE__ */ React80.createElement(
20556
20541
  HighlightedCode,
20557
20542
  {
20558
20543
  code: content || "(No content)",
@@ -20687,8 +20672,8 @@ function FileWritePermissionRequest({
20687
20672
  handleChoice("yes-session");
20688
20673
  return true;
20689
20674
  });
20690
- return /* @__PURE__ */ React82.createElement(
20691
- Box62,
20675
+ return /* @__PURE__ */ React81.createElement(
20676
+ Box61,
20692
20677
  {
20693
20678
  flexDirection: "column",
20694
20679
  borderStyle: "round",
@@ -20698,14 +20683,14 @@ function FileWritePermissionRequest({
20698
20683
  paddingRight: 1,
20699
20684
  paddingBottom: 1
20700
20685
  },
20701
- /* @__PURE__ */ React82.createElement(
20686
+ /* @__PURE__ */ React81.createElement(
20702
20687
  PermissionRequestTitle,
20703
20688
  {
20704
20689
  title: `${fileExists ? "Edit" : "Create"} file`,
20705
20690
  riskScore: toolUseConfirm.riskScore
20706
20691
  }
20707
20692
  ),
20708
- /* @__PURE__ */ React82.createElement(Box62, { flexDirection: "column" }, /* @__PURE__ */ React82.createElement(
20693
+ /* @__PURE__ */ React81.createElement(Box61, { flexDirection: "column" }, /* @__PURE__ */ React81.createElement(
20709
20694
  FileWriteToolDiff,
20710
20695
  {
20711
20696
  file_path,
@@ -20714,7 +20699,7 @@ function FileWritePermissionRequest({
20714
20699
  width: columns - 12
20715
20700
  }
20716
20701
  )),
20717
- /* @__PURE__ */ React82.createElement(Box62, { flexDirection: "column" }, /* @__PURE__ */ React82.createElement(Text67, null, "Do you want to ", fileExists ? "make this edit to" : "create", " ", /* @__PURE__ */ React82.createElement(Text67, { bold: true }, basename2(file_path)), "?"), /* @__PURE__ */ React82.createElement(
20702
+ /* @__PURE__ */ React81.createElement(Box61, { flexDirection: "column" }, /* @__PURE__ */ React81.createElement(Text66, null, "Do you want to ", fileExists ? "make this edit to" : "create", " ", /* @__PURE__ */ React81.createElement(Text66, { bold: true }, basename2(file_path)), "?"), /* @__PURE__ */ React81.createElement(
20718
20703
  Select,
20719
20704
  {
20720
20705
  options: [
@@ -20748,8 +20733,8 @@ async function extractLanguageName2(file_path) {
20748
20733
  }
20749
20734
 
20750
20735
  // src/ui/components/permissions/filesystem-permission-request/FilesystemPermissionRequest.tsx
20751
- import { Box as Box63, Text as Text68, useInput as useInput21 } from "ink";
20752
- import React83, { useCallback as useCallback10, useMemo as useMemo20 } from "react";
20736
+ import { Box as Box62, Text as Text67, useInput as useInput21 } from "ink";
20737
+ import React82, { useCallback as useCallback10, useMemo as useMemo20 } from "react";
20753
20738
  import chalk11 from "chalk";
20754
20739
  import { basename as basename3, dirname as dirname7 } from "path";
20755
20740
  import { statSync as statSync10 } from "fs";
@@ -20806,7 +20791,7 @@ function FilesystemPermissionRequest({
20806
20791
  }) {
20807
20792
  const path5 = pathFromToolUse(toolUseConfirm);
20808
20793
  if (!path5) {
20809
- return /* @__PURE__ */ React83.createElement(
20794
+ return /* @__PURE__ */ React82.createElement(
20810
20795
  FallbackPermissionRequest,
20811
20796
  {
20812
20797
  toolUseConfirm,
@@ -20815,7 +20800,7 @@ function FilesystemPermissionRequest({
20815
20800
  }
20816
20801
  );
20817
20802
  }
20818
- return /* @__PURE__ */ React83.createElement(
20803
+ return /* @__PURE__ */ React82.createElement(
20819
20804
  FilesystemPermissionRequestImpl,
20820
20805
  {
20821
20806
  toolUseConfirm,
@@ -20957,8 +20942,8 @@ function FilesystemPermissionRequestImpl({
20957
20942
  handleChoice("yes-session");
20958
20943
  return true;
20959
20944
  });
20960
- return /* @__PURE__ */ React83.createElement(
20961
- Box63,
20945
+ return /* @__PURE__ */ React82.createElement(
20946
+ Box62,
20962
20947
  {
20963
20948
  flexDirection: "column",
20964
20949
  borderStyle: "round",
@@ -20968,18 +20953,18 @@ function FilesystemPermissionRequestImpl({
20968
20953
  paddingRight: 1,
20969
20954
  paddingBottom: 1
20970
20955
  },
20971
- /* @__PURE__ */ React83.createElement(
20956
+ /* @__PURE__ */ React82.createElement(
20972
20957
  PermissionRequestTitle,
20973
20958
  {
20974
20959
  title,
20975
20960
  riskScore: toolUseConfirm.riskScore
20976
20961
  }
20977
20962
  ),
20978
- /* @__PURE__ */ React83.createElement(Box63, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React83.createElement(Text68, null, userFacingName3, "(", toolUseConfirm.tool.renderToolUseMessage(
20963
+ /* @__PURE__ */ React82.createElement(Box62, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React82.createElement(Text67, null, userFacingName3, "(", toolUseConfirm.tool.renderToolUseMessage(
20979
20964
  toolUseConfirm.input,
20980
20965
  { verbose }
20981
20966
  ), ")")),
20982
- /* @__PURE__ */ React83.createElement(Box63, { flexDirection: "column" }, /* @__PURE__ */ React83.createElement(Text68, null, "Do you want to proceed?"), /* @__PURE__ */ React83.createElement(
20967
+ /* @__PURE__ */ React82.createElement(Box62, { flexDirection: "column" }, /* @__PURE__ */ React82.createElement(Text67, null, "Do you want to proceed?"), /* @__PURE__ */ React82.createElement(
20983
20968
  Select,
20984
20969
  {
20985
20970
  options: [
@@ -21007,7 +20992,7 @@ function FilesystemPermissionRequestImpl({
21007
20992
 
21008
20993
  // src/tools/ai/SkillTool/SkillTool.tsx
21009
20994
  import { z as z9 } from "zod";
21010
- import * as React84 from "react";
20995
+ import * as React83 from "react";
21011
20996
 
21012
20997
  // src/tools/ai/SkillTool/prompt.ts
21013
20998
  var TOOL_NAME_FOR_PROMPT5 = "Skill";
@@ -21104,7 +21089,7 @@ ${availableSkills}${truncatedNotice}
21104
21089
  return skill || "";
21105
21090
  },
21106
21091
  renderToolUseRejectedMessage() {
21107
- return /* @__PURE__ */ React84.createElement(FallbackToolUseRejectedMessage, null);
21092
+ return /* @__PURE__ */ React83.createElement(FallbackToolUseRejectedMessage, null);
21108
21093
  },
21109
21094
  renderResultForAssistant(output) {
21110
21095
  return `Launching skill: ${output.commandName}`;
@@ -21239,8 +21224,8 @@ function findCommand(commandName, commands) {
21239
21224
  }
21240
21225
 
21241
21226
  // src/ui/components/permissions/slash-command-permission-request/SlashCommandPermissionRequest.tsx
21242
- import { Box as Box64, Text as Text69 } from "ink";
21243
- import React85, { useMemo as useMemo21 } from "react";
21227
+ import { Box as Box63, Text as Text68 } from "ink";
21228
+ import React84, { useMemo as useMemo21 } from "react";
21244
21229
  import chalk12 from "chalk";
21245
21230
  function parsePrefix(command4) {
21246
21231
  const trimmed = command4.trim();
@@ -21265,8 +21250,8 @@ function SlashCommandPermissionRequest({
21265
21250
  const command4 = typeof toolUseConfirm.input.command === "string" ? toolUseConfirm.input.command : "";
21266
21251
  const prefix = parsePrefix(command4);
21267
21252
  const showPrefixOption = !!prefix && hasArgs(command4);
21268
- return /* @__PURE__ */ React85.createElement(
21269
- Box64,
21253
+ return /* @__PURE__ */ React84.createElement(
21254
+ Box63,
21270
21255
  {
21271
21256
  flexDirection: "column",
21272
21257
  borderStyle: "round",
@@ -21276,14 +21261,14 @@ function SlashCommandPermissionRequest({
21276
21261
  paddingRight: 1,
21277
21262
  paddingBottom: 1
21278
21263
  },
21279
- /* @__PURE__ */ React85.createElement(PermissionRequestTitle, { title: "Slash command", riskScore: null }),
21280
- /* @__PURE__ */ React85.createElement(Box64, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React85.createElement(Text69, null, toolUseConfirm.tool.userFacingName?.() || "SlashCommand", "(", toolUseConfirm.tool.renderToolUseMessage(
21264
+ /* @__PURE__ */ React84.createElement(PermissionRequestTitle, { title: "Slash command", riskScore: null }),
21265
+ /* @__PURE__ */ React84.createElement(Box63, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React84.createElement(Text68, null, toolUseConfirm.tool.userFacingName?.() || "SlashCommand", "(", toolUseConfirm.tool.renderToolUseMessage(
21281
21266
  toolUseConfirm.input,
21282
21267
  {
21283
21268
  verbose
21284
21269
  }
21285
- ), ")"), /* @__PURE__ */ React85.createElement(Text69, { color: theme.secondaryText }, toolUseConfirm.description)),
21286
- /* @__PURE__ */ React85.createElement(Box64, { flexDirection: "column" }, /* @__PURE__ */ React85.createElement(Text69, null, "Do you want to proceed?"), /* @__PURE__ */ React85.createElement(
21270
+ ), ")"), /* @__PURE__ */ React84.createElement(Text68, { color: theme.secondaryText }, toolUseConfirm.description)),
21271
+ /* @__PURE__ */ React84.createElement(Box63, { flexDirection: "column" }, /* @__PURE__ */ React84.createElement(Text68, null, "Do you want to proceed?"), /* @__PURE__ */ React84.createElement(
21287
21272
  Select,
21288
21273
  {
21289
21274
  options: [
@@ -21384,8 +21369,8 @@ function SlashCommandPermissionRequest({
21384
21369
  }
21385
21370
 
21386
21371
  // src/ui/components/permissions/skill-permission-request/SkillPermissionRequest.tsx
21387
- import { Box as Box65, Text as Text70 } from "ink";
21388
- import React86, { useMemo as useMemo22 } from "react";
21372
+ import { Box as Box64, Text as Text69 } from "ink";
21373
+ import React85, { useMemo as useMemo22 } from "react";
21389
21374
  import chalk13 from "chalk";
21390
21375
  function SkillPermissionRequest({
21391
21376
  toolUseConfirm,
@@ -21400,8 +21385,8 @@ function SkillPermissionRequest({
21400
21385
  usePermissionRequestLogging(toolUseConfirm, unaryEvent);
21401
21386
  const raw = typeof toolUseConfirm.input.skill === "string" ? toolUseConfirm.input.skill : "";
21402
21387
  const skill = raw.trim().replace(/^\//, "");
21403
- return /* @__PURE__ */ React86.createElement(
21404
- Box65,
21388
+ return /* @__PURE__ */ React85.createElement(
21389
+ Box64,
21405
21390
  {
21406
21391
  flexDirection: "column",
21407
21392
  borderStyle: "round",
@@ -21411,14 +21396,14 @@ function SkillPermissionRequest({
21411
21396
  paddingRight: 1,
21412
21397
  paddingBottom: 1
21413
21398
  },
21414
- /* @__PURE__ */ React86.createElement(PermissionRequestTitle, { title: "Skill", riskScore: null }),
21415
- /* @__PURE__ */ React86.createElement(Box65, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React86.createElement(Text70, null, toolUseConfirm.tool.userFacingName?.() || "Skill", "(", toolUseConfirm.tool.renderToolUseMessage(
21399
+ /* @__PURE__ */ React85.createElement(PermissionRequestTitle, { title: "Skill", riskScore: null }),
21400
+ /* @__PURE__ */ React85.createElement(Box64, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React85.createElement(Text69, null, toolUseConfirm.tool.userFacingName?.() || "Skill", "(", toolUseConfirm.tool.renderToolUseMessage(
21416
21401
  toolUseConfirm.input,
21417
21402
  {
21418
21403
  verbose
21419
21404
  }
21420
- ), ")"), /* @__PURE__ */ React86.createElement(Text70, { color: theme.secondaryText }, toolUseConfirm.description)),
21421
- /* @__PURE__ */ React86.createElement(Box65, { flexDirection: "column" }, /* @__PURE__ */ React86.createElement(Text70, null, "Do you want to proceed?"), /* @__PURE__ */ React86.createElement(
21405
+ ), ")"), /* @__PURE__ */ React85.createElement(Text69, { color: theme.secondaryText }, toolUseConfirm.description)),
21406
+ /* @__PURE__ */ React85.createElement(Box64, { flexDirection: "column" }, /* @__PURE__ */ React85.createElement(Text69, null, "Do you want to proceed?"), /* @__PURE__ */ React85.createElement(
21422
21407
  Select,
21423
21408
  {
21424
21409
  options: [
@@ -21488,8 +21473,8 @@ function SkillPermissionRequest({
21488
21473
  }
21489
21474
 
21490
21475
  // src/tools/agent/PlanModeTool/EnterPlanModeTool.tsx
21491
- import { Box as Box66, Text as Text71 } from "ink";
21492
- import React87 from "react";
21476
+ import { Box as Box65, Text as Text70 } from "ink";
21477
+ import React86 from "react";
21493
21478
  import { z as z10 } from "zod";
21494
21479
 
21495
21480
  // src/tools/agent/PlanModeTool/prompt.ts
@@ -21641,11 +21626,11 @@ var EnterPlanModeTool = {
21641
21626
  },
21642
21627
  renderToolUseRejectedMessage() {
21643
21628
  const theme = getTheme();
21644
- return /* @__PURE__ */ React87.createElement(Box66, { flexDirection: "row", marginTop: 1 }, /* @__PURE__ */ React87.createElement(Text71, { color: theme.text }, BLACK_CIRCLE), /* @__PURE__ */ React87.createElement(Text71, null, " User declined to enter plan mode"));
21629
+ return /* @__PURE__ */ React86.createElement(Box65, { flexDirection: "row", marginTop: 1 }, /* @__PURE__ */ React86.createElement(Text70, { color: theme.text }, BLACK_CIRCLE), /* @__PURE__ */ React86.createElement(Text70, null, " User declined to enter plan mode"));
21645
21630
  },
21646
21631
  renderToolResultMessage(_output) {
21647
21632
  const theme = getTheme();
21648
- return /* @__PURE__ */ React87.createElement(Box66, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React87.createElement(Box66, { flexDirection: "row" }, /* @__PURE__ */ React87.createElement(Text71, { color: theme.planMode }, BLACK_CIRCLE), /* @__PURE__ */ React87.createElement(Text71, null, " Entered plan mode")), /* @__PURE__ */ React87.createElement(Box66, { paddingLeft: 2 }, /* @__PURE__ */ React87.createElement(Text71, { dimColor: true }, "Pyb Agent is now exploring and designing an implementation approach.")));
21633
+ return /* @__PURE__ */ React86.createElement(Box65, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React86.createElement(Box65, { flexDirection: "row" }, /* @__PURE__ */ React86.createElement(Text70, { color: theme.planMode }, BLACK_CIRCLE), /* @__PURE__ */ React86.createElement(Text70, null, " Entered plan mode")), /* @__PURE__ */ React86.createElement(Box65, { paddingLeft: 2 }, /* @__PURE__ */ React86.createElement(Text70, { dimColor: true }, "Pyb Agent is now exploring and designing an implementation approach.")));
21649
21634
  },
21650
21635
  renderResultForAssistant(output) {
21651
21636
  return `${output.message}
@@ -21678,8 +21663,8 @@ Remember: DO NOT write or edit any files yet. This is a read-only exploration an
21678
21663
  };
21679
21664
 
21680
21665
  // src/tools/agent/PlanModeTool/ExitPlanModeTool.tsx
21681
- import { Box as Box67, Text as Text72 } from "ink";
21682
- import React88 from "react";
21666
+ import { Box as Box66, Text as Text71 } from "ink";
21667
+ import React87 from "react";
21683
21668
  import { z as z11 } from "zod";
21684
21669
  function getExitPlanModePlanText(conversationKey) {
21685
21670
  const { content } = readPlanFile(void 0, conversationKey);
@@ -21724,8 +21709,8 @@ var ExitPlanModeTool = {
21724
21709
  const conversationKey = typeof options.conversationKey === "string" && options.conversationKey.trim() ? options.conversationKey.trim() : void 0;
21725
21710
  const { content } = readPlanFile(void 0, conversationKey);
21726
21711
  const plan = getExitPlanModePlanText(conversationKey);
21727
- return /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "column", marginTop: 1, width: "100%" }, /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "row" }, /* @__PURE__ */ React88.createElement(Text72, null, "\xA0\xA0\u23BF \xA0"), /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "column", width: "100%" }, /* @__PURE__ */ React88.createElement(Text72, { color: theme.error }, "User rejected Pyb Agent's plan:"), /* @__PURE__ */ React88.createElement(
21728
- Box67,
21712
+ return /* @__PURE__ */ React87.createElement(Box66, { flexDirection: "column", marginTop: 1, width: "100%" }, /* @__PURE__ */ React87.createElement(Box66, { flexDirection: "row" }, /* @__PURE__ */ React87.createElement(Text71, null, "\xA0\xA0\u23BF \xA0"), /* @__PURE__ */ React87.createElement(Box66, { flexDirection: "column", width: "100%" }, /* @__PURE__ */ React87.createElement(Text71, { color: theme.error }, "User rejected Pyb Agent's plan:"), /* @__PURE__ */ React87.createElement(
21713
+ Box66,
21729
21714
  {
21730
21715
  borderStyle: "round",
21731
21716
  borderColor: theme.planMode,
@@ -21733,14 +21718,14 @@ var ExitPlanModeTool = {
21733
21718
  paddingX: 1,
21734
21719
  overflow: "hidden"
21735
21720
  },
21736
- /* @__PURE__ */ React88.createElement(Text72, { dimColor: true }, plan)
21721
+ /* @__PURE__ */ React87.createElement(Text71, { dimColor: true }, plan)
21737
21722
  ))));
21738
21723
  },
21739
21724
  renderToolResultMessage(output) {
21740
21725
  const theme = getTheme();
21741
21726
  const planPath = typeof output.filePath === "string" ? output.filePath : null;
21742
21727
  const plan = output.plan || "No plan found";
21743
- return /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "column", marginTop: 1, width: "100%" }, /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "row" }, /* @__PURE__ */ React88.createElement(Text72, { color: theme.planMode }, BLACK_CIRCLE), /* @__PURE__ */ React88.createElement(Text72, null, " User approved Pyb Agent's plan")), /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "row" }, /* @__PURE__ */ React88.createElement(Text72, null, "\xA0\xA0\u23BF \xA0"), /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "column" }, planPath ? /* @__PURE__ */ React88.createElement(Text72, { dimColor: true }, "Plan saved to: ", planPath, " \xB7 /plan to edit") : null, /* @__PURE__ */ React88.createElement(Text72, { dimColor: true }, plan))));
21728
+ return /* @__PURE__ */ React87.createElement(Box66, { flexDirection: "column", marginTop: 1, width: "100%" }, /* @__PURE__ */ React87.createElement(Box66, { flexDirection: "row" }, /* @__PURE__ */ React87.createElement(Text71, { color: theme.planMode }, BLACK_CIRCLE), /* @__PURE__ */ React87.createElement(Text71, null, " User approved Pyb Agent's plan")), /* @__PURE__ */ React87.createElement(Box66, { flexDirection: "row" }, /* @__PURE__ */ React87.createElement(Text71, null, "\xA0\xA0\u23BF \xA0"), /* @__PURE__ */ React87.createElement(Box66, { flexDirection: "column" }, planPath ? /* @__PURE__ */ React87.createElement(Text71, { dimColor: true }, "Plan saved to: ", planPath, " \xB7 /plan to edit") : null, /* @__PURE__ */ React87.createElement(Text71, { dimColor: true }, plan))));
21744
21729
  },
21745
21730
  renderResultForAssistant(output) {
21746
21731
  if (output.isAgent) {
@@ -21824,8 +21809,8 @@ ${output.plan}`;
21824
21809
  };
21825
21810
 
21826
21811
  // src/ui/components/permissions/plan-mode-permission-request/EnterPlanModePermissionRequest.tsx
21827
- import { Box as Box68, Text as Text73, useInput as useInput22 } from "ink";
21828
- import React89 from "react";
21812
+ import { Box as Box67, Text as Text72, useInput as useInput22 } from "ink";
21813
+ import React88 from "react";
21829
21814
  function EnterPlanModePermissionRequest({
21830
21815
  toolUseConfirm,
21831
21816
  onDone
@@ -21838,8 +21823,8 @@ function EnterPlanModePermissionRequest({
21838
21823
  onDone();
21839
21824
  }
21840
21825
  });
21841
- return /* @__PURE__ */ React89.createElement(
21842
- Box68,
21826
+ return /* @__PURE__ */ React88.createElement(
21827
+ Box67,
21843
21828
  {
21844
21829
  flexDirection: "column",
21845
21830
  borderStyle: "round",
@@ -21849,11 +21834,11 @@ function EnterPlanModePermissionRequest({
21849
21834
  paddingRight: 1,
21850
21835
  paddingBottom: 1
21851
21836
  },
21852
- /* @__PURE__ */ React89.createElement(PermissionRequestTitle, { title: "Enter plan mode?", riskScore: null }),
21853
- /* @__PURE__ */ React89.createElement(Box68, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React89.createElement(Text73, null, "The assistant wants to enter plan mode to explore and design an implementation approach.")),
21854
- /* @__PURE__ */ React89.createElement(Box68, { flexDirection: "column", paddingX: 2 }, /* @__PURE__ */ React89.createElement(Text73, { dimColor: true }, "In plan mode, the assistant will:"), /* @__PURE__ */ React89.createElement(Text73, { dimColor: true }, " \xB7 Explore the codebase thoroughly"), /* @__PURE__ */ React89.createElement(Text73, { dimColor: true }, " \xB7 Identify existing patterns"), /* @__PURE__ */ React89.createElement(Text73, { dimColor: true }, " \xB7 Design an implementation strategy"), /* @__PURE__ */ React89.createElement(Text73, { dimColor: true }, " \xB7 Present a plan for your approval")),
21855
- /* @__PURE__ */ React89.createElement(Box68, { flexDirection: "column", paddingX: 2, marginTop: 1 }, /* @__PURE__ */ React89.createElement(Text73, { dimColor: true }, "No code changes will be made until you approve the plan.")),
21856
- /* @__PURE__ */ React89.createElement(Box68, { flexDirection: "column" }, /* @__PURE__ */ React89.createElement(Text73, null, "Would you like to proceed?"), /* @__PURE__ */ React89.createElement(
21837
+ /* @__PURE__ */ React88.createElement(PermissionRequestTitle, { title: "Enter plan mode?", riskScore: null }),
21838
+ /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React88.createElement(Text72, null, "The assistant wants to enter plan mode to explore and design an implementation approach.")),
21839
+ /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "column", paddingX: 2 }, /* @__PURE__ */ React88.createElement(Text72, { dimColor: true }, "In plan mode, the assistant will:"), /* @__PURE__ */ React88.createElement(Text72, { dimColor: true }, " \xB7 Explore the codebase thoroughly"), /* @__PURE__ */ React88.createElement(Text72, { dimColor: true }, " \xB7 Identify existing patterns"), /* @__PURE__ */ React88.createElement(Text72, { dimColor: true }, " \xB7 Design an implementation strategy"), /* @__PURE__ */ React88.createElement(Text72, { dimColor: true }, " \xB7 Present a plan for your approval")),
21840
+ /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "column", paddingX: 2, marginTop: 1 }, /* @__PURE__ */ React88.createElement(Text72, { dimColor: true }, "No code changes will be made until you approve the plan.")),
21841
+ /* @__PURE__ */ React88.createElement(Box67, { flexDirection: "column" }, /* @__PURE__ */ React88.createElement(Text72, null, "Would you like to proceed?"), /* @__PURE__ */ React88.createElement(
21857
21842
  Select,
21858
21843
  {
21859
21844
  options: [
@@ -21876,8 +21861,8 @@ function EnterPlanModePermissionRequest({
21876
21861
  }
21877
21862
 
21878
21863
  // src/ui/components/permissions/plan-mode-permission-request/ExitPlanModePermissionRequest.tsx
21879
- import { Box as Box69, Text as Text74, useInput as useInput23 } from "ink";
21880
- import React90, { useEffect as useEffect20, useMemo as useMemo23, useState as useState21 } from "react";
21864
+ import { Box as Box68, Text as Text73, useInput as useInput23 } from "ink";
21865
+ import React89, { useEffect as useEffect20, useMemo as useMemo23, useState as useState21 } from "react";
21881
21866
 
21882
21867
  // src/utils/system/externalEditor.ts
21883
21868
  import { spawn, spawnSync } from "child_process";
@@ -22184,8 +22169,8 @@ function ExitPlanModePermissionRequest({
22184
22169
  [bypassAvailable, launchSwarmAvailable, teammateCount]
22185
22170
  );
22186
22171
  if (showRejectInput) {
22187
- return /* @__PURE__ */ React90.createElement(
22188
- Box69,
22172
+ return /* @__PURE__ */ React89.createElement(
22173
+ Box68,
22189
22174
  {
22190
22175
  flexDirection: "column",
22191
22176
  borderStyle: "round",
@@ -22195,8 +22180,8 @@ function ExitPlanModePermissionRequest({
22195
22180
  paddingRight: 1,
22196
22181
  paddingBottom: 1
22197
22182
  },
22198
- /* @__PURE__ */ React90.createElement(PermissionRequestTitle, { title: "No, keep planning", riskScore: null }),
22199
- /* @__PURE__ */ React90.createElement(Box69, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React90.createElement(Text74, { dimColor: true }, "Type here to tell Pyb Agent what to change (Enter submits, Esc cancels)"), rejectError ? /* @__PURE__ */ React90.createElement(Text74, { color: theme.error }, rejectError) : null, /* @__PURE__ */ React90.createElement(
22183
+ /* @__PURE__ */ React89.createElement(PermissionRequestTitle, { title: "No, keep planning", riskScore: null }),
22184
+ /* @__PURE__ */ React89.createElement(Box68, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React89.createElement(Text73, { dimColor: true }, "Type here to tell Pyb Agent what to change (Enter submits, Esc cancels)"), rejectError ? /* @__PURE__ */ React89.createElement(Text73, { color: theme.error }, rejectError) : null, /* @__PURE__ */ React89.createElement(
22200
22185
  TextInput,
22201
22186
  {
22202
22187
  value: rejectFeedback,
@@ -22225,8 +22210,8 @@ function ExitPlanModePermissionRequest({
22225
22210
  ))
22226
22211
  );
22227
22212
  }
22228
- return /* @__PURE__ */ React90.createElement(
22229
- Box69,
22213
+ return /* @__PURE__ */ React89.createElement(
22214
+ Box68,
22230
22215
  {
22231
22216
  flexDirection: "column",
22232
22217
  borderStyle: "round",
@@ -22236,9 +22221,9 @@ function ExitPlanModePermissionRequest({
22236
22221
  paddingRight: 1,
22237
22222
  paddingBottom: 1
22238
22223
  },
22239
- /* @__PURE__ */ React90.createElement(PermissionRequestTitle, { title: "Ready to code?", riskScore: null }),
22240
- /* @__PURE__ */ React90.createElement(Box69, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React90.createElement(Text74, null, "Here is Pyb Agent's plan:"), /* @__PURE__ */ React90.createElement(
22241
- Box69,
22224
+ /* @__PURE__ */ React89.createElement(PermissionRequestTitle, { title: "Ready to code?", riskScore: null }),
22225
+ /* @__PURE__ */ React89.createElement(Box68, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React89.createElement(Text73, null, "Here is Pyb Agent's plan:"), /* @__PURE__ */ React89.createElement(
22226
+ Box68,
22242
22227
  {
22243
22228
  borderStyle: "dashed",
22244
22229
  borderColor: theme.secondaryBorder,
@@ -22250,10 +22235,10 @@ function ExitPlanModePermissionRequest({
22250
22235
  marginBottom: 1,
22251
22236
  flexDirection: "column"
22252
22237
  },
22253
- /* @__PURE__ */ React90.createElement(Text74, null, planText)
22238
+ /* @__PURE__ */ React89.createElement(Text73, null, planText)
22254
22239
  )),
22255
- /* @__PURE__ */ React90.createElement(Box69, { flexDirection: "column", paddingX: 2 }, /* @__PURE__ */ React90.createElement(Text74, { dimColor: true }, "Tip: Press ctrl+g to edit", " ", planSource === "file" ? `plan file: ${planFilePath}` : "plan text", planSaved ? " \xB7 Plan saved!" : "")),
22256
- /* @__PURE__ */ React90.createElement(Box69, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React90.createElement(Text74, { dimColor: true }, "Would you like to proceed?"), /* @__PURE__ */ React90.createElement(
22240
+ /* @__PURE__ */ React89.createElement(Box68, { flexDirection: "column", paddingX: 2 }, /* @__PURE__ */ React89.createElement(Text73, { dimColor: true }, "Tip: Press ctrl+g to edit", " ", planSource === "file" ? `plan file: ${planFilePath}` : "plan text", planSaved ? " \xB7 Plan saved!" : "")),
22241
+ /* @__PURE__ */ React89.createElement(Box68, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React89.createElement(Text73, { dimColor: true }, "Would you like to proceed?"), /* @__PURE__ */ React89.createElement(
22257
22242
  Select,
22258
22243
  {
22259
22244
  options,
@@ -22279,8 +22264,8 @@ function ExitPlanModePermissionRequest({
22279
22264
  }
22280
22265
 
22281
22266
  // src/tools/interaction/AskUserQuestionTool/AskUserQuestionTool.tsx
22282
- import { Box as Box70, Text as Text75 } from "ink";
22283
- import React91 from "react";
22267
+ import { Box as Box69, Text as Text74 } from "ink";
22268
+ import React90 from "react";
22284
22269
  import { z as z12 } from "zod";
22285
22270
 
22286
22271
  // src/tools/interaction/AskUserQuestionTool/prompt.ts
@@ -22357,11 +22342,11 @@ var AskUserQuestionTool = {
22357
22342
  },
22358
22343
  renderToolUseRejectedMessage() {
22359
22344
  const theme = getTheme();
22360
- return /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "row", marginTop: 1 }, /* @__PURE__ */ React91.createElement(Text75, { color: theme.text }, BLACK_CIRCLE, "\xA0"), /* @__PURE__ */ React91.createElement(Text75, null, "User declined to answer questions"));
22345
+ return /* @__PURE__ */ React90.createElement(Box69, { flexDirection: "row", marginTop: 1 }, /* @__PURE__ */ React90.createElement(Text74, { color: theme.text }, BLACK_CIRCLE, "\xA0"), /* @__PURE__ */ React90.createElement(Text74, null, "User declined to answer questions"));
22361
22346
  },
22362
22347
  renderToolResultMessage(output, _options) {
22363
22348
  const theme = getTheme();
22364
- return /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "row" }, /* @__PURE__ */ React91.createElement(Text75, { color: theme.text }, BLACK_CIRCLE, "\xA0"), /* @__PURE__ */ React91.createElement(Text75, null, "User answered Pyb Agent's questions:")), /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "column", paddingLeft: 2 }, Object.entries(output.answers).map(([question, answer]) => /* @__PURE__ */ React91.createElement(Box70, { key: question }, /* @__PURE__ */ React91.createElement(Text75, { dimColor: true }, "\xB7 ", question, " \u2192 ", answer)))));
22349
+ return /* @__PURE__ */ React90.createElement(Box69, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React90.createElement(Box69, { flexDirection: "row" }, /* @__PURE__ */ React90.createElement(Text74, { color: theme.text }, BLACK_CIRCLE, "\xA0"), /* @__PURE__ */ React90.createElement(Text74, null, "User answered Pyb Agent's questions:")), /* @__PURE__ */ React90.createElement(Box69, { flexDirection: "column", paddingLeft: 2 }, Object.entries(output.answers).map(([question, answer]) => /* @__PURE__ */ React90.createElement(Box69, { key: question }, /* @__PURE__ */ React90.createElement(Text74, { dimColor: true }, "\xB7 ", question, " \u2192 ", answer)))));
22365
22350
  },
22366
22351
  renderResultForAssistant(output) {
22367
22352
  const formatted = Object.entries(output.answers).map(([question, answer]) => `"${question}"="${answer}"`).join(", ");
@@ -22378,8 +22363,8 @@ var AskUserQuestionTool = {
22378
22363
  };
22379
22364
 
22380
22365
  // src/ui/components/permissions/ask-user-question-permission-request/AskUserQuestionPermissionRequest.tsx
22381
- import React92, { useCallback as useCallback11, useMemo as useMemo24, useState as useState22 } from "react";
22382
- import { Box as Box71, Text as Text76, useInput as useInput24 } from "ink";
22366
+ import React91, { useCallback as useCallback11, useMemo as useMemo24, useState as useState22 } from "react";
22367
+ import { Box as Box70, Text as Text75, useInput as useInput24 } from "ink";
22383
22368
  import figures8 from "figures";
22384
22369
  import stringWidth from "string-width";
22385
22370
  function isTextInputChar(input, key) {
@@ -22733,18 +22718,18 @@ function AskUserQuestionPermissionRequest({
22733
22718
  const rightArrowInactive = currentQuestionIndex === maxTabIndex;
22734
22719
  const allQuestionsAnswered = questions.every((q) => q?.question && Boolean(answers[q.question])) ?? false;
22735
22720
  if (questions.length === 0) {
22736
- return /* @__PURE__ */ React92.createElement(Box71, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React92.createElement(Text76, { color: theme.error }, "Invalid AskUserQuestion input."), /* @__PURE__ */ React92.createElement(Text76, { dimColor: true }, "Press Esc to cancel."));
22721
+ return /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React91.createElement(Text75, { color: theme.error }, "Invalid AskUserQuestion input."), /* @__PURE__ */ React91.createElement(Text75, { dimColor: true }, "Press Esc to cancel."));
22737
22722
  }
22738
- return /* @__PURE__ */ React92.createElement(Box71, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React92.createElement(
22739
- Box71,
22723
+ return /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React91.createElement(
22724
+ Box70,
22740
22725
  {
22741
22726
  borderTop: true,
22742
22727
  borderColor: theme.secondaryText,
22743
22728
  flexDirection: "column",
22744
22729
  paddingTop: 0
22745
22730
  },
22746
- /* @__PURE__ */ React92.createElement(Box71, { flexDirection: "row", marginBottom: 1 }, showArrows && /* @__PURE__ */ React92.createElement(
22747
- Text76,
22731
+ /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "row", marginBottom: 1 }, showArrows && /* @__PURE__ */ React91.createElement(
22732
+ Text75,
22748
22733
  {
22749
22734
  color: currentQuestionIndex === 0 ? theme.secondaryText : void 0
22750
22735
  },
@@ -22755,16 +22740,16 @@ function AskUserQuestionPermissionRequest({
22755
22740
  const checkbox = question.question && answers[question.question] ? figures8.checkboxOn : figures8.checkboxOff;
22756
22741
  const headerText = tabHeaders[index] ?? question.header ?? `Q${index + 1}`;
22757
22742
  const tabText = ` ${checkbox} ${headerText} `;
22758
- return /* @__PURE__ */ React92.createElement(React92.Fragment, { key: question.question || `question-${index}` }, /* @__PURE__ */ React92.createElement(
22759
- Text76,
22743
+ return /* @__PURE__ */ React91.createElement(React91.Fragment, { key: question.question || `question-${index}` }, /* @__PURE__ */ React91.createElement(
22744
+ Text75,
22760
22745
  {
22761
22746
  backgroundColor: isSelected ? theme.permission : void 0,
22762
22747
  color: isSelected ? inverseText : void 0
22763
22748
  },
22764
22749
  tabText
22765
22750
  ));
22766
- }), !hideSubmitTab && /* @__PURE__ */ React92.createElement(
22767
- Text76,
22751
+ }), !hideSubmitTab && /* @__PURE__ */ React91.createElement(
22752
+ Text75,
22768
22753
  {
22769
22754
  backgroundColor: isSubmitTab ? theme.permission : void 0,
22770
22755
  color: isSubmitTab ? inverseText : void 0
@@ -22773,23 +22758,23 @@ function AskUserQuestionPermissionRequest({
22773
22758
  figures8.tick,
22774
22759
  " Submit",
22775
22760
  " "
22776
- ), showArrows && /* @__PURE__ */ React92.createElement(Text76, { color: rightArrowInactive ? theme.secondaryText : void 0 }, " ", "\u2192")),
22777
- !isSubmitTab && currentQuestion && /* @__PURE__ */ React92.createElement(React92.Fragment, null, /* @__PURE__ */ React92.createElement(Text76, { bold: true }, currentQuestion.question), /* @__PURE__ */ React92.createElement(Box71, { flexDirection: "column", marginTop: 1 }, (() => {
22761
+ ), showArrows && /* @__PURE__ */ React91.createElement(Text75, { color: rightArrowInactive ? theme.secondaryText : void 0 }, " ", "\u2192")),
22762
+ !isSubmitTab && currentQuestion && /* @__PURE__ */ React91.createElement(React91.Fragment, null, /* @__PURE__ */ React91.createElement(Text75, { bold: true }, currentQuestion.question), /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "column", marginTop: 1 }, (() => {
22778
22763
  const rawSelected = activeQuestionState?.selectedValue;
22779
22764
  const selectedValues = Array.isArray(rawSelected) ? rawSelected : [];
22780
22765
  const otherSelected = currentQuestion.multiSelect ? selectedValues.includes("__other__") : rawSelected === "__other__";
22781
22766
  const otherText = questionStates[currentQuestion.question]?.textInputValue ?? "";
22782
22767
  const otherPlaceholder = currentQuestion.multiSelect ? "Type something" : "Type something.";
22783
22768
  const otherLine = otherText.length > 0 ? otherText : isOtherFocused || otherSelected ? otherPlaceholder : "";
22784
- return /* @__PURE__ */ React92.createElement(React92.Fragment, null, currentQuestion.options.map((option, index) => {
22769
+ return /* @__PURE__ */ React91.createElement(React91.Fragment, null, currentQuestion.options.map((option, index) => {
22785
22770
  const isFocused = !isMultiSelectSubmitFocused && index === focusedOptionIndex;
22786
22771
  const isSelected = currentQuestion.multiSelect ? selectedValues.includes(option.label) : rawSelected === option.label;
22787
22772
  const pointer = isFocused ? figures8.pointer : " ";
22788
22773
  const color = isFocused ? theme.pyb : theme.text;
22789
22774
  const indicator = currentQuestion.multiSelect ? isSelected ? figures8.checkboxOn : figures8.checkboxOff : isSelected ? figures8.tick : " ";
22790
- return /* @__PURE__ */ React92.createElement(Box71, { key: option.label, flexDirection: "column" }, /* @__PURE__ */ React92.createElement(Text76, { color }, pointer, " ", indicator, " ", option.label), /* @__PURE__ */ React92.createElement(Text76, { color: theme.secondaryText }, " ", option.description));
22791
- }), /* @__PURE__ */ React92.createElement(Box71, { flexDirection: "column" }, /* @__PURE__ */ React92.createElement(Text76, { color: isOtherFocused ? theme.pyb : theme.text }, isOtherFocused ? figures8.pointer : " ", " ", currentQuestion.multiSelect ? otherSelected ? figures8.checkboxOn : figures8.checkboxOff : otherSelected ? figures8.tick : " ", " ", "Other"), (isOtherFocused || otherSelected || otherText.trim().length > 0) && /* @__PURE__ */ React92.createElement(Text76, { color: theme.secondaryText }, otherLine, isOtherFocused && /* @__PURE__ */ React92.createElement(Text76, { color: "gray" }, "\u258C"))), currentQuestion.multiSelect && /* @__PURE__ */ React92.createElement(Box71, { marginTop: 0 }, /* @__PURE__ */ React92.createElement(
22792
- Text76,
22775
+ return /* @__PURE__ */ React91.createElement(Box70, { key: option.label, flexDirection: "column" }, /* @__PURE__ */ React91.createElement(Text75, { color }, pointer, " ", indicator, " ", option.label), /* @__PURE__ */ React91.createElement(Text75, { color: theme.secondaryText }, " ", option.description));
22776
+ }), /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "column" }, /* @__PURE__ */ React91.createElement(Text75, { color: isOtherFocused ? theme.pyb : theme.text }, isOtherFocused ? figures8.pointer : " ", " ", currentQuestion.multiSelect ? otherSelected ? figures8.checkboxOn : figures8.checkboxOff : otherSelected ? figures8.tick : " ", " ", "Other"), (isOtherFocused || otherSelected || otherText.trim().length > 0) && /* @__PURE__ */ React91.createElement(Text75, { color: theme.secondaryText }, otherLine, isOtherFocused && /* @__PURE__ */ React91.createElement(Text75, { color: "gray" }, "\u258C"))), currentQuestion.multiSelect && /* @__PURE__ */ React91.createElement(Box70, { marginTop: 0 }, /* @__PURE__ */ React91.createElement(
22777
+ Text75,
22793
22778
  {
22794
22779
  color: isMultiSelectSubmitFocused ? theme.pyb : theme.text,
22795
22780
  bold: isMultiSelectSubmitFocused
@@ -22797,9 +22782,9 @@ function AskUserQuestionPermissionRequest({
22797
22782
  isMultiSelectSubmitFocused ? figures8.pointer : " ",
22798
22783
  " ",
22799
22784
  currentQuestionIndex === questions.length - 1 ? "Submit" : "Next"
22800
- )), /* @__PURE__ */ React92.createElement(Box71, { marginTop: 1 }, /* @__PURE__ */ React92.createElement(Text76, { color: theme.secondaryText, dimColor: true }, "Enter to select \xB7 Tab/Arrow keys to navigate \xB7 Esc to cancel")));
22785
+ )), /* @__PURE__ */ React91.createElement(Box70, { marginTop: 1 }, /* @__PURE__ */ React91.createElement(Text75, { color: theme.secondaryText, dimColor: true }, "Enter to select \xB7 Tab/Arrow keys to navigate \xB7 Esc to cancel")));
22801
22786
  })())),
22802
- isSubmitTab && /* @__PURE__ */ React92.createElement(Box71, { flexDirection: "column" }, /* @__PURE__ */ React92.createElement(Text76, { bold: true }, "Review your answers"), !allQuestionsAnswered && /* @__PURE__ */ React92.createElement(Box71, { marginTop: 1 }, /* @__PURE__ */ React92.createElement(Text76, { color: theme.warning }, figures8.warning, " You have not answered all questions")), /* @__PURE__ */ React92.createElement(Box71, { flexDirection: "column", marginTop: 1 }, questions.filter((q) => q?.question && answers[q.question]).map((q) => /* @__PURE__ */ React92.createElement(Box71, { key: q.question, flexDirection: "column", marginLeft: 1 }, /* @__PURE__ */ React92.createElement(Text76, null, figures8.bullet, " ", q.question), /* @__PURE__ */ React92.createElement(Box71, { marginLeft: 2 }, /* @__PURE__ */ React92.createElement(Text76, { color: theme.success }, figures8.arrowRight, " ", answers[q.question]))))), /* @__PURE__ */ React92.createElement(Box71, { marginTop: 1 }, /* @__PURE__ */ React92.createElement(Text76, { color: theme.secondaryText }, "Ready to submit your answers?")), /* @__PURE__ */ React92.createElement(Box71, { marginTop: 1 }, /* @__PURE__ */ React92.createElement(
22787
+ isSubmitTab && /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "column" }, /* @__PURE__ */ React91.createElement(Text75, { bold: true }, "Review your answers"), !allQuestionsAnswered && /* @__PURE__ */ React91.createElement(Box70, { marginTop: 1 }, /* @__PURE__ */ React91.createElement(Text75, { color: theme.warning }, figures8.warning, " You have not answered all questions")), /* @__PURE__ */ React91.createElement(Box70, { flexDirection: "column", marginTop: 1 }, questions.filter((q) => q?.question && answers[q.question]).map((q) => /* @__PURE__ */ React91.createElement(Box70, { key: q.question, flexDirection: "column", marginLeft: 1 }, /* @__PURE__ */ React91.createElement(Text75, null, figures8.bullet, " ", q.question), /* @__PURE__ */ React91.createElement(Box70, { marginLeft: 2 }, /* @__PURE__ */ React91.createElement(Text75, { color: theme.success }, figures8.arrowRight, " ", answers[q.question]))))), /* @__PURE__ */ React91.createElement(Box70, { marginTop: 1 }, /* @__PURE__ */ React91.createElement(Text75, { color: theme.secondaryText }, "Ready to submit your answers?")), /* @__PURE__ */ React91.createElement(Box70, { marginTop: 1 }, /* @__PURE__ */ React91.createElement(
22803
22788
  Select,
22804
22789
  {
22805
22790
  options: [
@@ -22869,7 +22854,7 @@ function PermissionRequest({
22869
22854
  `${PRODUCT_NAME} needs your permission to use ${toolName}`
22870
22855
  );
22871
22856
  const PermissionComponent = permissionComponentForTool(toolUseConfirm.tool);
22872
- return /* @__PURE__ */ React93.createElement(
22857
+ return /* @__PURE__ */ React92.createElement(
22873
22858
  PermissionComponent,
22874
22859
  {
22875
22860
  toolUseConfirm,
@@ -22880,8 +22865,8 @@ function PermissionRequest({
22880
22865
  }
22881
22866
 
22882
22867
  // src/ui/components/PromptInput.tsx
22883
- import { Box as Box74, Text as Text79, useInput as useInput27 } from "ink";
22884
- import * as React97 from "react";
22868
+ import { Box as Box73, Text as Text78, useInput as useInput27 } from "ink";
22869
+ import * as React96 from "react";
22885
22870
 
22886
22871
  // src/ui/hooks/useArrowKeyHistory.ts
22887
22872
  import { useState as useState23 } from "react";
@@ -24915,8 +24900,8 @@ function countTokens(messages) {
24915
24900
  }
24916
24901
 
24917
24902
  // src/ui/components/SentryErrorBoundary.ts
24918
- import * as React94 from "react";
24919
- var SentryErrorBoundary = class extends React94.Component {
24903
+ import * as React93 from "react";
24904
+ var SentryErrorBoundary = class extends React93.Component {
24920
24905
  constructor(props) {
24921
24906
  super(props);
24922
24907
  this.state = { hasError: false };
@@ -24939,8 +24924,8 @@ var SentryErrorBoundary = class extends React94.Component {
24939
24924
  };
24940
24925
 
24941
24926
  // src/ui/components/TokenWarning.tsx
24942
- import { Box as Box72, Text as Text77 } from "ink";
24943
- import * as React95 from "react";
24927
+ import { Box as Box71, Text as Text76 } from "ink";
24928
+ import * as React94 from "react";
24944
24929
  var MAX_TOKENS = 19e4;
24945
24930
  var WARNING_THRESHOLD = MAX_TOKENS * 0.6;
24946
24931
  var ERROR_THRESHOLD = MAX_TOKENS * 0.8;
@@ -24950,7 +24935,7 @@ function TokenWarning({ tokenUsage }) {
24950
24935
  return null;
24951
24936
  }
24952
24937
  const isError = tokenUsage >= ERROR_THRESHOLD;
24953
- return /* @__PURE__ */ React95.createElement(Box72, { flexDirection: "row" }, /* @__PURE__ */ React95.createElement(Text77, { color: isError ? theme.error : theme.warning }, "Context low (", Math.max(0, 100 - Math.round(tokenUsage / MAX_TOKENS * 100)), "% remaining) \xB7 Run /compact to compact & continue"));
24938
+ return /* @__PURE__ */ React94.createElement(Box71, { flexDirection: "row" }, /* @__PURE__ */ React94.createElement(Text76, { color: isError ? theme.error : theme.warning }, "Context low (", Math.max(0, 100 - Math.round(tokenUsage / MAX_TOKENS * 100)), "% remaining) \xB7 Run /compact to compact & continue"));
24954
24939
  }
24955
24940
 
24956
24941
  // src/utils/commands/hashCommand.ts
@@ -24996,8 +24981,8 @@ _Added on ${now.toLocaleString()} ${timezone}_`;
24996
24981
  }
24997
24982
 
24998
24983
  // src/ui/components/ModeIndicator.tsx
24999
- import React96 from "react";
25000
- import { Box as Box73, Text as Text78 } from "ink";
24984
+ import React95 from "react";
24985
+ import { Box as Box72, Text as Text77 } from "ink";
25001
24986
  function __getModeIndicatorDisplayForTests(args) {
25002
24987
  if (args.mode === "default") {
25003
24988
  return {
@@ -25068,7 +25053,7 @@ function CompactModeIndicator() {
25068
25053
  shortcutDisplayText: shortcut.displayText,
25069
25054
  theme
25070
25055
  });
25071
- return /* @__PURE__ */ React96.createElement(Text78, { color: indicator.color }, indicator.mainText, /* @__PURE__ */ React96.createElement(Text78, { dimColor: true }, indicator.shortcutHintText));
25056
+ return /* @__PURE__ */ React95.createElement(Text77, { color: indicator.color }, indicator.mainText, /* @__PURE__ */ React95.createElement(Text77, { dimColor: true }, indicator.shortcutHintText));
25072
25057
  }
25073
25058
 
25074
25059
  // src/utils/terminal/promptInputSpecialKey.ts
@@ -25195,7 +25180,7 @@ function useStatusLine() {
25195
25180
  // src/ui/components/PromptInput.tsx
25196
25181
  async function interpretHashCommand(input) {
25197
25182
  try {
25198
- const { queryQuick: queryQuick2 } = await import("./llm-5RBAGTX5.js");
25183
+ const { queryQuick: queryQuick2 } = await import("./llm-VY6RXJY7.js");
25199
25184
  const systemPrompt = [
25200
25185
  "You're helping the user structure notes that will be added to their PYB.md file.",
25201
25186
  "Format the user's input into a well-structured note that will be useful for later reference.",
@@ -25246,10 +25231,7 @@ function PromptInput({
25246
25231
  onShowMessageSelector,
25247
25232
  setForkConvoWithMessagesOnTheNextRender,
25248
25233
  readFileTimestamps,
25249
- onModelChange,
25250
- onQueueMessage,
25251
- onQueueEditRequest,
25252
- hasQueuedMessages
25234
+ onModelChange
25253
25235
  }) {
25254
25236
  useEffect23(() => {
25255
25237
  if (!isDisabled && !isLoading) {
@@ -25270,9 +25252,8 @@ function PromptInput({
25270
25252
  const [pastedImages, setPastedImages] = useState26([]);
25271
25253
  const [isEditingExternally, setIsEditingExternally] = useState26(false);
25272
25254
  const [currentPwd, setCurrentPwd] = useState26(process.cwd());
25273
- const [editingQueuedId, setEditingQueuedId] = useState26(null);
25274
- const pastedTextCounter = React97.useRef(1);
25275
- const pastedImageCounter = React97.useRef(1);
25255
+ const pastedTextCounter = React96.useRef(1);
25256
+ const pastedImageCounter = React96.useRef(1);
25276
25257
  const { cycleMode, currentMode, toolPermissionContext } = usePermissionContext();
25277
25258
  const modeCycleShortcut = useMemo25(() => getPermissionModeCycleShortcut(), []);
25278
25259
  const showQuickModelSwitchShortcut = modeCycleShortcut.displayText !== "alt+m";
@@ -25307,13 +25288,13 @@ function PromptInput({
25307
25288
  const isSelected = index === selectedIndex;
25308
25289
  const isAgent = suggestion.type === "agent";
25309
25290
  const displayColor = isSelected ? theme.suggestion : isAgent && suggestion.metadata?.color ? suggestion.metadata.color : void 0;
25310
- return /* @__PURE__ */ React97.createElement(
25311
- Box74,
25291
+ return /* @__PURE__ */ React96.createElement(
25292
+ Box73,
25312
25293
  {
25313
25294
  key: `${suggestion.type}-${suggestion.value}-${index}`,
25314
25295
  flexDirection: "row"
25315
25296
  },
25316
- /* @__PURE__ */ React97.createElement(Text79, { color: displayColor, dimColor: !isSelected && !displayColor }, isSelected ? "\u25C6 " : " ", suggestion.displayValue)
25297
+ /* @__PURE__ */ React96.createElement(Text78, { color: displayColor, dimColor: !isSelected && !displayColor }, isSelected ? "\u25C6 " : " ", suggestion.displayValue)
25317
25298
  );
25318
25299
  });
25319
25300
  }, [suggestions, selectedIndex, theme.suggestion]);
@@ -25380,16 +25361,6 @@ function PromptInput({
25380
25361
  );
25381
25362
  const handleHistoryUp = () => {
25382
25363
  if (!completionActive) {
25383
- if (isLoading && hasQueuedMessages && onQueueEditRequest) {
25384
- const queued = onQueueEditRequest(editingQueuedId ?? void 0);
25385
- if (queued) {
25386
- onInputChange(queued.content);
25387
- onModeChange(queued.mode);
25388
- setCursorOffset(queued.content.length);
25389
- setEditingQueuedId(queued.id);
25390
- return;
25391
- }
25392
- }
25393
25364
  onHistoryUp();
25394
25365
  }
25395
25366
  };
@@ -25402,47 +25373,6 @@ function PromptInput({
25402
25373
  if (!isSubmittingSlashCommand && completionActive && suggestions.length > 0) {
25403
25374
  return;
25404
25375
  }
25405
- if (input2 === "" && !(isLoading && editingQueuedId)) {
25406
- return;
25407
- }
25408
- if (isDisabled) {
25409
- return;
25410
- }
25411
- if (isLoading) {
25412
- if (onQueueMessage) {
25413
- if (editingQueuedId) {
25414
- if (input2 === "") {
25415
- onQueueMessage({
25416
- content: "",
25417
- mode,
25418
- replaceId: editingQueuedId,
25419
- delete: true
25420
- });
25421
- setEditingQueuedId(null);
25422
- onInputChange("");
25423
- setCursorOffset(0);
25424
- return;
25425
- }
25426
- const inputToAdd2 = mode === "bash" ? `!${input2}` : input2;
25427
- addToHistory(inputToAdd2);
25428
- resetHistory();
25429
- onInputChange("");
25430
- onQueueMessage({
25431
- content: input2,
25432
- mode,
25433
- replaceId: editingQueuedId
25434
- });
25435
- setEditingQueuedId(null);
25436
- return;
25437
- }
25438
- const inputToAdd = mode === "bash" ? `!${input2}` : input2;
25439
- addToHistory(inputToAdd);
25440
- resetHistory();
25441
- onInputChange("");
25442
- onQueueMessage({ content: input2, mode });
25443
- }
25444
- return;
25445
- }
25446
25376
  if ((mode === "pyb" || input2.startsWith("#")) && input2.match(/^(#\s*)?(put|create|generate|write|give|provide)/i)) {
25447
25377
  try {
25448
25378
  const originalInput = input2;
@@ -25509,6 +25439,15 @@ function PromptInput({
25509
25439
  onModeChange("prompt");
25510
25440
  return;
25511
25441
  }
25442
+ if (input2 === "") {
25443
+ return;
25444
+ }
25445
+ if (isDisabled) {
25446
+ return;
25447
+ }
25448
+ if (isLoading) {
25449
+ return;
25450
+ }
25512
25451
  if (["exit", "quit", ":q", ":q!", ":wq", ":wq!"].includes(input2.trim())) {
25513
25452
  exit();
25514
25453
  }
@@ -25554,7 +25493,7 @@ function PromptInput({
25554
25493
  if (messages2.length) {
25555
25494
  if (mode === "bash") {
25556
25495
  onQuery(messages2, newAbortController).then(async () => {
25557
- const { getCwd: getCwd2 } = await import("./state-QBXHDWLK.js");
25496
+ const { getCwd: getCwd2 } = await import("./state-GH6RNHJT.js");
25558
25497
  setCurrentPwd(getCwd2());
25559
25498
  });
25560
25499
  } else {
@@ -25606,12 +25545,6 @@ function PromptInput({
25606
25545
  }, [input]);
25607
25546
  useInput27(
25608
25547
  (inputChar, key) => {
25609
- if (key.escape && isLoading && editingQueuedId) {
25610
- setEditingQueuedId(null);
25611
- onInputChange("");
25612
- setCursorOffset(0);
25613
- return true;
25614
- }
25615
25548
  if (mode === "bash" && (key.backspace || key.delete)) {
25616
25549
  if (input === "") {
25617
25550
  onModeChange("prompt");
@@ -25716,17 +25649,17 @@ function PromptInput({
25716
25649
  currentTokens: tokenUsage
25717
25650
  };
25718
25651
  }, [tokenUsage, modelSwitchMessage.show, submitCount, currentModelId]);
25719
- return /* @__PURE__ */ React97.createElement(Box74, { flexDirection: "column" }, (mode === "bash" || modelInfo) && /* @__PURE__ */ React97.createElement(
25720
- Box74,
25652
+ return /* @__PURE__ */ React96.createElement(Box73, { flexDirection: "column" }, (mode === "bash" || modelInfo) && /* @__PURE__ */ React96.createElement(
25653
+ Box73,
25721
25654
  {
25722
25655
  justifyContent: "space-between",
25723
25656
  marginBottom: 1,
25724
25657
  flexDirection: "row"
25725
25658
  },
25726
- mode === "bash" ? /* @__PURE__ */ React97.createElement(Text79, { color: theme.bashBorder }, "Shell PWD: ", currentPwd) : /* @__PURE__ */ React97.createElement(Text79, null, " "),
25727
- modelInfo && /* @__PURE__ */ React97.createElement(Text79, { dimColor: true }, "[", modelInfo.provider, "] ", modelInfo.name, ":", " ", Math.round(modelInfo.currentTokens / 1e3), "k /", " ", Math.round(modelInfo.contextLength / 1e3), "k")
25728
- ), /* @__PURE__ */ React97.createElement(
25729
- Box74,
25659
+ mode === "bash" ? /* @__PURE__ */ React96.createElement(Text78, { color: theme.bashBorder }, "Shell PWD: ", currentPwd) : /* @__PURE__ */ React96.createElement(Text78, null, " "),
25660
+ modelInfo && /* @__PURE__ */ React96.createElement(Text78, { dimColor: true }, "[", modelInfo.provider, "] ", modelInfo.name, ":", " ", Math.round(modelInfo.currentTokens / 1e3), "k /", " ", Math.round(modelInfo.contextLength / 1e3), "k")
25661
+ ), /* @__PURE__ */ React96.createElement(
25662
+ Box73,
25730
25663
  {
25731
25664
  alignItems: "flex-start",
25732
25665
  justifyContent: "flex-start",
@@ -25740,8 +25673,8 @@ function PromptInput({
25740
25673
  marginTop: 1,
25741
25674
  width: "100%"
25742
25675
  },
25743
- /* @__PURE__ */ React97.createElement(
25744
- Box74,
25676
+ /* @__PURE__ */ React96.createElement(
25677
+ Box73,
25745
25678
  {
25746
25679
  alignItems: "flex-start",
25747
25680
  alignSelf: "flex-start",
@@ -25749,9 +25682,9 @@ function PromptInput({
25749
25682
  justifyContent: "flex-start",
25750
25683
  width: 3
25751
25684
  },
25752
- mode === "bash" ? /* @__PURE__ */ React97.createElement(Text79, { color: theme.bashBorder }, "\xA0!\xA0") : mode === "pyb" ? /* @__PURE__ */ React97.createElement(Text79, { color: theme.noting }, "\xA0#\xA0") : /* @__PURE__ */ React97.createElement(Text79, { color: isLoading ? theme.secondaryText : void 0 }, "P>\xA0")
25685
+ mode === "bash" ? /* @__PURE__ */ React96.createElement(Text78, { color: theme.bashBorder }, "\xA0!\xA0") : mode === "pyb" ? /* @__PURE__ */ React96.createElement(Text78, { color: theme.noting }, "\xA0#\xA0") : /* @__PURE__ */ React96.createElement(Text78, { color: isLoading ? theme.secondaryText : void 0 }, "P>\xA0")
25753
25686
  ),
25754
- /* @__PURE__ */ React97.createElement(Box74, { paddingRight: 1 }, /* @__PURE__ */ React97.createElement(
25687
+ /* @__PURE__ */ React96.createElement(Box73, { paddingRight: 1 }, /* @__PURE__ */ React96.createElement(
25755
25688
  TextInput,
25756
25689
  {
25757
25690
  multiline: true,
@@ -25776,44 +25709,44 @@ function PromptInput({
25776
25709
  onSpecialKey: handleSpecialKey
25777
25710
  }
25778
25711
  ))
25779
- ), !completionActive && suggestions.length === 0 && /* @__PURE__ */ React97.createElement(Box74, { flexDirection: "column", paddingX: 2, paddingY: 0 }, /* @__PURE__ */ React97.createElement(Box74, { flexDirection: "row", justifyContent: "space-between" }, /* @__PURE__ */ React97.createElement(Box74, { justifyContent: "flex-start", gap: 1 }, exitMessage.show ? /* @__PURE__ */ React97.createElement(Text79, { dimColor: true }, "Press ", exitMessage.key, " again to exit") : message.show ? /* @__PURE__ */ React97.createElement(Text79, { dimColor: true }, message.text) : rewindMessagePending ? /* @__PURE__ */ React97.createElement(Text79, { dimColor: true }, "Press Escape again to undo") : modelSwitchMessage.show ? /* @__PURE__ */ React97.createElement(Text79, { color: theme.success }, modelSwitchMessage.text) : mode === "prompt" && currentMode !== "default" ? /* @__PURE__ */ React97.createElement(CompactModeIndicator, null) : /* @__PURE__ */ React97.createElement(React97.Fragment, null, /* @__PURE__ */ React97.createElement(
25780
- Text79,
25712
+ ), !completionActive && suggestions.length === 0 && /* @__PURE__ */ React96.createElement(Box73, { flexDirection: "column", paddingX: 2, paddingY: 0 }, /* @__PURE__ */ React96.createElement(Box73, { flexDirection: "row", justifyContent: "space-between" }, /* @__PURE__ */ React96.createElement(Box73, { justifyContent: "flex-start", gap: 1 }, exitMessage.show ? /* @__PURE__ */ React96.createElement(Text78, { dimColor: true }, "Press ", exitMessage.key, " again to exit") : message.show ? /* @__PURE__ */ React96.createElement(Text78, { dimColor: true }, message.text) : rewindMessagePending ? /* @__PURE__ */ React96.createElement(Text78, { dimColor: true }, "Press Escape again to undo") : modelSwitchMessage.show ? /* @__PURE__ */ React96.createElement(Text78, { color: theme.success }, modelSwitchMessage.text) : mode === "prompt" && currentMode !== "default" ? /* @__PURE__ */ React96.createElement(CompactModeIndicator, null) : /* @__PURE__ */ React96.createElement(React96.Fragment, null, /* @__PURE__ */ React96.createElement(
25713
+ Text78,
25781
25714
  {
25782
25715
  color: mode === "bash" ? theme.bashBorder : void 0,
25783
25716
  dimColor: mode !== "bash"
25784
25717
  },
25785
25718
  "! run some shell command"
25786
- ), /* @__PURE__ */ React97.createElement(Text79, { dimColor: true }, " \xB7 / for commands"), /* @__PURE__ */ React97.createElement(
25787
- Text79,
25719
+ ), /* @__PURE__ */ React96.createElement(Text78, { dimColor: true }, " \xB7 / for commands"), /* @__PURE__ */ React96.createElement(
25720
+ Text78,
25788
25721
  {
25789
25722
  color: mode === "pyb" ? theme.noting : void 0,
25790
25723
  dimColor: mode !== "pyb"
25791
25724
  },
25792
25725
  " ",
25793
25726
  "\xB7 # tell agent something to remember forever"
25794
- ))), /* @__PURE__ */ React97.createElement(Box74, { justifyContent: "flex-end" }, /* @__PURE__ */ React97.createElement(Text79, { dimColor: true, wrap: "truncate-end" }, statusLine ? `${statusLine} \xB7 ESC to interrupt \xB7 2\xD7ESC for undo` : "ESC to interrupt \xB7 2\xD7ESC for undo"))), !exitMessage.show && !message.show && !modelSwitchMessage.show && !rewindMessagePending && /* @__PURE__ */ React97.createElement(Box74, { flexDirection: "row", justifyContent: "space-between" }, /* @__PURE__ */ React97.createElement(Box74, { justifyContent: "flex-start", gap: 1 }, /* @__PURE__ */ React97.createElement(Text79, { dimColor: true, wrap: "truncate-end" }, "option+enter: newline \xB7", " ", showQuickModelSwitchShortcut ? "option+m: switch model \xB7 " : "", "option+g: external editor \xB7 ", modeCycleShortcut.displayText, ": switch mode")), /* @__PURE__ */ React97.createElement(
25727
+ ))), /* @__PURE__ */ React96.createElement(Box73, { justifyContent: "flex-end" }, /* @__PURE__ */ React96.createElement(Text78, { dimColor: true, wrap: "truncate-end" }, statusLine ? `${statusLine} \xB7 ESC to interrupt \xB7 2\xD7ESC for undo` : "ESC to interrupt \xB7 2\xD7ESC for undo"))), !exitMessage.show && !message.show && !modelSwitchMessage.show && !rewindMessagePending && /* @__PURE__ */ React96.createElement(Box73, { flexDirection: "row", justifyContent: "space-between" }, /* @__PURE__ */ React96.createElement(Box73, { justifyContent: "flex-start", gap: 1 }, /* @__PURE__ */ React96.createElement(Text78, { dimColor: true, wrap: "truncate-end" }, "option+enter: newline \xB7", " ", showQuickModelSwitchShortcut ? "option+m: switch model \xB7 " : "", "option+g: external editor \xB7 ", modeCycleShortcut.displayText, ": switch mode")), /* @__PURE__ */ React96.createElement(
25795
25728
  SentryErrorBoundary,
25796
25729
  {
25797
- children: /* @__PURE__ */ React97.createElement(Box74, { justifyContent: "flex-end", gap: 1 }, /* @__PURE__ */ React97.createElement(TokenWarning, { tokenUsage }))
25730
+ children: /* @__PURE__ */ React96.createElement(Box73, { justifyContent: "flex-end", gap: 1 }, /* @__PURE__ */ React96.createElement(TokenWarning, { tokenUsage }))
25798
25731
  }
25799
- ))), suggestions.length > 0 && /* @__PURE__ */ React97.createElement(
25800
- Box74,
25732
+ ))), suggestions.length > 0 && /* @__PURE__ */ React96.createElement(
25733
+ Box73,
25801
25734
  {
25802
25735
  flexDirection: "row",
25803
25736
  justifyContent: "space-between",
25804
25737
  paddingX: 2,
25805
25738
  paddingY: 0
25806
25739
  },
25807
- /* @__PURE__ */ React97.createElement(Box74, { flexDirection: "column" }, renderedSuggestions, /* @__PURE__ */ React97.createElement(
25808
- Box74,
25740
+ /* @__PURE__ */ React96.createElement(Box73, { flexDirection: "column" }, renderedSuggestions, /* @__PURE__ */ React96.createElement(
25741
+ Box73,
25809
25742
  {
25810
25743
  marginTop: 1,
25811
25744
  paddingX: 3,
25812
25745
  borderStyle: "round",
25813
25746
  borderColor: "gray"
25814
25747
  },
25815
- /* @__PURE__ */ React97.createElement(
25816
- Text79,
25748
+ /* @__PURE__ */ React96.createElement(
25749
+ Text78,
25817
25750
  {
25818
25751
  dimColor: !emptyDirMessage,
25819
25752
  color: emptyDirMessage ? "yellow" : void 0
@@ -25833,10 +25766,10 @@ function PromptInput({
25833
25766
  })()
25834
25767
  )
25835
25768
  )),
25836
- /* @__PURE__ */ React97.createElement(
25769
+ /* @__PURE__ */ React96.createElement(
25837
25770
  SentryErrorBoundary,
25838
25771
  {
25839
- children: /* @__PURE__ */ React97.createElement(Box74, { justifyContent: "flex-end", gap: 1 }, /* @__PURE__ */ React97.createElement(TokenWarning, { tokenUsage: countTokens(messages) }))
25772
+ children: /* @__PURE__ */ React96.createElement(Box73, { justifyContent: "flex-end", gap: 1 }, /* @__PURE__ */ React96.createElement(TokenWarning, { tokenUsage: countTokens(messages) }))
25840
25773
  }
25841
25774
  )
25842
25775
  ));
@@ -26464,24 +26397,6 @@ function startWatchingTaskList(listId) {
26464
26397
  startFallbackWatcher(entry);
26465
26398
  }
26466
26399
 
26467
- // src/utils/session/finalizeTurn.ts
26468
- function finalizeTurnAndFlushQueue() {
26469
- setSessionState({ activeAbortController: null });
26470
- setSessionState({ isProcessingTurn: false });
26471
- setRequestStatus({ kind: "idle" });
26472
- const state = getSessionState();
26473
- if (state.isConsumingQueue) {
26474
- setSessionState({ shouldFlushQueue: false });
26475
- return { shouldFlushQueue: false };
26476
- }
26477
- if (state.queuedUserInputs.length === 0) {
26478
- setSessionState({ shouldFlushQueue: false });
26479
- return { shouldFlushQueue: false };
26480
- }
26481
- setSessionState({ shouldFlushQueue: true });
26482
- return { shouldFlushQueue: true };
26483
- }
26484
-
26485
26400
  // src/utils/session/fileRecoveryCore.ts
26486
26401
  var MAX_FILES_TO_RECOVER = 5;
26487
26402
  var MAX_TOKENS_PER_FILE = 1e4;
@@ -27210,22 +27125,6 @@ async function* queryCore(messages, systemPrompt, context, canUseTool, toolUseCo
27210
27125
  return;
27211
27126
  }
27212
27127
  }
27213
- const queuedMessages = await toolUseContext.options?.dequeueQueuedMessagesForNextTurn?.(
27214
- assistantMessage.message?.id
27215
- );
27216
- if (queuedMessages && queuedMessages.length > 0) {
27217
- yield assistantMessage;
27218
- yield* await queryCore(
27219
- [...messages, assistantMessage, ...queuedMessages],
27220
- systemPrompt,
27221
- context,
27222
- canUseTool,
27223
- toolUseContext,
27224
- getBinaryFeedbackResponse,
27225
- hookState
27226
- );
27227
- return;
27228
- }
27229
27128
  yield assistantMessage;
27230
27129
  return;
27231
27130
  }
@@ -27254,17 +27153,8 @@ async function* queryCore(messages, systemPrompt, context, canUseTool, toolUseCo
27254
27153
  return;
27255
27154
  }
27256
27155
  try {
27257
- const queuedMessages = await toolUseContext.options?.dequeueQueuedMessagesForNextTurn?.(
27258
- assistantMessage.message?.id
27259
- );
27260
- const nextMessages = queuedMessages?.length ? [
27261
- ...messages,
27262
- assistantMessage,
27263
- ...toolMessagesForNextTurn,
27264
- ...queuedMessages
27265
- ] : [...messages, assistantMessage, ...toolMessagesForNextTurn];
27266
27156
  yield* await queryCore(
27267
- nextMessages,
27157
+ [...messages, assistantMessage, ...toolMessagesForNextTurn],
27268
27158
  systemPrompt,
27269
27159
  context,
27270
27160
  canUseTool,
@@ -27276,7 +27166,7 @@ async function* queryCore(messages, systemPrompt, context, canUseTool, toolUseCo
27276
27166
  throw error;
27277
27167
  }
27278
27168
  } finally {
27279
- finalizeTurnAndFlushQueue();
27169
+ setRequestStatus({ kind: "idle" });
27280
27170
  }
27281
27171
  }
27282
27172
  async function* runToolUse(toolUse, siblingToolUseIDs, assistantMessage, canUseTool, toolUseContext, shouldSkipPermissionCheck) {
@@ -27680,118 +27570,18 @@ function createErrorToolResultBlock(args) {
27680
27570
  };
27681
27571
  }
27682
27572
 
27683
- // src/utils/queue/queuedInput.ts
27684
- function applyQueuedEdit(args) {
27685
- const { entries, replaceId, content, mode, delete: shouldDelete } = args;
27686
- const index = entries.findIndex((entry) => entry.id === replaceId);
27687
- if (index === -1) {
27688
- return entries;
27689
- }
27690
- if (shouldDelete) {
27691
- return entries.filter((entry) => entry.id !== replaceId);
27692
- }
27693
- const target = entries[index];
27694
- const updated = {
27695
- ...target,
27696
- content: content ?? target.content,
27697
- mode: mode ?? target.mode
27698
- };
27699
- const next = [...entries];
27700
- next[index] = updated;
27701
- return next;
27702
- }
27703
- function takeQueuedBatch(args) {
27704
- const { entries, windowMs } = args;
27705
- if (entries.length === 0) {
27706
- return { batch: null, remaining: entries };
27707
- }
27708
- const sorted = [...entries].sort((a, b) => a.queuedAt - b.queuedAt);
27709
- const first = sorted[0];
27710
- const batchEntries = [first];
27711
- let lastQueuedAt = first.queuedAt;
27712
- for (let i = 1; i < sorted.length; i += 1) {
27713
- const next = sorted[i];
27714
- if (next.mode !== first.mode) {
27715
- break;
27716
- }
27717
- if (next.queuedAt - lastQueuedAt > windowMs) {
27718
- break;
27719
- }
27720
- batchEntries.push(next);
27721
- lastQueuedAt = next.queuedAt;
27722
- }
27723
- const batchIds = new Set(batchEntries.map((entry) => entry.id));
27724
- const remaining = entries.filter((entry) => !batchIds.has(entry.id));
27725
- return {
27726
- batch: {
27727
- entries: batchEntries,
27728
- mode: first.mode,
27729
- queuedAt: first.queuedAt
27730
- },
27731
- remaining
27732
- };
27733
- }
27734
- function buildQueuedWrapper(args) {
27735
- const prefix = [
27736
- "<system-reminder>",
27737
- "\u7528\u6237\u521A\u8FFD\u52A0\u4E86\u4E00\u6761\u4EFB\u52A1\u6307\u4EE4\uFF0C\u53D1\u751F\u5728\u6A21\u578B\u8F93\u51FA\u671F\u95F4",
27738
- "</system-reminder>",
27739
- "<queued-user-message>",
27740
- `<queued-at>${args.queuedAt}</queued-at>`,
27741
- "<queued-during>assistant_response</queued-during>"
27742
- ].join("\n");
27743
- const suffix = "</queued-user-message>";
27744
- return { prefix, suffix };
27745
- }
27746
- function wrapQueuedContent(args) {
27747
- const { prefix, suffix } = buildQueuedWrapper({
27748
- queuedAt: args.queuedAt
27749
- });
27750
- return `${prefix}
27751
- ${args.content}
27752
- ${suffix}`;
27753
- }
27754
-
27755
- // src/utils/session/sessionQueue.ts
27756
- import { randomUUID as randomUUID5 } from "crypto";
27757
- var SessionQueue = class {
27758
- constructor(state) {
27759
- this.state = state;
27760
- }
27761
- enqueue(input) {
27762
- const entry = {
27763
- id: randomUUID5(),
27764
- content: input.content,
27765
- queuedAt: Date.now(),
27766
- mode: input.mode
27767
- };
27768
- this.state.queuedUserInputs.push(entry);
27769
- return entry;
27770
- }
27771
- flushOne() {
27772
- if (this.state.isConsumingQueue) return null;
27773
- if (this.state.queuedUserInputs.length === 0) return null;
27774
- this.state.isConsumingQueue = true;
27775
- try {
27776
- return this.state.queuedUserInputs.shift() ?? null;
27777
- } finally {
27778
- this.state.isConsumingQueue = false;
27779
- }
27780
- }
27781
- };
27782
-
27783
27573
  // src/ui/components/binary-feedback/BinaryFeedback.tsx
27784
- import { default as React101, useCallback as useCallback15 } from "react";
27574
+ import { default as React100, useCallback as useCallback15 } from "react";
27785
27575
 
27786
27576
  // src/ui/components/binary-feedback/BinaryFeedbackView.tsx
27787
27577
  import chalk14 from "chalk";
27788
- import { Box as Box76, Text as Text80, useInput as useInput29 } from "ink";
27578
+ import { Box as Box75, Text as Text79, useInput as useInput29 } from "ink";
27789
27579
  import Link2 from "ink-link";
27790
- import React100, { useState as useState27 } from "react";
27580
+ import React99, { useState as useState27 } from "react";
27791
27581
 
27792
27582
  // src/ui/components/binary-feedback/BinaryFeedbackOption.tsx
27793
- import * as React99 from "react";
27794
- import { Box as Box75 } from "ink";
27583
+ import * as React98 from "react";
27584
+ import { Box as Box74 } from "ink";
27795
27585
  function BinaryFeedbackOption({
27796
27586
  debug: debug2,
27797
27587
  erroredToolUseIDs,
@@ -27803,7 +27593,7 @@ function BinaryFeedbackOption({
27803
27593
  verbose
27804
27594
  }) {
27805
27595
  const { columns } = useTerminalSize();
27806
- return normalizeMessages([message]).filter((_) => _.type !== "progress").map((_, index) => /* @__PURE__ */ React99.createElement(Box75, { flexDirection: "column", key: index }, /* @__PURE__ */ React99.createElement(
27596
+ return normalizeMessages([message]).filter((_) => _.type !== "progress").map((_, index) => /* @__PURE__ */ React98.createElement(Box74, { flexDirection: "column", key: index }, /* @__PURE__ */ React98.createElement(
27807
27597
  Message,
27808
27598
  {
27809
27599
  addMargin: false,
@@ -27819,7 +27609,7 @@ function BinaryFeedbackOption({
27819
27609
  verbose,
27820
27610
  width: columns / 2 - 6
27821
27611
  }
27822
- ), /* @__PURE__ */ React99.createElement(AdditionalContext, { message: _, verbose })));
27612
+ ), /* @__PURE__ */ React98.createElement(AdditionalContext, { message: _, verbose })));
27823
27613
  }
27824
27614
  function AdditionalContext({
27825
27615
  message,
@@ -27851,7 +27641,7 @@ function AdditionalContext({
27851
27641
  } catch {
27852
27642
  return null;
27853
27643
  }
27854
- return /* @__PURE__ */ React99.createElement(
27644
+ return /* @__PURE__ */ React98.createElement(
27855
27645
  FileEditToolDiff,
27856
27646
  {
27857
27647
  file_path: input.data.file_path,
@@ -27867,7 +27657,7 @@ function AdditionalContext({
27867
27657
  if (!input.success) {
27868
27658
  return null;
27869
27659
  }
27870
- return /* @__PURE__ */ React99.createElement(
27660
+ return /* @__PURE__ */ React98.createElement(
27871
27661
  FileWriteToolDiff,
27872
27662
  {
27873
27663
  file_path: input.data.file_path,
@@ -27932,8 +27722,8 @@ function BinaryFeedbackView({
27932
27722
  onChoose?.("neither");
27933
27723
  }
27934
27724
  });
27935
- return /* @__PURE__ */ React100.createElement(React100.Fragment, null, /* @__PURE__ */ React100.createElement(
27936
- Box76,
27725
+ return /* @__PURE__ */ React99.createElement(React99.Fragment, null, /* @__PURE__ */ React99.createElement(
27726
+ Box75,
27937
27727
  {
27938
27728
  flexDirection: "column",
27939
27729
  height: "100%",
@@ -27941,9 +27731,9 @@ function BinaryFeedbackView({
27941
27731
  borderStyle: "round",
27942
27732
  borderColor: theme.permission
27943
27733
  },
27944
- /* @__PURE__ */ React100.createElement(Box76, { width: "100%", justifyContent: "space-between", paddingX: 1 }, /* @__PURE__ */ React100.createElement(Text80, { bold: true, color: theme.permission }, "[ANT-ONLY] Help train ", PRODUCT_NAME), /* @__PURE__ */ React100.createElement(Text80, null, /* @__PURE__ */ React100.createElement(Link2, { url: HELP_URL }, "[?]"))),
27945
- /* @__PURE__ */ React100.createElement(Box76, { flexDirection: "row", width: "100%", flexGrow: 1, paddingTop: 1 }, /* @__PURE__ */ React100.createElement(
27946
- Box76,
27734
+ /* @__PURE__ */ React99.createElement(Box75, { width: "100%", justifyContent: "space-between", paddingX: 1 }, /* @__PURE__ */ React99.createElement(Text79, { bold: true, color: theme.permission }, "[ANT-ONLY] Help train ", PRODUCT_NAME), /* @__PURE__ */ React99.createElement(Text79, null, /* @__PURE__ */ React99.createElement(Link2, { url: HELP_URL }, "[?]"))),
27735
+ /* @__PURE__ */ React99.createElement(Box75, { flexDirection: "row", width: "100%", flexGrow: 1, paddingTop: 1 }, /* @__PURE__ */ React99.createElement(
27736
+ Box75,
27947
27737
  {
27948
27738
  flexDirection: "column",
27949
27739
  flexGrow: 1,
@@ -27954,7 +27744,7 @@ function BinaryFeedbackView({
27954
27744
  marginRight: 1,
27955
27745
  padding: 1
27956
27746
  },
27957
- /* @__PURE__ */ React100.createElement(
27747
+ /* @__PURE__ */ React99.createElement(
27958
27748
  BinaryFeedbackOption,
27959
27749
  {
27960
27750
  erroredToolUseIDs,
@@ -27967,8 +27757,8 @@ function BinaryFeedbackView({
27967
27757
  verbose
27968
27758
  }
27969
27759
  )
27970
- ), /* @__PURE__ */ React100.createElement(
27971
- Box76,
27760
+ ), /* @__PURE__ */ React99.createElement(
27761
+ Box75,
27972
27762
  {
27973
27763
  flexDirection: "column",
27974
27764
  flexGrow: 1,
@@ -27979,7 +27769,7 @@ function BinaryFeedbackView({
27979
27769
  marginLeft: 1,
27980
27770
  padding: 1
27981
27771
  },
27982
- /* @__PURE__ */ React100.createElement(
27772
+ /* @__PURE__ */ React99.createElement(
27983
27773
  BinaryFeedbackOption,
27984
27774
  {
27985
27775
  erroredToolUseIDs,
@@ -27993,7 +27783,7 @@ function BinaryFeedbackView({
27993
27783
  }
27994
27784
  )
27995
27785
  )),
27996
- /* @__PURE__ */ React100.createElement(Box76, { flexDirection: "column", paddingTop: 1, paddingX: 1 }, /* @__PURE__ */ React100.createElement(Text80, null, "How do you want to proceed?"), /* @__PURE__ */ React100.createElement(
27786
+ /* @__PURE__ */ React99.createElement(Box75, { flexDirection: "column", paddingTop: 1, paddingX: 1 }, /* @__PURE__ */ React99.createElement(Text79, null, "How do you want to proceed?"), /* @__PURE__ */ React99.createElement(
27997
27787
  Select,
27998
27788
  {
27999
27789
  options: getOptions2(),
@@ -28002,7 +27792,7 @@ function BinaryFeedbackView({
28002
27792
  onChange: onChoose
28003
27793
  }
28004
27794
  ))
28005
- ), exitState.pending ? /* @__PURE__ */ React100.createElement(Box76, { marginLeft: 3 }, /* @__PURE__ */ React100.createElement(Text80, { dimColor: true }, "Press ", exitState.keyName, " again to exit")) : /* @__PURE__ */ React100.createElement(Text80, null, " "));
27795
+ ), exitState.pending ? /* @__PURE__ */ React99.createElement(Box75, { marginLeft: 3 }, /* @__PURE__ */ React99.createElement(Text79, { dimColor: true }, "Press ", exitState.keyName, " again to exit")) : /* @__PURE__ */ React99.createElement(Text79, null, " "));
28006
27796
  }
28007
27797
 
28008
27798
  // src/ui/components/binary-feedback/BinaryFeedback.tsx
@@ -28028,7 +27818,7 @@ function BinaryFeedback({
28028
27818
  useNotifyAfterTimeout(
28029
27819
  `${PRODUCT_NAME} needs your input on a response comparison`
28030
27820
  );
28031
- return /* @__PURE__ */ React101.createElement(
27821
+ return /* @__PURE__ */ React100.createElement(
28032
27822
  BinaryFeedbackView,
28033
27823
  {
28034
27824
  debug: debug2,
@@ -28136,12 +27926,6 @@ function REPL({
28136
27926
  null
28137
27927
  );
28138
27928
  const [messages, setMessages2] = useState28(initialMessages ?? []);
28139
- const [queuedMessages, setQueuedMessages] = useState28(
28140
- () => getSessionState("queuedUserInputs")
28141
- );
28142
- const queuedMessagesRef = useRef13(
28143
- getSessionState("queuedUserInputs")
28144
- );
28145
27929
  const [inputValue, setInputValue] = useState28("");
28146
27930
  const [inputMode, setInputMode] = useState28(
28147
27931
  "prompt"
@@ -28168,129 +27952,7 @@ function REPL({
28168
27952
  []
28169
27953
  );
28170
27954
  const readFileTimestamps = useRef13({});
28171
- const queueMergeWindowMs = getGlobalConfig().queueMergeWindowMs ?? 500;
28172
- const sessionQueue = useMemo26(
28173
- () => new SessionQueue(getSessionState()),
28174
- []
28175
- );
28176
- const updateQueuedMessages = useCallback16(
28177
- (next) => {
28178
- setSessionState({ queuedUserInputs: next });
28179
- queuedMessagesRef.current = next;
28180
- setQueuedMessages(next);
28181
- },
28182
- []
28183
- );
28184
- const updateAbortController = useCallback16(
28185
- (next) => {
28186
- setAbortController(next);
28187
- setSessionState({ activeAbortController: next });
28188
- },
28189
- []
28190
- );
28191
- const enqueueQueuedMessage = useCallback16(
28192
- (args) => {
28193
- if (args.replaceId) {
28194
- const next = applyQueuedEdit({
28195
- entries: queuedMessagesRef.current,
28196
- replaceId: args.replaceId,
28197
- content: args.content,
28198
- mode: args.mode,
28199
- delete: args.delete
28200
- });
28201
- updateQueuedMessages(next);
28202
- return;
28203
- }
28204
- sessionQueue.enqueue({ content: args.content, mode: args.mode });
28205
- updateQueuedMessages([...getSessionState("queuedUserInputs")]);
28206
- },
28207
- [sessionQueue, updateQueuedMessages]
28208
- );
28209
- const dequeueQueuedMessageForEdit = useCallback16(
28210
- (currentEditId) => {
28211
- const current = queuedMessagesRef.current;
28212
- if (current.length === 0) return null;
28213
- if (!currentEditId) {
28214
- const last2 = current[current.length - 1];
28215
- return { id: last2.id, content: last2.content, mode: last2.mode };
28216
- }
28217
- const index = current.findIndex((entry) => entry.id === currentEditId);
28218
- if (index > 0) {
28219
- const prev = current[index - 1];
28220
- return { id: prev.id, content: prev.content, mode: prev.mode };
28221
- }
28222
- const fallback = current[current.length - 1];
28223
- return fallback ? { id: fallback.id, content: fallback.content, mode: fallback.mode } : null;
28224
- },
28225
- []
28226
- );
28227
- const dequeueQueuedMessagesForNextTurn = useCallback16(
28228
- async (_activeTurnId) => {
28229
- const { batch, remaining } = takeQueuedBatch({
28230
- entries: queuedMessagesRef.current,
28231
- windowMs: queueMergeWindowMs
28232
- });
28233
- if (!batch) return null;
28234
- updateQueuedMessages(remaining);
28235
- const combinedContent = batch.entries.length === 1 ? batch.entries[0].content : batch.entries.map((entry, index) => `${index + 1}) ${entry.content}`).join("\n");
28236
- const wrappedContent = batch.mode === "bash" ? combinedContent : wrapQueuedContent({
28237
- content: combinedContent,
28238
- queuedAt: new Date(batch.queuedAt).toISOString()
28239
- });
28240
- const generatedMessages = await processUserInput(
28241
- wrappedContent,
28242
- batch.mode,
28243
- setToolJSX,
28244
- {
28245
- options: {
28246
- commands,
28247
- forkNumber,
28248
- messageLogName,
28249
- tools,
28250
- verbose,
28251
- maxThinkingTokens: 0,
28252
- safeMode,
28253
- toolPermissionContext: getToolPermissionContextForConversationKey({
28254
- conversationKey: `${messageLogName}:${forkNumber}`,
28255
- isBypassPermissionsModeAvailable: !(safeMode ?? false)
28256
- })
28257
- },
28258
- messageId: getLastAssistantMessageId(messages),
28259
- setForkConvoWithMessagesOnTheNextRender,
28260
- readFileTimestamps: readFileTimestamps.current,
28261
- abortController: abortController || new AbortController()
28262
- },
28263
- null
28264
- );
28265
- return generatedMessages;
28266
- },
28267
- [
28268
- commands,
28269
- forkNumber,
28270
- messageLogName,
28271
- tools,
28272
- verbose,
28273
- safeMode,
28274
- setToolJSX,
28275
- setForkConvoWithMessagesOnTheNextRender,
28276
- messages,
28277
- abortController,
28278
- queueMergeWindowMs,
28279
- updateQueuedMessages
28280
- ]
28281
- );
28282
27955
  const { status: apiKeyStatus, reverify } = useApiKeyVerification();
28283
- useEffect26(() => {
28284
- const initialStatus = getRequestStatus();
28285
- const initialBusy = initialStatus.kind !== "idle";
28286
- setIsLoading(initialBusy);
28287
- setSessionState({ isProcessingTurn: initialBusy });
28288
- return subscribeRequestStatus((status) => {
28289
- const busy = status.kind !== "idle";
28290
- setIsLoading(busy);
28291
- setSessionState({ isProcessingTurn: busy });
28292
- });
28293
- }, []);
28294
27956
  function onCancel() {
28295
27957
  if (!isLoading) {
28296
27958
  return;
@@ -28346,7 +28008,7 @@ function REPL({
28346
28008
  }
28347
28009
  setIsLoading(true);
28348
28010
  const newAbortController = new AbortController();
28349
- updateAbortController(newAbortController);
28011
+ setAbortController(newAbortController);
28350
28012
  const model = new ModelManager(getGlobalConfig()).getModelName("main");
28351
28013
  const newMessages = await processUserInput(
28352
28014
  initialPrompt,
@@ -28407,7 +28069,6 @@ function REPL({
28407
28069
  verbose,
28408
28070
  safeMode,
28409
28071
  maxThinkingTokens,
28410
- dequeueQueuedMessagesForNextTurn,
28411
28072
  toolPermissionContext: getToolPermissionContextForConversationKey({
28412
28073
  conversationKey: `${messageLogName}:${forkNumber}`,
28413
28074
  isBypassPermissionsModeAvailable: !(safeMode ?? false)
@@ -28422,14 +28083,6 @@ function REPL({
28422
28083
  )) {
28423
28084
  setMessages2((oldMessages) => [...oldMessages, message]);
28424
28085
  }
28425
- if (getSessionState("shouldFlushQueue")) {
28426
- const queuedMessagesForNextTurn = await dequeueQueuedMessagesForNextTurn();
28427
- setSessionState({ shouldFlushQueue: false });
28428
- if (queuedMessagesForNextTurn && queuedMessagesForNextTurn.length > 0) {
28429
- await onQuery(queuedMessagesForNextTurn);
28430
- return;
28431
- }
28432
- }
28433
28086
  } else {
28434
28087
  addToHistory(initialPrompt);
28435
28088
  }
@@ -28437,12 +28090,12 @@ function REPL({
28437
28090
  getGlobalConfig().hasAcknowledgedCostThreshold || false
28438
28091
  );
28439
28092
  setIsLoading(false);
28440
- updateAbortController(null);
28093
+ setAbortController(null);
28441
28094
  }
28442
28095
  async function onQuery(newMessages, passedAbortController) {
28443
28096
  const controllerToUse = passedAbortController || new AbortController();
28444
28097
  if (!passedAbortController) {
28445
- updateAbortController(controllerToUse);
28098
+ setAbortController(controllerToUse);
28446
28099
  }
28447
28100
  const isPybRequest = newMessages.length > 0 && newMessages[0].type === "user" && "options" in newMessages[0] && newMessages[0].options?.isPybRequest === true;
28448
28101
  setMessages2((oldMessages) => [...oldMessages, ...newMessages]);
@@ -28451,7 +28104,7 @@ function REPL({
28451
28104
  if (lastMessage.type === "user" && typeof lastMessage.message.content === "string") {
28452
28105
  }
28453
28106
  if (lastMessage.type === "assistant") {
28454
- updateAbortController(null);
28107
+ setAbortController(null);
28455
28108
  setIsLoading(false);
28456
28109
  return;
28457
28110
  }
@@ -28480,7 +28133,6 @@ function REPL({
28480
28133
  safeMode,
28481
28134
  maxThinkingTokens,
28482
28135
  isPybRequest: isPybRequest || void 0,
28483
- dequeueQueuedMessagesForNextTurn,
28484
28136
  toolPermissionContext: getToolPermissionContextForConversationKey({
28485
28137
  conversationKey: `${messageLogName}:${forkNumber}`,
28486
28138
  isBypassPermissionsModeAvailable: !(safeMode ?? false)
@@ -28509,14 +28161,6 @@ function REPL({
28509
28161
  debug.error("REPL_PYB_SAVE_PROJECT_DOCS_ERROR", { error });
28510
28162
  }
28511
28163
  }
28512
- if (getSessionState("shouldFlushQueue")) {
28513
- const queuedMessagesForNextTurn = await dequeueQueuedMessagesForNextTurn();
28514
- setSessionState({ shouldFlushQueue: false });
28515
- if (queuedMessagesForNextTurn && queuedMessagesForNextTurn.length > 0) {
28516
- await onQuery(queuedMessagesForNextTurn);
28517
- return;
28518
- }
28519
- }
28520
28164
  setIsLoading(false);
28521
28165
  }
28522
28166
  useCostSummary();
@@ -28577,7 +28221,7 @@ function REPL({
28577
28221
  const messagesJSX = useMemo26(() => {
28578
28222
  return orderedMessages.map((_, index) => {
28579
28223
  const toolUseID = getToolUseID(_);
28580
- const message = _.type === "progress" ? _.content.message.content[0]?.type === "text" && _.content.message.content[0].text === INTERRUPT_MESSAGE ? /* @__PURE__ */ React102.createElement(
28224
+ const message = _.type === "progress" ? _.content.message.content[0]?.type === "text" && _.content.message.content[0].text === INTERRUPT_MESSAGE ? /* @__PURE__ */ React101.createElement(
28581
28225
  Message,
28582
28226
  {
28583
28227
  message: _.content,
@@ -28592,10 +28236,10 @@ function REPL({
28592
28236
  shouldAnimate: false,
28593
28237
  shouldShowDot: false
28594
28238
  }
28595
- ) : /* @__PURE__ */ React102.createElement(
28239
+ ) : /* @__PURE__ */ React101.createElement(
28596
28240
  MessageResponse,
28597
28241
  {
28598
- children: /* @__PURE__ */ React102.createElement(
28242
+ children: /* @__PURE__ */ React101.createElement(
28599
28243
  Message,
28600
28244
  {
28601
28245
  message: _.content,
@@ -28614,7 +28258,7 @@ function REPL({
28614
28258
  }
28615
28259
  )
28616
28260
  }
28617
- ) : /* @__PURE__ */ React102.createElement(
28261
+ ) : /* @__PURE__ */ React101.createElement(
28618
28262
  Message,
28619
28263
  {
28620
28264
  message: _,
@@ -28633,8 +28277,8 @@ function REPL({
28633
28277
  const isInStaticPrefix = index < replStaticPrefixLength;
28634
28278
  if (debug2) {
28635
28279
  return {
28636
- jsx: /* @__PURE__ */ React102.createElement(
28637
- Box77,
28280
+ jsx: /* @__PURE__ */ React101.createElement(
28281
+ Box76,
28638
28282
  {
28639
28283
  borderStyle: "single",
28640
28284
  borderColor: isInStaticPrefix ? "green" : "red",
@@ -28646,7 +28290,7 @@ function REPL({
28646
28290
  };
28647
28291
  }
28648
28292
  return {
28649
- jsx: /* @__PURE__ */ React102.createElement(Box77, { key: _.uuid, width: "100%" }, message)
28293
+ jsx: /* @__PURE__ */ React101.createElement(Box76, { key: _.uuid, width: "100%" }, message)
28650
28294
  };
28651
28295
  });
28652
28296
  }, [
@@ -28669,7 +28313,7 @@ function REPL({
28669
28313
  const staticItems = useMemo26(
28670
28314
  () => [
28671
28315
  {
28672
- jsx: /* @__PURE__ */ React102.createElement(Box77, { flexDirection: "column", key: `logo${forkNumber}` }, /* @__PURE__ */ React102.createElement(
28316
+ jsx: /* @__PURE__ */ React101.createElement(Box76, { flexDirection: "column", key: `logo${forkNumber}` }, /* @__PURE__ */ React101.createElement(
28673
28317
  Logo,
28674
28318
  {
28675
28319
  mcpClients,
@@ -28677,7 +28321,7 @@ function REPL({
28677
28321
  updateBannerVersion: updateAvailableVersion,
28678
28322
  updateBannerCommands: updateCommands
28679
28323
  }
28680
- ), /* @__PURE__ */ React102.createElement(ProjectOnboarding, { workspaceDir: getOriginalCwd() }))
28324
+ ), /* @__PURE__ */ React101.createElement(ProjectOnboarding, { workspaceDir: getOriginalCwd() }))
28681
28325
  },
28682
28326
  ...messagesJSX.slice(0, replStaticPrefixLength)
28683
28327
  ],
@@ -28697,24 +28341,23 @@ function REPL({
28697
28341
  );
28698
28342
  const showingCostDialog = !isLoading && showCostDialog;
28699
28343
  const conversationKey = `${messageLogName}:${forkNumber}`;
28700
- const hasQueuedMessages = queuedMessages.length > 0;
28701
- return /* @__PURE__ */ React102.createElement(
28344
+ return /* @__PURE__ */ React101.createElement(
28702
28345
  PermissionProvider,
28703
28346
  {
28704
28347
  conversationKey,
28705
28348
  isBypassPermissionsModeAvailable: !safeMode
28706
28349
  },
28707
- /* @__PURE__ */ React102.createElement(React102.Fragment, null, /* @__PURE__ */ React102.createElement(React102.Fragment, { key: `static-messages-${forkNumber}` }, /* @__PURE__ */ React102.createElement(Static2, { items: staticItems, children: (item) => item.jsx })), /* @__PURE__ */ React102.createElement(TaskPanel, null), transientItems.map((_) => _.jsx), /* @__PURE__ */ React102.createElement(
28708
- Box77,
28350
+ /* @__PURE__ */ React101.createElement(React101.Fragment, null, /* @__PURE__ */ React101.createElement(React101.Fragment, { key: `static-messages-${forkNumber}` }, /* @__PURE__ */ React101.createElement(Static2, { items: staticItems, children: (item) => item.jsx })), /* @__PURE__ */ React101.createElement(TaskPanel, null), transientItems.map((_) => _.jsx), /* @__PURE__ */ React101.createElement(
28351
+ Box76,
28709
28352
  {
28710
28353
  borderColor: "red",
28711
28354
  borderStyle: debug2 ? "single" : void 0,
28712
28355
  flexDirection: "column",
28713
28356
  width: "100%"
28714
28357
  },
28715
- !toolJSX && !toolUseConfirm && !binaryFeedbackContext && isLoading && /* @__PURE__ */ React102.createElement(RequestStatusIndicator, null),
28358
+ !toolJSX && !toolUseConfirm && !binaryFeedbackContext && isLoading && /* @__PURE__ */ React101.createElement(RequestStatusIndicator, null),
28716
28359
  toolJSX ? toolJSX.jsx : null,
28717
- !toolJSX && binaryFeedbackContext && !isMessageSelectorVisible && /* @__PURE__ */ React102.createElement(
28360
+ !toolJSX && binaryFeedbackContext && !isMessageSelectorVisible && /* @__PURE__ */ React101.createElement(
28718
28361
  BinaryFeedback,
28719
28362
  {
28720
28363
  m1: binaryFeedbackContext.m1,
@@ -28732,7 +28375,7 @@ function REPL({
28732
28375
  unresolvedToolUseIDs
28733
28376
  }
28734
28377
  ),
28735
- !toolJSX && toolUseConfirm && !isMessageSelectorVisible && !binaryFeedbackContext && /* @__PURE__ */ React102.createElement(
28378
+ !toolJSX && toolUseConfirm && !isMessageSelectorVisible && !binaryFeedbackContext && /* @__PURE__ */ React101.createElement(
28736
28379
  PermissionRequest,
28737
28380
  {
28738
28381
  toolUseConfirm,
@@ -28740,7 +28383,7 @@ function REPL({
28740
28383
  verbose
28741
28384
  }
28742
28385
  ),
28743
- !toolJSX && !toolUseConfirm && !isMessageSelectorVisible && !binaryFeedbackContext && showingCostDialog && /* @__PURE__ */ React102.createElement(
28386
+ !toolJSX && !toolUseConfirm && !isMessageSelectorVisible && !binaryFeedbackContext && showingCostDialog && /* @__PURE__ */ React101.createElement(
28744
28387
  CostThresholdDialog,
28745
28388
  {
28746
28389
  onDone: () => {
@@ -28754,17 +28397,7 @@ function REPL({
28754
28397
  }
28755
28398
  }
28756
28399
  ),
28757
- /* @__PURE__ */ React102.createElement(
28758
- QueuedMessageList,
28759
- {
28760
- items: queuedMessages.map((item) => ({
28761
- id: item.id,
28762
- content: item.content
28763
- }))
28764
- }
28765
- ),
28766
- /* @__PURE__ */ React102.createElement(QueuedHintLine, { show: hasQueuedMessages && isLoading }),
28767
- !toolUseConfirm && !toolJSX?.shouldHidePromptInput && shouldShowPromptInput && !isMessageSelectorVisible && !binaryFeedbackContext && !showingCostDialog && /* @__PURE__ */ React102.createElement(React102.Fragment, null, /* @__PURE__ */ React102.createElement(
28400
+ !toolUseConfirm && !toolJSX?.shouldHidePromptInput && shouldShowPromptInput && !isMessageSelectorVisible && !binaryFeedbackContext && !showingCostDialog && /* @__PURE__ */ React101.createElement(React101.Fragment, null, /* @__PURE__ */ React101.createElement(
28768
28401
  PromptInput_default,
28769
28402
  {
28770
28403
  commands,
@@ -28786,18 +28419,15 @@ function REPL({
28786
28419
  submitCount,
28787
28420
  onSubmitCountChange: setSubmitCount,
28788
28421
  setIsLoading,
28789
- setAbortController: updateAbortController,
28422
+ setAbortController,
28790
28423
  uiRefreshCounter,
28791
28424
  onShowMessageSelector: () => setIsMessageSelectorVisible((prev) => !prev),
28792
28425
  setForkConvoWithMessagesOnTheNextRender,
28793
28426
  readFileTimestamps: readFileTimestamps.current,
28794
- abortController,
28795
- onQueueMessage: enqueueQueuedMessage,
28796
- onQueueEditRequest: dequeueQueuedMessageForEdit,
28797
- hasQueuedMessages
28427
+ abortController
28798
28428
  }
28799
28429
  ))
28800
- ), isMessageSelectorVisible && /* @__PURE__ */ React102.createElement(
28430
+ ), isMessageSelectorVisible && /* @__PURE__ */ React101.createElement(
28801
28431
  MessageSelector,
28802
28432
  {
28803
28433
  erroredToolUseIDs,
@@ -28823,13 +28453,13 @@ function REPL({
28823
28453
  onEscape: () => setIsMessageSelectorVisible(false),
28824
28454
  tools
28825
28455
  }
28826
- ), /* @__PURE__ */ React102.createElement(Newline4, null))
28456
+ ), /* @__PURE__ */ React101.createElement(Newline4, null))
28827
28457
  );
28828
28458
  }
28829
28459
 
28830
28460
  // src/ui/components/SessionSelector.tsx
28831
- import React103 from "react";
28832
- import { Box as Box78, Text as Text82 } from "ink";
28461
+ import React102 from "react";
28462
+ import { Box as Box77, Text as Text81 } from "ink";
28833
28463
  function SessionSelector({
28834
28464
  sessions,
28835
28465
  onSelect
@@ -28857,18 +28487,18 @@ function SessionSelector({
28857
28487
  const truncated = labelTxt.length > columns - 2 ? `${labelTxt.slice(0, columns - 5)}...` : labelTxt;
28858
28488
  return { label: truncated, value: String(i) };
28859
28489
  });
28860
- return /* @__PURE__ */ React103.createElement(Box78, { flexDirection: "column", height: "100%", width: "100%" }, /* @__PURE__ */ React103.createElement(Box78, { paddingLeft: 9 }, /* @__PURE__ */ React103.createElement(Text82, { bold: true, color: getTheme().text }, "Modified"), /* @__PURE__ */ React103.createElement(Text82, null, " "), /* @__PURE__ */ React103.createElement(Text82, { bold: true, color: getTheme().text }, "Created"), /* @__PURE__ */ React103.createElement(Text82, null, " "), /* @__PURE__ */ React103.createElement(Text82, { bold: true, color: getTheme().text }, "Tag"), /* @__PURE__ */ React103.createElement(Text82, null, " "), /* @__PURE__ */ React103.createElement(Text82, { bold: true, color: getTheme().text }, "Session")), /* @__PURE__ */ React103.createElement(
28490
+ return /* @__PURE__ */ React102.createElement(Box77, { flexDirection: "column", height: "100%", width: "100%" }, /* @__PURE__ */ React102.createElement(Box77, { paddingLeft: 9 }, /* @__PURE__ */ React102.createElement(Text81, { bold: true, color: getTheme().text }, "Modified"), /* @__PURE__ */ React102.createElement(Text81, null, " "), /* @__PURE__ */ React102.createElement(Text81, { bold: true, color: getTheme().text }, "Created"), /* @__PURE__ */ React102.createElement(Text81, null, " "), /* @__PURE__ */ React102.createElement(Text81, { bold: true, color: getTheme().text }, "Tag"), /* @__PURE__ */ React102.createElement(Text81, null, " "), /* @__PURE__ */ React102.createElement(Text81, { bold: true, color: getTheme().text }, "Session")), /* @__PURE__ */ React102.createElement(
28861
28491
  Select,
28862
28492
  {
28863
28493
  options,
28864
28494
  onChange: (value) => onSelect(parseInt(value, 10)),
28865
28495
  visibleOptionCount: visibleCount
28866
28496
  }
28867
- ), hiddenCount > 0 && /* @__PURE__ */ React103.createElement(Box78, { paddingLeft: 2 }, /* @__PURE__ */ React103.createElement(Text82, { color: getTheme().secondaryText }, "and ", hiddenCount, " more\u2026")));
28497
+ ), hiddenCount > 0 && /* @__PURE__ */ React102.createElement(Box77, { paddingLeft: 2 }, /* @__PURE__ */ React102.createElement(Text81, { color: getTheme().secondaryText }, "and ", hiddenCount, " more\u2026")));
28868
28498
  }
28869
28499
 
28870
28500
  // src/ui/screens/ResumeConversation.tsx
28871
- import { randomUUID as randomUUID6 } from "crypto";
28501
+ import { randomUUID as randomUUID5 } from "crypto";
28872
28502
  function ResumeConversation({
28873
28503
  cwd,
28874
28504
  context,
@@ -28892,7 +28522,7 @@ function ResumeConversation({
28892
28522
  if (!selected) return;
28893
28523
  context.unmount?.();
28894
28524
  const resumedFromSessionId = selected.sessionId;
28895
- const effectiveSessionId = forkSession ? forkSessionId?.trim() || randomUUID6() : resumedFromSessionId;
28525
+ const effectiveSessionId = forkSession ? forkSessionId?.trim() || randomUUID5() : resumedFromSessionId;
28896
28526
  setPybAgentSessionId(effectiveSessionId);
28897
28527
  const messages = loadPybAgentSessionMessages({
28898
28528
  cwd,
@@ -28900,7 +28530,7 @@ function ResumeConversation({
28900
28530
  });
28901
28531
  const isDefaultModel = await isDefaultSlowAndCapableModel();
28902
28532
  render(
28903
- /* @__PURE__ */ React104.createElement(
28533
+ /* @__PURE__ */ React103.createElement(
28904
28534
  REPL,
28905
28535
  {
28906
28536
  commands,
@@ -28928,7 +28558,7 @@ function ResumeConversation({
28928
28558
  throw e;
28929
28559
  }
28930
28560
  }
28931
- return /* @__PURE__ */ React104.createElement(SessionSelector, { sessions, onSelect });
28561
+ return /* @__PURE__ */ React103.createElement(SessionSelector, { sessions, onSelect });
28932
28562
  }
28933
28563
 
28934
28564
  // src/commands/resume.tsx
@@ -28951,7 +28581,7 @@ var resume_default = {
28951
28581
  return null;
28952
28582
  }
28953
28583
  render2(
28954
- /* @__PURE__ */ React105.createElement(
28584
+ /* @__PURE__ */ React104.createElement(
28955
28585
  ResumeConversation,
28956
28586
  {
28957
28587
  cwd,
@@ -28968,11 +28598,11 @@ var resume_default = {
28968
28598
  };
28969
28599
 
28970
28600
  // src/commands/agents.tsx
28971
- import React107 from "react";
28601
+ import React106 from "react";
28972
28602
 
28973
28603
  // src/commands/agents/ui.tsx
28974
- import React106, { useCallback as useCallback17, useEffect as useEffect27, useMemo as useMemo27, useRef as useRef14, useState as useState29 } from "react";
28975
- import { Box as Box79, Text as Text83, useInput as useInput30 } from "ink";
28604
+ import React105, { useCallback as useCallback17, useEffect as useEffect27, useMemo as useMemo27, useRef as useRef14, useState as useState29 } from "react";
28605
+ import { Box as Box78, Text as Text82, useInput as useInput30 } from "ink";
28976
28606
  import figures9 from "figures";
28977
28607
  import chalk15 from "chalk";
28978
28608
  import { join as join13 } from "path";
@@ -29040,9 +28670,9 @@ import { join as join12 } from "path";
29040
28670
  import { homedir as homedir8 } from "os";
29041
28671
 
29042
28672
  // src/commands/agents/generation.ts
29043
- import { randomUUID as randomUUID7 } from "crypto";
28673
+ import { randomUUID as randomUUID6 } from "crypto";
29044
28674
  async function generateAgentWithClaude(prompt) {
29045
- const { queryModel } = await import("./llm-5RBAGTX5.js");
28675
+ const { queryModel } = await import("./llm-VY6RXJY7.js");
29046
28676
  const systemPrompt = `You are an expert at creating AI agent configurations. Based on the user's description, generate a specialized agent configuration.
29047
28677
 
29048
28678
  Return your response as a JSON object with exactly these fields:
@@ -29055,7 +28685,7 @@ Make the agent highly specialized and effective for the described use case.`;
29055
28685
  const messages = [
29056
28686
  {
29057
28687
  type: "user",
29058
- uuid: randomUUID7(),
28688
+ uuid: randomUUID6(),
29059
28689
  message: { role: "user", content: prompt }
29060
28690
  }
29061
28691
  ];
@@ -29424,21 +29054,21 @@ function panelBorderColor(kind) {
29424
29054
  }
29425
29055
  function Panel(props) {
29426
29056
  const theme = getTheme();
29427
- return /* @__PURE__ */ React106.createElement(
29428
- Box79,
29057
+ return /* @__PURE__ */ React105.createElement(
29058
+ Box78,
29429
29059
  {
29430
29060
  borderStyle: "round",
29431
29061
  borderColor: props.borderColor ?? theme.suggestion,
29432
29062
  flexDirection: "column"
29433
29063
  },
29434
- /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", paddingX: 1 }, /* @__PURE__ */ React106.createElement(Text83, { bold: true, color: props.titleColor ?? theme.text }, props.title), props.subtitle ? /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, props.subtitle) : null),
29435
- /* @__PURE__ */ React106.createElement(Box79, { paddingX: 1, flexDirection: "column" }, props.children)
29064
+ /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", paddingX: 1 }, /* @__PURE__ */ React105.createElement(Text82, { bold: true, color: props.titleColor ?? theme.text }, props.title), props.subtitle ? /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, props.subtitle) : null),
29065
+ /* @__PURE__ */ React105.createElement(Box78, { paddingX: 1, flexDirection: "column" }, props.children)
29436
29066
  );
29437
29067
  }
29438
29068
  function Instructions({
29439
29069
  instructions = "Press \u2191\u2193 to navigate \xB7 Enter to select \xB7 Esc to go back"
29440
29070
  }) {
29441
- return /* @__PURE__ */ React106.createElement(Box79, { marginLeft: 3 }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, instructions));
29071
+ return /* @__PURE__ */ React105.createElement(Box78, { marginLeft: 3 }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, instructions));
29442
29072
  }
29443
29073
  function computeOverrides(args) {
29444
29074
  const activeByType = /* @__PURE__ */ new Map();
@@ -29517,38 +29147,38 @@ function AgentsListView(props) {
29517
29147
  setSelectedAgent(nextAgent);
29518
29148
  }
29519
29149
  });
29520
- const renderCreateNew = () => /* @__PURE__ */ React106.createElement(Box79, null, /* @__PURE__ */ React106.createElement(Text83, { color: onCreateOption ? theme.suggestion : void 0 }, onCreateOption ? `${figures9.pointer} ` : " "), /* @__PURE__ */ React106.createElement(Text83, { color: onCreateOption ? theme.suggestion : void 0 }, "Create new agent"));
29150
+ const renderCreateNew = () => /* @__PURE__ */ React105.createElement(Box78, null, /* @__PURE__ */ React105.createElement(Text82, { color: onCreateOption ? theme.suggestion : void 0 }, onCreateOption ? `${figures9.pointer} ` : " "), /* @__PURE__ */ React105.createElement(Text82, { color: onCreateOption ? theme.suggestion : void 0 }, "Create new agent"));
29521
29151
  const renderAgentRow = (agent) => {
29522
29152
  const isBuiltIn = agent.source === "built-in";
29523
29153
  const isSelected = !isBuiltIn && !onCreateOption && selectedAgent?.agentType === agent.agentType && selectedAgent?.source === agent.source;
29524
29154
  const dimmed = Boolean(isBuiltIn || agent.overriddenBy);
29525
29155
  const rowColor = isSelected ? theme.suggestion : void 0;
29526
29156
  const pointer = isBuiltIn ? "" : isSelected ? `${figures9.pointer} ` : " ";
29527
- return /* @__PURE__ */ React106.createElement(Box79, { key: `${agent.agentType}-${agent.source}`, flexDirection: "row" }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: dimmed && !isSelected, color: rowColor }, pointer), /* @__PURE__ */ React106.createElement(Text83, { dimColor: dimmed && !isSelected, color: rowColor }, agent.agentType), /* @__PURE__ */ React106.createElement(Text83, { dimColor: true, color: rowColor }, " \xB7 ", formatModelShort(agent.model)), agent.overriddenBy ? /* @__PURE__ */ React106.createElement(Text83, { dimColor: !isSelected, color: isSelected ? theme.warning : void 0 }, " ", figures9.warning, " overridden by ", agent.overriddenBy) : null);
29157
+ return /* @__PURE__ */ React105.createElement(Box78, { key: `${agent.agentType}-${agent.source}`, flexDirection: "row" }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: dimmed && !isSelected, color: rowColor }, pointer), /* @__PURE__ */ React105.createElement(Text82, { dimColor: dimmed && !isSelected, color: rowColor }, agent.agentType), /* @__PURE__ */ React105.createElement(Text82, { dimColor: true, color: rowColor }, " \xB7 ", formatModelShort(agent.model)), agent.overriddenBy ? /* @__PURE__ */ React105.createElement(Text82, { dimColor: !isSelected, color: isSelected ? theme.warning : void 0 }, " ", figures9.warning, " overridden by ", agent.overriddenBy) : null);
29528
29158
  };
29529
29159
  const group = (label, agents) => {
29530
29160
  if (agents.length === 0) return null;
29531
29161
  const baseDir = agents[0]?.baseDir;
29532
- return /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginBottom: 1 }, /* @__PURE__ */ React106.createElement(Box79, { paddingLeft: 2 }, /* @__PURE__ */ React106.createElement(Text83, { bold: true, dimColor: true }, label), baseDir ? /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, " ", "(", baseDir, ")") : null), agents.map(renderAgentRow));
29162
+ return /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginBottom: 1 }, /* @__PURE__ */ React105.createElement(Box78, { paddingLeft: 2 }, /* @__PURE__ */ React105.createElement(Text82, { bold: true, dimColor: true }, label), baseDir ? /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, " ", "(", baseDir, ")") : null), agents.map(renderAgentRow));
29533
29163
  };
29534
29164
  const builtInSection = (label = "Built-in (always available):") => {
29535
29165
  const builtIn = props.agents.filter((a) => a.source === "built-in");
29536
29166
  if (builtIn.length === 0) return null;
29537
- return /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginBottom: 1, paddingLeft: 2 }, /* @__PURE__ */ React106.createElement(Text83, { bold: true, dimColor: true }, label), builtIn.map(renderAgentRow));
29167
+ return /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginBottom: 1, paddingLeft: 2 }, /* @__PURE__ */ React105.createElement(Text82, { bold: true, dimColor: true }, label), builtIn.map(renderAgentRow));
29538
29168
  };
29539
29169
  const notOverriddenCount = props.agents.filter((a) => !a.overriddenBy).length;
29540
29170
  const title = titleForSource(props.source);
29541
29171
  if (props.agents.length === 0 || props.source !== "built-in" && !props.agents.some((a) => a.source !== "built-in")) {
29542
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Panel, { title, subtitle: "No agents found" }, props.onCreateNew ? /* @__PURE__ */ React106.createElement(Box79, { marginY: 1 }, renderCreateNew()) : null, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "No agents found. Create specialized subagents that Claude can delegate to."), /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "Each subagent has its own context window, custom system prompt, and specific tools."), /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "Try creating: Code Reviewer, Code Simplifier, Security Reviewer, Tech Lead, or UX Reviewer."), props.source !== "built-in" && props.agents.some((a) => a.source === "built-in") ? /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "\u2500".repeat(40))), builtInSection()) : null), /* @__PURE__ */ React106.createElement(Instructions, null));
29172
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Panel, { title, subtitle: "No agents found" }, props.onCreateNew ? /* @__PURE__ */ React105.createElement(Box78, { marginY: 1 }, renderCreateNew()) : null, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "No agents found. Create specialized subagents that Claude can delegate to."), /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "Each subagent has its own context window, custom system prompt, and specific tools."), /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "Try creating: Code Reviewer, Code Simplifier, Security Reviewer, Tech Lead, or UX Reviewer."), props.source !== "built-in" && props.agents.some((a) => a.source === "built-in") ? /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "\u2500".repeat(40))), builtInSection()) : null), /* @__PURE__ */ React105.createElement(Instructions, null));
29543
29173
  }
29544
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(
29174
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(
29545
29175
  Panel,
29546
29176
  {
29547
29177
  title,
29548
29178
  subtitle: `${notOverriddenCount} agents`
29549
29179
  },
29550
- props.changes.length > 0 ? /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, props.changes[props.changes.length - 1])) : null,
29551
- /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginTop: 1 }, props.onCreateNew ? /* @__PURE__ */ React106.createElement(Box79, { marginBottom: 1 }, renderCreateNew()) : null, props.source === "all" ? /* @__PURE__ */ React106.createElement(React106.Fragment, null, group(
29180
+ props.changes.length > 0 ? /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, props.changes[props.changes.length - 1])) : null,
29181
+ /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginTop: 1 }, props.onCreateNew ? /* @__PURE__ */ React105.createElement(Box78, { marginBottom: 1 }, renderCreateNew()) : null, props.source === "all" ? /* @__PURE__ */ React105.createElement(React105.Fragment, null, group(
29552
29182
  "User agents",
29553
29183
  props.agents.filter((a) => a.source === "userSettings")
29554
29184
  ), group(
@@ -29563,8 +29193,8 @@ function AgentsListView(props) {
29563
29193
  ), group(
29564
29194
  "CLI arg agents",
29565
29195
  props.agents.filter((a) => a.source === "flagSettings")
29566
- ), builtInSection("Built-in agents (always available)")) : props.source === "built-in" ? /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true, italic: true }, "Built-in agents are provided by default and cannot be modified."), /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1, flexDirection: "column" }, props.agents.map(renderAgentRow))) : /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column" }, props.agents.filter((a) => a.source !== "built-in").map(renderAgentRow)))
29567
- ), /* @__PURE__ */ React106.createElement(Instructions, null));
29196
+ ), builtInSection("Built-in agents (always available)")) : props.source === "built-in" ? /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true, italic: true }, "Built-in agents are provided by default and cannot be modified."), /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1, flexDirection: "column" }, props.agents.map(renderAgentRow))) : /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column" }, props.agents.filter((a) => a.source !== "built-in").map(renderAgentRow)))
29197
+ ), /* @__PURE__ */ React105.createElement(Instructions, null));
29568
29198
  }
29569
29199
  function wizardLocationToStorageLocation(location) {
29570
29200
  return location === "projectSettings" ? "project" : "user";
@@ -29655,16 +29285,16 @@ function Wizard(props) {
29655
29285
  cancel
29656
29286
  ]
29657
29287
  );
29658
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, props.steps[stepIndex]?.(ctx) ?? null);
29288
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, props.steps[stepIndex]?.(ctx) ?? null);
29659
29289
  }
29660
29290
  function WizardPanel(props) {
29661
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Panel, { title: "Create new agent", subtitle: props.subtitle }, props.children), /* @__PURE__ */ React106.createElement(Instructions, { instructions: props.footerText }));
29291
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Panel, { title: "Create new agent", subtitle: props.subtitle }, props.children), /* @__PURE__ */ React105.createElement(Instructions, { instructions: props.footerText }));
29662
29292
  }
29663
29293
  function StepChooseLocation({ ctx }) {
29664
29294
  useInput30((_input, key) => {
29665
29295
  if (key.escape) ctx.cancel();
29666
29296
  });
29667
- return /* @__PURE__ */ React106.createElement(WizardPanel, { subtitle: "Choose location", footerText: "Press \u2191\u2193 to navigate \xB7 Enter to select \xB7 Esc to cancel" }, /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(
29297
+ return /* @__PURE__ */ React105.createElement(WizardPanel, { subtitle: "Choose location", footerText: "Press \u2191\u2193 to navigate \xB7 Enter to select \xB7 Esc to cancel" }, /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(
29668
29298
  Select,
29669
29299
  {
29670
29300
  options: [
@@ -29683,7 +29313,7 @@ function StepChooseMethod({ ctx }) {
29683
29313
  useInput30((_input, key) => {
29684
29314
  if (key.escape) ctx.goBack();
29685
29315
  });
29686
- return /* @__PURE__ */ React106.createElement(WizardPanel, { subtitle: "Creation method" }, /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(
29316
+ return /* @__PURE__ */ React105.createElement(WizardPanel, { subtitle: "Creation method" }, /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(
29687
29317
  Select,
29688
29318
  {
29689
29319
  options: [
@@ -29767,7 +29397,7 @@ function StepGenerationPrompt(props) {
29767
29397
  abortRef.current = null;
29768
29398
  }
29769
29399
  };
29770
- return /* @__PURE__ */ React106.createElement(WizardPanel, { subtitle: "Describe the agent you want" }, /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React106.createElement(Text83, null, "What should this agent do?"), /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "Describe a role like \u201Ccode reviewer\u201D, \u201Csecurity auditor\u201D, or \u201Ctech lead\u201D."), /* @__PURE__ */ React106.createElement(
29400
+ return /* @__PURE__ */ React105.createElement(WizardPanel, { subtitle: "Describe the agent you want" }, /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React105.createElement(Text82, null, "What should this agent do?"), /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "Describe a role like \u201Ccode reviewer\u201D, \u201Csecurity auditor\u201D, or \u201Ctech lead\u201D."), /* @__PURE__ */ React105.createElement(
29771
29401
  TextInput,
29772
29402
  {
29773
29403
  value,
@@ -29778,7 +29408,7 @@ function StepGenerationPrompt(props) {
29778
29408
  cursorOffset,
29779
29409
  onChangeCursorOffset: setCursorOffset
29780
29410
  }
29781
- ), error ? /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, error) : null, isGenerating ? /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "Generating\u2026") : null));
29411
+ ), error ? /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, error) : null, isGenerating ? /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "Generating\u2026") : null));
29782
29412
  }
29783
29413
  function themeColor(kind) {
29784
29414
  const theme = getTheme();
@@ -29814,13 +29444,13 @@ function StepAgentType(props) {
29814
29444
  ctx.updateWizardData({ agentType: trimmed });
29815
29445
  ctx.goNext();
29816
29446
  };
29817
- return /* @__PURE__ */ React106.createElement(
29447
+ return /* @__PURE__ */ React105.createElement(
29818
29448
  WizardPanel,
29819
29449
  {
29820
29450
  subtitle: "Agent type (identifier)",
29821
29451
  footerText: "Press Enter to continue \xB7 Esc to go back"
29822
29452
  },
29823
- /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React106.createElement(Text83, null, "Enter a unique identifier for your agent:"), /* @__PURE__ */ React106.createElement(
29453
+ /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React105.createElement(Text82, null, "Enter a unique identifier for your agent:"), /* @__PURE__ */ React105.createElement(
29824
29454
  TextInput,
29825
29455
  {
29826
29456
  value,
@@ -29830,7 +29460,7 @@ function StepAgentType(props) {
29830
29460
  cursorOffset,
29831
29461
  onChangeCursorOffset: setCursorOffset
29832
29462
  }
29833
- ), /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "e.g., code-reviewer, tech-lead, etc"), error ? /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, error) : null)
29463
+ ), /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "e.g., code-reviewer, tech-lead, etc"), error ? /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, error) : null)
29834
29464
  );
29835
29465
  }
29836
29466
  function StepSystemPrompt({ ctx }) {
@@ -29851,13 +29481,13 @@ function StepSystemPrompt({ ctx }) {
29851
29481
  ctx.updateWizardData({ systemPrompt: trimmed });
29852
29482
  ctx.goNext();
29853
29483
  };
29854
- return /* @__PURE__ */ React106.createElement(
29484
+ return /* @__PURE__ */ React105.createElement(
29855
29485
  WizardPanel,
29856
29486
  {
29857
29487
  subtitle: "System prompt",
29858
29488
  footerText: "Press Enter to continue \xB7 Esc to go back"
29859
29489
  },
29860
- /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React106.createElement(Text83, null, "Enter the system prompt for your agent:"), /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "Be comprehensive for best results"), /* @__PURE__ */ React106.createElement(
29490
+ /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React105.createElement(Text82, null, "Enter the system prompt for your agent:"), /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "Be comprehensive for best results"), /* @__PURE__ */ React105.createElement(
29861
29491
  TextInput,
29862
29492
  {
29863
29493
  value,
@@ -29868,7 +29498,7 @@ function StepSystemPrompt({ ctx }) {
29868
29498
  cursorOffset,
29869
29499
  onChangeCursorOffset: setCursorOffset
29870
29500
  }
29871
- ), error ? /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, error) : null)
29501
+ ), error ? /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, error) : null)
29872
29502
  );
29873
29503
  }
29874
29504
  function StepDescription({ ctx }) {
@@ -29889,13 +29519,13 @@ function StepDescription({ ctx }) {
29889
29519
  ctx.updateWizardData({ whenToUse: trimmed });
29890
29520
  ctx.goNext();
29891
29521
  };
29892
- return /* @__PURE__ */ React106.createElement(
29522
+ return /* @__PURE__ */ React105.createElement(
29893
29523
  WizardPanel,
29894
29524
  {
29895
29525
  subtitle: "Description (tell Claude when to use this agent)",
29896
29526
  footerText: "Press Enter to continue \xB7 Esc to go back"
29897
29527
  },
29898
- /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React106.createElement(Text83, null, "When should Claude use this agent?"), /* @__PURE__ */ React106.createElement(
29528
+ /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React105.createElement(Text82, null, "When should Claude use this agent?"), /* @__PURE__ */ React105.createElement(
29899
29529
  TextInput,
29900
29530
  {
29901
29531
  value,
@@ -29906,7 +29536,7 @@ function StepDescription({ ctx }) {
29906
29536
  cursorOffset,
29907
29537
  onChangeCursorOffset: setCursorOffset
29908
29538
  }
29909
- ), error ? /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, error) : null)
29539
+ ), error ? /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, error) : null)
29910
29540
  );
29911
29541
  }
29912
29542
  function ToolPicker(props) {
@@ -30065,12 +29695,12 @@ function ToolPicker(props) {
30065
29695
  return;
30066
29696
  }
30067
29697
  });
30068
- return /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, { color: cursorIndex === 0 ? themeColor("suggestion") : void 0, bold: cursorIndex === 0 }, cursorIndex === 0 ? `${figures9.pointer} ` : " ", "[ Continue ]"), /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "\u2500".repeat(40)), items.slice(1).map((item, idx) => {
29698
+ return /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, { color: cursorIndex === 0 ? themeColor("suggestion") : void 0, bold: cursorIndex === 0 }, cursorIndex === 0 ? `${figures9.pointer} ` : " ", "[ Continue ]"), /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "\u2500".repeat(40)), items.slice(1).map((item, idx) => {
30069
29699
  const index = idx + 1;
30070
29700
  const focused = index === cursorIndex;
30071
29701
  const prefix = item.isHeader ? "" : focused ? `${figures9.pointer} ` : " ";
30072
- return /* @__PURE__ */ React106.createElement(React106.Fragment, { key: item.id }, item.isToggle ? /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "\u2500".repeat(40)) : null, /* @__PURE__ */ React106.createElement(
30073
- Text83,
29702
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, { key: item.id }, item.isToggle ? /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "\u2500".repeat(40)) : null, /* @__PURE__ */ React105.createElement(
29703
+ Text82,
30074
29704
  {
30075
29705
  dimColor: item.isHeader,
30076
29706
  color: !item.isHeader && focused ? themeColor("suggestion") : void 0,
@@ -30078,12 +29708,12 @@ function ToolPicker(props) {
30078
29708
  },
30079
29709
  item.isToggle ? `${prefix}[ ${item.label} ]` : `${prefix}${item.label}`
30080
29710
  ));
30081
- }), /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, isAllSelected ? "All tools selected" : `${selectedSet.size} of ${allToolNames.length} tools selected`)));
29711
+ }), /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, isAllSelected ? "All tools selected" : `${selectedSet.size} of ${allToolNames.length} tools selected`)));
30082
29712
  }
30083
29713
  function StepSelectTools(props) {
30084
29714
  const { ctx } = props;
30085
29715
  const initialTools = ctx.wizardData.selectedTools;
30086
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Panel, { title: "Create new agent", subtitle: "Select tools" }, /* @__PURE__ */ React106.createElement(
29716
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Panel, { title: "Create new agent", subtitle: "Select tools" }, /* @__PURE__ */ React105.createElement(
30087
29717
  ToolPicker,
30088
29718
  {
30089
29719
  tools: props.tools,
@@ -30094,7 +29724,7 @@ function StepSelectTools(props) {
30094
29724
  },
30095
29725
  onCancel: ctx.goBack
30096
29726
  }
30097
- )), /* @__PURE__ */ React106.createElement(Instructions, { instructions: "Press Enter to toggle selection \xB7 \u2191\u2193 Navigate \xB7 Esc to go back" }));
29727
+ )), /* @__PURE__ */ React105.createElement(Instructions, { instructions: "Press Enter to toggle selection \xB7 \u2191\u2193 Navigate \xB7 Esc to go back" }));
30098
29728
  }
30099
29729
  function StepSelectModel({ ctx }) {
30100
29730
  useInput30((_input, key) => {
@@ -30102,7 +29732,7 @@ function StepSelectModel({ ctx }) {
30102
29732
  });
30103
29733
  const options = modelOptions();
30104
29734
  const defaultValue = ctx.wizardData.selectedModel ?? DEFAULT_AGENT_MODEL;
30105
- return /* @__PURE__ */ React106.createElement(WizardPanel, { subtitle: "Select model", footerText: "Press \u2191\u2193 to navigate \xB7 Enter to select \xB7 Esc to go back" }, /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "Model determines the agent's reasoning capabilities and speed."), /* @__PURE__ */ React106.createElement(
29735
+ return /* @__PURE__ */ React105.createElement(WizardPanel, { subtitle: "Select model", footerText: "Press \u2191\u2193 to navigate \xB7 Enter to select \xB7 Esc to go back" }, /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "Model determines the agent's reasoning capabilities and speed."), /* @__PURE__ */ React105.createElement(
30106
29736
  Select,
30107
29737
  {
30108
29738
  options,
@@ -30123,12 +29753,12 @@ function ColorPicker(props) {
30123
29753
  else if (key.downArrow) setIndex((i) => i < COLOR_OPTIONS.length - 1 ? i + 1 : 0);
30124
29754
  else if (key.return) props.onConfirm(COLOR_OPTIONS[index] ?? "automatic");
30125
29755
  });
30126
- return /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", gap: 1 }, COLOR_OPTIONS.map((color, i) => {
29756
+ return /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", gap: 1 }, COLOR_OPTIONS.map((color, i) => {
30127
29757
  const focused = i === index;
30128
29758
  const prefix = focused ? figures9.pointer : " ";
30129
29759
  const label = color === "automatic" ? "Automatic color" : color.charAt(0).toUpperCase() + color.slice(1);
30130
- return /* @__PURE__ */ React106.createElement(React106.Fragment, { key: color }, /* @__PURE__ */ React106.createElement(
30131
- Text83,
29760
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, { key: color }, /* @__PURE__ */ React105.createElement(
29761
+ Text82,
30132
29762
  {
30133
29763
  color: focused ? themeColor("suggestion") : void 0,
30134
29764
  bold: focused
@@ -30161,7 +29791,7 @@ function StepChooseColor({ ctx }) {
30161
29791
  });
30162
29792
  ctx.goNext();
30163
29793
  };
30164
- return /* @__PURE__ */ React106.createElement(WizardPanel, { subtitle: "Choose background color", footerText: "Press \u2191\u2193 to navigate \xB7 Enter to select \xB7 Esc to go back" }, /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(ColorPicker, { agentName: agentType, currentColor: "automatic", onConfirm })));
29794
+ return /* @__PURE__ */ React105.createElement(WizardPanel, { subtitle: "Choose background color", footerText: "Press \u2191\u2193 to navigate \xB7 Enter to select \xB7 Esc to go back" }, /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(ColorPicker, { agentName: agentType, currentColor: "automatic", onConfirm })));
30165
29795
  }
30166
29796
  function validateFinalAgent(args) {
30167
29797
  const errors = [];
@@ -30226,28 +29856,28 @@ function StepConfirm(props) {
30226
29856
  });
30227
29857
  const locationPath = finalAgent.source === "projectSettings" ? getPrimaryAgentFilePath("project", finalAgent.agentType) : getPrimaryAgentFilePath("user", finalAgent.agentType);
30228
29858
  const truncate = (text) => text.length > 240 ? `${text.slice(0, 240)}\u2026` : text;
30229
- return /* @__PURE__ */ React106.createElement(
29859
+ return /* @__PURE__ */ React105.createElement(
30230
29860
  WizardPanel,
30231
29861
  {
30232
29862
  subtitle: "Confirm and save",
30233
29863
  footerText: "Press s/Enter to save \xB7 e to edit in your editor \xB7 Esc to cancel"
30234
29864
  },
30235
- /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "Name"), ": ", finalAgent.agentType), /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "Location"), ": ", locationPath), /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "Tools"), ": ", toolSummary(finalAgent.tools)), /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "Model"), ": ", formatModelLong(finalAgent.model)), /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "Description"), " (tells Claude when to use this agent):"), /* @__PURE__ */ React106.createElement(Box79, { marginLeft: 2, marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, null, truncate(finalAgent.whenToUse)))), /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "System prompt"), ":"), /* @__PURE__ */ React106.createElement(Box79, { marginLeft: 2, marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, null, truncate(finalAgent.systemPrompt)))), validation.warnings.length > 0 ? /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("warning") }, "Warnings:"), validation.warnings.map((w, i) => /* @__PURE__ */ React106.createElement(React106.Fragment, { key: i }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, " ", "\u2022 ", w)))) : null, validation.errors.length > 0 ? /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, "Errors:"), validation.errors.map((e, i) => /* @__PURE__ */ React106.createElement(React106.Fragment, { key: i }, /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, " ", "\u2022 ", e)))) : null, error ? /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, error)) : null)
29865
+ /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginTop: 1, gap: 1 }, /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "Name"), ": ", finalAgent.agentType), /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "Location"), ": ", locationPath), /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "Tools"), ": ", toolSummary(finalAgent.tools)), /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "Model"), ": ", formatModelLong(finalAgent.model)), /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "Description"), " (tells Claude when to use this agent):"), /* @__PURE__ */ React105.createElement(Box78, { marginLeft: 2, marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, null, truncate(finalAgent.whenToUse)))), /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "System prompt"), ":"), /* @__PURE__ */ React105.createElement(Box78, { marginLeft: 2, marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, null, truncate(finalAgent.systemPrompt)))), validation.warnings.length > 0 ? /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("warning") }, "Warnings:"), validation.warnings.map((w, i) => /* @__PURE__ */ React105.createElement(React105.Fragment, { key: i }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, " ", "\u2022 ", w)))) : null, validation.errors.length > 0 ? /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1, flexDirection: "column" }, /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, "Errors:"), validation.errors.map((e, i) => /* @__PURE__ */ React105.createElement(React105.Fragment, { key: i }, /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, " ", "\u2022 ", e)))) : null, error ? /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, error)) : null)
30236
29866
  );
30237
29867
  }
30238
29868
  function CreateAgentWizard(props) {
30239
29869
  const steps = useMemo27(() => {
30240
29870
  return [
30241
- (ctx) => /* @__PURE__ */ React106.createElement(StepChooseLocation, { ctx }),
30242
- (ctx) => /* @__PURE__ */ React106.createElement(StepChooseMethod, { ctx }),
30243
- (ctx) => /* @__PURE__ */ React106.createElement(StepGenerationPrompt, { ctx, existingAgents: props.existingAgents }),
30244
- (ctx) => /* @__PURE__ */ React106.createElement(StepAgentType, { ctx, existingAgents: props.existingAgents }),
30245
- (ctx) => /* @__PURE__ */ React106.createElement(StepSystemPrompt, { ctx }),
30246
- (ctx) => /* @__PURE__ */ React106.createElement(StepDescription, { ctx }),
30247
- (ctx) => /* @__PURE__ */ React106.createElement(StepSelectTools, { ctx, tools: props.tools }),
30248
- (ctx) => /* @__PURE__ */ React106.createElement(StepSelectModel, { ctx }),
30249
- (ctx) => /* @__PURE__ */ React106.createElement(StepChooseColor, { ctx }),
30250
- (ctx) => /* @__PURE__ */ React106.createElement(
29871
+ (ctx) => /* @__PURE__ */ React105.createElement(StepChooseLocation, { ctx }),
29872
+ (ctx) => /* @__PURE__ */ React105.createElement(StepChooseMethod, { ctx }),
29873
+ (ctx) => /* @__PURE__ */ React105.createElement(StepGenerationPrompt, { ctx, existingAgents: props.existingAgents }),
29874
+ (ctx) => /* @__PURE__ */ React105.createElement(StepAgentType, { ctx, existingAgents: props.existingAgents }),
29875
+ (ctx) => /* @__PURE__ */ React105.createElement(StepSystemPrompt, { ctx }),
29876
+ (ctx) => /* @__PURE__ */ React105.createElement(StepDescription, { ctx }),
29877
+ (ctx) => /* @__PURE__ */ React105.createElement(StepSelectTools, { ctx, tools: props.tools }),
29878
+ (ctx) => /* @__PURE__ */ React105.createElement(StepSelectModel, { ctx }),
29879
+ (ctx) => /* @__PURE__ */ React105.createElement(StepChooseColor, { ctx }),
29880
+ (ctx) => /* @__PURE__ */ React105.createElement(
30251
29881
  StepConfirm,
30252
29882
  {
30253
29883
  ctx,
@@ -30280,7 +29910,7 @@ function CreateAgentWizard(props) {
30280
29910
  )
30281
29911
  ];
30282
29912
  }, [props]);
30283
- return /* @__PURE__ */ React106.createElement(
29913
+ return /* @__PURE__ */ React105.createElement(
30284
29914
  Wizard,
30285
29915
  {
30286
29916
  steps,
@@ -30303,13 +29933,13 @@ function AgentMenu(props) {
30303
29933
  ],
30304
29934
  { label: "Back", value: "back" }
30305
29935
  ];
30306
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Panel, { title: props.agent.agentType }, /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React106.createElement(
29936
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Panel, { title: props.agent.agentType }, /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", marginTop: 1 }, /* @__PURE__ */ React105.createElement(
30307
29937
  Select,
30308
29938
  {
30309
29939
  options,
30310
29940
  onChange: (value) => props.onChoose(value)
30311
29941
  }
30312
- ))), /* @__PURE__ */ React106.createElement(Instructions, null));
29942
+ ))), /* @__PURE__ */ React105.createElement(Instructions, null));
30313
29943
  }
30314
29944
  function ViewAgent(props) {
30315
29945
  useInput30((_input, key) => {
@@ -30345,9 +29975,9 @@ function ViewAgent(props) {
30345
29975
  const toolsSummary = () => {
30346
29976
  if (parsedTools.hasWildcard) return "All tools";
30347
29977
  if (!props.agent.tools || props.agent.tools === "*" || props.agent.tools.length === 0) return "None";
30348
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, parsedTools.valid.length > 0 ? parsedTools.valid.join(", ") : null, parsedTools.invalid.length > 0 ? /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("warning") }, " ", figures9.warning, " Unrecognized: ", parsedTools.invalid.join(", "))) : null);
29978
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, parsedTools.valid.length > 0 ? parsedTools.valid.join(", ") : null, parsedTools.invalid.length > 0 ? /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("warning") }, " ", figures9.warning, " Unrecognized: ", parsedTools.invalid.join(", "))) : null);
30349
29979
  };
30350
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Panel, { title: props.agent.agentType }, /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", gap: 1 }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, sourceLine), /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column" }, /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "Description"), " (tells Claude when to use this agent):"), /* @__PURE__ */ React106.createElement(Box79, { marginLeft: 2 }, /* @__PURE__ */ React106.createElement(Text83, null, props.agent.whenToUse))), /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "Tools"), ": ", toolsSummary()), /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "Model"), ": ", formatModelLong(props.agent.model)), props.agent.color ? /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "Color"), ": ", props.agent.color) : null, props.agent.systemPrompt ? /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Text83, null, /* @__PURE__ */ React106.createElement(Text83, { bold: true }, "System prompt"), ":"), /* @__PURE__ */ React106.createElement(Box79, { marginLeft: 2, marginRight: 2 }, /* @__PURE__ */ React106.createElement(Text83, null, props.agent.systemPrompt))) : null)), /* @__PURE__ */ React106.createElement(Instructions, { instructions: "Press Enter or Esc to go back" }));
29980
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Panel, { title: props.agent.agentType }, /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", gap: 1 }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, sourceLine), /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column" }, /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "Description"), " (tells Claude when to use this agent):"), /* @__PURE__ */ React105.createElement(Box78, { marginLeft: 2 }, /* @__PURE__ */ React105.createElement(Text82, null, props.agent.whenToUse))), /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "Tools"), ": ", toolsSummary()), /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "Model"), ": ", formatModelLong(props.agent.model)), props.agent.color ? /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "Color"), ": ", props.agent.color) : null, props.agent.systemPrompt ? /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Text82, null, /* @__PURE__ */ React105.createElement(Text82, { bold: true }, "System prompt"), ":"), /* @__PURE__ */ React105.createElement(Box78, { marginLeft: 2, marginRight: 2 }, /* @__PURE__ */ React105.createElement(Text82, null, props.agent.systemPrompt))) : null)), /* @__PURE__ */ React105.createElement(Instructions, { instructions: "Press Enter or Esc to go back" }));
30351
29981
  }
30352
29982
  function EditAgent(props) {
30353
29983
  const [mode, setMode] = useState29("menu");
@@ -30412,7 +30042,7 @@ function EditAgent(props) {
30412
30042
  }
30413
30043
  });
30414
30044
  if (mode === "edit-tools") {
30415
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Panel, { title: `Edit agent: ${props.agent.agentType}` }, /* @__PURE__ */ React106.createElement(
30045
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Panel, { title: `Edit agent: ${props.agent.agentType}` }, /* @__PURE__ */ React105.createElement(
30416
30046
  ToolPicker,
30417
30047
  {
30418
30048
  tools: props.tools,
@@ -30424,10 +30054,10 @@ function EditAgent(props) {
30424
30054
  },
30425
30055
  onCancel: () => setMode("menu")
30426
30056
  }
30427
- ), error ? /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, error)) : null), /* @__PURE__ */ React106.createElement(Instructions, { instructions: "Press Enter to toggle selection \xB7 \u2191\u2193 Navigate \xB7 Esc to go back" }));
30057
+ ), error ? /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, error)) : null), /* @__PURE__ */ React105.createElement(Instructions, { instructions: "Press Enter to toggle selection \xB7 \u2191\u2193 Navigate \xB7 Esc to go back" }));
30428
30058
  }
30429
30059
  if (mode === "edit-model") {
30430
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Panel, { title: `Edit agent: ${props.agent.agentType}` }, /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", gap: 1, marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "Model determines the agent's reasoning capabilities and speed."), /* @__PURE__ */ React106.createElement(
30060
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Panel, { title: `Edit agent: ${props.agent.agentType}` }, /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", gap: 1, marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "Model determines the agent's reasoning capabilities and speed."), /* @__PURE__ */ React105.createElement(
30431
30061
  Select,
30432
30062
  {
30433
30063
  options: modelOptions(),
@@ -30437,10 +30067,10 @@ function EditAgent(props) {
30437
30067
  setMode("menu");
30438
30068
  }
30439
30069
  }
30440
- )), error ? /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, error)) : null), /* @__PURE__ */ React106.createElement(Instructions, null));
30070
+ )), error ? /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, error)) : null), /* @__PURE__ */ React105.createElement(Instructions, null));
30441
30071
  }
30442
30072
  if (mode === "edit-color") {
30443
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Panel, { title: `Edit agent: ${props.agent.agentType}` }, /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(
30073
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Panel, { title: `Edit agent: ${props.agent.agentType}` }, /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(
30444
30074
  ColorPicker,
30445
30075
  {
30446
30076
  agentName: props.agent.agentType,
@@ -30450,29 +30080,29 @@ function EditAgent(props) {
30450
30080
  setMode("menu");
30451
30081
  }
30452
30082
  }
30453
- )), error ? /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, error)) : null), /* @__PURE__ */ React106.createElement(Instructions, null));
30083
+ )), error ? /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, error)) : null), /* @__PURE__ */ React105.createElement(Instructions, null));
30454
30084
  }
30455
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Panel, { title: `Edit agent: ${props.agent.agentType}` }, /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column" }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "Source: ", titleForSource(props.agent.source)), /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1, flexDirection: "column" }, menuItems.map((item, idx) => /* @__PURE__ */ React106.createElement(React106.Fragment, { key: item.label }, /* @__PURE__ */ React106.createElement(
30456
- Text83,
30085
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Panel, { title: `Edit agent: ${props.agent.agentType}` }, /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column" }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "Source: ", titleForSource(props.agent.source)), /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1, flexDirection: "column" }, menuItems.map((item, idx) => /* @__PURE__ */ React105.createElement(React105.Fragment, { key: item.label }, /* @__PURE__ */ React105.createElement(
30086
+ Text82,
30457
30087
  {
30458
30088
  color: idx === selectedIndex ? themeColor("suggestion") : void 0
30459
30089
  },
30460
30090
  idx === selectedIndex ? `${figures9.pointer} ` : " ",
30461
30091
  item.label
30462
- )))), error ? /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, { color: themeColor("error") }, error)) : null)), /* @__PURE__ */ React106.createElement(Instructions, null));
30092
+ )))), error ? /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, { color: themeColor("error") }, error)) : null)), /* @__PURE__ */ React105.createElement(Instructions, null));
30463
30093
  }
30464
30094
  function DeleteConfirm(props) {
30465
30095
  useInput30((_input, key) => {
30466
30096
  if (key.escape) props.onCancel();
30467
30097
  });
30468
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(
30098
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(
30469
30099
  Panel,
30470
30100
  {
30471
30101
  title: "Delete agent",
30472
30102
  borderColor: panelBorderColor("error"),
30473
30103
  titleColor: themeColor("error")
30474
30104
  },
30475
- /* @__PURE__ */ React106.createElement(Box79, { flexDirection: "column", gap: 1 }, /* @__PURE__ */ React106.createElement(Text83, null, "Are you sure you want to delete the agent ", /* @__PURE__ */ React106.createElement(Text83, { bold: true }, props.agent.agentType), "?"), /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "Source: ", props.agent.source)), /* @__PURE__ */ React106.createElement(Box79, { marginTop: 1 }, /* @__PURE__ */ React106.createElement(
30105
+ /* @__PURE__ */ React105.createElement(Box78, { flexDirection: "column", gap: 1 }, /* @__PURE__ */ React105.createElement(Text82, null, "Are you sure you want to delete the agent ", /* @__PURE__ */ React105.createElement(Text82, { bold: true }, props.agent.agentType), "?"), /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "Source: ", props.agent.source)), /* @__PURE__ */ React105.createElement(Box78, { marginTop: 1 }, /* @__PURE__ */ React105.createElement(
30476
30106
  Select,
30477
30107
  {
30478
30108
  options: [
@@ -30485,7 +30115,7 @@ function DeleteConfirm(props) {
30485
30115
  }
30486
30116
  }
30487
30117
  )))
30488
- ), /* @__PURE__ */ React106.createElement(Instructions, { instructions: "Press \u2191\u2193 to navigate, Enter to select, Esc to cancel" }));
30118
+ ), /* @__PURE__ */ React105.createElement(Instructions, { instructions: "Press \u2191\u2193 to navigate, Enter to select, Esc to cancel" }));
30489
30119
  }
30490
30120
  function AgentsUI({ onExit }) {
30491
30121
  const [mode, setMode] = useState29({ mode: "list-agents", source: "all" });
@@ -30556,10 +30186,10 @@ ${changes.join("\n")}`);
30556
30186
  onExit("Agents dialog dismissed");
30557
30187
  }, [changes, onExit]);
30558
30188
  if (loading) {
30559
- return /* @__PURE__ */ React106.createElement(React106.Fragment, null, /* @__PURE__ */ React106.createElement(Panel, { title: "Agents", subtitle: "Loading\u2026" }, /* @__PURE__ */ React106.createElement(Text83, { dimColor: true }, "Loading agents\u2026")), /* @__PURE__ */ React106.createElement(Instructions, null));
30189
+ return /* @__PURE__ */ React105.createElement(React105.Fragment, null, /* @__PURE__ */ React105.createElement(Panel, { title: "Agents", subtitle: "Loading\u2026" }, /* @__PURE__ */ React105.createElement(Text82, { dimColor: true }, "Loading agents\u2026")), /* @__PURE__ */ React105.createElement(Instructions, null));
30560
30190
  }
30561
30191
  if (mode.mode === "list-agents") {
30562
- return /* @__PURE__ */ React106.createElement(
30192
+ return /* @__PURE__ */ React105.createElement(
30563
30193
  AgentsListView,
30564
30194
  {
30565
30195
  source: mode.source,
@@ -30572,7 +30202,7 @@ ${changes.join("\n")}`);
30572
30202
  );
30573
30203
  }
30574
30204
  if (mode.mode === "create-agent") {
30575
- return /* @__PURE__ */ React106.createElement(
30205
+ return /* @__PURE__ */ React105.createElement(
30576
30206
  CreateAgentWizard,
30577
30207
  {
30578
30208
  tools,
@@ -30587,7 +30217,7 @@ ${changes.join("\n")}`);
30587
30217
  );
30588
30218
  }
30589
30219
  if (mode.mode === "agent-menu") {
30590
- return /* @__PURE__ */ React106.createElement(
30220
+ return /* @__PURE__ */ React105.createElement(
30591
30221
  AgentMenu,
30592
30222
  {
30593
30223
  agent: mode.agent,
@@ -30602,7 +30232,7 @@ ${changes.join("\n")}`);
30602
30232
  );
30603
30233
  }
30604
30234
  if (mode.mode === "view-agent") {
30605
- return /* @__PURE__ */ React106.createElement(
30235
+ return /* @__PURE__ */ React105.createElement(
30606
30236
  ViewAgent,
30607
30237
  {
30608
30238
  agent: mode.agent,
@@ -30612,7 +30242,7 @@ ${changes.join("\n")}`);
30612
30242
  );
30613
30243
  }
30614
30244
  if (mode.mode === "edit-agent") {
30615
- return /* @__PURE__ */ React106.createElement(
30245
+ return /* @__PURE__ */ React105.createElement(
30616
30246
  EditAgent,
30617
30247
  {
30618
30248
  agent: mode.agent,
@@ -30627,7 +30257,7 @@ ${changes.join("\n")}`);
30627
30257
  );
30628
30258
  }
30629
30259
  if (mode.mode === "delete-confirm") {
30630
- return /* @__PURE__ */ React106.createElement(
30260
+ return /* @__PURE__ */ React105.createElement(
30631
30261
  DeleteConfirm,
30632
30262
  {
30633
30263
  agent: mode.agent,
@@ -30652,7 +30282,7 @@ var agents_default = {
30652
30282
  isEnabled: true,
30653
30283
  isHidden: false,
30654
30284
  async call(onExit) {
30655
- return /* @__PURE__ */ React107.createElement(AgentsUI, { onExit });
30285
+ return /* @__PURE__ */ React106.createElement(AgentsUI, { onExit });
30656
30286
  },
30657
30287
  userFacingName() {
30658
30288
  return "agents";
@@ -30813,7 +30443,7 @@ ${availableLines}${truncatedNotice}
30813
30443
  return command4 || "";
30814
30444
  },
30815
30445
  renderToolUseRejectedMessage() {
30816
- return /* @__PURE__ */ React108.createElement(FallbackToolUseRejectedMessage, null);
30446
+ return /* @__PURE__ */ React107.createElement(FallbackToolUseRejectedMessage, null);
30817
30447
  },
30818
30448
  renderResultForAssistant(output) {
30819
30449
  return `Launching command: /${output.commandName}`;
@@ -30969,8 +30599,8 @@ function parseMcpToolName2(name3) {
30969
30599
  }
30970
30600
 
30971
30601
  // src/tools/system/KillShellTool/KillShellTool.tsx
30972
- import { Box as Box80, Text as Text84 } from "ink";
30973
- import React109 from "react";
30602
+ import { Box as Box79, Text as Text83 } from "ink";
30603
+ import React108 from "react";
30974
30604
  import { z as z14 } from "zod";
30975
30605
 
30976
30606
  // src/tools/system/KillShellTool/prompt.ts
@@ -31016,10 +30646,10 @@ var KillShellTool = {
31016
30646
  return `Kill shell: ${shell_id}`;
31017
30647
  },
31018
30648
  renderToolUseRejectedMessage() {
31019
- return /* @__PURE__ */ React109.createElement(FallbackToolUseRejectedMessage, null);
30649
+ return /* @__PURE__ */ React108.createElement(FallbackToolUseRejectedMessage, null);
31020
30650
  },
31021
30651
  renderToolResultMessage(output) {
31022
- return /* @__PURE__ */ React109.createElement(Box80, { flexDirection: "row" }, /* @__PURE__ */ React109.createElement(Text84, null, "\xA0\xA0\u23BF \xA0"), /* @__PURE__ */ React109.createElement(Text84, null, "Shell ", output.shell_id, " killed"));
30652
+ return /* @__PURE__ */ React108.createElement(Box79, { flexDirection: "row" }, /* @__PURE__ */ React108.createElement(Text83, null, "\xA0\xA0\u23BF \xA0"), /* @__PURE__ */ React108.createElement(Text83, null, "Shell ", output.shell_id, " killed"));
31023
30653
  },
31024
30654
  renderResultForAssistant(output) {
31025
30655
  return JSON.stringify(output);
@@ -31746,8 +31376,8 @@ function WebFetchPermissionRequest({
31746
31376
  reject();
31747
31377
  }
31748
31378
  });
31749
- return /* @__PURE__ */ React110.createElement(
31750
- Box81,
31379
+ return /* @__PURE__ */ React109.createElement(
31380
+ Box80,
31751
31381
  {
31752
31382
  flexDirection: "column",
31753
31383
  borderStyle: "round",
@@ -31757,14 +31387,14 @@ function WebFetchPermissionRequest({
31757
31387
  paddingRight: 1,
31758
31388
  paddingBottom: 1
31759
31389
  },
31760
- /* @__PURE__ */ React110.createElement(
31390
+ /* @__PURE__ */ React109.createElement(
31761
31391
  PermissionRequestTitle,
31762
31392
  {
31763
31393
  title: "Network request outside of sandbox",
31764
31394
  riskScore: null
31765
31395
  }
31766
31396
  ),
31767
- /* @__PURE__ */ React110.createElement(Box81, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React110.createElement(Box81, null, /* @__PURE__ */ React110.createElement(Text85, { dimColor: true }, "Host:"), /* @__PURE__ */ React110.createElement(Text85, null, " ", hostLabel)), /* @__PURE__ */ React110.createElement(Box81, { marginTop: 1 }, /* @__PURE__ */ React110.createElement(Text85, null, "Do you want to allow this connection?")), /* @__PURE__ */ React110.createElement(Box81, { marginTop: 1 }, /* @__PURE__ */ React110.createElement(
31397
+ /* @__PURE__ */ React109.createElement(Box80, { flexDirection: "column", paddingX: 2, paddingY: 1 }, /* @__PURE__ */ React109.createElement(Box80, null, /* @__PURE__ */ React109.createElement(Text84, { dimColor: true }, "Host:"), /* @__PURE__ */ React109.createElement(Text84, null, " ", hostLabel)), /* @__PURE__ */ React109.createElement(Box80, { marginTop: 1 }, /* @__PURE__ */ React109.createElement(Text84, null, "Do you want to allow this connection?")), /* @__PURE__ */ React109.createElement(Box80, { marginTop: 1 }, /* @__PURE__ */ React109.createElement(
31768
31398
  Select,
31769
31399
  {
31770
31400
  options: [
@@ -32136,10 +31766,10 @@ var BashTool = {
32136
31766
  return withDescription(base.trim());
32137
31767
  },
32138
31768
  renderToolUseRejectedMessage() {
32139
- return /* @__PURE__ */ React111.createElement(FallbackToolUseRejectedMessage, null);
31769
+ return /* @__PURE__ */ React110.createElement(FallbackToolUseRejectedMessage, null);
32140
31770
  },
32141
31771
  renderToolResultMessage(content) {
32142
- return /* @__PURE__ */ React111.createElement(BashToolResultMessage_default, { content, verbose: false });
31772
+ return /* @__PURE__ */ React110.createElement(BashToolResultMessage_default, { content, verbose: false });
32143
31773
  },
32144
31774
  renderResultForAssistant({
32145
31775
  interrupted,
@@ -32380,7 +32010,7 @@ Did you mean "git ${cmdParts.slice(1).join(" ")}"?`;
32380
32010
  }
32381
32011
  };
32382
32012
  setToolJSX({
32383
- jsx: /* @__PURE__ */ React111.createElement(
32013
+ jsx: /* @__PURE__ */ React110.createElement(
32384
32014
  WebFetchPermissionRequest,
32385
32015
  {
32386
32016
  toolUseConfirm,
@@ -32576,7 +32206,7 @@ ${footerParts.join(" ")}`;
32576
32206
  if (!overlayShown && setToolJSX && Date.now() - startedAt >= PROGRESS_INITIAL_DELAY_MS) {
32577
32207
  overlayShown = true;
32578
32208
  setToolJSX({
32579
- jsx: /* @__PURE__ */ React111.createElement(
32209
+ jsx: /* @__PURE__ */ React110.createElement(
32580
32210
  BashToolRunInBackgroundOverlay,
32581
32211
  {
32582
32212
  onBackground: requestBackground