dsh-plugin-dev-kb 1.3.0 → 1.4.0

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 (364) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/README.en.md +4 -4
  3. package/README.md +5 -5
  4. package/kb/INDEX.md +18 -18
  5. package/kb/README.md +6 -4
  6. package/kb/extra/AGENTS.md +11 -10
  7. package/kb/extra/cookbook/adding-a-remote-api.md +2 -2
  8. package/kb/extra/cookbook/adding-a-remote-api.zh.md +2 -2
  9. package/kb/extra/cookbook/adding-a-session-format-version.md +48 -6
  10. package/kb/extra/cookbook/adding-a-session-format-version.zh.md +48 -6
  11. package/kb/extra/cookbook/reviewing-persistence-type-changes.md +120 -0
  12. package/kb/extra/cookbook/reviewing-persistence-type-changes.zh.md +120 -0
  13. package/kb/extra/deepseek-llm-api-wire-extensions.md +18 -19
  14. package/kb/extra/deepseek-llm-api-wire-extensions.zh.md +17 -18
  15. package/kb/extra/development.md +27 -10
  16. package/kb/extra/development.zh.md +27 -10
  17. package/kb/extra/event-producer-consumer.md +89 -68
  18. package/kb/extra/event-producer-consumer.zh.md +90 -69
  19. package/kb/extra/glossary.md +1 -1
  20. package/kb/extra/glossary.zh.md +1 -1
  21. package/kb/extra/i18n/README.md +15 -7
  22. package/kb/extra/i18n/README.zh.md +15 -7
  23. package/kb/extra/i18n/terminology.md +4 -4
  24. package/kb/extra/i18n/translation-prompt.md +2 -2
  25. package/kb/extra/module-graph.md +574 -326
  26. package/kb/extra/module-graph.zh.md +574 -326
  27. package/kb/extra/persistence-changes/2026-09-11-initial.md +280 -0
  28. package/kb/extra/persistence-changes/2026-09-11-initial.zh.md +280 -0
  29. package/kb/extra/persistence-changes/2026-09-12-auto-review-error-metadata.md +52 -0
  30. package/kb/extra/persistence-changes/2026-09-12-auto-review-error-metadata.zh.md +52 -0
  31. package/kb/extra/persistence-changes/2026-09-14-image-offload.md +96 -0
  32. package/kb/extra/persistence-changes/2026-09-14-image-offload.zh.md +96 -0
  33. package/kb/extra/persistence-changes/2026-09-14-workspace-changes-event.md +48 -0
  34. package/kb/extra/persistence-changes/2026-09-14-workspace-changes-event.zh.md +48 -0
  35. package/kb/extra/persistence-changes/2026-09-16-session-format-v4.md +120 -0
  36. package/kb/extra/persistence-changes/2026-09-16-session-format-v4.zh.md +120 -0
  37. package/kb/extra/persistence-changes/2026-09-18-schedule-optional-title.md +48 -0
  38. package/kb/extra/persistence-changes/2026-09-18-schedule-optional-title.zh.md +48 -0
  39. package/kb/extra/persistence-changes/2026-09-20-unknown-child-catalog.md +48 -0
  40. package/kb/extra/persistence-changes/2026-09-20-unknown-child-catalog.zh.md +48 -0
  41. package/kb/extra/persistence-changes/2026-09-21-user-question-reply.md +60 -0
  42. package/kb/extra/persistence-changes/2026-09-21-user-question-reply.zh.md +60 -0
  43. package/kb/extra/persistence-changes/README.md +88 -0
  44. package/kb/extra/persistence-changes/README.zh.md +88 -0
  45. package/kb/extra/persistence-changes/historical-formats/README.md +75 -0
  46. package/kb/extra/persistence-changes/historical-formats/README.zh.md +75 -0
  47. package/kb/extra/persistence-changes/historical-formats/v0.md +5105 -0
  48. package/kb/extra/persistence-changes/historical-formats/v0.zh.md +5105 -0
  49. package/kb/extra/persistence-changes/historical-formats/v1.md +5107 -0
  50. package/kb/extra/persistence-changes/historical-formats/v1.zh.md +5107 -0
  51. package/kb/extra/persistence-changes/historical-formats/v2.md +5362 -0
  52. package/kb/extra/persistence-changes/historical-formats/v2.zh.md +5362 -0
  53. package/kb/extra/persistence-changes/historical-formats/v3.md +5634 -0
  54. package/kb/extra/persistence-changes/historical-formats/v3.zh.md +5634 -0
  55. package/kb/extra/persistence-changes/releases/README.md +103 -0
  56. package/kb/extra/persistence-changes/releases/README.zh.md +103 -0
  57. package/kb/extra/persistence-changes/releases/dsh-v0.0.1-rc.1.md +201 -0
  58. package/kb/extra/persistence-changes/releases/dsh-v0.0.1-rc.1.zh.md +201 -0
  59. package/kb/extra/persistence-changes/releases/dsh-v0.0.1-rc.2.md +261 -0
  60. package/kb/extra/persistence-changes/releases/dsh-v0.0.1-rc.2.zh.md +261 -0
  61. package/kb/extra/persistence-changes/releases/dsh-v0.0.1-rc.3.md +126 -0
  62. package/kb/extra/persistence-changes/releases/dsh-v0.0.1-rc.3.zh.md +126 -0
  63. package/kb/extra/persistence-changes/releases/dsh-v0.0.1-rc.4.md +75 -0
  64. package/kb/extra/persistence-changes/releases/dsh-v0.0.1-rc.4.zh.md +75 -0
  65. package/kb/extra/persistence-changes/releases/dsh-v0.0.1-rc.5.md +75 -0
  66. package/kb/extra/persistence-changes/releases/dsh-v0.0.1-rc.5.zh.md +75 -0
  67. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.1.md +75 -0
  68. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.1.zh.md +75 -0
  69. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.2.md +75 -0
  70. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.2.zh.md +75 -0
  71. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.3.md +75 -0
  72. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.3.zh.md +75 -0
  73. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.5.md +75 -0
  74. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.5.zh.md +75 -0
  75. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.6.md +75 -0
  76. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.6.zh.md +75 -0
  77. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.7.md +82 -0
  78. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.7.zh.md +82 -0
  79. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.8.md +110 -0
  80. package/kb/extra/persistence-changes/releases/dsh-v0.1.0-rc.8.zh.md +110 -0
  81. package/kb/extra/persistence-changes/releases/dsh-v0.1.1-rc.1.md +82 -0
  82. package/kb/extra/persistence-changes/releases/dsh-v0.1.1-rc.1.zh.md +82 -0
  83. package/kb/extra/persistence-changes/releases/dsh-v0.1.1-rc.2.md +119 -0
  84. package/kb/extra/persistence-changes/releases/dsh-v0.1.1-rc.2.zh.md +119 -0
  85. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-alpha.1.md +295 -0
  86. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-alpha.1.zh.md +295 -0
  87. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-alpha.2.md +286 -0
  88. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-alpha.2.zh.md +286 -0
  89. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-alpha.3.md +75 -0
  90. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-alpha.3.zh.md +75 -0
  91. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-alpha.4.md +95 -0
  92. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-alpha.4.zh.md +95 -0
  93. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-alpha.5.md +75 -0
  94. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-alpha.5.zh.md +75 -0
  95. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-rc.1.md +75 -0
  96. package/kb/extra/persistence-changes/releases/dsh-v0.1.2-rc.1.zh.md +75 -0
  97. package/kb/extra/persistence-changes/releases/dsh-v0.1.3-alpha.1.md +154 -0
  98. package/kb/extra/persistence-changes/releases/dsh-v0.1.3-alpha.1.zh.md +154 -0
  99. package/kb/extra/persistence-changes/releases/dsh-v0.1.3-alpha.2.md +86 -0
  100. package/kb/extra/persistence-changes/releases/dsh-v0.1.3-alpha.2.zh.md +86 -0
  101. package/kb/extra/persistence-changes/releases/dsh-v0.1.5-alpha.1.md +139 -0
  102. package/kb/extra/persistence-changes/releases/dsh-v0.1.5-alpha.1.zh.md +139 -0
  103. package/kb/extra/persistence-changes/releases/dsh-v0.1.5-alpha.2.md +95 -0
  104. package/kb/extra/persistence-changes/releases/dsh-v0.1.5-alpha.2.zh.md +95 -0
  105. package/kb/extra/persistence-changes/releases/dsh-v0.1.5-rc.1.md +75 -0
  106. package/kb/extra/persistence-changes/releases/dsh-v0.1.5-rc.1.zh.md +75 -0
  107. package/kb/extra/persistence-changes/releases/dsh-v0.1.5-rc.2.md +75 -0
  108. package/kb/extra/persistence-changes/releases/dsh-v0.1.5-rc.2.zh.md +75 -0
  109. package/kb/extra/rescope.md +1 -1
  110. package/kb/extra/rescope.zh.md +1 -1
  111. package/kb/extra/session-format-status.md +22 -6
  112. package/kb/extra/session-format-status.zh.md +22 -6
  113. package/kb/extra/subsystems/agent-team.md +52 -28
  114. package/kb/extra/subsystems/agent-team.zh.md +52 -28
  115. package/kb/extra/subsystems/attachment.md +19 -9
  116. package/kb/extra/subsystems/attachment.zh.md +19 -9
  117. package/kb/extra/subsystems/boot.md +323 -0
  118. package/kb/extra/subsystems/boot.zh.md +323 -0
  119. package/kb/extra/subsystems/browser-use.md +67 -0
  120. package/kb/extra/subsystems/browser-use.zh.md +67 -0
  121. package/kb/extra/subsystems/claude-code-mods.md +146 -0
  122. package/kb/extra/subsystems/claude-code-mods.zh.md +146 -0
  123. package/kb/extra/subsystems/computer-use.md +56 -0
  124. package/kb/extra/subsystems/computer-use.zh.md +56 -0
  125. package/kb/extra/subsystems/deliverables.md +178 -0
  126. package/kb/extra/subsystems/deliverables.zh.md +178 -0
  127. package/kb/extra/subsystems/extensions.md +6 -4
  128. package/kb/extra/subsystems/extensions.zh.md +6 -4
  129. package/kb/extra/subsystems/feedback.md +4 -4
  130. package/kb/extra/subsystems/feedback.zh.md +4 -4
  131. package/kb/extra/subsystems/mcp.md +139 -0
  132. package/kb/extra/subsystems/mcp.zh.md +139 -0
  133. package/kb/extra/subsystems/office-to-pdf.md +87 -0
  134. package/kb/extra/subsystems/office-to-pdf.zh.md +87 -0
  135. package/kb/extra/subsystems/otel.md +44 -0
  136. package/kb/extra/subsystems/otel.zh.md +44 -0
  137. package/kb/extra/subsystems/product-telemetry.md +79 -0
  138. package/kb/extra/subsystems/product-telemetry.zh.md +79 -0
  139. package/kb/extra/subsystems/ssh.md +135 -0
  140. package/kb/extra/subsystems/ssh.zh.md +135 -0
  141. package/kb/extra/subsystems/todo.md +3 -3
  142. package/kb/extra/subsystems/todo.zh.md +3 -3
  143. package/kb/extra/subsystems/voice-input.md +164 -0
  144. package/kb/extra/subsystems/voice-input.zh.md +164 -0
  145. package/kb/extra/subsystems/webhook.md +3 -3
  146. package/kb/extra/subsystems/webhook.zh.md +1 -1
  147. package/kb/extra/testing.md +3 -3
  148. package/kb/extra/testing.zh.md +3 -3
  149. package/kb/extra/ui-radius.md +115 -0
  150. package/kb/extra/ui-radius.zh.md +115 -0
  151. package/kb/extra/upgrade-guide/v0.1.7-rc.2/schedule-optional-bundle/guide.md +22 -0
  152. package/kb/extra/upgrade-guide/v0.1.7-rc.2/schedule-optional-bundle/guide.zh.md +22 -0
  153. package/kb/extra/upgrade-guide/v0.1.7-rc.2/transcript-view-legacy-normal/guide.md +25 -0
  154. package/kb/extra/upgrade-guide/v0.1.7-rc.2/transcript-view-legacy-normal/guide.zh.md +25 -0
  155. package/kb/extra/upgrade-guide/v0.2.0-rc.2/account-sign-in-errors/guide.md +18 -0
  156. package/kb/extra/upgrade-guide/v0.2.0-rc.2/account-sign-in-errors/guide.zh.md +18 -0
  157. package/kb/extra/upgrade-guide/v0.2.0-rc.2/remove-runtime-invariants/guide.md +23 -0
  158. package/kb/extra/upgrade-guide/v0.2.0-rc.2/remove-runtime-invariants/guide.zh.md +23 -0
  159. package/kb/extra/upgrade-guide/v0.2.0-rc.2/schedule-bundle-retired/guide.md +22 -0
  160. package/kb/extra/upgrade-guide/v0.2.0-rc.2/schedule-bundle-retired/guide.zh.md +22 -0
  161. package/kb/extra/upgrade-guide/v0.2.0-rc.2/subpath-plugin-display-manifest/guide.md +27 -0
  162. package/kb/extra/upgrade-guide/v0.2.0-rc.2/subpath-plugin-display-manifest/guide.zh.md +27 -0
  163. package/kb/extra/web-styling.md +12 -3
  164. package/kb/extra/web-styling.zh.md +12 -3
  165. package/kb/meta/search-index.json +976 -256
  166. package/kb/meta/site-pages.txt +188 -188
  167. package/kb/meta/source.json +6 -6
  168. package/kb/meta/topics.md +10 -6
  169. package/kb/site/develop/basic/config.md +1 -0
  170. package/kb/site/develop/basic/index.md +1 -0
  171. package/kb/site/develop/basic/publish.md +9 -2
  172. package/kb/site/develop/basic/tool.md +1 -0
  173. package/kb/site/develop/cordis-tutorial/01-first-plugin.md +1 -0
  174. package/kb/site/develop/cordis-tutorial/02-lifecycle-and-effects.md +1 -0
  175. package/kb/site/develop/cordis-tutorial/03-services.md +1 -0
  176. package/kb/site/develop/cordis-tutorial/04-events.md +1 -0
  177. package/kb/site/develop/cordis-tutorial/05-config.md +28 -0
  178. package/kb/site/develop/cordis-tutorial/06-composition-and-hmr.md +3 -2
  179. package/kb/site/develop/cordis-tutorial/07-into-the-harness.md +1 -0
  180. package/kb/site/develop/cordis-tutorial/index.md +1 -0
  181. package/kb/site/develop/framework/events.md +1 -0
  182. package/kb/site/develop/framework/index.md +2 -1
  183. package/kb/site/develop/framework/service.md +1 -0
  184. package/kb/site/develop/practice/dynamic-cordis.md +9 -8
  185. package/kb/site/develop/practice/index.md +1 -0
  186. package/kb/site/develop/practice/llm-adapter.md +2 -1
  187. package/kb/site/en/develop/basic/config.md +1 -0
  188. package/kb/site/en/develop/basic/index.md +1 -0
  189. package/kb/site/en/develop/basic/publish.md +9 -2
  190. package/kb/site/en/develop/basic/tool.md +1 -0
  191. package/kb/site/en/develop/cordis-tutorial/01-first-plugin.md +1 -0
  192. package/kb/site/en/develop/cordis-tutorial/02-lifecycle-and-effects.md +1 -0
  193. package/kb/site/en/develop/cordis-tutorial/03-services.md +1 -0
  194. package/kb/site/en/develop/cordis-tutorial/04-events.md +1 -0
  195. package/kb/site/en/develop/cordis-tutorial/05-config.md +28 -0
  196. package/kb/site/en/develop/cordis-tutorial/06-composition-and-hmr.md +3 -2
  197. package/kb/site/en/develop/cordis-tutorial/07-into-the-harness.md +1 -0
  198. package/kb/site/en/develop/cordis-tutorial/index.md +1 -0
  199. package/kb/site/en/develop/framework/events.md +1 -0
  200. package/kb/site/en/develop/framework/index.md +2 -1
  201. package/kb/site/en/develop/framework/service.md +1 -0
  202. package/kb/site/en/develop/practice/dynamic-cordis.md +9 -8
  203. package/kb/site/en/develop/practice/index.md +1 -0
  204. package/kb/site/en/develop/practice/llm-adapter.md +2 -1
  205. package/kb/site/en/guide/github-review.md +1 -0
  206. package/kb/site/en/guide/mcp-memory.md +1 -0
  207. package/kb/site/en/guide/network-proxy.md +2 -1
  208. package/kb/site/en/guide/providers-custom-form.png +0 -0
  209. package/kb/site/en/guide/providers-models-page.png +0 -0
  210. package/kb/site/en/guide/providers.md +97 -82
  211. package/kb/site/en/guide/public-deployments.md +36 -0
  212. package/kb/site/en/guide/python-sdk.md +42 -21
  213. package/kb/site/en/guide/quickstart.md +2 -0
  214. package/kb/site/en/guide/schedule.md +70 -11
  215. package/kb/site/en/reference/agent-lifecycle.md +1 -0
  216. package/kb/site/en/reference/api-gateway.md +13 -11
  217. package/kb/site/en/reference/capability-seams.md +177 -59
  218. package/kb/site/en/reference/config-catalog.md +1758 -821
  219. package/kb/site/en/reference/cookbook/adding-a-package.md +57 -3
  220. package/kb/site/en/reference/cookbook/adding-a-settings-card.md +35 -64
  221. package/kb/site/en/reference/cookbook/adding-a-tool.md +4 -3
  222. package/kb/site/en/reference/cookbook/adding-an-llm-adapter.md +1 -0
  223. package/kb/site/en/reference/cookbook/extension-cookbook.md +6 -5
  224. package/kb/site/en/reference/cordis-api/context.md +1 -0
  225. package/kb/site/en/reference/cordis-api/events.md +1 -0
  226. package/kb/site/en/reference/cordis-api/fiber.md +4 -3
  227. package/kb/site/en/reference/cordis-api/inherited.md +16 -16
  228. package/kb/site/en/reference/cordis-api/registry.md +1 -0
  229. package/kb/site/en/reference/cordis-api/service.md +1 -0
  230. package/kb/site/en/reference/cordis-primer.md +1 -0
  231. package/kb/site/en/reference/index.md +18 -11
  232. package/kb/site/en/reference/persistence-catalog.md +7687 -54
  233. package/kb/site/en/reference/subsystems/approval.md +2 -1
  234. package/kb/site/en/reference/subsystems/client-modules.md +23 -15
  235. package/kb/site/en/reference/subsystems/client-resources.md +3 -1
  236. package/kb/site/en/reference/subsystems/commands.md +6 -1
  237. package/kb/site/en/reference/subsystems/compaction.md +50 -3
  238. package/kb/site/en/reference/subsystems/conversation.md +36 -6
  239. package/kb/site/en/reference/subsystems/core.md +97 -257
  240. package/kb/site/en/reference/subsystems/credentials.md +169 -5
  241. package/kb/site/en/reference/subsystems/filesystem.md +11 -0
  242. package/kb/site/en/reference/subsystems/goal.md +2 -1
  243. package/kb/site/en/reference/subsystems/index.md +16 -5
  244. package/kb/site/en/reference/subsystems/jobs.md +337 -127
  245. package/kb/site/en/reference/subsystems/llm-streaming.md +76 -36
  246. package/kb/site/en/reference/subsystems/lsp.md +1 -0
  247. package/kb/site/en/reference/subsystems/permission-presets.md +66 -29
  248. package/kb/site/en/reference/subsystems/persistence.md +4 -3
  249. package/kb/site/en/reference/subsystems/plan.md +2 -1
  250. package/kb/site/en/reference/subsystems/ptc-runtime.md +236 -0
  251. package/kb/site/en/reference/subsystems/sandbox.md +7 -5
  252. package/kb/site/en/reference/subsystems/schedule.md +392 -33
  253. package/kb/site/en/reference/subsystems/scope.md +2 -1
  254. package/kb/site/en/reference/subsystems/session-projection.md +22 -19
  255. package/kb/site/en/reference/subsystems/session-query.md +1 -0
  256. package/kb/site/en/reference/subsystems/session-reference.md +8 -6
  257. package/kb/site/en/reference/subsystems/session-telemetry.md +7 -4
  258. package/kb/site/en/reference/subsystems/session-title.md +6 -5
  259. package/kb/site/en/reference/subsystems/session.md +199 -81
  260. package/kb/site/en/reference/subsystems/settings.md +43 -292
  261. package/kb/site/en/reference/subsystems/shell.md +37 -28
  262. package/kb/site/en/reference/subsystems/sidebar-right.md +23 -12
  263. package/kb/site/en/reference/subsystems/skills.md +5 -6
  264. package/kb/site/en/reference/subsystems/slots.md +34 -13
  265. package/kb/site/en/reference/subsystems/spill.md +4 -3
  266. package/kb/site/en/reference/subsystems/storage.md +2 -2
  267. package/kb/site/en/reference/subsystems/subagent.md +50 -64
  268. package/kb/site/en/reference/subsystems/subprocess.md +17 -18
  269. package/kb/site/en/reference/subsystems/system-prompt.md +4 -1
  270. package/kb/site/en/reference/subsystems/terminal.md +1 -0
  271. package/kb/site/en/reference/subsystems/token-meter.md +1 -0
  272. package/kb/site/en/reference/subsystems/tools.md +40 -12
  273. package/kb/site/en/reference/subsystems/typert.md +153 -10
  274. package/kb/site/en/reference/subsystems/user-questions.md +131 -1
  275. package/kb/site/en/reference/subsystems/web-client.md +15 -9
  276. package/kb/site/en/reference/subsystems/web-server.md +74 -1
  277. package/kb/site/en/reference/subsystems/web.md +1 -0
  278. package/kb/site/en/reference/subsystems/workflow.md +10 -9
  279. package/kb/site/en/reference/subsystems/workspace.md +294 -34
  280. package/kb/site/en/reference/tool-catalog.md +782 -331
  281. package/kb/site/en/reference/tool-execution-pipeline.md +7 -3
  282. package/kb/site/guide/github-review.md +1 -0
  283. package/kb/site/guide/mcp-memory.md +1 -0
  284. package/kb/site/guide/network-proxy.md +2 -1
  285. package/kb/site/guide/providers-custom-form.zh.png +0 -0
  286. package/kb/site/guide/providers-models-page.zh.png +0 -0
  287. package/kb/site/guide/providers.md +109 -94
  288. package/kb/site/guide/public-deployments.md +36 -0
  289. package/kb/site/guide/python-sdk.md +42 -21
  290. package/kb/site/guide/quickstart.md +2 -0
  291. package/kb/site/guide/schedule.md +70 -11
  292. package/kb/site/reference/agent-lifecycle.md +1 -0
  293. package/kb/site/reference/api-gateway.md +13 -11
  294. package/kb/site/reference/capability-seams.md +177 -59
  295. package/kb/site/reference/config-catalog.md +1760 -822
  296. package/kb/site/reference/cookbook/adding-a-package.md +55 -3
  297. package/kb/site/reference/cookbook/adding-a-settings-card.md +35 -64
  298. package/kb/site/reference/cookbook/adding-a-tool.md +4 -3
  299. package/kb/site/reference/cookbook/adding-an-llm-adapter.md +1 -0
  300. package/kb/site/reference/cookbook/extension-cookbook.md +6 -5
  301. package/kb/site/reference/cordis-api/context.md +1 -0
  302. package/kb/site/reference/cordis-api/events.md +1 -0
  303. package/kb/site/reference/cordis-api/fiber.md +4 -3
  304. package/kb/site/reference/cordis-api/inherited.md +16 -16
  305. package/kb/site/reference/cordis-api/registry.md +1 -0
  306. package/kb/site/reference/cordis-api/service.md +1 -0
  307. package/kb/site/reference/cordis-primer.md +1 -0
  308. package/kb/site/reference/index.md +18 -11
  309. package/kb/site/reference/persistence-catalog.md +7693 -60
  310. package/kb/site/reference/subsystems/approval.md +2 -1
  311. package/kb/site/reference/subsystems/client-modules.md +23 -15
  312. package/kb/site/reference/subsystems/client-resources.md +3 -1
  313. package/kb/site/reference/subsystems/commands.md +6 -1
  314. package/kb/site/reference/subsystems/compaction.md +50 -3
  315. package/kb/site/reference/subsystems/conversation.md +35 -5
  316. package/kb/site/reference/subsystems/core.md +97 -257
  317. package/kb/site/reference/subsystems/credentials.md +169 -5
  318. package/kb/site/reference/subsystems/filesystem.md +11 -0
  319. package/kb/site/reference/subsystems/goal.md +2 -1
  320. package/kb/site/reference/subsystems/index.md +16 -5
  321. package/kb/site/reference/subsystems/jobs.md +336 -126
  322. package/kb/site/reference/subsystems/llm-streaming.md +76 -36
  323. package/kb/site/reference/subsystems/lsp.md +1 -0
  324. package/kb/site/reference/subsystems/permission-presets.md +66 -29
  325. package/kb/site/reference/subsystems/persistence.md +4 -3
  326. package/kb/site/reference/subsystems/plan.md +2 -1
  327. package/kb/site/reference/subsystems/ptc-runtime.md +236 -0
  328. package/kb/site/reference/subsystems/sandbox.md +7 -5
  329. package/kb/site/reference/subsystems/schedule.md +392 -33
  330. package/kb/site/reference/subsystems/scope.md +2 -1
  331. package/kb/site/reference/subsystems/session-projection.md +22 -19
  332. package/kb/site/reference/subsystems/session-query.md +1 -0
  333. package/kb/site/reference/subsystems/session-reference.md +8 -6
  334. package/kb/site/reference/subsystems/session-telemetry.md +7 -4
  335. package/kb/site/reference/subsystems/session-title.md +6 -5
  336. package/kb/site/reference/subsystems/session.md +199 -81
  337. package/kb/site/reference/subsystems/settings.md +43 -292
  338. package/kb/site/reference/subsystems/shell.md +37 -28
  339. package/kb/site/reference/subsystems/sidebar-right.md +23 -12
  340. package/kb/site/reference/subsystems/skills.md +5 -6
  341. package/kb/site/reference/subsystems/slots.md +34 -13
  342. package/kb/site/reference/subsystems/spill.md +3 -2
  343. package/kb/site/reference/subsystems/storage.md +2 -2
  344. package/kb/site/reference/subsystems/subagent.md +49 -63
  345. package/kb/site/reference/subsystems/subprocess.md +17 -18
  346. package/kb/site/reference/subsystems/system-prompt.md +4 -1
  347. package/kb/site/reference/subsystems/terminal.md +1 -0
  348. package/kb/site/reference/subsystems/token-meter.md +1 -0
  349. package/kb/site/reference/subsystems/tools.md +40 -12
  350. package/kb/site/reference/subsystems/typert.md +153 -10
  351. package/kb/site/reference/subsystems/user-questions.md +132 -2
  352. package/kb/site/reference/subsystems/web-client.md +15 -9
  353. package/kb/site/reference/subsystems/web-server.md +74 -1
  354. package/kb/site/reference/subsystems/web.md +1 -0
  355. package/kb/site/reference/subsystems/workflow.md +10 -9
  356. package/kb/site/reference/subsystems/workspace.md +294 -34
  357. package/kb/site/reference/tool-catalog.md +784 -333
  358. package/kb/site/reference/tool-execution-pipeline.md +7 -3
  359. package/package.json +2 -2
  360. package/skills/dsh-plugin-dev-kb.md +5 -4
  361. package/kb/site/en/reference/subsystems/code-runtime.md +0 -198
  362. package/kb/site/en/reference/subsystems/invariants.md +0 -91
  363. package/kb/site/reference/subsystems/code-runtime.md +0 -198
  364. package/kb/site/reference/subsystems/invariants.md +0 -91
