pi-subagents 0.73.1 → 0.74.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (237) hide show
  1. package/CHANGELOG.md +54 -0
  2. package/README.md +1 -1
  3. package/docs/agents.md +16 -12
  4. package/docs/configuration.md +66 -9
  5. package/docs/extension-api.md +5 -4
  6. package/docs/missions.md +13 -13
  7. package/docs/models.md +2 -2
  8. package/docs/observability.md +2 -2
  9. package/docs/tool-reference.md +63 -86
  10. package/docs/workflows.md +165 -171
  11. package/package.json +2 -2
  12. package/prompts/review-loop.md +1 -1
  13. package/skills/council-mode/SKILL.md +1 -1
  14. package/skills/pi-subagents/SKILL.md +12 -5
  15. package/skills/pi-subagents/references/constraints-and-recipes.md +3 -3
  16. package/skills/pi-subagents/references/execution-controls.md +68 -67
  17. package/skills/pi-subagents/references/management-authoring-rpc.md +2 -2
  18. package/skills/pi-subagents/references/multi-lane-orchestration.md +1 -1
  19. package/skills/pi-subagents/references/prompting-and-roles.md +45 -48
  20. package/src/agents/agent-management.js +2 -2
  21. package/src/agents/agent-management.js.map +1 -1
  22. package/src/agents/agents.d.ts +1 -0
  23. package/src/agents/agents.d.ts.map +1 -1
  24. package/src/agents/agents.js +8 -0
  25. package/src/agents/agents.js.map +1 -1
  26. package/src/api/preflight.d.ts +5 -1
  27. package/src/api/preflight.d.ts.map +1 -1
  28. package/src/api/preflight.js +2 -1
  29. package/src/api/preflight.js.map +1 -1
  30. package/src/extension/config.d.ts.map +1 -1
  31. package/src/extension/config.js +12 -4
  32. package/src/extension/config.js.map +1 -1
  33. package/src/extension/control-notices.d.ts +2 -0
  34. package/src/extension/control-notices.d.ts.map +1 -1
  35. package/src/extension/control-notices.js +2 -0
  36. package/src/extension/control-notices.js.map +1 -1
  37. package/src/extension/doctor.d.ts.map +1 -1
  38. package/src/extension/doctor.js +1 -0
  39. package/src/extension/doctor.js.map +1 -1
  40. package/src/extension/fanout-child.d.ts.map +1 -1
  41. package/src/extension/fanout-child.js +13 -3
  42. package/src/extension/fanout-child.js.map +1 -1
  43. package/src/extension/herdr-pi-bridge.d.ts.map +1 -1
  44. package/src/extension/herdr-pi-bridge.js +2 -0
  45. package/src/extension/herdr-pi-bridge.js.map +1 -1
  46. package/src/extension/index.d.ts +1 -1
  47. package/src/extension/index.d.ts.map +1 -1
  48. package/src/extension/index.js +62 -161
  49. package/src/extension/index.js.map +1 -1
  50. package/src/extension/public-execution.d.ts +10 -1
  51. package/src/extension/public-execution.d.ts.map +1 -1
  52. package/src/extension/public-execution.js +69 -35
  53. package/src/extension/public-execution.js.map +1 -1
  54. package/src/extension/reply-workflow-script.d.ts +12 -0
  55. package/src/extension/reply-workflow-script.d.ts.map +1 -0
  56. package/src/extension/reply-workflow-script.js +61 -0
  57. package/src/extension/reply-workflow-script.js.map +1 -0
  58. package/src/extension/rpc.d.ts +2 -0
  59. package/src/extension/rpc.d.ts.map +1 -1
  60. package/src/extension/rpc.js +33 -10
  61. package/src/extension/rpc.js.map +1 -1
  62. package/src/extension/schemas.d.ts +3 -117
  63. package/src/extension/schemas.d.ts.map +1 -1
  64. package/src/extension/schemas.js +38 -125
  65. package/src/extension/schemas.js.map +1 -1
  66. package/src/extension/tool-activation.d.ts +2 -4
  67. package/src/extension/tool-activation.d.ts.map +1 -1
  68. package/src/extension/tool-activation.js +54 -104
  69. package/src/extension/tool-activation.js.map +1 -1
  70. package/src/extension/tool-description.d.ts +8 -5
  71. package/src/extension/tool-description.d.ts.map +1 -1
  72. package/src/extension/tool-description.js +51 -27
  73. package/src/extension/tool-description.js.map +1 -1
  74. package/src/extension/upgrade-notice.d.ts +7 -0
  75. package/src/extension/upgrade-notice.d.ts.map +1 -0
  76. package/src/extension/upgrade-notice.js +37 -0
  77. package/src/extension/upgrade-notice.js.map +1 -0
  78. package/src/integrations/herdr-status.d.ts +3 -0
  79. package/src/integrations/herdr-status.d.ts.map +1 -1
  80. package/src/integrations/herdr-status.js +17 -3
  81. package/src/integrations/herdr-status.js.map +1 -1
  82. package/src/intercom/native-supervisor-channel.d.ts.map +1 -1
  83. package/src/intercom/native-supervisor-channel.js +4 -1
  84. package/src/intercom/native-supervisor-channel.js.map +1 -1
  85. package/src/runs/background/async-execution.d.ts +3 -0
  86. package/src/runs/background/async-execution.d.ts.map +1 -1
  87. package/src/runs/background/async-execution.js +6 -2
  88. package/src/runs/background/async-execution.js.map +1 -1
  89. package/src/runs/background/async-job-tracker.d.ts.map +1 -1
  90. package/src/runs/background/async-job-tracker.js +65 -22
  91. package/src/runs/background/async-job-tracker.js.map +1 -1
  92. package/src/runs/background/async-retention.d.ts +1 -1
  93. package/src/runs/background/async-retention.d.ts.map +1 -1
  94. package/src/runs/background/async-retention.js +47 -15
  95. package/src/runs/background/async-retention.js.map +1 -1
  96. package/src/runs/background/await-async-run.d.ts +23 -0
  97. package/src/runs/background/await-async-run.d.ts.map +1 -0
  98. package/src/runs/background/await-async-run.js +80 -0
  99. package/src/runs/background/await-async-run.js.map +1 -0
  100. package/src/runs/background/chain-root-attachment.d.ts +1 -0
  101. package/src/runs/background/chain-root-attachment.d.ts.map +1 -1
  102. package/src/runs/background/chain-root-attachment.js +3 -3
  103. package/src/runs/background/chain-root-attachment.js.map +1 -1
  104. package/src/runs/background/notify.d.ts +3 -0
  105. package/src/runs/background/notify.d.ts.map +1 -1
  106. package/src/runs/background/notify.js +3 -0
  107. package/src/runs/background/notify.js.map +1 -1
  108. package/src/runs/background/run-child-session.d.ts.map +1 -1
  109. package/src/runs/background/run-child-session.js +4 -1
  110. package/src/runs/background/run-child-session.js.map +1 -1
  111. package/src/runs/background/run-status.d.ts.map +1 -1
  112. package/src/runs/background/run-status.js +6 -0
  113. package/src/runs/background/run-status.js.map +1 -1
  114. package/src/runs/background/runner-child-launch.d.ts +1 -0
  115. package/src/runs/background/runner-child-launch.d.ts.map +1 -1
  116. package/src/runs/background/runner-child-launch.js +2 -0
  117. package/src/runs/background/runner-child-launch.js.map +1 -1
  118. package/src/runs/background/scheduled-runs.js +5 -5
  119. package/src/runs/background/scheduled-runs.js.map +1 -1
  120. package/src/runs/background/subagent-runner.d.ts +3 -0
  121. package/src/runs/background/subagent-runner.d.ts.map +1 -1
  122. package/src/runs/background/subagent-runner.js +5 -0
  123. package/src/runs/background/subagent-runner.js.map +1 -1
  124. package/src/runs/foreground/async-stop-action.d.ts.map +1 -1
  125. package/src/runs/foreground/async-stop-action.js +15 -1
  126. package/src/runs/foreground/async-stop-action.js.map +1 -1
  127. package/src/runs/foreground/execution.d.ts.map +1 -1
  128. package/src/runs/foreground/execution.js +8 -1
  129. package/src/runs/foreground/execution.js.map +1 -1
  130. package/src/runs/foreground/subagent-executor.d.ts +6 -5
  131. package/src/runs/foreground/subagent-executor.d.ts.map +1 -1
  132. package/src/runs/foreground/subagent-executor.js +293 -182
  133. package/src/runs/foreground/subagent-executor.js.map +1 -1
  134. package/src/runs/shared/child-launch.d.ts +5 -1
  135. package/src/runs/shared/child-launch.d.ts.map +1 -1
  136. package/src/runs/shared/child-launch.js +15 -1
  137. package/src/runs/shared/child-launch.js.map +1 -1
  138. package/src/runs/shared/child-session.d.ts +9 -0
  139. package/src/runs/shared/child-session.d.ts.map +1 -1
  140. package/src/runs/shared/child-session.js +90 -4
  141. package/src/runs/shared/child-session.js.map +1 -1
  142. package/src/runs/shared/child-tool-plan.d.ts +4 -0
  143. package/src/runs/shared/child-tool-plan.d.ts.map +1 -1
  144. package/src/runs/shared/child-tool-plan.js +11 -4
  145. package/src/runs/shared/child-tool-plan.js.map +1 -1
  146. package/src/runs/shared/dynamic-fanout.js +1 -1
  147. package/src/runs/shared/dynamic-fanout.js.map +1 -1
  148. package/src/runs/shared/mcp-config-sources.d.ts +1 -0
  149. package/src/runs/shared/mcp-config-sources.d.ts.map +1 -1
  150. package/src/runs/shared/mcp-config-sources.js +1 -1
  151. package/src/runs/shared/mcp-config-sources.js.map +1 -1
  152. package/src/runs/shared/mcp-direct-tool-allowlist.d.ts +28 -0
  153. package/src/runs/shared/mcp-direct-tool-allowlist.d.ts.map +1 -1
  154. package/src/runs/shared/mcp-direct-tool-allowlist.js +78 -2
  155. package/src/runs/shared/mcp-direct-tool-allowlist.js.map +1 -1
  156. package/src/runs/shared/model-resolution.d.ts +10 -0
  157. package/src/runs/shared/model-resolution.d.ts.map +1 -1
  158. package/src/runs/shared/model-resolution.js +30 -9
  159. package/src/runs/shared/model-resolution.js.map +1 -1
  160. package/src/runs/shared/model-scope.d.ts +2 -1
  161. package/src/runs/shared/model-scope.d.ts.map +1 -1
  162. package/src/runs/shared/model-scope.js +26 -10
  163. package/src/runs/shared/model-scope.js.map +1 -1
  164. package/src/runs/shared/parallel-utils.d.ts +2 -0
  165. package/src/runs/shared/parallel-utils.d.ts.map +1 -1
  166. package/src/runs/shared/parallel-utils.js.map +1 -1
  167. package/src/runs/shared/pi-spawn.d.ts +1 -10
  168. package/src/runs/shared/pi-spawn.d.ts.map +1 -1
  169. package/src/runs/shared/pi-spawn.js +7 -86
  170. package/src/runs/shared/pi-spawn.js.map +1 -1
  171. package/src/runs/shared/subagent-prompt-runtime.d.ts.map +1 -1
  172. package/src/runs/shared/subagent-prompt-runtime.js +2 -0
  173. package/src/runs/shared/subagent-prompt-runtime.js.map +1 -1
  174. package/src/runs/shared/worktree.d.ts +1 -1
  175. package/src/runs/shared/worktree.d.ts.map +1 -1
  176. package/src/runs/shared/worktree.js +1 -1
  177. package/src/runs/shared/worktree.js.map +1 -1
  178. package/src/shared/disabled-features.d.ts +92 -0
  179. package/src/shared/disabled-features.d.ts.map +1 -0
  180. package/src/shared/disabled-features.js +113 -0
  181. package/src/shared/disabled-features.js.map +1 -0
  182. package/src/shared/extension-context.d.ts +9 -0
  183. package/src/shared/extension-context.d.ts.map +1 -1
  184. package/src/shared/extension-context.js +7 -0
  185. package/src/shared/extension-context.js.map +1 -1
  186. package/src/shared/settings.d.ts +1 -1
  187. package/src/shared/types.d.ts +20 -0
  188. package/src/shared/types.d.ts.map +1 -1
  189. package/src/shared/types.js.map +1 -1
  190. package/src/slash/prompt-template-bridge.js +2 -2
  191. package/src/slash/prompt-template-bridge.js.map +1 -1
  192. package/src/slash/slash-commands.d.ts +2 -0
  193. package/src/slash/slash-commands.d.ts.map +1 -1
  194. package/src/slash/slash-commands.js +2 -2
  195. package/src/slash/slash-commands.js.map +1 -1
  196. package/src/tui/render.d.ts.map +1 -1
  197. package/src/tui/render.js +55 -17
  198. package/src/tui/render.js.map +1 -1
  199. package/src/watchdog/diff-tool.d.ts +3 -1
  200. package/src/watchdog/diff-tool.d.ts.map +1 -1
  201. package/src/watchdog/diff-tool.js +20 -11
  202. package/src/watchdog/diff-tool.js.map +1 -1
  203. package/src/watchdog/register-child.js +2 -2
  204. package/src/watchdog/register-child.js.map +1 -1
  205. package/src/watchdog/register-main.js +2 -2
  206. package/src/watchdog/register-main.js.map +1 -1
  207. package/src/watchdog/review.d.ts +1 -1
  208. package/src/watchdog/review.d.ts.map +1 -1
  209. package/src/watchdog/review.js +1 -1
  210. package/src/watchdog/review.js.map +1 -1
  211. package/src/watchdog/turn-delta.js +1 -1
  212. package/src/watchdog/turn-delta.js.map +1 -1
  213. package/src/workflows/chat-progress.js +2 -2
  214. package/src/workflows/chat-progress.js.map +1 -1
  215. package/src/workflows/scripted-workflow.d.ts +8 -0
  216. package/src/workflows/scripted-workflow.d.ts.map +1 -1
  217. package/src/workflows/scripted-workflow.js +10 -2
  218. package/src/workflows/scripted-workflow.js.map +1 -1
  219. package/src/workflows/structured-workflow-scripts.d.ts +10 -0
  220. package/src/workflows/structured-workflow-scripts.d.ts.map +1 -0
  221. package/src/workflows/structured-workflow-scripts.js +166 -0
  222. package/src/workflows/structured-workflow-scripts.js.map +1 -0
  223. package/src/workflows/workflow-receipt.d.ts.map +1 -1
  224. package/src/workflows/workflow-receipt.js +8 -2
  225. package/src/workflows/workflow-receipt.js.map +1 -1
  226. package/src/workflows/workflow-resources.d.ts +9 -0
  227. package/src/workflows/workflow-resources.d.ts.map +1 -1
  228. package/src/workflows/workflow-resources.js +39 -12
  229. package/src/workflows/workflow-resources.js.map +1 -1
  230. package/src/workflows/workflow-reuse.d.ts +51 -0
  231. package/src/workflows/workflow-reuse.d.ts.map +1 -0
  232. package/src/workflows/workflow-reuse.js +103 -0
  233. package/src/workflows/workflow-reuse.js.map +1 -0
  234. package/src/workflows/workflow-revival.d.ts +32 -0
  235. package/src/workflows/workflow-revival.d.ts.map +1 -0
  236. package/src/workflows/workflow-revival.js +111 -0
  237. package/src/workflows/workflow-revival.js.map +1 -0
