openfox 2.0.113 → 2.0.114
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/CHANGELOG.md +22 -0
- package/dist/CHANGELOG.md +22 -0
- package/dist/agent-defaults/builder.agent.md +1 -0
- package/dist/agent-defaults/planner.agent.md +1 -0
- package/dist/{backend-P3GHHLHJ.js → backend-LVYHLGQJ.js} +2 -2
- package/dist/{chat-handler-PEK5JDHO.js → chat-handler-KWXRSWXZ.js} +31 -25
- package/dist/{chunk-HKD4IMOE.js → chunk-2XD65L7M.js} +2 -2
- package/dist/{chunk-AZFZE36I.js → chunk-3O77NT4T.js} +17 -7
- package/dist/{chunk-HGOTZWON.js → chunk-7GWARYQC.js} +60 -1064
- package/dist/{chunk-YHEQTVFV.js → chunk-AZHWLLPP.js} +1 -1
- package/dist/{chunk-6UPBZ2ZR.js → chunk-BZVW77PI.js} +4 -4
- package/dist/{chunk-YGPPFVLJ.js → chunk-FW4NDUBL.js} +15 -15
- package/dist/{chunk-O2YSYW2F.js → chunk-GUHHUDNL.js} +6 -6
- package/dist/{chunk-WWTYWLDM.js → chunk-HP5CIB66.js} +2 -2
- package/dist/{chunk-ONONXV3N.js → chunk-HV6IALXF.js} +4 -4
- package/dist/{chunk-4NMGX5F2.js → chunk-I7FY2LTR.js} +2 -2
- package/dist/{chunk-Y64PEWKP.js → chunk-JP7NM545.js} +2 -2
- package/dist/{chunk-CP44U7BT.js → chunk-JXLRL5JR.js} +5 -5
- package/dist/{chunk-5VYSKVZT.js → chunk-K733B5T2.js} +254 -20
- package/dist/{chunk-SNLLOXCM.js → chunk-L63Q4JQJ.js} +3 -3
- package/dist/{chunk-43M7QZMX.js → chunk-LXYPMFTH.js} +3 -3
- package/dist/{chunk-TCGWZBTS.js → chunk-MUSPWEBB.js} +3 -3
- package/dist/chunk-NCZRWCJN.js +7 -0
- package/dist/{chunk-JR54MDZI.js → chunk-NLO64UE3.js} +2 -2
- package/dist/{chunk-3R43CMLS.js → chunk-NWJLWLKF.js} +8 -8
- package/dist/chunk-OSXPQSLW.js +128 -0
- package/dist/chunk-OTYAEEX3.js +1081 -0
- package/dist/{chunk-V4664YKR.js → chunk-OXSTNSCF.js} +2 -2
- package/dist/{chunk-R2MTWC7C.js → chunk-P5UANBBX.js} +6 -4
- package/dist/{chunk-PWXBIUEY.js → chunk-PBW3YC3G.js} +85 -1
- package/dist/{chunk-TEQEDOWI.js → chunk-QD7MRMCH.js} +245 -289
- package/dist/{chunk-BNFGDTEU.js → chunk-SA34STZ6.js} +2 -2
- package/dist/{chunk-VGRVPYZ5.js → chunk-SBSUDHL4.js} +2 -2
- package/dist/{chunk-XQR76MQ5.js → chunk-SFZGMB2G.js} +2 -2
- package/dist/{chunk-EC5T5A6O.js → chunk-TKKP56QK.js} +3 -3
- package/dist/{chunk-BYSUSSSC.js → chunk-UPBWEHIL.js} +30 -148
- package/dist/{chunk-YB6WYVNY.js → chunk-UTIQ7OO5.js} +2 -2
- package/dist/{chunk-EMI3YYLP.js → chunk-VPVLO436.js} +4 -4
- package/dist/chunk-W77NBJAZ.js +957 -0
- package/dist/{chunk-BKCW3JLL.js → chunk-X25Q6RAV.js} +1 -1
- package/dist/{chunk-FF2EKUQO.js → chunk-YGJIK3CG.js} +4 -4
- package/dist/cli/dev.js +1 -1
- package/dist/cli/index.js +1 -1
- package/dist/{client-3LJGD6KY.js → client-EM7ISGUP.js} +6 -6
- package/dist/{compactor-ZBNKANHV.js → compactor-V3LR7APW.js} +13 -12
- package/dist/{dynamic-context-F2XTQJR5.js → dynamic-context-MVGOF5V2.js} +10 -9
- package/dist/{events-224IO5NJ.js → events-PI7IMPHT.js} +8 -7
- package/dist/{folding-YTTTVS56.js → folding-FO57K4JM.js} +6 -5
- package/dist/http-client-33EZ3BLR.js +11 -0
- package/dist/{inspect-proxy-B7LGGTM7.js → inspect-proxy-NHKQQ2CD.js} +4 -4
- package/dist/launch-L5ROVNI3.js +52 -0
- package/dist/{manager-4QGXI6WZ.js → manager-66YAEO7K.js} +5 -5
- package/dist/{model-overrides-OY2YKUNV.js → model-overrides-L53PZNZA.js} +4 -4
- package/dist/orchestrator-XK5K3RPL.js +63 -0
- package/dist/package.json +3 -3
- package/dist/{path-security-PFMZY7IA.js → path-security-RSEI3YKB.js} +12 -11
- package/dist/{platform-QNGCKX4L.js → platform-WA4GK5BO.js} +4 -4
- package/dist/{processor-NYPJ5PFA.js → processor-WDZSFBVO.js} +30 -24
- package/dist/{project-creator-AWP2JUFS.js → project-creator-676WQXVI.js} +3 -3
- package/dist/{projects-C4353IQK.js → projects-SSBWIYL4.js} +3 -3
- package/dist/{protocol-CBT1d98i.d.ts → protocol-BzHs024-.d.ts} +21 -3
- package/dist/{protocol-LZZ7C4VQ.js → protocol-RKSWKNXI.js} +3 -3
- package/dist/provider/index.d.ts +4 -4
- package/dist/{provider-PIRPN2CC.js → provider-PLIWRBCF.js} +7 -7
- package/dist/{provider-manager-GNEPR6UN.js → provider-manager-2QSJTPWS.js} +7 -7
- package/dist/{registry-VCKDSVKA.js → registry-ZP4TN2IN.js} +5 -4
- package/dist/{serve-6DRHQLCG.js → serve-MZ3BCCWC.js} +35 -32
- package/dist/server/index.d.ts +4 -4
- package/dist/server/index.js +34 -31
- package/dist/server-EPXODFMB.js +55 -0
- package/dist/service-54PGIPDQ.js +25 -0
- package/dist/{session-overrides-RNKV35MU.js → session-overrides-LXN6W7SA.js} +7 -6
- package/dist/{sessions-D5CEPQGU.js → sessions-CHPVUG6H.js} +6 -5
- package/dist/{settings-BNRNX6IW.js → settings-NEBM3GQX.js} +3 -3
- package/dist/shared/index.d.ts +3 -3
- package/dist/shared/index.js +1 -1
- package/dist/skill-defaults/workflows/SKILL.md +24 -6
- package/dist/tasks-TJXG2V3U.js +217 -0
- package/dist/{tools-2B363F7L.js → tools-CIM26IFB.js} +30 -22
- package/dist/{types-BAxh20ZL.d.ts → types-CMtHpDWT.d.ts} +74 -1
- package/dist/{types-cVfqOj6M.d.ts → types-CbggXFvR.d.ts} +1 -1
- package/dist/{update-IQMRYN7J.js → update-UZBBO42X.js} +2 -2
- package/dist/web/assets/{index-CjWC6EQ4.css → index-BmILAZrT.css} +1 -1
- package/dist/web/assets/index-rZHXkfMq.js +324 -0
- package/dist/web/index.html +2 -2
- package/dist/web/sw.js +1 -1
- package/dist/workflow-defaults/default.workflow.json +5 -3
- package/dist/{workspace-YUNHV4WS.js → workspace-2XODU4YJ.js} +4 -4
- package/package.json +3 -3
- package/dist/chunk-B2PHPBFU.js +0 -7
- package/dist/http-client-YC3UA5OZ.js +0 -11
- package/dist/orchestrator-JKBY7B3P.js +0 -57
- package/dist/server-HUHFJW7U.js +0 -48
- package/dist/web/assets/index-DBUtUSHK.js +0 -323
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getEventStore
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-JXLRL5JR.js";
|
|
4
4
|
import {
|
|
5
5
|
createChatPathConfirmationMessage
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-I7FY2LTR.js";
|
|
7
7
|
import {
|
|
8
8
|
getPlatformShell
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-SA34STZ6.js";
|
|
10
10
|
|
|
11
11
|
// src/server/tools/path-security.ts
|
|
12
12
|
import { realpath } from "fs/promises";
|
|
@@ -535,4 +535,4 @@ export {
|
|
|
535
535
|
getConfirmationSessionId,
|
|
536
536
|
getPendingConfirmationsBySession
|
|
537
537
|
};
|
|
538
|
-
//# sourceMappingURL=chunk-
|
|
538
|
+
//# sourceMappingURL=chunk-BZVW77PI.js.map
|
|
@@ -1,45 +1,45 @@
|
|
|
1
|
-
import {
|
|
2
|
-
buildCachedPrompt,
|
|
3
|
-
computeDynamicContextHash,
|
|
4
|
-
getToolFingerprint
|
|
5
|
-
} from "./chunk-O2YSYW2F.js";
|
|
6
1
|
import {
|
|
7
2
|
createAssemblyResult,
|
|
8
3
|
getConversationMessages,
|
|
9
4
|
getToolRegistryForAgent,
|
|
10
5
|
processEventsForConversation,
|
|
11
6
|
runTopLevelAgentLoop
|
|
12
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-K733B5T2.js";
|
|
8
|
+
import {
|
|
9
|
+
buildCachedPrompt,
|
|
10
|
+
computeDynamicContextHash,
|
|
11
|
+
getToolFingerprint
|
|
12
|
+
} from "./chunk-GUHHUDNL.js";
|
|
13
13
|
import {
|
|
14
14
|
getAllInstructions,
|
|
15
15
|
getEnabledSkillMetadata
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-YGJIK3CG.js";
|
|
17
17
|
import {
|
|
18
18
|
TurnMetrics,
|
|
19
19
|
createChatDoneEvent,
|
|
20
20
|
createMessageStartEvent
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-NLO64UE3.js";
|
|
22
22
|
import {
|
|
23
23
|
buildAgentReminder,
|
|
24
24
|
buildAgentSmallReminder
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-2XD65L7M.js";
|
|
26
26
|
import {
|
|
27
27
|
PathAccessDeniedError
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-BZVW77PI.js";
|
|
29
29
|
import {
|
|
30
30
|
getCurrentContextWindowId,
|
|
31
31
|
getCurrentWindowMessageOptions,
|
|
32
32
|
getEventStore
|
|
33
|
-
} from "./chunk-
|
|
33
|
+
} from "./chunk-JXLRL5JR.js";
|
|
34
34
|
import {
|
|
35
35
|
buildSnapshotFromSessionState
|
|
36
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-UTIQ7OO5.js";
|
|
37
37
|
import {
|
|
38
38
|
findAgentById,
|
|
39
39
|
getRuntimeConfig,
|
|
40
40
|
loadAllAgentsDefault,
|
|
41
41
|
resolveDefaultAgentId
|
|
42
|
-
} from "./chunk-
|
|
42
|
+
} from "./chunk-UPBWEHIL.js";
|
|
43
43
|
import {
|
|
44
44
|
logger
|
|
45
45
|
} from "./chunk-K44MW7JJ.js";
|
|
@@ -49,7 +49,7 @@ import {
|
|
|
49
49
|
|
|
50
50
|
// src/server/chat/orchestrator.ts
|
|
51
51
|
async function buildRetryPatterns() {
|
|
52
|
-
const { getSetting, SETTINGS_KEYS } = await import("./settings-
|
|
52
|
+
const { getSetting, SETTINGS_KEYS } = await import("./settings-NEBM3GQX.js");
|
|
53
53
|
const raw = getSetting(SETTINGS_KEYS.RETRY_PATTERNS);
|
|
54
54
|
if (!raw) {
|
|
55
55
|
const oldXmlProtection = getSetting("llm.disableXmlProtection");
|
|
@@ -319,4 +319,4 @@ export {
|
|
|
319
319
|
runChatTurn,
|
|
320
320
|
runAgentTurn
|
|
321
321
|
};
|
|
322
|
-
//# sourceMappingURL=chunk-
|
|
322
|
+
//# sourceMappingURL=chunk-FW4NDUBL.js.map
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getAllInstructions,
|
|
3
3
|
getEnabledSkillMetadata
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-YGJIK3CG.js";
|
|
5
5
|
import {
|
|
6
6
|
buildTopLevelSystemPrompt
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-2XD65L7M.js";
|
|
8
8
|
import {
|
|
9
9
|
findAgentById,
|
|
10
10
|
getRuntimeConfig,
|
|
11
11
|
getSubAgents,
|
|
12
12
|
loadAllAgentsDefault,
|
|
13
13
|
resolveDefaultAgentId
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-UPBWEHIL.js";
|
|
15
15
|
import {
|
|
16
16
|
logger
|
|
17
17
|
} from "./chunk-K44MW7JJ.js";
|
|
@@ -105,7 +105,7 @@ function resolveAgentDef(sessionManager, sessionId) {
|
|
|
105
105
|
}
|
|
106
106
|
async function buildCachedPrompt(sessionManager, sessionId, agentDef, modelName) {
|
|
107
107
|
const { instructionContent, skills } = await loadSessionContext(sessionManager, sessionId);
|
|
108
|
-
const { getToolRegistryForAgent } = await import("./tools-
|
|
108
|
+
const { getToolRegistryForAgent } = await import("./tools-CIM26IFB.js");
|
|
109
109
|
const tools = getToolRegistryForAgent(agentDef, sessionId).definitions;
|
|
110
110
|
const toolFingerprint = getToolFingerprint(tools);
|
|
111
111
|
const allAgents = await loadAllAgentsDefault();
|
|
@@ -124,7 +124,7 @@ async function buildCachedPrompt(sessionManager, sessionId, agentDef, modelName)
|
|
|
124
124
|
async function computeSessionHash(sessionManager, sessionId, modelName) {
|
|
125
125
|
const { instructionContent, skills } = await loadSessionContext(sessionManager, sessionId);
|
|
126
126
|
const agentDef = await resolveAgentDef(sessionManager, sessionId);
|
|
127
|
-
const { getToolRegistryForAgent } = await import("./tools-
|
|
127
|
+
const { getToolRegistryForAgent } = await import("./tools-CIM26IFB.js");
|
|
128
128
|
const tools = getToolRegistryForAgent(agentDef, sessionId).definitions;
|
|
129
129
|
const toolFingerprint = getToolFingerprint(tools);
|
|
130
130
|
return computeDynamicContextHash(instructionContent, skills, toolFingerprint, modelName);
|
|
@@ -148,4 +148,4 @@ export {
|
|
|
148
148
|
computeSessionHash,
|
|
149
149
|
applyDynamicContext
|
|
150
150
|
};
|
|
151
|
-
//# sourceMappingURL=chunk-
|
|
151
|
+
//# sourceMappingURL=chunk-GUHHUDNL.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getDatabase
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-PBW3YC3G.js";
|
|
4
4
|
|
|
5
5
|
// src/server/db/settings.ts
|
|
6
6
|
var SETTINGS_KEYS = {
|
|
@@ -131,4 +131,4 @@ export {
|
|
|
131
131
|
getAllSettings,
|
|
132
132
|
getMaxVisibleItems
|
|
133
133
|
};
|
|
134
|
-
//# sourceMappingURL=chunk-
|
|
134
|
+
//# sourceMappingURL=chunk-HP5CIB66.js.map
|
|
@@ -163,7 +163,7 @@ async function runCli(options) {
|
|
|
163
163
|
break;
|
|
164
164
|
}
|
|
165
165
|
case "provider": {
|
|
166
|
-
const { runProviderCommand } = await import("./provider-
|
|
166
|
+
const { runProviderCommand } = await import("./provider-PLIWRBCF.js");
|
|
167
167
|
const [, subcommand] = positionals;
|
|
168
168
|
await runProviderCommand(mode, subcommand);
|
|
169
169
|
break;
|
|
@@ -200,7 +200,7 @@ async function runCli(options) {
|
|
|
200
200
|
break;
|
|
201
201
|
}
|
|
202
202
|
case "update": {
|
|
203
|
-
const { runUpdate } = await import("./update-
|
|
203
|
+
const { runUpdate } = await import("./update-UZBBO42X.js");
|
|
204
204
|
const code = await runUpdate();
|
|
205
205
|
if (code !== 0) {
|
|
206
206
|
process.exit(code);
|
|
@@ -213,7 +213,7 @@ async function runCli(options) {
|
|
|
213
213
|
if (!configExists) {
|
|
214
214
|
await runNetworkSetup(mode);
|
|
215
215
|
}
|
|
216
|
-
const { runServe } = await import("./serve-
|
|
216
|
+
const { runServe } = await import("./serve-MZ3BCCWC.js");
|
|
217
217
|
const serveOptions = { mode };
|
|
218
218
|
if (values.port) serveOptions.port = parseInt(values.port);
|
|
219
219
|
if (values["no-browser"] === true) serveOptions.openBrowser = false;
|
|
@@ -225,4 +225,4 @@ async function runCli(options) {
|
|
|
225
225
|
export {
|
|
226
226
|
runCli
|
|
227
227
|
};
|
|
228
|
-
//# sourceMappingURL=chunk-
|
|
228
|
+
//# sourceMappingURL=chunk-HV6IALXF.js.map
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
import {
|
|
5
5
|
createServerMessage,
|
|
6
6
|
isClientMessage
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-X25Q6RAV.js";
|
|
8
8
|
|
|
9
9
|
// src/server/session/client-session.ts
|
|
10
10
|
function toClientSession(session) {
|
|
@@ -366,4 +366,4 @@ export {
|
|
|
366
366
|
createQueueStateMessage,
|
|
367
367
|
storedEventToServerMessage
|
|
368
368
|
};
|
|
369
|
-
//# sourceMappingURL=chunk-
|
|
369
|
+
//# sourceMappingURL=chunk-I7FY2LTR.js.map
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
SETTINGS_KEYS,
|
|
3
3
|
getSetting,
|
|
4
4
|
setSetting
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-HP5CIB66.js";
|
|
6
6
|
|
|
7
7
|
// src/server/agents/model-overrides.ts
|
|
8
8
|
import { z } from "zod";
|
|
@@ -69,4 +69,4 @@ export {
|
|
|
69
69
|
setAgentModelOverride,
|
|
70
70
|
resolveLLMClientForAgent
|
|
71
71
|
};
|
|
72
|
-
//# sourceMappingURL=chunk-
|
|
72
|
+
//# sourceMappingURL=chunk-JP7NM545.js.map
|
|
@@ -6,16 +6,16 @@ import {
|
|
|
6
6
|
foldSessionState,
|
|
7
7
|
spreadOptionalMessageFields,
|
|
8
8
|
trimSnapshotStreamingOutput
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-UTIQ7OO5.js";
|
|
10
10
|
import {
|
|
11
11
|
updateSessionMessageCount
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-3O77NT4T.js";
|
|
13
13
|
import {
|
|
14
14
|
getRuntimeConfig
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-UPBWEHIL.js";
|
|
16
16
|
import {
|
|
17
17
|
SETTINGS_KEYS
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-HP5CIB66.js";
|
|
19
19
|
import {
|
|
20
20
|
logger
|
|
21
21
|
} from "./chunk-K44MW7JJ.js";
|
|
@@ -1465,4 +1465,4 @@ export {
|
|
|
1465
1465
|
truncateSessionMessages,
|
|
1466
1466
|
getRecentUserPromptsForSession
|
|
1467
1467
|
};
|
|
1468
|
-
//# sourceMappingURL=chunk-
|
|
1468
|
+
//# sourceMappingURL=chunk-JXLRL5JR.js.map
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
getEnabledSkillMetadata,
|
|
5
5
|
isSkillEnabled,
|
|
6
6
|
loadAllSkills
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-YGJIK3CG.js";
|
|
8
8
|
import {
|
|
9
9
|
TurnMetrics,
|
|
10
10
|
consumeStreamGenerator,
|
|
@@ -14,15 +14,15 @@ import {
|
|
|
14
14
|
createToolCallEvent,
|
|
15
15
|
createToolResultEvent,
|
|
16
16
|
streamLLMPure
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-NLO64UE3.js";
|
|
18
18
|
import {
|
|
19
19
|
COMPACTION_PROMPT,
|
|
20
20
|
buildBasePrompt,
|
|
21
21
|
computeEffectiveTools
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-2XD65L7M.js";
|
|
23
23
|
import {
|
|
24
24
|
startInspectProxy
|
|
25
|
-
} from "./chunk-
|
|
25
|
+
} from "./chunk-P5UANBBX.js";
|
|
26
26
|
import {
|
|
27
27
|
checkAborted,
|
|
28
28
|
createProcess,
|
|
@@ -36,7 +36,7 @@ import {
|
|
|
36
36
|
spawnShellProcess,
|
|
37
37
|
startProcessCommand,
|
|
38
38
|
stopProcess
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-TKKP56QK.js";
|
|
40
40
|
import {
|
|
41
41
|
getMaxPerSession,
|
|
42
42
|
getSessionProcessCount,
|
|
@@ -52,36 +52,41 @@ import {
|
|
|
52
52
|
getGitBranch,
|
|
53
53
|
isGitRepository,
|
|
54
54
|
listWorkspaces
|
|
55
|
-
} from "./chunk-
|
|
55
|
+
} from "./chunk-SBSUDHL4.js";
|
|
56
|
+
import {
|
|
57
|
+
getGateConfig,
|
|
58
|
+
isTaskConflictError,
|
|
59
|
+
isTaskGateError
|
|
60
|
+
} from "./chunk-OTYAEEX3.js";
|
|
56
61
|
import {
|
|
57
62
|
getSessionDisabledServers
|
|
58
|
-
} from "./chunk-
|
|
63
|
+
} from "./chunk-L63Q4JQJ.js";
|
|
59
64
|
import {
|
|
60
65
|
PathAccessDeniedError,
|
|
61
66
|
extractAbsolutePathsFromCommand,
|
|
62
67
|
extractSensitivePathsFromCommand,
|
|
63
68
|
registerPathConfirmation,
|
|
64
69
|
requestPathAccess
|
|
65
|
-
} from "./chunk-
|
|
70
|
+
} from "./chunk-BZVW77PI.js";
|
|
66
71
|
import {
|
|
67
72
|
getCurrentContextWindowId,
|
|
68
73
|
getCurrentWindowMessageOptions,
|
|
69
74
|
getEventStore
|
|
70
|
-
} from "./chunk-
|
|
75
|
+
} from "./chunk-JXLRL5JR.js";
|
|
71
76
|
import {
|
|
72
77
|
createChatDoneMessage,
|
|
73
78
|
createChatMessageMessage,
|
|
74
79
|
createChatMessageUpdatedMessage,
|
|
75
80
|
createChatPathConfirmationMessage,
|
|
76
81
|
createQueueStateMessage
|
|
77
|
-
} from "./chunk-
|
|
82
|
+
} from "./chunk-I7FY2LTR.js";
|
|
78
83
|
import {
|
|
79
84
|
AskUserInterrupt,
|
|
80
85
|
askUserTool
|
|
81
86
|
} from "./chunk-JURM3RPZ.js";
|
|
82
87
|
import {
|
|
83
88
|
resolveLLMClientForAgent
|
|
84
|
-
} from "./chunk-
|
|
89
|
+
} from "./chunk-JP7NM545.js";
|
|
85
90
|
import {
|
|
86
91
|
buildContextMessagesFromEventHistory,
|
|
87
92
|
foldContextState,
|
|
@@ -91,13 +96,13 @@ import {
|
|
|
91
96
|
handleToolResult,
|
|
92
97
|
reorderToolMessages,
|
|
93
98
|
stripOrphanedToolCalls
|
|
94
|
-
} from "./chunk-
|
|
99
|
+
} from "./chunk-UTIQ7OO5.js";
|
|
95
100
|
import {
|
|
96
101
|
findAgentById,
|
|
97
102
|
getRuntimeConfig,
|
|
98
103
|
getSubAgents,
|
|
99
104
|
loadAllAgentsDefault
|
|
100
|
-
} from "./chunk-
|
|
105
|
+
} from "./chunk-UPBWEHIL.js";
|
|
101
106
|
import {
|
|
102
107
|
modelSupportsVision
|
|
103
108
|
} from "./chunk-V4IE7HJY.js";
|
|
@@ -115,7 +120,7 @@ import {
|
|
|
115
120
|
import {
|
|
116
121
|
SETTINGS_KEYS,
|
|
117
122
|
getSetting
|
|
118
|
-
} from "./chunk-
|
|
123
|
+
} from "./chunk-HP5CIB66.js";
|
|
119
124
|
import {
|
|
120
125
|
logger
|
|
121
126
|
} from "./chunk-K44MW7JJ.js";
|
|
@@ -139,7 +144,7 @@ async function requestUserConfirmation(context, toolLabel, desc) {
|
|
|
139
144
|
if (context.dangerLevel === "dangerous") return Promise.resolve(true);
|
|
140
145
|
if (toolLabel === "workspace" || toolLabel === "command") {
|
|
141
146
|
try {
|
|
142
|
-
const { getSetting: getSetting2, SETTINGS_KEYS: SETTINGS_KEYS2 } = await import("./settings-
|
|
147
|
+
const { getSetting: getSetting2, SETTINGS_KEYS: SETTINGS_KEYS2 } = await import("./settings-NEBM3GQX.js");
|
|
143
148
|
if (getSetting2(SETTINGS_KEYS2.CONFIRM_ON_WORKSPACE_ACTIONS) !== "true") {
|
|
144
149
|
return Promise.resolve(true);
|
|
145
150
|
}
|
|
@@ -1935,7 +1940,7 @@ ${CONTINUE_PROMPT}` : CONTINUE_PROMPT;
|
|
|
1935
1940
|
);
|
|
1936
1941
|
if (!compacting) {
|
|
1937
1942
|
const contextState2 = sessionManager.getContextState(sessionId);
|
|
1938
|
-
const { shouldCompact, appendCompactionPrompt } = await import("./compactor-
|
|
1943
|
+
const { shouldCompact, appendCompactionPrompt } = await import("./compactor-V3LR7APW.js");
|
|
1939
1944
|
if (shouldCompact(
|
|
1940
1945
|
contextState2.currentTokens,
|
|
1941
1946
|
contextState2.maxTokens,
|
|
@@ -2923,7 +2928,7 @@ var callSubAgentTool = {
|
|
|
2923
2928
|
};
|
|
2924
2929
|
}
|
|
2925
2930
|
try {
|
|
2926
|
-
const { getToolRegistryForAgent: getToolRegistryForAgent2 } = await import("./tools-
|
|
2931
|
+
const { getToolRegistryForAgent: getToolRegistryForAgent2 } = await import("./tools-CIM26IFB.js");
|
|
2927
2932
|
const toolRegistry = getToolRegistryForAgent2(agentDef);
|
|
2928
2933
|
const turnMetrics = new TurnMetrics();
|
|
2929
2934
|
const result = await executeSubAgent({
|
|
@@ -3945,7 +3950,7 @@ var mcpConfigTool = createTool(
|
|
|
3945
3950
|
mcpNotifyChanged?.(sessionId);
|
|
3946
3951
|
}
|
|
3947
3952
|
async function rebuildTools() {
|
|
3948
|
-
const { setMcpTools: setMcpTools2 } = await import("./tools-
|
|
3953
|
+
const { setMcpTools: setMcpTools2 } = await import("./tools-CIM26IFB.js");
|
|
3949
3954
|
const mcpTools = createMcpTools(mcpManagerForTools);
|
|
3950
3955
|
setMcpTools2(mcpTools);
|
|
3951
3956
|
}
|
|
@@ -4359,6 +4364,233 @@ Actions:
|
|
|
4359
4364
|
}
|
|
4360
4365
|
);
|
|
4361
4366
|
|
|
4367
|
+
// src/server/tools/project-tasks.ts
|
|
4368
|
+
var tasksService = null;
|
|
4369
|
+
function setTasksService(service) {
|
|
4370
|
+
tasksService = service;
|
|
4371
|
+
}
|
|
4372
|
+
function getTasksService() {
|
|
4373
|
+
if (!tasksService) {
|
|
4374
|
+
throw new Error("Project tasks service not initialized");
|
|
4375
|
+
}
|
|
4376
|
+
return tasksService;
|
|
4377
|
+
}
|
|
4378
|
+
var VALID_ACTIONS = [
|
|
4379
|
+
"list",
|
|
4380
|
+
"get",
|
|
4381
|
+
"create",
|
|
4382
|
+
"edit",
|
|
4383
|
+
"move",
|
|
4384
|
+
"set_gate_value",
|
|
4385
|
+
"set_gates",
|
|
4386
|
+
"duplicate",
|
|
4387
|
+
"delete",
|
|
4388
|
+
"reorder"
|
|
4389
|
+
];
|
|
4390
|
+
var projectTasksTool = createTool(
|
|
4391
|
+
"project_tasks",
|
|
4392
|
+
{
|
|
4393
|
+
type: "function",
|
|
4394
|
+
function: {
|
|
4395
|
+
name: "project_tasks",
|
|
4396
|
+
description: "Work with the project task board \u2014 the kanban of tasks owned by this project. Provides full parity with the human UI: list, get, create, edit, move, fill gate values, set gate configuration, duplicate, delete, and reorder.\n\nRules:\n- Moving a task to in_progress binds it to YOUR current session (you never create a new session for it).\n- Entering 'done' is blocked by unmet column gates (definition of done). When blocked, the error lists the missing fields; set them with action=set_gate_value (filling proof/evidence as part of your work), then retry the move.\n- All transitions are serialized server-side. If another actor changed the task, you get a CONFLICT error: re-list and retry.\n\nActions:\n- list: list all tasks (with gate values, status, queue position, bound session, audit trail)\n- get: fetch a single task (taskId)\n- create: create a task in To Do (prompt must contain text or an attachment)\n- edit: update prompt/attachments/agent/model (taskId + any fields)\n- move: change state \u2014 to: 'todo' | 'in_progress' | 'done' (optional reason for reverts)\n- set_gate_value: fill a gate field (taskId, gateId, value)\n- set_gates: replace the project gate configuration (gates: array of {id, name, description, required, variant})\n- duplicate: copy a task into To Do (taskId)\n- delete: permanently delete a task (taskId). Sessions stay untouched.\n- reorder: move a task to an index within its column (taskId, status, index)",
|
|
4397
|
+
parameters: {
|
|
4398
|
+
type: "object",
|
|
4399
|
+
properties: {
|
|
4400
|
+
action: { type: "string", enum: VALID_ACTIONS, description: "The action to perform" },
|
|
4401
|
+
taskId: {
|
|
4402
|
+
type: "string",
|
|
4403
|
+
description: "Target task id (get, edit, move, set_gate_value, duplicate, delete, reorder)"
|
|
4404
|
+
},
|
|
4405
|
+
prompt: { type: "string", description: "The prompt/instruction executed when the task launches" },
|
|
4406
|
+
attachments: { type: "array", description: "Optional attachments (same shape as chat attachments)" },
|
|
4407
|
+
agentId: { type: "string", description: "Selected agent id" },
|
|
4408
|
+
providerId: { type: "string", description: "Provider id used when a session is spawned" },
|
|
4409
|
+
model: { type: "string", description: "Model label used when a session is spawned" },
|
|
4410
|
+
to: { type: "string", enum: ["todo", "in_progress", "done"], description: "Destination column for move" },
|
|
4411
|
+
reason: { type: "string", description: "Optional short reason (recorded in the audit trail) for reverts" },
|
|
4412
|
+
gateId: { type: "string", description: "Gate field id for set_gate_value" },
|
|
4413
|
+
value: { type: "string", description: "Proof/evidence value for set_gate_value" },
|
|
4414
|
+
gates: {
|
|
4415
|
+
type: "array",
|
|
4416
|
+
description: "Full replacement gate config: [{id, name, description, required, variant}]"
|
|
4417
|
+
},
|
|
4418
|
+
status: { type: "string", enum: ["todo", "in_progress", "done"], description: "Column for reorder" },
|
|
4419
|
+
index: { type: "number", description: "Zero-based target index within the column (reorder)" },
|
|
4420
|
+
expectedVersion: {
|
|
4421
|
+
type: "number",
|
|
4422
|
+
description: "Optimistic concurrency guard \u2014 pass the task version you saw; stale writes fail with CONFLICT"
|
|
4423
|
+
}
|
|
4424
|
+
},
|
|
4425
|
+
required: ["action"]
|
|
4426
|
+
}
|
|
4427
|
+
}
|
|
4428
|
+
},
|
|
4429
|
+
async (args, context, helpers) => {
|
|
4430
|
+
const action = args.action;
|
|
4431
|
+
const permError = validateActionWithPermission(action, VALID_ACTIONS, "project_tasks", context.permittedActions);
|
|
4432
|
+
if (permError) return permError;
|
|
4433
|
+
const session = context.sessionManager.getSession(context.sessionId);
|
|
4434
|
+
if (!session) return helpers.error("Session not found");
|
|
4435
|
+
const projectId = session.projectId;
|
|
4436
|
+
const svc = getTasksService();
|
|
4437
|
+
const actor = { actor: "agent", actorName: "agent" };
|
|
4438
|
+
try {
|
|
4439
|
+
switch (action) {
|
|
4440
|
+
case "list": {
|
|
4441
|
+
const tasks = svc.list(projectId);
|
|
4442
|
+
const gates = getGateConfig(projectId);
|
|
4443
|
+
return helpers.success(JSON.stringify({ gates, tasks: tasks.map((t) => taskForAgent(t)) }, null, 2));
|
|
4444
|
+
}
|
|
4445
|
+
case "get": {
|
|
4446
|
+
if (!args.taskId) return helpers.error('Parameter "taskId" is required for action=get');
|
|
4447
|
+
const task = svc.get(projectId, args.taskId);
|
|
4448
|
+
if (!task) return helpers.error(`Task not found: ${args.taskId}`);
|
|
4449
|
+
return helpers.success(JSON.stringify(taskForAgent(task), null, 2));
|
|
4450
|
+
}
|
|
4451
|
+
case "create": {
|
|
4452
|
+
const task = svc.create(
|
|
4453
|
+
projectId,
|
|
4454
|
+
{
|
|
4455
|
+
prompt: args.prompt ?? "",
|
|
4456
|
+
...args.attachments ? { attachments: sanitizeAttachments(args.attachments) } : {},
|
|
4457
|
+
...args.agentId ? { agentId: args.agentId } : {},
|
|
4458
|
+
...args.providerId ? { providerId: args.providerId } : {},
|
|
4459
|
+
...args.model ? { model: args.model } : {}
|
|
4460
|
+
},
|
|
4461
|
+
actor
|
|
4462
|
+
);
|
|
4463
|
+
return helpers.success(JSON.stringify(taskForAgent(task), null, 2));
|
|
4464
|
+
}
|
|
4465
|
+
case "edit": {
|
|
4466
|
+
if (!args.taskId) return helpers.error('Parameter "taskId" is required for action=edit');
|
|
4467
|
+
const result = await svc.update(
|
|
4468
|
+
projectId,
|
|
4469
|
+
args.taskId,
|
|
4470
|
+
{
|
|
4471
|
+
...args.prompt !== void 0 ? { prompt: args.prompt } : {},
|
|
4472
|
+
...args.attachments ? { attachments: sanitizeAttachments(args.attachments) } : {},
|
|
4473
|
+
...args.agentId !== void 0 ? { agentId: args.agentId } : {},
|
|
4474
|
+
...args.providerId !== void 0 ? { providerId: args.providerId } : {},
|
|
4475
|
+
...args.model !== void 0 ? { model: args.model } : {}
|
|
4476
|
+
},
|
|
4477
|
+
actor,
|
|
4478
|
+
args.expectedVersion
|
|
4479
|
+
);
|
|
4480
|
+
return helpers.success(JSON.stringify(taskForAgent(result.task), null, 2));
|
|
4481
|
+
}
|
|
4482
|
+
case "move": {
|
|
4483
|
+
if (!args.taskId) return helpers.error('Parameter "taskId" is required for action=move');
|
|
4484
|
+
if (!args.to)
|
|
4485
|
+
return helpers.error('Parameter "to" is required for action=move ("todo" | "in_progress" | "done")');
|
|
4486
|
+
const result = await svc.move(projectId, args.taskId, args.to, {
|
|
4487
|
+
actor: "agent",
|
|
4488
|
+
actorName: "agent",
|
|
4489
|
+
sessionId: context.sessionId,
|
|
4490
|
+
...args.reason ? { reason: args.reason } : {},
|
|
4491
|
+
...args.expectedVersion ? { expectedVersion: args.expectedVersion } : {}
|
|
4492
|
+
});
|
|
4493
|
+
return helpers.success(JSON.stringify(taskForAgent(result.task), null, 2));
|
|
4494
|
+
}
|
|
4495
|
+
case "set_gate_value": {
|
|
4496
|
+
if (!args.taskId) return helpers.error('Parameter "taskId" is required for action=set_gate_value');
|
|
4497
|
+
if (!args.gateId) return helpers.error('Parameter "gateId" is required for action=set_gate_value');
|
|
4498
|
+
if (args.value === void 0) return helpers.error('Parameter "value" is required for action=set_gate_value');
|
|
4499
|
+
const result = await svc.setGateValue(
|
|
4500
|
+
projectId,
|
|
4501
|
+
args.taskId,
|
|
4502
|
+
args.gateId,
|
|
4503
|
+
args.value,
|
|
4504
|
+
actor,
|
|
4505
|
+
context.sessionId,
|
|
4506
|
+
args.expectedVersion
|
|
4507
|
+
);
|
|
4508
|
+
return helpers.success(JSON.stringify(taskForAgent(result.task), null, 2));
|
|
4509
|
+
}
|
|
4510
|
+
case "set_gates": {
|
|
4511
|
+
if (!Array.isArray(args.gates)) {
|
|
4512
|
+
return helpers.error('Parameter "gates" (array) is required for action=set_gates');
|
|
4513
|
+
}
|
|
4514
|
+
const gates = sanitizeGates(args.gates);
|
|
4515
|
+
svc.setGateConfig(projectId, gates, actor);
|
|
4516
|
+
return helpers.success(JSON.stringify({ gates }, null, 2));
|
|
4517
|
+
}
|
|
4518
|
+
case "duplicate": {
|
|
4519
|
+
if (!args.taskId) return helpers.error('Parameter "taskId" is required for action=duplicate');
|
|
4520
|
+
const task = svc.duplicate(projectId, args.taskId, actor);
|
|
4521
|
+
return helpers.success(JSON.stringify(taskForAgent(task), null, 2));
|
|
4522
|
+
}
|
|
4523
|
+
case "delete": {
|
|
4524
|
+
if (!args.taskId) return helpers.error('Parameter "taskId" is required for action=delete');
|
|
4525
|
+
await svc.remove(projectId, args.taskId, actor);
|
|
4526
|
+
return helpers.success(`Task ${args.taskId} deleted (linked sessions untouched)`);
|
|
4527
|
+
}
|
|
4528
|
+
case "reorder": {
|
|
4529
|
+
if (!args.taskId) return helpers.error('Parameter "taskId" is required for action=reorder');
|
|
4530
|
+
if (!args.status || args.index === void 0) {
|
|
4531
|
+
return helpers.error('Parameters "status" and "index" are required for action=reorder');
|
|
4532
|
+
}
|
|
4533
|
+
const task = svc.reorder(projectId, args.taskId, args.status, args.index);
|
|
4534
|
+
return helpers.success(JSON.stringify(taskForAgent(task), null, 2));
|
|
4535
|
+
}
|
|
4536
|
+
default:
|
|
4537
|
+
return helpers.error(`Unknown action: ${String(action)}`);
|
|
4538
|
+
}
|
|
4539
|
+
} catch (error) {
|
|
4540
|
+
if (isTaskGateError(error)) {
|
|
4541
|
+
const missing = error.missing.map((m) => `'${m.name}' (${m.gateId}): ${m.description}`).join("; ");
|
|
4542
|
+
return helpers.error(
|
|
4543
|
+
`Move blocked by column gates. Missing required gate fields: ${missing}. Fill them with action=set_gate_value (taskId, gateId, value=<acceptable proof>) and then call move again. You set these values as part of your work \u2014 this is the intended loop, not a dead end.`
|
|
4544
|
+
);
|
|
4545
|
+
}
|
|
4546
|
+
if (isTaskConflictError(error)) {
|
|
4547
|
+
return helpers.error(
|
|
4548
|
+
`Task changed, refresh and retry. Another actor modified this task since your last read. Re-list and retry with the latest updatedAt.`
|
|
4549
|
+
);
|
|
4550
|
+
}
|
|
4551
|
+
throw error;
|
|
4552
|
+
}
|
|
4553
|
+
}
|
|
4554
|
+
);
|
|
4555
|
+
function taskForAgent(task) {
|
|
4556
|
+
return {
|
|
4557
|
+
id: task.id,
|
|
4558
|
+
prompt: task.prompt,
|
|
4559
|
+
status: task.status,
|
|
4560
|
+
...task.runState ? { runState: task.runState } : {},
|
|
4561
|
+
...task.queuePosition ? { queuePosition: task.queuePosition } : {},
|
|
4562
|
+
...task.activeSessionId ? { boundSession: task.activeSessionId } : {},
|
|
4563
|
+
...task.model ? { model: task.model } : {},
|
|
4564
|
+
version: task.version,
|
|
4565
|
+
attachments: task.attachments.length,
|
|
4566
|
+
gateValues: task.gateValues.map((v) => ({ [v.gateId]: v.value, actor: v.actor, timestamp: v.timestamp })),
|
|
4567
|
+
auditTrail: task.auditTrail.map((a) => ({
|
|
4568
|
+
action: a.action,
|
|
4569
|
+
actor: a.actor,
|
|
4570
|
+
detail: a.detail,
|
|
4571
|
+
timestamp: a.timestamp
|
|
4572
|
+
})),
|
|
4573
|
+
updatedAt: task.updatedAt
|
|
4574
|
+
};
|
|
4575
|
+
}
|
|
4576
|
+
function sanitizeAttachments(raw) {
|
|
4577
|
+
return raw.filter(
|
|
4578
|
+
(a) => typeof a === "object" && a !== null && typeof a.id === "string" && typeof a.filename === "string"
|
|
4579
|
+
);
|
|
4580
|
+
}
|
|
4581
|
+
function sanitizeGates(raw) {
|
|
4582
|
+
return raw.map((g, i) => {
|
|
4583
|
+
const gate = g;
|
|
4584
|
+
return {
|
|
4585
|
+
id: typeof gate.id === "string" && gate.id ? gate.id : `gate_${i}`,
|
|
4586
|
+
name: typeof gate.name === "string" && gate.name ? gate.name : `Gate ${i + 1}`,
|
|
4587
|
+
description: typeof gate.description === "string" ? gate.description : "",
|
|
4588
|
+
required: gate.required !== false,
|
|
4589
|
+
variant: gate.variant === "ready" ? "ready" : "done"
|
|
4590
|
+
};
|
|
4591
|
+
});
|
|
4592
|
+
}
|
|
4593
|
+
|
|
4362
4594
|
// src/server/tools/index.ts
|
|
4363
4595
|
var _builtInTools;
|
|
4364
4596
|
function getBuiltInTools() {
|
|
@@ -4379,7 +4611,8 @@ function getBuiltInTools() {
|
|
|
4379
4611
|
stepDoneTool,
|
|
4380
4612
|
backgroundProcessTool,
|
|
4381
4613
|
mcpConfigTool,
|
|
4382
|
-
workspaceTool
|
|
4614
|
+
workspaceTool,
|
|
4615
|
+
projectTasksTool
|
|
4383
4616
|
];
|
|
4384
4617
|
}
|
|
4385
4618
|
return _builtInTools;
|
|
@@ -4628,6 +4861,7 @@ export {
|
|
|
4628
4861
|
setMcpConfigMode,
|
|
4629
4862
|
setMcpConfigPath,
|
|
4630
4863
|
setNotifyMcpServersChanged,
|
|
4864
|
+
setTasksService,
|
|
4631
4865
|
getBuiltInToolNames,
|
|
4632
4866
|
parseToolPermissions,
|
|
4633
4867
|
getToolPermissions,
|
|
@@ -4638,4 +4872,4 @@ export {
|
|
|
4638
4872
|
getToolRegistryForAgent,
|
|
4639
4873
|
createToolRegistry
|
|
4640
4874
|
};
|
|
4641
|
-
//# sourceMappingURL=chunk-
|
|
4875
|
+
//# sourceMappingURL=chunk-K733B5T2.js.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
updateSessionMcpDisabledServers
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-3O77NT4T.js";
|
|
4
4
|
import {
|
|
5
5
|
getDatabase
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-PBW3YC3G.js";
|
|
7
7
|
|
|
8
8
|
// src/server/mcp/session-overrides.ts
|
|
9
9
|
var sessionOverrides = /* @__PURE__ */ new Map();
|
|
@@ -62,4 +62,4 @@ export {
|
|
|
62
62
|
clearSessionOverrides,
|
|
63
63
|
getAllSessionOverrides
|
|
64
64
|
};
|
|
65
|
-
//# sourceMappingURL=chunk-
|
|
65
|
+
//# sourceMappingURL=chunk-L63Q4JQJ.js.map
|