@@ -0,0 +1,178 @@
1
+ # Deliverables
2
+
3
+ English | [中文](deliverables.zh.md)
4
+
5
+ What a turn hands to the user, owned by the [deliverables package group](../../packages/deliverables/README.md): the files the model declared through the `present` tool, recorded in a log-only Session event, and the files the turn changed, summarized from git working-tree snapshots taken at turn start and turn end plus whole-file captures around each file-tool edit for the paths git does not cover, announced by a log-only event and served by a Host service while the Session lives together with each listed file's turn-start and turn-end comparison. Only clients read them; the Web [deliverables plugin](../../packages/client/ui-deliverables/README.md) renders both at the end of the turn. Tool behavior, snapshot mechanics, and configuration are on the package READMEs for [`tool-present`](../../packages/deliverables/tool-present/README.md) and [`workspace-changes`](../../packages/deliverables/workspace-changes/README.md).
6
+
7
+ Sources: [`packages/deliverables/tool-present/src/types.ts`](../../packages/deliverables/tool-present/src/types.ts), [`packages/deliverables/workspace-changes/src/types.ts`](../../packages/deliverables/workspace-changes/src/types.ts)
8
+
9
+ ## `PresentedFile` — one declared delivery
10
+
11
+ ```ts type-equiv
12
+ /** A declared filesystem file whose current contents remain at its source path. */
13
+ interface PresentedFile {
14
+ /** Original absolute path or path relative to the Session working directory. */
15
+ path: string
16
+ /** Optional description supplied by the model. */
17
+ description?: string
18
+ }
19
+ ```
20
+
21
+ ## `WorkspaceChangedFile` — one changed file
22
+
23
+ ```ts type-equiv
24
+ /** One file changed during a turn, with line counts from git or from the whole-file captures around its file-tool edits. */
25
+ interface WorkspaceChangedFile {
26
+ /** Path relative to the Session working directory, or an absolute Host path outside it. */
27
+ path: string
28
+ /**
29
+ * Sort key and label: the relative path inside the working directory, a
30
+ * `../` path for repository files above it, a `~` path under the home
31
+ * directory, otherwise the absolute path. Always slash-separated.
32
+ */
33
+ display: string
34
+ /** Lines added; zero for a binary or oversized file. */
35
+ added: number
36
+ /** Lines deleted; zero for a binary or oversized file. */
37
+ deleted: number
38
+ /** Present when git reported the file as binary, or when a captured side holds a NUL byte. */
39
+ binary?: true
40
+ /** Present when a captured side exceeded the plugin's `maxFileBytes`; the file is listed without counts or comparison. */
41
+ oversized?: true
42
+ }
43
+ ```
44
+
45
+ ## `WorkspaceChangesSummary` — one turn's change summary
46
+
47
+ ```ts type-equiv
48
+ /** Files changed during one top-level turn, kept on the Host until its Session is disposed. */
49
+ interface WorkspaceChangesSummary {
50
+ /** The turn whose file changes this summary describes. */
51
+ turn: number
52
+ /** The Session working directory `path` values are relative to. */
53
+ cwd: string
54
+ /** Changed files in `display` order, capped at the plugin's `maxFiles`. */
55
+ files: WorkspaceChangedFile[]
56
+ /** Complete changed-file count, including files omitted by the cap. */
57
+ total: number
58
+ /** Lines added over every changed file, including files omitted by the cap. */
59
+ added: number
60
+ /** Lines deleted over every changed file, including files omitted by the cap. */
61
+ deleted: number
62
+ /** Git tree ids of the turn-start and turn-end snapshots; absent when no snapshot was taken. */
63
+ snapshot?: { before: string; after: string }
64
+ }
65
+ ```
66
+
67
+ ## `WorkspaceDiffHunk` — one unified-diff hunk
68
+
69
+ ```ts type-equiv
70
+ /** One unified-diff hunk with three context lines; every line keeps its `+`, `-`, or space prefix. */
71
+ interface WorkspaceDiffHunk {
72
+ /** First line of the hunk in the turn-start content, 1-based; a side without lines starts at 1 with zero lines. */
73
+ oldStart: number
74
+ /** Lines of the hunk taken from the turn-start content. */
75
+ oldLines: number
76
+ /** First line of the hunk in the turn-end content, 1-based; a side without lines starts at 1 with zero lines. */
77
+ newStart: number
78
+ /** Lines of the hunk taken from the turn-end content. */
79
+ newLines: number
80
+ /** Hunk body in order, each line prefixed with `+`, `-`, or a space. */
81
+ lines: string[]
82
+ }
83
+ ```
84
+
85
+ ## `WorkspaceFileDiff` — one file's comparison
86
+
87
+ ```ts type-equiv
88
+ /** The comparison of one listed file's turn-start and turn-end contents, computed when asked for. */
89
+ type WorkspaceFileDiff =
90
+ | {
91
+ kind: 'text'
92
+ /** The listed file's `path`. */
93
+ path: string
94
+ /** The listed file's `display`. */
95
+ display: string
96
+ /** Whether the file existed at turn start. */
97
+ before: boolean
98
+ /** Whether the file existed at turn end. */
99
+ after: boolean
100
+ /** Hunks in file order; empty when both sides hold the same lines. */
101
+ hunks: WorkspaceDiffHunk[]
102
+ /** True when the line comparison exceeded the plugin's `diffTimeoutMs` and every line is shown as replaced. */
103
+ coarse: boolean
104
+ }
105
+ /** A side git reported as binary or that holds a NUL byte; no lines are served. */
106
+ | { kind: 'binary'; path: string; display: string }
107
+ /** A side larger than the plugin's `maxFileBytes`; no lines are served. */
108
+ | { kind: 'oversized'; path: string; display: string }
109
+ ```
110
+
111
+ ## `WorkspaceChanges` — the Host service serving summaries and comparisons
112
+
113
+ ```ts type-equiv
114
+ /** Serves the summaries and file comparisons the recorder keeps for live Sessions. */
115
+ interface WorkspaceChanges {
116
+ /**
117
+ * The summary announced by one `workspace/changes` event.
118
+ * @param sessionId - the Session that appended the event.
119
+ * @param seq - the event's sequence number.
120
+ * @returns the summary, or undefined once its Session was disposed or when this Host never recorded it.
121
+ */
122
+ summary(sessionId: SessionId, seq: number): WorkspaceChangesSummary | undefined
123
+ /**
124
+ * Compare one listed file's contents at turn start and turn end.
125
+ * @param sessionId - the Session that appended the event.
126
+ * @param seq - the event's sequence number.
127
+ * @param index - the file's index in the summary's `files`.
128
+ * @param signal - cancels the reads.
129
+ * @returns the comparison, or undefined once its Session was disposed, when this Host never recorded it, or when no file has that index.
130
+ * @throws when a snapshot read fails for a live Session.
131
+ */
132
+ diff(sessionId: SessionId, seq: number, index: number, signal: AbortSignal): Promise<WorkspaceFileDiff | undefined>
133
+ }
134
+ ```
135
+
136
+ ## Durable events and the served summary
137
+
138
+ `tool-present` declaration-merges `deliverables/presented: { turn; callId; files: PresentedFile[] }` into `SessionEventMap`, appended once per successful final `present` result. `workspace-changes` merges `workspace/changes: { turn }`, appended when a top-level turn stops; the summary that event announced is not in the log but is returned by `workspaceChanges.summary(sessionId, seq)` for the event's sequence until the Session is disposed, so a conversation reopened after a Host restart has no changed-files card for its earlier turns. `workspaceChanges.diff(sessionId, seq, index, signal)` compares one listed file on the same terms. A later event for the same turn replaces the earlier one, so a client keeps only the latest. The generated [persistence catalog](../persistence-catalog.md#deliverablespresented--log-only) records both declaration sites. Neither event reaches the model.
139
+
140
+ <!-- BEGIN GENERATED cordis-surface (gen-cordis-catalog.ts) — do not edit between markers -->
141
+
142
+ <a id="cordis-surface"></a>
143
+
144
+ ## Cordis API
145
+
146
+ Generated from source by `scripts/gen-cordis-catalog.ts` (verified fresh by `pnpm run verify-cordis-catalog` in doc-sync; regenerate with `pnpm run gen-cordis-catalog`) — the language sides differ only in locale-specific paired document paths. Signature blocks use a `ts cordis-catalog` fence and keep the original source JSDoc; dispatch modes are defined in the [primer](../cordis-primer.md#dispatch-modes), and the framework-inherited `ctx` API lives in [cordis-api/inherited.md](../cordis-api/inherited.md).
147
+
148
+ <a id="ctxworkspacechanges--workspacechanges"></a>
149
+
150
+ ### `ctx.workspaceChanges` — `WorkspaceChanges`
151
+
152
+ Serves the summaries and file comparisons the recorder keeps for live Sessions.
153
+
154
+ ```ts cordis-catalog
155
+ /**
156
+ * The summary announced by one `workspace/changes` event.
157
+ * @param sessionId - the Session that appended the event.
158
+ * @param seq - the event's sequence number.
159
+ * @returns the summary, or undefined once its Session was disposed or when this Host never recorded it.
160
+ */
161
+ summary(sessionId: SessionId, seq: number): WorkspaceChangesSummary | undefined
162
+
163
+ /**
164
+ * Compare one listed file's contents at turn start and turn end.
165
+ * @param sessionId - the Session that appended the event.
166
+ * @param seq - the event's sequence number.
167
+ * @param index - the file's index in the summary's `files`.
168
+ * @param signal - cancels the reads.
169
+ * @returns the comparison, or undefined once its Session was disposed, when this Host never recorded it, or when no file has that index.
170
+ * @throws when a snapshot read fails for a live Session.
171
+ */
172
+ diff(sessionId: SessionId, seq: number, index: number, signal: AbortSignal): Promise<WorkspaceFileDiff | undefined>
173
+ ```
174
+
175
+ Types: [SessionId](core.md)
176
+
177
+ Source: [`packages/deliverables/workspace-changes/src/types.ts`](../../packages/deliverables/workspace-changes/src/types.ts)
178
+ <!-- END GENERATED cordis-surface -->
@@ -0,0 +1,178 @@
1
+ # 产出物
2
+
3
+ [English](deliverables.md) | 中文
4
+
5
+ 记录一轮交给用户的东西,由 [deliverables 包组](../../packages/deliverables/README.zh.md)拥有:模型通过 `present` 工具声明的文件,记在一个只写日志的 Session 事件里;这一轮改动的文件,由轮开始和轮结束时的 git 工作树快照对比得出,git 覆盖不到的路径则由文件工具每次编辑前后的整文件捕获得出,用一个只写日志的事件宣告,并在 Session 存活期间由 Host 服务连同每个所列文件在轮开始与轮结束时的对比一起提供。它们只由客户端读取,Web [产出物插件](../../packages/client/ui-deliverables/README.zh.md)在轮末渲染两者。工具行为、快照机制和配置见 [`tool-present`](../../packages/deliverables/tool-present/README.zh.md) 与 [`workspace-changes`](../../packages/deliverables/workspace-changes/README.zh.md) 的包 README。
6
+
7
+ 源码:[`packages/deliverables/tool-present/src/types.ts`](../../packages/deliverables/tool-present/src/types.ts)、[`packages/deliverables/workspace-changes/src/types.ts`](../../packages/deliverables/workspace-changes/src/types.ts)
8
+
9
+ ## `PresentedFile`:一条声明的交付
10
+
11
+ ```ts type-equiv
12
+ /** A declared filesystem file whose current contents remain at its source path. */
13
+ interface PresentedFile {
14
+ /** Original absolute path or path relative to the Session working directory. */
15
+ path: string
16
+ /** Optional description supplied by the model. */
17
+ description?: string
18
+ }
19
+ ```
20
+
21
+ ## `WorkspaceChangedFile`:一个改动的文件
22
+
23
+ ```ts type-equiv
24
+ /** One file changed during a turn, with line counts from git or from the whole-file captures around its file-tool edits. */
25
+ interface WorkspaceChangedFile {
26
+ /** Path relative to the Session working directory, or an absolute Host path outside it. */
27
+ path: string
28
+ /**
29
+ * Sort key and label: the relative path inside the working directory, a
30
+ * `../` path for repository files above it, a `~` path under the home
31
+ * directory, otherwise the absolute path. Always slash-separated.
32
+ */
33
+ display: string
34
+ /** Lines added; zero for a binary or oversized file. */
35
+ added: number
36
+ /** Lines deleted; zero for a binary or oversized file. */
37
+ deleted: number
38
+ /** Present when git reported the file as binary, or when a captured side holds a NUL byte. */
39
+ binary?: true
40
+ /** Present when a captured side exceeded the plugin's `maxFileBytes`; the file is listed without counts or comparison. */
41
+ oversized?: true
42
+ }
43
+ ```
44
+
45
+ ## `WorkspaceChangesSummary`:一轮的改动摘要
46
+
47
+ ```ts type-equiv
48
+ /** Files changed during one top-level turn, kept on the Host until its Session is disposed. */
49
+ interface WorkspaceChangesSummary {
50
+ /** The turn whose file changes this summary describes. */
51
+ turn: number
52
+ /** The Session working directory `path` values are relative to. */
53
+ cwd: string
54
+ /** Changed files in `display` order, capped at the plugin's `maxFiles`. */
55
+ files: WorkspaceChangedFile[]
56
+ /** Complete changed-file count, including files omitted by the cap. */
57
+ total: number
58
+ /** Lines added over every changed file, including files omitted by the cap. */
59
+ added: number
60
+ /** Lines deleted over every changed file, including files omitted by the cap. */
61
+ deleted: number
62
+ /** Git tree ids of the turn-start and turn-end snapshots; absent when no snapshot was taken. */
63
+ snapshot?: { before: string; after: string }
64
+ }
65
+ ```
66
+
67
+ ## `WorkspaceDiffHunk`:一个 unified diff hunk
68
+
69
+ ```ts type-equiv
70
+ /** One unified-diff hunk with three context lines; every line keeps its `+`, `-`, or space prefix. */
71
+ interface WorkspaceDiffHunk {
72
+ /** First line of the hunk in the turn-start content, 1-based; a side without lines starts at 1 with zero lines. */
73
+ oldStart: number
74
+ /** Lines of the hunk taken from the turn-start content. */
75
+ oldLines: number
76
+ /** First line of the hunk in the turn-end content, 1-based; a side without lines starts at 1 with zero lines. */
77
+ newStart: number
78
+ /** Lines of the hunk taken from the turn-end content. */
79
+ newLines: number
80
+ /** Hunk body in order, each line prefixed with `+`, `-`, or a space. */
81
+ lines: string[]
82
+ }
83
+ ```
84
+
85
+ ## `WorkspaceFileDiff`:一个文件的对比
86
+
87
+ ```ts type-equiv
88
+ /** The comparison of one listed file's turn-start and turn-end contents, computed when asked for. */
89
+ type WorkspaceFileDiff =
90
+ | {
91
+ kind: 'text'
92
+ /** The listed file's `path`. */
93
+ path: string
94
+ /** The listed file's `display`. */
95
+ display: string
96
+ /** Whether the file existed at turn start. */
97
+ before: boolean
98
+ /** Whether the file existed at turn end. */
99
+ after: boolean
100
+ /** Hunks in file order; empty when both sides hold the same lines. */
101
+ hunks: WorkspaceDiffHunk[]
102
+ /** True when the line comparison exceeded the plugin's `diffTimeoutMs` and every line is shown as replaced. */
103
+ coarse: boolean
104
+ }
105
+ /** A side git reported as binary or that holds a NUL byte; no lines are served. */
106
+ | { kind: 'binary'; path: string; display: string }
107
+ /** A side larger than the plugin's `maxFileBytes`; no lines are served. */
108
+ | { kind: 'oversized'; path: string; display: string }
109
+ ```
110
+
111
+ ## `WorkspaceChanges`:提供摘要与对比的 Host 服务
112
+
113
+ ```ts type-equiv
114
+ /** Serves the summaries and file comparisons the recorder keeps for live Sessions. */
115
+ interface WorkspaceChanges {
116
+ /**
117
+ * The summary announced by one `workspace/changes` event.
118
+ * @param sessionId - the Session that appended the event.
119
+ * @param seq - the event's sequence number.
120
+ * @returns the summary, or undefined once its Session was disposed or when this Host never recorded it.
121
+ */
122
+ summary(sessionId: SessionId, seq: number): WorkspaceChangesSummary | undefined
123
+ /**
124
+ * Compare one listed file's contents at turn start and turn end.
125
+ * @param sessionId - the Session that appended the event.
126
+ * @param seq - the event's sequence number.
127
+ * @param index - the file's index in the summary's `files`.
128
+ * @param signal - cancels the reads.
129
+ * @returns the comparison, or undefined once its Session was disposed, when this Host never recorded it, or when no file has that index.
130
+ * @throws when a snapshot read fails for a live Session.
131
+ */
132
+ diff(sessionId: SessionId, seq: number, index: number, signal: AbortSignal): Promise<WorkspaceFileDiff | undefined>
133
+ }
134
+ ```
135
+
136
+ ## 持久事件与提供的摘要
137
+
138
+ `tool-present` 通过声明合并把 `deliverables/presented: { turn; callId; files: PresentedFile[] }` 加入 `SessionEventMap`,每次 `present` 的最终结果成功时追加一条。`workspace-changes` 合并 `workspace/changes: { turn }`,在顶层轮停止时追加;该事件宣告的摘要不在日志里,而是由 `workspaceChanges.summary(sessionId, seq)` 按事件序号返回,直到 Session 释放,因此 Host 重启后重新打开的对话,先前轮次没有改动文件卡片。`workspaceChanges.diff(sessionId, seq, index, signal)` 按同样的条件对比一个所列文件。同一轮后来的事件替代先前的,客户端只保留最新一条。生成的[持久化目录](../persistence-catalog.zh.md#deliverablespresented--log-only)记录了两处声明位置。两个事件都不会进入模型请求。
139
+
140
+ <!-- BEGIN GENERATED cordis-surface (gen-cordis-catalog.ts) — do not edit between markers -->
141
+
142
+ <a id="cordis-surface"></a>
143
+
144
+ ## Cordis API
145
+
146
+ Generated from source by `scripts/gen-cordis-catalog.ts` (verified fresh by `pnpm run verify-cordis-catalog` in doc-sync; regenerate with `pnpm run gen-cordis-catalog`) — the language sides differ only in locale-specific paired document paths. Signature blocks use a `ts cordis-catalog` fence and keep the original source JSDoc; dispatch modes are defined in the [primer](../cordis-primer.zh.md#dispatch-modes), and the framework-inherited `ctx` API lives in [cordis-api/inherited.md](../cordis-api/inherited.md).
147
+
148
+ <a id="ctxworkspacechanges--workspacechanges"></a>
149
+
150
+ ### `ctx.workspaceChanges` — `WorkspaceChanges`
151
+
152
+ Serves the summaries and file comparisons the recorder keeps for live Sessions.
153
+
154
+ ```ts cordis-catalog
155
+ /**
156
+ * The summary announced by one `workspace/changes` event.
157
+ * @param sessionId - the Session that appended the event.
158
+ * @param seq - the event's sequence number.
159
+ * @returns the summary, or undefined once its Session was disposed or when this Host never recorded it.
160
+ */
161
+ summary(sessionId: SessionId, seq: number): WorkspaceChangesSummary | undefined
162
+
163
+ /**
164
+ * Compare one listed file's contents at turn start and turn end.
165
+ * @param sessionId - the Session that appended the event.
166
+ * @param seq - the event's sequence number.
167
+ * @param index - the file's index in the summary's `files`.
168
+ * @param signal - cancels the reads.
169
+ * @returns the comparison, or undefined once its Session was disposed, when this Host never recorded it, or when no file has that index.
170
+ * @throws when a snapshot read fails for a live Session.
171
+ */
172
+ diff(sessionId: SessionId, seq: number, index: number, signal: AbortSignal): Promise<WorkspaceFileDiff | undefined>
173
+ ```
174
+
175
+ Types: [SessionId](core.zh.md)
176
+
177
+ Source: [`packages/deliverables/workspace-changes/src/types.ts`](../../packages/deliverables/workspace-changes/src/types.ts)
178
+ <!-- END GENERATED cordis-surface -->
@@ -46,7 +46,8 @@ list(): CordisInspectProviderView[]
46
46
  * @param input - optional lossless JSON input.
47
47
  * @param agent - requesting Agent and scope.
48
48
  * @param signal - tool-call cancellation.
49
- * @returns provider JSON data.
49
+ * @returns provider JSON data; Client queries fail fast when Gateway has no live Client
50
+ * and retain only the first observed failure diagnostic for timeout reporting.
50
51
  */
51
52
  async query( platform: CordisInspectPlatform, providerId: string, methodName: string, input: JsonValue | undefined, agent: Agent, signal: AbortSignal, ): Promise<JsonValue>
52
53
 
@@ -55,7 +56,7 @@ async query( platform: CordisInspectPlatform, providerId: string, methodName: st
55
56
  * @param agent - Agent whose Session owns the query.
56
57
  * @param requestId - Pending Client query identity.
57
58
  * @param resolution - Client provider result or failure.
58
- * @returns whether this response settled the still-pending query.
59
+ * @returns acknowledgement with accepted true only for a success that settles the query; only the first failure diagnostic is retained.
59
60
  */
60
61
  resolveClientQuery( agent: Agent, requestId: CordisInspectRequestId, resolution: CordisInspectQueryResolution, ): CordisInspectResolveAck
61
62
  ```
@@ -168,11 +169,12 @@ async stop(agent: Agent, pluginId: CordisDynamicPluginId): Promise<DynamicCordis
168
169
  @Remote('syncInspectManifest') syncInspectManifest(providers: readonly CordisInspectProviderManifest[]): null
169
170
 
170
171
  /**
171
- * Claim one pending Client inspect query with its live result.
172
+ * Submit a Client inspect result or failure for a pending query.
172
173
  * @param agent - Session that owns the query.
173
174
  * @param requestId - exact pending query identity.
174
175
  * @param resolution - provider result or structured refusal.
175
- * @returns whether this answer won the query.
176
+ * @returns acknowledgement with accepted true only for a valid success that settles the query;
177
+ * pending-query failures return { accepted: false } and retain only the first diagnostic.
176
178
  */
177
179
  @Remote('resolveInspectQuery') resolveInspectQuery( agent: Agent, requestId: CordisInspectRequestId, resolution: CordisInspectQueryResolution, ): CordisInspectResolveAck
178
180
 
@@ -46,7 +46,8 @@ list(): CordisInspectProviderView[]
46
46
  * @param input - optional lossless JSON input.
47
47
  * @param agent - requesting Agent and scope.
48
48
  * @param signal - tool-call cancellation.
49
- * @returns provider JSON data.
49
+ * @returns provider JSON data; Client queries fail fast when Gateway has no live Client
50
+ * and retain only the first observed failure diagnostic for timeout reporting.
50
51
  */
51
52
  async query( platform: CordisInspectPlatform, providerId: string, methodName: string, input: JsonValue | undefined, agent: Agent, signal: AbortSignal, ): Promise<JsonValue>
52
53
 
@@ -55,7 +56,7 @@ async query( platform: CordisInspectPlatform, providerId: string, methodName: st
55
56
  * @param agent - Agent whose Session owns the query.
56
57
  * @param requestId - Pending Client query identity.
57
58
  * @param resolution - Client provider result or failure.
58
- * @returns whether this response settled the still-pending query.
59
+ * @returns acknowledgement with accepted true only for a success that settles the query; only the first failure diagnostic is retained.
59
60
  */
60
61
  resolveClientQuery( agent: Agent, requestId: CordisInspectRequestId, resolution: CordisInspectQueryResolution, ): CordisInspectResolveAck
61
62
  ```
@@ -168,11 +169,12 @@ async stop(agent: Agent, pluginId: CordisDynamicPluginId): Promise<DynamicCordis
168
169
  @Remote('syncInspectManifest') syncInspectManifest(providers: readonly CordisInspectProviderManifest[]): null
169
170
 
170
171
  /**
171
- * Claim one pending Client inspect query with its live result.
172
+ * Submit a Client inspect result or failure for a pending query.
172
173
  * @param agent - Session that owns the query.
173
174
  * @param requestId - exact pending query identity.
174
175
  * @param resolution - provider result or structured refusal.
175
- * @returns whether this answer won the query.
176
+ * @returns acknowledgement with accepted true only for a valid success that settles the query;
177
+ * pending-query failures return { accepted: false } and retain only the first diagnostic.
176
178
  */
177
179
  @Remote('resolveInspectQuery') resolveInspectQuery( agent: Agent, requestId: CordisInspectRequestId, resolution: CordisInspectQueryResolution, ): CordisInspectResolveAck
178
180
 
@@ -27,7 +27,7 @@ interface MessageFeedbackItem {
27
27
  readonly rating: MessageFeedbackRating
28
28
  /** Optional explanation, preserved verbatim after validation. */
29
29
  readonly note?: string
30
- /** Category the human filed a negative judgment under. */
30
+ /** Category the human filed the judgment under. */
31
31
  readonly category?: FeedbackCategory
32
32
  /** Equality-only token replaced by every material create or update. */
33
33
  readonly version: MessageFeedbackVersion
@@ -290,7 +290,7 @@ Successful message-feedback mutations await canonical persistence: live operatio
290
290
 
291
291
  Plugin disposal closes operation admission and drains accepted per-Session queue work.
292
292
 
293
- When explicitly enabled, [`session-log-deepseek`](../../packages/session/session-log-deepseek/README.md) carries feedback as part of the ordinary `dsh_session_log` suffix on subsequent eligible DeepSeek requests. Recording feedback does not trigger an LLM request or a separate `dsh_feedback` upload. For non-DeepSeek routes, the [OTel backend](../../packages/session/session-telemetry-otel/README.md) can release the canonical prefix through recorded feedback. The command acknowledgement confirms recording and identifies the Session and anonymous user; it reports neither telemetry policy nor delivery.
293
+ By default, [`session-log-deepseek`](../../packages/session/session-log-deepseek/README.md) carries feedback as part of the ordinary `dsh_session_log` suffix on subsequent eligible DeepSeek requests; a composition disables it with `enabled: false`. Recording feedback does not trigger an LLM request or a separate `dsh_feedback` upload. For non-DeepSeek routes, the [OTel backend](../../packages/session/session-telemetry-otel/README.md) can release the canonical prefix through recorded feedback. The command acknowledgement confirms recording and identifies the Session and anonymous user; it reports neither telemetry policy nor delivery.
294
294
 
295
295
  ## Web surface
296
296
 
@@ -298,9 +298,9 @@ When explicitly enabled, [`session-log-deepseek`](../../packages/session/session
298
298
 
299
299
  The controls are the `feedback` entry (order 10) of the `conversation.chat.assistant-actions` list slot, which `ui-conversation` declares and renders inside the finalized assistant message's IconActions row. `AssistantMessageNode` carries the optional `messageId` from the `assistant/message` event. The field is absent on interruption-frozen partials, and the render site skips the slot when it is absent. The strip renders once per turn, on the closing assistant message: the Host accepts every append-origin step message as a target, but earlier steps of a multi-step turn render tool rows rather than a rateable body, so the UI exposes a narrower set than the Host contract allows.
300
300
 
301
- One `MessageFeedbackController` per Session backs every message control in that Session: a single `list` read seeds the whole transcript, deferred to first hover or focus rather than fired on mount. Each mutation sends the version that controller last observed as `ifVersion`; a `version-conflict` reply carries the authoritative item, so the controller reconciles from the reply instead of refetching. Mutations serialize per Session so a queued operation compares against the committed version. A `connection/reset` refreshes only Sessions already read.
301
+ One `MessageFeedbackController` per Session backs every message control in that Session: a single `list` read seeds the whole transcript, deferred to first hover or focus rather than fired on mount. Each mutation sends the version that controller last observed as `ifVersion`; a `version-conflict` reply carries the authoritative item, so the controller reconciles from the reply instead of refetching. Mutations serialize per Session so a queued operation compares against the committed version. The injected `retract` operation rechecks the committed rating inside that queue and becomes a no-op after a concurrent change, so stale UI cannot bypass the dialog by recording a bare rating. A `connection/reset` refreshes only Sessions already read.
302
302
 
303
- Like records the bare positive judgment at once and shows the acknowledgement toast. Dislike opens the Session's feedback dialog, the `feedback-dialog` entry of `conversation.input.overlay`: the shared Modal card with seven category chips and a detail box. Submit puts a negative judgment carrying the chosen category and the trimmed description, or neither. The same dialog opens for the Session from a bare `/feedback` — a decoration `ui-commands` routes as an `action` — and then records through `sessionFeedback.record`; `/feedback <text>` keeps the Host command path. Clicking a recorded rating retracts it.
303
+ Either unrecorded rating opens the Session's feedback dialog, the `feedback-dialog` entry of `conversation.input.overlay`: the shared Modal card with seven category chips and a detail box. Submit puts the selected judgment carrying the chosen category and the trimmed description, or neither; success closes the dialog and shows the acknowledgement toast, while failure keeps the dialog and draft open and shows a warning toast. The same dialog opens for the Session from a bare `/feedback` — a decoration `ui-commands` routes as an `action` — and then records through `sessionFeedback.record`; `/feedback <text>` keeps the Host command path. Clicking a recorded rating retracts it without opening the dialog.
304
304
 
305
305
  ## Boundaries and limitations
306
306
 
@@ -27,7 +27,7 @@ interface MessageFeedbackItem {
27
27
  readonly rating: MessageFeedbackRating
28
28
  /** Optional explanation, preserved verbatim after validation. */
29
29
  readonly note?: string
30
- /** Category the human filed a negative judgment under. */
30
+ /** Category the human filed the judgment under. */
31
31
  readonly category?: FeedbackCategory
32
32
  /** Equality-only token replaced by every material create or update. */
33
33
  readonly version: MessageFeedbackVersion
@@ -290,7 +290,7 @@ fork 种子可以包含父 Session 的反馈事件,但 payload 保留父级 `s
290
290
 
291
291
  插件释放会关闭操作接纳,并排空已进入各 Session 队列的工作。
292
292
 
293
- 显式启用后,[`session-log-deepseek`](../../packages/session/session-log-deepseek/README.zh.md) 会在后续符合条件的 DeepSeek 请求中,把反馈作为普通 `dsh_session_log` 后缀的一部分传送。记录反馈不会触发 LLM 请求,也不会单独上传 `dsh_feedback`。对于非 DeepSeek 路由,[OTel 后端](../../packages/session/session-telemetry-otel/README.zh.md)可以将权威日志前缀释放至已记录的反馈。命令确认文本确认记录并标识 Session 与匿名用户,不报告遥测策略或投递结果。
293
+ 默认情况下,[`session-log-deepseek`](../../packages/session/session-log-deepseek/README.zh.md) 会在后续符合条件的 DeepSeek 请求中,把反馈作为普通 `dsh_session_log` 后缀的一部分传送;组合可用 `enabled: false` 禁用它。记录反馈不会触发 LLM 请求,也不会单独上传 `dsh_feedback`。对于非 DeepSeek 路由,[OTel 后端](../../packages/session/session-telemetry-otel/README.zh.md)可以将权威日志前缀释放至已记录的反馈。命令确认文本确认记录并标识 Session 与匿名用户,不报告遥测策略或投递结果。
294
294
 
295
295
  ## Web 界面
296
296
 
@@ -298,9 +298,9 @@ fork 种子可以包含父 Session 的反馈事件,但 payload 保留父级 `s
298
298
 
299
299
  控件是 `conversation.chat.assistant-actions` list slot 的 `feedback` 条目(order 10),该 slot 由 `ui-conversation` 声明,并渲染在已定稿助手消息的 IconActions 行内。`AssistantMessageNode` 携带来自 `assistant/message` 事件的可选 `messageId`。被中断冻结的部分输出没有该字段,渲染点在字段缺失时跳过该 slot。该操作栏每个 Turn 渲染一次,位于收尾的助手消息上:Host 接受每条 append-origin 步骤消息作为目标,但多步骤 Turn 中较早的步骤渲染的是工具行而非可评分正文,因此 UI 暴露的范围比 Host 约定允许的更窄。
300
300
 
301
- 每个 Session 一个 `MessageFeedbackController`,支撑该 Session 内所有消息的控件:一次 `list` 读取即填充整段对话,且延迟到首次 hover 或 focus 才发起,而非挂载时触发。每次变更把该 controller 最后观察到的版本作为 `ifVersion` 发送;`version-conflict` 响应携带权威条目,controller 据此对账而不重新拉取。变更按 Session 串行,排队操作与已提交版本比较。`connection/reset` 只刷新已读取过的 Session。
301
+ 每个 Session 一个 `MessageFeedbackController`,支撑该 Session 内所有消息的控件:一次 `list` 读取即填充整段对话,且延迟到首次 hover 或 focus 才发起,而非挂载时触发。每次变更把该 controller 最后观察到的版本作为 `ifVersion` 发送;`version-conflict` 响应携带权威条目,controller 据此对账而不重新拉取。变更按 Session 串行,排队操作与已提交版本比较。注入的 `retract` 操作会在该队列内重新检查已提交评分,并在并发变更后变为无操作,因此陈旧 UI 无法绕过弹窗记录裸评分。`connection/reset` 只刷新已读取过的 Session。
302
302
 
303
- 点赞立即记录不带备注的好评并显示确认 toast。点踩打开该 Session 的反馈弹窗,即 `conversation.input.overlay` 的 `feedback-dialog` 条目:共用的 Modal 卡片,里面是七个分类标签和一个详情框。提交会 put 一条差评,带上所选分类与去除首尾空白的描述,两者也可都不带。不带文本的 `/feedback`(`ui-commands` 以 `action` 路由的一个装饰)为 Session 打开同一个弹窗,随后通过 `sessionFeedback.record` 记录;`/feedback <text>` 仍走宿主命令路径。再次点击已记录的评分会撤回它。
303
+ 任一未记录的评分都会打开该 Session 的反馈弹窗,即 `conversation.input.overlay` 的 `feedback-dialog` 条目:共用的 Modal 卡片,里面是七个分类标签和一个详情框。提交会 put 所选评分,带上所选分类与去除首尾空白的描述,两者也可都不带;成功会关闭弹窗并显示确认 toast,失败则保留弹窗与草稿并显示警告 toast。不带文本的 `/feedback`(`ui-commands` 以 `action` 路由的一个装饰)为 Session 打开同一个弹窗,随后通过 `sessionFeedback.record` 记录;`/feedback <text>` 仍走宿主命令路径。再次点击已记录的评分会直接撤回,不打开弹窗。
304
304
 
305
305
  ## 边界与限制
306
306
 
@@ -0,0 +1,139 @@
1
+ # MCP
2
+
3
+ English | [中文](mcp.zh.md)
4
+
5
+ ## Summary
6
+
7
+ Model Context Protocol (MCP) connects the model to tools supplied by external servers. Each configured server contributes ordinary harness tools with cancellation, permission checks, recorded results, and supported image output. Shared tools discover and read resources when a server is configured in the caller's scope, while server instructions join the logged system prompt. The official SDK negotiates modern or supported legacy protocol revisions. This reference covers the MCP package group's responsibilities, scope, and composition choices; the [client README](../../packages/mcp/mcp-client/README.md) owns server configuration.
8
+
9
+ ## Table of Contents
10
+
11
+ - [Configuration](#configuration)
12
+ - [Responsibilities and scope](#responsibilities-and-scope)
13
+ - [Protocol and results](#protocol-and-results)
14
+ - [Resources and instructions](#resources-and-instructions)
15
+ - [Resource provider types](#resource-provider-types)
16
+ - [Limits](#limits)
17
+ - [Further reading](#further-reading)
18
+
19
+ -----
20
+
21
+ <a id="configuration"></a>
22
+ ## Configuration
23
+
24
+ MCP servers are opt-in. Configure one `@deepseek-ai/dsh-mcp-client` entry per server in the intended Cordis scope. Every shipped profile supplies the [tool registry](tools.md) and mounts the shared resource service once; users configure only client entries. Callers with no visible configured server receive no MCP prompt text or tools in native or PTC mode.
25
+
26
+ | Choice | Configuration owner |
27
+ |---|---|
28
+ | Server identity, local process or HTTP endpoint, credentials, and process environment | [Client configuration](../../packages/mcp/mcp-client/README.md#use-this-package) |
29
+ | Tool and resource request timeout, startup failure policy, and reconnection | [Client configuration](../../packages/mcp/mcp-client/README.md#use-this-package) |
30
+ | Resource discovery and reading | The [MCP resource service](../../packages/mcp/mcp-resources/README.md#use-this-package) is included in shipped profiles; it has no configuration fields |
31
+ | Server instruction size limit | Client `maxInstructionBytes`; the composition supplies [system-prompt assembly](system-prompt.md) |
32
+ | Permission decisions and supported image output | [Tool execution](tools.md) and [attachments](attachment.md) |
33
+
34
+ Protocol negotiation follows the SDK's supported revisions; there is no product setting that forces a protocol revision. The [configuration catalog](../config-catalog.md#deepseek-aidsh-mcp-client) lists accepted client fields and defaults.
35
+
36
+ -----
37
+
38
+ <a id="responsibilities-and-scope"></a>
39
+ ## Responsibilities and scope
40
+
41
+ The client is a per-server connection plugin and a consumer of the harness tool registry. It does not publish a shared `ctx.mcp` service. The external server implements MCP operations; the SDK owns protocol exchange; the client adapts discovered tools to harness execution.
42
+
43
+ `mcp-resources` owns the shared resource tools and selects providers in the caller's scope. Each MCP client supplies resource operations through its own connection. The first provider in a scope enables the local shared tools, and removing the last removes them; inherited providers remain visible. The service owns these tool registrations independently of any one client. Connection failures do not remove shared resource tools while a visible client entry remains active.
44
+
45
+ Configured `serverName` identifies a server in its registration scope. Two entries in that scope cannot reserve the same name; separate Agent scopes can reuse it. Public tool names include the configured server name, so equally named tools from different servers remain distinct. Registration effects own names and discovered tools; plugin disposal closes the connection and removes its contributions.
46
+
47
+ The [native Cua Driver provider](../../packages/experimental/computer-use-cua-driver-native/README.md) shares the client's exported result adapter without opening an MCP connection. Desktop provider selection belongs to the [computer-use subsystem](computer-use.md).
48
+
49
+ -----
50
+
51
+ <a id="protocol-and-results"></a>
52
+ ## Protocol and results
53
+
54
+ Both stdio and Streamable HTTP use the official SDK's negotiation, discovery, protocol validation, and cancellation. Tool-list changes trigger discovery through legacy notifications or a modern subscription. A failed refresh retains the previous tool generation; connection recovery follows the [client lifecycle](../../packages/mcp/mcp-client/README.md#use-this-package).
55
+
56
+ The result adapter retains canonical MCP JSON for programmatic callers and prepares ordinary tool content. Supported images use the attachment system; unsupported rich content produces explicit text diagnostics. The tool registry remains authoritative for policy failures and replaced results. The [tool contracts](tools.md) own recording and final presentation; the [client result reference](../../packages/mcp/mcp-client/README.md#use-this-package) owns MCP-specific projection details.
57
+
58
+ -----
59
+
60
+ <a id="resources-and-instructions"></a>
61
+ ## Resources and instructions
62
+
63
+ Resource calls require an explicit configured server name. When system-prompt assembly is available, the resource service lists caller-visible names from the same registry used for dispatch, including servers with no tools or instructions. The shared registry resolves that name in the calling Agent's scope before dispatch; unavailable servers fail without a network request. Discovery and reads are on demand, including for servers that expose resources without tools. The [resource package](../../packages/mcp/mcp-resources/README.md) owns pagination and content rendering; its generated tool schemas live in the [tool catalog](../tool-catalog.md#deepseek-aidsh-mcp-resources).
64
+
65
+ Resource providers remain connection-owned. Scope disposal removes registrations; the MCP client controls cancellation and recovery. Canonical results retain complete JSON for programmatic callers, while the text projection replaces binary blobs with descriptions. Returned text enters ordinary tool history; content is not fetched merely because a server connects.
66
+
67
+ When system-prompt assembly is composed, the client publishes nonblank server instructions as a scoped, server-attributed section. Instructions remain literal text and pass the configured size limit before publication. A replacement connection publishes instructions only after discovery succeeds; absent instructions add no section. The [system-prompt subsystem](system-prompt.md) owns assembly and recording.
68
+
69
+ -----
70
+
71
+ <a id="resource-provider-types"></a>
72
+ ## Resource provider types
73
+
74
+ The connection provider receives one operation and the original tool execution, including its caller and cancellation signal.
75
+
76
+ ```ts type-equiv
77
+ /** One supported resource operation, with server-owned cursors and URIs. */
78
+ type McpResourceRequest =
79
+ | { method: 'resources/list' | 'resources/templates/list'; cursor?: string }
80
+ | { method: 'resources/read'; uri: string }
81
+ ```
82
+
83
+ ```ts type-equiv
84
+ /** One configured server's resource access, owned by its MCP connection plugin. */
85
+ interface McpResourceProvider {
86
+ /**
87
+ * Run an operation against one live connection generation.
88
+ * @param request - MCP resource method and parameters.
89
+ * @param exec - caller identity and cancellation for this invocation.
90
+ * @returns the protocol result as lossless JSON.
91
+ */
92
+ request(request: McpResourceRequest, exec: ToolExecution): Promise<JsonValue>
93
+ }
94
+ ```
95
+
96
+ -----
97
+
98
+ <a id="limits"></a>
99
+ ## Limits
100
+
101
+ MCP prompt templates, human-input elicitation, task-based execution, and resource subscriptions are unsupported. Resource tools require a caller-visible configured server; binary resources remain programmatic data with text descriptions for the model. Servers without a tools capability connect with an empty tool set. Connection and discovery timeouts follow the SDK; the client has no separate settings for them.
102
+
103
+ -----
104
+
105
+ <a id="further-reading"></a>
106
+ ## Further reading
107
+
108
+ - [MCP package group](../../packages/mcp/README.md) — package entry points.
109
+ - [MCP resources](../../packages/mcp/mcp-resources/README.md) — shared tools and resource-provider semantics.
110
+ - [Resource visibility reference](../../packages/mcp/mcp-resources/README.md) — shared profile mounting and visibility from configured servers.
111
+ - [Third-party memory servers](../user/guide/mcp-memory.md) — product configuration guide.
112
+ - [Protocol negotiation reference](../../packages/mcp/mcp-client/README.md) — SDK ownership and compatibility decisions.
113
+
114
+ <!-- BEGIN GENERATED cordis-surface (gen-cordis-catalog.ts) — do not edit between markers -->
115
+
116
+ <a id="cordis-surface"></a>
117
+
118
+ ## Cordis API
119
+
120
+ Generated from source by `scripts/gen-cordis-catalog.ts` (verified fresh by `pnpm run verify-cordis-catalog` in doc-sync; regenerate with `pnpm run gen-cordis-catalog`) — the language sides differ only in locale-specific paired document paths. Signature blocks use a `ts cordis-catalog` fence and keep the original source JSDoc; dispatch modes are defined in the [primer](../cordis-primer.md#dispatch-modes), and the framework-inherited `ctx` API lives in [cordis-api/inherited.md](../cordis-api/inherited.md).
121
+
122
+ <a id="ctxmcpresources--mcpresourceruntime"></a>
123
+
124
+ ### `ctx.mcpResources` — `McpResourceRuntime`
125
+
126
+ Scoped resource access plus three tools shared by configured MCP servers.
127
+
128
+ ```ts cordis-catalog
129
+ /**
130
+ * Register one server and expose resource tools while that scope has providers.
131
+ * @param server - configured server name, unique in this scope.
132
+ * @param provider - connection-owned resource operations.
133
+ * @returns the effect disposer for this exact registration.
134
+ */
135
+ register(server: string, provider: McpResourceProvider): () => void
136
+ ```
137
+
138
+ Source: [`packages/mcp/mcp-resources/src/index.ts`](../../packages/mcp/mcp-resources/src/index.ts)
139
+ <!-- END GENERATED cordis-surface -->