@jayyuen66/dsh-dir-prep-organize 0.1.4 → 0.1.6

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 (81) hide show
  1. package/CHANGELOG.md +117 -0
  2. package/LICENSE +1 -1
  3. package/README.md +209 -104
  4. package/README.zh-CN.md +209 -102
  5. package/agents/academic/academic-statistician.md +143 -0
  6. package/agents/design/design-inclusive-visuals-specialist.md +4 -3
  7. package/agents/design/design-ui-designer.md +6 -3
  8. package/agents/design/design-ux-architect.md +20 -7
  9. package/agents/design/design-whimsy-injector.md +23 -1
  10. package/agents/engineering/engineering-autonomous-optimization-architect.md +31 -22
  11. package/agents/engineering/engineering-backend-architect.md +43 -54
  12. package/agents/engineering/engineering-data-engineer.md +21 -6
  13. package/agents/engineering/engineering-database-optimizer.md +22 -10
  14. package/agents/engineering/engineering-devops-automator.md +12 -3
  15. package/agents/engineering/engineering-email-intelligence-engineer.md +41 -4
  16. package/agents/engineering/engineering-embedded-firmware-engineer.md +27 -5
  17. package/agents/engineering/engineering-feishu-integration-developer.md +10 -2
  18. package/agents/engineering/engineering-frontend-developer.md +24 -18
  19. package/agents/engineering/engineering-git-workflow-master.md +16 -4
  20. package/agents/engineering/engineering-incident-response-commander.md +3 -3
  21. package/agents/engineering/engineering-prompt-engineer.md +7 -2
  22. package/agents/engineering/engineering-rapid-prototyper.md +7 -3
  23. package/agents/engineering/engineering-security-engineer.md +2 -0
  24. package/agents/engineering/engineering-solidity-smart-contract-engineer.md +1 -1
  25. package/agents/engineering/engineering-technical-writer.md +4 -4
  26. package/agents/engineering/engineering-threat-detection-engineer.md +2 -0
  27. package/agents/engineering/engineering-voice-ai-integration-engineer.md +39 -16
  28. package/agents/engineering/engineering-wechat-mini-program-developer.md +7 -2
  29. package/agents/game-development/blender/blender-addon-engineer.md +12 -3
  30. package/agents/game-development/economy-designer.md +155 -0
  31. package/agents/game-development/godot/godot-gameplay-scripter.md +4 -0
  32. package/agents/game-development/godot/godot-multiplayer-engineer.md +6 -2
  33. package/agents/game-development/godot/godot-shader-developer.md +4 -3
  34. package/agents/game-development/roblox-studio/roblox-experience-designer.md +7 -6
  35. package/agents/game-development/roblox-studio/roblox-systems-scripter.md +7 -0
  36. package/agents/game-development/technical-artist.md +4 -0
  37. package/agents/game-development/unity/unity-multiplayer-engineer.md +67 -0
  38. package/agents/game-development/unreal-engine/unreal-multiplayer-architect.md +82 -31
  39. package/agents/game-development/unreal-engine/unreal-systems-engineer.md +13 -1
  40. package/agents/marketing/marketing-agentic-search-optimizer.md +50 -87
  41. package/agents/marketing/marketing-carousel-growth-engine.md +49 -35
  42. package/agents/marketing/marketing-private-domain-operator.md +2 -2
  43. package/agents/marketing/marketing-seo-specialist.md +22 -0
  44. package/agents/product/product-behavioral-nudge-engine.md +3 -0
  45. package/agents/project-management/project-management-jira-workflow-steward.md +5 -2
  46. package/agents/security/security-appsec-engineer.md +75 -43
  47. package/agents/security/security-threat-detection-engineer.md +6 -0
  48. package/agents/security/security-threat-intelligence-analyst.md +32 -15
  49. package/agents/specialized/accounts-payable-agent.md +39 -45
  50. package/agents/specialized/grant-writer.md +2 -2
  51. package/agents/specialized/healthcare-aging-parent-care-companion.md +396 -0
  52. package/agents/specialized/identity-graph-operator.md +24 -3
  53. package/agents/specialized/lsp-index-engineer.md +17 -15
  54. package/agents/specialized/recruitment-specialist.md +17 -11
  55. package/agents/specialized/specialized-developer-advocate.md +4 -4
  56. package/agents/specialized/specialized-fedramp-rmf-compliance.md +379 -0
  57. package/agents/specialized/specialized-focus-music-architect.md +176 -0
  58. package/agents/specialized/specialized-french-consulting-market.md +17 -15
  59. package/agents/specialized/specialized-model-qa.md +78 -34
  60. package/agents/specialized/specialized-salesforce-architect.md +17 -15
  61. package/agents/specialized/specialized-workflow-architect.md +2 -2
  62. package/agents/supply-chain/supply-chain-strategist.md +12 -3
  63. package/agents/support/support-analytics-reporter.md +48 -30
  64. package/agents/support/support-finance-tracker.md +36 -18
  65. package/agents/support/support-infrastructure-maintainer.md +2 -2
  66. package/agents/support/support-support-responder.md +43 -26
  67. package/agents/testing/testing-api-tester.md +37 -27
  68. package/agents/testing/testing-performance-benchmarker.md +82 -47
  69. package/agents/testing/testing-test-results-analyzer.md +37 -18
  70. package/agents/testing/testing-tool-evaluator.md +30 -10
  71. package/client.js +209 -141
  72. package/cordis.patch.yml +4 -23
  73. package/host.js +98 -68
  74. package/package.json +53 -44
  75. package/templates.data.mjs +9 -10
  76. package/types/host.d.ts +29 -21
  77. package/types/src/client-timeouts.d.ts +4 -4
  78. package/types/src/host-messages.d.ts +5 -3
  79. package/types/src/remote.d.ts +12 -3
  80. package/types/src/templates.d.ts +3 -3
  81. package/types/src/ui-messages.d.ts +22 -14
