dsh-plugin-guide 0.3.15 → 0.3.17

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.
Files changed (446) hide show
  1. package/README-es.md +43 -40
  2. package/README-hi.md +43 -40
  3. package/README-pt.md +43 -40
  4. package/README-zh.md +43 -40
  5. package/README.md +19 -15
  6. package/dist/dsh-plugin-dev.js +230 -6
  7. package/guide/plugin-dev-guide.md +1 -1
  8. package/guide/release-engineering.md +7 -5
  9. package/guide/release-engineering.zh-CN.md +7 -5
  10. package/guide/unfixed-issues.md +4 -2
  11. package/package.json +5 -4
  12. package/references/official-docs/AGENTS.md +74 -49
  13. package/references/official-docs/README.i18n.yaml +2 -2
  14. package/references/official-docs/README.zh.md +12 -0
  15. package/references/official-docs/SNAPSHOT.md +4 -4
  16. package/references/official-docs/THIRD_PARTY_NOTICES.md +86 -30
  17. package/references/official-docs/docs/AGENTS.md +7 -6
  18. package/references/official-docs/docs/agent-lifecycle.i18n.yaml +2 -2
  19. package/references/official-docs/docs/agent-lifecycle.md +12 -5
  20. package/references/official-docs/docs/agent-lifecycle.zh.md +12 -5
  21. package/references/official-docs/docs/api-gateway.i18n.yaml +2 -2
  22. package/references/official-docs/docs/api-gateway.md +2 -2
  23. package/references/official-docs/docs/api-gateway.zh.md +2 -2
  24. package/references/official-docs/docs/architecture.i18n.yaml +2 -2
  25. package/references/official-docs/docs/architecture.md +26 -12
  26. package/references/official-docs/docs/architecture.zh.md +28 -14
  27. package/references/official-docs/docs/capability-seams.i18n.yaml +2 -2
  28. package/references/official-docs/docs/capability-seams.md +111 -31
  29. package/references/official-docs/docs/capability-seams.zh.md +111 -31
  30. package/references/official-docs/docs/config-catalog.i18n.yaml +2 -2
  31. package/references/official-docs/docs/config-catalog.md +674 -202
  32. package/references/official-docs/docs/config-catalog.zh.md +691 -219
  33. package/references/official-docs/docs/cookbook/adding-a-session-format-version.i18n.yaml +6 -0
  34. package/references/official-docs/docs/cookbook/adding-a-session-format-version.md +111 -0
  35. package/references/official-docs/docs/cookbook/adding-a-session-format-version.zh.md +111 -0
  36. package/references/official-docs/docs/cookbook/adding-a-settings-card.md +8 -8
  37. package/references/official-docs/docs/cookbook/adding-a-settings-card.zh.md +9 -9
  38. package/references/official-docs/docs/cookbook/adding-a-tool.i18n.yaml +2 -2
  39. package/references/official-docs/docs/cookbook/adding-a-tool.md +2 -2
  40. package/references/official-docs/docs/cookbook/adding-a-tool.zh.md +4 -4
  41. package/references/official-docs/docs/cookbook/adding-a-vendored-package.i18n.yaml +2 -2
  42. package/references/official-docs/docs/cookbook/adding-a-vendored-package.md +1 -1
  43. package/references/official-docs/docs/cookbook/adding-a-vendored-package.zh.md +1 -1
  44. package/references/official-docs/docs/cookbook/adding-an-llm-adapter.zh.md +1 -1
  45. package/references/official-docs/docs/cookbook/extension-cookbook.i18n.yaml +2 -2
  46. package/references/official-docs/docs/cookbook/extension-cookbook.md +3 -3
  47. package/references/official-docs/docs/cookbook/extension-cookbook.zh.md +5 -5
  48. package/references/official-docs/docs/cookbook/responding-to-pr-review-on-a-stack.i18n.yaml +2 -2
  49. package/references/official-docs/docs/cookbook/responding-to-pr-review-on-a-stack.md +1 -1
  50. package/references/official-docs/docs/cookbook/responding-to-pr-review-on-a-stack.zh.md +1 -1
  51. package/references/official-docs/docs/cookbook/reviewing-persistence-type-changes.i18n.yaml +6 -0
  52. package/references/official-docs/docs/cookbook/reviewing-persistence-type-changes.md +108 -0
  53. package/references/official-docs/docs/cookbook/reviewing-persistence-type-changes.zh.md +108 -0
  54. package/references/official-docs/docs/cordis-api/fiber.i18n.yaml +2 -2
  55. package/references/official-docs/docs/cordis-api/fiber.md +3 -3
  56. package/references/official-docs/docs/cordis-api/fiber.zh.md +3 -3
  57. package/references/official-docs/docs/cordis-api/inherited.md +0 -3
  58. package/references/official-docs/docs/cordis-tutorial/06-composition-and-hmr.i18n.yaml +2 -2
  59. package/references/official-docs/docs/cordis-tutorial/06-composition-and-hmr.md +2 -2
  60. package/references/official-docs/docs/cordis-tutorial/06-composition-and-hmr.zh.md +2 -2
  61. package/references/official-docs/docs/deepseek-llm-api-wire-extensions.i18n.yaml +2 -2
  62. package/references/official-docs/docs/deepseek-llm-api-wire-extensions.md +14 -15
  63. package/references/official-docs/docs/deepseek-llm-api-wire-extensions.zh.md +15 -16
  64. package/references/official-docs/docs/dependency-catalog.json +7312 -0
  65. package/references/official-docs/docs/development.i18n.yaml +2 -2
  66. package/references/official-docs/docs/development.md +13 -3
  67. package/references/official-docs/docs/development.zh.md +16 -6
  68. package/references/official-docs/docs/event-producer-consumer.i18n.yaml +2 -2
  69. package/references/official-docs/docs/event-producer-consumer.md +50 -39
  70. package/references/official-docs/docs/event-producer-consumer.zh.md +55 -44
  71. package/references/official-docs/docs/glossary.i18n.yaml +2 -2
  72. package/references/official-docs/docs/glossary.md +1 -1
  73. package/references/official-docs/docs/glossary.zh.md +1 -1
  74. package/references/official-docs/docs/i18n/README.i18n.yaml +2 -2
  75. package/references/official-docs/docs/i18n/README.md +8 -3
  76. package/references/official-docs/docs/i18n/README.zh.md +8 -3
  77. package/references/official-docs/docs/i18n/style-samples.md +1 -1
  78. package/references/official-docs/docs/i18n/translation-prompt.md +5 -5
  79. package/references/official-docs/docs/i18n/translation-rules.zh.md +2 -2
  80. package/references/official-docs/docs/module-graph.i18n.yaml +2 -2
  81. package/references/official-docs/docs/module-graph.md +303 -120
  82. package/references/official-docs/docs/module-graph.zh.md +303 -120
  83. package/references/official-docs/docs/persistence-catalog.i18n.yaml +2 -2
  84. package/references/official-docs/docs/persistence-catalog.md +5699 -64
  85. package/references/official-docs/docs/persistence-catalog.zh.md +5708 -73
  86. package/references/official-docs/docs/persistence-changes/2026-09-11-initial.i18n.yaml +6 -0
  87. package/references/official-docs/docs/persistence-changes/2026-09-11-initial.md +280 -0
  88. package/references/official-docs/docs/persistence-changes/2026-09-11-initial.schema.json +13557 -0
  89. package/references/official-docs/docs/persistence-changes/2026-09-11-initial.zh.md +280 -0
  90. package/references/official-docs/docs/persistence-changes/2026-09-12-auto-review-error-metadata.i18n.yaml +6 -0
  91. package/references/official-docs/docs/persistence-changes/2026-09-12-auto-review-error-metadata.md +52 -0
  92. package/references/official-docs/docs/persistence-changes/2026-09-12-auto-review-error-metadata.schema.json +910 -0
  93. package/references/official-docs/docs/persistence-changes/2026-09-12-auto-review-error-metadata.zh.md +52 -0
  94. package/references/official-docs/docs/persistence-changes/2026-09-14-image-offload.i18n.yaml +6 -0
  95. package/references/official-docs/docs/persistence-changes/2026-09-14-image-offload.md +96 -0
  96. package/references/official-docs/docs/persistence-changes/2026-09-14-image-offload.schema.json +8478 -0
  97. package/references/official-docs/docs/persistence-changes/2026-09-14-image-offload.zh.md +96 -0
  98. package/references/official-docs/docs/persistence-changes/2026-09-14-workspace-changes-event.i18n.yaml +6 -0
  99. package/references/official-docs/docs/persistence-changes/2026-09-14-workspace-changes-event.md +48 -0
  100. package/references/official-docs/docs/persistence-changes/2026-09-14-workspace-changes-event.schema.json +72 -0
  101. package/references/official-docs/docs/persistence-changes/2026-09-14-workspace-changes-event.zh.md +48 -0
  102. package/references/official-docs/docs/persistence-changes/README.i18n.yaml +6 -0
  103. package/references/official-docs/docs/persistence-changes/README.md +74 -0
  104. package/references/official-docs/docs/persistence-changes/README.zh.md +74 -0
  105. package/references/official-docs/docs/persistence-changes/historical-formats/README.i18n.yaml +6 -0
  106. package/references/official-docs/docs/persistence-changes/historical-formats/README.md +74 -0
  107. package/references/official-docs/docs/persistence-changes/historical-formats/README.zh.md +74 -0
  108. package/references/official-docs/docs/persistence-changes/historical-formats/v0.i18n.yaml +6 -0
  109. package/references/official-docs/docs/persistence-changes/historical-formats/v0.md +5105 -0
  110. package/references/official-docs/docs/persistence-changes/historical-formats/v0.schema.json +49308 -0
  111. package/references/official-docs/docs/persistence-changes/historical-formats/v0.zh.md +5105 -0
  112. package/references/official-docs/docs/persistence-changes/historical-formats/v1.i18n.yaml +6 -0
  113. package/references/official-docs/docs/persistence-changes/historical-formats/v1.md +5107 -0
  114. package/references/official-docs/docs/persistence-changes/historical-formats/v1.schema.json +49411 -0
  115. package/references/official-docs/docs/persistence-changes/historical-formats/v1.zh.md +5107 -0
  116. package/references/official-docs/docs/persistence-changes/historical-formats/v2.i18n.yaml +6 -0
  117. package/references/official-docs/docs/persistence-changes/historical-formats/v2.md +5362 -0
  118. package/references/official-docs/docs/persistence-changes/historical-formats/v2.schema.json +56466 -0
  119. package/references/official-docs/docs/persistence-changes/historical-formats/v2.zh.md +5362 -0
  120. package/references/official-docs/docs/persistence-changes/releases/README.i18n.yaml +6 -0
  121. package/references/official-docs/docs/persistence-changes/releases/README.md +103 -0
  122. package/references/official-docs/docs/persistence-changes/releases/README.zh.md +103 -0
  123. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.1.i18n.yaml +6 -0
  124. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.1.md +201 -0
  125. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.1.schema.json +39868 -0
  126. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.1.zh.md +201 -0
  127. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.2.i18n.yaml +6 -0
  128. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.2.md +261 -0
  129. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.2.schema.json +43342 -0
  130. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.2.zh.md +261 -0
  131. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.3.i18n.yaml +6 -0
  132. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.3.md +126 -0
  133. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.3.schema.json +19452 -0
  134. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.3.zh.md +126 -0
  135. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.4.i18n.yaml +6 -0
  136. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.4.md +75 -0
  137. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.4.schema.json +5 -0
  138. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.4.zh.md +75 -0
  139. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.5.i18n.yaml +6 -0
  140. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.5.md +75 -0
  141. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.5.schema.json +5 -0
  142. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.5.zh.md +75 -0
  143. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.1.i18n.yaml +6 -0
  144. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.1.md +75 -0
  145. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.1.schema.json +5 -0
  146. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.1.zh.md +75 -0
  147. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.2.i18n.yaml +6 -0
  148. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.2.md +75 -0
  149. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.2.schema.json +5 -0
  150. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.2.zh.md +75 -0
  151. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.3.i18n.yaml +6 -0
  152. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.3.md +75 -0
  153. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.3.schema.json +5 -0
  154. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.3.zh.md +75 -0
  155. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.5.i18n.yaml +6 -0
  156. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.5.md +75 -0
  157. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.5.schema.json +5 -0
  158. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.5.zh.md +75 -0
  159. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.6.i18n.yaml +6 -0
  160. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.6.md +75 -0
  161. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.6.schema.json +5 -0
  162. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.6.zh.md +75 -0
  163. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.7.i18n.yaml +6 -0
  164. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.7.md +82 -0
  165. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.7.schema.json +5320 -0
  166. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.7.zh.md +82 -0
  167. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.8.i18n.yaml +6 -0
  168. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.8.md +110 -0
  169. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.8.schema.json +21258 -0
  170. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.8.zh.md +110 -0
  171. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.1.i18n.yaml +6 -0
  172. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.1.md +82 -0
  173. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.1.schema.json +417 -0
  174. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.1.zh.md +82 -0
  175. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.2.i18n.yaml +6 -0
  176. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.2.md +119 -0
  177. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.2.schema.json +29672 -0
  178. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.2.zh.md +119 -0
  179. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.1.i18n.yaml +6 -0
  180. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.1.md +295 -0
  181. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.1.schema.json +48429 -0
  182. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.1.zh.md +295 -0
  183. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.2.i18n.yaml +6 -0
  184. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.2.md +286 -0
  185. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.2.schema.json +49347 -0
  186. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.2.zh.md +286 -0
  187. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.3.i18n.yaml +6 -0
  188. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.3.md +75 -0
  189. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.3.schema.json +5 -0
  190. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.3.zh.md +75 -0
  191. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.4.i18n.yaml +6 -0
  192. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.4.md +95 -0
  193. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.4.schema.json +17642 -0
  194. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.4.zh.md +95 -0
  195. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.5.i18n.yaml +6 -0
  196. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.5.md +75 -0
  197. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.5.schema.json +5 -0
  198. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.5.zh.md +75 -0
  199. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-rc.1.i18n.yaml +6 -0
  200. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-rc.1.md +75 -0
  201. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-rc.1.schema.json +5 -0
  202. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-rc.1.zh.md +75 -0
  203. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.1.i18n.yaml +6 -0
  204. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.1.md +154 -0
  205. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.1.schema.json +38678 -0
  206. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.1.zh.md +154 -0
  207. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.2.i18n.yaml +6 -0
  208. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.2.md +86 -0
  209. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.2.schema.json +783 -0
  210. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.2.zh.md +86 -0
  211. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.1.i18n.yaml +6 -0
  212. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.1.md +139 -0
  213. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.1.schema.json +24597 -0
  214. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.1.zh.md +139 -0
  215. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.2.i18n.yaml +6 -0
  216. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.2.md +95 -0
  217. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.2.schema.json +2132 -0
  218. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.2.zh.md +95 -0
  219. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-rc.1.i18n.yaml +6 -0
  220. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-rc.1.md +75 -0
  221. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-rc.1.schema.json +5 -0
  222. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-rc.1.zh.md +75 -0
  223. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-rc.2.i18n.yaml +6 -0
  224. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-rc.2.md +75 -0
  225. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-rc.2.schema.json +5 -0
  226. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-rc.2.zh.md +75 -0
  227. package/references/official-docs/docs/persistence-changes/releases/manifest.json +162 -0
  228. package/references/official-docs/docs/persistence-schema.json +61480 -0
  229. package/references/official-docs/docs/postmortem/README.i18n.yaml +1 -1
  230. package/references/official-docs/docs/postmortem/README.md +1 -1
  231. package/references/official-docs/docs/postmortem/README.zh.md +1 -1
  232. package/references/official-docs/docs/rescope.i18n.yaml +2 -2
  233. package/references/official-docs/docs/rescope.md +2 -2
  234. package/references/official-docs/docs/rescope.zh.md +2 -2
  235. package/references/official-docs/docs/session-format-status.i18n.yaml +6 -0
  236. package/references/official-docs/docs/session-format-status.md +49 -0
  237. package/references/official-docs/docs/session-format-status.zh.md +49 -0
  238. package/references/official-docs/docs/subsystems/README.i18n.yaml +2 -2
  239. package/references/official-docs/docs/subsystems/README.md +12 -3
  240. package/references/official-docs/docs/subsystems/README.zh.md +23 -14
  241. package/references/official-docs/docs/subsystems/agent-team.i18n.yaml +2 -2
  242. package/references/official-docs/docs/subsystems/agent-team.md +1 -1
  243. package/references/official-docs/docs/subsystems/agent-team.zh.md +2 -2
  244. package/references/official-docs/docs/subsystems/approval.i18n.yaml +2 -2
  245. package/references/official-docs/docs/subsystems/approval.md +1 -1
  246. package/references/official-docs/docs/subsystems/approval.zh.md +1 -1
  247. package/references/official-docs/docs/subsystems/attachment.i18n.yaml +2 -2
  248. package/references/official-docs/docs/subsystems/attachment.md +17 -7
  249. package/references/official-docs/docs/subsystems/attachment.zh.md +17 -7
  250. package/references/official-docs/docs/subsystems/{code-runtime.i18n.yaml → boot.i18n.yaml} +3 -3
  251. package/references/official-docs/docs/subsystems/boot.md +223 -0
  252. package/references/official-docs/docs/subsystems/boot.zh.md +223 -0
  253. package/references/official-docs/docs/subsystems/browser-use.i18n.yaml +6 -0
  254. package/references/official-docs/docs/subsystems/browser-use.md +67 -0
  255. package/references/official-docs/docs/subsystems/browser-use.zh.md +67 -0
  256. package/references/official-docs/docs/subsystems/client-modules.i18n.yaml +2 -2
  257. package/references/official-docs/docs/subsystems/client-modules.md +20 -10
  258. package/references/official-docs/docs/subsystems/client-modules.zh.md +21 -11
  259. package/references/official-docs/docs/subsystems/client-resources.i18n.yaml +6 -0
  260. package/references/official-docs/docs/subsystems/client-resources.md +92 -0
  261. package/references/official-docs/docs/subsystems/client-resources.zh.md +92 -0
  262. package/references/official-docs/docs/subsystems/commands.i18n.yaml +2 -2
  263. package/references/official-docs/docs/subsystems/commands.md +4 -0
  264. package/references/official-docs/docs/subsystems/commands.zh.md +5 -1
  265. package/references/official-docs/docs/subsystems/compaction.i18n.yaml +2 -2
  266. package/references/official-docs/docs/subsystems/compaction.md +48 -2
  267. package/references/official-docs/docs/subsystems/compaction.zh.md +50 -4
  268. package/references/official-docs/docs/subsystems/computer-use.i18n.yaml +6 -0
  269. package/references/official-docs/docs/subsystems/computer-use.md +56 -0
  270. package/references/official-docs/docs/subsystems/computer-use.zh.md +56 -0
  271. package/references/official-docs/docs/subsystems/conversation.zh.md +1 -1
  272. package/references/official-docs/docs/subsystems/core.i18n.yaml +2 -2
  273. package/references/official-docs/docs/subsystems/core.md +106 -60
  274. package/references/official-docs/docs/subsystems/core.zh.md +109 -63
  275. package/references/official-docs/docs/subsystems/deliverables.i18n.yaml +6 -0
  276. package/references/official-docs/docs/subsystems/deliverables.md +178 -0
  277. package/references/official-docs/docs/subsystems/deliverables.zh.md +178 -0
  278. package/references/official-docs/docs/subsystems/extensions.zh.md +1 -1
  279. package/references/official-docs/docs/subsystems/feedback.i18n.yaml +2 -2
  280. package/references/official-docs/docs/subsystems/feedback.md +165 -31
  281. package/references/official-docs/docs/subsystems/feedback.zh.md +165 -31
  282. package/references/official-docs/docs/subsystems/filesystem.i18n.yaml +2 -2
  283. package/references/official-docs/docs/subsystems/filesystem.md +15 -0
  284. package/references/official-docs/docs/subsystems/filesystem.zh.md +16 -1
  285. package/references/official-docs/docs/subsystems/goal.i18n.yaml +2 -2
  286. package/references/official-docs/docs/subsystems/goal.md +37 -1
  287. package/references/official-docs/docs/subsystems/goal.zh.md +38 -2
  288. package/references/official-docs/docs/subsystems/invariants.i18n.yaml +2 -2
  289. package/references/official-docs/docs/subsystems/invariants.md +1 -1
  290. package/references/official-docs/docs/subsystems/invariants.zh.md +3 -3
  291. package/references/official-docs/docs/subsystems/jobs.i18n.yaml +1 -1
  292. package/references/official-docs/docs/subsystems/jobs.md +1 -1
  293. package/references/official-docs/docs/subsystems/jobs.zh.md +1 -1
  294. package/references/official-docs/docs/subsystems/llm-streaming.i18n.yaml +2 -2
  295. package/references/official-docs/docs/subsystems/llm-streaming.md +35 -15
  296. package/references/official-docs/docs/subsystems/llm-streaming.zh.md +37 -17
  297. package/references/official-docs/docs/subsystems/lsp.i18n.yaml +2 -2
  298. package/references/official-docs/docs/subsystems/lsp.md +1 -1
  299. package/references/official-docs/docs/subsystems/lsp.zh.md +1 -1
  300. package/references/official-docs/docs/subsystems/mcp.i18n.yaml +6 -0
  301. package/references/official-docs/docs/subsystems/mcp.md +139 -0
  302. package/references/official-docs/docs/subsystems/mcp.zh.md +139 -0
  303. package/references/official-docs/docs/subsystems/office-to-pdf.i18n.yaml +6 -0
  304. package/references/official-docs/docs/subsystems/office-to-pdf.md +87 -0
  305. package/references/official-docs/docs/subsystems/office-to-pdf.zh.md +87 -0
  306. package/references/official-docs/docs/subsystems/permission-presets.i18n.yaml +2 -2
  307. package/references/official-docs/docs/subsystems/permission-presets.md +62 -27
  308. package/references/official-docs/docs/subsystems/permission-presets.zh.md +62 -27
  309. package/references/official-docs/docs/subsystems/persistence.i18n.yaml +2 -2
  310. package/references/official-docs/docs/subsystems/persistence.md +36 -15
  311. package/references/official-docs/docs/subsystems/persistence.zh.md +36 -15
  312. package/references/official-docs/docs/subsystems/plan.zh.md +2 -2
  313. package/references/official-docs/docs/subsystems/ptc-runtime.i18n.yaml +6 -0
  314. package/references/official-docs/docs/subsystems/ptc-runtime.md +232 -0
  315. package/references/official-docs/docs/subsystems/ptc-runtime.zh.md +232 -0
  316. package/references/official-docs/docs/subsystems/sandbox.i18n.yaml +2 -2
  317. package/references/official-docs/docs/subsystems/sandbox.md +5 -4
  318. package/references/official-docs/docs/subsystems/sandbox.zh.md +7 -6
  319. package/references/official-docs/docs/subsystems/schedule.i18n.yaml +2 -2
  320. package/references/official-docs/docs/subsystems/schedule.md +2 -2
  321. package/references/official-docs/docs/subsystems/schedule.zh.md +3 -3
  322. package/references/official-docs/docs/subsystems/scope.i18n.yaml +2 -2
  323. package/references/official-docs/docs/subsystems/scope.md +1 -1
  324. package/references/official-docs/docs/subsystems/scope.zh.md +1 -1
  325. package/references/official-docs/docs/subsystems/session-projection.i18n.yaml +2 -2
  326. package/references/official-docs/docs/subsystems/session-projection.md +1 -1
  327. package/references/official-docs/docs/subsystems/session-projection.zh.md +2 -2
  328. package/references/official-docs/docs/subsystems/session-reference.i18n.yaml +2 -2
  329. package/references/official-docs/docs/subsystems/session-reference.md +11 -6
  330. package/references/official-docs/docs/subsystems/session-reference.zh.md +11 -6
  331. package/references/official-docs/docs/subsystems/session-telemetry.i18n.yaml +2 -2
  332. package/references/official-docs/docs/subsystems/session-telemetry.md +22 -6
  333. package/references/official-docs/docs/subsystems/session-telemetry.zh.md +23 -7
  334. package/references/official-docs/docs/subsystems/session-title.i18n.yaml +2 -2
  335. package/references/official-docs/docs/subsystems/session-title.md +5 -5
  336. package/references/official-docs/docs/subsystems/session-title.zh.md +5 -5
  337. package/references/official-docs/docs/subsystems/session.i18n.yaml +2 -2
  338. package/references/official-docs/docs/subsystems/session.md +149 -61
  339. package/references/official-docs/docs/subsystems/session.zh.md +150 -62
  340. package/references/official-docs/docs/subsystems/shell.i18n.yaml +2 -2
  341. package/references/official-docs/docs/subsystems/shell.md +19 -15
  342. package/references/official-docs/docs/subsystems/shell.zh.md +20 -16
  343. package/references/official-docs/docs/subsystems/sidebar-right.i18n.yaml +6 -0
  344. package/references/official-docs/docs/subsystems/sidebar-right.md +153 -0
  345. package/references/official-docs/docs/subsystems/sidebar-right.zh.md +153 -0
  346. package/references/official-docs/docs/subsystems/skills.i18n.yaml +2 -2
  347. package/references/official-docs/docs/subsystems/skills.md +4 -6
  348. package/references/official-docs/docs/subsystems/skills.zh.md +4 -6
  349. package/references/official-docs/docs/subsystems/slots.i18n.yaml +2 -2
  350. package/references/official-docs/docs/subsystems/slots.md +52 -38
  351. package/references/official-docs/docs/subsystems/slots.zh.md +53 -39
  352. package/references/official-docs/docs/subsystems/spill.i18n.yaml +2 -2
  353. package/references/official-docs/docs/subsystems/spill.md +13 -6
  354. package/references/official-docs/docs/subsystems/spill.zh.md +13 -6
  355. package/references/official-docs/docs/subsystems/ssh.i18n.yaml +6 -0
  356. package/references/official-docs/docs/subsystems/ssh.md +135 -0
  357. package/references/official-docs/docs/subsystems/ssh.zh.md +135 -0
  358. package/references/official-docs/docs/subsystems/storage.zh.md +2 -2
  359. package/references/official-docs/docs/subsystems/subagent.i18n.yaml +2 -2
  360. package/references/official-docs/docs/subsystems/subagent.md +33 -16
  361. package/references/official-docs/docs/subsystems/subagent.zh.md +32 -15
  362. package/references/official-docs/docs/subsystems/subprocess.i18n.yaml +2 -2
  363. package/references/official-docs/docs/subsystems/subprocess.md +41 -44
  364. package/references/official-docs/docs/subsystems/subprocess.zh.md +41 -44
  365. package/references/official-docs/docs/subsystems/system-prompt.i18n.yaml +2 -2
  366. package/references/official-docs/docs/subsystems/system-prompt.md +6 -2
  367. package/references/official-docs/docs/subsystems/system-prompt.zh.md +7 -3
  368. package/references/official-docs/docs/subsystems/todo.zh.md +1 -1
  369. package/references/official-docs/docs/subsystems/token-meter.i18n.yaml +2 -2
  370. package/references/official-docs/docs/subsystems/token-meter.md +2 -1
  371. package/references/official-docs/docs/subsystems/token-meter.zh.md +2 -1
  372. package/references/official-docs/docs/subsystems/tools.i18n.yaml +2 -2
  373. package/references/official-docs/docs/subsystems/tools.md +28 -12
  374. package/references/official-docs/docs/subsystems/tools.zh.md +28 -12
  375. package/references/official-docs/docs/subsystems/typert.i18n.yaml +2 -2
  376. package/references/official-docs/docs/subsystems/typert.md +6 -5
  377. package/references/official-docs/docs/subsystems/typert.zh.md +6 -5
  378. package/references/official-docs/docs/subsystems/user-questions.i18n.yaml +2 -2
  379. package/references/official-docs/docs/subsystems/user-questions.md +2 -0
  380. package/references/official-docs/docs/subsystems/user-questions.zh.md +2 -0
  381. package/references/official-docs/docs/subsystems/web-client.i18n.yaml +2 -2
  382. package/references/official-docs/docs/subsystems/web-client.md +5 -5
  383. package/references/official-docs/docs/subsystems/web-client.zh.md +6 -6
  384. package/references/official-docs/docs/subsystems/web-server.i18n.yaml +2 -2
  385. package/references/official-docs/docs/subsystems/web-server.md +64 -0
  386. package/references/official-docs/docs/subsystems/web-server.zh.md +65 -1
  387. package/references/official-docs/docs/subsystems/webhook.i18n.yaml +1 -1
  388. package/references/official-docs/docs/subsystems/webhook.md +2 -2
  389. package/references/official-docs/docs/subsystems/workflow.i18n.yaml +2 -2
  390. package/references/official-docs/docs/subsystems/workflow.md +8 -8
  391. package/references/official-docs/docs/subsystems/workflow.zh.md +10 -10
  392. package/references/official-docs/docs/subsystems/workspace.i18n.yaml +2 -2
  393. package/references/official-docs/docs/subsystems/workspace.md +199 -1
  394. package/references/official-docs/docs/subsystems/workspace.zh.md +199 -1
  395. package/references/official-docs/docs/testing.i18n.yaml +2 -2
  396. package/references/official-docs/docs/testing.md +5 -4
  397. package/references/official-docs/docs/testing.zh.md +5 -4
  398. package/references/official-docs/docs/tool-catalog.i18n.yaml +2 -2
  399. package/references/official-docs/docs/tool-catalog.md +452 -187
  400. package/references/official-docs/docs/tool-catalog.zh.md +454 -189
  401. package/references/official-docs/docs/tool-execution-pipeline.i18n.yaml +2 -2
  402. package/references/official-docs/docs/tool-execution-pipeline.md +2 -2
  403. package/references/official-docs/docs/tool-execution-pipeline.zh.md +2 -2
  404. package/references/official-docs/docs/user/develop/basic/index.zh.md +1 -1
  405. package/references/official-docs/docs/user/develop/basic/publish.i18n.yaml +2 -2
  406. package/references/official-docs/docs/user/develop/basic/publish.md +2 -2
  407. package/references/official-docs/docs/user/develop/basic/publish.zh.md +5 -5
  408. package/references/official-docs/docs/user/develop/framework/index.i18n.yaml +2 -2
  409. package/references/official-docs/docs/user/develop/framework/index.md +1 -1
  410. package/references/official-docs/docs/user/develop/framework/index.zh.md +1 -1
  411. package/references/official-docs/docs/user/develop/practice/dynamic-cordis.i18n.yaml +2 -2
  412. package/references/official-docs/docs/user/develop/practice/dynamic-cordis.md +8 -8
  413. package/references/official-docs/docs/user/develop/practice/dynamic-cordis.zh.md +8 -8
  414. package/references/official-docs/docs/user/guide/index.zh.md +2 -2
  415. package/references/official-docs/docs/user/guide/mcp-memory.zh.md +1 -1
  416. package/references/official-docs/docs/user/guide/network-proxy.i18n.yaml +2 -2
  417. package/references/official-docs/docs/user/guide/network-proxy.md +1 -1
  418. package/references/official-docs/docs/user/guide/network-proxy.zh.md +1 -1
  419. package/references/official-docs/docs/user/guide/providers.i18n.yaml +2 -2
  420. package/references/official-docs/docs/user/guide/providers.md +12 -8
  421. package/references/official-docs/docs/user/guide/providers.zh.md +14 -10
  422. package/references/official-docs/docs/user/guide/python-sdk.i18n.yaml +2 -2
  423. package/references/official-docs/docs/user/guide/python-sdk.md +59 -23
  424. package/references/official-docs/docs/user/guide/python-sdk.zh.md +60 -24
  425. package/references/official-docs/docs/web-styling.i18n.yaml +2 -2
  426. package/references/official-docs/docs/web-styling.md +2 -1
  427. package/references/official-docs/docs/web-styling.zh.md +3 -2
  428. package/references/official-docs/packages/AGENTS.md +1 -1
  429. package/references/official-docs/packages/README.md +12 -7
  430. package/references/official-docs/vendor/README.md +15 -11
  431. package/references/official-docs/website-docs.ts +4 -2
  432. package/scripts/sync-official-docs.ps1 +5 -5
  433. package/templates/js/README-es.md +1 -1
  434. package/templates/js/README-hi.md +1 -1
  435. package/templates/js/README-pt.md +1 -1
  436. package/templates/js/README-zh.md +1 -1
  437. package/templates/js/README.md +1 -1
  438. package/templates/js/package.json +2 -2
  439. package/templates/ts/README-es.md +1 -1
  440. package/templates/ts/README-hi.md +1 -1
  441. package/templates/ts/README-pt.md +1 -1
  442. package/templates/ts/README-zh.md +1 -1
  443. package/templates/ts/README.md +1 -1
  444. package/templates/ts/package.json +2 -2
  445. package/references/official-docs/docs/subsystems/code-runtime.md +0 -195
  446. package/references/official-docs/docs/subsystems/code-runtime.zh.md +0 -195
