docs(i18n): include complete proofreading corpus

This commit is contained in:
xjt
2026-08-12 12:30:19 +08:00
parent 7b450d121e
commit 4806d94715
884 changed files with 2546 additions and 2547 deletions

View File

@@ -3,4 +3,4 @@
# after editing either side, bring the other along and re-record with:
# pnpm run verify-translation-pairing --write docs/cordis-tutorial/04-events.md
04-events.md: db911b9a06d7304d73030a2020de3d465fde2f9c
04-events.zh.md: e0357b2c04785d52a54f839d1b8ff3ecccb027ed
04-events.zh.md: e72c94e8548a6ac621f9a020db81910bcf22b541

View File

@@ -89,7 +89,7 @@ export function apply(ctx: Context) {
| bail | `ctx.bail(name, ...args)` | serial 的同步版本。 |
| waterfall瀑布式事件 | `ctx.waterfall(name, ...args, next)` | 环绕中间件,见下文。 |
每个 harness 事件都会在其所属[子系统页面](../subsystems/core.md)生成参考中记录其模式。
每个 harness 事件都会在其所属[子系统页面](../subsystems/core.md)自动生成参考文档中记录其模式。
## waterfall转换或短路

View File

@@ -3,4 +3,4 @@
# after editing either side, bring the other along and re-record with:
# pnpm run verify-translation-pairing --write docs/cordis-tutorial/index.md
index.md: fb700344e6d07d3864655009d2edac15ee9eede8
index.zh.md: a68e931d81e745164d8f9a5dc7ec9aec4cd0e590
index.zh.md: 9759123c42db893e91c2f3660f2f64a6c466b0a9

View File

@@ -6,7 +6,7 @@ Cordis 是 DeepSeek Harness SDK 底层的插件框架:它是一个小型运行
本教程面向 agent 开发者。你不需要深入掌握 TypeScript下文的 [TypeScript 说明](#typescript-notes)会解释可能陌生的语法,并且每一章都会给出确切命令和预期输出。
如果你想阅读精简的概念参考,而不是逐步实践,请参阅 [Cordis 入门](../cordis-primer.md)。详尽的 API 参考见[子系统页面](../subsystems/core.md)上生成的 `cordis-surface` 区块,以及 [Cordis 核心 API](../cordis-api/context.md)页面。
如果你想阅读精简的概念参考,而不是逐步实践,请参阅 [Cordis 入门](../cordis-primer.md)。详尽的 API 参考见[子系统页面](../subsystems/core.md)上生成的 `cordis-surface` 区块,以及 [Cordis 核心 API](../cordis-api/context.md) 页面。
## 准备工作
@@ -49,7 +49,7 @@ node --import tsx ../../vendor/cordis/bin.js
这些示例使用了普通现代 JavaScript 之外的三项 TypeScript 功能:
- **类型注解** 描述值,但不会改变运行时行为:`ctx: Context` 表示 `ctx` 具备 Cordis 上下文 API`who: string` 接受文本,而 `string[]` 表示字符串数组。
- **类型注解**描述值,但不会改变运行时行为:`ctx: Context` 表示 `ctx` 具备 Cordis 上下文 API`who: string` 接受文本,而 `string[]` 表示字符串数组。
- **`import type { Context } from '@deepseek-ai/cordis'`** 只导入类型信息。它在运行时会消失,因此仅为类型注解使用 `Context` 的插件文件不会增加运行时依赖。
- **声明合并**`declare module '@deepseek-ai/cordis' { ... }`)会为 Cordis 已经声明的接口添加你的条目,例如新 `ctx.greeter` 属性的类型或事件名称。它不会生成任何运行时接线;插件必须另行提供服务或发出事件。第 3 章会完整展示该模式。