dsh-plugin-guide 0.3.27 → 0.3.30

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 (304) hide show
  1. package/README-es.md +3 -3
  2. package/README-hi.md +3 -3
  3. package/README-pt.md +3 -3
  4. package/README-zh.md +5 -3
  5. package/README.md +5 -3
  6. package/SKILL.md +21 -8
  7. package/dist/dsh-plugin-dev.js +93 -18
  8. package/guide/family-toolchain.md +260 -0
  9. package/guide/links.md +3 -2
  10. package/guide/migration-0.2.md +64 -8
  11. package/guide/plugin-dev-guide.md +8 -6
  12. package/guide/quick-reference.es.md +3 -2
  13. package/guide/quick-reference.hi.md +4 -3
  14. package/guide/quick-reference.md +6 -5
  15. package/guide/quick-reference.pt.md +4 -3
  16. package/guide/quick-reference.zh-CN.md +6 -5
  17. package/guide/release-engineering.md +4 -2
  18. package/guide/release-engineering.zh-CN.md +4 -2
  19. package/guide/unfixed-issues.md +7 -0
  20. package/guide/version-matrix.md +309 -0
  21. package/guide/when-to-retire-a-plugin.md +5 -5
  22. package/guide/when-to-retire-a-plugin.zh-CN.md +5 -5
  23. package/index.d.ts +32 -0
  24. package/index.js +24 -9
  25. package/package.json +19 -11
  26. package/references/community-ecosystem.md +2 -1
  27. package/references/dev-resource-landscape.md +294 -0
  28. package/references/official-docs/AGENTS.md +4 -5
  29. package/references/official-docs/SNAPSHOT.md +3 -3
  30. package/references/official-docs/THIRD_PARTY_NOTICES.md +2 -1
  31. package/references/official-docs/docs/AGENTS.md +1 -1
  32. package/references/official-docs/docs/architecture.i18n.yaml +14 -14
  33. package/references/official-docs/docs/architecture.md +11 -12
  34. package/references/official-docs/docs/architecture.zh.md +11 -12
  35. package/references/official-docs/docs/capability-seams.i18n.yaml +2 -2
  36. package/references/official-docs/docs/capability-seams.md +48 -23
  37. package/references/official-docs/docs/capability-seams.zh.md +48 -23
  38. package/references/official-docs/docs/cli-help.i18n.yaml +34 -0
  39. package/references/official-docs/docs/cli-help.md +203 -0
  40. package/references/official-docs/docs/cli-help.zh.md +205 -0
  41. package/references/official-docs/docs/config-catalog.md +305 -145
  42. package/references/official-docs/docs/config-catalog.zh.md +305 -145
  43. package/references/official-docs/docs/cookbook/adding-a-session-format-version.i18n.yaml +6 -6
  44. package/references/official-docs/docs/cookbook/adding-a-session-format-version.md +7 -5
  45. package/references/official-docs/docs/cookbook/adding-a-session-format-version.zh.md +7 -5
  46. package/references/official-docs/docs/cookbook/reviewing-persistence-type-changes.i18n.yaml +6 -6
  47. package/references/official-docs/docs/cookbook/reviewing-persistence-type-changes.md +11 -9
  48. package/references/official-docs/docs/cookbook/reviewing-persistence-type-changes.zh.md +11 -9
  49. package/references/official-docs/docs/deepseek-llm-api-wire-extensions.i18n.yaml +4 -4
  50. package/references/official-docs/docs/deepseek-llm-api-wire-extensions.md +5 -5
  51. package/references/official-docs/docs/deepseek-llm-api-wire-extensions.zh.md +5 -5
  52. package/references/official-docs/docs/defensive-patterns.i18n.yaml +2 -2
  53. package/references/official-docs/docs/defensive-patterns.md +1 -1
  54. package/references/official-docs/docs/defensive-patterns.zh.md +1 -1
  55. package/references/official-docs/docs/development.i18n.yaml +6 -6
  56. package/references/official-docs/docs/development.md +4 -2
  57. package/references/official-docs/docs/development.zh.md +4 -2
  58. package/references/official-docs/docs/event-producer-consumer.md +33 -33
  59. package/references/official-docs/docs/event-producer-consumer.zh.md +33 -33
  60. package/references/official-docs/docs/experimental-persistence-catalog.i18n.yaml +10 -0
  61. package/references/official-docs/docs/experimental-persistence-catalog.md +17 -0
  62. package/references/official-docs/docs/experimental-persistence-catalog.zh.md +17 -0
  63. package/references/official-docs/docs/module-graph.md +202 -131
  64. package/references/official-docs/docs/module-graph.zh.md +202 -131
  65. package/references/official-docs/docs/persistence-catalog.i18n.yaml +185 -158
  66. package/references/official-docs/docs/persistence-catalog.md +213 -112
  67. package/references/official-docs/docs/persistence-catalog.zh.md +213 -112
  68. package/references/official-docs/docs/persistence-changes/2026-09-13-working-directory.i18n.yaml +28 -0
  69. package/references/official-docs/docs/persistence-changes/2026-09-13-working-directory.md +48 -0
  70. package/references/official-docs/docs/persistence-changes/2026-09-13-working-directory.schema.json +76 -0
  71. package/references/official-docs/docs/persistence-changes/2026-09-13-working-directory.zh.md +48 -0
  72. package/references/official-docs/docs/persistence-changes/2026-09-16-session-format-v4.i18n.yaml +4 -4
  73. package/references/official-docs/docs/persistence-changes/2026-09-16-session-format-v4.md +2 -2
  74. package/references/official-docs/docs/persistence-changes/2026-09-16-session-format-v4.zh.md +2 -2
  75. package/references/official-docs/docs/persistence-changes/2026-09-19-external-subagent-catalog.i18n.yaml +28 -0
  76. package/references/official-docs/docs/persistence-changes/2026-09-19-external-subagent-catalog.md +48 -0
  77. package/references/official-docs/docs/persistence-changes/2026-09-19-external-subagent-catalog.schema.json +290 -0
  78. package/references/official-docs/docs/persistence-changes/2026-09-19-external-subagent-catalog.zh.md +48 -0
  79. package/references/official-docs/docs/persistence-changes/2026-10-05-ptc-operation-metadata.i18n.yaml +28 -0
  80. package/references/official-docs/docs/persistence-changes/2026-10-05-ptc-operation-metadata.md +48 -0
  81. package/references/official-docs/docs/persistence-changes/2026-10-05-ptc-operation-metadata.schema.json +457 -0
  82. package/references/official-docs/docs/persistence-changes/2026-10-05-ptc-operation-metadata.zh.md +48 -0
  83. package/references/official-docs/docs/persistence-changes/2026-10-05-working-directory-attribution.i18n.yaml +28 -0
  84. package/references/official-docs/docs/persistence-changes/2026-10-05-working-directory-attribution.md +60 -0
  85. package/references/official-docs/docs/persistence-changes/2026-10-05-working-directory-attribution.schema.json +11474 -0
  86. package/references/official-docs/docs/persistence-changes/2026-10-05-working-directory-attribution.zh.md +60 -0
  87. package/references/official-docs/docs/persistence-changes/2026-10-07-title-reasoning-effort.i18n.yaml +28 -0
  88. package/references/official-docs/docs/persistence-changes/2026-10-07-title-reasoning-effort.md +48 -0
  89. package/references/official-docs/docs/persistence-changes/2026-10-07-title-reasoning-effort.schema.json +2990 -0
  90. package/references/official-docs/docs/persistence-changes/2026-10-07-title-reasoning-effort.zh.md +48 -0
  91. package/references/official-docs/docs/persistence-changes/README.i18n.yaml +4 -4
  92. package/references/official-docs/docs/persistence-changes/README.md +12 -10
  93. package/references/official-docs/docs/persistence-changes/README.zh.md +12 -10
  94. package/references/official-docs/docs/persistence-changes/historical-formats/README.i18n.yaml +2 -2
  95. package/references/official-docs/docs/persistence-changes/historical-formats/README.md +1 -1
  96. package/references/official-docs/docs/persistence-changes/historical-formats/README.zh.md +1 -1
  97. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.2.i18n.yaml +2 -2
  98. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.2.md +50 -50
  99. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.2.zh.md +50 -50
  100. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.3.i18n.yaml +2 -2
  101. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.3.md +14 -14
  102. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.0.1-rc.3.zh.md +14 -14
  103. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.7.i18n.yaml +2 -2
  104. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.7.md +3 -3
  105. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.7.zh.md +3 -3
  106. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.8.i18n.yaml +2 -2
  107. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.8.md +10 -10
  108. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.0-rc.8.zh.md +10 -10
  109. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.1.i18n.yaml +2 -2
  110. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.1.md +3 -3
  111. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.1.zh.md +3 -3
  112. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.2.i18n.yaml +2 -2
  113. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.2.md +13 -13
  114. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.1-rc.2.zh.md +13 -13
  115. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.1.i18n.yaml +2 -2
  116. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.1.md +63 -63
  117. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.1.zh.md +63 -63
  118. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.2.i18n.yaml +2 -2
  119. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.2.md +54 -54
  120. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.2.zh.md +54 -54
  121. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.4.i18n.yaml +2 -2
  122. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.4.md +7 -7
  123. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.2-alpha.4.zh.md +7 -7
  124. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.1.i18n.yaml +2 -2
  125. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.1.md +27 -27
  126. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.1.zh.md +27 -27
  127. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.2.i18n.yaml +2 -2
  128. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.2.md +4 -4
  129. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.3-alpha.2.zh.md +4 -4
  130. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.1.i18n.yaml +2 -2
  131. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.1.md +27 -27
  132. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.1.zh.md +27 -27
  133. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.2.i18n.yaml +2 -2
  134. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.2.md +7 -7
  135. package/references/official-docs/docs/persistence-changes/releases/dsh-v0.1.5-alpha.2.zh.md +7 -7
  136. package/references/official-docs/docs/persistence-schema.json +2084 -1827
  137. package/references/official-docs/docs/session-format-status.i18n.yaml +6 -6
  138. package/references/official-docs/docs/session-format-status.md +6 -6
  139. package/references/official-docs/docs/session-format-status.zh.md +6 -6
  140. package/references/official-docs/docs/subsystems/README.i18n.yaml +2 -2
  141. package/references/official-docs/docs/subsystems/README.md +4 -1
  142. package/references/official-docs/docs/subsystems/README.zh.md +4 -1
  143. package/references/official-docs/docs/subsystems/agent-team.i18n.yaml +7 -7
  144. package/references/official-docs/docs/subsystems/agent-team.md +10 -10
  145. package/references/official-docs/docs/subsystems/agent-team.zh.md +10 -10
  146. package/references/official-docs/docs/subsystems/boot.i18n.yaml +2 -2
  147. package/references/official-docs/docs/subsystems/boot.md +4 -4
  148. package/references/official-docs/docs/subsystems/boot.zh.md +4 -4
  149. package/references/official-docs/docs/subsystems/claude-code-mods.i18n.yaml +2 -2
  150. package/references/official-docs/docs/subsystems/claude-code-mods.md +1 -1
  151. package/references/official-docs/docs/subsystems/claude-code-mods.zh.md +1 -1
  152. package/references/official-docs/docs/subsystems/jobs.i18n.yaml +2 -2
  153. package/references/official-docs/docs/subsystems/jobs.md +2 -3
  154. package/references/official-docs/docs/subsystems/jobs.zh.md +2 -3
  155. package/references/official-docs/docs/subsystems/llm-streaming.i18n.yaml +4 -4
  156. package/references/official-docs/docs/subsystems/llm-streaming.md +41 -14
  157. package/references/official-docs/docs/subsystems/llm-streaming.zh.md +41 -14
  158. package/references/official-docs/docs/subsystems/persistence.md +2 -0
  159. package/references/official-docs/docs/subsystems/persistence.zh.md +2 -0
  160. package/references/official-docs/docs/subsystems/plan.i18n.yaml +2 -2
  161. package/references/official-docs/docs/subsystems/plan.md +1 -1
  162. package/references/official-docs/docs/subsystems/plan.zh.md +1 -1
  163. package/references/official-docs/docs/subsystems/session-query.md +2 -0
  164. package/references/official-docs/docs/subsystems/session-query.zh.md +2 -0
  165. package/references/official-docs/docs/subsystems/session-title.i18n.yaml +6 -6
  166. package/references/official-docs/docs/subsystems/session-title.md +14 -5
  167. package/references/official-docs/docs/subsystems/session-title.zh.md +14 -5
  168. package/references/official-docs/docs/subsystems/session.i18n.yaml +3 -0
  169. package/references/official-docs/docs/subsystems/session.md +48 -5
  170. package/references/official-docs/docs/subsystems/session.zh.md +48 -5
  171. package/references/official-docs/docs/subsystems/skills.i18n.yaml +2 -2
  172. package/references/official-docs/docs/subsystems/skills.md +2 -2
  173. package/references/official-docs/docs/subsystems/skills.zh.md +2 -2
  174. package/references/official-docs/docs/subsystems/slots.md +10 -8
  175. package/references/official-docs/docs/subsystems/slots.zh.md +10 -8
  176. package/references/official-docs/docs/subsystems/ssh.i18n.yaml +2 -2
  177. package/references/official-docs/docs/subsystems/ssh.md +22 -11
  178. package/references/official-docs/docs/subsystems/ssh.zh.md +22 -11
  179. package/references/official-docs/docs/subsystems/subagent.i18n.yaml +24 -27
  180. package/references/official-docs/docs/subsystems/subagent.md +165 -229
  181. package/references/official-docs/docs/subsystems/subagent.zh.md +167 -233
  182. package/references/official-docs/docs/subsystems/system-prompt.i18n.yaml +2 -2
  183. package/references/official-docs/docs/subsystems/system-prompt.md +32 -2
  184. package/references/official-docs/docs/subsystems/system-prompt.zh.md +32 -2
  185. package/references/official-docs/docs/subsystems/tools.i18n.yaml +2 -2
  186. package/references/official-docs/docs/subsystems/tools.md +3 -3
  187. package/references/official-docs/docs/subsystems/tools.zh.md +3 -3
  188. package/references/official-docs/docs/subsystems/translation.i18n.yaml +19 -0
  189. package/references/official-docs/docs/subsystems/translation.md +103 -0
  190. package/references/official-docs/docs/subsystems/translation.zh.md +103 -0
  191. package/references/official-docs/docs/subsystems/web-server.i18n.yaml +8 -8
  192. package/references/official-docs/docs/subsystems/web-server.md +43 -8
  193. package/references/official-docs/docs/subsystems/web-server.zh.md +43 -8
  194. package/references/official-docs/docs/subsystems/webhook.md +1 -1
  195. package/references/official-docs/docs/subsystems/webhook.zh.md +1 -1
  196. package/references/official-docs/docs/subsystems/workflow.i18n.yaml +2 -2
  197. package/references/official-docs/docs/subsystems/workflow.md +1 -1
  198. package/references/official-docs/docs/subsystems/workflow.zh.md +1 -1
  199. package/references/official-docs/docs/subsystems/working-directory.i18n.yaml +13 -0
  200. package/references/official-docs/docs/subsystems/working-directory.md +64 -0
  201. package/references/official-docs/docs/subsystems/working-directory.zh.md +64 -0
  202. package/references/official-docs/docs/subsystems/workspace.md +2 -2
  203. package/references/official-docs/docs/subsystems/workspace.zh.md +2 -2
  204. package/references/official-docs/docs/subsystems/worktrees.i18n.yaml +13 -0
  205. package/references/official-docs/docs/subsystems/worktrees.md +76 -0
  206. package/references/official-docs/docs/subsystems/worktrees.zh.md +76 -0
  207. package/references/official-docs/docs/testing.i18n.yaml +2 -2
  208. package/references/official-docs/docs/testing.md +1 -1
  209. package/references/official-docs/docs/testing.zh.md +1 -1
  210. package/references/official-docs/docs/tool-catalog.i18n.yaml +57 -45
  211. package/references/official-docs/docs/tool-catalog.md +95 -41
  212. package/references/official-docs/docs/tool-catalog.zh.md +99 -45
  213. package/references/official-docs/docs/upgrade-guide/v0.2.0-rc.2/bundled-python-tests/guide.i18n.yaml +16 -0
  214. package/references/official-docs/docs/upgrade-guide/v0.2.0-rc.2/bundled-python-tests/guide.md +18 -0
  215. package/references/official-docs/docs/upgrade-guide/v0.2.0-rc.2/bundled-python-tests/guide.zh.md +18 -0
  216. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/deepseek-model-discovery/guide.i18n.yaml +16 -0
  217. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/deepseek-model-discovery/guide.md +17 -0
  218. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/deepseek-model-discovery/guide.zh.md +17 -0
  219. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/desktop-test-auth-popup/guide.i18n.yaml +16 -0
  220. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/desktop-test-auth-popup/guide.md +18 -0
  221. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/desktop-test-auth-popup/guide.zh.md +18 -0
  222. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/experimental-package-composition/guide.i18n.yaml +16 -0
  223. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/experimental-package-composition/guide.md +28 -0
  224. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/experimental-package-composition/guide.zh.md +28 -0
  225. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/instruction-home-override/guide.i18n.yaml +16 -0
  226. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/instruction-home-override/guide.md +20 -0
  227. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/instruction-home-override/guide.zh.md +20 -0
  228. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/mock-messages-events/guide.i18n.yaml +16 -0
  229. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/mock-messages-events/guide.md +17 -0
  230. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/mock-messages-events/guide.zh.md +17 -0
  231. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/native-subagent-bundle-tools/guide.i18n.yaml +16 -0
  232. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/native-subagent-bundle-tools/guide.md +31 -0
  233. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/native-subagent-bundle-tools/guide.zh.md +31 -0
  234. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/new-session-generations/guide.i18n.yaml +16 -0
  235. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/new-session-generations/guide.md +20 -0
  236. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/new-session-generations/guide.zh.md +20 -0
  237. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/plugin-option-placement/guide.i18n.yaml +16 -0
  238. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/plugin-option-placement/guide.md +20 -0
  239. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/plugin-option-placement/guide.zh.md +20 -0
  240. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/python-optional-resources/guide.i18n.yaml +16 -0
  241. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/python-optional-resources/guide.md +18 -0
  242. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/python-optional-resources/guide.zh.md +18 -0
  243. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/python-ptc-sandbox/guide.i18n.yaml +16 -0
  244. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/python-ptc-sandbox/guide.md +21 -0
  245. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/python-ptc-sandbox/guide.zh.md +21 -0
  246. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/session-title-adapters/guide.i18n.yaml +16 -0
  247. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/session-title-adapters/guide.md +18 -0
  248. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/session-title-adapters/guide.zh.md +18 -0
  249. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/session-title-provider-strategy/guide.i18n.yaml +16 -0
  250. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/session-title-provider-strategy/guide.md +20 -0
  251. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/session-title-provider-strategy/guide.zh.md +20 -0
  252. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/ssh-helper-launch/guide.i18n.yaml +16 -0
  253. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/ssh-helper-launch/guide.md +19 -0
  254. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/ssh-helper-launch/guide.zh.md +19 -0
  255. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/subagent-activations/guide.i18n.yaml +16 -0
  256. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/subagent-activations/guide.md +59 -0
  257. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/subagent-activations/guide.zh.md +59 -0
  258. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/team-direct-inbox/guide.i18n.yaml +16 -0
  259. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/team-direct-inbox/guide.md +21 -0
  260. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/team-direct-inbox/guide.zh.md +21 -0
  261. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/terminal-command-labels/guide.i18n.yaml +16 -0
  262. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/terminal-command-labels/guide.md +18 -0
  263. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/terminal-command-labels/guide.zh.md +18 -0
  264. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/tool-presentation-mode/guide.i18n.yaml +16 -0
  265. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/tool-presentation-mode/guide.md +21 -0
  266. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/tool-presentation-mode/guide.zh.md +21 -0
  267. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/web-listener-trust-config/guide.i18n.yaml +16 -0
  268. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/web-listener-trust-config/guide.md +36 -0
  269. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/web-listener-trust-config/guide.zh.md +36 -0
  270. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/working-directory/guide.i18n.yaml +16 -0
  271. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/working-directory/guide.md +25 -0
  272. package/references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/working-directory/guide.zh.md +25 -0
  273. package/references/official-docs/docs/user/guide/github-review.i18n.yaml +4 -4
  274. package/references/official-docs/docs/user/guide/github-review.md +7 -10
  275. package/references/official-docs/docs/user/guide/github-review.zh.md +7 -10
  276. package/references/official-docs/docs/user/guide/public-deployments.i18n.yaml +8 -8
  277. package/references/official-docs/docs/user/guide/public-deployments.md +9 -5
  278. package/references/official-docs/docs/user/guide/public-deployments.zh.md +9 -5
  279. package/references/official-docs/packages/README.md +4 -6
  280. package/references/official-docs/website-docs.ts +1 -0
  281. package/references/official-plugin-dev-skill.md +2 -2
  282. package/references/sources.md +2 -1
  283. package/scripts/archive-discussions.ps1 +162 -162
  284. package/scripts/build-llms-full.mjs +8 -0
  285. package/scripts/check-docs-drift.ps1 +55 -55
  286. package/scripts/check-ps1-bom.mjs +68 -0
  287. package/scripts/download-community-articles.ps1 +188 -188
  288. package/scripts/download-community-repos.ps1 +232 -232
  289. package/scripts/download-sources.ps1 +195 -195
  290. package/scripts/gen-topic-snapshot.ps1 +91 -91
  291. package/scripts/install-skill.ps1 +63 -63
  292. package/scripts/sync-official-docs.ps1 +138 -138
  293. package/scripts/verify-artifacts.mjs +26 -0
  294. package/scripts/verify-kit.ps1 +197 -187
  295. package/templates/js/README-es.md +1 -1
  296. package/templates/js/README-hi.md +1 -1
  297. package/templates/js/README-pt.md +1 -1
  298. package/templates/js/README-zh.md +1 -1
  299. package/templates/js/README.md +1 -1
  300. package/templates/ts/README-es.md +1 -1
  301. package/templates/ts/README-hi.md +1 -1
  302. package/templates/ts/README-pt.md +1 -1
  303. package/templates/ts/README-zh.md +1 -1
  304. package/templates/ts/README.md +1 -1
