docs(zh): sync remaining code mode-value prose to ptc

The review bot found stale 'code' configuration values in the zh tools
and agent-tool-presentation READMEs and the zh tool catalog, which the
runtime schema already rejects in favor of 'ptc'.
This commit is contained in:
Tianyi Cui
2026-08-28 00:16:29 +08:00
parent 84dd2447f3
commit b7c71d805a
6 changed files with 8 additions and 8 deletions
@@ -3,4 +3,4 @@
# after editing either side, bring the other along and re-record with:
# pnpm run verify-translation-pairing --write packages/core/agent-tool-presentation/README.md
README.md: c57938f2b32bead9558b283112c09e8a46b6e866
README.zh.md: bbe7801fba2e3f284be0146c1375f73a5dc00009
README.zh.md: ac511f0793c1f883d539fd05cc53655869f19f5d
@@ -25,7 +25,7 @@ kind: "package-reference"
<a id="use-this-package"></a>
## 使用本包
把这一行加入 agent preset,以固定每个加入该 preset 的 agent 看到其工具的方式。`native` 以函数定义的形式呈现每个可见工具 schema;`code` 只呈现 `run_code` 传输、一份生成的 SDK 以及「只有 `run_code` 可被直接调用」这条规则;`both` 同时呈现两种形态。未作声明的 agent 会拿到 [`dsh-tools`](../tools/README.zh.md) 那一行上的部署级 `mode`
把这一行加入 agent preset,以固定每个加入该 preset 的 agent 看到其工具的方式。`native` 以函数定义的形式呈现每个可见工具 schema;`ptc` 只呈现 `run_code` 传输、一份生成的 SDK 以及「只有 `run_code` 可被直接调用」这条规则;`both` 同时呈现两种形态。未作声明的 agent 会拿到 [`dsh-tools`](../tools/README.zh.md) 那一行上的部署级 `mode`
### 把这一行加入 preset
@@ -37,7 +37,7 @@ kind: "package-reference"
| 字段 | 默认值 | 含义 |
|---|---|---|
| `mode` | 必填 | `native`——每个 schema`code`——`run_code` 加生成 SDK`both`——两种形态 |
| `mode` | 必填 | `native`——每个 schema`ptc`——`run_code` 加生成 SDK`both`——两种形态 |
生成的[配置目录](../../../docs/config-catalog.zh.md#deepseek-aidsh-agent-tool-presentation)是每个受支持字段的穷尽式真源。`mode` 是必填而非有默认值,因为不带这一行的 preset 会继承部署默认值。
+1 -1
View File
@@ -3,4 +3,4 @@
# after editing either side, bring the other along and re-record with:
# pnpm run verify-translation-pairing --write packages/core/tools/README.md
README.md: f586b926ec9a8e426f48b62e4d03b1661201a76a
README.zh.md: 15282a7dff6d8da3a2a43315f1bc2ebe8dcd9a60
README.zh.md: 5f422dd848ee9a6e8e0afe96d3dd03238ecc3857
+2 -2
View File
@@ -61,7 +61,7 @@ ctx.tools.register(defineTool({
### 配置呈现模式
`mode` 配置决定模型看到什么:`native`(每个可见 schema)、`code`(只有 `run_code` 加一份生成 SDK)或 `both`
`mode` 配置决定模型看到什么:`native`(每个可见 schema)、`ptc`(只有 `run_code` 加一份生成 SDK)或 `both`
```yaml
- name: '@deepseek-ai/dsh-tools'
@@ -122,7 +122,7 @@ ctx.tools.register(defineTool({
### PTC mode
`ptc``both` 下,注册表公开保留的 `run_code` 传输以及按所加载运行时语言生成的确定性 SDK。每个 SDK 绑定调用都会在日志中与外层调用关联,重新进入完整工具流水线,并通过复用原生并发约定的每次运行独有池调度。在纯 `code` 下,模型直呼其他任何可见工具都会在策略之前解析为 `UNKNOWN_TOOL`——通告面与可调用面保持一致。中间绑定值只存在于执行局部;只有外层 `run_code` 结果有硬大小上限。[执行器塌缩 note](../../../.agents/notes/implemented/bug-fix/2026-08-07-ptc-executor-collapse.zh.md) 拥有该收束约定。
`ptc``both` 下,注册表公开保留的 `run_code` 传输以及按所加载运行时语言生成的确定性 SDK。每个 SDK 绑定调用都会在日志中与外层调用关联,重新进入完整工具流水线,并通过复用原生并发约定的每次运行独有池调度。在纯 `ptc` 下,模型直呼其他任何可见工具都会在策略之前解析为 `UNKNOWN_TOOL`——通告面与可调用面保持一致。中间绑定值只存在于执行局部;只有外层 `run_code` 结果有硬大小上限。[执行器塌缩 note](../../../.agents/notes/implemented/bug-fix/2026-08-07-ptc-executor-collapse.zh.md) 拥有该收束约定。
<a id="extension-points"></a>
### 扩展点