dsh-plugin-guide 0.1.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 (374) hide show
  1. package/LICENSE +202 -0
  2. package/NOTICE.md +26 -0
  3. package/README.es.md +139 -0
  4. package/README.hi.md +138 -0
  5. package/README.md +165 -0
  6. package/README.pt.md +139 -0
  7. package/README.zh-CN.md +164 -0
  8. package/SKILL.md +69 -0
  9. package/cordis.patch.yml +4 -0
  10. package/guide/links.md +92 -0
  11. package/guide/plugin-dev-guide.md +429 -0
  12. package/guide/quick-reference.es.md +176 -0
  13. package/guide/quick-reference.hi.md +176 -0
  14. package/guide/quick-reference.md +176 -0
  15. package/guide/quick-reference.pt.md +176 -0
  16. package/guide/quick-reference.zh-CN.md +175 -0
  17. package/index.js +58 -0
  18. package/package.json +83 -0
  19. package/references/community-ecosystem.md +201 -0
  20. package/references/community-repo-deep-dive.md +695 -0
  21. package/references/cordis-paper-and-community.md +326 -0
  22. package/references/harness-repo.md +654 -0
  23. package/references/official-docs/AGENTS.md +149 -0
  24. package/references/official-docs/BENCHMARK.md +3 -0
  25. package/references/official-docs/CLAUDE.md +1 -0
  26. package/references/official-docs/CONTRIBUTING.i18n.yaml +6 -0
  27. package/references/official-docs/CONTRIBUTING.md +23 -0
  28. package/references/official-docs/CONTRIBUTING.zh.md +23 -0
  29. package/references/official-docs/LICENSE +21 -0
  30. package/references/official-docs/README.i18n.yaml +6 -0
  31. package/references/official-docs/README.md +35 -0
  32. package/references/official-docs/README.zh.md +74 -0
  33. package/references/official-docs/SNAPSHOT.md +16 -0
  34. package/references/official-docs/THIRD_PARTY_NOTICES.md +192 -0
  35. package/references/official-docs/docs/AGENTS.md +75 -0
  36. package/references/official-docs/docs/agent-lifecycle.i18n.yaml +6 -0
  37. package/references/official-docs/docs/agent-lifecycle.md +82 -0
  38. package/references/official-docs/docs/agent-lifecycle.zh.md +84 -0
  39. package/references/official-docs/docs/api-gateway.i18n.yaml +6 -0
  40. package/references/official-docs/docs/api-gateway.md +164 -0
  41. package/references/official-docs/docs/api-gateway.zh.md +164 -0
  42. package/references/official-docs/docs/architecture.i18n.yaml +6 -0
  43. package/references/official-docs/docs/architecture.md +129 -0
  44. package/references/official-docs/docs/architecture.zh.md +133 -0
  45. package/references/official-docs/docs/capability-seams.i18n.yaml +6 -0
  46. package/references/official-docs/docs/capability-seams.md +471 -0
  47. package/references/official-docs/docs/capability-seams.zh.md +473 -0
  48. package/references/official-docs/docs/config-catalog.i18n.yaml +6 -0
  49. package/references/official-docs/docs/config-catalog.md +3151 -0
  50. package/references/official-docs/docs/config-catalog.zh.md +3152 -0
  51. package/references/official-docs/docs/cookbook/adding-a-conversation-node.i18n.yaml +6 -0
  52. package/references/official-docs/docs/cookbook/adding-a-conversation-node.md +233 -0
  53. package/references/official-docs/docs/cookbook/adding-a-conversation-node.zh.md +233 -0
  54. package/references/official-docs/docs/cookbook/adding-a-package.i18n.yaml +6 -0
  55. package/references/official-docs/docs/cookbook/adding-a-package.md +118 -0
  56. package/references/official-docs/docs/cookbook/adding-a-package.zh.md +118 -0
  57. package/references/official-docs/docs/cookbook/adding-a-tool.i18n.yaml +6 -0
  58. package/references/official-docs/docs/cookbook/adding-a-tool.md +94 -0
  59. package/references/official-docs/docs/cookbook/adding-a-tool.zh.md +96 -0
  60. package/references/official-docs/docs/cookbook/adding-a-vendored-package.i18n.yaml +6 -0
  61. package/references/official-docs/docs/cookbook/adding-a-vendored-package.md +59 -0
  62. package/references/official-docs/docs/cookbook/adding-a-vendored-package.zh.md +59 -0
  63. package/references/official-docs/docs/cookbook/adding-an-llm-adapter.i18n.yaml +6 -0
  64. package/references/official-docs/docs/cookbook/adding-an-llm-adapter.md +43 -0
  65. package/references/official-docs/docs/cookbook/adding-an-llm-adapter.zh.md +43 -0
  66. package/references/official-docs/docs/cookbook/extension-cookbook.i18n.yaml +6 -0
  67. package/references/official-docs/docs/cookbook/extension-cookbook.md +129 -0
  68. package/references/official-docs/docs/cookbook/extension-cookbook.zh.md +131 -0
  69. package/references/official-docs/docs/cookbook/maintaining-dsh-code-review.i18n.yaml +6 -0
  70. package/references/official-docs/docs/cookbook/maintaining-dsh-code-review.md +64 -0
  71. package/references/official-docs/docs/cookbook/maintaining-dsh-code-review.zh.md +64 -0
  72. package/references/official-docs/docs/cookbook/responding-to-pr-review-on-a-stack.i18n.yaml +6 -0
  73. package/references/official-docs/docs/cookbook/responding-to-pr-review-on-a-stack.md +32 -0
  74. package/references/official-docs/docs/cookbook/responding-to-pr-review-on-a-stack.zh.md +32 -0
  75. package/references/official-docs/docs/cordis-api/context.i18n.yaml +6 -0
  76. package/references/official-docs/docs/cordis-api/context.md +364 -0
  77. package/references/official-docs/docs/cordis-api/context.zh.md +366 -0
  78. package/references/official-docs/docs/cordis-api/events.i18n.yaml +6 -0
  79. package/references/official-docs/docs/cordis-api/events.md +207 -0
  80. package/references/official-docs/docs/cordis-api/events.zh.md +209 -0
  81. package/references/official-docs/docs/cordis-api/fiber.i18n.yaml +6 -0
  82. package/references/official-docs/docs/cordis-api/fiber.md +375 -0
  83. package/references/official-docs/docs/cordis-api/fiber.zh.md +377 -0
  84. package/references/official-docs/docs/cordis-api/inherited.md +39 -0
  85. package/references/official-docs/docs/cordis-api/registry.i18n.yaml +6 -0
  86. package/references/official-docs/docs/cordis-api/registry.md +152 -0
  87. package/references/official-docs/docs/cordis-api/registry.zh.md +154 -0
  88. package/references/official-docs/docs/cordis-api/service.i18n.yaml +6 -0
  89. package/references/official-docs/docs/cordis-api/service.md +102 -0
  90. package/references/official-docs/docs/cordis-api/service.zh.md +104 -0
  91. package/references/official-docs/docs/cordis-primer.i18n.yaml +6 -0
  92. package/references/official-docs/docs/cordis-primer.md +44 -0
  93. package/references/official-docs/docs/cordis-primer.zh.md +50 -0
  94. package/references/official-docs/docs/cordis-tutorial/01-first-plugin.i18n.yaml +6 -0
  95. package/references/official-docs/docs/cordis-tutorial/01-first-plugin.md +95 -0
  96. package/references/official-docs/docs/cordis-tutorial/01-first-plugin.zh.md +95 -0
  97. package/references/official-docs/docs/cordis-tutorial/02-lifecycle-and-effects.i18n.yaml +6 -0
  98. package/references/official-docs/docs/cordis-tutorial/02-lifecycle-and-effects.md +98 -0
  99. package/references/official-docs/docs/cordis-tutorial/02-lifecycle-and-effects.zh.md +98 -0
  100. package/references/official-docs/docs/cordis-tutorial/03-services.i18n.yaml +6 -0
  101. package/references/official-docs/docs/cordis-tutorial/03-services.md +98 -0
  102. package/references/official-docs/docs/cordis-tutorial/03-services.zh.md +98 -0
  103. package/references/official-docs/docs/cordis-tutorial/04-events.i18n.yaml +6 -0
  104. package/references/official-docs/docs/cordis-tutorial/04-events.md +144 -0
  105. package/references/official-docs/docs/cordis-tutorial/04-events.zh.md +144 -0
  106. package/references/official-docs/docs/cordis-tutorial/05-config.i18n.yaml +6 -0
  107. package/references/official-docs/docs/cordis-tutorial/05-config.md +84 -0
  108. package/references/official-docs/docs/cordis-tutorial/05-config.zh.md +84 -0
  109. package/references/official-docs/docs/cordis-tutorial/06-composition-and-hmr.i18n.yaml +6 -0
  110. package/references/official-docs/docs/cordis-tutorial/06-composition-and-hmr.md +113 -0
  111. package/references/official-docs/docs/cordis-tutorial/06-composition-and-hmr.zh.md +113 -0
  112. package/references/official-docs/docs/cordis-tutorial/07-into-the-harness.i18n.yaml +6 -0
  113. package/references/official-docs/docs/cordis-tutorial/07-into-the-harness.md +107 -0
  114. package/references/official-docs/docs/cordis-tutorial/07-into-the-harness.zh.md +107 -0
  115. package/references/official-docs/docs/cordis-tutorial/index.i18n.yaml +6 -0
  116. package/references/official-docs/docs/cordis-tutorial/index.md +60 -0
  117. package/references/official-docs/docs/cordis-tutorial/index.zh.md +62 -0
  118. package/references/official-docs/docs/defensive-patterns.i18n.yaml +6 -0
  119. package/references/official-docs/docs/defensive-patterns.md +33 -0
  120. package/references/official-docs/docs/defensive-patterns.zh.md +33 -0
  121. package/references/official-docs/docs/development.i18n.yaml +6 -0
  122. package/references/official-docs/docs/development.md +171 -0
  123. package/references/official-docs/docs/development.zh.md +171 -0
  124. package/references/official-docs/docs/event-producer-consumer.i18n.yaml +6 -0
  125. package/references/official-docs/docs/event-producer-consumer.md +76 -0
  126. package/references/official-docs/docs/event-producer-consumer.zh.md +78 -0
  127. package/references/official-docs/docs/glossary.i18n.yaml +6 -0
  128. package/references/official-docs/docs/glossary.md +45 -0
  129. package/references/official-docs/docs/glossary.zh.md +45 -0
  130. package/references/official-docs/docs/graph-atlas.i18n.yaml +6 -0
  131. package/references/official-docs/docs/graph-atlas.md +24 -0
  132. package/references/official-docs/docs/graph-atlas.zh.md +26 -0
  133. package/references/official-docs/docs/i18n/README.i18n.yaml +6 -0
  134. package/references/official-docs/docs/i18n/README.md +60 -0
  135. package/references/official-docs/docs/i18n/README.zh.md +60 -0
  136. package/references/official-docs/docs/i18n/style-samples.md +87 -0
  137. package/references/official-docs/docs/i18n/terminology.md +214 -0
  138. package/references/official-docs/docs/i18n/translation-prompt.md +263 -0
  139. package/references/official-docs/docs/i18n/translation-rules.i18n.yaml +6 -0
  140. package/references/official-docs/docs/i18n/translation-rules.md +69 -0
  141. package/references/official-docs/docs/i18n/translation-rules.zh.md +69 -0
  142. package/references/official-docs/docs/module-graph.i18n.yaml +6 -0
  143. package/references/official-docs/docs/module-graph.md +1638 -0
  144. package/references/official-docs/docs/module-graph.zh.md +1640 -0
  145. package/references/official-docs/docs/persistence-catalog.i18n.yaml +6 -0
  146. package/references/official-docs/docs/persistence-catalog.md +944 -0
  147. package/references/official-docs/docs/persistence-catalog.zh.md +946 -0
  148. package/references/official-docs/docs/postmortem/0001-acp-default-export-drops-inject.i18n.yaml +6 -0
  149. package/references/official-docs/docs/postmortem/0001-acp-default-export-drops-inject.md +113 -0
  150. package/references/official-docs/docs/postmortem/0001-acp-default-export-drops-inject.zh.md +113 -0
  151. package/references/official-docs/docs/postmortem/0002-js-expression-disabled-filesystem-tools.i18n.yaml +6 -0
  152. package/references/official-docs/docs/postmortem/0002-js-expression-disabled-filesystem-tools.md +47 -0
  153. package/references/official-docs/docs/postmortem/0002-js-expression-disabled-filesystem-tools.zh.md +47 -0
  154. package/references/official-docs/docs/postmortem/0003-web-agent-gui-feedback-loop.i18n.yaml +6 -0
  155. package/references/official-docs/docs/postmortem/0003-web-agent-gui-feedback-loop.md +53 -0
  156. package/references/official-docs/docs/postmortem/0003-web-agent-gui-feedback-loop.zh.md +53 -0
  157. package/references/official-docs/docs/postmortem/0004-landlock-partial-notice-misclassified-child-failures.i18n.yaml +6 -0
  158. package/references/official-docs/docs/postmortem/0004-landlock-partial-notice-misclassified-child-failures.md +55 -0
  159. package/references/official-docs/docs/postmortem/0004-landlock-partial-notice-misclassified-child-failures.zh.md +55 -0
  160. package/references/official-docs/docs/postmortem/README.i18n.yaml +6 -0
  161. package/references/official-docs/docs/postmortem/README.md +18 -0
  162. package/references/official-docs/docs/postmortem/README.zh.md +18 -0
  163. package/references/official-docs/docs/rescope.i18n.yaml +6 -0
  164. package/references/official-docs/docs/rescope.md +53 -0
  165. package/references/official-docs/docs/rescope.zh.md +53 -0
  166. package/references/official-docs/docs/subsystems/README.i18n.yaml +6 -0
  167. package/references/official-docs/docs/subsystems/README.md +55 -0
  168. package/references/official-docs/docs/subsystems/README.zh.md +55 -0
  169. package/references/official-docs/docs/subsystems/approval.i18n.yaml +6 -0
  170. package/references/official-docs/docs/subsystems/approval.md +170 -0
  171. package/references/official-docs/docs/subsystems/approval.zh.md +170 -0
  172. package/references/official-docs/docs/subsystems/attachment.i18n.yaml +6 -0
  173. package/references/official-docs/docs/subsystems/attachment.md +115 -0
  174. package/references/official-docs/docs/subsystems/attachment.zh.md +115 -0
  175. package/references/official-docs/docs/subsystems/client-modules.i18n.yaml +6 -0
  176. package/references/official-docs/docs/subsystems/client-modules.md +118 -0
  177. package/references/official-docs/docs/subsystems/client-modules.zh.md +118 -0
  178. package/references/official-docs/docs/subsystems/code-runtime.i18n.yaml +6 -0
  179. package/references/official-docs/docs/subsystems/code-runtime.md +191 -0
  180. package/references/official-docs/docs/subsystems/code-runtime.zh.md +191 -0
  181. package/references/official-docs/docs/subsystems/commands.i18n.yaml +6 -0
  182. package/references/official-docs/docs/subsystems/commands.md +187 -0
  183. package/references/official-docs/docs/subsystems/commands.zh.md +187 -0
  184. package/references/official-docs/docs/subsystems/compaction.i18n.yaml +6 -0
  185. package/references/official-docs/docs/subsystems/compaction.md +238 -0
  186. package/references/official-docs/docs/subsystems/compaction.zh.md +238 -0
  187. package/references/official-docs/docs/subsystems/core.i18n.yaml +6 -0
  188. package/references/official-docs/docs/subsystems/core.md +1070 -0
  189. package/references/official-docs/docs/subsystems/core.zh.md +1078 -0
  190. package/references/official-docs/docs/subsystems/credentials.i18n.yaml +6 -0
  191. package/references/official-docs/docs/subsystems/credentials.md +133 -0
  192. package/references/official-docs/docs/subsystems/credentials.zh.md +133 -0
  193. package/references/official-docs/docs/subsystems/extensions.i18n.yaml +6 -0
  194. package/references/official-docs/docs/subsystems/extensions.md +364 -0
  195. package/references/official-docs/docs/subsystems/extensions.zh.md +364 -0
  196. package/references/official-docs/docs/subsystems/feedback.i18n.yaml +6 -0
  197. package/references/official-docs/docs/subsystems/feedback.md +266 -0
  198. package/references/official-docs/docs/subsystems/feedback.zh.md +266 -0
  199. package/references/official-docs/docs/subsystems/filesystem.i18n.yaml +6 -0
  200. package/references/official-docs/docs/subsystems/filesystem.md +495 -0
  201. package/references/official-docs/docs/subsystems/filesystem.zh.md +495 -0
  202. package/references/official-docs/docs/subsystems/goal.i18n.yaml +6 -0
  203. package/references/official-docs/docs/subsystems/goal.md +277 -0
  204. package/references/official-docs/docs/subsystems/goal.zh.md +277 -0
  205. package/references/official-docs/docs/subsystems/invariants.i18n.yaml +6 -0
  206. package/references/official-docs/docs/subsystems/invariants.md +88 -0
  207. package/references/official-docs/docs/subsystems/invariants.zh.md +88 -0
  208. package/references/official-docs/docs/subsystems/jobs.i18n.yaml +6 -0
  209. package/references/official-docs/docs/subsystems/jobs.md +290 -0
  210. package/references/official-docs/docs/subsystems/jobs.zh.md +290 -0
  211. package/references/official-docs/docs/subsystems/llm-streaming.i18n.yaml +6 -0
  212. package/references/official-docs/docs/subsystems/llm-streaming.md +888 -0
  213. package/references/official-docs/docs/subsystems/llm-streaming.zh.md +894 -0
  214. package/references/official-docs/docs/subsystems/lsp.i18n.yaml +6 -0
  215. package/references/official-docs/docs/subsystems/lsp.md +202 -0
  216. package/references/official-docs/docs/subsystems/lsp.zh.md +202 -0
  217. package/references/official-docs/docs/subsystems/permission-presets.i18n.yaml +6 -0
  218. package/references/official-docs/docs/subsystems/permission-presets.md +131 -0
  219. package/references/official-docs/docs/subsystems/permission-presets.zh.md +131 -0
  220. package/references/official-docs/docs/subsystems/persistence.i18n.yaml +6 -0
  221. package/references/official-docs/docs/subsystems/persistence.md +385 -0
  222. package/references/official-docs/docs/subsystems/persistence.zh.md +385 -0
  223. package/references/official-docs/docs/subsystems/plan.i18n.yaml +6 -0
  224. package/references/official-docs/docs/subsystems/plan.md +87 -0
  225. package/references/official-docs/docs/subsystems/plan.zh.md +87 -0
  226. package/references/official-docs/docs/subsystems/sandbox.i18n.yaml +6 -0
  227. package/references/official-docs/docs/subsystems/sandbox.md +218 -0
  228. package/references/official-docs/docs/subsystems/sandbox.zh.md +218 -0
  229. package/references/official-docs/docs/subsystems/schedule.i18n.yaml +6 -0
  230. package/references/official-docs/docs/subsystems/schedule.md +186 -0
  231. package/references/official-docs/docs/subsystems/schedule.zh.md +186 -0
  232. package/references/official-docs/docs/subsystems/scope.i18n.yaml +6 -0
  233. package/references/official-docs/docs/subsystems/scope.md +59 -0
  234. package/references/official-docs/docs/subsystems/scope.zh.md +59 -0
  235. package/references/official-docs/docs/subsystems/session-projection.i18n.yaml +6 -0
  236. package/references/official-docs/docs/subsystems/session-projection.md +262 -0
  237. package/references/official-docs/docs/subsystems/session-projection.zh.md +262 -0
  238. package/references/official-docs/docs/subsystems/session-query.i18n.yaml +6 -0
  239. package/references/official-docs/docs/subsystems/session-query.md +495 -0
  240. package/references/official-docs/docs/subsystems/session-query.zh.md +495 -0
  241. package/references/official-docs/docs/subsystems/session-reference.i18n.yaml +6 -0
  242. package/references/official-docs/docs/subsystems/session-reference.md +108 -0
  243. package/references/official-docs/docs/subsystems/session-reference.zh.md +108 -0
  244. package/references/official-docs/docs/subsystems/session-telemetry.i18n.yaml +6 -0
  245. package/references/official-docs/docs/subsystems/session-telemetry.md +194 -0
  246. package/references/official-docs/docs/subsystems/session-telemetry.zh.md +194 -0
  247. package/references/official-docs/docs/subsystems/session-title.i18n.yaml +6 -0
  248. package/references/official-docs/docs/subsystems/session-title.md +204 -0
  249. package/references/official-docs/docs/subsystems/session-title.zh.md +204 -0
  250. package/references/official-docs/docs/subsystems/session.i18n.yaml +6 -0
  251. package/references/official-docs/docs/subsystems/session.md +849 -0
  252. package/references/official-docs/docs/subsystems/session.zh.md +851 -0
  253. package/references/official-docs/docs/subsystems/settings.i18n.yaml +6 -0
  254. package/references/official-docs/docs/subsystems/settings.md +310 -0
  255. package/references/official-docs/docs/subsystems/settings.zh.md +310 -0
  256. package/references/official-docs/docs/subsystems/shell.i18n.yaml +6 -0
  257. package/references/official-docs/docs/subsystems/shell.md +303 -0
  258. package/references/official-docs/docs/subsystems/shell.zh.md +303 -0
  259. package/references/official-docs/docs/subsystems/skills.i18n.yaml +6 -0
  260. package/references/official-docs/docs/subsystems/skills.md +331 -0
  261. package/references/official-docs/docs/subsystems/skills.zh.md +331 -0
  262. package/references/official-docs/docs/subsystems/spill.i18n.yaml +6 -0
  263. package/references/official-docs/docs/subsystems/spill.md +117 -0
  264. package/references/official-docs/docs/subsystems/spill.zh.md +117 -0
  265. package/references/official-docs/docs/subsystems/storage.i18n.yaml +6 -0
  266. package/references/official-docs/docs/subsystems/storage.md +229 -0
  267. package/references/official-docs/docs/subsystems/storage.zh.md +229 -0
  268. package/references/official-docs/docs/subsystems/subagent.i18n.yaml +6 -0
  269. package/references/official-docs/docs/subsystems/subagent.md +734 -0
  270. package/references/official-docs/docs/subsystems/subagent.zh.md +736 -0
  271. package/references/official-docs/docs/subsystems/subprocess.i18n.yaml +6 -0
  272. package/references/official-docs/docs/subsystems/subprocess.md +324 -0
  273. package/references/official-docs/docs/subsystems/subprocess.zh.md +324 -0
  274. package/references/official-docs/docs/subsystems/system-prompt.i18n.yaml +6 -0
  275. package/references/official-docs/docs/subsystems/system-prompt.md +207 -0
  276. package/references/official-docs/docs/subsystems/system-prompt.zh.md +207 -0
  277. package/references/official-docs/docs/subsystems/terminal.i18n.yaml +6 -0
  278. package/references/official-docs/docs/subsystems/terminal.md +184 -0
  279. package/references/official-docs/docs/subsystems/terminal.zh.md +184 -0
  280. package/references/official-docs/docs/subsystems/token-meter.i18n.yaml +6 -0
  281. package/references/official-docs/docs/subsystems/token-meter.md +90 -0
  282. package/references/official-docs/docs/subsystems/token-meter.zh.md +90 -0
  283. package/references/official-docs/docs/subsystems/tools.i18n.yaml +6 -0
  284. package/references/official-docs/docs/subsystems/tools.md +720 -0
  285. package/references/official-docs/docs/subsystems/tools.zh.md +720 -0
  286. package/references/official-docs/docs/subsystems/typert.i18n.yaml +6 -0
  287. package/references/official-docs/docs/subsystems/typert.md +336 -0
  288. package/references/official-docs/docs/subsystems/typert.zh.md +336 -0
  289. package/references/official-docs/docs/subsystems/user-questions.i18n.yaml +6 -0
  290. package/references/official-docs/docs/subsystems/user-questions.md +178 -0
  291. package/references/official-docs/docs/subsystems/user-questions.zh.md +178 -0
  292. package/references/official-docs/docs/subsystems/web-server.i18n.yaml +6 -0
  293. package/references/official-docs/docs/subsystems/web-server.md +108 -0
  294. package/references/official-docs/docs/subsystems/web-server.zh.md +108 -0
  295. package/references/official-docs/docs/subsystems/web.i18n.yaml +6 -0
  296. package/references/official-docs/docs/subsystems/web.md +199 -0
  297. package/references/official-docs/docs/subsystems/web.zh.md +199 -0
  298. package/references/official-docs/docs/subsystems/workflow.i18n.yaml +6 -0
  299. package/references/official-docs/docs/subsystems/workflow.md +278 -0
  300. package/references/official-docs/docs/subsystems/workflow.zh.md +278 -0
  301. package/references/official-docs/docs/subsystems/workspace.i18n.yaml +6 -0
  302. package/references/official-docs/docs/subsystems/workspace.md +228 -0
  303. package/references/official-docs/docs/subsystems/workspace.zh.md +228 -0
  304. package/references/official-docs/docs/testing.i18n.yaml +6 -0
  305. package/references/official-docs/docs/testing.md +49 -0
  306. package/references/official-docs/docs/testing.zh.md +49 -0
  307. package/references/official-docs/docs/tool-catalog.i18n.yaml +6 -0
  308. package/references/official-docs/docs/tool-catalog.md +1873 -0
  309. package/references/official-docs/docs/tool-catalog.zh.md +1878 -0
  310. package/references/official-docs/docs/tool-execution-pipeline.i18n.yaml +6 -0
  311. package/references/official-docs/docs/tool-execution-pipeline.md +62 -0
  312. package/references/official-docs/docs/tool-execution-pipeline.zh.md +64 -0
  313. package/references/official-docs/docs/user/develop/basic/config.i18n.yaml +6 -0
  314. package/references/official-docs/docs/user/develop/basic/config.md +106 -0
  315. package/references/official-docs/docs/user/develop/basic/config.zh.md +106 -0
  316. package/references/official-docs/docs/user/develop/basic/index.i18n.yaml +6 -0
  317. package/references/official-docs/docs/user/develop/basic/index.md +144 -0
  318. package/references/official-docs/docs/user/develop/basic/index.zh.md +144 -0
  319. package/references/official-docs/docs/user/develop/basic/publish.i18n.yaml +6 -0
  320. package/references/official-docs/docs/user/develop/basic/publish.md +183 -0
  321. package/references/official-docs/docs/user/develop/basic/publish.zh.md +183 -0
  322. package/references/official-docs/docs/user/develop/basic/tool.i18n.yaml +6 -0
  323. package/references/official-docs/docs/user/develop/basic/tool.md +52 -0
  324. package/references/official-docs/docs/user/develop/basic/tool.zh.md +52 -0
  325. package/references/official-docs/docs/user/develop/framework/events.i18n.yaml +6 -0
  326. package/references/official-docs/docs/user/develop/framework/events.md +143 -0
  327. package/references/official-docs/docs/user/develop/framework/events.zh.md +143 -0
  328. package/references/official-docs/docs/user/develop/framework/index.i18n.yaml +6 -0
  329. package/references/official-docs/docs/user/develop/framework/index.md +137 -0
  330. package/references/official-docs/docs/user/develop/framework/index.zh.md +137 -0
  331. package/references/official-docs/docs/user/develop/framework/service.i18n.yaml +6 -0
  332. package/references/official-docs/docs/user/develop/framework/service.md +148 -0
  333. package/references/official-docs/docs/user/develop/framework/service.zh.md +150 -0
  334. package/references/official-docs/docs/user/develop/practice/index.i18n.yaml +6 -0
  335. package/references/official-docs/docs/user/develop/practice/index.md +155 -0
  336. package/references/official-docs/docs/user/develop/practice/index.zh.md +155 -0
  337. package/references/official-docs/docs/user/develop/practice/llm-adapter.i18n.yaml +6 -0
  338. package/references/official-docs/docs/user/develop/practice/llm-adapter.md +188 -0
  339. package/references/official-docs/docs/user/develop/practice/llm-adapter.zh.md +188 -0
  340. package/references/official-docs/docs/user/guide/index.i18n.yaml +6 -0
  341. package/references/official-docs/docs/user/guide/index.md +30 -0
  342. package/references/official-docs/docs/user/guide/index.zh.md +30 -0
  343. package/references/official-docs/docs/user/guide/providers-custom-form.png +0 -0
  344. package/references/official-docs/docs/user/guide/providers-custom-form.zh.png +0 -0
  345. package/references/official-docs/docs/user/guide/providers-models-page.png +0 -0
  346. package/references/official-docs/docs/user/guide/providers-models-page.zh.png +0 -0
  347. package/references/official-docs/docs/user/guide/providers.i18n.yaml +6 -0
  348. package/references/official-docs/docs/user/guide/providers.md +98 -0
  349. package/references/official-docs/docs/user/guide/providers.zh.md +98 -0
  350. package/references/official-docs/docs/user/guide/python-sdk.i18n.yaml +6 -0
  351. package/references/official-docs/docs/user/guide/python-sdk.md +104 -0
  352. package/references/official-docs/docs/user/guide/python-sdk.zh.md +104 -0
  353. package/references/official-docs/docs/user/index.i18n.yaml +6 -0
  354. package/references/official-docs/docs/user/index.md +11 -0
  355. package/references/official-docs/docs/user/index.zh.md +11 -0
  356. package/references/official-docs/docs/web-styling.i18n.yaml +6 -0
  357. package/references/official-docs/docs/web-styling.md +25 -0
  358. package/references/official-docs/docs/web-styling.zh.md +25 -0
  359. package/references/official-docs/examples/AGENTS.md +20 -0
  360. package/references/official-docs/packages/AGENTS.md +27 -0
  361. package/references/official-docs/packages/README.md +69 -0
  362. package/references/official-docs/vendor/README.md +60 -0
  363. package/references/official-docs/website-docs.ts +524 -0
  364. package/references/sources.md +137 -0
  365. package/references/upstream-cordis.md +594 -0
  366. package/references/website-pages.md +668 -0
  367. package/scripts/archive-discussions.ps1 +154 -0
  368. package/scripts/download-community-articles.ps1 +188 -0
  369. package/scripts/download-community-repos.ps1 +232 -0
  370. package/scripts/download-sources.ps1 +195 -0
  371. package/scripts/gen-topic-snapshot.ps1 +91 -0
  372. package/scripts/install-skill.ps1 +63 -0
  373. package/scripts/sync-official-docs.ps1 +130 -0
  374. package/scripts/verify-kit.ps1 +191 -0