@@ -0,0 +1,260 @@
1
+ # 家族工具链路由(family-toolchain.md)
2
+
3
+ > **这份文件回答**:我的问题该找哪个工具?哪个文档是这项事实的**权威所有者**?
4
+ > 以及 `dsh-plugin-dev check` 的 16 项检查和 `dsh-plugin-doctor` 的 33 项检查是什么关系。
5
+ >
6
+ > **原则**:**一个事实只有一个所有者。** 本知识库只负责"认知 + 索引",
7
+ > 机械检查交给工具;发现重复时**链接**而不是**复述**。
8
+ >
9
+ > **测量时间**:2026-10-13。
10
+
11
+ ---
12
+
13
+ ## 1. 路由表:问题 → 所有者 → 可引用产物
14
+
15
+ | 你的问题 | 权威所有者 | 可引用产物 | 命令 |
16
+ |---|---|---|---|
17
+ | 这个插件包结构对不对? | `dsh-plugin-doctor` | `SPEC.md`(规范)R0–R8 | `npx @perrylink/dsh-plugin-doctor --only R` |
18
+ | 我的 Cordis 用法有没有踩契约? | `dsh-plugin-doctor` | `SPEC.md` §4.2b,K1–K14 | `… --only K` |
19
+ | 装了能不能起来? | `dsh-plugin-doctor` D 组 / `dsh-test-drive` | D0–D3/D9;test-drive 的四态记录 | `… --only D` |
20
+ | 我在各个目录里被收录对了吗? | `dsh-plugin-doctor` CC 组 | CC1–CC5 | `… --only CC` |
21
+ | 我的插件质量几分? | `dsh-score` | 五维评分 + 排行榜 JSON/MD | `dsh-score <repo\|pkg>` |
22
+ | 怎么从旧世代升上来? | `dsh-plugin-upgrade` | 走廊卡(`legAB` 20 seams / `legC` E1–E5) | `dsh-plugin-upgrade-scan` |
23
+ | 共享代码怎么写? | `@perrylink/dsh-plugin-kit` | `data/peer-range.json`、seam/gate 契约、新插件骨架 | — |
24
+ | 社区认证是什么等级? | `dsh-plugin-certification` + `dsh-cert-mcp` | 五维 A–E、等级 A–D、安全否决 | MCP:`get_certification` |
25
+ | 目标宿主这一版有什么? | **本知识库** | [`version-matrix.md`](version-matrix.md) | `dsh --version` |
26
+ | 该改哪一行? | **本知识库** | [`migration-0.2.md`](migration-0.2.md) | — |
27
+ | 官方怎么规定的? | **本知识库镜像** | `references/official-docs/` | — |
28
+
29
+ ---
30
+
31
+ ## 2. `dsh-plugin-doctor`:33 项检查全表
32
+
33
+ 规范来源是 **`SPEC.md`**(spec `v1`,checkset 字符串
34
+ `R0-R8+K1-K14+D0-D3,D9+CC1-CC5/3`),ID 空间**已冻结**(SPEC §3.3)。
35
+ 共 **33** 项 = 9 (R) + 14 (K) + 5 (D) + 5 (CC)。
36
+
37
+ > ⚠️ **不要引用 doctor 的 README 核对检查 ID。** README 在 5 处写 `K1–K9` 和"16 checks",
38
+ > 而规范 `SPEC.md` 定义的是 **K1–K14** 和 **21 项规范门禁**——README 在 K10–K14 落地时没更新。
39
+ > README 内部还自相矛盾(43 / 41 / 37 仓 vs `data/verified-repos.json` 的 40 条)。
40
+
41
+ ### 2.1 裁定词表(SPEC §2,规范,五种)
42
+
43
+ | 裁定 | 含义 |
44
+ |---|---|
45
+ | `pass` | 已评估且成立 |
46
+ | `warn` | 已评估、看似违规,**启发式**,需人工复核,**单独不足以定罪** |
47
+ | `fail` | 已评估且违规 → 计入失败 |
48
+ | `error` | **检查本身无法完成** → 计入失败 |
49
+ | `skip` | **未评估** —— **绝不能渲染成 pass** |
50
+
51
+ 正交分类:`critical`(目前仅 `R1`)与 `category` ∈
52
+ {`plugin-defect`, `policy`, `not-applicable`, `environment`, `infrastructure`, `unsupported-host`, `unstable`}。
53
+ **后四类永远不是插件缺陷**;`policy` 表示这是"家族约定而规范并不共享"(R5、R8)。
54
+
55
+ **降级规则**(SPEC §3.2,规范):被请求的组里**每一项都 `skip`**,则该组"未被评估",
56
+ 不得报告成功;零检查执行、或组名匹配不到任何东西,同样不得报告成功。
57
+ 规范里记了理由:**曾经一个写坏的组名让 35 个仓库的 CI 门禁全绿,而实际什么都没查。**
58
+
59
+ **K 组覆盖模式**(SPEC §3.4,规范披露):`src`(带 `src/` → 完整预期覆盖)·
60
+ `lib-fallback`(无 `src/`,退到 `main` 所在目录 → 真实覆盖但**不等价**,K3–K7 可能少报)·
61
+ `none`(都不存在 → 降级)。
62
+
63
+ ### 2.2 R 组 —— 静态 · 包结构(R0–R8)
64
+
65
+ | ID | 要求 | 裁定 | critical |
66
+ |---|---|---|---|
67
+ | `R0` | 基础清单字段 `name`/`version`/`license`(SPDX)/`type`;仓内有 `README.md` + `LICENSE` | warn · pass | 否 |
68
+ | `R1` | **激活门 `dsh.bundle.patch`** 声明为非空字符串 | fail · pass | **是——唯一 critical** |
69
+ | `R2` | tarball 完整性:`npm pack --dry-run --json --ignore-scripts` 成功;文件表含声明的入口**与** patch 文件且都非空;tarball 名 = name+version | fail · pass · skip | 否 |
70
+ | `R3` | `cordis.patch.yml` 结构(启发式):存在、解析为顶层 YAML **数组**;空数组合法;非空必须含 `- insert:` 与 ≥1 个 `id:`;每个 `name:` 等于或命名空间在包名之下 | skip · fail · pass | 否 |
71
+ | `R4` | 入口契约:`main`/`exports` 入口存在且同时导出 `apply` 与 `name`;`inject` 是字符串字面量数组 | fail · warn · pass · skip | 否 |
72
+ | `R5` | 依赖策略:① 任何位置不许裸 `cordis`/`schemastery`;② 导入的 `@deepseek-ai/cordis` 必须被声明;③ 它必须在 `peerDependencies` **和** `devDependencies`,**绝不** `dependencies`;④ `@deepseek-ai/dsh` 不得是直接 `dependencies` | fail · pass · skip | 否(`policy`) |
73
+ | `R6` | `engines.node` 兼容 `^22.19.0 \|\| >=24.0.0`(只声明 Node 23 会失败) | fail · warn · pass | 否 |
74
+ | `R7` | `files` 白名单已声明且覆盖入口 + patch;需要构建时入口不得指向源码 | fail · pass | 否 |
75
+ | `R8` | 不得有指向已被取代的预发布线的陈旧 peer 范围(`0.1.0-rc.*`、`0.1.1-rc.*`、`0.1.2-alpha.*`、`0.1.3-alpha.*`),也不得有开顶 `>=` 范围 | skip · fail · warn · pass | 否(`policy`;"报告**陈旧**,不是**损坏**") |
76
+
77
+ **规范门禁**(SPEC §1):`R0, R1, R3, R5, R6, R7, R8, K1–K14` = **21 项**,
78
+ 故意排除 R2 和 R4(它们读的是**构建产物**)。
79
+
80
+ ### 2.3 K 组 —— 静态 · Cordis 契约扫描(K1–K14)
81
+
82
+ K1–K9 回答"这个插件自身正确吗";**K10–K14 回答"它会不会干扰别的插件,或被别的插件悄悄吃掉"**。
83
+ 全部为启发式;没有发现源码文件时一律 `skip`。
84
+
85
+ | ID | 含义 | 裁定 |
86
+ |---|---|---|
87
+ | `K1` | 每个 `ctx.<service>` 访问要么是 Context 内建、要么在 `inject` 声明、要么经 `ctx.get(name)` | skip · warn · pass |
88
+ | `K2` | **活数据序列化红线** —— 绝不 `JSON.stringify(ctx…)`、`structuredClone(ctx…)`、`{...ctx…}` | skip · **fail** · pass |
89
+ | `K3` | 定时器/全局监听被 `ctx.effect`(或 `ctx.on`)包裹,或显式自清理 | skip · warn · pass |
90
+ | `K4` | 定义 `Schema` 的文件里不得引入箭头函数 | skip · warn · pass |
91
+ | `K5` | `apply` 返回形态(v4 Effect 契约):disposer 函数、`null`、`undefined`、`Promise<disposer>`、或(异步)可迭代;async `apply` 合法但必须返回 `Promise<disposer>` | skip · warn · pass |
92
+ | `K6` | 每个注入的服务名要么是已知宿主接缝、要么带命名空间(含 `.`)、要么是自己 `provide` 的 | skip · warn · pass |
93
+ | `K7` | 无 v3 遗留 API:`ctx.using/scope/runtime/lifecycle/collect/accept/decline/alias/off/fork`、`ctx.config`、`ctx.start()/stop()`、v3 的 `inject: {required, optional}` | skip · **fail**(硬名单)· warn(软名单)· pass |
94
+ | `K8` | `export const Config` 必须是 Standard Schema 校验器,不是普通对象字面量 | skip · **fail** · pass |
95
+ | `K9` | 对象插件不得设 `name: 'apply'`(框架会把它重置为 `undefined`) | skip · warn · pass |
96
+ | `K10` | 用 `ctx.on(<waterfall 事件>, …)` 注册的监听器必须引用 `next` | skip · warn · pass |
97
+ | `K11` | 注册的工具名不得与宿主内建或保留字 `run_code` 冲突,也不得用 `tools.data.delete(def.name)` + 重新注册的遮蔽写法 | skip · warn · pass |
98
+ | `K12` | 传给 `super(ctx, '<name>')` / `ctx.provide('<name>')` 的键不得等于宿主接缝名 | skip · warn · pass |
99
+ | `K13` | `cordis.patch.yml` 不得带顶层(非 `insert`)且 `id` 属于宿主的行(按 id 定位的 patch **整行替换 config,不做深合并**) | skip · warn · pass |
100
+ | `K14` | **跨仓注入点冲突** —— 任何自有名字(服务键、工具名、命令名、patch `insert` 行 id)都不得与同工作区的兄弟插件仓重复 | skip · warn · pass |
101
+
102
+ **K14 有规范的"守卫感知豁免"**(SPEC §4.2b):在 `package.json` 的
103
+ `dsh-plugin-doctor.crossPlugin.exempt` 或旁挂 `dsh-plugin-doctor.yml` 里声明
104
+ `{kind, name, peer?, guard?}` 列表,`kind` ∈ {`service`, `tool`, `command`, `patch insert id`};
105
+ 被豁免的冲突算 `pass`。工作区里少于两个插件仓时降级为 `skip`——
106
+ 所以随包发布的 CI workflow(不传 `--workspace`)不会因此挂构建。
107
+
108
+ K10/K11/K13 的参照数据取自上游 `docs/event-producer-consumer.md` 的 `@mode` 列、
109
+ 工具目录各节,以及基线 DSH `0.2.0-rc.2` 的 `packages/bundle/base/cordis.patch.yml` 顶层 id。
110
+
111
+ ### 2.4 D 组 —— 动态 · 沙箱冒烟(D0–D3, D9)
112
+
113
+ | ID | 要求 | 裁定 |
114
+ |---|---|---|
115
+ | `D0` | `npm pack --ignore-scripts` 成功;tarball 写进**沙箱**,不是被测仓库 | fail · pass |
116
+ | `D1` | 宿主从 tarball 安装:`dsh plugin --profile headless add <tarball>`(带 `--ignore-scripts`)把包名写进 `dsh.profile.bundles` | skip · fail · pass |
117
+ | `D2` | `dsh --profile headless --dump-config` 输出层标记 `# == <package name>` | skip · fail · pass |
118
+ | `D3` | **无密钥 headless 冒烟(`MISSING_CREDENTIAL` 判据)**:无凭据时以**退出码 1 + `dsh: MISSING_CREDENTIAL`** 结束(有凭据环境下退出 0 也算 pass)。明确致命:`NO_ADAPTER`、`ERR_MODULE_NOT_FOUND`、`SyntaxError`、`TypeError`、`ReferenceError`、`Cannot find module` | skip · fail · pass |
119
+ | `D9` | **沙箱隔离** —— 沙箱被隔离而非删除;运行打印隔离路径;删除是单独显式步骤 | pass · fail |
120
+
121
+ D1 里"不是插件缺陷"的情形:缺 `pnpm`/`npm`(`infrastructure`)、宿主版本装不上(`unsupported-host`)、
122
+ pnpm `ignored-builds` 阻断(`environment`,报为 `skip`)。
123
+
124
+ ### 2.5 CC 组 —— 生态 · 目录收录(CC1–CC5)
125
+
126
+ 渠道数据缺失时一律 `skip`,**永不判失败**。
127
+
128
+ | ID | 要求 | 裁定 |
129
+ |---|---|---|
130
+ | `CC1` | 认证注册表 spec v1:若已收录,条目需带 `grade`、`snapshot` 和五维(`manifest`、`buildHygiene`、`supplyChain`、`releaseIntegrity`、`installSmoke`)的 `evidence`,无 `veto`,且 `installSmoke ≠ install-fail` | skip · warn · pass |
131
+ | `CC2` | `adp-list` 条目:`url`/`name`/`category` 齐备;`category` 在 **23 值枚举**内;`url` 与仓库一致;`description.en` 单行;`tarball` 若存在须是 GitHub Release 上的 `https` `.tgz` | skip · fail · pass |
132
+ | `CC3` | `dsh-catalog` 条目:`npm`/`repo`/`displayName`/`categories`/`summary` 齐备;`repo` 一致;`categories` 非空数组;`summary` ≤1000 字符、不含安装命令文本、且未被截断(须以标点结尾) | skip · fail · pass |
133
+ | `CC4` | `dshWorkshop` 清单:若声明,`lifecycle.activation` 必须是**五个枚举值**之一 | skip · fail · pass |
134
+ | `CC5` | **家族三重门——规范明说"这不是生态标准"**:Apache-2.0 许可、五语 README、三种 seam 角色,由 `dsh-plugin-kit` 校验 CLI 检查。非 PerryLink 工作区报 `skip`(`not-applicable`) | skip · fail · pass |
135
+
136
+ > **CC4 的五个值**(doctor SPEC 断言,但**只有 doctor 的 `SURVEY.md` §1.5 列出了它们**):
137
+ > `immediate`、`hot-reload`、`restart-plugin`、`restart-profile`、`restart-host`;
138
+ > `restartRequired` 判据为 `/^restart-/`。
139
+
140
+ ### 2.6 退出码契约
141
+
142
+ | 码 | 含义 |
143
+ |---|---|
144
+ | `0` | 无 fail/error,且每个被请求的组**真的跑过** |
145
+ | `1` | 存在 fail/error(插件缺陷) |
146
+ | `2` | 用法错误 / 未知组 / 未知选项 |
147
+ | `3` | 基础设施错误 |
148
+ | `4` | 宿主版本不支持,**不是插件裁定** |
149
+ | `5` | 结果不稳定,步骤超时或被杀 |
150
+ | `6` | **降级(degraded)**——被请求的组从未真正运行 |
151
+
152
+ `--allow-degraded` 把 6 降为 0,但 JSON 里 `degraded` 字段仍非空。
153
+ **两道防假绿**:`--only` 组名匹配不到 → 立即 `2`;被请求的组全部 `skip` → `6`。
154
+
155
+ **组别名**:`R` = R0–R8,`K` = K1–K9 *(README)* / **K1–K14** *(SPEC,以此为准)*,
156
+ `D` = D0–D3/D9,`CC` = CC1–CC5。**建议用 ASCII 别名**——
157
+ 一个被双重错误编码的 CJK 组名匹配不到任何东西(这正是 35 仓假绿的成因)。
158
+
159
+ ---
160
+
161
+ ## 3. 六项检查族的交叉对照
162
+
163
+ | 工具 | 检查项 | 层级 | 与本库的关系 |
164
+ |---|---|---|---|
165
+ | `dsh-plugin-dev check`(**本库**) | **16** 项 | 静态 | 每项经 `src/cli/skill-sections.ts` 链回本知识库章节 |
166
+ | `dsh-plugin-doctor` | **33** 项(规范门禁 21) | 静态 + 动态 + 生态 | 超集;R8 与我们的 `manifest-peers` 重叠但**更严**(查开顶区间与陈旧线) |
167
+ | `omdsh-dev/dsh-plugin-check` | **33** 项(README 只列 26) | 静态 | 独立实现,基线停在 0.1.5-rc.1 |
168
+ | `dsh-session-health` | 11 项检测 ID | 静态 | 会话文件层面 |
169
+ | `dsh-security-audit` | 6 个 action | 静态 | 四态诚实模型(skipped/error 永不记为 pass) |
170
+ | `dsh-cert-mcp` / certification | 5 维(A–E) | 生态 | 认证等级 A–D + 安全否决 |
171
+
172
+ ### 3.1 本库 `dsh-plugin-dev check` 的 16 项 ID
173
+
174
+ `patch-valid` · `patch-ids-unique` · `manifest-bundle-patch` · `manifest-main` ·
175
+ `manifest-peers` · `manifest-engines` · `manifest-files` · `manifest-package-manager` ·
176
+ `display-meta` · `readme-five-langs` · `readme-consistency` ·
177
+ `redline-persona-role` · `redline-waterfall-next` · `redline-no-hardcoded-tunables` ·
178
+ `redline-effect-registration` · `redline-async-apply-registration`
179
+
180
+ ### 3.2 与 doctor 的对应关系(谁更严就用谁)
181
+
182
+ | 本库检查 | doctor 对应 | 说明 |
183
+ |---|---|---|
184
+ | `patch-valid` | `R3` | doctor 额外要求 `name:` 命名空间在包名之下 |
185
+ | `patch-ids-unique` | `K13` | doctor 从"重复"扩展到"是否占用宿主 id" |
186
+ | `manifest-bundle-patch` | `R1` | **R1 是唯一 critical**,我们的是普通 fail |
187
+ | `manifest-main` | `R4` | doctor 还查导出是否含 `apply` + `name` |
188
+ | `manifest-peers` | `R5` + `R8` | **doctor 更严**:查裸 `cordis`、查 `dependencies` 误置、查陈旧线与开顶区间 |
189
+ | `manifest-engines` | `R6` | — |
190
+ | `manifest-files` | `R7` | — |
191
+ | `manifest-package-manager` | — | 本库独有 |
192
+ | `display-meta` | — | 本库独有(doctor 无展示元数据检查) |
193
+ | `readme-five-langs` | `CC5`(仅家族内) | doctor 只在 PerryLink 工作区查 |
194
+ | `readme-consistency` | — | 本库独有 |
195
+ | `redline-persona-role` | — | 本库独有 |
196
+ | `redline-waterfall-next` | `K10` | 重叠 |
197
+ | `redline-effect-registration` | `K3` + `K5` | doctor 拆成两项 |
198
+ | `redline-async-apply-registration` | `K5` 部分 | ⚠️ **我们是家族内该缺陷的唯一检测器**——`dsh-plugin-upgrade` 的 `legC` W0 卡明确点名"guide async-apply lint"作为 E2 的预防门。doctor 只查返回形态 |
199
+ | `redline-no-hardcoded-tunables` | `K8` 部分 | doctor 查 `Config` 是否 Standard Schema |
200
+
201
+ > **结论**:**我们的 16 项是 doctor 33 项的子集,但有 5 项 doctor 没有**
202
+ > (`manifest-package-manager`、`display-meta`、`readme-consistency`、
203
+ > `redline-persona-role`、`redline-async-apply-registration`)。
204
+ > 两者**不是替代关系**:本库的检查**每一项都链回可读章节**,doctor 的检查**有裁定语义与退出码契约**。
205
+ > 严肃发布请**两个都跑**。
206
+
207
+ ---
208
+
209
+ ## 4. 规范事实:只认一个所有者
210
+
211
+ | 事实 | 所有者 | 值 |
212
+ |---|---|---|
213
+ | canonical peer 区间 | `dsh-plugin-kit` → `data/peer-range.json` | 六子句(见 [version-matrix.md](version-matrix.md) §4.1) |
214
+ | 家族花名册 | `dsh-plugin-kit` → `data/repos.json` | **95 条**(94 插件 + 1 基建);活跃 87 / 冻结 5 / 退役 3 |
215
+ | 家族检查 ID 空间 | `dsh-plugin-doctor` → `SPEC.md` | 33 项,已冻结 |
216
+ | 认证等级定义 | `dsh-plugin-certification` → README(即规范) | 五维 A–E,等级 A–D |
217
+ | 认证注册表内容 | 同上 → `data/certified.json` | 截至 2026-10-13:**仅 1 条**(`dsh-auto-review`,A 级,快照 2026-09-07) |
218
+ | 已核验仓名单 | `dsh-plugin-doctor` → `data/verified-repos.json` | **40 条** |
219
+ | 升级走廊与 seam | `dsh-plugin-upgrade` | `legAB` 20 seams;`legC` E1–E5 |
220
+ | DSH 版本谱系与 peer 区间选择 | **本知识库** | [`version-matrix.md`](version-matrix.md) |
221
+
222
+ > ⚠️ **花名册计数存在五个互相冲突的说法**,引用前先看日期:
223
+ > `data/repos.json`(2026-10-12)95 条 · certification README 94/86 · doctor README 42/34 ·
224
+ > doctor 自己的表 45 行 · `dsh-catalog` README 自相矛盾(开头 96 / 计数节 42)·
225
+ > `dsh-kit` README "87 活跃 + 5 冻结 = 92"。
226
+ > **以 `data/repos.json` 为准**;本库 `guide/when-to-retire-a-plugin.md` 的
227
+ > "44 仓 / 7 冻结"是 **2026-10-05 那次审计的快照**,测的是不同时点,**不要直接换算**。
228
+
229
+ ---
230
+
231
+ ## 5. 本知识库在家族里的位置
232
+
233
+ ```
234
+ 认知层(读) 机械层(跑)
235
+ ┌──────────────────────┐ ┌──────────────────────────┐
236
+ 官方契约 ──────┤ dsh-plugin-guide │ │ dsh-plugin-doctor │ 33 项,有裁定语义
237
+ + 版本谱系 │ (本库) │ │ dsh-test-drive │ 隔离冒烟
238
+ + 迁移叙事 │ guide/ + references/ │ │ dsh-score │ 五维评分
239
+ + 踩坑档案 │ + dsh-plugin-dev │ │ dsh-cert-mcp │ 认证查询
240
+ │ check(16 项) │ │ dsh-plugin-upgrade │ 走廊扫描
241
+ └──────────────────────┘ └──────────────────────────┘
242
+ ↑ ↑
243
+ 回答"为什么/该改哪" 回答"过没过/几分"
244
+ ```
245
+
246
+ **分工一句话**:本库负责**认知**(为什么、该改哪一行、这一版有什么),
247
+ 工具链负责**判定**(过没过、几分、能不能装)。**两者都链到本库章节**——
248
+ `dsh-plugin-dev check` 经 `src/cli/skill-sections.ts`,
249
+ `dsh-plugin-upgrade` 的 `legC` 卡直接点名本库的 async-apply lint。
250
+
251
+ ---
252
+
253
+ ## 6. 未核事项
254
+
255
+ - `dsh-plugin-doctor` 的 `--dsh` 默认值:README 兼容性单元格写 peer 下界 `0.1.2-rc.1`,
256
+ 用法注释却写 npm latest——**两处冲突**。
257
+ - SPEC checkset 字符串里的 `/3` 含义未确认。
258
+ - CC2 的 23 值 `category` 枚举**家族内无人发布完整列表**(doctor 的 `adp-list` 可导出)。
259
+ - `data/verified.json`(区别于 `verified-repos.json`)当前内容未读。
260
+ - 本表**未执行任何家族工具**;所有行为描述均为**文档化行为**,非实测行为。
package/guide/links.md CHANGED
@@ -44,7 +44,7 @@
44
44
 