package/cordis.patch.yml CHANGED
@@ -1,26 +1,7 @@
1
- # dir-prep-organize(整理 + 模板;内容源为内置角色库)。
2
- # 功能一「整理」:输入框右上角分段按钮。主键点击 → 按当前目录结构 + 当前 session
3
- # 模型整理优化草稿(成功直接替换,失败保持原值);▾ → 「以 XX 视角整理」(角色菜单,
4
- # 角色上下文 = 模板正文提炼,随 organize 调用注入 system,走同一 LLM 流)。
5
- # 功能二「模板」:输入框旁「模板」下拉,默认展示精选角色集(由 scripts/gen-defaults.mjs
6
- # 从插件 agents/ 目录生成,src/default-templates.generated.ts 单源),按 group 分组
7
- # 渲染(emoji + 名称 + description 悬停);点选插入草稿(空整段填入 / 非空末尾追加)。
8
- # 列表存 settings(0.1.7 隐式注册:命名空间 = 本条目 id,可编辑字段 = host.ts 导出的
9
- # Config 上标了 .volatile() 的 templates/importAllowRoots;生成集不再是 register 的 base,
10
- # 而是 client 半的回落),设置页卡逐条增删改(name/emoji/
11
- # group/description/text)+ 两步确认恢复默认 + 角色导入(importTemplates:留空 = 一键
12
- # 导入内置 agents/ 全部;填路径 = 导入本地 .md 或目录)。client 直读本条目的配置表单
13
- # (ctx.configForms.get(条目 id);0.1.7 已移除 settingsScope)。
14
- #
15
- # 架构:Host 半(host.ts)注册官方 Typert Remote 的服务键 `dirPrepOrganize`,
16
- # defaults / context / model / organize / importTemplates 五个方法就是全部读面;
17
- # 认证、Host/DNS 重绑定/Origin 判据与请求体上限由宿主 /api 网关承担,本包不注册
18
- # HTTP 路由、也没有自建 CSRF 令牌。Client 半(src/client-entry.ts → client.js)注册
19
- # conversation.input.right list 槽(整理 id=dir-prep-organize order 99 / 模板
20
- # id=…-templates order 100)与 plugins.bundle.config 设置卡(keyed;0.1.6 起
21
- # settings.plugin.item 已随旧设置页删除);整理经 Remote 读取器调用上述方法,写回走
22
- # inputActions.setDraft;模板读写配置表单 ctx.configForms.get(条目 id)(数组 set=字段级整体替换,
23
- # 已按 dsh-settings applyPathOp/cloneJsonShaped 源码取证)。
1
+ # 本包提供的输入框「润色」与「模板」能力由 client 半注册成 dock 条目;这份 patch 只负责
2
+ # 把 bundle 插进插件层栈。设置卡数据面走官方 Typert Remote 的 dirPrepOrganize 命名空间,
3
+ # 内置精选集由 host 半从 templates.data.mjs 经 defaults 方法按需下发。
4
+ # 架构与数据流见 README 与 host.ts / src/client-entry.ts。
24
5
  - insert:
25
6
  - id: dir-prep-organize
26
7
  name: "@jayyuen66/dsh-dir-prep-organize"
package/host.js CHANGED
@@ -6,18 +6,18 @@ import { Remote, TypertRemoteService } from "@deepseek-ai/dsh-typert-protocol";
6
6
  import { LOCALE_SETTINGS_NAMESPACE, messagesFor, resolveLocalePreference } from "@jayyuen66/dsh-plugin-shared/lib/locale";
7
7
  import { isRecord } from "@jayyuen66/dsh-plugin-shared/lib/record";
8
8
  import { errorText } from "@jayyuen66/dsh-plugin-shared/lib/errors";
