mirror of
https://github.com/deepseek-ai/deepseek-harness.git
synced 2026-08-29 04:26:38 +00:00
docs(i18n): localize Chinese internal links
This commit is contained in:
@@ -3,4 +3,4 @@
|
||||
# after editing either side, bring the other along and re-record with:
|
||||
# pnpm run verify-translation-pairing --write docs/user/develop/basic/config.md
|
||||
config.md: 21ba39fd7de1795e9139aff3e2b11743eedd4833
|
||||
config.zh.md: a882c4d59b0ac8e8ec27a5b32da5376b534a7f62
|
||||
config.zh.md: 642a413950e2d8deb8591bc688968607604c050d
|
||||
|
||||
@@ -93,7 +93,7 @@ export interface Config {
|
||||
|
||||
### 配置错误要响亮
|
||||
|
||||
在 schema 中表达自身完备的约束,使无效配置在插件加载时失败。对服务或已注册资源的引用需要依赖注入;[服务教程](../framework/service.md) 会介绍这项约定。
|
||||
在 schema 中表达自身完备的约束,使无效配置在插件加载时失败。对服务或已注册资源的引用需要依赖注入;[服务教程](../framework/service.zh.md) 会介绍这项约定。
|
||||
|
||||
## 配合 HMR
|
||||
|
||||
@@ -101,6 +101,6 @@ export interface Config {
|
||||
|
||||
## 下一步
|
||||
|
||||
- [打包与安装插件](./publish.md) — 把插件以可安装包的形式交付
|
||||
- [插件与生命周期](../framework/) — 深入了解插件的完整生命周期
|
||||
- [服务与依赖](../framework/service.md) — 让你的插件对外提供服务
|
||||
- [打包与安装插件](./publish.zh.md) — 把插件以可安装包的形式交付
|
||||
- [插件与生命周期](../framework/index.zh.md) — 深入了解插件的完整生命周期
|
||||
- [服务与依赖](../framework/service.zh.md) — 让你的插件对外提供服务
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
# after editing either side, bring the other along and re-record with:
|
||||
# pnpm run verify-translation-pairing --write docs/user/develop/basic/index.md
|
||||
index.md: 08199624e638aaf4a36b04446c39c228b2af6025
|
||||
index.zh.md: c45a30d0bfffaf4a6c78303f9ca043c3397c8a08
|
||||
index.zh.md: 2ea894079ffb3c5b8c4563fd535fe6e654861b1b
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
[English](index.md) | 中文
|
||||
|
||||
本教程会创建一个最小的 Harness 插件,并将其加载到 Web UI 中。请从已完成[从源码运行路径](../../../../README.md#run-from-source)的仓库检出开始。
|
||||
本教程会创建一个最小的 Harness 插件,并将其加载到 Web UI 中。请从已完成[从源码运行路径](../../../../README.zh.md#run-from-source)的仓库检出开始。
|
||||
|
||||
## 创建本地项目
|
||||
|
||||
@@ -135,10 +135,10 @@ export default class MyService extends Service {
|
||||
}
|
||||
```
|
||||
|
||||
大多数情况下,函数形式足够了。当插件需要向其他插件提供服务时,可使用类形式(见 [服务与依赖](../framework/service.md))。
|
||||
大多数情况下,函数形式足够了。当插件需要向其他插件提供服务时,可使用类形式(见 [服务与依赖](../framework/service.zh.md))。
|
||||
|
||||
## 下一步
|
||||
|
||||
- [开发一个工具](./tool.md) — 了解工具定义 DSL
|
||||
- [插件配置](./config.md) — 让插件接受用户配置
|
||||
- [Cordis 框架教程](../../../cordis-tutorial/index.md) — 底层的插件框架,在临时目录中动手构建,无需 API 密钥
|
||||
- [开发一个工具](./tool.zh.md) — 了解工具定义 DSL
|
||||
- [插件配置](./config.zh.md) — 让插件接受用户配置
|
||||
- [Cordis 框架教程](../../../cordis-tutorial/index.zh.md) — 底层的插件框架,在临时目录中动手构建,无需 API 密钥
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
# after editing either side, bring the other along and re-record with:
|
||||
# pnpm run verify-translation-pairing --write docs/user/develop/basic/publish.md
|
||||
publish.md: 9548fe2f8e4636dd160c79cd0d50f01f8bdfd3d1
|
||||
publish.zh.md: 2cff05edcca55bac5fde9d2e7d24ed9c8b48a6f5
|
||||
publish.zh.md: 00b8885d6cbd39fa9899e110b1d31ef96175e127
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
[English](publish.md) | 中文
|
||||
|
||||
前几篇教程通过 `--patch` overlay 加载本地插件。本教程把它打包成可安装的**组合包**(bundle),用 `dsh plugin add` 安装进一个 **profile**,并解释决定组合后配置的层顺序。本文假设 `dsh` CLI 已安装。请先完成[插件配置](./config.md)。
|
||||
前几篇教程通过 `--patch` overlay 加载本地插件。本教程把它打包成可安装的**组合包**(bundle),用 `dsh plugin add` 安装进一个 **profile**,并解释决定组合后配置的层顺序。本文假设 `dsh` CLI 已安装。请先完成[插件配置](./config.zh.md)。
|
||||
|
||||
如果改用全新的源码 checkout,请先按照[从源码运行章节](../../../../README.md#run-from-source)完成准备,将本教程的 `hello-plugin` 目录放在仓库根目录,并从该目录把下文的 `dsh ...` 命令改为 `pnpm dsh ...`。构建与启动器行为见[源码执行](../../../../apps/cli/reference/README.md#source-execution)。
|
||||
如果改用全新的源码 checkout,请先按照[从源码运行章节](../../../../README.zh.md#run-from-source)完成准备,将本教程的 `hello-plugin` 目录放在仓库根目录,并从该目录把下文的 `dsh ...` 命令改为 `pnpm dsh ...`。构建与启动器行为见[源码执行](../../../../apps/cli/reference/README.zh.md#source-execution)。
|
||||
|
||||
## 两个概念,两种 manifest
|
||||
|
||||
@@ -136,7 +136,7 @@ dsh --profile demo
|
||||
name: 'dsh-hello-plugin/startup'
|
||||
```
|
||||
|
||||
该插件导出 `inject = ['cmdlineArgs']`,使用自己的 commander program 调用 [`@deepseek-ai/dsh-cmdline`](../../../../packages/boot/cmdline/README.md) 中的 `parseCmdline`,再在 program 自己的 action 中把应用自有服务提供出去。启动器把自身 flag 之后的同一份不可变参数交给每个插件,因此添加应用专属 flag 无需修改启动器,多个插件也可以解析该快照。Loader 行不需要启动器标记或特殊类型。
|
||||
该插件导出 `inject = ['cmdlineArgs']`,使用自己的 commander program 调用 [`@deepseek-ai/dsh-cmdline`](../../../../packages/boot/cmdline/README.zh.md) 中的 `parseCmdline`,再在 program 自己的 action 中把应用自有服务提供出去。启动器把自身 flag 之后的同一份不可变参数交给每个插件,因此添加应用专属 flag 无需修改启动器,多个插件也可以解析该快照。Loader 行不需要启动器标记或特殊类型。
|
||||
|
||||
受这些参数配置的行会注入提供方服务,并在自己的 `!!js` 选项中读取它,同时把部署取值写在旁边作为回退:
|
||||
|
||||
@@ -179,5 +179,5 @@ dsh plugin --profile demo add github:you/hello-plugin
|
||||
|
||||
## 下一步
|
||||
|
||||
- [插件与生命周期](../framework/) — 插件的完整生命周期
|
||||
- [CLI(命令行界面)行为参考](../../../../apps/cli/reference/README.md) — 确切的层优先级、flag 与 profile 机制
|
||||
- [插件与生命周期](../framework/index.zh.md) — 插件的完整生命周期
|
||||
- [CLI(命令行界面)行为参考](../../../../apps/cli/reference/README.zh.md) — 确切的层优先级、flag 与 profile 机制
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
# after editing either side, bring the other along and re-record with:
|
||||
# pnpm run verify-translation-pairing --write docs/user/develop/basic/tool.md
|
||||
tool.md: eb262d131a7f2b540827e86e56f8c0a28cb5f904
|
||||
tool.zh.md: d33d9946a73881df2cd44ebf3695819d02d013ab
|
||||
tool.zh.md: a07bef588f5a18093cf2eb1971b855bf40d1d0b6
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
[English](tool.md) | 中文
|
||||
|
||||
本教程会在 Web UI 中添加一个 `greet` 工具。请先完成[第一个插件](./),并保留其中的 `scratch-plugin` 目录。
|
||||
本教程会在 Web UI 中添加一个 `greet` 工具。请先完成[第一个插件](./index.zh.md),并保留其中的 `scratch-plugin` 目录。
|
||||
|
||||
## 创建工具插件
|
||||
|
||||
@@ -47,6 +47,6 @@ pnpm dsh web --patch ./scratch-plugin/cordis.yml
|
||||
|
||||
## 下一步
|
||||
|
||||
- [插件配置](./config.md) — 让问候语可配置。
|
||||
- [工具编写参考](../../../cookbook/adding-a-tool.md) — 查阅嵌套 schema、规范值、后台工作、策略钩子、Code Mode 和 UI 卡片。
|
||||
- [能力分层](../practice/) — 将可替换能力拆分为 Service Definition、Service Provider 和 Consumer 三类包。
|
||||
- [插件配置](./config.zh.md) — 让问候语可配置。
|
||||
- [工具编写参考](../../../cookbook/adding-a-tool.zh.md) — 查阅嵌套 schema、规范值、后台工作、策略钩子、Code Mode 和 UI 卡片。
|
||||
- [能力分层](../practice/index.zh.md) — 将可替换能力拆分为 Service Definition、Service Provider 和 Consumer 三类包。
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
# after editing either side, bring the other along and re-record with:
|
||||
# pnpm run verify-translation-pairing --write docs/user/develop/framework/events.md
|
||||
events.md: 1d9fe5c8f5068de6ad8b2abaa85cf67be35c8459
|
||||
events.zh.md: 8bb9447a270cc2db966b1e01298a831a60a1b9c1
|
||||
events.zh.md: 6936a5ad6c51393d2fbcd5103d4e418ce010d569
|
||||
|
||||
@@ -101,7 +101,7 @@ declare module '@deepseek-ai/cordis' {
|
||||
|
||||
## Cordis 事件与会话记录
|
||||
|
||||
Harness 的 Cordis 事件遵循 `namespace/action` 命名,例如 `agent/step`、`agent/request`、`agent/request-error`、`tools/result` 和 `session/event`。完整签名与触发模式见[子系统页面](../../../subsystems/core.md)上生成的 `cordis-surface` 区块。
|
||||
Harness 的 Cordis 事件遵循 `namespace/action` 命名,例如 `agent/step`、`agent/request`、`agent/request-error`、`tools/result` 和 `session/event`。完整签名与触发模式见[子系统页面](../../../subsystems/core.zh.md)上生成的 `cordis-surface` 区块。
|
||||
|
||||
`turn/*`、`step/*`、`tool/call`、`tool/result` 和 `compaction/*` 是持久化的会话事件类型,不是同名 Cordis 事件。需要观察它们时,监听 `session/event` 并检查 `event.type`。
|
||||
|
||||
@@ -139,5 +139,5 @@ export function apply(ctx: Context) {
|
||||
|
||||
## 下一步
|
||||
|
||||
- [能力分层](../practice/) — 了解能力接口中的事件
|
||||
- [LLM(大语言模型)适配器](../practice/llm-adapter.md) — 实现一个完整的 LLM 后端
|
||||
- [能力分层](../practice/index.zh.md) — 了解能力接口中的事件
|
||||
- [LLM(大语言模型)适配器](../practice/llm-adapter.zh.md) — 实现一个完整的 LLM 后端
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
# after editing either side, bring the other along and re-record with:
|
||||
# pnpm run verify-translation-pairing --write docs/user/develop/framework/index.md
|
||||
index.md: 8cc673148d7fec4f7d9b994907e17293bc3a6a97
|
||||
index.zh.md: 1a1f7feb8685e124babb182544bde332b52da42c
|
||||
index.zh.md: 8f55bd1cdd472b2f7b90e9280c58d15533ffce57
|
||||
|
||||
@@ -132,6 +132,6 @@ effect cleaned up
|
||||
|
||||
## 下一步
|
||||
|
||||
- [服务与依赖](./service.md) — 让插件向其他插件提供能力
|
||||
- [事件系统](./events.md) — 在插件之间通信
|
||||
- [Cordis 框架教程](../../../cordis-tutorial/index.md) — 在 Cordis 运行时上逐步搭出同一套生命周期、服务与事件
|
||||
- [服务与依赖](./service.zh.md) — 让插件向其他插件提供能力
|
||||
- [事件系统](./events.zh.md) — 在插件之间通信
|
||||
- [Cordis 框架教程](../../../cordis-tutorial/index.zh.md) — 在 Cordis 运行时上逐步搭出同一套生命周期、服务与事件
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
# after editing either side, bring the other along and re-record with:
|
||||
# pnpm run verify-translation-pairing --write docs/user/develop/framework/service.md
|
||||
service.md: 03f4e7dc4df934495a4b203066183753b621339e
|
||||
service.zh.md: 2f4c01e0ea6a87a87ca694b265b07e07098f3e59
|
||||
service.zh.md: b275c3d200fb50b1fab0e762d0154477c7ca4447
|
||||
|
||||
@@ -142,9 +142,9 @@ export function apply(ctx: Context) {
|
||||
|
||||
## Harness 内置服务
|
||||
|
||||
服务名、公开方法和源码位置由仓库自动生成到各服务的[子系统页面](../../../subsystems/core.md)。开发插件时应以这些生成区块和服务的 TypeScript 接口为准,不要维护另一份静态清单。
|
||||
服务名、公开方法和源码位置由仓库自动生成到各服务的[子系统页面](../../../subsystems/core.zh.md)。开发插件时应以这些生成区块和服务的 TypeScript 接口为准,不要维护另一份静态清单。
|
||||
|
||||
## 下一步
|
||||
|
||||
- [事件系统](./events.md) — 插件间松耦合通信
|
||||
- [能力分层](../practice/) — 将服务用作能力接口
|
||||
- [事件系统](./events.zh.md) — 插件间松耦合通信
|
||||
- [能力分层](../practice/index.zh.md) — 将服务用作能力接口
|
||||
|
||||
@@ -3,4 +3,4 @@
|
||||
# after editing either side, bring the other along and re-record with:
|
||||
# pnpm run verify-translation-pairing --write docs/user/develop/practice/index.md
|
||||
index.md: cc6bd7a234305f6fa193341f15354b40855f72e9
|
||||
index.zh.md: aed13b00f9bc74946aace614953bed30705c8281
|
||||
index.zh.md: 55ed3d3a93008f63a3e677de935c1de4be8872e5
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
[English](index.md) | 中文
|
||||
|
||||
本文分为两部分:先参考三种角色能力模式的概念,再通过高级教程构建一项能力。请先完成[基础插件路径](../basic/)和[服务教程](../framework/service.md)。
|
||||
本文分为两部分:先参考三种角色能力模式的概念,再通过高级教程构建一项能力。请先完成[基础插件路径](../basic/index.zh.md)和[服务教程](../framework/service.zh.md)。
|
||||
|
||||
## 概念参考
|
||||
|
||||
@@ -53,7 +53,7 @@
|
||||
- Consumer 依赖 Service Definition。
|
||||
- Service Provider 和 Consumer **互不依赖**。
|
||||
|
||||
当前内置系列及其包链接由[能力 seam 参考](../../../capability-seams.md)负责。
|
||||
当前内置系列及其包链接由[能力 seam 参考](../../../capability-seams.zh.md)负责。
|
||||
|
||||
## 教程:开发三种角色的能力
|
||||
|
||||
@@ -152,4 +152,4 @@ export function apply(ctx: Context) {
|
||||
|
||||
## 下一步
|
||||
|
||||
- [LLM(大语言模型)适配器](./llm-adapter.md):实现一个 LLM 提供方
|
||||
- [LLM(大语言模型)适配器](./llm-adapter.zh.md):实现一个 LLM 提供方
|
||||
|
||||
Reference in New Issue
Block a user