@@ -25,23 +25,30 @@ sequenceDiagram
25
25
  Note over Agent,Driver: claim pending next-step input plus one queued prompt
26
26
  Driver-->>SDK: <code>agent/inbox/spliced</code> pure deletion
27
27
  Driver-->>SDK: <code>agent/inbox/claimed</code> { message, turn } per message
28
+ Driver->>Prompt: <code>system-prompt/assemble</code> waterfall
28
29
  Driver->>Hooks: <code>agent/pre-step</code> waterfall
29
30
  Hooks-->>Driver: authoritative reject or enter(messages)
30
- alt proposed step rejected or pre-step failed
31
+ alt proposed step rejected, first batch empty, or pre-step failed
31
32
  Driver-->>Driver: claimed batch stays removed, the open turn spends no step
32
33
  else enter proposed step
33
34
  Driver->>Session: <code>step/start</code>
35
+ Driver->>Hooks: <code>agent/request</code> waterfall
36
+ Driver->>LLM: prepareCall(config, signal)
37
+ Note over Driver,LLM: cancellation during either async phase commits neither system nor users
38
+ Note over Driver,Session: synchronous admission using the prepared call capability
39
+ Driver->>Session: <code>system/message</code> ordered per-node reconciliation
34
40
  Driver->>Session: <code>user/message</code> per entered message