@@ -0,0 +1,209 @@
1
+ <!-- 英文源文件由 scripts/gen-cordis-catalog.ts 生成;本中文文件是通过双语配对维护的经评审对侧。
2
+ 更新时先运行 `pnpm run gen-cordis-catalog` 更新英文,再更新本文件并运行 `pnpm run verify-translation-pairing --write docs/cordis-api/events.md` 重新记录配对。 -->
3
+
4
+ # 事件
5
+
6
+ [English](events.md) | 中文
7
+
8
+ 每个上下文中都混入了事件分发 API。Harness 事件声明及其分发模式会生成到各自所属的[子系统页面](../subsystems/core.md)。
9
+
10
+ ### ctx.parallel(name, ...args)
11
+
12
+ ```ts cordis-catalog
13
+ /**
14
+ * Dispatch an event, running all listeners concurrently.
15
+ *
16
+ * @param name — the event name.
17
+ * @param args — arguments passed to every listener.
18
+ * @returns a promise resolving once every listener has settled.
19
+ */
20
+ parallel<K extends keyof Events>(name: K, ...args: Parameters<Events[K]>): Promise<void>
21
+ parallel<K extends keyof Events>(thisArg: NoInfer<ThisType<Events[K]>>, name: K, ...args: Parameters<Events[K]>): Promise<void>
22
+ ```
23
+
24
+ 分发一个事件,并发运行所有监听器。
25
+
26
+ - `name`:事件名称。
27
+ - `args`:传递给每个监听器的参数。
28
+
29
+ **返回值**:一个 Promise,在所有监听器均已完成后兑现。
30
+
31
+ [源码](../../vendor/cordis/src/events.ts#L44)
32
+
33
+ ### ctx.emit(name, ...args)
34
+
35
+ ```ts cordis-catalog
36
+ /**
37
+ * Dispatch an event synchronously, ignoring listener return values.
38
+ *
39
+ * @param name — the event name.
40
+ * @param args — arguments passed to every listener.
41
+ */
42
+ emit<K extends keyof Events>(name: K, ...args: Parameters<Events[K]>): void
43
+ emit<K extends keyof Events>(thisArg: NoInfer<ThisType<Events[K]>>, name: K, ...args: Parameters<Events[K]>): void
44
+ ```
45
+
46
+ 同步分发一个事件,忽略监听器的返回值。
47
+
48
+ - `name`:事件名称。
49
+ - `args`:传递给每个监听器的参数。
50
+
51
+ [源码](../../vendor/cordis/src/events.ts#L53)
52
+
53
+ ### ctx.serial(name, ...args)
54
+
55
+ ```ts cordis-catalog
56
+ /**
57
+ * Dispatch an event, awaiting listeners in order until one bails.
58
+ *
59
+ * @param name — the event name.
60
+ * @param args — arguments passed to each listener.
61
+ * @returns the first bail value (non-null, non-false, non-undefined), if any.
62
+ */
63
+ serial<K extends keyof Events>(name: K, ...args: Parameters<Events[K]>): Promisify<ReturnType<Events[K]>>
64
+ serial<K extends keyof Events>(thisArg: NoInfer<ThisType<Events[K]>>, name: K, ...args: Parameters<Events[K]>): Promisify<ReturnType<Events[K]>>
65
+ ```
66
+
67
+ 分发一个事件,依次等待各监听器,直到其中一个提前终止分发。
68
+
69
+ - `name`:事件名称。
70
+ - `args`:传递给每个监听器的参数。
71
+
72
+ **返回值**:第一个提前终止值(非 null、非 false 且非 undefined);如果没有,则不返回此类值。
73
+
74
+ [源码](../../vendor/cordis/src/events.ts#L63)
75
+
76
+ ### ctx.bail(name, ...args)
77
+
78
+ ```ts cordis-catalog
79
+ /**
80
+ * Dispatch an event, calling listeners in order until one bails.
81
+ *
82
+ * @param name — the event name.
83
+ * @param args — arguments passed to each listener.
84
+ * @returns the first bail value (non-null, non-false, non-undefined), if any.
85
+ */
86
+ bail<K extends keyof Events>(name: K, ...args: Parameters<Events[K]>): ReturnType<Events[K]>
87
+ bail<K extends keyof Events>(thisArg: NoInfer<ThisType<Events[K]>>, name: K, ...args: Parameters<Events[K]>): ReturnType<Events[K]>
88
+ ```
89
+
90
+ 分发一个事件,依次调用各监听器,直到其中一个提前终止分发。
91
+
92
+ - `name`:事件名称。
93
+ - `args`:传递给每个监听器的参数。
94
+
95
+ **返回值**:第一个提前终止值(非 null、非 false 且非 undefined);如果没有,则不返回此类值。
96
+
97
+ [源码](../../vendor/cordis/src/events.ts#L73)
98
+
99
+ ### ctx.waterfall(name, ...args)
100
+
101
+ ```ts cordis-catalog
102
+ /**
103
+ * Dispatch an event whose last argument is a `next` continuation.
104
+ *
105
+ * Each listener wraps the rest of the chain: calling `next()` invokes the
106
+ * next listener (finally the built-in behavior); not calling it vetoes.
107
+ *
108
+ * @param name — the event name.
109
+ * @param args — listener arguments; the final one is the innermost `next`.
110
+ * @returns the outermost listener's return value.
111
+ */
112
+ waterfall<K extends keyof Events>(name: K, ...args: Parameters<Events[K]>): ReturnType<Events[K]>
113
+ waterfall<K extends keyof Events>(thisArg: NoInfer<ThisType<Events[K]>>, name: K, ...args: Parameters<Events[K]>): ReturnType<Events[K]>
114
+ ```
115
+
116
+ 分发一个事件,其最后一个参数是续接执行的 `next` 回调。
117
+
118
+ 每个监听器都会包装调用链的其余部分:调用 `next()` 会执行下一个监听器,最终执行内置行为;不调用则会否决后续执行。
119
+
120
+ - `name`:事件名称。
121
+ - `args`:监听器参数;最后一个参数是最内层的 `next`。
122
+
123
+ **返回值**:最外层监听器的返回值。
124
+
125
+ [源码](../../vendor/cordis/src/events.ts#L86)
126
+
127
+ ### ctx.on(name, listener, options?)
128
+
129
+ ```ts cordis-catalog
130
+ /**
131
+ * Register an event listener owned by the current fiber.
132
+ *
133
+ * @param name — the event name to listen for.
134
+ * @param listener — called with the dispatch arguments.
135
+ * @param options — listener options; a boolean is shorthand for `prepend`.
136
+ * @returns a disposer removing the listener; `true` if it was still registered.
137
+ */
138
+ on<K extends keyof Events>(name: K, listener: Events[K], options?: boolean | EventOptions): () => boolean
139
+ ```
140
+
141
+ 注册一个归当前 fiber 所有的事件监听器。
142
+
143
+ - `name`:要监听的事件名称。
144
+ - `listener`:使用分发参数调用的监听器。
145
+ - `options`:监听器选项;布尔值可作为 `prepend` 的简写。
146
+
147
+ **返回值**:一个用于移除监听器的资源释放函数;如果调用该函数时监听器仍处于注册状态,则返回 `true`。
148
+
149
+ [源码](../../vendor/cordis/src/events.ts#L97)
150
+
151
+ ### ctx.once(name, listener, options?)
152
+
153
+ ```ts cordis-catalog
154
+ /**
155
+ * Same as `on()`, but the listener disposes itself after its first call.
156
+ *
157
+ * @param name — the event name to listen for.
158
+ * @param listener — called at most once with the dispatch arguments.
159
+ * @param options — listener options; a boolean is shorthand for `prepend`.
160
+ * @returns a disposer removing the listener; `true` if it was still registered.
161
+ */
162
+ once<K extends keyof Events>(name: K, listener: Events[K], options?: boolean | EventOptions): () => boolean
163
+ ```
164
+
165
+ 与 `on()` 相同,但监听器在首次调用后会自行注销。
166
+
167
+ - `name`:要监听的事件名称。
168
+ - `listener`:使用分发参数调用,最多调用一次。
169
+ - `options`:监听器选项;布尔值可作为 `prepend` 的简写。
170
+
171
+ **返回值**:一个用于移除监听器的资源释放函数;如果调用该函数时监听器仍处于注册状态,则返回 `true`。
172
+
173
+ [源码](../../vendor/cordis/src/events.ts#L106)
174
+
175
+ ## EventOptions
176
+
177
+ `ctx.on()` 和 `ctx.once()` 接受的选项。
178
+
179
+ ```ts cordis-catalog
180
+ /** Options accepted by `ctx.on()` and `ctx.once()`. */
181
+ interface EventOptions {
182
+ /** Add the listener before existing listeners for the same event. */
183
+ prepend?: boolean
184
+ /** Receive the event regardless of context filter checks. */
185
+ global?: boolean
186
+ }
187
+ ```
188
+
189
+ [源码](../../vendor/cordis/src/events.ts#L112)
190
+
191
+ ## DispatchMode
192
+
193
+ 事件服务使用的事件分发策略。
194
+
195
+ `emit` 运行同步监听器但不等待它们,`parallel` 同时等待所有监听器,`serial` 依次等待监听器直至其中一个提前终止分发,`bail` 遇到第一个同步提前终止值时停止,`waterfall` 则围绕最终的 `next` 回调组合监听器。
196
+
197
+ ```ts cordis-catalog
198
+ /**
199
+ * Event dispatch strategy used by the event service.
200
+ *
201
+ * `emit` runs synchronous listeners without awaiting them, `parallel` awaits
202
+ * all listeners together, `serial` awaits them in order until one bails,
203
+ * `bail` stops on the first synchronous bail value, and `waterfall` composes
204
+ * listeners around a final `next` callback.
205
+ */
206
+ type DispatchMode = 'emit' | 'parallel' | 'serial' | 'bail' | 'waterfall'
207
+ ```
208
+
209
+ [源码](../../vendor/cordis/src/events.ts#L32)
@@ -0,0 +1,6 @@
1
+ # Bilingual-pair consistency record (docs/i18n/README.md): the git blob hash of each
2
+ # side as of the last confirmed-consistent state. Both languages carry equal authority;
3
+ # after editing either side, bring the other along and re-record with:
4
+ # pnpm run verify-translation-pairing --write docs/cordis-api/fiber.md
5
+ fiber.md: 182b77390b29b8a90504437d0ccc2dfeba23921a
6
+ fiber.zh.md: 9ed3e52618586dc3815b9d913439d11a227fb64b
@@ -0,0 +1,375 @@
1
+ <!-- Generated by scripts/gen-cordis-catalog.ts — do not edit by hand.
2
+ Run `pnpm run gen-cordis-catalog` to regenerate. -->
3
+
4
+ # Fiber
5
+
6
+ A fiber is one loaded plugin instance: its lifecycle state, validated config, and registered effects. `ctx.fiber` is the current fiber, and `ctx.effect()` delegates to it.
7
+
8
+ ### ctx.effect(execute, label?)
9
+
10
+ ```ts cordis-catalog
11
+ /**
12
+ * Register a cleanup-aware effect on this fiber.
13
+ *
14
+ * `execute` runs immediately; the disposers it produces are collected and
15
+ * run (in reverse order) either when the returned disposer is called or
16
+ * when the fiber unloads, whichever comes first. Calling the disposer twice
17
+ * is a no-op. Throws `CordisError('INACTIVE_EFFECT')` if the fiber is
18
+ * already disposed, and `TypeError` if `execute` returns an invalid shape.
19
+ *
20
+ * @param execute — the effect body; see {@link Effect} for accepted shapes.
21
+ * @param label — effect label shown in `getEffects()` diagnostics.
22
+ * @returns a disposer that tears the effect down and settles once done.
23
+ */
24
+ effect(execute: () => SyncEffect, label?: string): Disposable<Promise<void>>
25
+ effect(execute: () => Effect, label?: string): AsyncDisposable<Promise<void>>
26
+ ```
27
+
28
+ Register a cleanup-aware effect on this fiber.
29
+
30
+ `execute` runs immediately; the disposers it produces are collected and run (in reverse order) either when the returned disposer is called or when the fiber unloads, whichever comes first. Calling the disposer twice is a no-op. Throws `CordisError('INACTIVE_EFFECT')` if the fiber is already disposed, and `TypeError` if `execute` returns an invalid shape.
31
+
32
+ - `execute` — the effect body; see `Effect` for accepted shapes.
33
+ - `label` — effect label shown in `getEffects()` diagnostics.
34
+
35
+ **Returns** a disposer that tears the effect down and settles once done.
36
+
37
+ [Source](../../vendor/cordis/src/fiber.ts#L415)
38
+
39
+ ### ctx.fiber
40
+
41
+ ```ts cordis-catalog
42
+ /** The fiber (plugin runtime instance) that owns this context. */
43
+ fiber: Fiber
44
+ ```
45
+
46
+ The fiber (plugin runtime instance) that owns this context.
47
+
48
+ [Source](../../vendor/cordis/src/fiber.ts#L12)
49
+
50
+ ## The Fiber class
51
+
52
+ Runtime instance of one plugin application.
53
+
54
+ A fiber tracks dependency state, validated config, lifecycle effects, and cleanup for the plugin context returned by `ctx.plugin()`.
55
+
56
+ [Source](../../vendor/cordis/src/fiber.ts#L184)
57
+
58
+ ### fiber.uid
59
+
60
+ ```ts cordis-catalog
61
+ /** Unique id within the registry; 0 for the root fiber, `null` once disposed. */
62
+ public uid: number | null
63
+ ```
64
+
65
+ Unique id within the registry; 0 for the root fiber, `null` once disposed.
66
+
67
+ [Source](../../vendor/cordis/src/fiber.ts#L186)
68
+
69
+ ### fiber.ctx
70
+
71
+ ```ts cordis-catalog
72
+ /** The context this fiber's plugin runs in (extends the parent context). */
73
+ public readonly ctx: Context
74
+ ```
75
+
76
+ The context this fiber's plugin runs in (extends the parent context).
77
+
78
+ [Source](../../vendor/cordis/src/fiber.ts#L188)
79
+
80
+ ### fiber.config
81
+
82
+ ```ts cordis-catalog
83
+ /** The validated plugin config (updated by `update()`). */
84
+ public config: any
85
+ ```
86
+
87
+ The validated plugin config (updated by `update()`).
88
+
89
+ [Source](../../vendor/cordis/src/fiber.ts#L190)
90
+
91
+ ### fiber.state
92
+
93
+ ```ts cordis-catalog
94
+ /** Current lifecycle state; transitions emit `internal/status`. */
95
+ public state
96
+ ```
97
+
98
+ Current lifecycle state; transitions emit `internal/status`.
99
+
100
+ [Source](../../vendor/cordis/src/fiber.ts#L194)
101
+
102
+ ### fiber.dispose
103
+
104
+ ```ts cordis-catalog
105
+ /** Dispose this fiber: unload the plugin, then settle once cleanup finished. */
106
+ public readonly dispose: () => Promise<void>
107
+ ```
108
+
109
+ Dispose this fiber: unload the plugin, then settle once cleanup finished.
110
+
111
+ [Source](../../vendor/cordis/src/fiber.ts#L196)
112
+
113
+ ### fiber.store
114
+
115
+ ```ts cordis-catalog
116
+ /** Snapshot of required service implementations while loaded; `undefined` otherwise. */
117
+ public store: Dict<Impl> | undefined
118
+ ```
119
+
120
+ Snapshot of required service implementations while loaded; `undefined` otherwise.
121
+
122
+ [Source](../../vendor/cordis/src/fiber.ts#L198)
123
+
124
+ ### fiber.inertia
125
+
126
+ ```ts cordis-catalog
127
+ /** The in-flight load/unload transition, if one is currently running. */
128
+ public inertia: Promise<void> | undefined
129
+ ```
130
+
131
+ The in-flight load/unload transition, if one is currently running.
132
+
133
+ [Source](../../vendor/cordis/src/fiber.ts#L200)
134
+
135
+ ### fiber.name
136
+
137
+ ```ts cordis-catalog
138
+ /** The plugin's display name, inherited from the nearest named ancestor, else `'root'`. */
139
+ get name()
140
+ ```
141
+
142
+ The plugin's display name, inherited from the nearest named ancestor, else `'root'`.
143
+
144
+ [Source](../../vendor/cordis/src/fiber.ts#L336)
145
+
146
+ ### fiber.assertActive()
147
+
148
+ ```ts cordis-catalog
149
+ /**
150
+ * Throw if the fiber has already been disposed.
151
+ *
152
+ * @returns nothing when the fiber is still active.
153
+ * @throws {CordisError} `INACTIVE_EFFECT` when the fiber's uid has been cleared.
154
+ */
155
+ assertActive()
156
+ ```
157
+
158
+ Throw if the fiber has already been disposed.
159
+
160
+ **Returns** nothing when the fiber is still active.
161
+
162
+ [Source](../../vendor/cordis/src/fiber.ts#L351)
163
+
164
+ ### fiber.effect(execute, label?)
165
+
166
+ ```ts cordis-catalog
167
+ /**
168
+ * Register a cleanup-aware effect on this fiber.
169
+ *
170
+ * `execute` runs immediately; the disposers it produces are collected and
171
+ * run (in reverse order) either when the returned disposer is called or
172
+ * when the fiber unloads, whichever comes first. Calling the disposer twice
173
+ * is a no-op. Throws `CordisError('INACTIVE_EFFECT')` if the fiber is
174
+ * already disposed, and `TypeError` if `execute` returns an invalid shape.
175
+ *
176
+ * @param execute — the effect body; see {@link Effect} for accepted shapes.
177
+ * @param label — effect label shown in `getEffects()` diagnostics.
178
+ * @returns a disposer that tears the effect down and settles once done.
179
+ */
180
+ effect(execute: () => SyncEffect, label?: string): Disposable<Promise<void>>
181
+ effect(execute: () => Effect, label?: string): AsyncDisposable<Promise<void>>
182
+ ```
183
+
184
+ Register a cleanup-aware effect on this fiber.
185
+
186
+ `execute` runs immediately; the disposers it produces are collected and run (in reverse order) either when the returned disposer is called or when the fiber unloads, whichever comes first. Calling the disposer twice is a no-op. Throws `CordisError('INACTIVE_EFFECT')` if the fiber is already disposed, and `TypeError` if `execute` returns an invalid shape.
187
+
188
+ - `execute` — the effect body; see `Effect` for accepted shapes.
189
+ - `label` — effect label shown in `getEffects()` diagnostics.
190
+
191
+ **Returns** a disposer that tears the effect down and settles once done.
192
+
193
+ [Source](../../vendor/cordis/src/fiber.ts#L415)
194
+
195
+ ### fiber.getEffects()
196
+
197
+ ```ts cordis-catalog
198
+ /**
199
+ * Return metadata for currently registered effects.
200
+ *
201
+ * @returns one {@link EffectMeta} tree per labeled live effect.
202
+ */
203
+ getEffects()
204
+ ```
205
+
206
+ Return metadata for currently registered effects.
207
+
208
+ **Returns** one `EffectMeta` tree per labeled live effect.
209
+
210
+ [Source](../../vendor/cordis/src/fiber.ts#L568)
211
+
212
+ ### fiber.await()
213
+
214
+ ```ts cordis-catalog
215
+ /**
216
+ * Wait for current lifecycle work and rethrow startup errors.
217
+ *
218
+ * @returns this fiber, once it has settled into a stable state.
219
+ * @throws the config-validation or plugin-startup error, if any.
220
+ */
221
+ async await()
222
+ ```
223
+
224
+ Wait for current lifecycle work and rethrow startup errors.
225
+
226
+ **Returns** this fiber, once it has settled into a stable state.
227
+
228
+ [Source](../../vendor/cordis/src/fiber.ts#L704)
229
+
230
+ ### fiber.restart()
231
+
232
+ ```ts cordis-catalog
233
+ /**
234
+ * Dispose and immediately reload this plugin with its current config.
235
+ *
236
+ * @returns a promise resolving once the reload settled.
237
+ * @throws {CordisError} `INACTIVE_EFFECT` when the fiber is already disposed.
238
+ */
239
+ async restart()
240
+ ```
241
+
242
+ Dispose and immediately reload this plugin with its current config.
243
+
244
+ **Returns** a promise resolving once the reload settled.
245
+
246
+ [Source](../../vendor/cordis/src/fiber.ts#L718)
247
+
248
+ ### fiber.update(config, noSave?)
249
+
250
+ ```ts cordis-catalog
251
+ /**
252
+ * Validate and apply new config, then restart the plugin.
253
+ *
254
+ * Runs the `internal/update` waterfall first, so update hooks (and HMR)
255
+ * can veto or replace the restart.
256
+ *
257
+ * @param config — the new raw config; validated before anything restarts.
258
+ * @param noSave — hint for persistence hooks not to write the change back.
259
+ * @returns the update waterfall result; the default restart returns a promise.
260
+ * @throws when validation, an update listener, or the restarted plugin fails.
261
+ */
262
+ update(config: any, noSave = false)
263
+ ```
264
+
265
+ Validate and apply new config, then restart the plugin.
266
+
267
+ Runs the `internal/update` waterfall first, so update hooks (and HMR) can veto or replace the restart.
268
+
269
+ - `config` — the new raw config; validated before anything restarts.
270
+ - `noSave` — hint for persistence hooks not to write the change back.
271
+
272
+ **Returns** the update waterfall result; the default restart returns a promise.
273
+
274
+ [Source](../../vendor/cordis/src/fiber.ts#L736)
275
+
276
+ ## Effect
277
+
278
+ Effect body result accepted by `ctx.effect()` and plugin startup.
279
+
280
+ Either a single disposer, a promise of one, or a (possibly async) iterable yielding several — generator effects register each yielded disposer as it is produced.
281
+
282
+ ```ts cordis-catalog
283
+ /**
284
+ * Effect body result accepted by `ctx.effect()` and plugin startup.
285
+ *
286
+ * Either a single disposer, a promise of one, or a (possibly async) iterable
287
+ * yielding several — generator effects register each yielded disposer as it
288
+ * is produced.
289
+ */
290
+ type Effect<T = any> =
291
+ | SyncEffect<T>
292
+ | AsyncEffect<T>
293
+ ```
294
+
295
+ [Source](../../vendor/cordis/src/fiber.ts#L83)
296
+
297
+ ## Disposable
298
+
299
+ Function returned by an effect to release resources during disposal.
300
+
301
+ Disposers run in reverse registration order when the owning fiber unloads; they may be async, in which case unloading awaits them.
302
+
303
+ ```ts cordis-catalog
304
+ /**
305
+ * Function returned by an effect to release resources during disposal.
306
+ *
307
+ * Disposers run in reverse registration order when the owning fiber unloads;
308
+ * they may be async, in which case unloading awaits them.
309
+ */
310
+ type Disposable<T = any> = () => T
311
+ ```
312
+
313
+ [Source](../../vendor/cordis/src/fiber.ts#L74)
314
+
315
+ ## EffectMeta
316
+
317
+ Tree node used to expose nested effect labels for diagnostics.
318
+
319
+ ```ts cordis-catalog
320
+ /** Tree node used to expose nested effect labels for diagnostics. */
321
+ interface EffectMeta {
322
+ /** Human-readable effect label, e.g. `ctx.on("event")` or `ctx.provide("name")`. */
323
+ label: string
324
+ /** Metadata of nested effects registered while this effect ran. */
325
+ children: EffectMeta[]
326
+ }
327
+ ```
328
+
329
+ [Source](../../vendor/cordis/src/fiber.ts#L96)
330
+
331
+ ## CordisError
332
+
333
+ Framework error with a stable machine-readable code.
334
+
335
+ ```ts cordis-catalog
336
+ /** Framework error with a stable machine-readable code. */
337
+ class CordisError extends Error {
338
+ /**
339
+ * @param code — the stable error code; also the default message.
340
+ * @param message — optional human-readable override.
341
+ */
342
+ constructor(public code: CordisError.Code, message?: string)
343
+ }
344
+
345
+ /** Cordis error code definitions. */
346
+ namespace CordisError {
347
+ export type Code = keyof typeof Code
348
+
349
+ export const Code = {
350
+ INACTIVE_EFFECT: 'cannot create effect on inactive context',
351
+ } as const
352
+ }
353
+ ```
354
+
355
+ [Source](../../vendor/cordis/src/fiber.ts#L157)
356
+
357
+ ## ValidationError
358
+
359
+ Error raised when plugin configuration fails standard-schema validation.
360
+
361
+ ```ts cordis-catalog
362
+ /** Error raised when plugin configuration fails standard-schema validation. */
363
+ class ValidationError extends TypeError {
364
+ name = 'ValidationError'
365
+
366
+ /**
367
+ * Build the aggregated message from schema issues.
368
+ *
369
+ * @param issues — the standard-schema issues, one message line each.
370
+ */
371
+ constructor(issues: readonly StandardSchemaV1.Issue[])
372
+ }
373
+ ```
374
+
375
+ [Source](../../vendor/cordis/src/fiber.ts#L19)