pi-subagents 0.83.0 → 0.83.1
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 -2
- package/bundle/agents.js +4 -4
- package/bundle/capability-ceiling.js +1 -1
- package/bundle/child-tool-plan.js +3 -3
- package/bundle/{chunk-P2NCCTZP.js → chunk-2D52JFLF.js} +1 -1
- package/bundle/{chunk-WG2OTTAK.js → chunk-2DHZTCOL.js} +2 -2
- package/bundle/{chunk-MBDOYZ2V.js → chunk-2S4K53MV.js} +1 -1
- package/bundle/{chunk-HJJAVHFB.js → chunk-5YIITCPD.js} +23 -23
- package/bundle/{chunk-CNLDYEH4.js → chunk-AHIFYGR3.js} +11 -11
- package/bundle/{chunk-MHX22USZ.js → chunk-C5P5CHYK.js} +1 -1
- package/bundle/{chunk-XXKG3P2W.js → chunk-C7JMPU5F.js} +4 -4
- package/bundle/{chunk-VTMNBPCQ.js → chunk-D3JAFGMO.js} +1 -1
- package/bundle/{chunk-BKFWQ642.js → chunk-F4ASL6OV.js} +1 -1
- package/bundle/{chunk-CDI3GMNV.js → chunk-F5DBXJ2G.js} +15 -15
- package/bundle/{chunk-JHZ6DZ5M.js → chunk-G2Z6ZH26.js} +1 -1
- package/bundle/{chunk-TJQJ3MEA.js → chunk-IPGZMQXV.js} +10 -10
- package/bundle/{chunk-Y3I6H6DV.js → chunk-LFDBD4PW.js} +2 -2
- package/bundle/{chunk-7F5SK2U3.js → chunk-LNRJCP2Y.js} +17 -14
- package/bundle/{chunk-6B4ITO2W.js → chunk-MABL3FUM.js} +1 -1
- package/bundle/{chunk-CGXWSNPA.js → chunk-NPIYWVOD.js} +4 -4
- package/bundle/{chunk-RZJN63GU.js → chunk-QP5ZWNIS.js} +2 -2
- package/bundle/{chunk-Z7KVHQHL.js → chunk-QXASAHIA.js} +2 -2
- package/bundle/{chunk-5ESXK62X.js → chunk-RNIZLSEA.js} +416 -389
- package/bundle/{chunk-HLE22FSH.js → chunk-SSG7IEP5.js} +2 -2
- package/bundle/{chunk-CZTMUBUI.js → chunk-UFL7IYCW.js} +4 -4
- package/bundle/{chunk-LDMXJIA6.js → chunk-UUP372DR.js} +44 -67
- package/bundle/{chunk-OOFW75PV.js → chunk-UYK5MZWE.js} +15 -11
- package/bundle/{chunk-CSSZRTKY.js → chunk-V2BZYLEP.js} +2 -2
- package/bundle/{chunk-4BW55BTL.js → chunk-VLFZIN6D.js} +4 -4
- package/bundle/{chunk-527E3D2J.js → chunk-YXFJVCOL.js} +5 -5
- package/bundle/{chunk-HXVKGS33.js → chunk-ZVOAMTUQ.js} +4 -4
- package/bundle/control-channel.js +3 -3
- package/bundle/index.js +1 -1
- package/bundle/intercom-bridge.js +3 -3
- package/bundle/preflight.js +9 -9
- package/bundle/project-panes.js +4 -4
- package/docs/configuration.md +12 -1
- package/docs/extension-api.md +2 -0
- package/docs/missions.md +2 -0
- package/docs/tool-reference.md +1 -1
- package/package.json +1 -1
- package/src/agents/agent-management.d.ts +1 -1
- package/src/agents/agent-management.js +2 -2
- package/src/agents/agents.js +1 -2
- package/src/agents/frontmatter.js +22 -18
- package/src/extension/index.js +2 -2
- package/src/missions/actions.js +7 -2
- package/src/missions/lifecycle.d.ts +11 -0
- package/src/missions/lifecycle.js +37 -6
- package/src/missions/store.js +1 -0
- package/src/missions/types.d.ts +2 -0
- package/src/runs/background/async-execution.d.ts +1 -1
- package/src/runs/background/async-execution.js +3 -3
- package/src/runs/background/async-resume.js +3 -2
- package/src/runs/background/retained-children.js +1 -1
- package/src/runs/foreground/subagent-executor.js +24 -51
- package/src/runs/shared/capability-ceiling.d.ts +2 -1
- package/src/runs/shared/capability-ceiling.js +3 -2
- package/src/runs/shared/parallel-handoff.d.ts +1 -1
- package/src/runs/shared/parallel-handoff.js +10 -6
- package/src/shared/types.d.ts +1 -1
- package/src/workflows/scripted-workflow.js +4 -1
- package/workflow-script-worker.cjs +2 -1
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
} from "./chunk-YFCK7H2S.js";
|
|
11
11
|
import {
|
|
12
12
|
normalizeCapabilityCeilingAllowedAgents
|
|
13
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-QXASAHIA.js";
|
|
14
14
|
|
|
15
15
|
// src/shared/file-system-retry.ts
|
|
16
16
|
var WAIT_BUFFER = typeof SharedArrayBuffer !== "undefined" ? new SharedArrayBuffer(4) : void 0;
|
|
@@ -338,16 +338,12 @@ function parseFrontmatter(content) {
|
|
|
338
338
|
const indent = line.search(/\S|$/);
|
|
339
339
|
const trimmed = line.trim();
|
|
340
340
|
if (trimmed.startsWith("#") && !currentFolded && !currentLiteral) continue;
|
|
341
|
-
if (currentKey !== null && currentBlockLines !== null && (indent > (currentIndent ?? 0) ||
|
|
341
|
+
if (currentKey !== null && currentBlockLines !== null && (indent > (currentIndent ?? 0) || trimmed === "")) {
|
|
342
342
|
currentBlockLines.push(line);
|
|
343
343
|
continue;
|
|
344
344
|
}
|
|
345
345
|
if (currentKey !== null && currentBlockLines !== null) {
|
|
346
|
-
|
|
347
|
-
const leadingSpaces = rawBlock.match(/^[ \t]+(?=\S)/m);
|
|
348
|
-
const prefix = leadingSpaces?.[0] ?? "";
|
|
349
|
-
const stripped = prefix ? rawBlock.replace(new RegExp(`^${escapeRegex(prefix)}`, "gm"), "").replace(/^\n/, "") : rawBlock;
|
|
350
|
-
frontmatter[currentKey] = currentFolded ? foldBlock(stripped) : stripped;
|
|
346
|
+
frontmatter[currentKey] = flushBlockLines(currentBlockLines, currentFolded, currentLiteral);
|
|
351
347
|
currentKey = null;
|
|
352
348
|
currentBlockLines = null;
|
|
353
349
|
currentIndent = null;
|
|
@@ -378,14 +374,22 @@ function parseFrontmatter(content) {
|
|
|
378
374
|
}
|
|
379
375
|
}
|
|
380
376
|
if (currentKey !== null && currentBlockLines !== null) {
|
|
381
|
-
|
|
382
|
-
const leadingSpaces = rawBlock.match(/^[ \t]+(?=\S)/m);
|
|
383
|
-
const prefix = leadingSpaces?.[0] ?? "";
|
|
384
|
-
const stripped = prefix ? rawBlock.replace(new RegExp(`^${escapeRegex(prefix)}`, "gm"), "").replace(/^\n/, "") : rawBlock;
|
|
385
|
-
frontmatter[currentKey] = currentFolded ? foldBlock(stripped) : stripped;
|
|
377
|
+
frontmatter[currentKey] = flushBlockLines(currentBlockLines, currentFolded, currentLiteral);
|
|
386
378
|
}
|
|
387
379
|
return { frontmatter, body };
|
|
388
380
|
}
|
|
381
|
+
function flushBlockLines(blockLines, folded, literal) {
|
|
382
|
+
let lines = blockLines;
|
|
383
|
+
if (!folded && !literal) {
|
|
384
|
+
const end = lines.indexOf("", lines.findLastIndex((line) => line.trim() !== "") + 1);
|
|
385
|
+
lines = lines.slice(lines.findIndex((line) => line !== ""), end < 0 ? lines.length : end);
|
|
386
|
+
}
|
|
387
|
+
const rawBlock = lines.join("\n");
|
|
388
|
+
const leadingSpaces = rawBlock.match(/^[ \t]+(?=\S)/m);
|
|
389
|
+
const prefix = leadingSpaces?.[0] ?? "";
|
|
390
|
+
const stripped = prefix ? rawBlock.replace(new RegExp(`^${escapeRegex(prefix)}`, "gm"), "").replace(/^\n/, "") : rawBlock;
|
|
391
|
+
return folded ? foldBlock(stripped) : stripped;
|
|
392
|
+
}
|
|
389
393
|
|
|
390
394
|
// src/shared/utils.ts
|
|
391
395
|
import * as fs14 from "node:fs";
|
|
@@ -6143,8 +6147,7 @@ function buildAgentDiscoverySources(cwd, preferredModelProvider, globalNpmRoot,
|
|
|
6143
6147
|
const watchPaths = /* @__PURE__ */ new Set([
|
|
6144
6148
|
userSettingsPath,
|
|
6145
6149
|
...projectSettingsPath ? [projectSettingsPath] : [],
|
|
6146
|
-
...projectDiscoveryWatchPaths(effectiveCwd),
|
|
6147
|
-
...findProjectRootCandidates(effectiveCwd).map((root) => path11.join(getProjectConfigDir(root), "settings.json")),
|
|
6150
|
+
...projectTrusted ? [...projectDiscoveryWatchPaths(effectiveCwd), ...findProjectRootCandidates(effectiveCwd).map((root) => path11.join(getProjectConfigDir(root), "settings.json"))] : [],
|
|
6148
6151
|
...userScanDirs.watchPaths,
|
|
6149
6152
|
...projectScanDirs.watchPaths,
|
|
6150
6153
|
...packageSubagentPaths.watchPaths
|
|
@@ -15,15 +15,15 @@ import {
|
|
|
15
15
|
resolveCurrentSessionId,
|
|
16
16
|
resolveWatchdogReviewModel,
|
|
17
17
|
startWatchdogDiffBaselineCapture
|
|
18
|
-
} from "./chunk-
|
|
18
|
+
} from "./chunk-UFL7IYCW.js";
|
|
19
19
|
import {
|
|
20
20
|
MODEL_ONLY_TOOL,
|
|
21
21
|
agentStreamOptions,
|
|
22
22
|
opencodeSessionHeaders
|
|
23
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-UYK5MZWE.js";
|
|
24
24
|
import {
|
|
25
25
|
inheritedNestedRouteOf
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-RNIZLSEA.js";
|
|
27
27
|
import {
|
|
28
28
|
CHILD_WATCHDOG_STATUS_EVENT,
|
|
29
29
|
MISSING_STRUCTURED_ACCEPTANCE_REPORT_ERROR,
|
|
@@ -39,7 +39,7 @@ import {
|
|
|
39
39
|
toolBudgetSoftNudge,
|
|
40
40
|
validateAcceptanceReport,
|
|
41
41
|
validateStructuredOutputValue
|
|
42
|
-
} from "./chunk-
|
|
42
|
+
} from "./chunk-LNRJCP2Y.js";
|
|
43
43
|
import {
|
|
44
44
|
INTERCOM_SESSION_IDENTITY_EVENT
|
|
45
45
|
} from "./chunk-JEZOSEWG.js";
|
|
@@ -11,13 +11,13 @@ import {
|
|
|
11
11
|
validateAuthorityPolicy,
|
|
12
12
|
validateMissionStoreConfig,
|
|
13
13
|
validateModelResponseAliases
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-RNIZLSEA.js";
|
|
15
15
|
import {
|
|
16
16
|
getAgentDir,
|
|
17
17
|
readStatus,
|
|
18
18
|
validatePermissionConfig,
|
|
19
19
|
writePrivateAtomicJson
|
|
20
|
-
} from "./chunk-
|
|
20
|
+
} from "./chunk-LNRJCP2Y.js";
|
|
21
21
|
import {
|
|
22
22
|
FLEET_KEYBINDING_ACTIONS,
|
|
23
23
|
RUNNER_LAUNCHER_NAME_PATTERN,
|
|
@@ -118,8 +118,8 @@ function resolveSubagentCapabilityCeiling(sessionId, inherited) {
|
|
|
118
118
|
}
|
|
119
119
|
return intersectSubagentCapabilityCeilings(inherited, ...active);
|
|
120
120
|
}
|
|
121
|
-
function resolveCurrentSubagentCapabilityCeiling(
|
|
122
|
-
return resolveSubagentCapabilityCeiling(
|
|
121
|
+
function resolveCurrentSubagentCapabilityCeiling(piSessionId) {
|
|
122
|
+
return resolveSubagentCapabilityCeiling(piSessionId, void 0);
|
|
123
123
|
}
|
|
124
124
|
function isAgentAllowedByCapabilityCeiling(agentName, ceiling) {
|
|
125
125
|
return ceiling?.allowedAgents === void 0 || ceiling.allowedAgents.includes(agentName);
|