45
45
  | 主题 | 本地副本 | GitHub 直链 |
46
46
  |---|---|---|
47
- | 会话格式版本状态(**版本权威**) | `docs/session-format-status.md`(含 `latestFinalizedVersion: 4` / `latestReleasedVersion: 3` 记录) | [blob](https://github.com/deepseek-ai/deepseek-harness/blob/master/docs/session-format-status.md) |
47
+ | 会话格式版本状态(**版本权威**) | `docs/session-format-status.md`(**版本权威**;镜像基线已更新为 `latestReleasedVersion: 4` / `evidenceTag: dsh-v0.2.0-rc.2`) | [blob](https://github.com/deepseek-ai/deepseek-harness/blob/master/docs/session-format-status.md) |
48
48
  | 逐版本迁移指南(**无 index、无入链**,6 篇) | `docs/upgrade-guide/v0.1.7-rc.2/**`、`docs/upgrade-guide/v0.2.0-rc.2/**`(schedule-optional-bundle、transcript-view-legacy-normal、account-sign-in-errors、remove-runtime-invariants、schedule-bundle-retired、subpath-plugin-display-manifest) | [目录](https://github.com/deepseek-ai/deepseek-harness/tree/master/docs/upgrade-guide) |
49
49
  | 持久化类型变更记录(含 V4 声明) | `docs/persistence-changes/**`(`2026-09-16-session-format-v4.md`、`finalized/v4.json`、`historical-formats/v3.md`…) | [目录](https://github.com/deepseek-ai/deepseek-harness/tree/master/docs/persistence-changes) |
50
50
  | 圆角规范 | `docs/ui-radius.md` | [blob](https://github.com/deepseek-ai/deepseek-harness/blob/master/docs/ui-radius.md) |
@@ -77,7 +77,8 @@
77
77
  | [omdsh-dev/plugin-template](https://github.com/omdsh-dev/plugin-template) | 生产级独立插件模板:src 四文件结构 + 7 个开发 skill + 自包含 prepare + 契约文档 |
78
78
  | [omdsh-dev/dsh-plugin-dev](https://github.com/omdsh-dev/dsh-plugin-dev) | 踩坑档案:20 个实测坑 + 环境基线 |
79
79
  | [Opr4Mp3r/deepseek-harness-plugin-from-scratch](https://github.com/Opr4Mp3r/deepseek-harness-plugin-from-scratch) | 代码审计式渐进教程:17 反模式 + 交付检查单 |
80
- | [vlln/plugin-registry](https://github.com/vlln/plugin-registry) | 插件注册中心 + make-dsh-plugin skill + 机制时间线(repository 0809→0811) |
80
+ | [vlln/dsh-skills](https://github.com/vlln/dsh-skills) | ✅ **现行**(`plugin-registry` 于 2026-10-03 归档后的继任者):`make-dsh-plugin` 开发引导 skill + 0.1.6→0.2.0 改名症状表 + 实测踩坑(`gotchas.md`) |
81
+ | ~~[vlln/plugin-registry](https://github.com/vlln/plugin-registry)~~ | ⚠️ **已归档(2026-10-03)**,冻结在 0.1.5 基线。仍可引其 repository-plugin 0809→0811 机制时间线,但**不要再当作活项目** |
81
82
  | [whyihaveyou/dsh-suite](https://github.com/whyihaveyou/dsh-suite) | 双语插件目录 + `npm create dsh-plugin` 脚手架 + 每日兼容性 CI |
82
83
  | [omdsh-dev/dsh-plugin-check](https://github.com/omdsh-dev/dsh-plugin-check) | 插件健康检查:清单协议 / patch 格式 / 构建陷阱 |
83
84
  | [omdsh-dev/dsh-plugin-skills](https://github.com/omdsh-dev/dsh-plugin-skills) | agent 会话内搭建/测试插件的 skill 集 |
@@ -1,7 +1,10 @@
1
1
  # 迁移到 0.2 世代(migration-0.2.md)
2
2
 
3
3
  > **适用对象**:所有针对 DeepSeek Harness `0.1.6-alpha.2` 及更早版本开发的第三方插件(bundle / 纯 cordis 插件 / UI 插件 / MCP 配置包)。
4
- > **基线**:本文件对照 `5badb15009ae1756c3afe0ae0cef1faafc290ccc`(tag `dsh-v0.2.1-alpha.1`,2026-10-03,master 最新)核验;区间起点为 `ddefc45fbc7f8e46dd73185e68295696d1297887`(tag `dsh-v0.1.6-alpha.2`,2026-09-17)。
4
+ > **基线**:本文件对照 `d743267388641bc76f17c45ce8b4c231aed1d32c`(tag `dsh-v0.2.1-alpha.2`,2026-10-09,master HEAD)核验;区间起点为 `ddefc45fbc7f8e46dd73185e68295696d1297887`(tag `dsh-v0.1.6-alpha.2`,2026-09-17)。
5
+ > **覆盖范围**:§0–§12 覆盖 `0.1.6-alpha.2` → `0.2.1-alpha.1`;
6
+ > **§13 覆盖 `0.2.1-alpha.1` → `0.2.1-alpha.2`(19 个 seam,`L1`–`L19`)**。
7
+ > 两段跨度都已有稳定 ID,可被扫描器引用(`dsh-plugin-upgrade` 的走廊目前只到 `legC`)。
5
8
  > **权威优先级**:官方 `docs/upgrade-guide/**`(原文副本 `references/official-docs/docs/upgrade-guide/`)> 本文件 > 社区文章。官方每一条"next release removes X"都对应本文件的一节。
6
9
  > 事实核实方式:源码 `path:line` + 提交号,全部可在 `D:\deepseek-harness`(或你的 checkout)复核;无法核实的项已标注 `UNVERIFIED`。
7
10
 
@@ -13,11 +16,12 @@
13
16
 
14
17
  ## 1. 版本与发布线(先认清"最新"是哪一个)
15
18
 
16
- | 问题 | 答案(2026-10-06 核验) |
19
+ | 问题 | 答案(**2026-10-09 复核**;完整谱系见 [version-matrix.md](version-matrix.md)) |
17
20
  |---|---|
18
- | master 最新 tag | `dsh-v0.2.1-alpha.1`(2026-10-03,`5badb15`) |
21
+ | master 最新 tag | `dsh-v0.2.1-alpha.2`(2026-10-09,`d743267388641bc76f17c45ce8b4c231aed1d32c`;**= master HEAD**) |
19
22
  | npm `latest` dist-tag | `0.2.0-rc.2`(**不是** master 最新 tag) |
20
- | npm `alpha` / `next` | `alpha`=`0.2.1-alpha.1`、`next`=`0.2.0-rc.2` |
23
+ | npm `alpha` / `next` | `alpha`=`0.2.1-alpha.2`、`next`=`0.2.0-rc.2` |
24
+ | 是否存在稳定版 | **否**。全部 31 个 npm 版本都是 `-alpha.N`/`-rc.N`,全部 26 个 GitHub Release 都是 `prerelease: true` |
21
25
  | 区间内发布线(9 个) | `0.1.6-alpha.2`(09-17) → `0.1.7-alpha.1`(09-22) → `0.1.5-rc.3`(09-22) → `0.1.7-alpha.2`(09-22) → `0.1.7-rc.1`(09-23) → `0.1.7-rc.2`(09-24) → `0.2.0-rc.1`(09-28) → `0.2.0-rc.2`(09-29) → `0.2.1-alpha.1`(10-03) |
22
26
  | Node 门槛 | `^22.19.0 \|\| >=24.0.0`,**区间内未变**(无 `.nvmrc`/`.node-version` 文件) |
23
27
  | `dsh.version` 字段 | **不存在**。DSH 的包清单只有 `dsh.bundle` / `dsh.profile` / `dsh.client` 三组键 |
@@ -39,7 +43,7 @@
39
43
  | `SESSION_FORMAT_VERSION`(`c36a83ff6b` = `dsh-v0.1.7-alpha.1` 及之后) | **`4`**(`packages/core/session/src/types.ts`) |
40
44
  | 首次写入 V4 的 tag | `dsh-v0.1.7-alpha.1`(2026-09-22)——**你本机装的 0.1.7-alpha.2 CLI 已经在写 V4** |
41
45
  | 转换包 | `@deepseek-ai/dsh-session-format-v3-to-v4`(npm 自 `0.1.7-alpha.1` 起) |
42
- | 官方 `docs/session-format-status.md` 的记录 | `latestFinalizedVersion: 4` 但 `latestReleasedVersion: 3`(evidenceTag `dsh-v0.1.5-alpha.1`)——**与代码和 npm 不一致**;官方文档自己写明"缺少发布记录不等于未发布",按 **V4 已发布** 处理 |
46
+ | 官方 `docs/session-format-status.md` 的记录 | ✅ **已解决**(2026-10-09 复核):上游已更新为 `latestReleasedVersion: 4` / `evidenceTag: dsh-v0.2.0-rc.2`。本项目镜像快照早于该更正(仍写 `latestReleasedVersion: 3` / `dsh-v0.1.5-alpha.1`),**以官方 live 为准** |
43
47
 
44
48
  对插件作者的后果:
45
49
 
@@ -202,12 +206,64 @@ DSH 自带的 preset 里有一整套**官方插件开发技能**,这是本世
202
206
  - [ ] 若把 patch 拆成多文件:改成 `dsh.bundle.patch` 数组,确认每个文件里的相对路径按各自目录解析。
203
207
  - [ ] 若覆盖 `schedule` / `time-context` / `ui-schedule` / `schedule_*`:按 §6 核对 preset 分叉与 bundle 撤并。
204
208
  - [ ] 依赖里没有 `"latest"` 形式的 `@deepseek-ai/*`(库包 `latest` 仍是 `0.0.1-rc.1`)。
205
- - [ ] peer 范围覆盖两条线(如 `>=0.1.2-rc.1 <0.3.0`),并知道它**不被校验**——关键兼容靠自己探测。
209
+ - [ ] ⚠️ peer 范围覆盖**每条线一个 clause**(六子句规范形,见 [version-matrix.md](version-matrix.md) §4.1),且知道它**会被安装期强制**——不是文档意图:`dsh plugin add` 拿运行时版本比对,不匹配直接**拒绝安装**。**不要写 `>=0.1.2-rc.1 <0.3.0` 这种跨代开区间**:它放行安装,但运行时会炸。范围之外仍要配运行时探测。
206
210
  - [ ] `pnpm pack` 后装进干净 `DSH_HOME` profile 冒烟(`dsh-plugin-dev verify` 已对此对齐)。
207
211
 
208
- ## 12. 已知分歧与未核实项(诚实标注)
212
+ ## 13. 新走廊:`0.2.1-alpha.1` → `0.2.1-alpha.2`(19 个 seam)
213
+
214
+ > **本节解决本文件此前的最大缺口**:`dsh-plugin-upgrade` 的走廊只覆盖到 `legC`(`0.1.5-rc.2 → 0.1.6-alpha.2`),
215
+ > 而本文件此前是 `0.2.1-alpha.1` 之前唯一有内容的文档,且**没有任何 seam ID**——没法被扫描器引用。
216
+ > 本节给该跨度**稳定 ID(`L1`–`L19`)**、**症状**、**修法**与**官方出处**。
217
+ >
218
+ > **适用判定**:`dsh --version` 落在 `0.2.1-alpha.2`(或更新)时,**逐条核对**;
219
+ > 停在 `0.2.0-rc.2` 及更早的**与本节无关**。
220
+ > 官方出处全部已随镜像落地:`references/official-docs/docs/upgrade-guide/v0.2.1-alpha.1/<item>/guide.md`。
221
+ >
222
+ > ⚠️ **目录名陷阱**:`v0.2.1-alpha.1/` 是**变更被引入时仓库的版本号**,描述的是
223
+ > **从该版升到下一版**的变更——即这 19 条**落在 `0.2.1-alpha.2`**。原文措辞是
224
+ > *"In v0.2.1-alpha.1, X was so; the next release no longer…"*。
225
+
226
+ | ID | 官方项 | 受影响面 | 症状(不修的后果) | 修法 |
227
+ |---|---|---|---|---|
228
+ | **L1** | `subagent-activations` | 子代理工具/服务 | `backgroundMode`、`enableRunInBackground`、`run_in_background` 全部失效;`dsh-subagent-in-process-driver` 包**被删**;`ctx.subagents.start()` 不存在 | 删两个配置键与工具参数;`startActivation({ …, delivery: 'caller' })` 后 `await activation.result`;自定义本地 provider 要实现 `prepareContinuable()` |
229
+ | **L2** | `tool-presentation-mode` | 工具呈现 | **`mode: both` 被拒绝**;`DSH_TOOLS_MODE=both` 与 `ctx.tools.presentAs('both')` 同样被拒 | 改为 `native` 或 `ptc` |
230
+ | **L3** | `web-listener-trust-config` | Web profile / 覆盖层 | **`webRuntime` 服务消失** → 注入它的 patch **永久等待**,Connection 起不来;`ctx.webRuntime.lanAddresses` 没了;**通配 host 加载期被拒** | `inject: [webRuntime]` → `[webStartup]`;`trustedHosts` 换服务;删 `lanAddresses`;通配 host 换具体 IP 字面量 |
231
+ | **L4** | `working-directory` | 提示词模板 / ACP·SDK 子代理 / `presentationMeta` | **保留 `{{cwd}}` 的自定义模板在发出模型请求前就失败**;`config.cwd` 被移除;嵌套 PTC 调用里的投影错误会让该次调用以 `ToolOutputError` 失败 | 删提示词里的目录子句并清空;`cwd` 改由子请求传或先调 `working_directory({ cd })`;保证投影纯且 JSON 安全 |
232
+ | **L5** | `session-title-provider-strategy` | 会话标题 | 三个导出符号消失(`registerSessionTitleLlmProvider` / `generateSessionTitleWithLlm` / `SessionTitleLlmMessageSelector`);`targetWords`/`targetCjkCharacters` 移出共享 Config | 改用 `ctx.sessionTitle.register({ id, automatic, generate })`,自己搭 system/input;拒绝 `tool-calls`/`max-tokens` 收尾 |
233
+ | **L6** | `session-title-adapters` | LLM 适配器 | 标题请求改走 `ctx.llm.prepareCall()`;只挂 `llm/stream` 中间件的组合不再被服务;`reasoning.efforts` 顺序错会被拒 | 用 `ctx.llm.registerAdapter()` 注册标题路由;`efforts` **从低到高**排 |
234
+ | **L7** | `ssh-helper-launch` | SSH / 远端 PTC | `node`/`bootstrapPath`/`bootstrapHash` 三键消失;**要求 SSH protocol 2**;helper 与 hash 不同步即失败 | 改 `launch: { kind: 'node-script' }` 或 `{ kind: 'executable' }`;helper 与 hash **必须同改** |
235
+ | **L8** | `team-direct-inbox` | Agent Teams(**数据丢失**) | `send_message` 只回 `{"sent":true}`(无 id、无 queued);`maxPendingMessagesPerMember` 被移除;**未投递的排队消息永不派发** | ⚠️ **升级前**让待发消息跑完;升级后必需的显式重发;改读 `sent` |
236
+ | **L9** | `instruction-home-override` | 指令加载 | `dsh-agent-instructions` 的 `dshHome` 字段被移除,**残留键被静默忽略**(不报错) | 删 `dshHome`;改用进程环境变量 `DSH_HOME`;用 `--dump-config` 复核 |
237
+ | **L10** | `experimental-package-composition` | profile 组合 | CLI 与 Python runtime 的安装依赖**不再含 hook 桥**;**装了不等于挂上**;只"启用"已被删行的 patch **不会把它插回来** | 显式装 peer;选 bundle **先于**覆盖其行;用完整 `insert` 替代对已删行的 override |
238
+ | **L11** | `native-subagent-bundle-tools` | Bundle 元数据(**类型破坏**) | 选中 bundle 会额外注册 Host 全局工具,对最小预设也可见;**构造或严格校验 `BundleInfo` 必须补两个必填字段 `official`/`availability`**,`PluginPackageRef` 同理 | 补必填字段;删同名冗余 Host 行(会被遮蔽) |
239
+ | **L12** | `python-ptc-sandbox` | Python PTC | Python runtime **要求 `sandbox` + `sandboxPolicy` 服务**,默认 `read-only`;受限运行以 `sandbox-unavailable` 失败 | 挂 `dsh-sandbox-local` + `dsh-sandbox-policy`;设 `sandbox-policy` 行的 `mode`/`workspaceRoot` |
240
+ | **L13** | `python-optional-resources` | Python 运行时资源 | wheels **不再内置** Office sidecar 与 authoring 解释器;SDK 启动不再自动下载 | 用前显式 `download_office()` / `download_primary_runtime()`;离线预置 `DSH_RESOURCE_CACHE` |
241
+ | **L14** | `plugin-option-placement` | CLI 调用 | **`dsh plugin add <pkg> --profile <name>` 现在直接失败** | 改为 `dsh plugin --profile <name> add <package>`(`--profile` 必须在转发参数之前) |
242
+ | **L15** | `terminal-command-labels` | 终端 UI 插件(**类型破坏**) | `TerminalBlockLabels` 新增**必填** `commandLine(line: number): string` | 给每个 labels 对象补 `commandLine`,返回本地化名称 |
243
+ | **L16** | `deepseek-model-discovery` | 模型发现 | `deepseek-official` 路由**无 key 时返回空目录** → Desktop/Web 隐藏 DeepSeek 组 | 配 key 或用 `apiKeyEnv`(默认 `DEEPSEEK_API_KEY`)指定的环境变量;消费方要处理空目录 |
244
+ | **L17** | `new-session-generations` | 客户端集成 | 新建会话**同时新建 Agent**,不再复用空会话(改过预设定义后旧会话不会自动跟上) | 改预设后用 New Session;要复用用 `openWorkspace`/`connectWorkspace` |
245
+ | **L18** | `mock-messages-events` | 测试支撑 | `dsh-llm-mock-server` 会在结构化 SSE 负载旁**同时发具名 Messages 事件** | 消费具名事件与其 `data` 字段,别只筛匿名消息 |
246
+ | **L19** | `desktop-test-auth-popup` | Desktop 测试构建 | 所有**测试**认证弹窗默认关闭;测试网关 cookie 不过重启 | 需要时设 `updates.allowTestAuthPopupWindow: true` 并**完全重启** |
247
+
248
+ **另有一条回填**(在 `v0.2.0-rc.2/` 目录里、但基线之后才加入):
249
+ `bundled-python-tests` —— 打包的 NumPy/pandas **测试目录**被移除;要跑上游测试套件请
250
+ **另建** Python 环境(别用会被升级替换的托管运行时目录)。它放在旧目录属于例外——
251
+ 上游自己的规则是"版本号 bump 后旧版本目录冻结"。
252
+
253
+ **官方发布说明**(双语,点名上述变更):
254
+ `https://github.com/deepseek-ai/deepseek-harness/releases/tag/dsh-v0.2.1-alpha.2`。
255
+
256
+ > **本节与 `guide/version-matrix.md` §3 是同一批事实的两种形态**:矩阵按"作者视角的破坏清单"写,
257
+ > 本节按"可被扫描器引用的 seam 表"写(`L1`–`L19` + 症状 + 修法)。
258
+ > **给 `dsh-plugin-upgrade` 提议 `legD` 走廊时,直接引用本节 ID。**
259
+ > 本库的 `dsh-plugin-dev check` 中 `redline-async-apply-registration` 是家族内该缺陷的唯一检测器,
260
+ > 已被 `legC` 的 W0 卡引用为 E2 的预防门——同一条联动可以复用到本节。
209
261
 
210
- 1. **官方会话格式发布记录与代码/npm 矛盾**:`docs/session-format-status.md` 写 `latestReleasedVersion: 3`,而 `SESSION_FORMAT_VERSION` 自 `dsh-v0.1.7-alpha.1` 起为 4 且转换包已上 npm。按 V4 已发布处理(代码与 npm 一致),但记录本身未更新。
262
+ ---
263
+
264
+ ## 14. 已知分歧与未核实项(诚实标注)
265
+
266
+ 1. ✅ **已解决(2026-10-13)**:上游 `docs/session-format-status.md` 已是 `latestReleasedVersion: 4` / `evidenceTag: dsh-v0.2.0-rc.2`,与代码和 npm 一致;本项目 `references/official-docs/` 镜像**已重同步**到 `d743267388641bc76f17c45ce8b4c231aed1d32c`(`dsh-v0.2.1-alpha.2`,2026-10-13),该矛盾在本库内部也一并消失。
211
267
  2. `UNVERIFIED`:未解包已发布的 npm tarball 逐字节确认产物与 tag 一致。
212
268
  3. `UNVERIFIED`:仓库内无 `CHANGELOG.md`、无 `docs/persistence-changes/releases/*` 新条目,因此**没有官方逐版本 release notes 可引**;tag 对应的提交主题是唯一线索。
213
269
  4. `ctx.agent` 在两个基线都**不存在**(不是"被移除")。
@@ -157,16 +157,18 @@ ctx.effect(() => { const t = setInterval(...); return () => clearInterval(t) })
157
157
 
158
158
  ### 3.5 事件(Events)
159
159
 
160
- 派发模式(事件契约的一部分,新事件必须用 `@mode` 标注):
160
+ 派发模式(事件契约的一部分,新事件必须用 `@mode` 标注)。**官方共五种**——
161
+ 权威定义见 `references/official-docs/docs/cordis-api/events.md`(`'emit' | 'parallel' | 'serial' | 'bail' | 'waterfall'`):
161
162
 
162
163
  | 模式 | await? | 顺序 | 返回值 |
163
164
  |---|---|---|---|
164
165
  | `emit` | 否 | 注册序 | 无 |
165
- | `waterfall` | 否 | 注册序 | 有(管线结果) |
166
166
  | `parallel` | 是 | 并行 | 无 |
167
167
  | `serial` | 是 | 注册序 | 有(首个非空即止) |
168
+ | `bail` | 否 | 注册序 | 有(首个非 `null/false/undefined` 即短路,**停止后续**) |
169
+ | `waterfall` | 否 | 注册序 | 有(管线结果,逐级传递) |
168
170
 
169
- - `ctx.bail`:首个非 `null/false/undefined` 结果即短路返回。
171
+ - **`serial` 与 `bail` 的区别是"停不停"**:`serial` 在首个非空值后停止后续监听器;`bail` 同样短路,但语义归类为"放弃/否决",`ctx.bail` 是其对应调用式。二者都**不是** `emit`(`emit` 永远跑完所有监听器)。
170
172
  - **waterfall 铁律**:监听器签名 `(payload, next)`,**必须调 `next()` 才能下传**;不调即短路(这正是拦截/网关的语义)。协作式监听器改共享对象后 `next()`;替换结果的监听器负责让下游只看到替换后的结果。仅在"必须最先执行"时才用 `prepend: true`。
171
173
  - **类型安全**:`declare module '@deepseek-ai/cordis' { interface Events { 'my-plugin/ready': (p: {id: string}) => void } }`。
172
174
  - **命名空间**:`namespace/action`(`agent/step`、`tools/result`、`session/event`……)。
@@ -372,7 +374,7 @@ Hook 的"原生 hook"就是挂在拦截点上的普通 Cordis 插件,不需要
372
374
 
373
375
  ### 7.0 插件形态选型:bundle vs 纯 cordis(两条官方安装通道)
374
376
 
375
- > 时间线(社区实测记录,vlln/plugin-registry):官方 0809 推出 repository-plugin 机制(`.dsh-plugin`),**0811 已从 `vendor/loader/src/repository.ts` 移除**(−258 行,`plugin_search/install/uninstall/status` 四个工具随之不复存在)。此后外部插件只有 web profile 一条官方路径,按是否声明 `dsh.bundle` 分两类。
377
+ > 时间线(社区实测记录,归档仓库 `vlln/plugin-registry`,**该仓 2026-10-03 已归档**,继任者 `vlln/dsh-skills`):官方 0809 推出 repository-plugin 机制(`.dsh-plugin`),**0811 已从 `vendor/loader/src/repository.ts` 移除**(−258 行,`plugin_search/install/uninstall/status` 四个工具随之不复存在)。此后外部插件只有 web profile 一条官方路径,按是否声明 `dsh.bundle` 分两类。
376
378
  > **预览期漂移提示**:官方文档里可能仍有残留旧表述(如 `docs/subsystems/skills.md` 的 "repository plugins land in the global layer"),且服务名在快照间会改名(0812 批量重命名:`httpServer→webServer`、`tasks→jobs`、`bash→shell`、`compact→compaction` 等 17 项)——遇到矛盾以**当前宿主的生成式参考**(subsystems 页 Cordis API 区)与社区事实源(`references/community-repo-deep-dive.md` §1.5)为准。
377
379
 
378
380
  | 需求 | 类型 | 安装通道 | 生效 |
@@ -487,7 +489,7 @@ bundle 挂一个普通 provider 插件:`inject = ['cmdlineArgs']`,用 `@deep
487
489
  - **官方社群**:[Discord](https://discord.gg/Ycq5dCaS4) · [GitHub Discussions](https://github.com/deepseek-ai/deepseek-harness/discussions) · 发布插件时给仓库加 [`dsh-plugin` topic](https://github.com/topics/dsh-plugin) 提升可见度。
488
490
  - **话题清单**:[GitHub topic `dsh-plugin`](https://github.com/topics/dsh-plugin)(三期早期快照 304/550/993 供续期对比;**08-15 第四期快照** `downloads/topic-snapshots/dsh-plugin-topic-2026-08-15/`:去重 998 个、抓取期间 API total_count 2668→2671 持续增长——search API 分页上限 1000 条)。
489
491
  - **精选列表**:[awesome-dsh-plugins](https://github.com/AdamPlatin123/awesome-dsh-plugins)(每日兼容性追踪)、[awesome-deepseek-harness](https://github.com/0xsline/awesome-deepseek-harness)、[Alex-Yanggg/awesome-DSH-plugin](https://github.com/Alex-Yanggg/awesome-DSH-plugin)、[bruc3van/awesome-dsh-plugin](https://github.com/bruc3van/awesome-dsh-plugin);08-14 新增 [walkinglabs](https://github.com/walkinglabs/awesome-deepseek-harness-plugins)、[vvlife](https://github.com/vvlife/awesome-deepseek-harness-plugins) 的 awesome-deepseek-harness-plugins 与 [cccakeee/awesome-dsh-plugins](https://github.com/cccakeee/awesome-dsh-plugins)(完整清单见 community-ecosystem.md §5)。
490
- - **插件注册/分发中心**:[vlln/plugin-registry](https://github.com/vlln/plugin-registry)(薄控制台 + `make-dsh-plugin` skill;注意其记录的机制时间线:repository-plugin 0809 推出、0811 移除)、[omdsh-dev/dsh-hub-workshop](https://github.com/omdsh-dev/dsh-hub-workshop)(插件市场/注册 workshop;dsh-external/hub 08-14 核查已 404);08-14 另出现多个 Web GUI 内插件市场([DSH-Plugins-Marketplace](https://github.com/bradeGithub/DSH-Plugins-Marketplace)、[dsh-plugin-installer](https://github.com/Toukaiteio/dsh-plugin-installer)、[dsh-plugin-marketplace](https://github.com/Scorp1o117/dsh-plugin-marketplace),未深读,信任边界同 dsh-hub-workshop"发现 ≠ 安装权限")。
492
+ - **插件注册/分发中心**:[vlln/dsh-skills](https://github.com/vlln/dsh-skills)(✅ **现行**:`make-dsh-plugin` 开发引导 skill + 0.1.6→0.2.0 改名症状表 + 实测踩坑,基线 0.2.0-rc.2);~~[vlln/plugin-registry](https://github.com/vlln/plugin-registry)~~(⚠️ **2026-10-03 归档**,冻结在 0.1.5 基线;其**机制时间线**仍可引用:repository-plugin 0809 推出、0811 移除)、[omdsh-dev/dsh-hub-workshop](https://github.com/omdsh-dev/dsh-hub-workshop)(插件市场/注册 workshop,`INTAKE.md` 是收录权威;dsh-external/hub 08-14 核查已 404);08-14 另出现多个 Web GUI 内插件市场([DSH-Plugins-Marketplace](https://github.com/bradeGithub/DSH-Plugins-Marketplace)、[dsh-plugin-installer](https://github.com/Toukaiteio/dsh-plugin-installer)、[dsh-plugin-marketplace](https://github.com/Scorp1o117/dsh-plugin-marketplace),未深读,信任边界同 dsh-hub-workshop"发现 ≠ 安装权限")。
491
493
  - **模板与脚手架**:[omdsh-dev/plugin-template](https://github.com/omdsh-dev/plugin-template)(完整生产模板:src 四文件结构 + 7 个开发 skill + tsdown 自包含 prepare + 契约文档 docs/dsh-plugin-contracts.md)、[`npm create dsh-plugin@latest`](https://github.com/whyihaveyou/dsh-suite)(whyihaveyou/dsh-suite 的脚手架,tool/events/webui 三模板)、[omdsh-dev/dsh-plugin-skills](https://github.com/omdsh-dev/dsh-plugin-skills)、[omdsh-dev/dsh-plugin-dev](https://github.com/omdsh-dev/dsh-plugin-dev)(踩坑档案 skill+文档,20 个实测坑)。
492
494
  - **教程与最小模板**:[Opr4Mp3r/deepseek-harness-plugin-from-scratch](https://github.com/Opr4Mp3r/deepseek-harness-plugin-from-scratch)(代码审计式渐进教程:checkpoint + 反模式 17 坑 + 交付检查单,锁 harness@47f9438/npm rc.6)、[randerous/dsh-turn-meta](https://github.com/randerous/dsh-turn-meta)(最小首插件:agent/pre-step + prepend:true + source 归属注入范例)、[omdsh-dev/fabric](https://github.com/omdsh-dev/fabric)(类 MC Fabric 的 hook 处理器)、[omdsh-dev/dsh-plugin-check](https://github.com/omdsh-dev/dsh-plugin-check)(插件健康检查:清单协议/patch 格式/构建陷阱)、[bobleer/deepseek-harness-plugin-mcp](https://github.com/bobleer/deepseek-harness-plugin-mcp)(经 MCP 发现/安装/运行插件)、[Nagi-ovo/dsh-find-plugins](https://github.com/Nagi-ovo/dsh-find-plugins)、[omdsh-dev/dsh-hub-workshop](https://github.com/omdsh-dev/dsh-hub-workshop)(插件市场/注册 workshop)。
493
495
  - **兼容性追踪**:[whyihaveyou/dsh-suite](https://github.com/whyihaveyou/dsh-suite)(双语目录 + 每日兼容性 CI,167+ 插件带 🟢/⚪ 徽章)、[AdamPlatin123/awesome-dsh-plugins](https://github.com/AdamPlatin123/awesome-dsh-plugins)(每日兼容性追踪)。
@@ -503,7 +505,7 @@ bundle 挂一个普通 provider 插件:`inject = ['cmdlineArgs']`,用 `@deep
503
505
 
504
506
  ## 9.1 版本兼容与迁移(0.2 世代必读)
505
507
 
506
- - **先认版本**:`dsh --version`。`0.1.7-alpha.1` 起包含本世代全部破坏性变更(会话格式 V4)。npm 上 `latest`=`0.2.0-rc.2`、`alpha`=`0.2.1-alpha.1`,而 master 最新 tag 是 `0.2.1-alpha.1`——**三个"最新"不是一个东西**。
508
+ - **先认版本**:`dsh --version`,然后读 [version-matrix.md](version-matrix.md)(版本适配矩阵:五个"最新"的区分、子包 `latest` 冻结陷阱、破坏性变更断层、peer 区间选择、会话格式谱系)。`0.1.7-alpha.1` 起包含本世代全部破坏性变更(会话格式 V4)。npm 上 `latest`=`next`=`0.2.0-rc.2`、`alpha`=`0.2.1-alpha.2`,而 master 最新 tag 是 `dsh-v0.2.1-alpha.2`——**这四个"最新"不是同一个东西**;**不存在稳定版**(全部 31 个 npm 版本都是 prerelease)。
507
509
  - **peer 范围要写全两侧的 prerelease 元组**(如 `>=0.1.2-rc.1 <0.2.0 || … || >=0.2.0-0 <0.3.0 || >=0.2.1-0 <0.3.0`)。⚠️ **这个范围会被安装期强制**,不是文档意图:`dsh plugin add` 用运行时版本比对它,不匹配就拒绝安装并打印你声明的范围。所以少一个 0.2.x clause,插件在 0.2.x 宿主上**根本装不上**(拦在安装期,不是运行期)。范围之外仍要靠运行时特性探测——范围只表达"能不能装",表达不了"某个 API 在不在"。
508
510
  - **共享实例的 dsh 包只放 peer + dev**,绝不放 dependencies(否则 profile 内副本会遮蔽运行时版本)。
509
511
  - **升级后必做**:`dsh --profile <name> --dump-config` 看有没有 `patch: entry <id> not found`(上游删行/改名后,你的 override 会**静默失效**);再跑一次真实能力。
@@ -53,7 +53,7 @@ Otras formas: objeto `export default { name, inject, apply }`; clase `class X ex
53
53
 
54
54
  Ciclo de vida: `PENDING → LOADING → ACTIVE` (si apply lanza → FAILED); `ACTIVE → UNLOADING → DISPOSED`. Si un servicio requerido desaparece, el plugin se descarga; se recarga cuando el servicio vuelve.
55
55
 
56
- ## Modos de despacho de eventos + bail
56
+ ## Modos de despacho de eventos (cinco, incluido bail)
57
57
 
58
58
  | Modo | await | Orden | Valor de retorno |
59
59
  |---|---|---|---|
@@ -61,6 +61,7 @@ Ciclo de vida: `PENDING → LOADING → ACTIVE` (si apply lanza → FAILED); `AC
61
61
  | waterfall | no | orden de registro | sí (**no llamar `next()` cortocircuita**) |
62
62
  | parallel | sí | paralelo | ninguno |
63
63
  | serial | sí | orden de registro | sí (el primero no vacío detiene) |
64
+ | bail | no | orden de registro | sí (el primero no null/false/undefined cortocircuita y DETIENE el resto) |
64
65
 
65
66
  Eventos tipados (declaration merging):
66
67
 
@@ -136,7 +137,7 @@ Protocolo de chunks: `block-start` → `text-delta*` → `block-end` (bloque com
136
137
  3. **El mecanismo más débil que baste**: `ctx.tools.restrict()` (solo quita) < `ctx.tools.guard()` (solo deniega) < reescritura por waterfall (depende del orden) < `system-prompt/assemble` (reemplaza todo). Observa resultados finales en `tools/result`; usa `tools/post-execute` solo para transformar.
137
138
  4. Visible-para-el-modelo ⇔ registrado: una nueva entrada visible requiere un nuevo evento de sesión (`SessionEventMap`) — **lo añade el host**, no tú (ver regla 10).
138
139
  5. Nunca codifiques valores ajustables (prueba: ¿puede cambiarlos cordis.yml?); la mala configuración falla en voz alta. Los campos editables en vivo usan `Volatile<T>` + `loader/volatile-update` (el namespace del formulario es el id de la entrada del perfil).
139
- 6. Paquetes de plugin independientes: cordis es peerDependency con la misma identidad del host (mezclar scoped `@deepseek-ai/cordis` y unscoped divide identidades); ESM; manifiesto `dsh.bundle` (`patch` puede ser una lista ordenada); instalaciones git necesitan `prepare` + `allowBuilds`; publica `lib/` o un tarball. Los paquetes dsh de instancia compartida van **solo en peerDependencies + devDependencies**, nunca en `dependencies` (una copia en el perfil ensombrece el runtime en silencio, y DSH **no valida** los rangos de peers).
140
+ 6. Paquetes de plugin independientes: cordis es peerDependency con la misma identidad del host (mezclar scoped `@deepseek-ai/cordis` y unscoped divide identidades); ESM; manifiesto `dsh.bundle` (`patch` puede ser una lista ordenada); instalaciones git necesitan `prepare` + `allowBuilds`; publica `lib/` o un tarball. Los paquetes dsh de instancia compartida van **solo en peerDependencies + devDependencies**, nunca en `dependencies` (una copia en el perfil ensombrece el runtime en silencio). ⚠️ Corregido: **los rangos de peers SÍ se aplican al instalar** — `dsh plugin add` compara la versión del runtime con el rango declarado de `@deepseek-ai/dsh-*` y rechaza la instalación; solo `engines.dsh` es declarativo y no se aplica. Un rango indica "se puede instalar", no "esta API existe": mantén la sonda en runtime (selección de rango: `version-matrix.md` §4).
140
141
  7. Publica metadatos de presentación: `locale/*.json` con `meta.title`/`meta.description` y un `./icon` exportado (SVG/PNG/JPEG/WebP, ≤256 KiB, dentro del paquete). Los plugins de subruta **nunca** leen su propio `package.json`.
141
142
  8. Documentación bilingüe en pares; descripciones/prompts son comportamiento; cambios no triviales llevan Agent Note; ejecuta el conjunto mínimo de checks antes de empujar (dsh-pre-push-checks).
142
143
  9. Los ids opacos entre límites son branded (`Branded<B>` de `dsh-brand`), nunca `string` pelado.
@@ -53,7 +53,7 @@ export function apply(ctx: Context, config: Config) {
53
53
 
54
54
  जीवनचक्र: `PENDING → LOADING → ACTIVE` (apply में त्रुटि → FAILED); `ACTIVE → UNLOADING → DISPOSED`। आवश्यक सेवा गायब होने पर प्लगइन अनलोड होता है; सेवा लौटने पर पुनः लोड होता है।
55
55
 
56
- ## इवेंट डिस्पैच मोड + bail
56
+ ## इवेंट डिस्पैच मोड (पाँच, bail सहित)
57
57
 
58
58
  | मोड | await | क्रम | रिटर्न मान |
59
59
  |---|---|---|---|
@@ -61,6 +61,7 @@ export function apply(ctx: Context, config: Config) {
61
61
  | waterfall | नहीं | पंजीकरण क्रम | हाँ (**`next()` न बुलाना शॉर्ट-सर्किट करता है**) |
62
62
  | parallel | हाँ | समानांतर | कोई नहीं |
63
63
  | serial | हाँ | पंजीकरण क्रम | हाँ (पहला गैर-खाली रुकता है) |
64
+ | bail | नहीं | पंजीकरण क्रम | हाँ (पहला non-null/false/undefined शॉर्ट-सर्किट करता है और बाकी रोक देता है) |
64
65
 
65
66
  टाइप्ड इवेंट (declaration merging):
66
67
 
@@ -136,7 +137,7 @@ Consumer (`dsh-tool-my-cap`): `inject = ['tools','myCap']`, `ctx.tools.register(
136
137
  3. **जो सबसे कमज़ोर mechanism काम करे वही लें**: `ctx.tools.restrict()` (केवल हटाता है) < `ctx.tools.guard()` (केवल मना करता है) < waterfall rewrite (क्रम पर निर्भर) < `system-prompt/assemble` (सब बदल देता है)। अंतिम परिणाम `tools/result` पर देखें; बदलने के लिए ही `tools/post-execute` लें।
137
138
  4. मॉडल-दृश्य ⇔ लॉग: नई मॉडल-दृश्य इनपुट के लिए नया सत्र इवेंट चाहिए (`SessionEventMap`) — **होस्ट जोड़ता है**, आप नहीं (नियम 10 देखें)।
138
139
  5. समायोज्य मान कभी हार्डकोड न करें (कसौटी: क्या cordis.yml इसे बदल सकता है?); गलत कॉन्फ़िग ज़ोर से विफल हो। लाइव-संपादन योग्य फ़ील्ड `Volatile<T>` + `loader/volatile-update` से (फ़ॉर्म namespace = profile entry id)।
139
- 6. स्वतंत्र प्लगइन पैकेज: cordis peerDependency है और होस्ट पहचान से मेल खाना चाहिए (scoped `@deepseek-ai/cordis` और unscoped मिलाना पहचान बाँट देता है); ESM; `dsh.bundle` मैनिफ़ेस्ट (`patch` क्रमबद्ध array हो सकता है); git इंस्टॉल को `prepare` + `allowBuilds` चाहिए; `lib/` या tarball प्रकाशित करें। साझा-इंस्टेंस वाले dsh पैकेज **केवल peerDependencies + devDependencies** में रखें, `dependencies` में कभी नहीं (profile की प्रति runtime को चुपचाप ढक देती है, और DSH peer रेंज **सत्यापित नहीं** करता)।
140
+ 6. स्वतंत्र प्लगइन पैकेज: cordis peerDependency है और होस्ट पहचान से मेल खाना चाहिए (scoped `@deepseek-ai/cordis` और unscoped मिलाना पहचान बाँट देता है); ESM; `dsh.bundle` मैनिफ़ेस्ट (`patch` क्रमबद्ध array हो सकता है); git इंस्टॉल को `prepare` + `allowBuilds` चाहिए; `lib/` या tarball प्रकाशित करें। साझा-इंस्टेंस वाले dsh पैकेज **केवल peerDependencies + devDependencies** में रखें, `dependencies` में कभी नहीं (profile की प्रति runtime को चुपचाप ढक देती है)। ⚠️ सुधार: **peer रेंज इंस्टॉल के समय लागू होती है** — `dsh plugin add` runtime संस्करण की तुलना घोषित `@deepseek-ai/dsh-*` रेंज से करता है और इंस्टॉल अस्वीकार कर देता है; केवल `engines.dsh` घोषणात्मक है और लागू नहीं होता। रेंज बताती है "इंस्टॉल हो सकता है", यह नहीं कि "यह API मौजूद है" — runtime probing रखें (रेंज चयन: `version-matrix.md` §4)।
140
141
  7. प्रदर्शन मेटाडेटा ज़रूर भेजें: `locale/*.json` में `meta.title`/`meta.description` और export किया हुआ `./icon` (SVG/PNG/JPEG/WebP, ≤256 KiB, पैकेज के भीतर)। subpath प्लगइन अपना `package.json` **कभी नहीं** पढ़ते।
141
142
  8. दस्तावेज़ द्विभाषी जोड़ों में; टूल विवरण/प्रॉम्प्ट ही व्यवहार हैं; गैर-तुच्छ बदलाव में Agent Note चाहिए; पुश से पहले न्यूनतम जाँच सेट चलाएँ (dsh-pre-push-checks)।
142
143
  9. सीमाओं के पार अपारदर्शी ids branded होते हैं (`Branded<B>` from `dsh-brand`), कभी भी नंगे `string` नहीं।
@@ -153,7 +154,7 @@ Consumer (`dsh-tool-my-cap`): `inject = ['tools','myCap']`, `ctx.tools.register(
153
154
  - Windows junctions PowerShell `New-Item -ItemType Junction` से; vitest ड्राइव अक्षर बड़ा `C:/`।
154
155
  - `DSH_PERMISSION_MODE=danger-full-access` उच्च जोखिम है (Windows पर सैंडबॉक्स बैकएंड नहीं, अनुमोदन बंद); `~/.dsh/.env` में `DSH_*` स्टार्टअप तोड़ता है।
155
156
  - सत्र फ़ाइलें मल्टी-फ़्रेम zstd हैं: `scanZstdFrames`/`createZstdFrameDecoder` उपयोग करें (`@deepseek-ai/dsh-session-persistence-jsonl/src/zstd.ts`)।
156
- - npm: बिना स्कोप वाला `dsh` असंबंधित node-dsh प्रोजेक्ट (एक shell) है — `@deepseek-ai/dsh` इंस्टॉल करें (`latest`=`next`=0.2.0-rc.2, `alpha`=0.2.1-alpha.1); `@deepseek-ai/dsh-tools`, `@deepseek-ai/dsh-base`, `@deepseek-ai/dsh-headless` और `@deepseek-ai/dsh-session-persistence-jsonl` का `latest` अब भी पुराना है (0.0.1-rc.1), इसलिए `next` (0.2.0-rc.2) या `alpha` (0.2.1-alpha.1) पिन करें; `create-dsh-plugin` latest=0.2.3; `@deepseek-ai/cordis` latest=4.0.4 और नया टैग `dsh-0-2-1-alpha-1`=4.0.5-alpha.1; dsh-core/dsh-sdk अभी भी अप्रकाशित (2026-10-06 को सत्यापित)।
157
+ - npm: बिना स्कोप वाला `dsh` असंबंधित node-dsh प्रोजेक्ट (एक shell) है — `@deepseek-ai/dsh` इंस्टॉल करें (`latest`=`next`=0.2.0-rc.2, `alpha`=0.2.1-alpha.2); `@deepseek-ai/dsh-tools`, `@deepseek-ai/dsh-base`, `@deepseek-ai/dsh-headless` और `@deepseek-ai/dsh-session-persistence-jsonl` का `latest` अब भी पुराना है (0.0.1-rc.1), इसलिए `next` (0.2.0-rc.2) या `alpha` (0.2.1-alpha.1) पिन करें; `create-dsh-plugin` latest=0.2.3; `@deepseek-ai/cordis` latest=4.0.4 और नया टैग `dsh-0-2-1-alpha-1`=4.0.5-alpha.1; dsh-core/dsh-sdk अभी भी अप्रकाशित (2026-10-06 को सत्यापित)।
157
158
  - पथ तुलना से पहले दोनों ओर `resolve()` करें (Windows बैकस्लैश जाल)।
158
159
 
159
160
  ## दस्तावेज़ लिंक
@@ -53,7 +53,7 @@ Other forms: object `export default { name, inject, apply }`; class `class X ext
53
53
 
54
54
  Lifecycle: `PENDING → LOADING → ACTIVE` (apply throws → FAILED); `ACTIVE → UNLOADING → DISPOSED`. A required service disappearing unloads the plugin; it reloads when the service returns.
55
55
 
56
- ## Event dispatch modes + bail
56
+ ## Event dispatch modes (five, including bail)
57
57
 
58
58
  | Mode | awaited | Order | Return value |
59
59
  |---|---|---|---|
@@ -61,6 +61,7 @@ Lifecycle: `PENDING → LOADING → ACTIVE` (apply throws → FAILED); `ACTIVE
61
61
  | waterfall | no | registration order | yes (**not calling next() short-circuits**) |
62
62
  | parallel | yes | parallel | none |
63
63
  | serial | yes | registration order | yes (first non-empty stops) |
64
+ | bail | no | registration order | yes (first non-null/false/undefined short-circuits and stops the rest) |
64
65
 
65
66
  Typed events (declaration merging):
66
67
 
@@ -136,7 +137,7 @@ Chunk protocol: `block-start` → `text-delta*` → `block-end` (complete block)
136
137
  3. Weakest mechanism that suffices: `ctx.tools.restrict()` (remove only) < `ctx.tools.guard()` (deny only) < waterfall rewrite (order-dependent) < `system-prompt/assemble` (replaces everything). Observe final outcomes on `tools/result`; use `tools/post-execute` only to transform.
137
138
  4. Model-visible ⇔ logged: new model-visible input requires a new session event (`SessionEventMap`) — added by the host, never by appending a new `type` yourself (see rule 8).
138
139
  5. Never hardcode tunables (test: can cordis.yml change it?); misconfiguration fails loud. Live-editable user fields use `Volatile<T>` + `loader/volatile-update` (the form namespace is the profile entry id).
139
- 6. Standalone plugin packages: cordis is a peerDependency matching the host identity (mixing scoped `@deepseek-ai/cordis` and unscoped splits identities); ESM; `dsh.bundle` manifest (`patch` may be an ordered array); git installs need `prepare` + `allowBuilds`; ship `lib/` or a tarball. Shared-instance dsh packages go in **peerDependencies + devDependencies only** — never `dependencies` (a profile copy silently shadows the runtime, and DSH does not validate peer ranges).
140
+ 6. Standalone plugin packages: cordis is a peerDependency matching the host identity (mixing scoped `@deepseek-ai/cordis` and unscoped splits identities); ESM; `dsh.bundle` manifest (`patch` may be an ordered array); git installs need `prepare` + `allowBuilds`; ship `lib/` or a tarball. Shared-instance dsh packages go in **peerDependencies + devDependencies only** — never `dependencies` (a profile copy silently shadows the runtime). ⚠️ Corrected: **peer ranges ARE enforced at install time** — `dsh plugin add` compares the runtime version against the declared `@deepseek-ai/dsh-*` range and refuses the install; only `engines.dsh` is declarative and unenforced. A range says "can it install", not "does this API exist" — keep runtime probing (range selection: `version-matrix.md` §4).
140
141
  7. Ship display metadata: `locale/*.json` `meta.title`/`meta.description` plus an exported `./icon` (SVG/PNG/JPEG/WebP, ≤256 KiB, inside the package). Subpath plugins never read their own `package.json`.
141
142
  8. Bilingual docs in pairs; tool descriptions/prompts are behavior; non-trivial changes need an Agent Note; run the minimal check set before pushing (dsh-pre-push-checks).
142
143
  9. Opaque cross-boundary ids are branded (`Branded<B>` from `dsh-brand`), never bare `string`.
@@ -153,7 +154,7 @@ Chunk protocol: `block-start` → `text-delta*` → `block-end` (complete block)
153
154
  - Windows junctions via PowerShell `New-Item -ItemType Junction`; vitest drive letter must be uppercase `C:/`.
154
155
  - `DSH_PERMISSION_MODE=danger-full-access` is high-risk (no sandbox backend on Windows, approvals disabled); `DSH_*` vars in `~/.dsh/.env` break startup.
155
156
  - Session files are multi-frame zstd: use `scanZstdFrames`/`createZstdFrameDecoder` (`@deepseek-ai/dsh-session-persistence-jsonl/src/zstd.ts`).
156
- - npm: unscoped `dsh` is the unrelated node-dsh shell — install `@deepseek-ai/dsh` (`latest`=`next`=0.2.0-rc.2, `alpha`=0.2.1-alpha.1); `@deepseek-ai/dsh-tools`, `@deepseek-ai/dsh-base`, `@deepseek-ai/dsh-headless` and `@deepseek-ai/dsh-session-persistence-jsonl` still ship a stale `latest` (0.0.1-rc.1), so pin `next` (0.2.0-rc.2) or `alpha` (0.2.1-alpha.1); `create-dsh-plugin` latest=0.2.3; `@deepseek-ai/cordis` latest=4.0.4 with a new `dsh-0-2-1-alpha-1` tag at 4.0.5-alpha.1; dsh-core/dsh-sdk still unpublished (verified 2026-10-06).
157
+ - npm: unscoped `dsh` is the unrelated node-dsh shell — install `@deepseek-ai/dsh` (`latest`=`next`=0.2.0-rc.2, `alpha`=0.2.1-alpha.2); `@deepseek-ai/dsh-tools`, `@deepseek-ai/dsh-base`, `@deepseek-ai/dsh-headless` and `@deepseek-ai/dsh-session-persistence-jsonl` still ship a stale `latest` (0.0.1-rc.1), so pin `next` (0.2.0-rc.2) or `alpha` (0.2.1-alpha.1); `create-dsh-plugin` latest=0.2.3; `@deepseek-ai/cordis` latest=4.0.4 with a new `dsh-0-2-1-alpha-1` tag at 4.0.5-alpha.1; dsh-core/dsh-sdk still unpublished (verified 2026-10-06).
157
158
  - `resolve()` both sides before path comparisons (Windows backslash trap).
158
159
 
159
160
  ## Documentation links
@@ -171,8 +172,8 @@ Community dev docs — templates/tutorials/pitfalls, full list in [references/co
171
172
 
172
173
  ## Key source index
173
174
 
174
- - Official docs verbatim: `references/official-docs/docs/**` (369 md pages, all 182 `.zh.md` pairs included); the pages **not on the documentation site** (session-format-status, `upgrade-guide/**`, `persistence-changes/**`, ui-radius, web-styling, module-graph) are listed in [links.md](links.md) §2.1
175
- - Migration checklist: [migration-0.2.md](migration-0.2.md) (every breaking change from 0.1.6-alpha.2 → 0.2.1-alpha.1, with the official upgrade-guide source for each)
175
+ - Official docs verbatim: `references/official-docs/docs/**` (429 md pages, all 212 `.zh.md` pairs included, mirror at `dsh-v0.2.1-alpha.2`); the pages **not on the documentation site** (session-format-status, `upgrade-guide/**`, `persistence-changes/**`, ui-radius, web-styling, module-graph) are listed in [links.md](links.md) §2.1
176
+ - Migration checklist: [migration-0.2.md](migration-0.2.md) — §0–§12 cover every breaking change from `0.1.6-alpha.2` → `0.2.1-alpha.1`, and §13 covers `0.2.1-alpha.1` → `0.2.1-alpha.2` as 19 citable seams (`L1`–`L19`); each entry cites its official upgrade-guide source
176
177
  - The official in-repo plugin-development skill: [references/official-plugin-dev-skill.md](../references/official-plugin-dev-skill.md)
177
178
  - Repo-root constraints: `references/official-docs/AGENTS.md`, `references/official-docs/packages/AGENTS.md`, `references/official-docs/vendor/README.md`; sync state in `references/official-docs/SNAPSHOT.md`
178
179
  - Site crawl HTML: `downloads/web/site/**` (EN+ZH full site) + `downloads/manifest.tsv` (download ledger)