pybao-cli 1.5.7 → 1.5.9
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-FDBOFOZN.js +50 -0
- package/dist/{acp-2LMTSBAU.js → acp-TKO6ZSSV.js} +54 -36
- package/dist/acp-TKO6ZSSV.js.map +7 -0
- package/dist/{agentsValidate-YQSHYCYC.js → agentsValidate-RDNLI7GA.js} +7 -7
- package/dist/{ask-4Z4LH5IS.js → ask-KTXMYPIA.js} +60 -34
- package/dist/ask-KTXMYPIA.js.map +7 -0
- package/dist/{autoUpdater-UTX7ZX2N.js → autoUpdater-53BZ6QWD.js} +3 -3
- package/dist/{chunk-OY6SB5B3.js → chunk-276RV4DQ.js} +4 -4
- package/dist/{chunk-7FFBXWS3.js → chunk-35X2VS4L.js} +3 -3
- package/dist/{chunk-VZDDKAL2.js → chunk-4C2CGHBI.js} +2 -2
- package/dist/{chunk-Y2RSIF7P.js → chunk-4KPVE4K7.js} +1 -1
- package/dist/{chunk-SDKYJZWD.js → chunk-57GJQMFS.js} +2 -2
- package/dist/{chunk-3JH34RBY.js → chunk-6PXEXL7C.js} +2 -2
- package/dist/{chunk-IKMMFSNJ.js → chunk-AMQ6XZOU.js} +1 -1
- package/dist/{chunk-W4PXRGP3.js → chunk-AWRDD6BG.js} +18 -1
- package/dist/chunk-AWRDD6BG.js.map +7 -0
- package/dist/{chunk-5JKCAVMI.js → chunk-BZGQQ4WZ.js} +3 -3
- package/dist/{chunk-4BFEUSKN.js → chunk-CATWZQ3R.js} +2 -2
- package/dist/{chunk-EGJRWKZ6.js → chunk-CPLMSZ63.js} +4 -4
- package/dist/{chunk-PI5RBPFA.js → chunk-DA6NJEFI.js} +2 -2
- package/dist/{chunk-IFC2PLAM.js → chunk-E35YJNX2.js} +4 -4
- package/dist/{chunk-TIMEEE5U.js → chunk-G7DKRXDS.js} +1 -4
- package/dist/{chunk-5F6IQJHF.js → chunk-HIJYNCCN.js} +1 -1
- package/dist/{chunk-F7HYDAWW.js → chunk-JE43CQYI.js} +3 -3
- package/dist/{chunk-JEAXJP2E.js → chunk-JLC2I3EY.js} +1 -1
- package/dist/chunk-JRMAK4PK.js +926 -0
- package/dist/chunk-JRMAK4PK.js.map +7 -0
- package/dist/{chunk-KLD4WAB6.js → chunk-KNLP4UO6.js} +4 -4
- package/dist/chunk-L3R7MPZU.js +81 -0
- package/dist/{chunk-ZD6NMP33.js.map → chunk-L3R7MPZU.js.map} +1 -1
- package/dist/{chunk-PMYMUSB4.js → chunk-LEYWQQ7V.js} +3 -3
- package/dist/{chunk-EN7L7JWN.js → chunk-LIOZM4KE.js} +1 -1
- package/dist/chunk-OC5CZWBQ.js.map +7 -0
- package/dist/{chunk-SWNNPHFY.js → chunk-PH6DPTO3.js} +2025 -1321
- package/dist/chunk-PH6DPTO3.js.map +7 -0
- package/dist/{chunk-CJ2YYIJN.js → chunk-PPFVOBEG.js} +144 -76
- package/dist/chunk-PPFVOBEG.js.map +7 -0
- package/dist/{chunk-4R7NUADF.js → chunk-Q5EZLUFC.js} +1 -1
- package/dist/{chunk-LYMH46VN.js → chunk-QMN64ICT.js} +3 -3
- package/dist/{chunk-VBV5RHIK.js → chunk-R4ZEH3KJ.js} +1 -1
- package/dist/{chunk-TKEWBSVM.js → chunk-SNASBZ2C.js} +3 -3
- package/dist/chunk-T7P3SSAQ.js +78 -0
- package/dist/chunk-T7P3SSAQ.js.map +7 -0
- package/dist/{chunk-T7UTA73F.js → chunk-TLZS274Y.js} +3 -3
- package/dist/{chunk-IOP3VA4X.js → chunk-YSL5H7NJ.js} +2 -2
- package/dist/{chunk-HFVRQO2J.js → chunk-YTEQEQ56.js} +48 -40
- package/dist/chunk-YTEQEQ56.js.map +7 -0
- package/dist/{cli-N3Q4D4BW.js → cli-LYWCNPC6.js} +131 -102
- package/dist/cli-LYWCNPC6.js.map +7 -0
- package/dist/commands-DYXAWJO6.js +54 -0
- package/dist/{config-GZXNPIIG.js → config-66BMMOES.js} +4 -4
- package/dist/{context-TUO5CUR3.js → context-PG7YTQCJ.js} +6 -6
- package/dist/conversationPersistence-DB6IUU2I.js +13 -0
- package/dist/{conversationTracker-APB6PR5Z.js → conversationTracker-WG3J56PX.js} +4 -3
- package/dist/{customCommands-J4DV6OI5.js → customCommands-XDKUVT73.js} +4 -4
- package/dist/{env-YBYEMHYQ.js → env-FW74XJHK.js} +2 -2
- package/dist/{file-KIBY6XZX.js → file-U2NXQ6RC.js} +4 -4
- package/dist/index.js +3 -3
- package/dist/{llm-T7C6QJWB.js → llm-6VJMMPDO.js} +416 -49
- package/dist/llm-6VJMMPDO.js.map +7 -0
- package/dist/{llmLazy-FDVUCPDQ.js → llmLazy-LYGZWC7G.js} +1 -1
- package/dist/{loader-QCHS455W.js → loader-DMZVU2XJ.js} +4 -4
- package/dist/{lsp-TE2SQ6CO.js → lsp-6LNF5DQB.js} +6 -6
- package/dist/{lspAnchor-IZ7YQJ64.js → lspAnchor-SF5Y7ZJT.js} +6 -6
- package/dist/{mcp-PLAWUZOQ.js → mcp-NLDX3RQE.js} +7 -7
- package/dist/{mentionProcessor-2O3AMZHB.js → mentionProcessor-BMX6VGRH.js} +5 -5
- package/dist/{messages-ZHFZ2OOG.js → messages-OTQ6IJM5.js} +9 -5
- package/dist/{model-GBC2PBVJ.js → model-KWGEASLY.js} +5 -5
- package/dist/{openai-2V2J23AE.js → openai-XIRWQY5H.js} +5 -5
- package/dist/{outputStyles-WD4VD4GZ.js → outputStyles-HKYM5C76.js} +4 -4
- package/dist/{pluginRuntime-WNZS26EV.js → pluginRuntime-25Y2MVIN.js} +6 -6
- package/dist/{pluginValidation-YP7MW35I.js → pluginValidation-CIJIQKGB.js} +6 -6
- package/dist/prompts-WH3VEHH6.js +56 -0
- package/dist/{pybAgentSessionLoad-YABCHELS.js → pybAgentSessionLoad-TF3BFX4S.js} +4 -4
- package/dist/{pybAgentSessionResume-C3LNSFQL.js → pybAgentSessionResume-Y5JO4GLH.js} +4 -4
- package/dist/{pybAgentStreamJsonSession-DFOGLEOB.js → pybAgentStreamJsonSession-46VLF4QN.js} +4 -3
- package/dist/pybAgentStreamJsonSession-46VLF4QN.js.map +7 -0
- package/dist/{pybHooks-LGGIB5PJ.js → pybHooks-LZPU4EF6.js} +4 -4
- package/dist/query-4B3GTPBN.js +58 -0
- package/dist/{registry-EYMCKHRG.js → registry-6LUE7ZWC.js} +5 -5
- package/dist/{ripgrep-JZN2MVSK.js → ripgrep-KVB55D22.js} +3 -3
- package/dist/{skillMarketplace-ETYXMAXF.js → skillMarketplace-2IVEPC2E.js} +3 -3
- package/dist/{state-MAVHRDNE.js → state-OGBESWFS.js} +2 -2
- package/dist/{theme-AUEZ6SNA.js → theme-QQ2SCFEK.js} +5 -5
- package/dist/{toolPermissionSettings-7JZYBUZC.js → toolPermissionSettings-ZGGPBK6S.js} +6 -6
- package/dist/tools-UXPFIHD4.js +55 -0
- package/dist/tools-UXPFIHD4.js.map +7 -0
- package/dist/{userInput-V6RU4BEQ.js → userInput-75VCTJDE.js} +76 -49
- package/dist/userInput-75VCTJDE.js.map +7 -0
- package/package.json +18 -1
- package/dist/REPL-YW6AH5YU.js +0 -49
- package/dist/acp-2LMTSBAU.js.map +0 -7
- package/dist/ask-4Z4LH5IS.js.map +0 -7
- package/dist/chunk-CJ2YYIJN.js.map +0 -7
- package/dist/chunk-HFVRQO2J.js.map +0 -7
- package/dist/chunk-O6DTZU7F.js.map +0 -7
- package/dist/chunk-SWNNPHFY.js.map +0 -7
- package/dist/chunk-W4PXRGP3.js.map +0 -7
- package/dist/chunk-YNGGZILT.js +0 -516
- package/dist/chunk-YNGGZILT.js.map +0 -7
- package/dist/chunk-ZD6NMP33.js +0 -240
- package/dist/cli-N3Q4D4BW.js.map +0 -7
- package/dist/commands-OOINF26E.js +0 -53
- package/dist/llm-T7C6QJWB.js.map +0 -7
- package/dist/prompts-QPYUI6SX.js +0 -55
- package/dist/pybAgentStreamJsonSession-DFOGLEOB.js.map +0 -7
- package/dist/query-EC6HGBDS.js +0 -57
- package/dist/tools-3JFVDDSZ.js +0 -54
- package/dist/userInput-V6RU4BEQ.js.map +0 -7
- /package/dist/{REPL-YW6AH5YU.js.map → REPL-FDBOFOZN.js.map} +0 -0
- /package/dist/{agentsValidate-YQSHYCYC.js.map → agentsValidate-RDNLI7GA.js.map} +0 -0
- /package/dist/{autoUpdater-UTX7ZX2N.js.map → autoUpdater-53BZ6QWD.js.map} +0 -0
- /package/dist/{chunk-OY6SB5B3.js.map → chunk-276RV4DQ.js.map} +0 -0
- /package/dist/{chunk-7FFBXWS3.js.map → chunk-35X2VS4L.js.map} +0 -0
- /package/dist/{chunk-VZDDKAL2.js.map → chunk-4C2CGHBI.js.map} +0 -0
- /package/dist/{chunk-Y2RSIF7P.js.map → chunk-4KPVE4K7.js.map} +0 -0
- /package/dist/{chunk-SDKYJZWD.js.map → chunk-57GJQMFS.js.map} +0 -0
- /package/dist/{chunk-3JH34RBY.js.map → chunk-6PXEXL7C.js.map} +0 -0
- /package/dist/{chunk-IKMMFSNJ.js.map → chunk-AMQ6XZOU.js.map} +0 -0
- /package/dist/{chunk-5JKCAVMI.js.map → chunk-BZGQQ4WZ.js.map} +0 -0
- /package/dist/{chunk-4BFEUSKN.js.map → chunk-CATWZQ3R.js.map} +0 -0
- /package/dist/{chunk-EGJRWKZ6.js.map → chunk-CPLMSZ63.js.map} +0 -0
- /package/dist/{chunk-PI5RBPFA.js.map → chunk-DA6NJEFI.js.map} +0 -0
- /package/dist/{chunk-IFC2PLAM.js.map → chunk-E35YJNX2.js.map} +0 -0
- /package/dist/{chunk-TIMEEE5U.js.map → chunk-G7DKRXDS.js.map} +0 -0
- /package/dist/{chunk-5F6IQJHF.js.map → chunk-HIJYNCCN.js.map} +0 -0
- /package/dist/{chunk-F7HYDAWW.js.map → chunk-JE43CQYI.js.map} +0 -0
- /package/dist/{chunk-JEAXJP2E.js.map → chunk-JLC2I3EY.js.map} +0 -0
- /package/dist/{chunk-KLD4WAB6.js.map → chunk-KNLP4UO6.js.map} +0 -0
- /package/dist/{chunk-PMYMUSB4.js.map → chunk-LEYWQQ7V.js.map} +0 -0
- /package/dist/{chunk-EN7L7JWN.js.map → chunk-LIOZM4KE.js.map} +0 -0
- /package/dist/{chunk-O6DTZU7F.js → chunk-OC5CZWBQ.js} +0 -0
- /package/dist/{chunk-4R7NUADF.js.map → chunk-Q5EZLUFC.js.map} +0 -0
- /package/dist/{chunk-LYMH46VN.js.map → chunk-QMN64ICT.js.map} +0 -0
- /package/dist/{chunk-VBV5RHIK.js.map → chunk-R4ZEH3KJ.js.map} +0 -0
- /package/dist/{chunk-TKEWBSVM.js.map → chunk-SNASBZ2C.js.map} +0 -0
- /package/dist/{chunk-T7UTA73F.js.map → chunk-TLZS274Y.js.map} +0 -0
- /package/dist/{chunk-IOP3VA4X.js.map → chunk-YSL5H7NJ.js.map} +0 -0
- /package/dist/{commands-OOINF26E.js.map → commands-DYXAWJO6.js.map} +0 -0
- /package/dist/{config-GZXNPIIG.js.map → config-66BMMOES.js.map} +0 -0
- /package/dist/{context-TUO5CUR3.js.map → context-PG7YTQCJ.js.map} +0 -0
- /package/dist/{conversationTracker-APB6PR5Z.js.map → conversationPersistence-DB6IUU2I.js.map} +0 -0
- /package/dist/{customCommands-J4DV6OI5.js.map → conversationTracker-WG3J56PX.js.map} +0 -0
- /package/dist/{env-YBYEMHYQ.js.map → customCommands-XDKUVT73.js.map} +0 -0
- /package/dist/{file-KIBY6XZX.js.map → env-FW74XJHK.js.map} +0 -0
- /package/dist/{llmLazy-FDVUCPDQ.js.map → file-U2NXQ6RC.js.map} +0 -0
- /package/dist/{loader-QCHS455W.js.map → llmLazy-LYGZWC7G.js.map} +0 -0
- /package/dist/{lsp-TE2SQ6CO.js.map → loader-DMZVU2XJ.js.map} +0 -0
- /package/dist/{mcp-PLAWUZOQ.js.map → lsp-6LNF5DQB.js.map} +0 -0
- /package/dist/{lspAnchor-IZ7YQJ64.js.map → lspAnchor-SF5Y7ZJT.js.map} +0 -0
- /package/dist/{messages-ZHFZ2OOG.js.map → mcp-NLDX3RQE.js.map} +0 -0
- /package/dist/{mentionProcessor-2O3AMZHB.js.map → mentionProcessor-BMX6VGRH.js.map} +0 -0
- /package/dist/{model-GBC2PBVJ.js.map → messages-OTQ6IJM5.js.map} +0 -0
- /package/dist/{openai-2V2J23AE.js.map → model-KWGEASLY.js.map} +0 -0
- /package/dist/{outputStyles-WD4VD4GZ.js.map → openai-XIRWQY5H.js.map} +0 -0
- /package/dist/{pluginValidation-YP7MW35I.js.map → outputStyles-HKYM5C76.js.map} +0 -0
- /package/dist/{pluginRuntime-WNZS26EV.js.map → pluginRuntime-25Y2MVIN.js.map} +0 -0
- /package/dist/{prompts-QPYUI6SX.js.map → pluginValidation-CIJIQKGB.js.map} +0 -0
- /package/dist/{pybAgentSessionLoad-YABCHELS.js.map → prompts-WH3VEHH6.js.map} +0 -0
- /package/dist/{pybAgentSessionResume-C3LNSFQL.js.map → pybAgentSessionLoad-TF3BFX4S.js.map} +0 -0
- /package/dist/{pybHooks-LGGIB5PJ.js.map → pybAgentSessionResume-Y5JO4GLH.js.map} +0 -0
- /package/dist/{query-EC6HGBDS.js.map → pybHooks-LZPU4EF6.js.map} +0 -0
- /package/dist/{registry-EYMCKHRG.js.map → query-4B3GTPBN.js.map} +0 -0
- /package/dist/{ripgrep-JZN2MVSK.js.map → registry-6LUE7ZWC.js.map} +0 -0
- /package/dist/{skillMarketplace-ETYXMAXF.js.map → ripgrep-KVB55D22.js.map} +0 -0
- /package/dist/{state-MAVHRDNE.js.map → skillMarketplace-2IVEPC2E.js.map} +0 -0
- /package/dist/{theme-AUEZ6SNA.js.map → state-OGBESWFS.js.map} +0 -0
- /package/dist/{toolPermissionSettings-7JZYBUZC.js.map → theme-QQ2SCFEK.js.map} +0 -0
- /package/dist/{tools-3JFVDDSZ.js.map → toolPermissionSettings-ZGGPBK6S.js.map} +0 -0
|
@@ -41,57 +41,58 @@ import {
|
|
|
41
41
|
runWithTaskListEnv,
|
|
42
42
|
runWithTaskListId,
|
|
43
43
|
updateTask
|
|
44
|
-
} from "./chunk-
|
|
44
|
+
} from "./chunk-PH6DPTO3.js";
|
|
45
45
|
import {
|
|
46
46
|
queryLLM
|
|
47
|
-
} from "./chunk-
|
|
47
|
+
} from "./chunk-KNLP4UO6.js";
|
|
48
48
|
import {
|
|
49
49
|
FallbackToolUseRejectedMessage,
|
|
50
50
|
MCPTool,
|
|
51
51
|
getClients,
|
|
52
52
|
getMCPTools
|
|
53
|
-
} from "./chunk-
|
|
53
|
+
} from "./chunk-276RV4DQ.js";
|
|
54
54
|
import {
|
|
55
55
|
emitReminderEvent
|
|
56
|
-
} from "./chunk-
|
|
56
|
+
} from "./chunk-YSL5H7NJ.js";
|
|
57
57
|
import {
|
|
58
58
|
getActiveAgents,
|
|
59
59
|
getAgentByType,
|
|
60
60
|
getAvailableAgentTypes
|
|
61
|
-
} from "./chunk-
|
|
61
|
+
} from "./chunk-DA6NJEFI.js";
|
|
62
62
|
import {
|
|
63
63
|
INTERRUPT_MESSAGE,
|
|
64
64
|
createAssistantMessage,
|
|
65
|
-
|
|
65
|
+
createUserMessageFromBlocks,
|
|
66
|
+
createUserMessageFromText,
|
|
66
67
|
getLastAssistantMessageId
|
|
67
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-JRMAK4PK.js";
|
|
68
69
|
import {
|
|
69
70
|
formatDuration,
|
|
70
71
|
formatNumber
|
|
71
72
|
} from "./chunk-OUXHGDLH.js";
|
|
72
73
|
import {
|
|
73
74
|
getAbsolutePath
|
|
74
|
-
} from "./chunk-
|
|
75
|
+
} from "./chunk-57GJQMFS.js";
|
|
75
76
|
import {
|
|
76
77
|
LspFacade,
|
|
77
78
|
formatDiagnosticsPretty
|
|
78
|
-
} from "./chunk-
|
|
79
|
+
} from "./chunk-CPLMSZ63.js";
|
|
79
80
|
import {
|
|
80
81
|
getModelManager
|
|
81
|
-
} from "./chunk-
|
|
82
|
+
} from "./chunk-QMN64ICT.js";
|
|
82
83
|
import {
|
|
83
84
|
getContext
|
|
84
|
-
} from "./chunk-
|
|
85
|
+
} from "./chunk-E35YJNX2.js";
|
|
85
86
|
import {
|
|
86
87
|
filesToTree,
|
|
87
88
|
ripGrepWithStatus
|
|
88
|
-
} from "./chunk-
|
|
89
|
+
} from "./chunk-LIOZM4KE.js";
|
|
89
90
|
import {
|
|
90
91
|
getTheme
|
|
91
|
-
} from "./chunk-
|
|
92
|
+
} from "./chunk-4KPVE4K7.js";
|
|
92
93
|
import {
|
|
93
94
|
debug
|
|
94
|
-
} from "./chunk-
|
|
95
|
+
} from "./chunk-AMQ6XZOU.js";
|
|
95
96
|
import {
|
|
96
97
|
BunShell,
|
|
97
98
|
MEMORY_DIR,
|
|
@@ -103,7 +104,7 @@ import {
|
|
|
103
104
|
overwriteLog,
|
|
104
105
|
readTaskOutput,
|
|
105
106
|
resolveXdgDataPath
|
|
106
|
-
} from "./chunk-
|
|
107
|
+
} from "./chunk-G7DKRXDS.js";
|
|
107
108
|
|
|
108
109
|
// src/tools/index.ts
|
|
109
110
|
import { memoize as memoize2 } from "lodash-es";
|
|
@@ -404,7 +405,7 @@ ${output.expertAnswer}`;
|
|
|
404
405
|
let systemMessages;
|
|
405
406
|
try {
|
|
406
407
|
systemMessages = messages.map(
|
|
407
|
-
(msg) => msg.role === "user" ?
|
|
408
|
+
(msg) => msg.role === "user" ? createUserMessageFromText(msg.content) : createAssistantMessage(msg.content)
|
|
408
409
|
);
|
|
409
410
|
} catch (error) {
|
|
410
411
|
logError(error);
|
|
@@ -701,6 +702,8 @@ var PROMPT = `- Retrieves output from a running or completed task (background sh
|
|
|
701
702
|
- Works with all task types: background shells, async agents, and remote sessions`;
|
|
702
703
|
|
|
703
704
|
// src/tools/system/TaskOutputTool/TaskOutputTool.tsx
|
|
705
|
+
var TOOL_PROGRESS_OPEN_TAG = ["<tool", "-progress>"].join("");
|
|
706
|
+
var TOOL_PROGRESS_CLOSE_TAG = ["</tool", "-progress>"].join("");
|
|
704
707
|
var inputSchema2 = z2.strictObject({
|
|
705
708
|
task_id: z2.string().describe("The task ID to get output from"),
|
|
706
709
|
block: z2.boolean().optional().default(true).describe("Whether to wait for completion"),
|
|
@@ -782,7 +785,7 @@ async function analyzeOutputWithLsp(output, exitCode) {
|
|
|
782
785
|
if (exitCode !== 0 || errorCount > 0 || warningCount > 0) {
|
|
783
786
|
try {
|
|
784
787
|
const { isAbsolute: isAbsolute3, resolve: resolve4 } = await import("path");
|
|
785
|
-
const { getSessionRoot: getSessionRoot2 } = await import("./state-
|
|
788
|
+
const { getSessionRoot: getSessionRoot2 } = await import("./state-OGBESWFS.js");
|
|
786
789
|
const lines = output.split("\n");
|
|
787
790
|
const uniqueFiles = /* @__PURE__ */ new Set();
|
|
788
791
|
const lspSuggestions = [];
|
|
@@ -981,8 +984,8 @@ ${output.task.output.trimEnd()}
|
|
|
981
984
|
yield {
|
|
982
985
|
type: "progress",
|
|
983
986
|
content: createAssistantMessage(
|
|
984
|
-
|
|
985
|
-
` : ""} Waiting for task (esc to give additional instructions)
|
|
987
|
+
`${TOOL_PROGRESS_OPEN_TAG}${initial.description ? ` ${initial.description}
|
|
988
|
+
` : ""} Waiting for task (esc to give additional instructions)${TOOL_PROGRESS_CLOSE_TAG}`
|
|
986
989
|
)
|
|
987
990
|
};
|
|
988
991
|
let finalTask = null;
|
|
@@ -1049,9 +1052,6 @@ Usage:
|
|
|
1049
1052
|
- The file_paths parameter must be an array of absolute paths.
|
|
1050
1053
|
- Supports recursive deletion for directories (be careful!).
|
|
1051
1054
|
- Safe and cross-platform (works on Windows/Linux/Mac).
|
|
1052
|
-
- **Safety Check**: The tool automatically performs a reference check using LSP. If a file is referenced by other files, the deletion will be BLOCKED.
|
|
1053
|
-
- **Forcing Deletion**: If you are sure about deleting a referenced file (e.g., refactoring), set \`force: true\` to bypass the safety check.
|
|
1054
|
-
- If LSP reference checks are unavailable, deletion may be blocked unless \`force: true\` is used after manual dependency verification.
|
|
1055
1055
|
- Do NOT use BashTool/RunCommand with 'rm', 'del', or 'rmdir'.
|
|
1056
1056
|
|
|
1057
1057
|
Examples:
|
|
@@ -1088,7 +1088,7 @@ Delete({
|
|
|
1088
1088
|
]
|
|
1089
1089
|
})
|
|
1090
1090
|
</example_batch>
|
|
1091
|
-
|
|
1091
|
+
`.trim();
|
|
1092
1092
|
|
|
1093
1093
|
// src/tools/filesystem/DeleteTool/DeleteTool.tsx
|
|
1094
1094
|
var inputSchema3 = z3.strictObject({
|
|
@@ -1155,7 +1155,7 @@ var DeleteTool = {
|
|
|
1155
1155
|
}
|
|
1156
1156
|
if (!force) {
|
|
1157
1157
|
try {
|
|
1158
|
-
const { LspFacade: LspFacade2 } = await import("./lsp-
|
|
1158
|
+
const { LspFacade: LspFacade2 } = await import("./lsp-6LNF5DQB.js");
|
|
1159
1159
|
const referenceDetail = await LspFacade2.checkFileReferences(fullPath);
|
|
1160
1160
|
if (referenceDetail) {
|
|
1161
1161
|
failedItems.push(
|
|
@@ -1436,7 +1436,7 @@ info with statistics
|
|
|
1436
1436
|
// src/tools/lsTool/lsTool.tsx
|
|
1437
1437
|
var MAX_FILES_LIMIT = 0;
|
|
1438
1438
|
var TOP_LEVEL_LIMIT = 5e3;
|
|
1439
|
-
var DISPLAY_LINE_LIMIT =
|
|
1439
|
+
var DISPLAY_LINE_LIMIT = 0;
|
|
1440
1440
|
var isEnabledFlag = (raw, defaultValue = false) => {
|
|
1441
1441
|
const normalized = String(raw ?? "").trim().toLowerCase();
|
|
1442
1442
|
if (!normalized) return defaultValue;
|
|
@@ -1778,6 +1778,11 @@ This tool acts as your "Code Analyst". Use it to understand the codebase semanti
|
|
|
1778
1778
|
- **Action**: Use \`diagnostics\` with \`waitForDiagnostics: true\`.
|
|
1779
1779
|
- **Why**: It waits for the language server to re-analyze the file and returns fresh errors/warnings. This is your "Self-Correction" mechanism.
|
|
1780
1780
|
|
|
1781
|
+
### 7. Workspace Symbol Search (Where is this symbol?)
|
|
1782
|
+
- **Scenario**: You need to find a class or function across the entire project.
|
|
1783
|
+
- **Action**: Use \`workspaceSymbol\` with a query string and a scoped filePath (module or directory).
|
|
1784
|
+
- **Why**: It searches across all files in the scope. **Important**: Must provide a scoped path to avoid unbounded full-repo queries.
|
|
1785
|
+
|
|
1781
1786
|
## Supported Operations
|
|
1782
1787
|
|
|
1783
1788
|
### Location-Based Operations (require line + character)
|
|
@@ -1822,6 +1827,7 @@ Optional:
|
|
|
1822
1827
|
If the specified position is not on a valid symbol, the tool automatically searches for the nearest valid token:
|
|
1823
1828
|
- **Search scope**: Current line, then previous line, then next line
|
|
1824
1829
|
- **Priority**: Current line tokens are preferred (lower score)
|
|
1830
|
+
- **Skipped tokens**: Keywords (function, class, if, for, return, etc.) and operators (=, =>, +, -, &&, ||, etc.) are automatically skipped
|
|
1825
1831
|
- **If no valid token found**: Returns an error message
|
|
1826
1832
|
|
|
1827
1833
|
### Best Practice for Position
|
|
@@ -2462,7 +2468,9 @@ var SUBAGENT_DISALLOWED_TOOL_NAMES = /* @__PURE__ */ new Set([
|
|
|
2462
2468
|
"Task",
|
|
2463
2469
|
"TaskOutput",
|
|
2464
2470
|
"KillShell",
|
|
2465
|
-
"AskUserQuestion"
|
|
2471
|
+
"AskUserQuestion",
|
|
2472
|
+
"MemoryRead",
|
|
2473
|
+
"MemoryWrite"
|
|
2466
2474
|
]);
|
|
2467
2475
|
async function getTaskTools(safeMode) {
|
|
2468
2476
|
return (await (!safeMode ? getTools() : getReadOnlyTools())).filter(
|
|
@@ -2587,6 +2595,8 @@ function asyncLaunchMessage(agentId) {
|
|
|
2587
2595
|
return buildTaskAsyncPolicy(agentId);
|
|
2588
2596
|
}
|
|
2589
2597
|
var FORK_CONTEXT_TOOL_RESULT_TEXT = TASK_FORK_CONTEXT_POLICY;
|
|
2598
|
+
var TOOL_PROGRESS_OPEN_TAG2 = ["<tool", "-progress>"].join("");
|
|
2599
|
+
var TOOL_PROGRESS_CLOSE_TAG2 = ["</tool", "-progress>"].join("");
|
|
2590
2600
|
function normalizeAgentPermissionMode(mode) {
|
|
2591
2601
|
if (typeof mode !== "string") return void 0;
|
|
2592
2602
|
const trimmed = mode.trim();
|
|
@@ -2616,7 +2626,7 @@ function readJsonArrayFile(path) {
|
|
|
2616
2626
|
}
|
|
2617
2627
|
}
|
|
2618
2628
|
function buildForkContextForAgent(options) {
|
|
2619
|
-
const userPromptMessage =
|
|
2629
|
+
const userPromptMessage = createUserMessageFromText(options.prompt);
|
|
2620
2630
|
if (!options.enabled || !options.toolUseId) {
|
|
2621
2631
|
return {
|
|
2622
2632
|
forkContextMessages: [],
|
|
@@ -2665,7 +2675,7 @@ function buildForkContextForAgent(options) {
|
|
|
2665
2675
|
content: [taskToolUseBlock]
|
|
2666
2676
|
}
|
|
2667
2677
|
};
|
|
2668
|
-
const forkContextToolResult =
|
|
2678
|
+
const forkContextToolResult = createUserMessageFromBlocks(
|
|
2669
2679
|
[
|
|
2670
2680
|
{
|
|
2671
2681
|
type: "tool_result",
|
|
@@ -2981,7 +2991,7 @@ var TaskTool = {
|
|
|
2981
2991
|
() => getNextAvailableLogSidechainNumber(messageLogName, forkNumber)
|
|
2982
2992
|
);
|
|
2983
2993
|
const PROGRESS_THROTTLE_MS = 200;
|
|
2984
|
-
const MAX_RECENT_ACTIONS =
|
|
2994
|
+
const MAX_RECENT_ACTIONS = 2;
|
|
2985
2995
|
let lastProgressEmitAt = 0;
|
|
2986
2996
|
let lastEmittedToolUseCount = 0;
|
|
2987
2997
|
const recentActions = [];
|
|
@@ -3047,7 +3057,7 @@ var TaskTool = {
|
|
|
3047
3057
|
yield {
|
|
3048
3058
|
type: "progress",
|
|
3049
3059
|
content: createAssistantMessage(
|
|
3050
|
-
|
|
3060
|
+
`${TOOL_PROGRESS_OPEN_TAG2}${renderProgressText(0)}${TOOL_PROGRESS_CLOSE_TAG2}`
|
|
3051
3061
|
)
|
|
3052
3062
|
};
|
|
3053
3063
|
lastProgressEmitAt = Date.now();
|
|
@@ -3097,7 +3107,7 @@ var TaskTool = {
|
|
|
3097
3107
|
yield {
|
|
3098
3108
|
type: "progress",
|
|
3099
3109
|
content: createAssistantMessage(
|
|
3100
|
-
|
|
3110
|
+
`${TOOL_PROGRESS_OPEN_TAG2}${renderProgressText(toolUseCount)}${TOOL_PROGRESS_CLOSE_TAG2}`
|
|
3101
3111
|
)
|
|
3102
3112
|
};
|
|
3103
3113
|
lastEmittedToolUseCount = toolUseCount;
|
|
@@ -3159,7 +3169,6 @@ var metadataSchema = z9.record(jsonValueSchema);
|
|
|
3159
3169
|
function mapStatusToOutput(status) {
|
|
3160
3170
|
if (status === "done") return "completed";
|
|
3161
3171
|
if (status === "deleted") return "deleted";
|
|
3162
|
-
if (status === "blocked") return "pending";
|
|
3163
3172
|
return status;
|
|
3164
3173
|
}
|
|
3165
3174
|
function toTaskListItem(task) {
|
|
@@ -3261,7 +3270,7 @@ Preferred single-task template:
|
|
|
3261
3270
|
}
|
|
3262
3271
|
|
|
3263
3272
|
## Status Notes
|
|
3264
|
-
- Use
|
|
3273
|
+
- Use pending when dependencies prevent work and fill blockedBy.
|
|
3265
3274
|
|
|
3266
3275
|
## Examples of When to Use TaskCreate
|
|
3267
3276
|
|
|
@@ -3300,7 +3309,7 @@ User: Create just one task.
|
|
|
3300
3309
|
Assistant: I'll create a single task.
|
|
3301
3310
|
*Creates one task without auto dependency chaining*
|
|
3302
3311
|
</example>
|
|
3303
|
-
|
|
3312
|
+
`.trim();
|
|
3304
3313
|
|
|
3305
3314
|
// src/tools/interaction/TaskCreateTool/TaskCreateTool.tsx
|
|
3306
3315
|
var inputSchema9 = z10.strictObject({
|
|
@@ -3412,7 +3421,7 @@ User: Can you check the status of task t-17 before updating it?
|
|
|
3412
3421
|
Assistant: I'll fetch the task details first.
|
|
3413
3422
|
*Fetches task t-17*
|
|
3414
3423
|
</example>
|
|
3415
|
-
|
|
3424
|
+
`.trim();
|
|
3416
3425
|
|
|
3417
3426
|
// src/tools/interaction/TaskGetTool/TaskGetTool.tsx
|
|
3418
3427
|
var inputSchema10 = z11.strictObject({
|
|
@@ -3524,7 +3533,7 @@ User: We just added dependencies, can we see what's blocked now?
|
|
|
3524
3533
|
Assistant: I'll list tasks to show the updated ready/blocked breakdown.
|
|
3525
3534
|
*Lists tasks with ready/blocked breakdown*
|
|
3526
3535
|
</example>
|
|
3527
|
-
|
|
3536
|
+
`.trim();
|
|
3528
3537
|
|
|
3529
3538
|
// src/tools/interaction/TaskListTool/TaskListTool.tsx
|
|
3530
3539
|
var inputSchema11 = z12.strictObject({
|
|
@@ -3541,7 +3550,7 @@ var mapStatusFilterInput = (input) => {
|
|
|
3541
3550
|
if (!input) return void 0;
|
|
3542
3551
|
if (input === "completed") return ["done"];
|
|
3543
3552
|
if (input === "deleted") return ["deleted"];
|
|
3544
|
-
if (input === "pending") return ["pending"
|
|
3553
|
+
if (input === "pending") return ["pending"];
|
|
3545
3554
|
return ["in_progress"];
|
|
3546
3555
|
};
|
|
3547
3556
|
var TaskListTool = {
|
|
@@ -3645,7 +3654,7 @@ NOTE that TaskUpdate should be used when you need to persist task changes.
|
|
|
3645
3654
|
|
|
3646
3655
|
## Status Notes
|
|
3647
3656
|
- Use in_progress for the task you are actively working on.
|
|
3648
|
-
- Use
|
|
3657
|
+
- Use pending when dependencies prevent progress and set blockedBy.
|
|
3649
3658
|
- Use completed only when all dependencies are satisfied.
|
|
3650
3659
|
|
|
3651
3660
|
## Examples of When to Use TaskUpdate
|
|
@@ -3667,8 +3676,7 @@ User: We've finished adding dependencies and want to finalize the plan.
|
|
|
3667
3676
|
Assistant: I'll set metadata.planFinalized to trigger the global validation.
|
|
3668
3677
|
*Updates metadata.planFinalized to "true"*
|
|
3669
3678
|
</example>
|
|
3670
|
-
|
|
3671
|
-
`;
|
|
3679
|
+
`.trim();
|
|
3672
3680
|
|
|
3673
3681
|
// src/tools/interaction/TaskUpdateTool/TaskUpdateTool.tsx
|
|
3674
3682
|
var normalizeDeps = (items) => [...items ?? []].filter(Boolean).sort();
|