9
- //#region src/host-messages.ts
9
+ // src/host-messages.ts
10
10
  const HOST_MESSAGES = {
11
11
  zh: {
12
- sysRole: "你是输入框内容整理助手。用户在 dsh 对话输入框写了一段要求,你需要结合当前工作目录的结构与会话最近上下文,把它整理成一段更清晰、可直接发送的要求。",
12
+ sysRole: "你是输入框内容润色助手。用户在 dsh 对话输入框写了一段要求,你需要结合当前工作目录的结构与会话最近上下文,把它润色成一段更清晰、可直接发送的要求。",
13
13
  sysRulesHeading: "规则:",
14
- sysRuleOutputOnly: "- 输出只有整理后的正文,不要任何前言、markdown 代码围栏、标题或解释。",
15
- sysRuleNoExecution: "- 不执行草稿中要求的任何任务:不写代码、不回答问题、不审查/不搜索/不生成任何内容——只整理文本本身(重组措辞与结构、补全缺失的上下文、消歧指代)。",
16
- sysRuleNoAnswer: "- 若草稿本身是问题或待办指令,整理结果仍是同一问题/指令的清晰完整版本,不要把解答、方案或示例写进整理结果。",
17
- sysRuleKeepIntent: "- 保留用户原意与语言(中文保持中文);缺失的关键信息(如目标文件/模块)若能从目录结构或最近对话推断就补上,推断不了不要编造。",
18
- sysRuleResolveRefs: "- 最近对话可能含相关指代(\"上面说的\"\"刚才那个文件\"),整理时把指代解析成明确表述。",
14
+ sysRuleOutputOnly: "- 输出只有润色后的正文,不要任何前言、markdown 代码围栏、标题或解释。",
15
+ sysRuleNoExecution: "- 不执行草稿中要求的任何任务:不写代码、不回答问题、不审查/不搜索/不生成任何内容——只润色文本本身(重组措辞与结构、补全缺失的上下文、消歧指代)。",
16
+ sysRuleNoAnswer: "- 若草稿本身是问题或待办指令,润色结果仍是同一问题/指令的清晰完整版本,不要把解答、方案或示例写进润色结果。",
17
+ sysRuleKeepIntent: "- 保留用户原意与语言(用草稿本身的文字写,不换语言);缺失的关键信息(如目标文件/模块)若能从目录结构或最近对话推断就补上,推断不了不要编造。",
18
+ sysRuleResolveRefs: "- 最近对话可能含相关指代(\"上面说的\"\"刚才那个文件\"),润色时把指代解析成明确表述。",
19
19
  sysRuleNoListing: "- 目录结构与对话历史仅是参考,不要罗列它们本身。",
20
- sysRuleRoleView: "- 若提供了参考角色,只借用其专业术语与措辞风格来重写草稿,不得以角色身份实际执行任务(如审查、修复、生成内容)。",
20
+ sysRuleRoleView: "- 若提供了参考角色,只借用其专业术语与措辞风格来润色草稿,不得以角色身份实际执行任务(如审查、修复、生成内容)。",
21
21
  sysCwdLine: "- 当前工作目录: {cwd}",
22
22
  sysCwdMissing: "(未提供)",
23
23
  sysSummaryLine: "- 目录结构摘要:\n{summary}",
@@ -43,28 +43,29 @@ const HOST_MESSAGES = {
43
43
  importPathNotString: "导入路径必须是字符串(仅设置卡点「导入角色」时可留空 = 内置角色库)",
44
44
  importPathBlank: "导入路径不能只含空白字符",
45
45
  missingFinishChunk: "模型返回流缺少 finish 块",
46
- streamNotFinished: "模型整理未正常完成({reason})",
46
+ streamNotFinished: "模型润色未正常完成({reason})",
47
47
  failureReason: "{kind}: {message}",
48
- emptyPrompt: "用户要求为空,无法整理",
48
+ emptyPrompt: "用户要求为空,无法润色",
49
49
  noModelSelected: "当前无可用模型选择",
50
- emptyOrganizeResult: "模型整理结果为空",
50
+ emptyOrganizeResult: "模型润色结果为空",
51
+ organizeTimeout: "润色超时:{seconds} 秒内模型未返回完整结果(可在设置里调大超时)",
51
52
  fsUnavailable: "fs 服务不可用",
52
53
  cwdUnknown: "无法确定会话 cwd(sessionId 缺失或会话不存在)",
53
54
  modelServiceUnavailable: "agentDefaultModel 服务不可用",
54
55
  readModelFailed: "读取模型选择失败: {reason}",
55
56
  llmUnavailable: "llm 服务不可用",
56
- organizeFailed: "整理异常: {reason}"
57
+ organizeFailed: "润色异常: {reason}"
57
58
  },
58
59
  en: {
59
- sysRole: "You are a drafting assistant for the chat input box. The user wrote a request in the dsh input box; combine the layout of the current working directory with the session's recent context and turn it into a clearer request that is ready to send.",
60
+ sysRole: "You are a polishing assistant for the chat input box. The user wrote a request in the dsh input box; combine the layout of the current working directory with the session's recent context and polish it into a clearer request that is ready to send.",
60
61
  sysRulesHeading: "Rules:",
61
- sysRuleOutputOnly: "- Output only the refined body: no preamble, no markdown code fences, no headings, no explanations.",
62
- sysRuleNoExecution: "- Do not carry out any task the draft asks for: write no code, answer no question, run no review/search/generation - refine the text itself only (reword and restructure, fill in missing context, disambiguate references).",
62
+ sysRuleOutputOnly: "- Output only the polished body: no preamble, no markdown code fences, no headings, no explanations.",
63
+ sysRuleNoExecution: "- Do not carry out any task the draft asks for: write no code, answer no question, run no review/search/generation - polish the text itself only (reword and restructure, fill in missing context, disambiguate references).",
63
64
  sysRuleNoAnswer: "- If the draft is itself a question or a to-do instruction, the result stays a clear and complete version of that same question/instruction; do not write answers, solutions or examples into the result.",
64
65
  sysRuleKeepIntent: "- Keep the user's intent and language (keep the original language of the draft); add missing key details (target file/module) when the directory layout or the recent turns make them inferable, and never invent them when they are not.",
65
- sysRuleResolveRefs: "- The recent turns may carry references such as \"what you said above\" or \"that file from before\"; resolve them into explicit wording while refining.",
66
+ sysRuleResolveRefs: "- The recent turns may carry references such as \"what you said above\" or \"that file from before\"; resolve them into explicit wording while polishing.",
66
67
  sysRuleNoListing: "- The directory layout and the conversation history are background only; do not enumerate them.",
67
- sysRuleRoleView: "- If a reference role is given, borrow only its terminology and tone to rewrite the draft; never act as that role (no reviews, fixes or content generation).",
68
+ sysRuleRoleView: "- If a reference role is given, borrow only its terminology and tone to polish the draft; never act as that role (no reviews, fixes or content generation).",
68
69
  sysCwdLine: "- Current working directory: {cwd}",
69
70
  sysCwdMissing: "(not provided)",
70
71
  sysSummaryLine: "- Directory summary:\n{summary}",
@@ -80,7 +81,7 @@ const HOST_MESSAGES = {
80
81
  rootLabelCwd: "session cwd",
81
82
  rootLabelBuiltin: "built-in role library",
82
83
  rootLabelAllowed: "importAllowRoots allowed directory",
83
- outsideRoots: "Import path out of bounds: absolute paths are refused by default, only inside {zones} are allowed; received: {absolute}",
84
+ outsideRoots: "Import path out of bounds: absolute paths are refused by default; allowed only inside \"{zones}\"; received: {absolute}",
84
85
  zoneSeparator: ", ",
85
86
  emptyImportPath: "The import path cannot be empty (give a role .md or a directory path; an empty path only means the built-in role library when you press \"Import roles\" on the settings card)",
86
87
  relativeNeedsCwd: "A relative path needs the session cwd (use an absolute path instead)",
@@ -90,21 +91,21 @@ const HOST_MESSAGES = {
90
91
  importPathNotString: "The import path must be a string (it may only be empty when you press \"Import roles\" on the settings card, which means the built-in role library)",
91
92
  importPathBlank: "The import path cannot consist of whitespace only",
92
93
  missingFinishChunk: "The model stream is missing its finish chunk",
93
- streamNotFinished: "The model did not finish refining ({reason})",
94
+ streamNotFinished: "The model did not finish polishing ({reason})",
94
95
  failureReason: "{kind}: {message}",
95
- emptyPrompt: "The request is empty: nothing to refine",
96
+ emptyPrompt: "The request is empty: nothing to polish",
96
97
  noModelSelected: "No model selection is available",
97
98
  emptyOrganizeResult: "The model returned an empty result",
99
+ organizeTimeout: "Polishing timed out: the model did not finish within {seconds} seconds (the timeout is configurable in settings)",
98
100
  fsUnavailable: "fs service unavailable",
99
101
  cwdUnknown: "Cannot determine the session cwd (sessionId missing or session unknown)",
100
102
  modelServiceUnavailable: "agentDefaultModel service unavailable",
101
103
  readModelFailed: "Failed to read the model selection: {reason}",
102
104
  llmUnavailable: "llm service unavailable",
103
- organizeFailed: "Refinement failed: {reason}"
105
+ organizeFailed: "Polishing failed: {reason}"
104
106
  }
105
107
  };
106
- //#endregion
107
- //#region src/group-labels.generated.ts
108
+ // src/group-labels.generated.ts
108
109
  /** 仓库目录名 → 下拉分组标签;未收录的目录回落目录名本身(见 templates.ts groupLabelOf)。 */
109
110
  const AGENT_DIR_GROUP_LABELS = {
110
111
  academic: "学术",
@@ -132,9 +133,8 @@ const AGENT_DIR_GROUP_LABELS = {
132
133
  support: "客户支持",
133
134
  testing: "测试"
134
135
  };
135
- //#endregion
136
- //#region src/templates.ts
137
- /** 角色正文提炼/「按角色整理」上下文:不设字符上限(用户拍板,
136
+ // src/templates.ts
137
+ /** 角色正文提炼/「按角色风格润色」上下文:不设字符上限(用户拍板,
138
138
  * 上下文完整性优先;模型 context 超限由模型报错提示用户自行处理)。 */
139
139
  /** 仓库目录名 → 下拉分组标签的**唯一**导出点在 `./group-labels.generated.ts`(表源 =
140
140
  * scripts/gen-defaults-lib.mjs,键序 = 下拉分组展示序),本文件不再同名 re-export:
@@ -161,7 +161,7 @@ function stripPairQuotes(value) {
161
161
  if (isWrappedIn(value, "'") || isWrappedIn(value, "\"")) return value.slice(1, -1).trim();
162
162
  return value;
163
163
  }
164
- /** frontmatter 键名形状(与旧版 `^key:.*$` 正则同语义)。 */
164
+ /** frontmatter 键名形状:字母开头,随后字母/数字/下划线/连字符。 */
165
165
  const FRONTMATTER_KEY = /^[A-Za-z][A-Za-z0-9_-]*$/u;
166
166
  /** 头部只解析前 20 行键值对(防御恶意超长头部拖慢)。 */
167
167
  const FRONTMATTER_MAX_LINES = 20;
@@ -235,28 +235,31 @@ function parseAgentFrontmatter(text) {
235
235
  return result;
236
236
  }
237
237
  /**
238
- * 角色正文提炼(导入 / 「按角色整理」共用):取叙述主干、去代码围栏。
238
+ * 角色正文提炼(导入 / 「按角色风格润色」共用):取叙述主干、去代码围栏。
239
239
  *
240
240
  * 规则(确定性,测试锁死):
241
241
  * - ``` 围栏行整体剔除(围栏内容多为长代码样例,对角色语境价值低);
242
242
  * - 行内反引号一并剔除——沿用"正文不含反引号、插入不破坏 markdown 围栏"不变式;
243
243
  * - 不设字符上限(用户拍板):全量保留叙述内容,避免截断影响
244
- * 「以角色整理」的上下文完整性;模型 context 超限由模型报错提示用户自行处理;
244
+ * 「以角色风格润色」的上下文完整性;模型 context 超限由模型报错提示用户自行处理;
245
245
  * - 结果 trim;空正文(全围栏/全空白)→ 空串。
246
246
  */
247
247
  function condenseRoleBody(body) {
248
248
  const lines = body.split(/\r?\n/u);
249
249
  const out = [];
250
250
  let inFence = false;
251
- for (const raw of lines) if (raw.trim().startsWith("```")) inFence = !inFence;
252
- else if (inFence) {} else out.push(raw.replaceAll("`", ""));
251
+ let fenceStart = 0;
252
+ for (const [index, raw] of lines.entries()) if (raw.trim().startsWith("```")) {
253
+ fenceStart = inFence ? 0 : index + 1;
254
+ inFence = !inFence;
255
+ } else if (inFence) {} else out.push(raw.replaceAll("`", ""));
256
+ if (inFence) throw new Error(`正文第 ${String(fenceStart)} 行的代码围栏没有结束标记(\`\`\`)`);
253
257
  return out.join("\n").trim();
254
258
  }
255
- //#endregion
256
- //#region host.ts
257
- /** 本包送进 `llm.stream({ messages })` 的整理请求帧是 **request-only 输入**:它从不落
259
+ // host.ts
260
+ /** 本包送进 `llm.stream({ messages })` 的润色请求帧是 **request-only 输入**:它从不落
258
261
  * 任何持久消息位(`runOrganize` 只回 `{ content }`,读面也不把帧身份回投给卡片),所以
259
- * 按 0.1.7 它既不需要 `id` 也不带 `source`——证据三条:
262
+ * 它既不需要 `id` 也不带 `source`——证据三条:
260
263
  * 1. installed `@deepseek-ai/dsh-llm/lib/types/types.d.ts` 的 `RequestUserInput`
261
264
  * 把两面都标成 `?: never`(`readonly id?: never` / `readonly source?: never`),
262
265
  * `GenerateOptions.messages` 收的是 `RequestMessage[] = Message | RequestUserInput`
@@ -368,19 +371,19 @@ const KEY_EXT = /* @__PURE__ */ new Set([
368
371
  * `db-password.json` 命中,而 `monkey.js`(key 前是 n)、`AUTHORS.md`(auth 后是 o)不命中。
369
372
  * 复数形式一并收进来:`tokens.json`、`accounts.json` 是真实存在的凭据文件名。 */
370
373
  const SECRET_PATTERN = /(?:^|[^a-z0-9])(?:credentials?|secrets?|id_rsa|pem|p12|pfx|keystore|env|keys?|tokens?|auth|passwd|password|accounts?)(?:[^a-z0-9]|$)/u;
371
- /** LLM 整理超时。 */
374
+ /** LLM 润色超时。 */
372
375
  /** schema .default() 的单源(host 消费走 config 字段,不再直读常量)。 */
373
376
  const ORGANIZE_TIMEOUT_MS = 12e4;
374
377
  /** 单个关键文件的摘要字节上限。harness 的 readWholeText 无上限,超限文件整份
375
378
  * 跳过(不截半份——半份摘要会以"全量"的名义喂给模型,比没有更误导),
376
379
  * 并计入 skipped.tooLarge 回报。 */
377
380
  const MAX_SNIPPET_BYTES = 262144;
378
- /** 单次整理带进模型的全部摘要的**总量**上限。
381
+ /** 单次润色带进模型的全部摘要的**总量**上限。
379
382
  *
380
383
  * 为什么需要总量而单文件上限不够:`maxSnippetBytes` 只管每个文件,而条目数不设上界
381
384
  * (用户拍板)。于是 client 把所有摘要拼成 `entriesSummary` 原样回投 organize,请求
382
385
  * 仍要过宿主 /api 网关的请求体上限,摘要一多就顶得过它,结果是 context 读面成功、
383
- * UI 正常列出文件树,用户点「整理」才在网关处失败。这里给总量封顶,让「context 成功」
386
+ * UI 正常列出文件树,用户点「润色」才在网关处失败。这里给总量封顶,让「context 成功」
384
387
  * 不再意味着「organize 必然失败」。留足余量:JSON 转义与 client 侧的拼接还会再放大一截。 */
385
388
  const MAX_CONTEXT_TOTAL_BYTES = 2097152;
386
389
  /** 文件读取并发上限:Promise.all 一次铺开会在导入内置角色库(整棵 agents/)时打满
@@ -417,7 +420,7 @@ function hasFnMember(value, member) {
417
420
  return typeof value[member] === "function";
418
421
  }
419
422
  function isSettingsService(value) {
420
- return hasFnMember(value, "describe");
423
+ return hasFnMember(value, "describe") && hasFnMember(value, "configure");
421
424
  }
422
425
  function isSessionsService(value) {
423
426
  return hasFnMember(value, "get");
@@ -437,6 +440,16 @@ function isServiceGetter(value) {
437
440
  /** 字典里的 `{name}` 占位填充(与卡片侧官方 Translate 同语义,host 侧没有官方 translator
438
441
  * 故自带)。用 split/join 而不是 replace:路径与模型回文里可能带 `$`,而字符串版
439
442
  * replace 会把 `$&` / `$1` 当替换模式解释。 */
443
+ /** 换行与控制字符(`Cc` 含 \r\n\t,`Zl`/`Zp` 是 Unicode 行分隔与段分隔)。 */
444
+ const LINE_BREAKERS = /[\p{Cc}\p{Zl}\p{Zp}]+/gu;
445
+ /** 把一段宿主文本压成单行。
446
+ *
447
+ * system 槽里每条内容独占一行,模型按行读它——任何能从外部带的换行都能在 system 里凭空
448
+ * 造出下一行,而那正是最高信任位。cwd 取自会话工作目录,是文件名,POSIX 允许目录名带换行。
449
+ * 这里不改成转义序列:读的人只需要知道「这一行就是那个路径」,多出来的字节不必还原。 */
450
+ function singleLine(text) {
451
+ return text.replaceAll(LINE_BREAKERS, " ");
452
+ }
440
453
  function fillTemplate(template, tokens) {
441
454
  let text = template;
442
455
  for (const [token, value] of tokens) text = text.split(token).join(value);
@@ -657,7 +670,7 @@ async function collectDirContext(fs, cwd, messages, limits) {
657
670
  * 不得被 `/home/dev/project` 的字符串前缀放行),越界即拒并回显解析后的绝对路径;
658
671
  * - 命中根后,「根以内的剩余部分」仍逐段校验:`.` / `..` / 以 `.` 开头的隐藏段一律
659
672
  * 拒绝(cwd 里的 `.ssh/` 不因"在 cwd 之内"就可读)。根前缀本身不参与该判断,
660
- * 因此装在 ~/.dsh 下的项目也能导入自己 cwd 内的角色(旧版把这类 cwd 整体拦死)。
673
+ * 因此装在 ~/.dsh 下的项目也能导入自己 cwd 内的角色。
661
674
  * - 请求路径以 `.md` 结尾 → 单文件导入;否则按目录导入(顶层 *.md + 一层子目录
662
675
  * *.md,跳过隐藏项),目录扫描不递归更深层,但漏掉的必须计数回报。
663
676
  *
@@ -715,7 +728,16 @@ function outsideRootsError(absolute, roots, messages) {
715
728
  * 包含关系),而不是再写第二条字符串规则:符号链接让「路径长得合法」与「读的是哪个
716
729
  * 对象」分叉,只有后端能收这个叉。一个根命中即放行;全落空即为逃逸。 */
717
730
  async function escapesAllRoots(fs, target, roots) {
718
- return !(await Promise.all(roots.map((root) => fs.resolve(root.absolute)))).some((root) => fs.contains(root, target));
731
+ const resolved = await Promise.all(roots.map(async (root) => {
732
+ try {
733
+ return await fs.resolve(root.absolute);
734
+ } catch {
735
+ return null;
736
+ }
737
+ }));
738
+ let anyHit = false;
739
+ for (const root of resolved) if (root !== null && fs.contains(root, target)) anyHit = true;
740
+ return !anyHit;
719
741
  }
720
742
  function importPathError(requested, cwd, allowRoots, messages) {
721
743
  const trimmed = requested.trim();
@@ -836,7 +858,7 @@ async function importFromFile(args, absolute) {
836
858
  };
837
859
  }
838
860
  if (info === void 0) {
839
- skipped.unnamed = 1;
861
+ skipped.unnamed += 1;
840
862
  return {
841
863
  entries: [],
842
864
  truncated: false,
@@ -903,7 +925,8 @@ function pushReadResult(read, entries, collided, skipped) {
903
925
  }
904
926
  /** 目录路径扫描(顶层 + 一层子目录的 .md,第三层只清点)→ 条目列表。
905
927
  * 跳过计数**就地累加进调用方持有的 `skipped`**(而不是返回一份新表):中途抛错时
906
- * 上层 catch 仍要报出已经数到的那部分。 */
928
+ * 上层 catch 仍要报出已经数到的那部分。这里的两层形状被 src/ui-messages.ts 的
929
+ * skipDeeper / importHint(中英四键)写给用户,改扫描深度要同步那四处文案。 */
907
930
  async function importFromDirectory(fs, absolute, target, limits, skipped) {
908
931
  const rootChildren = await fs.listDir(target);
909
932
  const rootFiles = mdCandidates(fs, target, rootChildren, path.basename(absolute), skipped);
@@ -968,7 +991,7 @@ async function collectAgentTemplates(fs, requested, cwd, messages, opts) {
968
991
  }, absolute);
969
992
  return {
970
993
  entries: await importFromDirectory(fs, absolute, target, limits, skipped),
971
- truncated: skipped.tooLarge + skipped.unreadable + skipped.deeper + skipped.escaped > 0,
994
+ truncated: skipped.tooLarge + skipped.unreadable + skipped.deeper + skipped.escaped + skipped.unnamed > 0,
972
995
  skipped
973
996
  };
974
997
  } catch (error) {
@@ -982,7 +1005,7 @@ async function collectAgentTemplates(fs, requested, cwd, messages, opts) {
982
1005
  }
983
1006
  }
984
1007
  /** 构造 system 提示(导出供测试)。规则正文与各段标题全部取自注入的字典——
985
- * 面向模型的 prompt 也随官方 locale 偏好切语言,zh 输出与迁移前逐字一致。 */
1008
+ * 面向模型的 prompt 也随官方 locale 偏好切语言;zh 输出的正文逐字取自该字典。 */
986
1009
  function buildOrganizeSystem(input, messages) {
987
1010
  return [
988
1011
  messages.sysRole,
@@ -995,16 +1018,19 @@ function buildOrganizeSystem(input, messages) {
995
1018
  messages.sysRuleNoListing,
996
1019
  messages.sysRuleRoleView,
997
1020
  messages.sysRuleDataNotInstruction,
998
- fillTemplate(messages.sysCwdLine, [["{cwd}", input.cwd || messages.sysCwdMissing]])
1021
+ fillTemplate(messages.sysCwdLine, [["{cwd}", singleLine(input.cwd) || messages.sysCwdMissing]])
999
1022
  ].filter((part) => part.length > 0).join("\n");
1000
1023
  }
1001
1024
  /**
1002
1025
  * user 消息 = 草稿 + 围栏起来的不可信数据块。
1003
1026
  *
1004
1027
  * 围栏用**成对的定界标记**而不是缩进或横线:模型侧最容易被无视的是「看起来像普通内容」
1005
- * 的标记,而 `</data>` 这种成对标签既显眼、又难以由数据自身伪造(数据里出现的
1006
- * `</data>` 会被当作提前闭合,后续内容重新落回指令位——所以围栏内容仍按纯文本处理,
1007
- * 不做任何解析或转义)。
1028
+ * 的标记,而成对标签既显眼、又便于判断边界。
1029
+ *
1030
+ * ⚠ 标签本身拦不住数据:围栏内容来自用户仓库(目录摘要里的文件名、会话历史、角色 .md
1031
+ * 正文),里面完全可能含 `</data>`。原样拼进去会被读成提前闭合,其后的字符就重新落回
1032
+ * 指令位——围栏反而把不可信内容送到了它本该隔离的信任层。所以落进围栏的每一段文本都先
1033
+ * 把自己的定界标记替换成中性写法,标记只能由本函数产生。
1008
1034
  *
1009
1035
  * @param prompt - 真正的用户草稿
1010
1036
  * @param input - 其余上下文(摘要/历史/角色)
@@ -1012,9 +1038,10 @@ function buildOrganizeSystem(input, messages) {
1012
1038
  * @returns 交给模型的那条 user 文本
1013
1039
  */
1014
1040
  function buildOrganizeUser(prompt, input, messages) {
1041
+ const defused = (line) => line.split(messages.sysDataFenceStart).join("[fence-open]").split(messages.sysDataFenceEnd).join("[fence-close]");
1015
1042
  const fenced = (line) => [
1016
1043
  messages.sysDataFenceStart,
1017
- line,
1044
+ defused(line),
1018
1045
  messages.sysDataFenceEnd
1019
1046
  ].join("\n");
1020
1047
  const blocks = [
@@ -1088,7 +1115,7 @@ async function drainStreamToText(stream, messages) {
1088
1115
  }
1089
1116
  return text.trim();
1090
1117
  }
1091
- /** 整理入口(读面调用;导出供测试注入假 stream)。失败文案与 system 提示都来自
1118
+ /** 润色入口(读面调用;导出供测试注入假 stream)。失败文案与 system 提示都来自
1092
1119
  * 注入的字典,本函数不读设置。 */
1093
1120
  async function runOrganize(llm, input, messages, timeoutMs = ORGANIZE_TIMEOUT_MS, callerSignal) {
1094
1121
  const { prompt } = input;
@@ -1103,7 +1130,10 @@ async function runOrganize(llm, input, messages, timeoutMs = ORGANIZE_TIMEOUT_MS
1103
1130
  }]
1104
1131
  }];
1105
1132
  const controller = new AbortController();
1133
+ let timedOut = false;
1134
+ const hasTimedOut = () => timedOut;
1106
1135
  const timer = setTimeout(() => {
1136
+ timedOut = true;
1107
1137
  controller.abort();
1108
1138
  }, timeoutMs);
1109
1139
  const onCallerAbort = () => {
@@ -1119,16 +1149,17 @@ async function runOrganize(llm, input, messages, timeoutMs = ORGANIZE_TIMEOUT_MS
1119
1149
  model: model.model,
1120
1150
  ...model.reasoningEffort === void 0 ? {} : { reasoningEffort: model.reasoningEffort },
1121
1151
  messages: llmMessages,
1122
- system: buildOrganizeSystem({
1123
- cwd: input.cwd,
1124
- ...input.entriesSummary === void 0 ? {} : { entriesSummary: input.entriesSummary },
1125
- ...input.recentTurns === void 0 ? {} : { recentTurns: input.recentTurns },
1126
- ...input.roleText === void 0 ? {} : { roleText: input.roleText }
1127
- }, messages),
1152
+ system: buildOrganizeSystem({ cwd: input.cwd }, messages),
1128
1153
  signal: controller.signal
1129
1154
  }), messages);
1130
1155
  if (content.length === 0) throw new Error(messages.emptyOrganizeResult);
1131
1156
  return { content };
1157
+ } catch (error) {
1158
+ if (hasTimedOut()) {
1159
+ const seconds = String(Math.round(timeoutMs / 1e3));
1160
+ throw new Error(fillTemplate(messages.organizeTimeout, [["{seconds}", seconds]]), { cause: error });
1161
+ }
1162
+ throw error;
1132
1163
  } finally {
1133
1164
  clearTimeout(timer);
1134
1165
  callerSignal?.removeEventListener("abort", onCallerAbort);
@@ -1187,9 +1218,9 @@ function importAllowRootsOf(raw) {
1187
1218
  return roots;
1188
1219
  }
1189
1220
  /** 注入的服务面:settings 为硬依赖(cordis 等它就绪才 apply)。
1190
- * 0.1.7 起命名空间是隐式的(= 本条目在 cordis.patch.yml 里的裸 id,可编辑字段取自
1191
- * 导出的 Config),所以 settings 不再是「注册的前提」而是「页面策略(configure)与
1192
- * 跨命名空间读(describe)」的载体;设置页只派发「host 已 serve 的命名空间 ∩
1221
+ * 命名空间是隐式的(= 本条目在 cordis.patch.yml 里的裸 id,可编辑字段取自
1222
+ * 导出的 Config),所以 settings 在这里的职责是「页面策略(configure)与跨命名空间读
1223
+ * (describe)」,而非「注册的前提」;设置页只派发「host 已 serve 的命名空间 ∩
1193
1224
  * settings.plugin.item 卡」(dsh-client-ui-settings-plugins 源码语义),configure 必须
1194
1225
  * 发生在 apply 期,故仍硬注入。sessions/fs/llm/agentDefaultModel 仍可选读。 */
1195
1226
  const inject = ["settings"];
@@ -1218,8 +1249,8 @@ function resolveRecentTurns(sessions, sessionId) {
1218
1249
  }
1219
1250
  }
1220
1251
  /** 已解析的请求体 → 导入目标(拒绝时带回执的状态码与文案,由调用方原样发出)。
1221
- * path 缺失/非字符串 → 直接拒(旧版把它悄悄当成"留空",于是一个写坏字段的请求会
1222
- * 静默导入整个内置库——越界与坏输入都不许降级成"更多权限");只含空白字符的串同样
1252
+ * path 缺失/非字符串 → 直接拒(把它当成"留空"就是一个写坏字段的请求静默导入
1253
+ * 整个内置库——越界与坏输入都不许降级成"更多权限");只含空白字符的串同样
1223
1254
  * 是坏输入,不给降级空间(**精确空串**才是内置全量那个哨兵)。 */
1224
1255
  function importRequestOf(parsed, messages) {
1225
1256
  const { path: importPathRaw, sessionId } = isRecord(parsed) ? parsed : {};
@@ -1318,7 +1349,7 @@ function modelPayload(scope) {
1318
1349
  };
1319
1350
  }
1320
1351
  }
1321
- /** organize 请求体的输入面:JSON 已解析的 unknown → 整理入参(非字符串一律按空值处理)。 */
1352
+ /** organize 请求体的输入面:JSON 已解析的 unknown → 润色入参(非字符串一律按空值处理)。 */
1322
1353
  function organizeRequestOf(body) {
1323
1354
  const { prompt, sessionId, entriesSummary, roleText } = body;
1324
1355
  return {
@@ -1328,7 +1359,7 @@ function organizeRequestOf(body) {
1328
1359
  sessionId: typeof sessionId === "string" ? sessionId : null
1329
1360
  };
1330
1361
  }
1331
- /** 整理:LLM 调用与两层错误回执。内层 catch 是「整理过程本身失败」(回裸 errorText),
1362
+ /** 润色:LLM 调用与两层错误回执。内层 catch 是「润色过程本身失败」(回裸 errorText),
1332
1363
  * 外层是「装配入参时炸」。`messages` 每次调用现读一次,不在此处二次现读。 */
1333
1364
  async function organizePayload(scope, parsed) {
1334
1365
  const messages = scope.messagesOf();
@@ -1455,8 +1486,8 @@ function createRemotePayloads(deps, messagesOf) {
1455
1486
  /** 官方 Typert Remote 的服务键(= 线上命名空间)。 */
1456
1487
  const DIR_PREP_REMOTE_NAMESPACE = "dirPrepOrganize";
1457
1488
  /**
1458
- * 设置卡的宿主读面(官方 Typert Remote):目录上下文、当前模型、整理、导入与内置模板。
1459
- * 取代原先的五条 HTTP 端点(旧数据面已删除)。
1489
+ * 设置卡的宿主读面(官方 Typert Remote):目录上下文、当前模型、润色、导入与内置模板。
1490
+ * 本包不自建 HTTP 端点,认证与分派由宿主 /api 网关负责。
1460
1491
  */
1461
1492
  var DirPrepRemoteService = class extends TypertRemoteService {
1462
1493
  scope;
@@ -1513,7 +1544,7 @@ function installDirPrepRemote(ctx, scope) {
1513
1544
  /** settings 注册的占位清理(无额外拆卸动作,注册随插件生命周期存续)。 */
1514
1545
  function noopDisposer() {}
1515
1546
  /** host apply:登记设置页策略 + 注册官方 Remote 读面(注入子上下文,卸载即撤)。
1516
- * 0.1.7 起模板设置是**隐式注册**的(导出的 Config + 字段上的 .volatile()),本函数
1547
+ * 模板设置是**隐式注册**的(导出的 Config + 字段上的 .volatile()),本函数
1517
1548
  * 不再向 settings 注册任何东西;配置值由 cordis 校验并填过默认后按 volatile 引用交进来
1518
1549
  * (第二参数 config),读当前值一律 `.get()`。 */
1519
1550
  function apply(ctx, config) {
@@ -1576,5 +1607,4 @@ function apply(ctx, config) {
1576
1607
  installDirPrepRemote(child, scope);
1577
1608
  });
1578
1609
  }
1579
- //#endregion
1580
1610
  export { configSchema as Config, DIR_PREP_REMOTE_NAMESPACE, DirPrepRemoteService, apply, buildOrganizeSystem, buildOrganizeUser, clampInt, collectAgentTemplates, collectDirContext, createRemotePayloads, defaultTemplatesFrom, drainStreamToText, extractRecentTurns, importAllowRootsOf, importPathError, inject, installDirPrepRemote, loadDefaultTemplates, runOrganize, sanitizeLimits };
package/package.json CHANGED
@@ -1,7 +1,15 @@
1
1
  {
2
2
  "name": "@jayyuen66/dsh-dir-prep-organize",
3
- "version": "0.1.4",
4
- "description": "dsh 插件:对话输入框「整理」按钮(主键直接整理/▾ 以角色视角整理,结合当前目录 + session 模型整理优化草稿)+「模板」下拉(内置精选角色集生成自插件 agents/ 角色库,可按部门分组;设置卡可增删改/一键导入内置全部/导入本地角色 .md)",
3
+ "version": "0.1.6",
4
+ "description": "dsh 插件:对话输入框「润色」按钮(主键直接润色/▾ 以角色风格润色,结合当前目录 + session 模型润色草稿)+「模板」下拉(内置精选角色集生成自插件 agents/ 角色库,可按部门分组;设置卡可增删改/一键导入内置全部/导入本地角色 .md)",
5
+ "keywords": [
6
+ "cordis",
7
+ "dsh",
8
+ "dsh-plugin",
9
+ "prompt-engineering",
10
+ "role-template",
11
+ "ui"
12
+ ],
5
13
  "homepage": "https://github.com/JayYuen666/dsh-dir-prep-organize#readme",
6
14
  "bugs": {
7
15
  "url": "https://github.com/JayYuen666/dsh-dir-prep-organize/issues"
@@ -21,6 +29,7 @@
21
29
  "cordis.patch.yml",
22
30
  "agents",
23
31
  "README.zh-CN.md",
32
+ "CHANGELOG.md",
24
33
  "THIRD_PARTY_NOTICES.md"
25
34
  ],
26
35
  "type": "module",
@@ -45,65 +54,65 @@
45
54
  "registry": "https://registry.npmjs.org"
46
55
  },
47
56
  "dependencies": {
48
- "@jayyuen66/dsh-plugin-shared": "^0.1.6"
57
+ "@jayyuen66/dsh-plugin-shared": "0.1.9"
49
58
  },
50
59
  "devDependencies": {
51
60
  "@deepseek-ai/cordis": "4.0.5",
52
61
  "@deepseek-ai/cordis-plugin-group": "1.0.5",
53
62
  "@deepseek-ai/cordis-plugin-include": "1.0.10",
54
63
  "@deepseek-ai/cosmokit": "1.8.6",
55
- "@deepseek-ai/dsh-agent-default-model": "0.2.1-rc.2",
56
- "@deepseek-ai/dsh-app-boot": "0.2.1-rc.2",
57
- "@deepseek-ai/dsh-brand": "0.2.1-rc.2",
58
- "@deepseek-ai/dsh-client-locale": "0.2.1-rc.2",
59
- "@deepseek-ai/dsh-client-ui-conversation": "0.2.1-rc.2",
60
- "@deepseek-ai/dsh-client-ui-plugin-manager": "0.2.1-rc.2",
61
- "@deepseek-ai/dsh-client-ui-renderer": "0.2.1-rc.2",
62
- "@deepseek-ai/dsh-client-ui-settings": "0.2.1-rc.2",
63
- "@deepseek-ai/dsh-client-ui-slots": "0.2.1-rc.2",
64
- "@deepseek-ai/dsh-config-editor": "0.2.1-rc.2",
65
- "@deepseek-ai/dsh-fs": "0.2.1-rc.2",
66
- "@deepseek-ai/dsh-home-paths": "0.2.1-rc.2",
67
- "@deepseek-ai/dsh-host-webserver": "0.2.1-rc.2",
68
- "@deepseek-ai/dsh-launch-environment": "0.2.1-rc.2",
69
- "@deepseek-ai/dsh-llm": "0.2.1-rc.2",
70
- "@deepseek-ai/dsh-sandbox": "0.2.1-rc.2",
71
- "@deepseek-ai/dsh-scope": "0.2.1-rc.2",
72
- "@deepseek-ai/dsh-session": "0.2.1-rc.2",
73
- "@deepseek-ai/dsh-settings": "0.2.1-rc.2",
74
- "@deepseek-ai/dsh-typert-protocol": "0.2.1-rc.2",
64
+ "@deepseek-ai/dsh-agent-default-model": "0.2.1-rc.3",
65
+ "@deepseek-ai/dsh-app-boot": "0.2.1-rc.3",
66
+ "@deepseek-ai/dsh-brand": "0.2.1-rc.3",
67
+ "@deepseek-ai/dsh-client-locale": "0.2.1-rc.3",
68
+ "@deepseek-ai/dsh-client-ui-conversation": "0.2.1-rc.3",
69
+ "@deepseek-ai/dsh-client-ui-plugin-manager": "0.2.1-rc.3",
70
+ "@deepseek-ai/dsh-client-ui-renderer": "0.2.1-rc.3",
71
+ "@deepseek-ai/dsh-client-ui-settings": "0.2.1-rc.3",
72
+ "@deepseek-ai/dsh-client-ui-slots": "0.2.1-rc.3",
73
+ "@deepseek-ai/dsh-config-editor": "0.2.1-rc.3",
74
+ "@deepseek-ai/dsh-fs": "0.2.1-rc.3",
75
+ "@deepseek-ai/dsh-home-paths": "0.2.1-rc.3",
76
+ "@deepseek-ai/dsh-host-webserver": "0.2.1-rc.3",
77
+ "@deepseek-ai/dsh-launch-environment": "0.2.1-rc.3",
78
+ "@deepseek-ai/dsh-llm": "0.2.1-rc.3",
79
+ "@deepseek-ai/dsh-sandbox": "0.2.1-rc.3",
80
+ "@deepseek-ai/dsh-scope": "0.2.1-rc.3",
81
+ "@deepseek-ai/dsh-session": "0.2.1-rc.3",
82
+ "@deepseek-ai/dsh-settings": "0.2.1-rc.3",
83
+ "@deepseek-ai/dsh-typert-protocol": "0.2.1-rc.3",
75
84
  "@deepseek-ai/schemastery": "3.18.5",
76
85
  "@types/node": "26.6.5",
77
86
  "@types/react": "19.3.0",
78
87
  "@types/react-dom": "19.3.0",
79
88
  "@vitest/coverage-v8": "5.0.5",
80
89
  "eslint-plugin-sonarjs": "4.2.2",
81
- "happy-dom": "21.0.3",
82
- "oxfmt": "0.73.0",
83
- "oxlint": "1.88.0",
84
- "oxlint-tsgolint": "7.0.2004",
90
+ "happy-dom": "21.0.4",
91
+ "oxfmt": "0.74.0",
92
+ "oxlint": "1.89.0",
93
+ "oxlint-tsgolint": "7.0.2005",
85
94
  "react": "^19.3.0",
86
95
  "react-dom": "^19.3.0",
87
- "rolldown": "1.2.14",
96
+ "rolldown": "1.2.15",
88
97
  "typescript": "7.0.2",
89
- "vite": "8.3.4",
98
+ "vite": "8.3.5",
90
99
  "vitest": "5.0.5"
91
100
  },
92
101
  "peerDependencies": {
93
102
  "@deepseek-ai/cordis": "4.0.5",
94
103
  "@deepseek-ai/cosmokit": "1.8.6",
95
- "@deepseek-ai/dsh": "^0.2.1-rc.2",
96
- "@deepseek-ai/dsh-agent-default-model": "0.2.1-rc.2",
97
- "@deepseek-ai/dsh-brand": "0.2.1-rc.2",
98
- "@deepseek-ai/dsh-client-locale": "0.2.1-rc.2",
99
- "@deepseek-ai/dsh-client-ui-conversation": "0.2.1-rc.2",
100
- "@deepseek-ai/dsh-client-ui-renderer": "0.2.1-rc.2",
101
- "@deepseek-ai/dsh-client-ui-settings": "0.2.1-rc.2",
102
- "@deepseek-ai/dsh-client-ui-slots": "0.2.1-rc.2",
103
- "@deepseek-ai/dsh-fs": "0.2.1-rc.2",
104
- "@deepseek-ai/dsh-llm": "0.2.1-rc.2",
105
- "@deepseek-ai/dsh-session": "0.2.1-rc.2",
106
- "@deepseek-ai/dsh-typert-protocol": "0.2.1-rc.2",
104
+ "@deepseek-ai/dsh": "^0.2.1-rc.3",
105
+ "@deepseek-ai/dsh-agent-default-model": "0.2.1-rc.3",
106
+ "@deepseek-ai/dsh-brand": "0.2.1-rc.3",
107
+ "@deepseek-ai/dsh-client-locale": "0.2.1-rc.3",
108
+ "@deepseek-ai/dsh-client-ui-conversation": "0.2.1-rc.3",
109
+ "@deepseek-ai/dsh-client-ui-renderer": "0.2.1-rc.3",
110
+ "@deepseek-ai/dsh-client-ui-settings": "0.2.1-rc.3",
111
+ "@deepseek-ai/dsh-client-ui-slots": "0.2.1-rc.3",
112
+ "@deepseek-ai/dsh-fs": "0.2.1-rc.3",
113
+ "@deepseek-ai/dsh-llm": "0.2.1-rc.3",
114
+ "@deepseek-ai/dsh-session": "0.2.1-rc.3",
115
+ "@deepseek-ai/dsh-typert-protocol": "0.2.1-rc.3",
107
116
  "@deepseek-ai/schemastery": "3.18.5"
108
117
  },
109
118
  "peerDependenciesMeta": {
@@ -149,7 +158,7 @@
149
158
  },
150
159
  "icon": "icon.svg",
151
160
  "engines": {
152
- "dsh": "^0.2.1-rc.2",
161
+ "dsh": "^0.2.1-rc.3",
153
162
  "node": ">=22.12.0"
154
163
  },
155
164
  "dsh": {
@@ -163,7 +172,7 @@
163
172
  }
164
173
  },
165
174
  "scripts": {
166
- "typecheck": "tsc --noEmit -p tsconfig.json && tsc --noEmit -p tsconfig.client.json",
175
+ "typecheck": "tsc --noEmit -p tsconfig.json && tsc --noEmit -p tsconfig.client.json && tsc --noEmit -p src/tsconfig.json && tsc --noEmit -p tsconfig.build-scripts.json",
167
176
  "lint": "oxlint .",
168
177
  "test": "vitest run --coverage",
169
178
  "gen:defaults": "node scripts/gen-defaults.mjs",
@@ -171,6 +180,6 @@
171
180
  "build:client": "node build-client.mjs",
172
181
  "build": "node build-host.mjs",
173
182
  "build:types": "node build-types.mjs",
174
- "fmt:check": "oxfmt --check ."
183
+ "fmt:check": "oxfmt --check . --ignore-path .gitignore --ignore-path .prettierignore"
175
184
  }
176
185
  }