dsh-plugin-tool-management 0.7.0 → 0.8.5

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 (37) hide show
  1. package/CHANGELOG.md +75 -0
  2. package/README.md +19 -5
  3. package/README_EN.md +19 -5
  4. package/docs/images/1/345/234/272/346/231/257.png +0 -0
  5. package/docs/images/1/345/234/272/346/231/257_en.png +0 -0
  6. package/docs/images/2MCP.png +0 -0
  7. package/docs/images/2MCP_en.png +0 -0
  8. package/docs/images/3/346/212/200/350/203/275.png +0 -0
  9. package/docs/images/3/346/212/200/350/203/275_en.png +0 -0
  10. package/docs/images/4/345/255/220/346/231/272/350/203/275/344/275/223.png +0 -0
  11. package/docs/images/4/345/255/220/346/231/272/350/203/275/344/275/223_en.png +0 -0
  12. package/docs/images/5/346/217/220/347/244/272/350/257/215.png +0 -0
  13. package/docs/images/5/346/217/220/347/244/272/350/257/215_en.png +0 -0
  14. package/docs/images/6/350/256/260/345/277/206.png +0 -0
  15. package/docs/images/6/350/256/260/345/277/206_en.png +0 -0
  16. package/docs/images/7/344/274/232/350/257/235.png +0 -0
  17. package/docs/images/7/344/274/232/350/257/235_en.png +0 -0
  18. package/docs/images/8/345/205/274/345/256/271.png +0 -0
  19. package/docs/images/8/345/205/274/345/256/271_en.png +0 -0
  20. package/docs/update.md +31 -0
  21. package/lib/agents-md/service.js +41 -3
  22. package/lib/client.js +913 -415
  23. package/lib/compat/preset-reach.js +1 -1
  24. package/lib/compat/probe.js +12 -2
  25. package/lib/index.js +651 -31
  26. package/lib/mcp/state-section.js +90 -0
  27. package/lib/prompt-sections.js +148 -0
  28. package/lib/rules/archive-engine.js +151 -30
  29. package/lib/rules/archive.js +78 -28
  30. package/lib/rules/service.js +273 -41
  31. package/lib/skills/core.js +36 -1
  32. package/lib/skills/service.js +36 -10
  33. package/lib/subagents/catalog.js +90 -0
  34. package/lib/subagents/service.js +187 -20
  35. package/lib/subagents/tools.js +10 -3
  36. package/package.json +97 -97
  37. package/lib/rules/provider.js +0 -121
@@ -5,7 +5,7 @@
5
5
  *
6
6
  * WHY THIS EXISTS
7
7
  * ---------------
8
- * `rules/provider.ts` registers a per-agent `systemPrompt` section, and the
8
+ * `prompt-sections.ts` registers a per-agent `systemPrompt` section, and the
9
9
  * registration SUCCEEDS under every preset. But `@deepseek-ai/dsh-persona`
10
10
  * with `complete: true` makes the prompt registry restore its prefix as the
11
11
  * ONLY section at assembly time, so the section never reaches the model — and
@@ -41,10 +41,20 @@ export const IDENTITY_PACKAGES = [
41
41
  '@deepseek-ai/dsh-storage-domain',
42
42
  '@deepseek-ai/dsh-spill-local',
43
43
  ];
44
- /** Peers this plugin was written and verified against. */
45
- export const EXPECTED_PEER_RANGE = '>=0.1.5-rc.2 <0.2.0-0';
44
+ /** Peers this plugin was written and verified against(只声明最低版本,无上界)。 */
45
+ export const EXPECTED_PEER_RANGE = '>=0.1.5-rc.2';
46
46
  /** The release this plugin's adapters were last verified against. */
47
47
  export const VERIFIED_HOST_VERSION = '0.1.5-rc.2';
48
+ /**
49
+ * peer range 的下界 —— 界面展示用。
50
+ *
51
+ * 刻意不带 semver 上界:官方持续发版,硬上界会在宿主跨 minor 升级时直接挡住
52
+ * 插件安装(pnpm peer 校验失败)。上界改为由**运行时能力探测**兜底 ——
53
+ * 宿主版本高于已验证范围时,`assessHost` 会逐项探测并把缺失能力降级/禁用,
54
+ * 而不是在安装期拒绝整包。展示时只应把「最低要求版本」当事实。
55
+ * 从 EXPECTED_PEER_RANGE 派生,避免两处手写漂移。
56
+ */
57
+ export const EXPECTED_MIN_HOST_VERSION = EXPECTED_PEER_RANGE.match(/^>=\s*([^\s]+)/)?.[1] ?? VERIFIED_HOST_VERSION;
48
58
  const isFn = (value) => typeof value === 'function';
49
59
  /** Resolve a package the way this plugin resolves it, without throwing. */
50
60
  function safeResolve(specifier) {