@ai-agent-forge/plugin-subagent-delegate 0.88.10 → 0.88.12

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/README.md CHANGED
@@ -38,6 +38,15 @@ server, progress face, and mailbox come from `@agent-forge/protocol`;
38
38
  agent-task contracts, durable service types, and session lineage reading come
39
39
  from `@agent-forge/plugin-sdk`.
40
40
 
41
+ ## 关闭边界与真实验收
42
+
43
+ runner pool 关闭后不再接受任务。在途 hello 被取消,尚未完成的 spawn 返回句柄后直接回收,
44
+ 不登记 runner 或再发 create,不触发替代 spawn;已经完成的任务结果保持原样。
45
+ spawn 工厂同步失败保留原错并结束本次创建,下一次显式创建可恢复,不会自动重跑原任务。
46
+ 真实 pooled 验收先在测试私有 agentDir 通过生产 bootstrap 准备插件依赖,再计时验证模型任务、
47
+ 取消和崩溃恢复。准备成功必须有实际 bootstrap 结果,offline/disabled 跳过不算成功。
48
+ 详见 `docs/design/冷资源准备与取消边界.md`。
49
+
41
50
  ## Capabilities
42
51
 
43
52
  Requires `session` + `tools`; `agents` is optional (leaf sessions register
package/agent-forge.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "packageFormatVersion": 1,
3
3
  "id": "agent-forge.plugin.subagent-delegate",
4
- "pluginVersion": "0.88.10",
4
+ "pluginVersion": "0.88.12",
5
5
  "apiVersion": "1",
6
6
  "minHostVersion": "0.84.4",
7
7
  "platform": {
@@ -1,4 +1,4 @@
1
- import { type AgentTaskAdapter, type AgentTaskChildProfileV1, type CapabilityAPI, type DisposableRegistration, type LoggerAPI, type SessionAPI, type SubagentCommunicationWiringV1 } from "@agent-forge/plugin-sdk";
1
+ import { type AgentTaskAdapter, type AgentTaskChildProfileV1, type CapabilityAPI, type DisposableRegistration, type DurableServiceV1, type LoggerAPI, type SessionAPI, type SubagentCommunicationWiringV1 } from "@agent-forge/plugin-sdk";
2
2
  import { type SubagentRunnerSpawnHandleV1 } from "./runner-pool.ts";
3
3
  import { type SubagentRuntimeLimitsV1, type SubagentRuntimeStatus } from "./subagent-runtime.ts";
4
4
  export declare const capabilityManifest: {
@@ -76,6 +76,18 @@ export interface SubagentDelegateCapabilityOptions {
76
76
  * 发生在父回合工具阶段、此时有值。getter 缺席或返回 undefined 时不写键,行为回退。
77
77
  */
78
78
  getTurnCorrelationId?: () => string | undefined;
79
+ /**
80
+ * Durable 终态持久化(durable replay assembly,2026-10-13 用户裁决):宿主注入
81
+ * durable 设施(store + writerId,写者租约生命周期由宿主持有),调度器按 `subagent-task:<taskId>` 落库终态
82
+ * 信封,`subagent_result` 跨进程重启后仍可读回(日志在 `<agentDir>/durable/`,
83
+ * 独立于 sessions 树,主会话删除/清理不波及)。未注入 = 优雅降级为现状(内存
84
+ * 记录 + transcript 落盘,`result()` 回 undefined);持久化失败不吞终态——错误经
85
+ * drain()/dispose() 的 reject 通道暴露(两处调用点都有 catch 臂)。
86
+ */
87
+ results?: {
88
+ readonly store: DurableServiceV1;
89
+ readonly writerId: string;
90
+ };
79
91
  }
80
92
  /** 结构化错误码:调用形状错误、批上限错误与未知角色分开表达,便于调用方分支。 */
81
93
  export type SubagentDelegateErrorCodesV1 = "subagent_invalid_input" | "subagent_batch_too_large" | "subagent_unknown_role"