35
- Driver->>Prompt: <code>system-prompt/assemble</code> waterfall
36
- Driver->>LLM: <code>agent/request</code> waterfall, then <code>llm/stream</code> waterfall
41
+ Driver->>Session: <code>request/header</code> and <code>request/context</code> as needed
42
+ Driver->>Driver: derive and freeze request from the log
43
+ Driver->>LLM: bound prepared call through <code>llm/stream</code> waterfall
37
44
  LLM-->>Driver: StreamChunk*
38
45
  Driver-->>SDK: <code>agent/assistant-stream</code> chunk*
39
46
  alt final adapter or terminal in-band request failure
40
47
  Driver->>Session: <code>assistant/attempt</code>
41
48
  Driver-->>SDK: <code>agent/assistant-stream</code> committed end
42
- Driver->>Session: <code>step/end</code>
43
49
  Driver->>Hooks: <code>agent/request-error</code> waterfall
44
50
  Hooks-->>Driver: return retry action or preserve the original error
51
+ Note over Driver,LLM: retry in the open step: prepare and reconcile the same rendered assembly without repeating pre-step or users
45
52
  else model request succeeded
46
53
  Driver->>Session: <code>assistant/message</code>
47
54
  Driver-->>SDK: <code>agent/assistant-stream</code> committed end
