@deepseek-ai/dsh-goal-round-driver 0.1.1-rc.2 → 0.1.2-alpha.2

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.i18n.yaml CHANGED
@@ -2,5 +2,5 @@
2
2
  # side as of the last confirmed-consistent state. Both languages carry equal authority;
3
3
  # after editing either side, bring the other along and re-record with:
4
4
  # pnpm run verify-translation-pairing --write packages/goal/goal-round-driver/README.md
5
- README.md: 34b11714b8ccf574549567f33b80204f3c0dde6a
6
- README.zh.md: be41c12258214aa8aa5323c73ec144642fb121ff
5
+ README.md: 18b086b9b2cef84861a54cbebda413cb1444d24f
6
+ README.zh.md: ca38b5f6cc9e6a5292c91008321ea254a698f2b5
package/README.md CHANGED
@@ -1,10 +1,35 @@
1
+ ---
2
+ description: "The same-session continuation driver for users and maintainers choosing, composing, or debugging automatic goal rounds."
3
+ kind: "package-reference"
4
+ ---
5
+
1
6
  # @deepseek-ai/dsh-goal-round-driver
2
7
 
3
8
  English | [中文](README.zh.md)
4
9
 
5
- Same-session continuation driver for [`ctx.goals`](../goal/README.md). It turns an active, armed goal into sequential [goal rounds](../../../docs/glossary.md#goal-round) through the public `Agent` and session services; the [same-session driver Agent Note](../../../.agents/notes/implemented/feature/2026-07-19-same-session-goal-round-driver.md) owns the race and lifecycle rationale.
10
+ ## Summary
11
+
12
+ `dsh-goal-round-driver` automatically continues an active goal in the same session: whenever the agent is idle with an active, armed goal and remaining round capacity, the driver starts the next goal round. Each round is one model turn toward the objective, driven by a retained goal-round prompt; only goal-sourced rounds count against the goal's round cap, and the goal records a blocker when the cap is exhausted. The driver has no configuration of its own — the round cap belongs to the goal definition and the model-facing blocked threshold belongs to `dsh-tool-goal`, so policy stays in one place. Mount it together with `dsh-goal` and `dsh-tool-goal` when a task should work itself toward completion across rounds; leave it out when every step needs human steering.
13
+
14
+ ## Table of Contents
15
+
16
+ - [Use this package](#use-this-package)
17
+ - [Understand the implementation](#understand-the-implementation)
18
+ - [Further Exploration](#further-exploration)
19
+ - [Model Experience](#model-experience)
20
+ - [Known Limitations and Deferred Work](#known-limitations-and-deferred-work)
21
+ - [Dev Note](#dev-note)
22
+
23
+ -----
24
+
25
+ <a id="use-this-package"></a>
26
+ ## Use this package
27
+
28
+ Mount `dsh-goal-round-driver` when an active goal should keep making progress without human intervention. It composes with the goal service and the goal tools: the service owns the state, the tools give the model control over it, and this package schedules the rounds.
6
29
 
7
- ## Composition
30
+ ### Compose it
31
+
32
+ Mount the driver beside the goal service and the goal tools; the driver itself takes no configuration.
8
33
 
9
34
  ```yaml
10
35
  - id: goal
@@ -17,28 +42,65 @@ Same-session continuation driver for [`ctx.goals`](../goal/README.md). It turns
17
42
  name: '@deepseek-ai/dsh-goal-round-driver'
18
43
  ```
19
44
 
20
- The plugin has no tunable configuration. `maxGoalRounds` belongs to the goal definition, while the model-facing blocked threshold belongs to [`dsh-tool-goal`](../tool-goal/README.md); duplicating either value in the driver could produce divergent policy.
45
+ `maxGoalRounds` belongs to the goal definition, while the model-facing blocked threshold belongs to `dsh-tool-goal`; duplicating either value in the driver could produce divergent policy.
46
+
47
+ ### What each round does
48
+
49
+ With an exact live agent idle, an active armed goal, and remaining capacity, the driver queues one goal-round prompt. It names the JSON-quoted objective, round number, and cap, and tells the model to use current workspace, tool results, and durable state as authority. An accepted round starts a distinct request series, so Chat renders its self-contained request header before the goal message. The round enters history as a goal-sourced user message; only an entered goal message consumes the cap, while human messages and stale reservations do not. Goal lifecycle mutations still require the independent authority checks in `dsh-tool-goal`.
50
+
51
+ ### When continuation stops
52
+
53
+ A round starts only at whole-agent idle, and completion, pause, and blocking suppress continuation; an edit only invalidates an in-flight round through the revision fence, and the driver continues the new revision. The driver also stops on its own when a turn ends on max tokens, a durability write fails, the agent is cancelled, the plugin unloads, or the round cap is exhausted — at the cap it records a blocker with the stable code `round-limit`. Cancellation never auto-restarts a round: a goal whose round was under way or already queued is paused at the next idle point, and a cancellation unrelated to a goal attempt only disarms continuation.
54
+
55
+ ### After resume, fork, or unload
56
+
57
+ Mounting the driver over an existing agent never arms a goal, and after session resume or fork an active goal stays disarmed until an explicit human-authorized resume — the driver never revives work on its own. Unloading the plugin cancels any in-flight round and ensures no later round starts.
21
58
 
22
- ## Round contract
59
+ -----
23
60
 
24
- When an exact live agent is idle with an active, armed goal and remaining capacity, the driver first checkpoints pending goal mutations, then reserves `roundsStarted + 1` for the current `{ goalId, revision }`. It queues one `<goal_round>` prompt with `GoalMessageSource`. The `agent/pre-step` listener verifies the complete claimed record and current goal both before and after downstream listeners; only an entered `user/message` increments `roundsStarted`. A reservation rejected as stale does not consume the round number.
61
+ <a id="understand-the-implementation"></a>
62
+ ## Understand the implementation
25
63
 
26
- `MessageId` identifies the reserved message through durable inbox insertion and claim; it does not identify a turn result. Human messages do not consume the goal cap. If human work enters the inbox before a reservation or joins its pending batch, automatic work yields until the agent becomes idle; a pending automatic prompt in a mixed batch is rejected and re-reserved only after that checkpoint.
64
+ <details>
65
+ <summary>Implementation internals — click to expand</summary>
27
66
 
28
- The retained prompt names the JSON-quoted objective and `round/maxGoalRounds`, treats the current workspace, tool results, and durable session state as authoritative, requires evidence before completion, and tells the model to leave the goal active when work remains. Quoting preserves multiline or tag-like objective text as data. Goal lifecycle mutations still require the independent authority checks in `dsh-tool-goal`.
67
+ This section explains how the driver schedules rounds without races; the observable behavior is covered in [Use this package](#use-this-package).
29
68
 
30
- ## Idle checkpoint
69
+ ### Design
31
70
 
32
- At whole-agent idle, durable goal phase and revision are authoritative. An active, armed goal with capacity reserves its next round; completion, pause, blocking, and edits suppress continuation. The driver does not classify the preceding activity by correlating the goal message with `turn/end`, so provider errors and token limits are not prompt-level goal outcomes.
71
+ - **Reservation, then admission.** At idle the driver reserves `roundsStarted + 1` for the current `{ goalId, revision }`, queues one `<goal_round>` prompt with a goal message source, and only an entered `user/message` increments `roundsStarted`. A reservation rejected as stale does not consume the round number.
72
+ - **Race fences.** The `agent/pre-step` listener verifies the complete claimed record against the current goal both before and after downstream listeners, so a stale, cancelled, or competing prompt is rejected before its step enters. Human work that arrives before a reservation makes automatic work yield until the agent is idle again.
73
+ - **Durability checkpoint.** `goal/changed` creates a durability obligation: before queuing work the driver awaits `ctx.sessions.flush()` and rechecks the goal revision and competing input after the await. A flush failure arriving through `agent/error` disarms continuation before another round can start.
74
+ - **Fail-closed teardown.** Teardown closes admission, disarms every live goal, cancels active work with the `parent` cause, and awaits the driver plus agent quiescence while its event fence remains installed.
33
75
 
34
- ## Lifecycle and durability
76
+ ### Source map
35
77
 
36
- `goal/changed` creates a durability obligation. Before queuing work, the driver awaits `ctx.sessions.flush()` and rechecks both the goal revision and competing input after the await. A flush failure arriving through `agent/error` disarms continuation before another round can start.
78
+ | File | Role |
79
+ |---|---|
80
+ | [`src/index.ts`](src/index.ts) | Plugin entry: driver state machine, race fences, teardown |
81
+ | [`src/prompt.ts`](src/prompt.ts) | The retained `<goal_round>` continuation prompt |
82
+ | [`src/invariant.ts`](src/invariant.ts) | Invariant companion: goal-round messages must match the package-owned prompt |
37
83
 
38
- Activation is never inherited when this plugin loads over an existing agent. `GoalService.disarm()` removes process-local authority without changing durable phase, revision, or history; explicit human-authorized resume records the later reactivation. The same rule applies after session resume and fork through the goal domain's `agent/session-start` handling.
84
+ ### The round prompt
39
85
 
40
- Cancellation removes pending inbox work or leaves an agent-wide aborted state. At the next idle checkpoint the driver pauses a goal with a reserved or admitted attempt so cancellation cannot auto-restart it; cancellation unrelated to a goal attempt only disarms process-local continuation. If the pause mutation fails, the driver falls back to disarming. Plugin teardown closes admission, disarms every live goal, cancels active work with the `parent` cause, and awaits the driver plus agent quiescence while its event fence remains installed.
86
+ The retained prompt is one text block: the JSON-quoted objective and `round/maxGoalRounds` on the first lines, then the working instructions. The invariant companion reconstructs the goal from the durable prefix and rejects any goal-sourced message whose content does not match the prompt exactly.
41
87
 
88
+ </details>
89
+
90
+ -----
91
+
92
+ <a id="further-exploration"></a>
93
+ ## Further Exploration
94
+
95
+ The driver consumes the goal state and defers policy to the goal tools; read these pages for the surrounding contract and the design rationale.
96
+
97
+ - [Goal service](../goal/README.md) — the goal state and lifecycle this driver continues.
98
+ - [Goal tools](../tool-goal/README.md) — the model-facing tools and their execution-time authority checks.
99
+ - [Same-session driver Agent Note](../../../.agents/notes/implemented/feature/2026-07-19-same-session-goal-round-driver.md) — the race and lifecycle rationale.
100
+
101
+ -----
102
+
103
+ <a id="model-experience"></a>
42
104
  ## Model Experience
43
105
 
44
106
  ### Goal-round prompt
@@ -57,8 +119,23 @@ Append-only within an epoch: each admitted round extends the existing conversati
57
119
 
58
120
  ## Known Limitations and Deferred Work
59
121
 
122
+ <a id="known-limitations-and-deferred-work"></a>
123
+
124
+
125
+ These limits define when the driver is a poor fit or needs special care. They are current package constraints, not a task backlog.
126
+
60
127
  - **No independent evaluator** — the model-facing goal policy decides when evidence is sufficient for completion and whether a blocker is semantically unchanged; evaluator-backed certification remains deferred.
61
128
  - **Same-session execution only** — this package deliberately does not spawn a fresh agent, fork a session prefix, or implement Ralph-style independent attempts; that workflow belongs to its own plugin layer.
62
129
  - **Accepted-queue unload race** — Cordis plugin unload is asynchronous. A goal prompt already accepted by the agent inbox can begin and consume its round before unload starts; teardown then cancels the request, disarms the goal, and awaits quiescence. No later round starts.
63
130
  - **Round cap, not resource budget** — token, currency, time, and provider quota policies remain independent. Their session events are not attributed to the goal message or mapped into goal blocker codes.
64
131
  - **No abnormal auto-retry** — transient provider and persistence failures require a later human-authorized resume rather than an implicit retry policy.
132
+
133
+ <a id="dev-note"></a>
134
+ ### Dev Note
135
+
136
+ <details>
137
+ <summary>Working context for maintainers — click to expand</summary>
138
+
139
+ This Dev Note is working context for maintainers; it is explicitly non-authoritative. Open, undecided directions: an abnormal-failure retry policy and evaluator-backed round certification; both stay outside this package by design.
140
+
141
+ </details>
package/README.zh.md CHANGED
@@ -1,10 +1,35 @@
1
+ ---
2
+ description: "面向选择、组合或排查自动 Goal Round 的用户与维护者的同会话续行驱动器说明。"
3
+ kind: "package-reference"
4
+ ---
5
+
1
6
  # @deepseek-ai/dsh-goal-round-driver
2
7
 
3
8
  [English](README.md) | 中文
4
9
 
5
- [`ctx.goals`](../goal/README.zh.md) 的同会话续行驱动器。它通过公开 `Agent` 与会话服务,把 phase 为 active 且已启用续行的目标转换为连续的 [Goal Round](../../../docs/glossary.zh.md#goal-round);[同会话驱动器 Agent Note](../../../.agents/notes/implemented/feature/2026-07-19-same-session-goal-round-driver.zh.md) 记载竞态与生命周期方面的设计理由。
10
+ ## 概述
11
+
12
+ `dsh-goal-round-driver` 会在同一会话中自动继续 active 的 goal:每当 agent 空闲且存在 active、已启用续行并有剩余容量的 goal 时,驱动器就会启动下一个 Goal Round。每一轮都是朝目标前进的一次模型轮次,由保留的 goal-round 提示词驱动;只有来源为 goal 的 Round 会计入 goal 的 Round 上限,上限耗尽时 goal 会记录一个 blocker。驱动器没有自己的配置——Round 上限属于 goal 定义,面向模型的阻塞阈值属于 `dsh-tool-goal`,策略因此只保留在一处。当任务应跨多轮自行推进时,与 `dsh-goal` 和 `dsh-tool-goal` 一起挂载它;当每一步都需要人工 steering(中途引导)时,不要挂载。
13
+
14
+ ## 目录
15
+
16
+ - [使用本包](#use-this-package)
17
+ - [理解实现](#understand-the-implementation)
18
+ - [进一步探索](#further-exploration)
19
+ - [模型体验](#model-experience)
20
+ - [已知限制与延期工作](#known-limitations-and-deferred-work)
21
+ - [开发备注](#dev-note)
22
+
23
+ -----
24
+
25
+ <a id="use-this-package"></a>
26
+ ## 使用本包
27
+
28
+ 当 active 的 goal 应在无人干预的情况下持续推进时,挂载 `dsh-goal-round-driver`。它与 goal 服务和 goal 工具组合使用:服务拥有状态,工具让模型控制状态,本包负责调度轮次。
6
29
 
7
- ## 组合
30
+ ### 组合方式
31
+
32
+ 把驱动器挂载在 goal 服务与 goal 工具旁边;驱动器本身不需要任何配置。
8
33
 
9
34
  ```yaml
10
35
  - id: goal
@@ -17,28 +42,65 @@
17
42
  name: '@deepseek-ai/dsh-goal-round-driver'
18
43
  ```
19
44
 
20
- 该插件没有可调配置。`maxGoalRounds` 属于目标定义,面向模型的阻塞阈值则属于 [`dsh-tool-goal`](../tool-goal/README.zh.md);在驱动器中重复任一数值都可能产生分歧策略。
45
+ `maxGoalRounds` 属于 goal 定义,面向模型的阻塞阈值属于 `dsh-tool-goal`;在驱动器中重复任一数值都可能产生分歧策略。
46
+
47
+ ### 每轮做什么
48
+
49
+ 当对应的活跃 agent 处于 idle,且存在 active、已启用续行、仍有容量的 goal 时,驱动器会排入一条 goal-round 提示词。它点明以 JSON 引用的目标、Round 编号与上限,并告诉模型以当前工作区、工具结果和持久状态为准。被接纳的 Round 会开启独立请求序列,因此 Chat 会在 goal 消息之前渲染其自包含请求 header。该 Round 以 goal 来源的用户消息进入历史;只有进入步骤的 goal 消息消耗上限,人类消息和陈旧预留不会消耗。goal 生命周期变更仍必须通过 `dsh-tool-goal` 的独立权限检查。
50
+
51
+ ### 何时停止续行
52
+
53
+ Round 只在整个 agent 进入 idle 时启动;完成、暂停和阻塞会阻止续行;编辑只会通过修订栅栏使进行中的 Round 失效,驱动器会继续新修订。驱动器也会在以下情况自行停止:轮次因 max tokens 结束、持久性写入失败、agent 被取消、插件卸载,或 Round 上限耗尽——上限耗尽时它会以稳定代码 `round-limit` 记录一个 blocker。取消绝不会自动重启 Round:Round 已在进行或已排入队列的 goal 会在下一次 idle 时被暂停;与 goal 尝试无关的取消只会停用续行。
54
+
55
+ ### resume、fork 或卸载之后
56
+
57
+ 把驱动器挂载到现有 agent 上绝不会启用任何 goal 的续行;会话 resume 或 fork 后,active 的 goal 会保持停用续行,直到用户明确授权 resume——驱动器绝不会自行复活工作。卸载插件会取消进行中的 Round,并确保不再启动后续 Round。
21
58
 
22
- ## Round 约定
59
+ -----
23
60
 
24
- 当对应的活跃 agent(智能体)实例处于 idle 状态,且目标 phase 为 active、已启用续行并有剩余容量时,驱动器先为待处理 goal 变更创建检查点,再预留 `roundsStarted + 1`,对应当前 `{ goalId, revision }`。它会排入一条 `<goal_round>` 提示词,并携带 `GoalMessageSource`。`agent/pre-step` 监听器会在下游监听器前后验证完整的已领取记录与当前 goal;只有进入步骤的 `user/message` 才会增加 `roundsStarted`。因陈旧而被拒绝的预留不会消耗 Round 编号。
61
+ <a id="understand-the-implementation"></a>
62
+ ## 理解实现
25
63
 
26
- `MessageId` 通过持久 inbox 插入和领取来标识预留消息;它不标识轮次结果。人类消息不消耗 goal 上限。如果人类工作在预留前进入 inbox,或加入预留的待处理批次,自动工作会让行,直到 agent 进入 idle;混合批次中的待处理自动提示词会被拒绝,只有在该检查点之后才重新预留。
64
+ <details>
65
+ <summary>实现细节——点击展开</summary>
27
66
 
28
- 保留的提示词会点明经过 JSON 引用的目标与 `round/maxGoalRounds`,将当前工作区、工具结果和持久会话状态视为权威信息,要求在完成前提供证据,并要求在工作仍未完成时保持目标 active。引用可将多行或形似标签的目标文本保留为数据。goal 生命周期变更仍必须通过 `dsh-tool-goal` 的独立权限检查。
67
+ 本节解释驱动器如何在无竞态的情况下调度 Round;可观察行为已在[使用本包](#use-this-package)中说明。
29
68
 
30
- ## Idle 检查点
69
+ ### 设计
31
70
 
32
- 整个 agent 进入 idle 时,持久 goal phase 和 revision 具有权威性。phase 为 active、已启用续行且仍有容量的 goal 会预留下一 Round;完成、暂停、阻塞和编辑都会阻止续行。驱动器不会通过关联 goal 消息与 `turn/end` 来对前一段活动分类,因此提供方错误和 token 上限不属于提示词级 goal 结果。
71
+ - **先预留,后准入。** idle 时驱动器为当前 `{ goalId, revision }` 预留 `roundsStarted + 1`,排入一条携带 goal 消息来源的 `<goal_round>` 提示词;只有进入步骤的 `user/message` 才会增加 `roundsStarted`。因陈旧而被拒绝的预留不会消耗 Round 编号。
72
+ - **竞态防护。** `agent/pre-step` 监听器会在下游监听器前后验证完整的已领取记录与当前 goal,因此陈旧、已取消或竞争中的提示词会在其步骤进入前被拒绝。在预留前到达的人类工作会让自动工作让行,直到 agent 重新进入 idle。
73
+ - **持久性检查点。** `goal/changed` 会产生持久性义务:排队工作前,驱动器会等待 `ctx.sessions.flush()`,并在等待后重新检查 goal revision 与竞争输入。通过 `agent/error` 到达的 flush 失败会停用续行,避免另一 Round 启动。
74
+ - **默认关闭的 teardown。** Teardown 会关闭准入、停用所有活跃 goal 的续行、以 `parent` 原因取消进行中的工作,并在事件防护仍生效的情况下等待驱动器和 agent 完全停稳。
33
75
 
34
- ## 生命周期与持久性
76
+ ### 源码地图
35
77
 
36
- `goal/changed` 会产生持久性义务。排队工作前,驱动器会等待 `ctx.sessions.flush()`,并在等待后重新检查 goal revision 与竞争输入。通过 `agent/error` 到达的 flush 失败会停用续行,避免另一 Round 启动。
78
+ | 文件 | 职责 |
79
+ |---|---|
80
+ | [`src/index.ts`](src/index.ts) | 插件入口:驱动器状态机、竞态防护、teardown |
81
+ | [`src/prompt.ts`](src/prompt.ts) | 保留的 `<goal_round>` 续行提示词 |
82
+ | [`src/invariant.ts`](src/invariant.ts) | 不变式伴生:goal-round 消息必须与包自有提示词一致 |
37
83
 
38
- 此插件加载到现有 agent 上时绝不会继承续行启用状态。`GoalService.disarm()` 会移除进程本地权限,而不改变持久 phase、revision 或历史;之后由用户明确授权的 resume 会记录重新启用续行。会话 resume 和 fork 后,goal 领域通过 `agent/session-start` 处理应用相同规则。
84
+ ### Round 提示词
39
85
 
40
- 取消会移除 inbox 中待处理的工作,或留下 agent 范围的 aborted 状态。在下一次 idle 检查点,驱动器会暂停存在已预留或已准入尝试的 goal,避免取消后自动重启;与 goal 尝试无关的取消只会撤销进程本地续行权限。如果 pause 变更失败,驱动器会回退到停用续行。插件 teardown 会关闭准入,停用所有活跃 goal 的续行,以 `parent` cause 取消正在进行的工作,并在事件防护仍生效的情况下等待驱动器和 agent 完全停稳。
86
+ 保留的提示词是一个文本块:前几行为 JSON 引用的目标与 `round/maxGoalRounds`,其后是工作指令。不变式伴生会从持久前缀重建 goal,并拒绝内容与该提示词不完全一致的任何 goal 来源消息。
41
87
 
88
+ </details>
89
+
90
+ -----
91
+
92
+ <a id="further-exploration"></a>
93
+ ## 进一步探索
94
+
95
+ 驱动器消费 goal 状态并把策略交由 goal 工具处理;需要了解周边约定与设计理由时阅读以下页面。
96
+
97
+ - [goal 服务](../goal/README.zh.md)——本驱动器继续推进的 goal 状态与生命周期。
98
+ - [goal 工具](../tool-goal/README.zh.md)——面向模型的工具及其执行时权限检查。
99
+ - [同会话驱动器 Agent Note](../../../.agents/notes/implemented/feature/2026-07-19-same-session-goal-round-driver.zh.md)——竞态与生命周期理由。
100
+
101
+ -----
102
+
103
+ <a id="model-experience"></a>
42
104
  ## 模型体验
43
105
 
44
106
  ### Goal Round 提示词
@@ -55,10 +117,25 @@
55
117
 
56
118
  在一个 epoch 内仅追加:每个已准入 Round 都会在可复用前缀后扩展现有对话。压缩可能替换派生历史后缀,并移动可复用边界。
57
119
 
58
- ## 已知限制与暂缓事项
120
+ ## 已知限制与延期工作
121
+
122
+ <a id="known-limitations-and-deferred-work"></a>
123
+
124
+
125
+ 这些限制说明驱动器何时不合适或需要特别注意。它们是当前包约束,不是任务积压。
126
+
127
+ - **没有独立评估器**——面向模型的 goal 策略会判断证据是否足以完成,以及 blocker 在语义上是否未变;评估器支持的认证仍保持暂缓。
128
+ - **只在同一会话执行**——此包有意不 spawn 新 agent、不 fork 会话前缀,也不实现 Ralph 风格的独立尝试;该工作流属于单独的插件层。
129
+ - **已接受队列的卸载竞态**——Cordis 插件卸载是异步的。已经被 agent inbox 接受的 goal 提示词可以在卸载开始前启动并消耗其 Round;teardown 随后会取消请求、停用 goal 的续行并等待完全停稳。不会再启动后续 Round。
130
+ - **只有 Round 上限,不是资源预算**——token、货币、时间与提供方配额策略保持独立。对应的会话事件不会归属于 goal 消息,也不会映射为 goal 阻塞代码。
131
+ - **异常情况不自动重试**——暂时性的提供方与持久化失败需要之后由用户授权 resume,而不会采用隐式重试策略。
132
+
133
+ <a id="dev-note"></a>
134
+ ### 开发备注
135
+
136
+ <details>
137
+ <summary>维护者的工作上下文——点击展开</summary>
138
+
139
+ 本开发备注是维护者的工作上下文,明确不具权威性。开放且未决的方向:异常失败重试策略与逐轮评估器认证;两者按设计都留在本包之外。
59
140
 
60
- - **没有独立评估器**:面向模型的 goal 策略会判断证据是否足以完成,以及 blocker 在语义上是否未变;评估器支持的认证仍保持暂缓。
61
- - **只在同一会话执行**:此包有意不 spawn 新 agent、不 fork 会话前缀,也不实现 Ralph 风格的独立尝试;该工作流属于单独的插件层。
62
- - **已接受队列的卸载竞态**:Cordis 插件卸载是异步的。已经被 agent inbox 接受的 goal 提示词可以在卸载开始前启动并消耗其 Round;teardown 随后会取消请求、停用 goal 的续行并等待完全停稳。不会再启动后续 Round。
63
- - **只有 Round 上限,不是资源预算**:token、货币、时间与提供方配额策略保持独立。对应的会话事件不会归属于 goal 消息,也不会映射为 goal 阻塞代码。
64
- - **异常情况不自动重试**:暂时性的提供方与持久化失败需要之后由用户授权 resume,而不会采用隐式重试策略。
141
+ </details>
package/lib/index.js CHANGED
@@ -335,7 +335,10 @@ function apply(ctx) {
335
335
  requestDrive(state);
336
336
  return { kind: "reject" };
337
337
  }
338
- return decision;
338
+ return {
339
+ ...decision,
340
+ startsRequestSeries: true
341
+ };
339
342
  });
340
343
  for (const agent of ctx.agents.list()) disarm(stateFor(agent));
341
344
  yield async () => {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@deepseek-ai/dsh-goal-round-driver",
3
3
  "description": "Race-fenced same-session goal-round driver",
4
- "version": "0.1.1-rc.2",
4
+ "version": "0.1.2-alpha.2",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -32,23 +32,24 @@
32
32
  ],
33
33
  "license": "MIT",
34
34
  "peerDependencies": {
35
- "@deepseek-ai/dsh-agent": "^0.1.1-rc.2",
36
- "@deepseek-ai/dsh-invariants": "^0.1.1-rc.2",
37
- "@deepseek-ai/dsh-llm": "^0.1.1-rc.2",
38
- "@deepseek-ai/dsh-goal": "^0.1.1-rc.2",
39
- "@deepseek-ai/dsh-session": "^0.1.1-rc.2",
40
- "@deepseek-ai/cordis": "^4.0.1"
35
+ "@deepseek-ai/dsh-goal": "^0.1.2-alpha.2",
36
+ "@deepseek-ai/dsh-invariants": "^0.1.2-alpha.2",
37
+ "@deepseek-ai/dsh-llm": "^0.1.2-alpha.2",
38
+ "@deepseek-ai/cordis": "^4.0.2",
39
+ "@deepseek-ai/dsh-agent": "^0.1.2-alpha.2",
40
+ "@deepseek-ai/dsh-session": "^0.1.2-alpha.2"
41
41
  },
42
42
  "devDependencies": {
43
- "@deepseek-ai/dsh-agent": "^0.1.1-rc.2",
44
- "@deepseek-ai/dsh-agent-loop": "^0.1.1-rc.2",
45
- "@deepseek-ai/dsh-agent-loop-testkit": "^0.1.1-rc.2",
46
- "@deepseek-ai/dsh-goal": "^0.1.1-rc.2",
47
- "@deepseek-ai/dsh-invariants": "^0.1.1-rc.2",
48
- "@deepseek-ai/dsh-llm": "^0.1.1-rc.2",
49
- "@deepseek-ai/dsh-session": "^0.1.1-rc.2",
50
- "@deepseek-ai/dsh-system-prompt": "^0.1.1-rc.2",
51
- "@deepseek-ai/dsh-tools": "^0.1.1-rc.2",
52
- "@deepseek-ai/cordis": "^4.0.1"
43
+ "@deepseek-ai/dsh-agent": "^0.1.2-alpha.2",
44
+ "@deepseek-ai/dsh-goal": "^0.1.2-alpha.2",
45
+ "@deepseek-ai/dsh-invariants": "^0.1.2-alpha.2",
46
+ "@deepseek-ai/dsh-llm": "^0.1.2-alpha.2",
47
+ "@deepseek-ai/dsh-session": "^0.1.2-alpha.2",
48
+ "@deepseek-ai/dsh-tools": "^0.1.2-alpha.2",
49
+ "@deepseek-ai/cordis": "^4.0.2",
50
+ "@deepseek-ai/dsh-session-projection": "^0.1.2-alpha.2",
51
+ "@deepseek-ai/dsh-system-prompt": "^0.1.2-alpha.2",
52
+ "@deepseek-ai/dsh-agent-loop": "^0.1.2-alpha.2",
53
+ "@deepseek-ai/dsh-agent-loop-testkit": "^0.1.2-alpha.2"
53
54
  }
54
55
  }