@deepseek-ai/dsh-sdk-protocol 0.0.1-rc.1 → 0.0.1-rc.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 +3 -3
- package/README.md +1 -1
- package/README.zh.md +1 -1
- package/lib/types/types.d.ts +1 -1
- package/package.json +10 -10
package/README.i18n.yaml
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Bilingual-pair consistency record (docs/i18n/README.md): the git blob hash of each
|
|
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
|
-
# pnpm run verify-translation-pairing --write packages/
|
|
5
|
-
README.md:
|
|
6
|
-
README.zh.md:
|
|
4
|
+
# pnpm run verify-translation-pairing --write packages/sdk/protocol/README.md
|
|
5
|
+
README.md: 082a890454f900aec51df123669f28814d39d601
|
|
6
|
+
README.zh.md: d9b8460e51b5313f4c3a8ac66471e8cd39142430
|
package/README.md
CHANGED
|
@@ -22,7 +22,7 @@ The shared wire protocol for the DeepSeek Harness SDK runtime: one newline-delim
|
|
|
22
22
|
| server→client | `subagent.started` | `SubagentStartedNotification` |
|
|
23
23
|
| server→client | `subagent.finished` | `SubagentFinishedNotification` (in-process runs only) |
|
|
24
24
|
|
|
25
|
-
`HarnessSdkRequestMap` and `HarnessSdkNotificationMap` index these by method name. `SessionPromptResult.messageId` identifies the queued `UserMessage`; it does not identify a later assistant message, turn ending, or prompt result. Clients combine the open-ended `session.event` stream with agent-wide `session.status` according to their own activity ownership. `InitializeParams.maxTokens` is an optional positive safe integer that caps each conversation-model output for SDK-created agents and their in-process descendants; omission allows the selected adapter's exact-model default to apply, or otherwise preserves provider behavior. The notification payload types depend on `SessionEvent` (`dsh-session`), `ContentBlock` (`dsh-llm`), and `SubagentStopReason` (`dsh-subagent`) — the protocol streams full session-log envelopes, so the session vocabulary is part of the wire contract. `serverInfo.name` stays the wire-stable `deepseek-harness-sdk-runtime`.
|
|
25
|
+
`HarnessSdkRequestMap` and `HarnessSdkNotificationMap` index these by method name. `SessionPromptResult.messageId` identifies the queued `UserMessage`; it does not identify a later assistant message, turn ending, or prompt result. Clients combine the open-ended `session.event` stream with agent-wide `session.status` according to their own activity ownership. `SubagentFinishedNotification.lastAssistantMessage` contains the child's last non-empty assistant message or, when no such message exists, its accumulated assistant text; the field is absent when the child produced neither. `InitializeParams.maxTokens` is an optional positive safe integer that caps each conversation-model output for SDK-created agents and their in-process descendants; omission allows the selected adapter's exact-model default to apply, or otherwise preserves provider behavior. The notification payload types depend on `SessionEvent` (`dsh-session`), `ContentBlock` (`dsh-llm`), and `SubagentStopReason` (`dsh-subagent`) — the protocol streams full session-log envelopes, so the session vocabulary is part of the wire contract. `serverInfo.name` stays the wire-stable `deepseek-harness-sdk-runtime`.
|
|
26
26
|
|
|
27
27
|
## Model Experience
|
|
28
28
|
|
package/README.zh.md
CHANGED
|
@@ -22,7 +22,7 @@ DeepSeek Harness SDK 运行时的共享协议格式(wire format):一个按
|
|
|
22
22
|
| server→client | `subagent.started` | `SubagentStartedNotification` |
|
|
23
23
|
| server→client | `subagent.finished` | `SubagentFinishedNotification`(仅进程内运行) |
|
|
24
24
|
|
|
25
|
-
`HarnessSdkRequestMap` 与 `HarnessSdkNotificationMap` 按方法名索引这些类型。`SessionPromptResult.messageId` 标识已排队的 `UserMessage`;它不标识后续的助手消息、轮次结束或提示词结果。客户端根据自己对活动区间的所有权,组合持续开放的 `session.event` 流与 agent 级的 `session.status`。`InitializeParams.maxTokens` 是可选的正的安全整数,用于限制 SDK 创建的 agent 及其进程内后代的每次对话模型输出;省略时会应用所选适配器的确切模型默认值,否则提供方行为保持不变。通知载荷类型依赖 `SessionEvent`(`dsh-session`)、`ContentBlock`(`dsh-llm`)与 `SubagentStopReason`(`dsh-subagent`)——协议以完整会话日志封套进行流式传输,因此会话词汇是协议格式约定的一部分。`serverInfo.name` 的协议值固定为 `deepseek-harness-sdk-runtime`。
|
|
25
|
+
`HarnessSdkRequestMap` 与 `HarnessSdkNotificationMap` 按方法名索引这些类型。`SessionPromptResult.messageId` 标识已排队的 `UserMessage`;它不标识后续的助手消息、轮次结束或提示词结果。客户端根据自己对活动区间的所有权,组合持续开放的 `session.event` 流与 agent 级的 `session.status`。`SubagentFinishedNotification.lastAssistantMessage` 包含子 agent 最后一条非空 assistant 消息;若不存在这类消息,则包含其累积的 assistant 文本;子 agent 两种输出均未产生时,该字段缺省。`InitializeParams.maxTokens` 是可选的正的安全整数,用于限制 SDK 创建的 agent 及其进程内后代的每次对话模型输出;省略时会应用所选适配器的确切模型默认值,否则提供方行为保持不变。通知载荷类型依赖 `SessionEvent`(`dsh-session`)、`ContentBlock`(`dsh-llm`)与 `SubagentStopReason`(`dsh-subagent`)——协议以完整会话日志封套进行流式传输,因此会话词汇是协议格式约定的一部分。`serverInfo.name` 的协议值固定为 `deepseek-harness-sdk-runtime`。
|
|
26
26
|
|
|
27
27
|
## 模型体验
|
|
28
28
|
|
package/lib/types/types.d.ts
CHANGED
|
@@ -78,7 +78,7 @@ export interface SubagentFinishedNotification {
|
|
|
78
78
|
status: SdkRunStatus;
|
|
79
79
|
/** The provider-reported stop reason. */
|
|
80
80
|
stopReason: SubagentStopReason;
|
|
81
|
-
/** The child's
|
|
81
|
+
/** The child's selected assistant output; absent when the child produced none. */
|
|
82
82
|
lastAssistantMessage?: ContentBlock[];
|
|
83
83
|
}
|
|
84
84
|
/** Server-to-client notifications by JSON-RPC method name. */
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deepseek-ai/dsh-sdk-protocol",
|
|
3
3
|
"description": "Shared wire protocol for the DeepSeek Harness SDK runtime: the newline-delimited JSON-RPC stdio transport and the named request, result, and notification types spoken between the runtime server and SDK clients",
|
|
4
|
-
"version": "0.0.1-rc.
|
|
4
|
+
"version": "0.0.1-rc.2",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "restricted"
|
|
7
7
|
},
|
|
8
8
|
"repository": {
|
|
9
9
|
"type": "git",
|
|
10
10
|
"url": "git+https://github.com/deepseek-ai/deepseek-harness.git",
|
|
11
|
-
"directory": "packages/
|
|
11
|
+
"directory": "packages/sdk/protocol"
|
|
12
12
|
},
|
|
13
13
|
"type": "module",
|
|
14
14
|
"main": "lib/index.js",
|
|
@@ -31,17 +31,17 @@
|
|
|
31
31
|
],
|
|
32
32
|
"license": "BSD-3-Clause",
|
|
33
33
|
"peerDependencies": {
|
|
34
|
-
"@deepseek-ai/dsh-llm": "^0.0.1-rc.
|
|
35
|
-
"@deepseek-ai/dsh-session": "^0.0.1-rc.
|
|
36
|
-
"@deepseek-ai/dsh-subagent": "^0.0.1-rc.
|
|
34
|
+
"@deepseek-ai/dsh-llm": "^0.0.1-rc.2",
|
|
35
|
+
"@deepseek-ai/dsh-session": "^0.0.1-rc.2",
|
|
36
|
+
"@deepseek-ai/dsh-subagent": "^0.0.1-rc.2",
|
|
37
37
|
"@deepseek-ai/cordis": "^4.0.1-rc.1",
|
|
38
|
-
"@deepseek-ai/dsh-invariants": "^0.0.1-rc.
|
|
38
|
+
"@deepseek-ai/dsh-invariants": "^0.0.1-rc.2"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
|
-
"@deepseek-ai/dsh-
|
|
42
|
-
"@deepseek-ai/dsh-llm": "^0.0.1-rc.
|
|
43
|
-
"@deepseek-ai/dsh-
|
|
44
|
-
"@deepseek-ai/dsh-subagent": "^0.0.1-rc.
|
|
41
|
+
"@deepseek-ai/dsh-invariants": "^0.0.1-rc.2",
|
|
42
|
+
"@deepseek-ai/dsh-llm": "^0.0.1-rc.2",
|
|
43
|
+
"@deepseek-ai/dsh-session": "^0.0.1-rc.2",
|
|
44
|
+
"@deepseek-ai/dsh-subagent": "^0.0.1-rc.2",
|
|
45
45
|
"@deepseek-ai/cordis": "^4.0.1-rc.1"
|
|
46
46
|
}
|
|
47
47
|
}
|