@@ -75,7 +82,7 @@ sequenceDiagram
75
82
 
76
83
  The `assistant/message` event records every successful provider call, including content-less and `max-tokens` finishes, and embeds the exact compact timed stream. Empty content stays out of derived history. A failed, retried, cancelled, or stream-error attempt that reaches settlement without a surface message records its stream as `assistant/attempt`. Live `agent/assistant-stream` chunk frames are transient; replay reads either durable settlement, and a hard process loss before settlement leaves no durable attempt stream.
77
84
 
78
- `dsh-compaction-basic` uses `agent/pre-step` for pressure before request derivation and `agent/request-error` only for canonical context overflow. Once either trigger qualifies, optional tool-result pruning runs before summary selection. Recovery works between the closed failed step and failed turn close, and opens a fresh retry turn only when pruning or summarization advances the surface replacement generation; otherwise the original request error remains authoritative.
85
+ `dsh-compaction-basic` uses `agent/pre-step` for pressure before request derivation and `agent/request-error` only for canonical context overflow. Once either trigger qualifies, optional tool-result pruning runs before summary selection. Recovery runs within the open step and retries only when pruning or summarization advances the surface replacement generation; otherwise the original request error remains authoritative. Each retry prepares its call and reconciles the retained rendered assembly before request derivation, without repeating assembly, pre-step, or user admission.
79
86
 
80
87
  The returned `agent/pre-step` decision is authoritative; listeners wrapping `next()` preserve downstream messages and `startsRequestSeries` unless replacement is intentional. Steering and injected context pass through the same waterfall after a later claim operation takes their next-step batch.
81
88
 
@@ -27,23 +27,30 @@ sequenceDiagram
27
27
  Note over Agent,Driver: claim pending next-step input plus one queued prompt
28
28
  Driver-->>SDK: <code>agent/inbox/spliced</code> pure deletion
29
29
  Driver-->>SDK: <code>agent/inbox/claimed</code> { message, turn } per message
30
+ Driver->>Prompt: <code>system-prompt/assemble</code> waterfall
30
31
  Driver->>Hooks: <code>agent/pre-step</code> waterfall
31
32
  Hooks-->>Driver: authoritative reject or enter(messages)
32
- alt proposed step rejected or pre-step failed
33
+ alt proposed step rejected, first batch empty, or pre-step failed
33
34
  Driver-->>Driver: claimed batch stays removed, the open turn spends no step
34
35
  else enter proposed step
35
36
  Driver->>Session: <code>step/start</code>
37
+ Driver->>Hooks: <code>agent/request</code> waterfall
38
+ Driver->>LLM: prepareCall(config, signal)
39
+ Note over Driver,LLM: cancellation during either async phase commits neither system nor users
40
+ Note over Driver,Session: synchronous admission using the prepared call capability
41
+ Driver->>Session: <code>system/message</code> ordered per-node reconciliation
36
42
  Driver->>Session: <code>user/message</code> per entered message
37
- Driver->>Prompt: <code>system-prompt/assemble</code> waterfall
38
- Driver->>LLM: <code>agent/request</code> waterfall, then <code>llm/stream</code> waterfall
43
+ Driver->>Session: <code>request/header</code> and <code>request/context</code> as needed
44
+ Driver->>Driver: derive and freeze request from the log
45
+ Driver->>LLM: bound prepared call through <code>llm/stream</code> waterfall
39
46
  LLM-->>Driver: StreamChunk*
40
47
  Driver-->>SDK: <code>agent/assistant-stream</code> chunk*
41
48
  alt final adapter or terminal in-band request failure
42
49
  Driver->>Session: <code>assistant/attempt</code>
43
50
  Driver-->>SDK: <code>agent/assistant-stream</code> committed end
44
- Driver->>Session: <code>step/end</code>
45
51
  Driver->>Hooks: <code>agent/request-error</code> waterfall
46
52
  Hooks-->>Driver: return retry action or preserve the original error
53
+ Note over Driver,LLM: retry in the open step: prepare and reconcile the same rendered assembly without repeating pre-step or users
47
54
  else model request succeeded
48
55
  Driver->>Session: <code>assistant/message</code>
49
56
  Driver-->>SDK: <code>agent/assistant-stream</code> committed end
@@ -77,7 +84,7 @@ sequenceDiagram
77
84
 
78
85
  `assistant/message` 事件会记录每次成功的提供方调用,包括返回空内容或以 `max-tokens` 结束的调用,并嵌入精确的紧凑带时间 stream。空内容不会进入派生历史。失败、重试、取消或 stream error attempt 到达 settlement 时,如果没有 surface message,就会把 stream 记录为 `assistant/attempt`。实时 `agent/assistant-stream` chunk frame 是瞬态数据;回放读取任一种持久 settlement,如果进程在 settlement 前硬中断,则不会留下持久 attempt stream。
