pybao-cli 1.5.21 → 1.5.22
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.
- package/dist/REPL-KRZBKRH2.js +50 -0
- package/dist/{acp-VH2FWCMR.js → acp-6UNV3LLZ.js} +31 -31
- package/dist/{agentsValidate-4E7AHAMS.js → agentsValidate-Q6TKU7TM.js} +7 -7
- package/dist/{ask-R3YZ5B44.js → ask-VKXARFSE.js} +30 -30
- package/dist/{autoUpdater-DCNAXD4F.js → autoUpdater-7EWH6KLS.js} +3 -3
- package/dist/{chunk-56IL2VXC.js → chunk-3OHETUTC.js} +1 -1
- package/dist/{chunk-KMCUZUZG.js → chunk-5S2CPB42.js} +3 -3
- package/dist/{chunk-VP5A6FKG.js → chunk-5SXLQSDA.js} +1 -1
- package/dist/{chunk-6UNYL6XK.js → chunk-7HPHH3FB.js} +190 -64
- package/dist/{chunk-6UNYL6XK.js.map → chunk-7HPHH3FB.js.map} +4 -4
- package/dist/{chunk-TXZ5UTGP.js → chunk-A7DBXB2F.js} +1 -1
- package/dist/{chunk-TXZ5UTGP.js.map → chunk-A7DBXB2F.js.map} +1 -1
- package/dist/{chunk-TBEA6BY3.js → chunk-AJ3UX6R7.js} +1 -1
- package/dist/{chunk-25GZITCX.js → chunk-BHQOSSZK.js} +3 -3
- package/dist/{chunk-RQ5X6LFM.js → chunk-C3FMLNZD.js} +4 -4
- package/dist/{chunk-BRSPPFSY.js → chunk-CDK4YHKS.js} +1 -1
- package/dist/{chunk-P5NTGZ5H.js → chunk-CZZKRPE2.js} +1 -1
- package/dist/{chunk-P5NTGZ5H.js.map → chunk-CZZKRPE2.js.map} +1 -1
- package/dist/{chunk-3UWTN6DM.js → chunk-DUQMZDAG.js} +3 -3
- package/dist/{chunk-BED7SG2Q.js → chunk-E4JH2XFM.js} +1 -1
- package/dist/{chunk-ZQR3MM2D.js → chunk-EC3PLGG3.js} +2 -2
- package/dist/{chunk-TSAURYF2.js → chunk-EJJSN2TT.js} +1 -1
- package/dist/{chunk-XRLMQN3Q.js → chunk-FCSVC7CP.js} +4 -4
- package/dist/{chunk-X5LLT4P2.js → chunk-GDDO2XA3.js} +1 -1
- package/dist/{chunk-LRL3MYKR.js → chunk-GSFBS4B4.js} +3 -3
- package/dist/{chunk-SE7UGQCE.js → chunk-IZQYUXSZ.js} +2 -2
- package/dist/{chunk-H2ZE5QDY.js → chunk-JUMRO5I7.js} +4 -4
- package/dist/{chunk-EP62LHB7.js → chunk-JZJUCJTK.js} +1 -1
- package/dist/{chunk-2OOER4FR.js → chunk-K75Q3DNN.js} +3 -3
- package/dist/{chunk-QE7PZPHW.js → chunk-LRKZ3RPS.js} +1 -1
- package/dist/{chunk-HA7FKBZI.js → chunk-NHGHYVP4.js} +2 -2
- package/dist/{chunk-CSONCQLF.js → chunk-NNLRGQH7.js} +2 -2
- package/dist/{chunk-CPYDPN2J.js → chunk-O7R3XZGO.js} +15 -15
- package/dist/{chunk-YQ2RQUQF.js → chunk-OPAEJ3Y5.js} +1 -1
- package/dist/{chunk-MMMMRMOG.js → chunk-P3H2FCWA.js} +3 -3
- package/dist/{chunk-GIXE5FJ2.js → chunk-VXBBKE3Z.js} +1 -1
- package/dist/{chunk-N3T2WAYN.js → chunk-WHAWWM3Y.js} +1 -1
- package/dist/{chunk-4ZGZTWMR.js → chunk-WPTE44L5.js} +4 -4
- package/dist/{chunk-5VO2CFAL.js → chunk-XSUCLDWY.js} +2 -2
- package/dist/{chunk-VY5KEHU5.js → chunk-YGVF37PC.js} +3 -3
- package/dist/{chunk-NRQHLVJJ.js → chunk-YTMIS255.js} +2 -2
- package/dist/{cli-RBMZQ5KF.js → cli-DFM7Z6AH.js} +92 -92
- package/dist/commands-E6P6G6RL.js +54 -0
- package/dist/{config-7TO5SQU5.js → config-XUPBT2EE.js} +4 -4
- package/dist/{context-LRA2DKJT.js → context-TE7OR7RQ.js} +6 -6
- package/dist/{conversationPersistence-Z4QSI5NB.js → conversationPersistence-24HWWB75.js} +3 -3
- package/dist/{conversationTracker-B3DMEHMA.js → conversationTracker-4JE7TNPU.js} +4 -4
- package/dist/{customCommands-6JZ2VUO2.js → customCommands-OGYMS6BW.js} +4 -4
- package/dist/{env-37ALKFXU.js → env-OFPQLCBS.js} +2 -2
- package/dist/{file-7EOMBX72.js → file-X2XAPBRZ.js} +4 -4
- package/dist/index.js +3 -3
- package/dist/{llm-3KQG5NEP.js → llm-6XIL53O7.js} +31 -31
- package/dist/{llmLazy-ENEH3KAB.js → llmLazy-U2GIPU5C.js} +1 -1
- package/dist/{loader-D6V3WFL6.js → loader-EGMA6CWF.js} +4 -4
- package/dist/{lsp-CTPOMI7O.js → lsp-JMPOPT6A.js} +6 -6
- package/dist/{lspAnchor-PPPTHRQH.js → lspAnchor-5PMHI5BV.js} +6 -6
- package/dist/{mcp-6M34WBA5.js → mcp-XSVQR6C6.js} +7 -7
- package/dist/{mentionProcessor-TS4SITI3.js → mentionProcessor-4MOOQMS7.js} +5 -5
- package/dist/{messages-BINU6SYX.js → messages-ZBGD2RVK.js} +1 -1
- package/dist/{model-6IW224UU.js → model-ECTUAZ5Q.js} +5 -5
- package/dist/{openai-O6CGVMYK.js → openai-CRNKDQJ3.js} +5 -5
- package/dist/{outputStyles-7PPMLSV6.js → outputStyles-Z4PB6UX5.js} +4 -4
- package/dist/{pluginRuntime-RU5STQ6F.js → pluginRuntime-DRDVDAUU.js} +6 -6
- package/dist/{pluginValidation-JTJTB3TB.js → pluginValidation-RHPC5SAR.js} +6 -6
- package/dist/prompts-XBRLSIXQ.js +56 -0
- package/dist/{pybAgentSessionLoad-ZXQAHTQS.js → pybAgentSessionLoad-YAEB2WL4.js} +4 -4
- package/dist/{pybAgentSessionResume-R73KFN3V.js → pybAgentSessionResume-C7MUM2PL.js} +4 -4
- package/dist/{pybAgentStreamJsonSession-N4SMTC64.js → pybAgentStreamJsonSession-3X3S5CI2.js} +1 -1
- package/dist/{pybHooks-NGJ5OFAI.js → pybHooks-DWLOM55R.js} +4 -4
- package/dist/query-7M3GL2CM.js +54 -0
- package/dist/{registry-FKY6JQ3L.js → registry-MFGZRI5N.js} +5 -5
- package/dist/{ripgrep-O7MOW25M.js → ripgrep-P7LJLNZR.js} +3 -3
- package/dist/{skillMarketplace-VK3AYR6Q.js → skillMarketplace-R5ZEB7NX.js} +3 -3
- package/dist/{state-T57IG35V.js → state-W25DUPH2.js} +2 -2
- package/dist/{theme-ZEFQIPVH.js → theme-YNA47SVG.js} +5 -5
- package/dist/{toolPermissionSettings-ERNXVP7A.js → toolPermissionSettings-IJR677NS.js} +6 -6
- package/dist/tools-XDOXLNVD.js +55 -0
- package/dist/{userInput-JBAUBHGI.js → userInput-I2PLDULC.js} +33 -33
- package/package.json +1 -1
- package/dist/REPL-64WF5V7K.js +0 -50
- package/dist/commands-WPHK776A.js +0 -54
- package/dist/prompts-CAPCICF3.js +0 -56
- package/dist/query-CYTIVMQ6.js +0 -54
- package/dist/tools-2XLLIKZM.js +0 -55
- /package/dist/{REPL-64WF5V7K.js.map → REPL-KRZBKRH2.js.map} +0 -0
- /package/dist/{acp-VH2FWCMR.js.map → acp-6UNV3LLZ.js.map} +0 -0
- /package/dist/{agentsValidate-4E7AHAMS.js.map → agentsValidate-Q6TKU7TM.js.map} +0 -0
- /package/dist/{ask-R3YZ5B44.js.map → ask-VKXARFSE.js.map} +0 -0
- /package/dist/{autoUpdater-DCNAXD4F.js.map → autoUpdater-7EWH6KLS.js.map} +0 -0
- /package/dist/{chunk-56IL2VXC.js.map → chunk-3OHETUTC.js.map} +0 -0
- /package/dist/{chunk-KMCUZUZG.js.map → chunk-5S2CPB42.js.map} +0 -0
- /package/dist/{chunk-VP5A6FKG.js.map → chunk-5SXLQSDA.js.map} +0 -0
- /package/dist/{chunk-TBEA6BY3.js.map → chunk-AJ3UX6R7.js.map} +0 -0
- /package/dist/{chunk-25GZITCX.js.map → chunk-BHQOSSZK.js.map} +0 -0
- /package/dist/{chunk-RQ5X6LFM.js.map → chunk-C3FMLNZD.js.map} +0 -0
- /package/dist/{chunk-BRSPPFSY.js.map → chunk-CDK4YHKS.js.map} +0 -0
- /package/dist/{chunk-3UWTN6DM.js.map → chunk-DUQMZDAG.js.map} +0 -0
- /package/dist/{chunk-BED7SG2Q.js.map → chunk-E4JH2XFM.js.map} +0 -0
- /package/dist/{chunk-ZQR3MM2D.js.map → chunk-EC3PLGG3.js.map} +0 -0
- /package/dist/{chunk-TSAURYF2.js.map → chunk-EJJSN2TT.js.map} +0 -0
- /package/dist/{chunk-XRLMQN3Q.js.map → chunk-FCSVC7CP.js.map} +0 -0
- /package/dist/{chunk-X5LLT4P2.js.map → chunk-GDDO2XA3.js.map} +0 -0
- /package/dist/{chunk-LRL3MYKR.js.map → chunk-GSFBS4B4.js.map} +0 -0
- /package/dist/{chunk-SE7UGQCE.js.map → chunk-IZQYUXSZ.js.map} +0 -0
- /package/dist/{chunk-H2ZE5QDY.js.map → chunk-JUMRO5I7.js.map} +0 -0
- /package/dist/{chunk-EP62LHB7.js.map → chunk-JZJUCJTK.js.map} +0 -0
- /package/dist/{chunk-2OOER4FR.js.map → chunk-K75Q3DNN.js.map} +0 -0
- /package/dist/{chunk-QE7PZPHW.js.map → chunk-LRKZ3RPS.js.map} +0 -0
- /package/dist/{chunk-HA7FKBZI.js.map → chunk-NHGHYVP4.js.map} +0 -0
- /package/dist/{chunk-CSONCQLF.js.map → chunk-NNLRGQH7.js.map} +0 -0
- /package/dist/{chunk-CPYDPN2J.js.map → chunk-O7R3XZGO.js.map} +0 -0
- /package/dist/{chunk-YQ2RQUQF.js.map → chunk-OPAEJ3Y5.js.map} +0 -0
- /package/dist/{chunk-MMMMRMOG.js.map → chunk-P3H2FCWA.js.map} +0 -0
- /package/dist/{chunk-GIXE5FJ2.js.map → chunk-VXBBKE3Z.js.map} +0 -0
- /package/dist/{chunk-N3T2WAYN.js.map → chunk-WHAWWM3Y.js.map} +0 -0
- /package/dist/{chunk-4ZGZTWMR.js.map → chunk-WPTE44L5.js.map} +0 -0
- /package/dist/{chunk-5VO2CFAL.js.map → chunk-XSUCLDWY.js.map} +0 -0
- /package/dist/{chunk-VY5KEHU5.js.map → chunk-YGVF37PC.js.map} +0 -0
- /package/dist/{chunk-NRQHLVJJ.js.map → chunk-YTMIS255.js.map} +0 -0
- /package/dist/{cli-RBMZQ5KF.js.map → cli-DFM7Z6AH.js.map} +0 -0
- /package/dist/{commands-WPHK776A.js.map → commands-E6P6G6RL.js.map} +0 -0
- /package/dist/{config-7TO5SQU5.js.map → config-XUPBT2EE.js.map} +0 -0
- /package/dist/{context-LRA2DKJT.js.map → context-TE7OR7RQ.js.map} +0 -0
- /package/dist/{conversationPersistence-Z4QSI5NB.js.map → conversationPersistence-24HWWB75.js.map} +0 -0
- /package/dist/{conversationTracker-B3DMEHMA.js.map → conversationTracker-4JE7TNPU.js.map} +0 -0
- /package/dist/{customCommands-6JZ2VUO2.js.map → customCommands-OGYMS6BW.js.map} +0 -0
- /package/dist/{env-37ALKFXU.js.map → env-OFPQLCBS.js.map} +0 -0
- /package/dist/{file-7EOMBX72.js.map → file-X2XAPBRZ.js.map} +0 -0
- /package/dist/{llm-3KQG5NEP.js.map → llm-6XIL53O7.js.map} +0 -0
- /package/dist/{llmLazy-ENEH3KAB.js.map → llmLazy-U2GIPU5C.js.map} +0 -0
- /package/dist/{loader-D6V3WFL6.js.map → loader-EGMA6CWF.js.map} +0 -0
- /package/dist/{lsp-CTPOMI7O.js.map → lsp-JMPOPT6A.js.map} +0 -0
- /package/dist/{lspAnchor-PPPTHRQH.js.map → lspAnchor-5PMHI5BV.js.map} +0 -0
- /package/dist/{mcp-6M34WBA5.js.map → mcp-XSVQR6C6.js.map} +0 -0
- /package/dist/{mentionProcessor-TS4SITI3.js.map → mentionProcessor-4MOOQMS7.js.map} +0 -0
- /package/dist/{messages-BINU6SYX.js.map → messages-ZBGD2RVK.js.map} +0 -0
- /package/dist/{model-6IW224UU.js.map → model-ECTUAZ5Q.js.map} +0 -0
- /package/dist/{openai-O6CGVMYK.js.map → openai-CRNKDQJ3.js.map} +0 -0
- /package/dist/{outputStyles-7PPMLSV6.js.map → outputStyles-Z4PB6UX5.js.map} +0 -0
- /package/dist/{pluginRuntime-RU5STQ6F.js.map → pluginRuntime-DRDVDAUU.js.map} +0 -0
- /package/dist/{pluginValidation-JTJTB3TB.js.map → pluginValidation-RHPC5SAR.js.map} +0 -0
- /package/dist/{prompts-CAPCICF3.js.map → prompts-XBRLSIXQ.js.map} +0 -0
- /package/dist/{pybAgentSessionLoad-ZXQAHTQS.js.map → pybAgentSessionLoad-YAEB2WL4.js.map} +0 -0
- /package/dist/{pybAgentSessionResume-R73KFN3V.js.map → pybAgentSessionResume-C7MUM2PL.js.map} +0 -0
- /package/dist/{pybAgentStreamJsonSession-N4SMTC64.js.map → pybAgentStreamJsonSession-3X3S5CI2.js.map} +0 -0
- /package/dist/{pybHooks-NGJ5OFAI.js.map → pybHooks-DWLOM55R.js.map} +0 -0
- /package/dist/{query-CYTIVMQ6.js.map → query-7M3GL2CM.js.map} +0 -0
- /package/dist/{registry-FKY6JQ3L.js.map → registry-MFGZRI5N.js.map} +0 -0
- /package/dist/{ripgrep-O7MOW25M.js.map → ripgrep-P7LJLNZR.js.map} +0 -0
- /package/dist/{skillMarketplace-VK3AYR6Q.js.map → skillMarketplace-R5ZEB7NX.js.map} +0 -0
- /package/dist/{state-T57IG35V.js.map → state-W25DUPH2.js.map} +0 -0
- /package/dist/{theme-ZEFQIPVH.js.map → theme-YNA47SVG.js.map} +0 -0
- /package/dist/{toolPermissionSettings-ERNXVP7A.js.map → toolPermissionSettings-IJR677NS.js.map} +0 -0
- /package/dist/{tools-2XLLIKZM.js.map → tools-XDOXLNVD.js.map} +0 -0
- /package/dist/{userInput-JBAUBHGI.js.map → userInput-I2PLDULC.js.map} +0 -0
|
@@ -2,18 +2,18 @@ import { createRequire as __pybCreateRequire } from "node:module";
|
|
|
2
2
|
const require = __pybCreateRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
loadPybAgentSessionMessages
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-WHAWWM3Y.js";
|
|
6
6
|
import {
|
|
7
7
|
listPybAgentSessions
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-CDK4YHKS.js";
|
|
9
9
|
import {
|
|
10
10
|
appendSessionCustomTitleRecord,
|
|
11
11
|
appendSessionTagRecord
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-EJJSN2TT.js";
|
|
13
13
|
import {
|
|
14
14
|
formatValidationResult,
|
|
15
15
|
validatePluginOrMarketplacePath
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-GSFBS4B4.js";
|
|
17
17
|
import {
|
|
18
18
|
ConversationTracker,
|
|
19
19
|
appendFinishState,
|
|
@@ -21,10 +21,10 @@ import {
|
|
|
21
21
|
getConversationTrackerForContext,
|
|
22
22
|
isFinishComplete,
|
|
23
23
|
mapFinishReason
|
|
24
|
-
} from "./chunk-
|
|
24
|
+
} from "./chunk-VXBBKE3Z.js";
|
|
25
25
|
import {
|
|
26
26
|
FileSystemConversationPersistence
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-JZJUCJTK.js";
|
|
28
28
|
import {
|
|
29
29
|
beginReplSessionScope
|
|
30
30
|
} from "./chunk-F4AXICO7.js";
|
|
@@ -39,7 +39,7 @@ import {
|
|
|
39
39
|
runStopHooks,
|
|
40
40
|
runUserPromptSubmitHooks,
|
|
41
41
|
updateHookTranscriptForMessages
|
|
42
|
-
} from "./chunk-
|
|
42
|
+
} from "./chunk-K75Q3DNN.js";
|
|
43
43
|
import {
|
|
44
44
|
DEFAULT_OUTPUT_STYLE,
|
|
45
45
|
getAvailableOutputStyles,
|
|
@@ -48,11 +48,11 @@ import {
|
|
|
48
48
|
getOutputStyleSystemPromptAdditions,
|
|
49
49
|
resolveOutputStyleName,
|
|
50
50
|
setCurrentOutputStyle
|
|
51
|
-
} from "./chunk-
|
|
51
|
+
} from "./chunk-IZQYUXSZ.js";
|
|
52
52
|
import {
|
|
53
53
|
fetchCustomModels,
|
|
54
54
|
getModelFeatures
|
|
55
|
-
} from "./chunk-
|
|
55
|
+
} from "./chunk-NNLRGQH7.js";
|
|
56
56
|
import {
|
|
57
57
|
getSessionState
|
|
58
58
|
} from "./chunk-XKYHFZEC.js";
|
|
@@ -60,7 +60,7 @@ import {
|
|
|
60
60
|
queryLLM,
|
|
61
61
|
queryQuick,
|
|
62
62
|
verifyApiKey
|
|
63
|
-
} from "./chunk-
|
|
63
|
+
} from "./chunk-WPTE44L5.js";
|
|
64
64
|
import {
|
|
65
65
|
DEFAULT_TIMEOUT_MS,
|
|
66
66
|
FallbackToolUseRejectedMessage,
|
|
@@ -74,7 +74,7 @@ import {
|
|
|
74
74
|
listMCPServers,
|
|
75
75
|
loadMergedSettings,
|
|
76
76
|
normalizeSandboxRuntimeConfigFromSettings
|
|
77
|
-
} from "./chunk-
|
|
77
|
+
} from "./chunk-JUMRO5I7.js";
|
|
78
78
|
import {
|
|
79
79
|
addMarketplace,
|
|
80
80
|
disableSkillPlugin,
|
|
@@ -87,11 +87,11 @@ import {
|
|
|
87
87
|
refreshMarketplaceAsync,
|
|
88
88
|
removeMarketplace,
|
|
89
89
|
uninstallSkillPlugin
|
|
90
|
-
} from "./chunk-
|
|
90
|
+
} from "./chunk-LRKZ3RPS.js";
|
|
91
91
|
import {
|
|
92
92
|
loadToolPermissionContextFromDisk,
|
|
93
93
|
persistToolPermissionUpdateToDisk
|
|
94
|
-
} from "./chunk-
|
|
94
|
+
} from "./chunk-5S2CPB42.js";
|
|
95
95
|
import {
|
|
96
96
|
applyToolPermissionContextUpdate,
|
|
97
97
|
applyToolPermissionContextUpdates,
|
|
@@ -102,13 +102,13 @@ import {
|
|
|
102
102
|
generateSystemReminders,
|
|
103
103
|
resetReminderSession,
|
|
104
104
|
systemReminderService
|
|
105
|
-
} from "./chunk-
|
|
105
|
+
} from "./chunk-EC3PLGG3.js";
|
|
106
106
|
import {
|
|
107
107
|
clearAgentCache,
|
|
108
108
|
getActiveAgents,
|
|
109
109
|
getAgentByType,
|
|
110
110
|
getAllAgents
|
|
111
|
-
} from "./chunk-
|
|
111
|
+
} from "./chunk-YTMIS255.js";
|
|
112
112
|
import {
|
|
113
113
|
API_ERROR_MESSAGE_PREFIX,
|
|
114
114
|
CANCEL_MESSAGE,
|
|
@@ -145,7 +145,7 @@ import {
|
|
|
145
145
|
reorderMessages,
|
|
146
146
|
resetAutoCompactTelemetry,
|
|
147
147
|
stripSystemMessages
|
|
148
|
-
} from "./chunk-
|
|
148
|
+
} from "./chunk-OPAEJ3Y5.js";
|
|
149
149
|
import {
|
|
150
150
|
getRequestStatus,
|
|
151
151
|
setRequestStatus,
|
|
@@ -175,7 +175,7 @@ import {
|
|
|
175
175
|
normalizeFilePath,
|
|
176
176
|
readTextContent,
|
|
177
177
|
writeTextContent
|
|
178
|
-
} from "./chunk-
|
|
178
|
+
} from "./chunk-NHGHYVP4.js";
|
|
179
179
|
import {
|
|
180
180
|
parseBlockEdits
|
|
181
181
|
} from "./chunk-QWIBSCDN.js";
|
|
@@ -185,18 +185,18 @@ import {
|
|
|
185
185
|
ParserRegistry,
|
|
186
186
|
initParser,
|
|
187
187
|
loadLanguage
|
|
188
|
-
} from "./chunk-
|
|
188
|
+
} from "./chunk-FCSVC7CP.js";
|
|
189
189
|
import {
|
|
190
190
|
getSettingsFileCandidates,
|
|
191
191
|
loadSettingsWithLegacyFallback,
|
|
192
192
|
readSettingsFile
|
|
193
|
-
} from "./chunk-
|
|
193
|
+
} from "./chunk-GDDO2XA3.js";
|
|
194
194
|
import {
|
|
195
195
|
getCustomCommandDirectories,
|
|
196
196
|
hasCustomCommands,
|
|
197
197
|
loadCustomCommands,
|
|
198
198
|
reloadCustomCommands
|
|
199
|
-
} from "./chunk-
|
|
199
|
+
} from "./chunk-XSUCLDWY.js";
|
|
200
200
|
import {
|
|
201
201
|
getSessionPlugins
|
|
202
202
|
} from "./chunk-BJSWTHRM.js";
|
|
@@ -205,7 +205,7 @@ import {
|
|
|
205
205
|
buildModelProfileKey,
|
|
206
206
|
getModelManager,
|
|
207
207
|
isDefaultSlowAndCapableModel
|
|
208
|
-
} from "./chunk-
|
|
208
|
+
} from "./chunk-BHQOSSZK.js";
|
|
209
209
|
import {
|
|
210
210
|
getCodeStyle,
|
|
211
211
|
getContext,
|
|
@@ -213,16 +213,16 @@ import {
|
|
|
213
213
|
getIsGit,
|
|
214
214
|
getProjectDocs,
|
|
215
215
|
getProjectStructureStatisticsBlock
|
|
216
|
-
} from "./chunk-
|
|
216
|
+
} from "./chunk-C3FMLNZD.js";
|
|
217
217
|
import {
|
|
218
218
|
getRipgrepPath,
|
|
219
219
|
getRipgrepPolicyMode,
|
|
220
220
|
resolveRipgrepPolicy,
|
|
221
221
|
ripGrep
|
|
222
|
-
} from "./chunk-
|
|
222
|
+
} from "./chunk-E4JH2XFM.js";
|
|
223
223
|
import {
|
|
224
224
|
getTheme
|
|
225
|
-
} from "./chunk-
|
|
225
|
+
} from "./chunk-3OHETUTC.js";
|
|
226
226
|
import {
|
|
227
227
|
DEFAULT_GLOBAL_CONFIG,
|
|
228
228
|
enableConfigs,
|
|
@@ -235,7 +235,7 @@ import {
|
|
|
235
235
|
saveGlobalConfig,
|
|
236
236
|
setAllPointersToModel,
|
|
237
237
|
setModelPointer
|
|
238
|
-
} from "./chunk-
|
|
238
|
+
} from "./chunk-DUQMZDAG.js";
|
|
239
239
|
import {
|
|
240
240
|
AbortError
|
|
241
241
|
} from "./chunk-RQVLBMP7.js";
|
|
@@ -244,7 +244,7 @@ import {
|
|
|
244
244
|
getCurrentRequest,
|
|
245
245
|
logUserFriendly,
|
|
246
246
|
markPhase
|
|
247
|
-
} from "./chunk-
|
|
247
|
+
} from "./chunk-AJ3UX6R7.js";
|
|
248
248
|
import {
|
|
249
249
|
ASCII_LOGO,
|
|
250
250
|
BunShell,
|
|
@@ -285,10 +285,10 @@ import {
|
|
|
285
285
|
setCwd,
|
|
286
286
|
shouldApplyToolOutputTruncation,
|
|
287
287
|
truncateToolOutput
|
|
288
|
-
} from "./chunk-
|
|
288
|
+
} from "./chunk-5SXLQSDA.js";
|
|
289
289
|
import {
|
|
290
290
|
MACRO
|
|
291
|
-
} from "./chunk-
|
|
291
|
+
} from "./chunk-A7DBXB2F.js";
|
|
292
292
|
import {
|
|
293
293
|
__export
|
|
294
294
|
} from "./chunk-I3J4JYES.js";
|
|
@@ -469,7 +469,7 @@ var getCommandSubcommandPrefix = memoize(
|
|
|
469
469
|
var getCommandPrefix = memoize(
|
|
470
470
|
async (command4, abortSignal) => {
|
|
471
471
|
const { systemPrompt, userPrompt } = buildBashCommandPrefixDetectionPrompt(command4);
|
|
472
|
-
const { API_ERROR_MESSAGE_PREFIX: API_ERROR_MESSAGE_PREFIX2, queryQuick: queryQuick2 } = await import("./llm-
|
|
472
|
+
const { API_ERROR_MESSAGE_PREFIX: API_ERROR_MESSAGE_PREFIX2, queryQuick: queryQuick2 } = await import("./llm-6XIL53O7.js");
|
|
473
473
|
const response = await queryQuick2({
|
|
474
474
|
systemPrompt,
|
|
475
475
|
userPrompt,
|
|
@@ -4271,7 +4271,7 @@ function formatParseError(error) {
|
|
|
4271
4271
|
return error instanceof Error ? error.message : String(error);
|
|
4272
4272
|
}
|
|
4273
4273
|
async function defaultGateQuery(args) {
|
|
4274
|
-
const { API_ERROR_MESSAGE_PREFIX: API_ERROR_MESSAGE_PREFIX2, queryLLM: queryLLM2 } = await import("./llm-
|
|
4274
|
+
const { API_ERROR_MESSAGE_PREFIX: API_ERROR_MESSAGE_PREFIX2, queryLLM: queryLLM2 } = await import("./llm-6XIL53O7.js");
|
|
4275
4275
|
const queryLLMFn = args.queryLLMOverride ?? queryLLM2;
|
|
4276
4276
|
const messages = [
|
|
4277
4277
|
{
|
|
@@ -6664,7 +6664,7 @@ var FileEditTool = {
|
|
|
6664
6664
|
const originalFileContent = currentFileContent;
|
|
6665
6665
|
let totalPatch = [];
|
|
6666
6666
|
const { SmartEdit } = await import("./smart-edit-AWHJDSU6.js");
|
|
6667
|
-
const { findLspAnchor } = await import("./lspAnchor-
|
|
6667
|
+
const { findLspAnchor } = await import("./lspAnchor-5PMHI5BV.js");
|
|
6668
6668
|
for (const op of editOperations) {
|
|
6669
6669
|
const normalizedSearch = normalizeLineEndings(op.search);
|
|
6670
6670
|
const normalizedReplace = normalizeLineEndings(op.replace);
|
|
@@ -7310,11 +7310,11 @@ function getDirname() {
|
|
|
7310
7310
|
function resolveTreeSitterResourceDir() {
|
|
7311
7311
|
const envDir = process.env.PYB_RESOURCE_DIR?.trim();
|
|
7312
7312
|
if (envDir) return envDir;
|
|
7313
|
-
const
|
|
7314
|
-
if (
|
|
7315
|
-
return path4.resolve(
|
|
7313
|
+
const dirname13 = getDirname();
|
|
7314
|
+
if (dirname13.includes("dist") || dirname13.includes("node_modules")) {
|
|
7315
|
+
return path4.resolve(dirname13, "../../../../resources/tree-sitter");
|
|
7316
7316
|
}
|
|
7317
|
-
return path4.resolve(
|
|
7317
|
+
return path4.resolve(dirname13, "../../../../../resources/tree-sitter");
|
|
7318
7318
|
}
|
|
7319
7319
|
var REQUIRED_TREE_SITTER_FILES = [
|
|
7320
7320
|
"tree-sitter.wasm",
|
|
@@ -12149,7 +12149,7 @@ async function createAndStoreApiKey(accessToken) {
|
|
|
12149
12149
|
}
|
|
12150
12150
|
saveGlobalConfig(config2);
|
|
12151
12151
|
try {
|
|
12152
|
-
const { resetAnthropicClient } = await import("./llm-
|
|
12152
|
+
const { resetAnthropicClient } = await import("./llm-6XIL53O7.js");
|
|
12153
12153
|
resetAnthropicClient();
|
|
12154
12154
|
} catch {
|
|
12155
12155
|
}
|
|
@@ -16573,7 +16573,7 @@ async function refreshPluginRuntimeFromInstalls() {
|
|
|
16573
16573
|
const existingRoots = getSessionPlugins().map((p) => p.rootDir);
|
|
16574
16574
|
const dirs = Array.from(/* @__PURE__ */ new Set([...existingRoots, ...installedRoots]));
|
|
16575
16575
|
if (dirs.length === 0) return [];
|
|
16576
|
-
const { configureSessionPlugins } = await import("./pluginRuntime-
|
|
16576
|
+
const { configureSessionPlugins } = await import("./pluginRuntime-DRDVDAUU.js");
|
|
16577
16577
|
const { errors } = await configureSessionPlugins({ pluginDirs: dirs });
|
|
16578
16578
|
return errors;
|
|
16579
16579
|
}
|
|
@@ -17248,7 +17248,7 @@ async function call(onDone, context) {
|
|
|
17248
17248
|
ModelConfig,
|
|
17249
17249
|
{
|
|
17250
17250
|
onClose: () => {
|
|
17251
|
-
import("./model-
|
|
17251
|
+
import("./model-ECTUAZ5Q.js").then(({ reloadModelManager: reloadModelManager2 }) => {
|
|
17252
17252
|
reloadModelManager2();
|
|
17253
17253
|
triggerModelConfigChange();
|
|
17254
17254
|
onDone();
|
|
@@ -19998,6 +19998,63 @@ import { homedir as homedir7 } from "os";
|
|
|
19998
19998
|
import { randomUUID as randomUUID4 } from "crypto";
|
|
19999
19999
|
import { AsyncLocalStorage } from "async_hooks";
|
|
20000
20000
|
|
|
20001
|
+
// src/utils/session/taskBoundaryTelemetrySink.ts
|
|
20002
|
+
function createTaskBoundaryTelemetrySink() {
|
|
20003
|
+
const events = [];
|
|
20004
|
+
return {
|
|
20005
|
+
push(event) {
|
|
20006
|
+
events.push(event);
|
|
20007
|
+
},
|
|
20008
|
+
snapshot() {
|
|
20009
|
+
const phaseCounts = {};
|
|
20010
|
+
for (const event of events) {
|
|
20011
|
+
const phase = event.phase;
|
|
20012
|
+
phaseCounts[phase] = (phaseCounts[phase] ?? 0) + 1;
|
|
20013
|
+
}
|
|
20014
|
+
return {
|
|
20015
|
+
eventCount: events.length,
|
|
20016
|
+
phaseCounts
|
|
20017
|
+
};
|
|
20018
|
+
},
|
|
20019
|
+
clear() {
|
|
20020
|
+
events.length = 0;
|
|
20021
|
+
}
|
|
20022
|
+
};
|
|
20023
|
+
}
|
|
20024
|
+
|
|
20025
|
+
// src/services/telemetry/taskBoundaryTelemetry.ts
|
|
20026
|
+
var TASK_BOUNDARY_LISTENER_ID = "task-boundary-telemetry-sink";
|
|
20027
|
+
var taskBoundarySink = createTaskBoundaryTelemetrySink();
|
|
20028
|
+
var sinkRegistered = false;
|
|
20029
|
+
function ensureTaskBoundaryTelemetryRegistered() {
|
|
20030
|
+
if (sinkRegistered) return;
|
|
20031
|
+
registerTelemetryListener(TASK_BOUNDARY_LISTENER_ID, (event) => {
|
|
20032
|
+
if (event.channel !== "task_boundary") return;
|
|
20033
|
+
taskBoundarySink.push({
|
|
20034
|
+
phase: event.phase,
|
|
20035
|
+
data: event.data
|
|
20036
|
+
});
|
|
20037
|
+
});
|
|
20038
|
+
sinkRegistered = true;
|
|
20039
|
+
}
|
|
20040
|
+
function emitTaskBoundaryTelemetryEvent(phase, data) {
|
|
20041
|
+
ensureTaskBoundaryTelemetryRegistered();
|
|
20042
|
+
emitTelemetryEvent({
|
|
20043
|
+
channel: "task_boundary",
|
|
20044
|
+
phase,
|
|
20045
|
+
data,
|
|
20046
|
+
timestamp: Date.now()
|
|
20047
|
+
});
|
|
20048
|
+
}
|
|
20049
|
+
function getTaskBoundaryTelemetrySnapshot() {
|
|
20050
|
+
ensureTaskBoundaryTelemetryRegistered();
|
|
20051
|
+
return taskBoundarySink.snapshot();
|
|
20052
|
+
}
|
|
20053
|
+
function resetTaskBoundaryTelemetry() {
|
|
20054
|
+
taskBoundarySink.clear();
|
|
20055
|
+
}
|
|
20056
|
+
ensureTaskBoundaryTelemetryRegistered();
|
|
20057
|
+
|
|
20001
20058
|
// src/utils/session/taskLockNative.ts
|
|
20002
20059
|
import { createRequire } from "module";
|
|
20003
20060
|
var require2 = createRequire(import.meta.url);
|
|
@@ -20845,6 +20902,11 @@ function updateTask(id, updates, options) {
|
|
|
20845
20902
|
(paths) => existsSync10(join8(paths.tasksDir, `${id}.json`))
|
|
20846
20903
|
);
|
|
20847
20904
|
if (!target) {
|
|
20905
|
+
emitTaskBoundaryTelemetryEvent("TASK_UPDATE_NOT_FOUND_NO_SIDE_EFFECT", {
|
|
20906
|
+
taskId: id,
|
|
20907
|
+
listId: options?.listId ?? null,
|
|
20908
|
+
noSideEffect: true
|
|
20909
|
+
});
|
|
20848
20910
|
throw new Error(`Task ${id} not found`);
|
|
20849
20911
|
}
|
|
20850
20912
|
return withTaskListLock(target, () => {
|
|
@@ -20930,8 +20992,14 @@ function updateTask(id, updates, options) {
|
|
|
20930
20992
|
}
|
|
20931
20993
|
function rebuildTaskBlocks(options) {
|
|
20932
20994
|
const paths = getTaskListPaths(options?.listId);
|
|
20995
|
+
if (!existsSync10(paths.listDir)) {
|
|
20996
|
+
emitTaskBoundaryTelemetryEvent("TASK_REBUILD_MISSING_LIST_DIR_REJECTED", {
|
|
20997
|
+
listId: paths.listId,
|
|
20998
|
+
noSideEffect: true
|
|
20999
|
+
});
|
|
21000
|
+
throw new Error(`Task list ${paths.listId} not found`);
|
|
21001
|
+
}
|
|
20933
21002
|
return withTaskListLock(paths, () => {
|
|
20934
|
-
ensureTaskListDirs(paths);
|
|
20935
21003
|
return persistBlocksForPaths(paths);
|
|
20936
21004
|
});
|
|
20937
21005
|
}
|
|
@@ -25751,7 +25819,7 @@ function useStatusLine() {
|
|
|
25751
25819
|
// src/ui/components/PromptInput.tsx
|
|
25752
25820
|
async function interpretHashCommand(input) {
|
|
25753
25821
|
try {
|
|
25754
|
-
const { queryQuick: queryQuick2 } = await import("./llm-
|
|
25822
|
+
const { queryQuick: queryQuick2 } = await import("./llm-6XIL53O7.js");
|
|
25755
25823
|
const systemPrompt = [
|
|
25756
25824
|
"You're helping the user structure notes that will be added to their PYB.md file.",
|
|
25757
25825
|
"Format the user's input into a well-structured note that will be useful for later reference.",
|
|
@@ -26064,7 +26132,7 @@ function PromptInput({
|
|
|
26064
26132
|
if (messages2.length) {
|
|
26065
26133
|
if (mode === "bash") {
|
|
26066
26134
|
onQuery(messages2, newAbortController).then(async () => {
|
|
26067
|
-
const { getCwd: getCwd2 } = await import("./state-
|
|
26135
|
+
const { getCwd: getCwd2 } = await import("./state-W25DUPH2.js");
|
|
26068
26136
|
setCurrentPwd(getCwd2());
|
|
26069
26137
|
});
|
|
26070
26138
|
} else {
|
|
@@ -27114,7 +27182,7 @@ function resolveReminderChannelFlags(env2 = process.env) {
|
|
|
27114
27182
|
}
|
|
27115
27183
|
|
|
27116
27184
|
// src/services/system/taskWatcher.ts
|
|
27117
|
-
import { existsSync as existsSync16,
|
|
27185
|
+
import { existsSync as existsSync16, statSync as statSync13, watch } from "fs";
|
|
27118
27186
|
|
|
27119
27187
|
// src/utils/session/taskGraph.ts
|
|
27120
27188
|
function buildTaskGraph(tasks) {
|
|
@@ -27205,9 +27273,6 @@ function calculateReadyBlocked(tasks) {
|
|
|
27205
27273
|
// src/services/system/taskWatcher.ts
|
|
27206
27274
|
var getPollIntervalMs = () => Number(process.env.PYB_TASK_WATCHER_POLL_INTERVAL_MS ?? 1e3);
|
|
27207
27275
|
var taskWatchers = /* @__PURE__ */ new Map();
|
|
27208
|
-
function ensureDirs(paths) {
|
|
27209
|
-
mkdirSync6(paths.tasksDir, { recursive: true });
|
|
27210
|
-
}
|
|
27211
27276
|
function getLatestMtime(dir) {
|
|
27212
27277
|
try {
|
|
27213
27278
|
if (!existsSync16(dir)) return 0;
|
|
@@ -27307,7 +27372,16 @@ function startFallbackWatcher(entry) {
|
|
|
27307
27372
|
function startWatchingTaskList(listId) {
|
|
27308
27373
|
const paths = getTaskListPaths(listId);
|
|
27309
27374
|
if (taskWatchers.has(paths.listId)) return;
|
|
27310
|
-
|
|
27375
|
+
if (!existsSync16(paths.listDir)) {
|
|
27376
|
+
debug.warn("TASK_WATCHER_SKIP_MISSING_LIST_DIR", {
|
|
27377
|
+
listId: paths.listId,
|
|
27378
|
+
watch_skipped_reason: "list_dir_missing"
|
|
27379
|
+
});
|
|
27380
|
+
emitTaskBoundaryTelemetryEvent("TASK_WATCH_SKIP_MISSING_LIST_DIR", {
|
|
27381
|
+
listId: paths.listId,
|
|
27382
|
+
watch_skipped_reason: "list_dir_missing"
|
|
27383
|
+
});
|
|
27384
|
+
}
|
|
27311
27385
|
const entry = {
|
|
27312
27386
|
listId: paths.listId,
|
|
27313
27387
|
listDir: paths.listDir,
|
|
@@ -27826,7 +27900,7 @@ function flushTypedParts(state) {
|
|
|
27826
27900
|
}
|
|
27827
27901
|
|
|
27828
27902
|
// src/services/ai/streamTyped/partStore.ts
|
|
27829
|
-
import { existsSync as existsSync17, mkdirSync as
|
|
27903
|
+
import { existsSync as existsSync17, mkdirSync as mkdirSync6 } from "fs";
|
|
27830
27904
|
import { dirname as dirname9 } from "path";
|
|
27831
27905
|
import { createRequire as createRequire2 } from "node:module";
|
|
27832
27906
|
var requireForSqlite = createRequire2(import.meta.url);
|
|
@@ -27899,7 +27973,7 @@ function upsertTypedPartsToDb(options) {
|
|
|
27899
27973
|
return { upserted: 0 };
|
|
27900
27974
|
}
|
|
27901
27975
|
if (!existsSync17(dirname9(options.dbFilePath))) {
|
|
27902
|
-
|
|
27976
|
+
mkdirSync6(dirname9(options.dbFilePath), { recursive: true });
|
|
27903
27977
|
}
|
|
27904
27978
|
const Database = getDatabaseCtorOrThrow();
|
|
27905
27979
|
const db = new Database(options.dbFilePath, { create: true });
|
|
@@ -30077,7 +30151,7 @@ function buildToolOutputLifecyclePreGateMetrics(samples) {
|
|
|
30077
30151
|
}
|
|
30078
30152
|
|
|
30079
30153
|
// src/services/telemetry/autoCompactTelemetryPersistence.ts
|
|
30080
|
-
import { appendFileSync, existsSync as existsSync18, mkdirSync as
|
|
30154
|
+
import { appendFileSync, existsSync as existsSync18, mkdirSync as mkdirSync7 } from "fs";
|
|
30081
30155
|
import { dirname as dirname10 } from "path";
|
|
30082
30156
|
function getAutoCompactTelemetryOutputFilePath() {
|
|
30083
30157
|
return resolveXdgCachePath("telemetry/auto-compact-metrics.jsonl");
|
|
@@ -30094,7 +30168,7 @@ function flushAutoCompactTelemetrySnapshot(options = {}) {
|
|
|
30094
30168
|
metrics: snapshot.metrics
|
|
30095
30169
|
};
|
|
30096
30170
|
if (!existsSync18(dirname10(outputFilePath))) {
|
|
30097
|
-
|
|
30171
|
+
mkdirSync7(dirname10(outputFilePath), { recursive: true });
|
|
30098
30172
|
}
|
|
30099
30173
|
appendFileSync(outputFilePath, JSON.stringify(record) + "\n");
|
|
30100
30174
|
if (options.resetAfterFlush !== false) {
|
|
@@ -30104,7 +30178,7 @@ function flushAutoCompactTelemetrySnapshot(options = {}) {
|
|
|
30104
30178
|
}
|
|
30105
30179
|
|
|
30106
30180
|
// src/services/telemetry/conversationTrackerTelemetryPersistence.ts
|
|
30107
|
-
import { appendFileSync as appendFileSync2, existsSync as existsSync19, mkdirSync as
|
|
30181
|
+
import { appendFileSync as appendFileSync2, existsSync as existsSync19, mkdirSync as mkdirSync8 } from "fs";
|
|
30108
30182
|
import { dirname as dirname11 } from "path";
|
|
30109
30183
|
|
|
30110
30184
|
// src/utils/session/conversationTrackerTelemetrySink.ts
|
|
@@ -30156,9 +30230,9 @@ function createConversationTrackerTelemetrySink() {
|
|
|
30156
30230
|
// src/services/telemetry/conversationTrackerTelemetryCollector.ts
|
|
30157
30231
|
var CONVERSATION_TRACKER_SINK_LISTENER_ID = "conversation-tracker-telemetry-sink";
|
|
30158
30232
|
var conversationTrackerSink = createConversationTrackerTelemetrySink();
|
|
30159
|
-
var
|
|
30233
|
+
var sinkRegistered2 = false;
|
|
30160
30234
|
function ensureConversationTrackerTelemetryRegistered() {
|
|
30161
|
-
if (
|
|
30235
|
+
if (sinkRegistered2) return;
|
|
30162
30236
|
registerTelemetryListener(CONVERSATION_TRACKER_SINK_LISTENER_ID, (event) => {
|
|
30163
30237
|
if (event.channel !== "conversation_tracker") return;
|
|
30164
30238
|
conversationTrackerSink.push({
|
|
@@ -30166,7 +30240,7 @@ function ensureConversationTrackerTelemetryRegistered() {
|
|
|
30166
30240
|
data: event.data
|
|
30167
30241
|
});
|
|
30168
30242
|
});
|
|
30169
|
-
|
|
30243
|
+
sinkRegistered2 = true;
|
|
30170
30244
|
}
|
|
30171
30245
|
function getConversationTrackerTelemetrySnapshot() {
|
|
30172
30246
|
ensureConversationTrackerTelemetryRegistered();
|
|
@@ -30238,7 +30312,7 @@ function flushConversationTrackerTelemetrySnapshot(options = {}) {
|
|
|
30238
30312
|
})
|
|
30239
30313
|
};
|
|
30240
30314
|
if (!existsSync19(dirname11(outputFilePath))) {
|
|
30241
|
-
|
|
30315
|
+
mkdirSync8(dirname11(outputFilePath), { recursive: true });
|
|
30242
30316
|
}
|
|
30243
30317
|
appendFileSync2(outputFilePath, JSON.stringify(record) + "\n");
|
|
30244
30318
|
if (options.resetAfterFlush !== false) {
|
|
@@ -30247,6 +30321,54 @@ function flushConversationTrackerTelemetrySnapshot(options = {}) {
|
|
|
30247
30321
|
return record;
|
|
30248
30322
|
}
|
|
30249
30323
|
|
|
30324
|
+
// src/services/telemetry/taskBoundaryTelemetryPersistence.ts
|
|
30325
|
+
import { appendFileSync as appendFileSync3, existsSync as existsSync20, mkdirSync as mkdirSync9 } from "fs";
|
|
30326
|
+
import { dirname as dirname12 } from "path";
|
|
30327
|
+
function getTaskBoundaryTelemetryOutputFilePath() {
|
|
30328
|
+
return resolveXdgCachePath("telemetry/task-boundary-metrics.jsonl");
|
|
30329
|
+
}
|
|
30330
|
+
function asCount(value) {
|
|
30331
|
+
return value ?? 0;
|
|
30332
|
+
}
|
|
30333
|
+
function flushTaskBoundaryTelemetrySnapshot(options = {}) {
|
|
30334
|
+
const snapshot = getTaskBoundaryTelemetrySnapshot();
|
|
30335
|
+
if (snapshot.eventCount <= 0) return null;
|
|
30336
|
+
const outputFilePath = options.outputFilePath ?? getTaskBoundaryTelemetryOutputFilePath();
|
|
30337
|
+
const watchSkipCount = asCount(
|
|
30338
|
+
snapshot.phaseCounts.TASK_WATCH_SKIP_MISSING_LIST_DIR
|
|
30339
|
+
);
|
|
30340
|
+
const updateNotFoundCount = asCount(
|
|
30341
|
+
snapshot.phaseCounts.TASK_UPDATE_NOT_FOUND_NO_SIDE_EFFECT
|
|
30342
|
+
);
|
|
30343
|
+
const rebuildRejectedCount = asCount(
|
|
30344
|
+
snapshot.phaseCounts.TASK_REBUILD_MISSING_LIST_DIR_REJECTED
|
|
30345
|
+
);
|
|
30346
|
+
const autoCreatedCount = asCount(
|
|
30347
|
+
snapshot.phaseCounts.TASK_LIST_DIR_AUTO_CREATED_WITHOUT_CREATE
|
|
30348
|
+
);
|
|
30349
|
+
const record = {
|
|
30350
|
+
timestamp: Date.now(),
|
|
30351
|
+
requestId: options.requestId,
|
|
30352
|
+
agentId: options.agentId ?? "main",
|
|
30353
|
+
eventCount: snapshot.eventCount,
|
|
30354
|
+
phaseCounts: snapshot.phaseCounts,
|
|
30355
|
+
metrics: {
|
|
30356
|
+
watch_skip_due_to_missing_list_dir_count: watchSkipCount,
|
|
30357
|
+
update_not_found_without_side_effect_count: updateNotFoundCount,
|
|
30358
|
+
rebuild_missing_list_dir_rejected_count: rebuildRejectedCount,
|
|
30359
|
+
empty_list_dir_auto_created_count: autoCreatedCount
|
|
30360
|
+
}
|
|
30361
|
+
};
|
|
30362
|
+
if (!existsSync20(dirname12(outputFilePath))) {
|
|
30363
|
+
mkdirSync9(dirname12(outputFilePath), { recursive: true });
|
|
30364
|
+
}
|
|
30365
|
+
appendFileSync3(outputFilePath, JSON.stringify(record) + "\n");
|
|
30366
|
+
if (options.resetAfterFlush !== false) {
|
|
30367
|
+
resetTaskBoundaryTelemetry();
|
|
30368
|
+
}
|
|
30369
|
+
return record;
|
|
30370
|
+
}
|
|
30371
|
+
|
|
30250
30372
|
// src/services/ai/streamTyped/projector.ts
|
|
30251
30373
|
function supportsRichToolResultByProvider(provider) {
|
|
30252
30374
|
return String(provider ?? "").trim().toLowerCase() === "anthropic";
|
|
@@ -32646,6 +32768,10 @@ async function* runQuerySessionRuntimeLoop(messages, systemPrompt, context, canU
|
|
|
32646
32768
|
requestId: currentRequest?.id,
|
|
32647
32769
|
agentId: toolUseContext?.agentId
|
|
32648
32770
|
});
|
|
32771
|
+
flushTaskBoundaryTelemetrySnapshot({
|
|
32772
|
+
requestId: currentRequest?.id,
|
|
32773
|
+
agentId: toolUseContext?.agentId
|
|
32774
|
+
});
|
|
32649
32775
|
if (Number.isFinite(Number(telemetryRecord?.metrics?.typed_primary_path_rate))) {
|
|
32650
32776
|
logUserFriendly("SESSION_READ_PATH_METRICS", {
|
|
32651
32777
|
requestId: currentRequest?.id,
|
|
@@ -33884,7 +34010,7 @@ async function getAvailableTools() {
|
|
|
33884
34010
|
|
|
33885
34011
|
// src/commands/agents/storage.ts
|
|
33886
34012
|
import {
|
|
33887
|
-
existsSync as
|
|
34013
|
+
existsSync as existsSync21,
|
|
33888
34014
|
mkdirSync as mkdirSync10,
|
|
33889
34015
|
renameSync as renameSync3,
|
|
33890
34016
|
unlinkSync as unlinkSync2,
|
|
@@ -33896,7 +34022,7 @@ import { homedir as homedir8 } from "os";
|
|
|
33896
34022
|
// src/commands/agents/generation.ts
|
|
33897
34023
|
import { randomUUID as randomUUID6 } from "crypto";
|
|
33898
34024
|
async function generateAgentWithClaude(prompt) {
|
|
33899
|
-
const { queryModel } = await import("./llm-
|
|
34025
|
+
const { queryModel } = await import("./llm-6XIL53O7.js");
|
|
33900
34026
|
const systemPrompt = `You are an expert at creating AI agent configurations. Based on the user's description, generate a specialized agent configuration.
|
|
33901
34027
|
|
|
33902
34028
|
Return your response as a JSON object with exactly these fields:
|
|
@@ -34098,7 +34224,7 @@ function getLegacyAgentFilePath(location, agentType) {
|
|
|
34098
34224
|
}
|
|
34099
34225
|
function ensureDirectoryExists(location) {
|
|
34100
34226
|
const dir = getAgentDirectory(location);
|
|
34101
|
-
if (!
|
|
34227
|
+
if (!existsSync21(dir)) {
|
|
34102
34228
|
mkdirSync10(dir, { recursive: true });
|
|
34103
34229
|
}
|
|
34104
34230
|
return dir;
|
|
@@ -34107,7 +34233,7 @@ async function saveAgent(location, agentType, description3, tools, systemPrompt,
|
|
|
34107
34233
|
ensureDirectoryExists(location);
|
|
34108
34234
|
const filePath = getPrimaryAgentFilePath(location, agentType);
|
|
34109
34235
|
const legacyPath = getLegacyAgentFilePath(location, agentType);
|
|
34110
|
-
if (throwIfExists && (
|
|
34236
|
+
if (throwIfExists && (existsSync21(filePath) || existsSync21(legacyPath))) {
|
|
34111
34237
|
throw new Error(`Agent file already exists: ${filePath}`);
|
|
34112
34238
|
}
|
|
34113
34239
|
const tempFile = `${filePath}.tmp.${Date.now()}.${Math.random().toString(36).substr(2, 9)}`;
|
|
@@ -34122,7 +34248,7 @@ async function saveAgent(location, agentType, description3, tools, systemPrompt,
|
|
|
34122
34248
|
);
|
|
34123
34249
|
try {
|
|
34124
34250
|
writeFileSync6(tempFile, content, { encoding: "utf-8", flag: "wx" });
|
|
34125
|
-
if (throwIfExists && (
|
|
34251
|
+
if (throwIfExists && (existsSync21(filePath) || existsSync21(legacyPath))) {
|
|
34126
34252
|
try {
|
|
34127
34253
|
unlinkSync2(tempFile);
|
|
34128
34254
|
} catch {
|
|
@@ -34132,7 +34258,7 @@ async function saveAgent(location, agentType, description3, tools, systemPrompt,
|
|
|
34132
34258
|
renameSync3(tempFile, filePath);
|
|
34133
34259
|
} catch (error) {
|
|
34134
34260
|
try {
|
|
34135
|
-
if (
|
|
34261
|
+
if (existsSync21(tempFile)) {
|
|
34136
34262
|
unlinkSync2(tempFile);
|
|
34137
34263
|
}
|
|
34138
34264
|
} catch (cleanupError) {
|
|
@@ -34160,7 +34286,7 @@ async function updateAgent(agent, description3, tools, systemPrompt, color, mode
|
|
|
34160
34286
|
const location = agent.location;
|
|
34161
34287
|
const primaryPath = getPrimaryAgentFilePath(location, agent.agentType);
|
|
34162
34288
|
const legacyPath = getLegacyAgentFilePath(location, agent.agentType);
|
|
34163
|
-
const filePath =
|
|
34289
|
+
const filePath = existsSync21(primaryPath) ? primaryPath : existsSync21(legacyPath) ? legacyPath : primaryPath;
|
|
34164
34290
|
ensureDirectoryExists(location);
|
|
34165
34291
|
writeFileSync6(filePath, content, { encoding: "utf-8", flag: "w" });
|
|
34166
34292
|
}
|
|
@@ -34171,10 +34297,10 @@ async function deleteAgent(agent) {
|
|
|
34171
34297
|
const location = agent.location;
|
|
34172
34298
|
const primaryPath = getPrimaryAgentFilePath(location, agent.agentType);
|
|
34173
34299
|
const legacyPath = getLegacyAgentFilePath(location, agent.agentType);
|
|
34174
|
-
if (
|
|
34300
|
+
if (existsSync21(primaryPath)) {
|
|
34175
34301
|
unlinkSync2(primaryPath);
|
|
34176
34302
|
}
|
|
34177
|
-
if (
|
|
34303
|
+
if (existsSync21(legacyPath)) {
|
|
34178
34304
|
unlinkSync2(legacyPath);
|
|
34179
34305
|
}
|
|
34180
34306
|
}
|