@@ -0,0 +1,111 @@
1
+ import * as fs from "node:fs";
2
+ import * as path from "node:path";
3
+ import { writePrivateAtomicJson } from "../shared/atomic-json.js";
4
+ import { readStatus } from "../shared/utils.js";
5
+ /**
6
+ * A top-level resume of a failed async workflow child starts a detached run. These records
7
+ * link that run back to its workflow key without writing the workflow's own status or receipt.
8
+ * The source run is terminal, so the live workflow host never writes its directory.
9
+ */
10
+ const REVIVAL_LINK_FILE = "workflow-revival.json";
11
+ /** The same link, kept in the revived run's directory so reviving it again keeps the key. */
12
+ export const REVIVAL_ORIGIN_FILE = "workflow-revival-origin.json";
13
+ /** Recording refuses a deeper link, so readers bounded by this always reach the chain's end. */
14
+ const MAX_REVIVAL_DEPTH = 16;
15
+ const KEY_PATTERN = /^[A-Za-z0-9][A-Za-z0-9._-]{0,127}$/;
16
+ function isRunId(value) {
17
+ return typeof value === "string" && value.length > 0 && value.length <= 255 && path.basename(value) === value && value !== "." && value !== "..";
18
+ }
19
+ function readLink(file) {
20
+ let value;
21
+ try {
22
+ value = JSON.parse(fs.readFileSync(file, "utf-8"));
23
+ }
24
+ catch {
25
+ return undefined;
26
+ }
27
+ if (!value || typeof value !== "object" || Array.isArray(value))
28
+ return undefined;
29
+ const link = value;
30
+ if (link.version !== 1 || !isRunId(link.workflowRunId) || typeof link.workflowKey !== "string" || !KEY_PATTERN.test(link.workflowKey) || !isRunId(link.sourceRunId) || !isRunId(link.revivedRunId))
31
+ return undefined;
32
+ if (!Number.isInteger(link.depth) || link.depth < 1 || link.depth > MAX_REVIVAL_DEPTH)
33
+ return undefined;
34
+ return { version: 1, workflowRunId: link.workflowRunId, workflowKey: link.workflowKey, sourceRunId: link.sourceRunId, revivedRunId: link.revivedRunId, depth: link.depth };
35
+ }
36
+ /**
37
+ * Links a detached revival to the workflow key of its source run when the source failed and is
38
+ * an async workflow child or an earlier revival of one. Throws when the source status cannot be
39
+ * read or the key's revival chain is full; the caller reports that on the revive receipt.
40
+ */
41
+ export function recordWorkflowRevival(asyncDirRoot, sourceRunId, revivedRunId) {
42
+ const sourceDir = path.join(asyncDirRoot, sourceRunId);
43
+ const status = readStatus(sourceDir);
44
+ if (status?.runId !== sourceRunId || status.state !== "failed")
45
+ return;
46
+ const origin = isRunId(status.parentWorkflowRunId) && typeof status.workflowKey === "string" && KEY_PATTERN.test(status.workflowKey)
47
+ ? { workflowRunId: status.parentWorkflowRunId, workflowKey: status.workflowKey, depth: 0 }
48
+ : readLink(path.join(sourceDir, REVIVAL_ORIGIN_FILE));
49
+ if (!origin || ("revivedRunId" in origin && origin.revivedRunId !== sourceRunId))
50
+ return;
51
+ if (origin.depth >= MAX_REVIVAL_DEPTH)
52
+ throw new Error(`workflow key '${origin.workflowKey}' of ${origin.workflowRunId} already has ${MAX_REVIVAL_DEPTH} chained revivals.`);
53
+ const link = { version: 1, workflowRunId: origin.workflowRunId, workflowKey: origin.workflowKey, sourceRunId, revivedRunId, depth: origin.depth + 1 };
54
+ const originFile = path.join(asyncDirRoot, revivedRunId, REVIVAL_ORIGIN_FILE);
55
+ writePrivateAtomicJson(originFile, link);
56
+ try {
57
+ writePrivateAtomicJson(path.join(sourceDir, REVIVAL_LINK_FILE), link);
58
+ }
59
+ catch (error) {
60
+ // Keep the origin exactly when the published link names this revival: an unlinked origin
61
+ // would only pin the run against retention, and a linked one protects the key's chain.
62
+ if (readLink(path.join(sourceDir, REVIVAL_LINK_FILE))?.revivedRunId !== revivedRunId)
63
+ fs.rmSync(originFile, { force: true });
64
+ throw error;
65
+ }
66
+ }
67
+ /**
68
+ * Follows revival links from one run of a workflow key by exact reads. Returns undefined when
69
+ * the run was never revived; malformed or mismatched links end the chain.
70
+ */
71
+ export function projectWorkflowKeyRevival(asyncDirRoot, workflowRunId, workflowKey, runId) {
72
+ if (!isRunId(runId))
73
+ return undefined;
74
+ const revivedRunIds = [];
75
+ let current = runId;
76
+ while (revivedRunIds.length < MAX_REVIVAL_DEPTH) {
77
+ const link = readLink(path.join(asyncDirRoot, current, REVIVAL_LINK_FILE));
78
+ if (!link || link.sourceRunId !== current || link.workflowRunId !== workflowRunId || link.workflowKey !== workflowKey)
79
+ break;
80
+ revivedRunIds.push(link.revivedRunId);
81
+ current = link.revivedRunId;
82
+ }
83
+ if (revivedRunIds.length === 0)
84
+ return undefined;
85
+ let status = null;
86
+ try {
87
+ status = readStatus(path.join(asyncDirRoot, current));
88
+ }
89
+ catch {
90
+ // Readers show "status unavailable" instead of failing the workflow's status or notice.
91
+ }
92
+ return { revivedRunIds, latestRunId: current, ...(status?.runId === current ? { state: status.state } : {}) };
93
+ }
94
+ /** `Revived → <run> [→ <run>]: <state>`, shown next to the key's original failure. */
95
+ export function formatWorkflowKeyRevival(revival) {
96
+ return `Revived → ${revival.revivedRunIds.join(" → ")}: ${revival.state === "complete" ? "completed" : revival.state ?? "status unavailable"}`;
97
+ }
98
+ /**
99
+ * Adds each failed child's revivals to its lineage, so the receipt's latest run for that key is
100
+ * the newest revival. The child's own result and evidence stay as they were.
101
+ */
102
+ export function withWorkflowRevivals(asyncDirRoot, workflowRunId, children) {
103
+ return children.map((child) => {
104
+ if (child.ok || child.state === "running" || !child.runId)
105
+ return child;
106
+ const lineage = child.continuation?.runIds ?? [child.runId];
107
+ const revival = projectWorkflowKeyRevival(asyncDirRoot, workflowRunId, child.key, lineage.at(-1) ?? child.runId);
108
+ return revival ? { ...child, continuation: { runIds: [...lineage, ...revival.revivedRunIds] }, revival } : child;
109
+ });
110
+ }
111
+ //# sourceMappingUR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