79
86
 
80
- `dsh-compaction-basic` 在派生请求之前通过 `agent/pre-step` 处理压力,而 `agent/request-error` 仅用于规范的上下文溢出。任一触发条件满足后,系统都会先执行可选的工具结果剪枝,再选择摘要。恢复发生在失败步骤结束之后、失败轮次结束之前;只有当剪枝或摘要生成推进了 surface replacement generation 时,系统才会开启一个全新的重试轮次,否则仍以原始请求错误为准。
87
+ `dsh-compaction-basic` 在派生请求之前通过 `agent/pre-step` 处理压力,而 `agent/request-error` 仅用于规范的上下文溢出。任一触发条件满足后,系统都会先执行可选的工具结果剪枝,再选择摘要。恢复发生在仍打开的步骤内,只有剪枝或摘要生成推进 surface replacement generation 时才重试,否则仍以原始请求错误为准。每次重试都会准备调用,并在派生请求之前协调保留的已渲染组装结果,不重复组装、pre-step 或用户消息准入。
81
88
 
82
89
  以返回的 `agent/pre-step` 决策为准;通过包装 `next()` 的监听器会保留下游消息与 `startsRequestSeries`,除非有意替换。steering(中途引导)和注入的上下文在后续的认领操作取得其下一步骤批次后,会经过同一 waterfall(瀑布式事件)。
83
90
 
@@ -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 docs/api-gateway.md
5
- api-gateway.md: 0c64fdf6a528ea6564915a06abb237fd65b91e66
6
- api-gateway.zh.md: 43bf87865de70a7921502c4105ce1777bc30394e
5
+ api-gateway.md: 2cf7b2f345991fd20639e1294662cc64fc02093d
6
+ api-gateway.zh.md: 5b80db08de49591b27751e187aa6278384a7444e
@@ -85,8 +85,8 @@ The `api-remotes` assembly and the `ctx.remote` contract are React-independent;
85
85
  | Build | `@deepseek-ai/dsh-typert-generator` | Strictly analyzes Remote signatures, the type graph, lookups, Contexts, and source locations from the Host `ts.Program`, then generates Host and Host-for-Client artifacts |
86
86
  | Host | `@deepseek-ai/dsh-typert-registry` and Loader | Places generated Host descriptors, schemas, and business-package registrations in `ctx.typert`, and holds lookup and Context providers |
87
87
  | Host | `@deepseek-ai/dsh-api-session-controller` | Owns the application Agent/Session identity policy and configures the corresponding Typert lookups |
88
- | Host | `@deepseek-ai/dsh-api-gateway` | Provides `ctx.typertGateway`, claims Remote endpoints, resolves objects or Contexts, invokes live Cordis services, and validates request and return values |
89
- | Client | `@deepseek-ai/dsh-api-gateway/client` | Provides `ctx.remote` and `remote.<namespace>` child Services, mounts generated descriptors as concrete methods, and initiates, validates, and cancels calls through the Connection |
88
+ | Host | `@deepseek-ai/dsh-api-gateway` | Provides `ctx.typertGateway`, claims Remote endpoints, validates request values, resolves objects or Contexts, and invokes live Cordis services |
89
+ | Client | `@deepseek-ai/dsh-api-gateway/client` | Provides `ctx.remote` and `remote.<namespace>` child Services, mounts generated descriptors as concrete methods, and initiates and cancels calls through the Connection |
90
90
  | Client | `@deepseek-ai/dsh-api-remotes/client` | Explicitly selects and mounts the `/remote` contributions allowed by the application and brings the corresponding declaration merges into business code |
91
91
  | Both | `@deepseek-ai/dsh-client-connection` | Provides the RPC carrier, request correlation, trust boundary, cancellation, response envelope, and the `/api` HTTP bridge |
92
92
 
@@ -85,8 +85,8 @@ Client 应用只装配 `@deepseek-ai/dsh-api-remotes`。该包以运行时值导
85
85
  | 构建 | `@deepseek-ai/dsh-typert-generator` | 从 Host `ts.Program` 严格分析 Remote 签名、类型图、lookup、Context 与源码位置,并生成 Host 和 Host-for-Client 产物 |
86
86
  | Host | `@deepseek-ai/dsh-typert-registry` 与 Loader | 把生成的 Host 描述符、schema 及业务包注册项放入 `ctx.typert`,并持有 lookup 与 Context 提供方 |
87
87
  | Host | `@deepseek-ai/dsh-api-session-controller` | 负责应用的 Agent/Session 身份策略,并配置对应的 Typert lookup |
88
- | Host | `@deepseek-ai/dsh-api-gateway` | 提供 `ctx.typertGateway`,认领 Remote endpoint,解析对象或 Context,调用实时 Cordis 服务,并校验请求值和返回值 |
89
- | Client | `@deepseek-ai/dsh-api-gateway/client` | 提供 `ctx.remote` 与 `remote.<namespace>` 子服务,把生成的描述符挂成具体方法,并通过 Connection 发起、校验和取消调用 |
88
+ | Host | `@deepseek-ai/dsh-api-gateway` | 提供 `ctx.typertGateway`,认领 Remote endpoint,校验请求值,解析对象或 Context,并调用实时 Cordis 服务 |
89
+ | Client | `@deepseek-ai/dsh-api-gateway/client` | 提供 `ctx.remote` 与 `remote.<namespace>` 子服务,把生成的描述符挂成具体方法,并通过 Connection 发起和取消调用 |
90
90
  | Client | `@deepseek-ai/dsh-api-remotes/client` | 显式选择并挂载本应用允许使用的 `/remote` 贡献,向业务代码带入对应的声明合并 |
91
91
  | 双侧 | `@deepseek-ai/dsh-client-connection` | 提供 RPC carrier、请求关联、信任边界、取消、响应 envelope 与 `/api` HTTP bridge |
92
92
 
@@ -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 docs/architecture.md
5
- architecture.md: 959ea9edf8f337b1ebe20df8b998f11fe35beb2e
6
- architecture.zh.md: 9666f3589ce3710f84306d685ec1c5e7a49d1b78
5
+ architecture.md: 0bbf5ef7f4c0444635178ba0ba85fbb9527d76ec
6
+ architecture.zh.md: 0d28dc349fd9c655529bcc43deabc47055e0d394
@@ -26,7 +26,9 @@ Each declares itself in its own `package.json` under a `dsh` field: `dsh.profile
26
26
 
27
27
  Layers apply to an empty entry list in this order: each bundle in the profile's listed order, then the profile's `cordis.patch.yml`, then the home-level one, then any `--patch` overlay. A patch targets a row by id and replaces its whole config, or inserts new rows.
28
28
 
29
- Custom profiles default to live patch reload. The shipped `web` profile is live; `headless`, `sdk`, `sdk-minimal`, and `acp` apply all layers once at startup because replacing a one-shot or stdio application's dependencies after it owns work would invalidate that lifecycle.
29
+ YAML controls HMR: base enables config-only `dsh-hmr`; headless, SDK and ACP disable it; `sdk-minimal` omits it. Profile patches override these defaults. HMR coordinates watching and reloads; the launcher provides profile data and readiness.
30
+
31
+ Base includes [Plugin Manager](../packages/boot/plugin-manager/README.md) for Web and agents.
30
32
 
31
33
  To see the tree your machine boots:
32
34
 
@@ -40,12 +42,18 @@ Composition mechanics are in [app-boot](../packages/boot/app-boot/README.md#prof
40
42
 
41
43
  ## Application launch
42
44
 
43
- Every supported Node application starts at the `dsh` CLI with a named profile. The shipped applications are `dsh web` (the deliberate alias for `--profile web`), `dsh --profile headless`, `dsh --profile sdk`, `dsh --profile sdk-minimal`, and `dsh --profile acp`. The TypeScript SDK resolves its same-version `dsh` dependency and selects `sdk`; custom plugin composition remains a profile plus ordered patch files, not another executable or inline application tree. `sdk-minimal` is a repository-owned standalone bundle behind the same launcher, not a caller-supplied Cordis tree.
45
+ Supported Node applications launch through named `dsh` profiles. The shipped profiles are `web`, `headless`, `sdk`, `sdk-minimal`, and `acp`, selected with `dsh --profile <name>` or `dsh <name>`. `plugin` names the management command; a profile with that name requires `--profile plugin`. The TypeScript SDK resolves its same-version `dsh` dependency and selects `sdk`; custom plugin composition remains a profile plus ordered patch files, not another executable or inline application tree. `sdk-minimal` is a repository-owned standalone bundle behind the same launcher, not a caller-supplied Cordis tree.
44
46
 
45
47
  Vendored CLIs, build-only and test-only executables, direct in-process plugin mounting, and the private browser WebWorker preview are not Harness application launchers. [`verify-application-entrypoints`](../scripts/verify-application-entrypoints.ts) keeps every package bin, executable source, and root demo in an explicit class and rejects a Node application path that bypasses `dsh`.
46
48
 
47
49
  The Python SDK follows the same application architecture. Its runtime wheel packages the normal `dsh` CLI as `deepseek-harness-sdk-runtime-<platform>-<arch>`, and the client launches `dsh --profile sdk` with an explicit Harness home by default. The minimal example selects the shipped `sdk-minimal` profile. Python exposes profile selection and ordered patch files rather than a complete Cordis tree; persistent external plugins are installed through `dsh plugin`. The removed private direct-config carrier has no compatibility bin or fallback parser.
48
50
 
51
+ ## Desktop application
52
+
53
+ The [Electron desktop application](../apps/desktop/README.md) carries its exact dsh production runtime in signed resources and owns the reserved `$DSH_HOME/profiles/desktop`. Shared profile helpers initialize its files, reconcile installed bundles, and resolve installation and bundle dependencies without replacing pnpm-owned packages. CLI and Desktop share product data, while executable packages, activation choices, and lockfiles remain separate. The public CLI cannot manage Desktop’s profile.
54
+
55
+ Electron starts the private Desktop Host in Electron Node mode. The Host invokes the shared CLI profile runner and complete Web application. The window immediately loads packaged Web assets and waits for boot injections before activating client plugins in the same document. Web owns RPC and streams; the desktop carrier connects the local page to the authenticated Host. Node IPC carries boot injections, readiness, fatal errors, and shutdown. Desktop defaults to port `19387`; profile configuration can override it. Shell-owned UI runs plugin transactions through bundled pnpm with normal user and profile configuration.
56
+
49
57
  ## Core packages
50
58
 
51
59
  Here are some core packages that contribute to the Cordis tree.
@@ -69,6 +77,8 @@ Events are the extension points, and picking the right domain is the first decis
69
77
  - **Agent events** (`agent/*`) carry a live `Agent`: inbox, step, status, request, validation, continuation. Use one to observe or intercept work in flight.
70
78
  - **Capability events** attach policy and adapters to a seam (`fs/*`, `tools/*`, `telemetry/*`) without importing the loop.
71
79
 
80
+ AgentLoop awaits serial `agent/created` initialization before starting queued work. Initialization failure rolls back creation; [agent-loop](../packages/core/agent-loop/README.md#understand-the-implementation) defines teardown ordering.
81
+
72
82
  The [event map](event-producer-consumer.md) lists every event's producers and consumers.
73
83
 
74
84
  ## Turn flow
@@ -78,13 +88,15 @@ A **step** is one model request plus the tools it calls. A **turn** is zero or m
78
88
  ```text
79
89
  turn/start
80
90
  claim next-step input plus one queued message
81
- assemble prompt sections + tool schemas
91
+ assemble prompt sections + tool schemas; project runtime context
82
92
  -> agent/pre-step reject | enter(messages, startsRequestSeries?)
83
93
  reject, or a first enter rewritten empty -> close the turn with no step
84
94
  step/start
85
- append entered messages as user/message
86
- derive model history from the log
87
- agent/request -> llm/stream -> agent/assistant-stream start
95
+ agent/request -> prepareCall (cancellation commits neither system nor users)
96
+ reconcile system/message using the prepared call capability
97
+ append entered messages as user/message; log request/header and request/context as needed
98
+ derive and freeze model history from the log
99
+ stream the bound prepared call -> llm/stream -> agent/assistant-stream start
88
100
  agent/assistant-stream chunk*
89
101
  assistant/message | assistant/attempt -> agent/assistant-stream end
90
102
  tool/call* -> tools/pre-execute -> tools/execute -> tools/post-execute -> tool/result*
@@ -94,11 +106,13 @@ turn/start
94
106
  turn/end
95
107
  ```
96
108
 
97
- `turn/*`, `step/*`, `user/message`, `assistant/message`, `assistant/attempt`, and `tool/*` are durable session events; the rest are live extension points across three domains. `agent/assistant-stream` publishes process-local start, transient chunk, and end frames. The loop commits the complete compact stream as one message or log-only attempt before a committed end frame, and the Web Session-follow adapter is the live event's only remote consumer. `agent/pre-step`, `agent/request`, `llm/stream`, and the three `tools/*` events are waterfalls, whose listeners must call `next()` to delegate; `agent/turn-stopping` is serial and has no `next()`.
109
+ `turn/*`, `step/*`, `system/message`, `user/message`, `assistant/message`, `assistant/attempt`, and `tool/*` are durable session events; the rest are live extension points across three domains. `agent/assistant-stream` publishes process-local start, transient chunk, and end frames. The loop commits the complete compact stream as one message or log-only attempt before a committed end frame, and the Web Session-follow adapter is the live event's only remote consumer. `agent/pre-step`, `agent/request`, `llm/stream`, and the three `tools/*` events are waterfalls, whose listeners must call `next()` to delegate; `agent/turn-stopping` is serial and has no `next()`.
110
+
111
+ One inbox feeds the driver; injected context waits for a waking message. AgentLoop’s durable `inbox` projection exposes pending input without live Agents.
98
112
 
99
- Input reaches the driver through one inbox. Some messages wake it immediately; injected context waits in the inbox until another message does.
113
+ `agent/pre-step` decides the accepted input. Listeners may rewrite or reject claimed messages; a rejected or empty first claim closes a durable turn without a step. An enter decision may set `startsRequestSeries`: the loop logs a fresh `request/header` (reason `series`, or `change` with `startsSeries: true` when the envelope also changed). Wrapping listeners preserve that declaration with `{ ...decision, messages }`. After assembly and `step/start`, `agent/request` and `prepareCall()` resolve the actual route before the system prompt and accepted users are committed; cancellation during either async phase commits neither. The prepared call capability governs prompt admission, not the preceding `request/context`. Every attempt synchronously reconciles the same rendered assembly, appends users only on the first attempt, logs header/context as needed, and derives and freezes the request before streaming the bound call. Retries do not repeat assembly or `agent/pre-step`. Surface replacements and image-offload decisions after attachment start a new request series, including during the first resumed pre-step; unchanged resume continues the series. The first admitted step reserves the system head before user messages even for an empty prompt (no wire message). The prompt travels only as `system/message` history: an empty rendering clears all active system nodes, leaving no old prompt model-visible; capable routes can append non-empty updates after the cached prefix; incapable routes and new request series consolidate non-empty prompt text at the first system node, with logged empty replacements for non-empty later system nodes ([decision](../.agents/notes/implemented/architecture/2026-09-02-system-prompt-as-surface-node.md); [decision rule](../packages/core/agent-loop/README.md#understand-the-implementation)).
100
114
 
101
- `agent/pre-step` decides what the model sees. Listeners may rewrite the claimed messages or reject them outright; a rejected or empty first claim still closes a durable turn that spent no step, so the log records the attempt. An enter decision may also set `startsRequestSeries` to begin a distinct model-message series: the loop then logs a fresh `request/header` (reason `series`, or `change` carrying `startsSeries: true` when the envelope changed too). A listener that rebuilds a downstream enter decision must spread it (`{ ...decision, messages }`) so the declaration survives. Each step reads the prompt sections and tool schemas that plugins registered.
115
+ The loop sends immutable requests while keeping cancellation live. It reuses message-freeze evidence only for identities it has fully frozen; [agent-loop](../packages/core/agent-loop/README.md) owns the request construction rules.
102
116
 
103
117
  Details: the [sequence diagram](agent-lifecycle.md), the [tool pipeline](tool-execution-pipeline.md), and [cancellation and error recovery](subsystems/core.md#the-agent-handle).
104
118
 
@@ -106,9 +120,9 @@ Details: the [sequence diagram](agent-lifecycle.md), the [tool pipeline](tool-ex
106
120
 
107
121
  The session log is the source of the context the model sees. `deriveMessages()` projects model history from it. Each `assistant/message` embeds the exact compact timed stream that produced its assembled content; `assistant/attempt` retains settled failed, retried, cancelled, and stream-error attempts without adding model history. Fork, resume, transcripts, telemetry, and persistence all derive from these durable settlements, while live UI incrementality comes from `agent/assistant-stream`; a hard process loss before settlement leaves no durable attempt stream ([decision](../.agents/notes/implemented/architecture/2026-09-01-v2-embedded-assistant-streams.md)).
108
122
 
109
- Session consumers know only the current logical format. Header-only `stat` and `list` rescan each Session directory, select its numerically highest canonical generation, and translate a supported historical header without loading events or publishing a successor. A stored-session `open` selects that same generation, refuses a future version, or composes the static adjacent migration chain in memory, validates the final result, and exclusively publishes only that version-named successor beside the unchanged source before returning a handle; semantic interrupted-turn repair remains a handle consumer responsibility. JSONL v0 uses `session.jsonl[.zstd]`, v1 and later use lowercase `session.vN.jsonl[.zstd]`, and committed generation paths are never renamed, replaced, or deleted. The JSONL provider owns physical framing, compression, generation selection, and exclusive publication, while each adjacent migration package owns exactly one `vN -> vN+1` step ([decision](../.agents/notes/implemented/architecture/2026-08-31-released-session-format-migrations.md)).
123
+ Session consumers know only the current logical format. Header-only `stat` and `list` rescan each Session directory, select its numerically highest canonical generation, and translate a supported historical header without loading events or publishing a successor. A stored-session `open` selects that same generation, refuses a future version, or decodes and composes the static adjacent migration chain once before returning validated current logical events. A read open uses that in-memory result without publishing a successor; a write open first encodes, verifies, and exclusively publishes the final version-named successor beside the unchanged source. Ordinary repair of an unsealed interrupted tail remains a handle consumer responsibility; migration inserts a missing interrupted `turn/end` only for the bounded released restart already sealed by a later `turn/start`. JSONL v0 uses `session.jsonl[.zstd]`, v1 and later use lowercase `session.vN.jsonl[.zstd]`, and committed generation paths are never renamed, replaced, or deleted. The JSONL provider owns physical framing, compression, generation selection, and exclusive publication, while each adjacent migration package owns exactly one `vN -> vN+1` step ([decision](../.agents/notes/implemented/architecture/2026-08-31-released-session-format-migrations.md)).
110
124
 
111
- **Model-visible means logged.** Anything that reaches a model request must be reconstructable from the log, and a runtime invariant asserts it. This is why a new model-visible input requires a new session event: extend `SessionEventMap` and render from the log.
125
+ **Model-visible means logged.** Anything that reaches a model request must be reconstructable from the log, and a runtime invariant asserts it. A new model-visible input requires a session event. Plugins that change existing message content register [pure message projections](subsystems/session.md#plugin-owned-message-projections); detached readers supply the same definitions explicitly.
112
126
 
113
127
  **Projection seam.** `dsh-session-projection` owns `ctx.sessionProjections`: registered units fold committed events incrementally, host consumers read one typed state with `stateOf()`, and carriers batch cropped client views with `snapshot()`. A host reader either requires this service during activation or fails explicitly when the registry or required key is absent. Contributors may retain `ctx.inject(['sessionProjections'], ...)` registration without silently defaulting a missing host value. The agent loop registers shared `turnBoundary` state for its readers ([decision](../.agents/notes/implemented/architecture/2026-08-19-session-projection-mandatory-seam.md)).
114
128
 
@@ -118,7 +132,7 @@ A **seam** is a swappable capability with three roles: a **Service Definition**
118
132
 
119
133
  Seams are why one provider swap changes the whole product. Filesystem and subprocess providers share one execution world, so pointing them at a remote sandbox moves Bash, PTY, and LSP with them, with no provider forks. [Subagent providers](subsystems/subagent.md) vary just as widely behind one interface, from a fresh child agent to a delegated turn in another product.
120
134
 
121
- [Experimental Agent Teams](subsystems/agent-team.md) is a private opt-in coordination seam on `ctx.agentTeams`, with a durable roster, task board, and mailbox layered over continuable subagents.
135
+ [Experimental Agent Teams](subsystems/agent-team.md) is a published opt-in coordination seam on `ctx.agentTeams`, with a durable roster, task board, and mailbox layered over continuable subagents.
122
136
 
123
137
  ## Where new behavior goes
124
138
 
@@ -22,11 +22,13 @@
22
22
 
23
23
  两者都在各自的 `package.json` 中通过 `dsh` 字段声明自己:`dsh.profile` 列出一个 profile 的组合包,`dsh.bundle` 指向一个组合包的 patch 文件。
24
24
 
25
- [`dsh-base`](../packages/bundle/base/README-zh.md) 是 `web`、`headless`、`sdk` 与 `acp` profile 的共享第一层:模型适配器、工具、持久化、沙箱与审批策略、设置、凭据、遥测。[`dsh-web-app`](../packages/bundle/web-app/README-zh.md) 增加浏览器应用,[`dsh-headless`](../packages/bundle/headless/README-zh.md) 增加不带服务器的一次性运行器,[`dsh-sdk-app`](../packages/bundle/sdk-app/README-zh.md) 增加 SDK JSON-RPC 服务器,[`dsh-acp-app`](../packages/bundle/acp-app/README-zh.md) 增加仅用于自动化的 ACP 服务器。[`dsh-sdk-minimal`](../packages/bundle/sdk-minimal/README-zh.md) 是刻意保留的例外:一个组合包拥有完整的显式 SDK 配置树,不应用 `dsh-base`。
25
+ [`dsh-base`](../packages/bundle/base/README.zh.md) 是 `web`、`headless`、`sdk` 与 `acp` profile 的共享第一层:模型适配器、工具、持久化、沙箱与审批策略、设置、凭据、遥测。[`dsh-web-app`](../packages/bundle/web-app/README.zh.md) 增加浏览器应用,[`dsh-headless`](../packages/bundle/headless/README.zh.md) 增加不带服务器的一次性运行器,[`dsh-sdk-app`](../packages/bundle/sdk-app/README.zh.md) 增加 SDK JSON-RPC 服务器,[`dsh-acp-app`](../packages/bundle/acp-app/README.zh.md) 增加仅用于自动化的 ACP 服务器。[`dsh-sdk-minimal`](../packages/bundle/sdk-minimal/README.zh.md) 是刻意保留的例外:一个组合包拥有完整的显式 SDK 配置树,不应用 `dsh-base`。
26
26
 
27
27
  各层按此顺序应用在空条目列表之上:先按 profile 列出的顺序应用每个组合包,然后是 profile 的 `cordis.patch.yml`,然后是 home 级的那份,最后是任意 `--patch` overlay。一条 patch 按 id 定位某个条目并替换其整个 config,或插入新条目。
28
28
 
29
- 自定义 profile 默认实时重载 patch。随附的 `web` profile 使用实时重载;`headless`、`sdk`、`sdk-minimal` `acp` 则只在启动时应用一次所有配置层,因为一次性应用或 stdio 应用拥有工作之后,替换其依赖会破坏该生命周期。
29
+ YAML 控制 HMR:base 启用仅监视配置的 `dsh-hmr`;Headless、SDK ACP 禁用它;`sdk-minimal` 不包含它。Profile patch 覆盖这些默认值。HMR 协调监听和重载;启动器提供 profile 数据和就绪信号。
30
+
31
+ base 提供用于 Web 和 Agent 的[插件管理器](../packages/boot/plugin-manager/README.zh.md)。
30
32
 
31
33
  要查看你的机器启动的配置树:
32
34
 
@@ -36,16 +38,22 @@ dsh --profile web --dump-config
36
38
 
37
39
  它打印出的任何条目,都可以由你自己的 patch 替换。
38
40
 
39
- 组装机制见 [app-boot](../packages/boot/app-boot/README-zh.md#profiles);配置字段见生成的[配置目录](config-catalog.zh.md)。
41
+ 组装机制见 [app-boot](../packages/boot/app-boot/README.zh.md#profiles);配置字段见生成的[配置目录](config-catalog.zh.md)。
40
42
 
41
43
  ## 应用启动
42
44
 
43
- 所有受支持的 Node 应用都从 `dsh` CLI 与具名 profile 启动。随附应用是 `dsh web`(刻意为 `--profile web` 保留的别名)、`dsh --profile headless`、`dsh --profile sdk`、`dsh --profile sdk-minimal` `dsh --profile acp`。TypeScript SDK 会解析其同版本 `dsh` 依赖并选择 `sdk`;自定义插件组合继续由 profile 与有序 patch 文件表达,而不是另一个可执行文件或内联应用树。`sdk-minimal` 是位于同一 launcher 后的仓库自有独立组合包,而不是由调用方提供的 Cordis 配置树。
45
+ 受支持的 Node 应用通过具名 `dsh` profile 启动。随附 profile `web`、`headless`、`sdk`、`sdk-minimal` `acp`,可通过 `dsh --profile <name>` `dsh <name>` 选择。`plugin` 表示管理命令;同名 profile 必须用 `--profile plugin` 选择。TypeScript SDK 会解析其同版本 `dsh` 依赖并选择 `sdk`;自定义插件组合继续由 profile 与有序 patch 文件表达,而不是另一个可执行文件或内联应用树。`sdk-minimal` 是位于同一 launcher 后的仓库自有独立组合包,而不是由调用方提供的 Cordis 配置树。
44
46
 
45
47
  Vendored CLI、仅用于构建和测试的可执行文件、进程内直接挂载插件以及私有浏览器 WebWorker 预览都不属于 Harness 应用启动器。[`verify-application-entrypoints`](../scripts/verify-application-entrypoints.ts)将每个包 bin、可执行源码与根 demo 归入显式类别,并拒绝任何绕过 `dsh` 的 Node 应用路径。
46
48
 
47
49
  Python SDK 遵循相同的应用架构。其运行时 wheel 把普通 `dsh` CLI 打包为 `deepseek-harness-sdk-runtime-<platform>-<arch>`,客户端默认以显式 Harness home 启动 `dsh --profile sdk`。极简示例选择随附的 `sdk-minimal` profile。Python 暴露 profile 选择与有序 patch 文件,而不是完整 Cordis 树;持久外部插件通过 `dsh plugin` 安装。已删除的私有直读配置载体没有兼容 bin 或回退 parser。
48
50
 
51
+ ## 桌面应用
52
+
53
+ [Electron 桌面应用](../apps/desktop/README.zh.md)在签名资源中携带精确匹配的 dsh 生产运行时,并拥有保留的 `$DSH_HOME/profiles/desktop`。共享 profile helper 初始化其文件、协调已安装 bundle,并解析安装与 bundle 的依赖而不替换 pnpm 拥有的包。CLI 与 Desktop 共享产品数据,可执行包、启用选择与锁文件保持独立。公开 CLI 不能管理 Desktop profile。
54
+
55
+ Electron 使用 Electron Node 模式启动私有 Desktop Host。Host 调用共享 CLI profile runner 与完整 Web 应用。窗口立即加载打包 Web 资源,等待启动注入后在同一文档中激活客户端插件。Web 负责 RPC 与流;桌面载体将本地页面连接到已认证的 Host。Node IPC 承载启动注入、就绪、致命错误与关闭。Desktop 默认端口为 `19387`,profile 配置可覆盖。壳拥有的 UI 通过内置 pnpm 执行插件事务,并遵循正常用户与 profile 配置。
56
+
49
57
  ## 核心包
50
58
 
51
59
  以下是向 Cordis 树贡献内容的部分核心包。
@@ -71,6 +79,8 @@ Python SDK 遵循相同的应用架构。其运行时 wheel 把普通 `dsh` CLI
71
79
  - **Agent 事件**(`agent/*`)携带活跃 `Agent`:inbox、步骤、状态、请求、验证、续跑。要观察或拦截进行中的工作时,使用它。
72
80
  - **能力事件**无需导入循环即可向某个 seam(`fs/*`、`tools/*`、`telemetry/*`)附加策略和适配器。
73
81
 
82
+ AgentLoop 在启动已排队工作前等待串行 `agent/created` 初始化。初始化失败会回滚创建;[agent-loop](../packages/core/agent-loop/README.zh.md#understand-the-implementation)定义 teardown 顺序。
83
+
74
84
  [事件映射](event-producer-consumer.zh.md)列出每个事件的生产方与消费方。
75
85
 
76
86
  <a id="turn-flow"></a>
@@ -82,13 +92,15 @@ Python SDK 遵循相同的应用架构。其运行时 wheel 把普通 `dsh` CLI
82
92
  ```text
83
93
  turn/start
84
94
  claim next-step input plus one queued message
85
- assemble prompt sections + tool schemas
95
+ assemble prompt sections + tool schemas; project runtime context
86
96
  -> agent/pre-step reject | enter(messages, startsRequestSeries?)
87
97
  reject, or a first enter rewritten empty -> close the turn with no step
88
98
  step/start
89
- append entered messages as user/message
90
- derive model history from the log
91
- agent/request -> llm/stream -> agent/assistant-stream start
99
+ agent/request -> prepareCall (cancellation commits neither system nor users)
100
+ reconcile system/message using the prepared call capability
101
+ append entered messages as user/message; log request/header and request/context as needed
102
+ derive and freeze model history from the log
103
+ stream the bound prepared call -> llm/stream -> agent/assistant-stream start
92
104
  agent/assistant-stream chunk*
93
105
  assistant/message | assistant/attempt -> agent/assistant-stream end
94
106
  tool/call* -> tools/pre-execute -> tools/execute -> tools/post-execute -> tool/result*
@@ -98,11 +110,13 @@ turn/start
98
110
  turn/end
99
111
  ```
100
112
 
101
- `turn/*`、`step/*`、`user/message`、`assistant/message`、`assistant/attempt` 和 `tool/*` 是持久会话事件;其余是分属三个事件域的实时扩展点。`agent/assistant-stream` 发布进程本地 start、瞬态 chunk 与 end frame。loop 会在 committed end frame 前把完整紧凑 stream 提交为一个 message 或仅日志 attempt;Web Session-follow adapter 是该 live event 唯一的远程消费方。`agent/pre-step`、`agent/request`、`llm/stream` 和三个 `tools/*` 事件是 waterfall(瀑布式事件),其监听器必须调用 `next()` 才能委托下去;`agent/turn-stopping` 是 serial 事件,没有 `next()`。
113
+ `turn/*`、`step/*`、`system/message`、`user/message`、`assistant/message`、`assistant/attempt` 和 `tool/*` 是持久会话事件;其余是分属三个事件域的实时扩展点。`agent/assistant-stream` 发布进程本地 start、瞬态 chunk 与 end frame。loop 会在 committed end frame 前把完整紧凑 stream 提交为一个 message 或仅日志 attempt;Web Session-follow adapter 是该 live event 唯一的远程消费方。`agent/pre-step`、`agent/request`、`llm/stream` 和三个 `tools/*` 事件是 waterfall(瀑布式事件),其监听器必须调用 `next()` 才能委托下去;`agent/turn-stopping` 是 serial 事件,没有 `next()`。
114
+
115
+ 输入通过同一个 inbox 到达驱动器;注入的上下文等待一条唤醒消息。AgentLoop 的持久 `inbox` 投影使待处理输入在没有活跃 Agent 时仍可读取。
102
116
 
103
- 输入通过同一个 inbox 到达驱动器。有些消息会立即唤醒它;注入的上下文会留在 inbox 中,直到另一条消息将其唤醒。
117
+ `agent/pre-step` 决定接纳的输入。监听器可以改写或拒绝已领取消息;首次领取被拒绝或为空时,关闭不含步骤的持久轮次。enter 决策可设置 `startsRequestSeries`:循环记录新的 `request/header`(原因为 `series`,或在封装同时变化时为携带 `startsSeries: true` 的 `change`)。包装监听器通过 `{ ...decision, messages }` 保留该声明。组装与 `step/start` 之后,`agent/request` 和 `prepareCall()` 先解析实际路由,再提交系统提示词与已接纳用户消息;在任一异步阶段取消都不会提交这两者。提示词准入依据已准备调用的能力,而非先前的 `request/context`。每次尝试同步协调同一份已渲染组装结果、仅在首次尝试追加用户消息、按需记录 header/context、派生并冻结请求,再通过绑定调用发起流式请求。重试不重复组装或 `agent/pre-step`。附接后的 surface 替换和图片省略决定开启新请求序列,包括恢复后的首次 pre-step 中发生的替换;未变化的恢复延续序列。首次接纳的步骤在用户消息之前预留系统头节点,即使提示词为空(不产生协议消息)。提示词仅通过 `system/message` 历史传递:空渲染文本清除所有生效的系统节点,模型不再看到旧提示词;具备能力的路由可在缓存前缀之后追加非空更新;不具备能力的路由与新请求序列将非空提示词文本归并到首个系统节点,并为非空的后续系统节点记录空内容替换([决策](../.agents/notes/implemented/architecture/2026-09-02-system-prompt-as-surface-node.zh.md);[决策规则](../packages/core/agent-loop/README.zh.md#understand-the-implementation))。
104
118
 
105
- `agent/pre-step` 决定模型看到什么。监听器可以改写已领取的消息,也可以直接拒绝它们;首次领取被拒绝或被改写为空时,仍会关闭一个不含步骤的持久轮次,因此日志会记录这次尝试。enter 决策还可以设置 `startsRequestSeries` 来开启独立的模型消息序列:loop 会随之记录一个新的 `request/header`(原因为 `series`,或在封装同时变化时为携带 `startsSeries: true` 的 `change`)。重建下游 enter 决策的监听器必须展开它(`{ ...decision, messages }`),该声明才能存活。每个步骤读取插件注册的提示词片段和工具 schema。
119
+ 循环发送不可变请求,同时保留实时取消能力。只有已由该循环完整冻结的消息对象身份才能复用冻结证明;[agent-loop](../packages/core/agent-loop/README.zh.md)拥有请求构造规则。
106
120
 
107
121
  详情见[时序图](agent-lifecycle.zh.md)、[工具流水线](tool-execution-pipeline.zh.md)和[取消与错误恢复](subsystems/core.zh.md#the-agent-handle)。
108
122
 
@@ -110,9 +124,9 @@ turn/end
110
124
 
111
125
  会话日志是模型所见上下文的来源。`deriveMessages()` 从中投影出模型历史。每个 `assistant/message` 都嵌入产生其组装内容的精确紧凑带时间 stream;`assistant/attempt` 保留已到达 settlement 的失败、重试、取消与 stream error attempt,且不添加模型历史。fork、恢复、transcript(文本记录)、遥测与持久化都从这些持久 settlement 派生,实时 UI 增量则来自 `agent/assistant-stream`;如果进程在 settlement 前硬中断,则不会留下持久 attempt stream(见[决策](../.agents/notes/implemented/architecture/2026-09-01-v2-embedded-assistant-streams.zh.md))。
112
126
 
113
- Session 消费方只了解当前逻辑格式。仅 header 的 `stat` 与 `list` 会重新扫描每个 Session 目录,选择数值最高的规范 generation,并在不加载事件或发布后继的情况下转换受支持的历史 header。已存储 Session 的 `open` 选择同一 generation,拒绝未来版本,或在内存中组合静态相邻迁移链、校验最终结果,并在返回句柄前以不覆盖方式只发布该版本命名的后继文件且保持源文件不变;语义层的中断轮次修复仍由句柄消费方负责。JSONL v0 使用 `session.jsonl[.zstd]`,v1 及后续版本使用小写 `session.vN.jsonl[.zstd]`;已提交 generation 路径绝不重命名、替换或删除。JSONL provider 负责物理 framing、压缩、generation 选择与排他发布,每个相邻迁移包只负责一个 `vN -> vN+1` 步骤([决策](../.agents/notes/implemented/architecture/2026-08-31-released-session-format-migrations.zh.md))。
127
+ Session 消费方只了解当前逻辑格式。仅 header 的 `stat` 与 `list` 会重新扫描每个 Session 目录,选择数值最高的规范 generation,并在不加载事件或发布后继的情况下转换受支持的历史 header。已存储 Session 的 `open` 选择同一 generation,拒绝未来版本,或只 Decode 并组合一次构建时静态确定的相邻迁移链,再返回经过校验的当前逻辑事件。只读 open 直接使用这份内存结果,不发布后继;写 open 则先编码、校验并在未改变源的旁边排他发布最终版本命名的后继。未被后续事件封住的普通中断尾部仍由句柄消费方修复;只有在后续 `turn/start` 已经封住一种有限的已发布 restart 时,migration 才会插入缺失的 interrupted `turn/end`。JSONL v0 使用 `session.jsonl[.zstd]`,v1 及后续版本使用小写 `session.vN.jsonl[.zstd]`;已提交 generation 路径绝不重命名、替换或删除。JSONL provider 负责物理 framing、压缩、generation 选择与排他发布,每个相邻迁移包只负责一个 `vN -> vN+1` 步骤([决策](../.agents/notes/implemented/architecture/2026-08-31-released-session-format-migrations.zh.md))。
114
128
 
115
- **模型可见即已记录。** 抵达模型请求的一切都必须能从日志重建,并由一项运行时不变量断言这一点。因此,新增一项模型可见输入就需要新增一个会话事件:扩展 `SessionEventMap` 并从日志渲染。
129
+ **模型可见即已记录。** 抵达模型请求的一切都必须能从日志重建,并由一项运行时不变量断言这一点。新增模型可见输入需要一个会话事件。修改现有消息内容的插件注册[纯消息投影](subsystems/session.zh.md#plugin-owned-message-projections),独立读取器显式传入相同的处理器。
116
130
 
117
131
  **投影 seam。** `dsh-session-projection` 提供 `ctx.sessionProjections`:已注册单元增量折叠已提交事件,host 消费方通过 `stateOf()` 读取单个类型化状态,载体通过 `snapshot()` 批量取得裁剪后的客户端视图。host 读取方要么在激活时要求该服务,要么在注册表或必需 key 缺席时明确失败。贡献方可以保留 `ctx.inject(['sessionProjections'], ...)` 注册,但不能为缺失的 host 值静默提供默认值。agent loop 为读取方注册共享的 `turnBoundary` 状态([决策](../.agents/notes/implemented/architecture/2026-08-19-session-projection-mandatory-seam.zh.md))。
118
132
 
@@ -122,7 +136,7 @@ Session 消费方只了解当前逻辑格式。仅 header 的 `stat` 与 `list`
122
136
 
123
137
  seam 正是替换一个提供方就能改变整个产品的原因。文件系统与进程提供方共享同一个执行世界,因此把它们指向远程沙箱,也就把 Bash、PTY 和 LSP 一并搬了过去,无需提供方专用 fork。[subagent 提供方](subsystems/subagent.zh.md)在同一个接口之后同样千差万别,从新建一个子 agent,到把一个轮次委派给另一个产品。
124
138
 
125
- [实验性 Agent Teams](subsystems/agent-team.zh.md) 是 `ctx.agentTeams` 上的私有显式启用协作 seam,在可继续 subagent 之上提供持久 roster、任务板和 mailbox。
139
+ [实验性 Agent Teams](subsystems/agent-team.zh.md) 是 `ctx.agentTeams` 上公开发布、显式启用的协作 seam,在可继续 subagent 之上提供持久 roster、任务板和 mailbox。
126
140
 
127
141
  ## 新行为的归属位置
128
142
 
@@ -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 docs/capability-seams.md
5
- capability-seams.md: ecc88e397f41c4d279effa2df9d1b29108756ea5
6
- capability-seams.zh.md: 105752ac01007d24788bcfbcb2eb22c07cfdd0f5
5
+ capability-seams.md: edb8cd688768ec49ee3699c3775409a66975129d
6
+ capability-seams.zh.md: b06d9378616669407b79ffa1da205924ff6ad757