skill-creator 1.5.2 → 2.0.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 (140) hide show
  1. package/CHANGELOG.md +73 -0
  2. package/LICENSE +21 -0
  3. package/README.md +248 -345
  4. package/dist/cli.js +51129 -0
  5. package/dist/cli.js.map +7 -0
  6. package/dist/daemon.js +52163 -0
  7. package/dist/daemon.js.map +7 -0
  8. package/dist/package.json +5 -0
  9. package/dist/webui/_app/immutable/assets/0.0XN00VKF.css +2 -0
  10. package/dist/webui/_app/immutable/assets/ProviderView.DEH95hqa.css +1 -0
  11. package/dist/webui/_app/immutable/assets/inter-cyrillic-ext-wght-normal.BOeWTOD4.woff2 +0 -0
  12. package/dist/webui/_app/immutable/assets/inter-cyrillic-wght-normal.DqGufNeO.woff2 +0 -0
  13. package/dist/webui/_app/immutable/assets/inter-greek-ext-wght-normal.DlzME5K_.woff2 +0 -0
  14. package/dist/webui/_app/immutable/assets/inter-greek-wght-normal.CkhJZR-_.woff2 +0 -0
  15. package/dist/webui/_app/immutable/assets/inter-latin-ext-wght-normal.DO1Apj_S.woff2 +0 -0
  16. package/dist/webui/_app/immutable/assets/inter-latin-wght-normal.Dx4kXJAl.woff2 +0 -0
  17. package/dist/webui/_app/immutable/assets/inter-vietnamese-wght-normal.CBcvBZtf.woff2 +0 -0
  18. package/dist/webui/_app/immutable/assets/shell.U4CQV8re.css +1 -0
  19. package/dist/webui/_app/immutable/chunks/0umLG1IN.js +1 -0
  20. package/dist/webui/_app/immutable/chunks/B2zyE4XX.js +1 -0
  21. package/dist/webui/_app/immutable/chunks/BD9g8Udg.js +1 -0
  22. package/dist/webui/_app/immutable/chunks/BEPs9Z9s.js +1 -0
  23. package/dist/webui/_app/immutable/chunks/BEsyQXpe.js +1 -0
  24. package/dist/webui/_app/immutable/chunks/BIfnT_mK.js +1 -0
  25. package/dist/webui/_app/immutable/chunks/BYNWtKcf.js +259 -0
  26. package/dist/webui/_app/immutable/chunks/B_YFzSAv.js +2 -0
  27. package/dist/webui/_app/immutable/chunks/BaH4uqzh.js +1 -0
  28. package/dist/webui/_app/immutable/chunks/Bjy-W4x2.js +81 -0
  29. package/dist/webui/_app/immutable/chunks/BkEnd9_Z.js +1 -0
  30. package/dist/webui/_app/immutable/chunks/BrDKAjtR.js +1 -0
  31. package/dist/webui/_app/immutable/chunks/Bs27XW8_.js +1 -0
  32. package/dist/webui/_app/immutable/chunks/BySEbwqx.js +1 -0
  33. package/dist/webui/_app/immutable/chunks/C3mlWJXx.js +1 -0
  34. package/dist/webui/_app/immutable/chunks/CEpOi93z.js +2 -0
  35. package/dist/webui/_app/immutable/chunks/CIFG41pU.js +1 -0
  36. package/dist/webui/_app/immutable/chunks/CNPsST_i.js +1 -0
  37. package/dist/webui/_app/immutable/chunks/CQD9uzpA.js +1 -0
  38. package/dist/webui/_app/immutable/chunks/CeR4do8T.js +1 -0
  39. package/dist/webui/_app/immutable/chunks/Ckw1quWt.js +1 -0
  40. package/dist/webui/_app/immutable/chunks/CmCJ0SKP.js +3 -0
  41. package/dist/webui/_app/immutable/chunks/D-V0xBeS.js +1 -0
  42. package/dist/webui/_app/immutable/chunks/D-ecV3TD.js +1 -0
  43. package/dist/webui/_app/immutable/chunks/D0xHg31U.js +1 -0
  44. package/dist/webui/_app/immutable/chunks/D25cXQtk.js +1 -0
  45. package/dist/webui/_app/immutable/chunks/D8Der6oM.js +1 -0
  46. package/dist/webui/_app/immutable/chunks/DEtYLPO4.js +8 -0
  47. package/dist/webui/_app/immutable/chunks/DJNLWtK-.js +1 -0
  48. package/dist/webui/_app/immutable/chunks/DLuJKUyD.js +1 -0
  49. package/dist/webui/_app/immutable/chunks/DWcQbrnv.js +52 -0
  50. package/dist/webui/_app/immutable/chunks/DZ_Kltd5.js +1 -0
  51. package/dist/webui/_app/immutable/chunks/DecrR9TK.js +1 -0
  52. package/dist/webui/_app/immutable/chunks/Dl8eQ129.js +5 -0
  53. package/dist/webui/_app/immutable/chunks/Dnkino9G.js +1 -0
  54. package/dist/webui/_app/immutable/chunks/HclGiUj8.js +1 -0
  55. package/dist/webui/_app/immutable/chunks/IYkYSIV6.js +1 -0
  56. package/dist/webui/_app/immutable/chunks/J36u8XLO.js +1 -0
  57. package/dist/webui/_app/immutable/chunks/UeEccMjN.js +1 -0
  58. package/dist/webui/_app/immutable/chunks/Y--VMh3y.js +1 -0
  59. package/dist/webui/_app/immutable/chunks/iicbWqXp.js +3 -0
  60. package/dist/webui/_app/immutable/chunks/s48N5eaK.js +67 -0
  61. package/dist/webui/_app/immutable/chunks/xihTtKlq.js +1 -0
  62. package/dist/webui/_app/immutable/entry/app.CbFi8HIH.js +2 -0
  63. package/dist/webui/_app/immutable/entry/start.C3bV1TCO.js +1 -0
  64. package/dist/webui/_app/immutable/nodes/0.C7-AKGsj.js +231 -0
  65. package/dist/webui/_app/immutable/nodes/1.raBmjc20.js +1 -0
  66. package/dist/webui/_app/immutable/nodes/2.ewWz-Ki-.js +1 -0
  67. package/dist/webui/_app/immutable/nodes/3.DCVfhckZ.js +1 -0
  68. package/dist/webui/_app/version.json +1 -0
  69. package/dist/webui/icons/app-icon/darwin-dark.icns +0 -0
  70. package/dist/webui/icons/app-icon/darwin-light.icns +0 -0
  71. package/dist/webui/icons/app-icon/win32-dark.ico +0 -0
  72. package/dist/webui/icons/app-icon/win32-light.ico +0 -0
  73. package/dist/webui/icons/app-icon.icns +0 -0
  74. package/dist/webui/icons/app-icon.ico +0 -0
  75. package/dist/webui/icons/app-icon.json +84 -0
  76. package/dist/webui/icons/app-icon.png +0 -0
  77. package/dist/webui/icons/flat-symbol.png +0 -0
  78. package/dist/webui/icons/linux/128x128/app-icon.png +0 -0
  79. package/dist/webui/icons/linux/16x16/app-icon.png +0 -0
  80. package/dist/webui/icons/linux/256x256/app-icon.png +0 -0
  81. package/dist/webui/icons/linux/32x32/app-icon.png +0 -0
  82. package/dist/webui/icons/linux/48x48/app-icon.png +0 -0
  83. package/dist/webui/icons/linux/512x512/app-icon.png +0 -0
  84. package/dist/webui/icons/linux/64x64/app-icon.png +0 -0
  85. package/dist/webui/icons/monochrome-mini.png +0 -0
  86. package/dist/webui/index.html +62 -0
  87. package/dist/webui/robots.txt +3 -0
  88. package/package.json +99 -73
  89. package/dist/buildIndex-B_9ABRtx.mjs +0 -2
  90. package/dist/buildIndex-B_9ABRtx.mjs.map +0 -1
  91. package/dist/buildIndex-Cea97e0l.mjs +0 -1
  92. package/dist/cli.d.mts +0 -1016
  93. package/dist/cli.d.mts.map +0 -1
  94. package/dist/cli.mjs +0 -20
  95. package/dist/cli.mjs.map +0 -1
  96. package/dist/contentManager-CoVTiSDT.mjs +0 -13
  97. package/dist/contentManager-CoVTiSDT.mjs.map +0 -1
  98. package/dist/contentManager-CwquwC1s.mjs +0 -1
  99. package/dist/context7-BejCCqkm.mjs +0 -1
  100. package/dist/context7-BxMpyQiW.mjs +0 -2
  101. package/dist/context7-BxMpyQiW.mjs.map +0 -1
  102. package/dist/index.d.mts +0 -2158
  103. package/dist/index.d.mts.map +0 -1
  104. package/dist/index.mjs +0 -2
  105. package/dist/index.mjs.map +0 -1
  106. package/dist/listContext7-DHj9AL-z.mjs +0 -2
  107. package/dist/listContext7-DHj9AL-z.mjs.map +0 -1
  108. package/dist/package-CFJazwTO.mjs +0 -2
  109. package/dist/package-CFJazwTO.mjs.map +0 -1
  110. package/dist/referenceSearchUtils-DZgupMZp.mjs +0 -2
  111. package/dist/referenceSearchUtils-DZgupMZp.mjs.map +0 -1
  112. package/dist/removeContext7-BZtL4_CJ.mjs +0 -3
  113. package/dist/removeContext7-BZtL4_CJ.mjs.map +0 -1
  114. package/dist/removeSkill-Bat_plVG.mjs +0 -5
  115. package/dist/removeSkill-Bat_plVG.mjs.map +0 -1
  116. package/dist/removeSkill-DjDZjhJU.mjs +0 -1
  117. package/dist/runScript-CSKqb831.mjs +0 -13
  118. package/dist/runScript-CSKqb831.mjs.map +0 -1
  119. package/dist/scopeSelection-BWteJQSv.mjs +0 -2
  120. package/dist/scopeSelection-BWteJQSv.mjs.map +0 -1
  121. package/dist/searchQuality-DVdHmamh.mjs +0 -2
  122. package/dist/searchQuality-DVdHmamh.mjs.map +0 -1
  123. package/dist/search_format-RyjXACJa.mjs +0 -5
  124. package/dist/search_format-RyjXACJa.mjs.map +0 -1
  125. package/dist/shared-DsVh4gOV.mjs +0 -2
  126. package/dist/shared-DsVh4gOV.mjs.map +0 -1
  127. package/dist/skillCreator-BomXoqdw.mjs +0 -2
  128. package/dist/skillCreator-BomXoqdw.mjs.map +0 -1
  129. package/dist/skillMdManager-DGBZ6M5J.mjs +0 -7
  130. package/dist/skillMdManager-DGBZ6M5J.mjs.map +0 -1
  131. package/dist/sqliteVectorSearchAdapter-56kZjbUT.mjs +0 -28
  132. package/dist/sqliteVectorSearchAdapter-56kZjbUT.mjs.map +0 -1
  133. package/dist/sqliteVectorSearchAdapter-DNkyKuZs.mjs +0 -1
  134. package/dist/unifiedSearch-CLdazMYU.mjs +0 -4
  135. package/dist/unifiedSearch-CLdazMYU.mjs.map +0 -1
  136. package/dist/unifiedSearch-DCFPrtzZ.mjs +0 -1
  137. package/templates/SKILL.md +0 -56
  138. package/templates/SKILL.zh-CN.md +0 -339
  139. package/templates/skill-creator.md +0 -130
  140. package/templates/skill-creator.zh-CN.md +0 -133
package/README.md CHANGED
@@ -1,392 +1,295 @@
1
- # Skill Creator
2
-
3
- A powerful composite tool for creating and managing Claude Code skills. It serves as both:
4
-
5
- 1. **CLI Tool** - A TypeScript/Node.js command-line interface for skill management
6
- 2. **Claude Code Subagent** - An intelligent agent that automates skill creation workflow
7
-
8
- ## Features
9
-
10
- ### Core Capabilities
11
-
12
- - 🚀 **Automated Skill Creation**: Generate skills with proper folder naming (`package@version` format)
13
- - 📚 **Context7 Integration**: Resolve the best Context7 project ID, then download and slice documentation automatically
14
- - 🔍 **Intelligent Search**: Lightweight local full-text search with optional explicit vector mode
15
- - 💾 **Dynamic Content Management**: Add custom knowledge with deduplication
16
-
17
- ### CLI & Subagent
18
-
19
- - 🛠️ **Modern TypeScript**: Full type safety with ESM modules
20
- - 🎯 **CLI-first Workflow**: Non-interactive by default, with explicit interactive prompts when requested
21
- - 🤖 **Subagent Mode**: Intelligent agent that handles the entire skill creation workflow
22
- - 📦 **Flexible Storage**: Store skills in project (`.claude/skills/`) or user directory (`~/.claude/skills`)
23
-
24
- ## Installation
25
-
26
- ### Install skill-creator
27
-
28
- ```bash
29
- npm install -g skill-creator
30
- ```
31
-
32
- ### Verify Installation
33
-
34
- After installation, verify that the CLI is available:
35
-
36
- ```bash
37
- skill-creator --help
1
+ <!--
2
+ 文件意图(2026-07-22)
3
+ 用户原始需求摘录:
4
+ - 「参考 ../../pnpm-pub 这个项目的架构:cli+gui(webui+opentray),基于 ../ccski 这个 sdk 来快速搭建一个 skills 管理器。」
5
+ - 「skills manager 只是路由的一部分(`/workspace/~/`);我们还需要支持导入 workspace;创造、编辑技能的路由(/creator);以及 `/repository/`。」
6
+ - [2026-07-22]「home 目录定义为特殊的 GlobalWorkspace;一个 Workspace 下可以包含多个 providers;下载到某个 Workspace.provider,且能多选。」
7
+ - 「继续迭代,大胆创新……以人为本,要让小白到各行各业到专业工程师用起来都舒心。」
8
+ - [2026-07-15]「按照你自己的节奏去推进开发迭代。」
9
+ - [2026-07-19]「我们已经不做 keepOnTop:true 的模式了。而是走 appMode:true 模式。所以走原生的窗口管理。」
10
+ - [2026-07-21]「我们默认是破坏性更新的……使用 zod 的 safeParse 来统一解决这个问题,遇到不兼容的就当是空值。」
11
+ - [2026-07-21]「任何外部输入都应该遵循这个规则:各种配置文件、数据库结构、网络返回等。」
12
+ - [2026-07-21]「`skill-creator stop` 找不到 daemon,但 `pnpm dev` 又说已有 daemon 持有 socket。」
13
+ - [2026-07-22]「同意,但是改成 `skill-creator openinbrowser`。」
14
+ 正交意图:1. 定义产品边界;2. 给出真实安装与运行方式;3. 说明协议和安全模型;4. 提供开发验证入口;5. 承载品牌门面图(color-symbol)。
15
+ 妥协声明:README 是包发布后唯一随包分发的公开入口,安装、运行、边界与安全事实必须同处一份文件,拆分会使发布包缺失必要上下文。品牌图经项目相对路径 `./resources/color-symbol.png` 引用,GitHub 自动渲染为 raw 链接;resources 不进 npm 包,npm 端图片缺失不影响文本可读性,repository 字段引导读者到 GitHub。
16
+ -->
17
+
18
+ <p align="center">
19
+ <img src="./resources/color-symbol.png" alt="Skill Creator" width="180" />
20
+ </p>
21
+
22
+ <h1 align="center">Skill Creator</h1>
23
+
24
+ Skill Creator 是本地优先的 Agent 技能工作台。薄 CLI 管理单例 daemon,daemon 以自己的 shell(SPA + ChromeTabs 三 App)作为唯一宿主:右侧 Agent 面板承载聊天对话,DSH(DeepSeek Harness)只作为 headless 内核(agent/session/llm/approval)驱动会话;Manager 的领域能力以 MCP server(`/mcp`,同一实现另有 `skill-creator mcp` stdio 形态)供给内核与外部 client——mutation 一律产 proposal 待人工审批。技能的发现、校验和安装以 ccski SDK 完成;Workspace/Provider 投影、权限边界和跨路由体验属于 Skill Creator,而不是 ccski。内核不可用时 daemon 降级为 Manager-only 面,不阻塞启动。
25
+
26
+ ```text
27
+ Skill Creator
28
+
29
+ Human
30
+ |
31
+ +-- CLI -------- versioned IPC --------+
32
+ | |
33
+ +-- Tray WebUI -- authenticated oRPC --+--> Daemon --> filesystem / Git
34
+ |
35
+ +--> ccski
36
+ +--> OpenTray ext-webview
37
+
38
+ /workspaces /creator /repository
39
+ list / import/remove create / edit scan / preview / install
40
+ discover / inspect revision checked one pinned Git commit
41
+ validate / toggle change log curated + user sources
38
42
  ```
39
43
 
40
- If the help output renders, the local skill workflow is available.
41
-
42
- ### Runtime Prerequisites
43
-
44
- `skill-creator` does not require Claude Code MCP servers for its core CLI workflow.
45
-
46
- It uses:
47
- - npm registry HTTP APIs for `search` and `get-info`
48
- - Context7 HTTP APIs for `resolve-context7` and `download-context7`
49
-
50
- You only need normal outbound network access when using those commands.
51
-
52
- ## Quick Start
44
+ 一级导航是 Workspaces、Creator、Repository 三个 App;WebUI 使用 ChromeTabs 式标签 Shell(`webui/src/lib/shell` + `webui/src/lib/apps`),URL 由 shell 内 route registry 解析,SvelteKit 侧只有一个 catch-all 承载点。
53
45
 
54
- ### 1. Install as CLI Tool
46
+ ## 产品边界
55
47
 
56
- ```bash
57
- npm install -g skill-creator
58
- ```
48
+ | Surface | 责任 | 写入边界 |
49
+ | -------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------- |
50
+ | `/workspaces` home | 索引 Global 与 Imported Workspace,提供导入与移除恢复入口 | Remove Workspace 只删除 registry entry,不删除用户目录 |
51
+ | `/workspaces` provider tab | 在一个 Workspace 的 Provider 中发现、筛选、查看、校验、启用或禁用技能;对比上游检查并按需重装过时技能;`Workflow` 标签承载技能管家工作流(见下文) | 每次操作显式携带 Workspace ID + Provider ID |
52
+ | Global Workspace(`~`) | 聚合各 Agent 的全局 skills roots | 可读/可管理现有技能,不作为 Creator 或 Repository 的写入目标 |
53
+ | `/creator` | 在已导入 Workspace.Provider 中创建、加载、编辑和删除 `SKILL.md`;查看 change log(Agent 会话由右侧面板承载,见下文) | `workspace`+`provider` 预选新建;再加 `skill` 加载编辑;更新和删除需要内容 revision |
54
+ | `/repository` | 扫描 Git 仓库、预览技能、dry-run、多目标安装并复核结果;管理 curated 与自建 Discover 源 | 扫描会话固定到一个 commit;可多选已导入 Workspace.Provider 写入目标;用户源仅 https Git URL |
59
55
 
60
- ### 2. Setup for Claude Code
61
-
62
- ```bash
63
- # Interactive installation - defaults to current when a local subagent already exists, otherwise user
64
- skill-creator init
56
+ Workspace 是技能作用域的第一层,Provider 是其中的 Agent skills root。Global Workspace(`~`)从社区 catalog 解析本机 Agent 全局目录;Imported Workspace 从其 canonical directory 派生每个 Provider 根目录。用户只在导入 Workspace 时提交目录路径;注册后,技能读写使用 daemon 验证的 `WorkspaceProviderTarget`、opaque Workspace ID 和 Skill ID,不由 WebUI 拼接输出路径。
65
57
 
66
- # Non-interactive installation with explicit default scope resolution
67
- skill-creator init --scope auto
58
+ Provider catalog 是 [vercel-labs/skills](https://github.com/vercel-labs/skills) `src/agents.ts` 的审阅快照,运行时位于 `src/shared/provider-catalog.ts`。本地研究检出说明见 [references/README.md](references/README.md);它不是运行时或发布依赖。
68
59
 
69
- # Machine-readable installation output for tooling/subagents
70
- skill-creator init-cc --json
60
+ ```text
61
+ /creator
62
+ |-- no query ----------------------------------- blank draft in the first writable Workspace.Provider
63
+ |-- ?workspace=ws_*&provider=<provider> -------- blank draft in that Imported Workspace.Provider
64
+ `-- ?workspace=ws_*&provider=<provider>&skill=sk_* -- revision-safe edit
71
65
 
72
- # Machine-readable documentation sync output
73
- skill-creator download-context7 --pwd ~/.claude/skills/zustand@5 --package zustand --package-version 5.0.0 --json
66
+ skill without workspace / invalid ID ---- redirect to canonical /creator
74
67
 
75
- # Machine-readable user-note output
76
- skill-creator add-skill --package zustand --title "Best Practices" --content "Your custom notes" --json
77
-
78
- # Machine-readable index build output
79
- skill-creator build-index --pwd ~/.claude/skills/zustand@5 --json
68
+ Repository install
69
+ `-- selected skills x selected Workspace.Provider targets
70
+ -> daemon-verified local Skill IDs -> Review installed -> Creator edit
80
71
  ```
81
72
 
82
- ### 3. Choose Your Usage Mode
83
-
84
- #### CLI Mode - Full Control
73
+ ## 环境要求
85
74
 
86
- Use commands directly for complete control over the skill creation process.
75
+ - Node.js `>=20`
76
+ - Bun `>=1.3`(开发与构建脚本)
77
+ - pnpm `>=10`
78
+ - Git,可被当前进程通过 `git` 命令调用
79
+ - macOS、Windows(`arm64` / `x64`)或 Linux
87
80
 
88
- #### Subagent Mode - Effortless
81
+ macOS 与 Windows 使用 `@opentray/ext-webview` 承载原生应用窗口(`appMode: true` 进入任务栏/Dock 与应用切换器;窗口焦点、层级和关闭由系统管理)。Linux 上 `@opentray/ext-webview` 没有原生包,默认进入 **web 模式**:daemon 只挂载纯 opentray 通知栏图标(菜单 + 图标),WebUI 在系统浏览器中打开。任何平台都可用 `--web` / `--no-web` 显式覆盖。
89
82
 
90
- Simply describe what you want, and let the subagent handle everything automatically.
83
+ ## 安装与开发
91
84
 
92
- ```
93
- User: Use skill-creator subagent to help me create a vitest skill
94
-
95
- User: Tell me about vitest testing patterns
96
- ```
97
-
98
- The skill-creator subagent will handle the entire workflow automatically.
99
-
100
- ### 4. Create a Skill by cli
85
+ 根目录是 pnpm workspace,包含 `webui`。只需安装一次:
101
86
 
102
87
  ```bash
103
- # Search for packages
104
- skill-creator search "react query"
105
-
106
- # Get package information (Options)
107
- skill-creator get-info @tanstack/react-query
108
-
109
- # Create skill with package identity only
110
- skill-creator create-cc-skill --scope user --name "@tanstack/react-query" --description "React Query for data fetching" @tanstack/react-query@5 --json
111
-
112
- # Create skill with a custom visible skill name while keeping the source package identity
113
- skill-creator create-cc-skill --scope user --name "@tanstack/react-query" --skill-name "react-query" --description "React Query for data fetching" @tanstack/react-query@5 --json
114
-
115
- # Let the CLI choose the default storage scope automatically
116
- skill-creator create-cc-skill --scope auto --name zod --description "Zod validation skill" zod@4 --json
117
-
118
- # Create skill with interactive prompts
119
- skill-creator create-cc-skill --scope user --interactive --description "React Query for data fetching" @tanstack/react-query@5
120
-
121
- # Resolve the best Context7 project id
122
- skill-creator resolve-context7 @tanstack/react-query
123
-
124
- # If no package-path candidate matches reliably, the command exits instead of returning a wrong website mirror
125
- skill-creator resolve-context7 is-odd --package-version 3.0.1
126
-
127
- # Download documentation directly from the package name
128
- skill-creator download-context7 --package @tanstack/react-query --package-version 5.0.0
129
-
130
- # If the skill was created from a package, the package metadata is stored in SKILL.md
131
- # so the same download can usually be triggered with only the skill path
132
- skill-creator download-context7 --pwd ~/.claude/skills/@tanstack__react-query@5
133
-
134
- # Or download with an explicit resolved Context7 id
135
- skill-creator download-context7 --package @tanstack/react-query /tanstack/react-query
136
-
137
- # Search your skill knowledge base
138
- skill-creator search-skill --package @tanstack/react-query "useQuery hook"
139
-
140
- # Append a structured knowledge update into the closest matching user note
141
- skill-creator add-skill --package @tanstack/react-query --title "Bundle guidance" --content "Prefer React Query cache ownership conventions in bundle-sensitive apps." --force-append
142
- ```
143
-
144
- ## Commands
145
-
146
- ### Installation & Setup
147
-
148
- | Command | Description |
149
- | --------- | ----------------------------------------------------------- |
150
- | `init` | Install skill-creator as Claude Code subagent (`user`, `current`, or `auto`) |
151
- | `init-cc` | Install skill-creator as subagent in user directory |
152
-
153
- ### Skill Creation (CLI Mode)
154
-
155
- | Command | Description |
156
- | ------------------------ | -------------------------------- |
157
- | `search <keywords>` | Search npm packages |
158
- | `get-info <package>` | Get detailed package information |
159
- | `resolve-context7 <package>` | Resolve the best Context7 library id |
160
- | `create-cc-skill <name>` | Create a new skill directory |
161
-
162
- ### Content Management
163
-
164
- | Command | Description |
165
- | -------------------------------- | ----------------------------------------- |
166
- | `download-context7 [project_id]` | Download and slice Context7 documentation |
167
- | `build-index` | Build or refresh the local search index |
168
- | `search-skill <query>` | Search in skill knowledge base |
169
- | `add-skill` | Add custom knowledge to skill |
170
-
171
- > **Tip**: When using the skill-creator as a subagent, you don't need to remember these commands. Just tell Claude what you want to create, and the subagent will handle the entire workflow automatically.
172
-
173
- ### Options
174
-
175
- - `--scope <user|current|auto>`: Storage location for skills (required). `auto` resolves to `current` when `.claude/agents/skill-creator.md` exists, otherwise `user`
176
- - `--name <name>`: Package name for the skill (recommended)
177
- - `--skill-name <name>`: Visible skill name written into `SKILL.md`. When omitted, the visible skill name defaults to `--name` when present, otherwise `skill_dir_name`
178
- - `--pwd <path>`: Working directory for skill operations
179
- - `--package <name>`: Use package name to find skill directory
180
- - `--package-version <version>`: Version hint for Context7 library resolution
181
- - `--description <description>`: Custom description for the skill
182
- - `--force`: Replace the closest matching user knowledge note when adding content
183
- - `--force-append`: Append a structured knowledge update into the closest matching user note
184
- - `--skip-indexing`: Skip automatic local index building
185
- - `--interactive`: Enable interactive prompts
186
- - `--json`: Print machine-readable output for `init`, `init-cc`, `create-cc-skill`, `download-context7`, `add-skill`, and `build-index`
187
-
188
- When `--package <name>` is used to find an existing skill, the CLI first checks the
189
- `<skill-package ...>` metadata stored in `SKILL.md`. Directory-name matching is only a fallback.
190
-
191
- ## Workflow
192
-
193
- ### Complete Skill Creation Workflow
194
-
195
- 1. **Search Package**: Find the right package for your skill
196
-
197
- ```bash
198
- skill-creator search "state management"
199
- ```
200
-
201
- 2. **Get Package Info**: Retrieve detailed information
202
-
203
- ```bash
204
- skill-creator get-info zustand
205
- ```
206
-
207
- 3. **Create Skill**: Set up skill directory (requires --scope, recommended to use --name)
208
-
209
- ```bash
210
- # With source package identity only
211
- skill-creator create-cc-skill --scope current --name zustand --description "Zustand state management" zustand@5 --json
212
-
213
- # With a separate visible skill name
214
- skill-creator create-cc-skill --scope current --name @tanstack/router --skill-name router-skill --description "Router workflow skill" tanstack-router@1 --json
215
-
216
- # With explicit default scope resolution handled by the CLI
217
- skill-creator create-cc-skill --scope auto --name zod --description "Zod validation skill" zod@4 --json
218
-
219
- # With interactive prompts
220
- skill-creator create-cc-skill --scope current --interactive zustand
221
- ```
222
-
223
- `--name` records the source package identity for later package-aware workflows. `--skill-name` only controls the visible skill title written into `SKILL.md`.
224
-
225
- 4. **Resolve Context7 Project ID**: Pick the strongest Context7 source for the package
226
-
227
- ```bash
228
- skill-creator resolve-context7 zustand --package-version 5.0.0
229
- ```
230
-
231
- 5. **Download Documentation**: Get Context7 docs with automatic indexing
232
-
233
- ```bash
234
- # Simplest path when the skill already stores package metadata
235
- skill-creator download-context7 --pwd ~/.claude/skills/zustand@5
236
-
237
- # One-step path: resolve and download from the package name
238
- skill-creator download-context7 --package zustand --package-version 5.0.0
239
-
240
- # Two-step path: supply the explicit Context7 project id
241
- skill-creator download-context7 --package zustand /zustand
242
- ```
243
-
244
- 6. **Add Custom Knowledge**: Enhance with your own content
245
-
246
- ```bash
247
- skill-creator add-skill --package zustand --title "Best Practices" --content "Your custom notes"
248
-
249
- # Replace the closest existing user note
250
- skill-creator add-skill --package zustand --title "Best Practices" --content "Updated note" --force
251
-
252
- # Append a structured update into the closest existing user note
253
- skill-creator add-skill --package zustand --title "Operational update" --content "Additional guidance" --force-append
254
- ```
255
-
256
- 7. **Search Knowledge Base**: Query your skill
257
- ```bash
258
- skill-creator search-skill --package zustand "typescript patterns"
259
- ```
260
-
261
- ## Directory Structure
262
-
263
- ```
264
- .claude/skills/
265
- └── package@version/
266
- ├── assets/
267
- │ ├── references/
268
- │ ├── context7/ # Auto-sliced Context7 docs
269
- │ └── user/ # Custom knowledge files
270
- │ └── search/ # Local search indexes and state
271
- └── SKILL.md # Skill documentation
88
+ pnpm install
272
89
  ```
273
90
 
274
- ## Development
275
-
276
- ### Development Setup
91
+ 启动带 HMR 的 WebUI 与开发 daemon:
277
92
 
278
93
  ```bash
279
- # Install dependencies
280
- npm install
281
-
282
- # Development mode with watch
283
- npm run dev
284
-
285
- # Build TypeScript
286
- npm run build
287
-
288
- # Run tests
289
- npm test
290
-
291
- # Run tests with coverage
292
- npm run test:coverage
293
-
294
- # Type check
295
- pnpm ts
94
+ pnpm dev # 默认(macOS/Windows 用原生窗口)
95
+ pnpm dev --web # 强制 web 模式:纯 tray + 浏览器,无原生窗口
96
+ pnpm dev --no-web # 强制 windowed 模式(覆盖 Linux 默认)
296
97
  ```
297
98
 
298
- ### Testing Context7 Integration
99
+ `pnpm dev` 由 `scripts/dev.sh.ts` 包装:它拦截 `--web` / `--no-web` 转成 `SKILL_CREATOR_WEB` env(vite 本身不容忍未知 flag),其余参数原样透传给 vite。Vite 会先释放正式 daemon 与上一棵开发进程树,再分配 daemon 端口,于 SvelteKit SPA fallback 之前挂载 `/api/` 与 `/ws/` 代理,并挂载开发态 OpenTray。重复执行 `pnpm dev` 不需要手动清理旧 socket;接管会等待旧 daemon 的 PID 和 IPC endpoint 同时释放。daemon 启动窗口返回可重试 `503`,不会把 API 请求误回退为 `index.html`。macOS 开发态的 home 默认为 `/tmp/sc-v2`,因此应用状态位于 `/tmp/sc-v2/.skill-creator/`,不会读写正式用户状态。Windows 使用系统临时目录下的 `skill-creator-v2-dev`。
299
100
 
300
- To test the built-in Context7 workflow during development:
101
+ 构建与完整静态检查:
301
102
 
302
103
  ```bash
303
- skill-creator resolve-context7 vitest --package-version 4.1.7
304
- skill-creator download-context7 --help
104
+ pnpm build
105
+ pnpm check
305
106
  ```
306
107
 
307
- ### Verifying Installed Binaries During Development
308
-
309
- When validating the real installed CLI during local development, prefer isolated install roots instead of relying on your machine's global package manager state:
310
-
311
- ```bash
312
- # Source-mode workflow verification
313
- pnpm verify:workflow
314
-
315
- # Published-style installed binary verification in an isolated prefix
316
- pnpm verify:installed
108
+ `pnpm build` 产出:
317
109
 
318
- # Source-linked binary verification in an isolated prefix
319
- pnpm verify:linked
110
+ ```text
111
+ dist/
112
+ |-- cli.js # skill-creator bin
113
+ |-- daemon.js # daemon entry
114
+ |-- package.json # daemon/CLI version truth
115
+ `-- webui/ # static SvelteKit SPA
320
116
  ```
321
117
 
322
- These workflow gates now also prove the vector-runtime contract:
118
+ ## CLI
323
119
 
324
- - if the local runtime supports `node:sqlite` and `sqlite-vec`, the verification path builds and queries a real `--mode=vector` index
325
- - otherwise, the verification path proves that the CLI returns the expected runtime-support error
120
+ 构建后可在仓库内使用 `pnpm skill-creator <command>`;作为包安装后使用 `skill-creator <command>`。
326
121
 
327
- If you still want a linked local binary for ad hoc manual testing, use an isolated prefix:
122
+ | Command | 行为 |
123
+ | --------------- | ----------------------------------------------------------------------------------------------------------------------------- |
124
+ | `start` | 启动 daemon,等待 WebUI 与 tray 完成挂载,然后显示原生窗口;web 模式打开浏览器;headless 时只提示 `openinbrowser`,不自动打开 |
125
+ | `start --web` | 以 web 模式启动:只挂纯 tray 图标(菜单 + 图标),不创建原生窗口,WebUI 在系统浏览器打开(Linux 默认) |
126
+ | `open` | 显示并聚焦现有 tray 窗口;web 模式降级为打开浏览器;headless 时不可用并提示 `openinbrowser` |
127
+ | `openinbrowser` | 显式在系统浏览器打开当前 daemon 的带 token WebUI URL |
128
+ | `status` | 输出 PID、版本、HTTP 端口、tray 状态(mounted/web/headless)和可用的 tray 错误 |
129
+ | `stop` | 停止正式 daemon;若正式 endpoint 不存在则发现开发 daemon,并等待 endpoint 释放 |
130
+ | `version` | 输出包版本 |
131
+ | `help` | 输出命令帮助 |
328
132
 
329
133
  ```bash
330
- TMP_PREFIX="$(mktemp -d /tmp/skill-creator-link-XXXXXX)"
331
- npm_config_prefix="$TMP_PREFIX" npm link
332
- PATH="$TMP_PREFIX/bin:$PATH" skill-creator --help
134
+ pnpm build
135
+ pnpm skill-creator start
136
+ pnpm skill-creator start --web # 强制 web 模式(纯 tray + 浏览器)
137
+ pnpm skill-creator status
138
+ pnpm skill-creator open
139
+ pnpm skill-creator openinbrowser
140
+ pnpm skill-creator stop
333
141
  ```
334
142
 
335
- This avoids toolchain managers such as Volta interfering with the linked executable.
336
-
337
- If you intentionally skip indexing during documentation download, rebuild it explicitly with:
338
-
339
- ```bash
340
- skill-creator build-index --pwd ~/.claude/skills/zustand@5
143
+ 以上命令在构建产物(`dist/`,与发布包同内容)上实测:`start` headless 输出恢复提示并以退出码 0 返回;`status` 输出 pid/版本/端口/tray 终态、DSH 宿主健康行(`--json` 输出完整状态)与带 token 的 WebUI URL;`open` 在 headless 态不可用并提示 `openinbrowser`;`openinbrowser` 打印并调用系统浏览器;`stop` 后 HTTP endpoint 立即释放,再次 `status` 报 ENOENT 并给出 `start` 恢复入口。发布包在仓库外空目录 `npm install <tarball>` 后同样以黑盒方式完成 start/status/stop/restart 实测(ccski 已打入产物,无 `link:` 依赖;复现:`bun scripts/clean-install-check.sh.ts`,证据见 `docs/release/skill-steward.md`)。运行要求 Node `>=22.13.0`(DSH code-runtime 依赖 `node:module` 的 `stripTypeScriptTypes`)。
144
+
145
+ ## 技能管家(Skill Steward)
146
+
147
+ 技能管家是 Manager-owned 的维护工作流:选择任务与范围 → 运行 → 审阅证据 → 人工批准 → 应用 → 必要时回滚。入口在 Workspaces 的 provider 视图 **Workflow** 标签。
148
+
149
+ ## Agent 面板与 MCP 能力面
150
+
151
+ - **Agent 面板**:shell 级右栏 drawer(≥720px 常驻 440px,窄屏单屏覆盖),跨 tab 存活。会话列表/新建/切换、对话流(工具行可展开输入/结果)、ask_user_question 审批卡、model/preset/approval 配置投影;断线可见与恢复。
152
+ - **headless 内核**:daemon 内 boot 单 `dsh-base` bundle(无 DSH webui/HTTP 面);产品 preset 只含 persona + ask-user,bash/fs/web 等通用工具行禁用;官方 `@deepseek-ai/dsh-mcp-client` 桥把 Manager 能力注册为 `mcp__skill-creator__*` 工具。
153
+ - **MCP 面**:`/mcp`(loopback + Bearer web token,stateless streamable HTTP)与 `skill-creator mcp`(stdio,readonly 收窄)同一实现;技能文档另有只读 resource 模板。工具结果按能力面自动附带 `ui://` 视觉卡(skill 信息/finding/proposal/安装结果,含应用内跳转),面板以沙箱 iframe 渲染,不可信文本强制转义。
154
+ - **authority 红线**:MCP mutation 一律产 proposal(`*_propose` 工具)待人工在面板审批后经 Manager 执行;Manager 永远拥有路径、revision、启停、安装、更新与审批 authority。
155
+
156
+ ### 模型配置
157
+
158
+ - 打开 Workflow 标签即显示当前 runtime config(模型、preset、approval 策略、revision)。preset 为 `deterministic`(内置脚本化 transport,零凭据、可离线)或 `live`(真实 provider)。
159
+ - 切到 `live` 需要先为所选 provider 写入 API key(凭据存 daemon 私有文件 `0600`,UI 只回显 configured 状态,永不回显值)。
160
+ - approval 策略 `ask` / `never` 只影响 agent 运行时的交互策略;**apply 永远要求人工批准的一次性 grant**,该策略不构成授权放宽。
161
+
162
+ ### 维护流程
163
+
164
+ 1. 选任务:`Check`(只读体检)、`Optimize`(编辑优化)、`Organize`(拆分/合并/启停整理)。
165
+ 2. 选范围:勾选技能子集(留空 = 整个 Provider),可附加上限 2000 字的补充指令。
166
+ 3. `Run`:daemon 建快照、agent 通过五个域白名单工具执行(每次调用回 Manager registry 审计),产出提案。
167
+ 4. 审阅:每张提案卡 `Validate`(逐项 checks)→ `Approve`(铸造一次性 grant,绑定 patch fingerprint 与全部输入 revision)→ `Apply`(journaled 事务;mutation diff 表列出 relPath/语义/revision 变化)。
168
+ 5. 回滚:`Prepare rollback` 后按提案类型二选一——启停类逆操作是反向提案(需再走 Approve reverse / Apply reverse);拆分/合并类直接 `Rollback (replay)` 反向重放 journal。磁盘逐字节恢复由事务层保证。
169
+
170
+ ### 恢复流程
171
+
172
+ - **DSH 内核不可用**(缺包/版本不符/插件失败):daemon 显式降级为 Manager-only 面(无 Agent 会话;`agent.*` 返回 typed UNAVAILABLE),`status` 的 `dsh` 字段携带降级原因;重启 daemon 是恢复内核的入口。
173
+ - **apply 终态 `recovery-required` / `compensated`**:提案卡显示横幅与 daemon 侧失败原因;`compensated` 表示事务内已自动回滚,`recovery-required` 表示需要按提示处理残留(文件状态被保全,不静默覆盖)。处理后重新运行任务生成新提案——revision 漂移的旧提案在 validation 即被拒绝(`stale`)。
174
+ - **断线重连**:任务/范围选择、runtime config 与最近一次 run 投影跨重连存活;迟到响应一律不覆盖新状态。
175
+ - **daemon 重启**:`skill-creator stop && skill-creator start`;未消费的审批 grant 全部失效(不重放授权),需要重新批准。
176
+
177
+ ## 运行架构
178
+
179
+ ```text
180
+ src/cli/cli.ts
181
+ |
182
+ | length-prefixed JSON frame
183
+ | protocolVersion + clientVersion
184
+ v
185
+ src/daemon/ipc-server.ts ---------------------- single-instance owner
186
+ |
187
+ +--> src/daemon/index.ts ------------------ lifecycle/status
188
+ | |-- WebServer @ 127.0.0.1:random -- SPA + /ws/rpc + /mcp (MCP face)
189
+ | |-- dsh-host-lifecycle.ts -------- headless DSH kernel mount
190
+ | | (failure degrades to manager-only)
191
+ | `-- TrayHost -> OpenTray ext-webview
192
+ |
193
+ +--> src/daemon/rpc-router.ts
194
+ `--> domain.ts ------------------ one daemon composition root
195
+ |-- workspace-registry/ -- persisted truth + dynamic projection
196
+ |-- skill-service.ts ----- ccski adapter
197
+ |-- creator-service.ts --- revision-safe document writes
198
+ |-- repository-service.ts pinned clone lifecycle
199
+ |-- source-registry.ts --- curated + user Discover sources
200
+ |-- skills-update-service.ts lock-hash update check/apply
201
+ |-- steward/ --------------- Skill Steward pipeline + journal
202
+ | `-- dsh-session-binder -- run↔kernel session + stream frames
203
+ |-- kernel/ ---------------- headless dsh-base boot + agent
204
+ | |-- dsh-kernel ------- profile + tool-surface policy + MCP row
205
+ | |-- agent-sessions --- panel sessions + stream + answerer
206
+ | `-- product-prompt --- versioned best-practices section
207
+ |-- mcp/ -------------------- skill-creator MCP server
208
+ | |-- skill-creator-mcp - capability tools + resources
209
+ | |-- cards ------------- ui:// card templates (escaped)
210
+ | `-- proposals --------- mutation→proposal approval chain
211
+ |-- capability/ ------------- capability-core + domain registry
212
+ |-- dsh-settings.ts ------- model/preset/permissions
213
+ `-- acp-bridge-service.ts [internal legacy] agent subprocess + fs security gate(产品入口已移除,3.2)
214
+
215
+ src/shared/rpc-contract.ts
216
+ ^ ^
217
+ | runtime schemas | inferred client types
218
+ daemon webui/src/lib/rpc-client.ts
341
219
  ```
342
220
 
343
- `build-index` supports the same persistent index modes as the runtime:
344
-
345
- - `--mode=auto`: build the default lightweight persisted index path
346
- - `--mode=fulltext`: build the explicit MiniSearch index
347
- - `--mode=vector`: build the explicit SQLite vector index when the runtime supports it
221
+ 浏览器安全的契约由 `src/shared/rpc-contract.ts` 统一组合,具体 schema 物理拆分在 `src/shared/contracts/`:
222
+
223
+ | RPC module | Procedures |
224
+ | -------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
225
+ | `skills` | `list`, `info`, `toggle`, `validate`, `update.check`, `update.apply` |
226
+ | `workspace` | `list`, `add`, `remove`, `setActive` |
227
+ | `creator` | `save`, `load`, `remove`, `revisions` |
228
+ | `repository` | `scan`, `preview`, `install`, `sources.list`, `sources.add`, `sources.remove` |
229
+ | `daemon` | `status` |
230
+ | `skillSteward` | `startRun`, `validate`, `approve`, `apply`, `prepareRollback`, `applyRollback`(人类审批面;apply/rollback 为 journaled 事务) |
231
+ | `agent` | `sessions.list/streams`, `session.create/prompt/cancel/stream/answer`, `card.get`, `proposals.list/approve/reject`, `settings.get/update`, `credentials.set/clear`(面板 + 审批链 + 配置投影) |
232
+ | `acp` | `agents.list`, `session.open`, `session.close`(internal legacy,非产品入口) |
233
+
234
+ WebUI 直接从共享契约推导 client 类型;daemon 通过同一契约实现 handler。网络输入和输出都经过 Zod runtime validation。
235
+
236
+ Workspace 列表、Skill 列表/详情和 Repository 扫描/预览分别使用独立请求代次;新请求、作用域切换或 RPC client 更替会使旧响应失去提交资格,避免慢响应覆盖新界面状态。失效的读写请求不会触发新连接的后续刷新或导航;Creator 已接纳的 dirty draft 不因断线重连被清空。
237
+
238
+ ## 安全模型
239
+
240
+ ```text
241
+ explicit import path
242
+ |
243
+ v
244
+ realpath + directory check --> ws_<digest> --> server registry
245
+ |
246
+ WebUI mutation -----------------------------+--> server resolves root
247
+ workspaceId + providerId + skillId |
248
+ +--> containment check
249
+ +--> atomic write
250
+
251
+ Git source + ref --> temporary clone --> commit SHA --> repo_<session>
252
+ |
253
+ preview/install --+--> same snapshot
254
+ ```
348
255
 
349
- For offline or deterministic local vector verification, pass an explicit embedder:
256
+ - HTTP 仅监听 `127.0.0.1`。`/api/health` 和静态 SPA 不执行文件系统 mutation。
257
+ - daemon 每次启动生成 32-byte Web token。token 经 URL fragment 交给 WebUI,捕获到当前标签页的 `sessionStorage` 后从地址栏移除;`/ws/rpc` 在升级前校验 token。
258
+ - IPC endpoint 是单例锁。macOS 上 runtime 目录权限为 `0700`、socket 为 `0600`;Windows 使用 `\\.\pipe\skill-creator-sock`。
259
+ - Workspace、Provider、Skill、Repository Session 与 Remote Skill 均由 server 生成或验证的身份约束。除 `workspace.add` 的显式导入和 `repository.scan` 的 Git source 外,mutation 不接受调用方输出路径。
260
+ - daemon 生命周期内只有一个内存 Workspace Registry。持久路径必须绝对且规范化,`ws_*` 必须与路径 digest 相符;导入、移除和切换先原子提交完整 next state,再替换内存状态。`skillCount` 与可用性只在读取时派生,永不写入 registry。
261
+ - Creator 新建只允许已导入 Workspace.Provider 的直接子目录;编辑和删除必须仍在该 Provider root 内。文档使用临时文件加 rename 原子落盘,update/delete 以 SHA-256 revision 拒绝陈旧操作。
262
+ - Repository 扫描先 clone,再用 Zod 收窄 HEAD commit。预览和安装复用同一临时快照与 session ID;淘汰立即拒绝新操作,但会让已接受的安装持有快照直到完成。daemon stop 会终止 pending clone,且 late scan 不得重新登记 session。
263
+ - Repository 安装不能指向 `~`;每个目标必须是一个已导入、可写的 Workspace.Provider。多选目标会得到逐 skill、逐目标的独立结果。
264
+ - Repository 安装汇总携带提交时的 Workspace.Provider target;ccski installer output 先经 runtime schema 收窄,只有实际 `installed` / `overwritten` 且重新验证为 Provider root 直属、非符号链接 `SKILL.md` 目录的结果项会获得本地 Skill ID,供 Creator 复核。
265
+ - daemon 在 tray mount 前发布 stop coordinator 与 signal listeners。stop 先关闭 HTTP/WebSocket 与 IPC admission,再并行回收 Repository、tray 与连接;mount 期间迟到的 native handles 会被立即销毁,非协作 socket 在 grace deadline 后强制关闭,并发 stop 合并为同一完成态。
266
+ - 所有外部读取先解码为 `unknown`,再用当前 Zod schema `safeParse`。配置文件、未来数据库记录和第三方/网络返回中不兼容的快照按其领域投影为空,集合丢弃无效项,不能读取为安全空值的结果返回类型化失败;RPC/IPC、鉴权、路径和 mutation 输入仍明确拒绝,绝不降级为空。
267
+ - 当前 v2 registry 没有旧 schema 的迁移层。JSON 语法错误或不符合当前 Zod schema 的旧状态整体按空值加载:不读取、不转换、不在加载时写回;下一次正常 workspace mutation 才原子提交当前 v2 状态。文件 I/O 错误仍拒绝启动并写入当前 home 下的 `.skill-creator/logs/daemon.log`。当前没有数据库实现;引入后数据库读取必须遵循同一投影法则。
268
+
269
+ ## 状态路径
270
+
271
+ | 状态 | macOS / release | Windows / release |
272
+ | ------------------ | ----------------------------------------- | ---------------------------------------------- |
273
+ | 应用目录 | `~/.skill-creator/` | `%USERPROFILE%\.skill-creator\` |
274
+ | Workspace registry | `~/.skill-creator/workspaces.json` | `%USERPROFILE%\.skill-creator\workspaces.json` |
275
+ | 用户 Repository 源 | `~/.skill-creator/sources.json` | `%USERPROFILE%\.skill-creator\sources.json` |
276
+ | Daemon log | `~/.skill-creator/logs/daemon.log` | `%USERPROFILE%\.skill-creator\logs\daemon.log` |
277
+ | IPC | `~/.skill-creator/run/skill-creator.sock` | `\\.\pipe\skill-creator-sock-<home-digest>` |
278
+
279
+ `SKILL_CREATOR_HOME` 可覆盖当前命令的 home 根目录;应用仍在该目录下创建 `.skill-creator/`。`SKILL_CREATOR_DEV_HOME` 专门覆盖开发 runtime 的发现路径;macOS 默认对应 `/tmp/sc-v2/.skill-creator/`。
280
+
281
+ ## 验证
350
282
 
351
283
  ```bash
352
- skill-creator build-index --pwd ~/.claude/skills/zustand@5 --mode vector --vector-embedder deterministic
353
- skill-creator search-skill --pwd ~/.claude/skills/zustand@5 --mode vector --vector-embedder deterministic "query ownership"
284
+ pnpm test
285
+ pnpm typecheck
286
+ pnpm --dir webui check
287
+ pnpm build
288
+ pnpm exec vp fmt --check
289
+ git diff --check
290
+ npm pack --dry-run
354
291
  ```
355
292
 
356
- `--vector-embedder deterministic` switches vector mode to the built-in local deterministic embedder instead of the default runtime embedder.
357
-
358
- `--mode=fuzzy` is intentionally rejected because fuzzy search does not use a standalone persisted index.
359
-
360
- ### Release Readiness
361
-
362
- `pnpm pre-release-check` is a release gate, not a diagnostic summary. It now fails when:
363
-
364
- - the current `package.json` version is already published to npm
365
- - the published npm version cannot be verified
366
-
367
- That means a green result is evidence that the repository is both technically verified and version-ready for release.
368
-
369
- ## Search Modes
370
-
371
- - `auto`: default path, tries full-text first and falls back to fuzzy when quality is weak
372
- - `fulltext`: explicit MiniSearch-backed local index
373
- - `fuzzy`: explicit `uFuzzy` fallback for path/term-style matching
374
- - `vector`: explicit SQLite vector search path when the local runtime supports it
375
-
376
- `chroma` remains accepted only as an undocumented legacy alias for `vector`.
377
-
378
- ## Architecture
379
-
380
- - **TypeScript + ESM**: Modern JavaScript with full type safety
381
- - **Search Runtime**: MiniSearch-backed local full-text indexing by default, with explicit vector mode available when runtime support exists
382
- - **Context7 API**: Automated documentation downloading and slicing
383
- - **CLI-first Design**: Professional command-line interface
384
- - **Modular Architecture**: Clean separation of concerns
385
-
386
293
  ## License
387
294
 
388
295
  MIT
389
-
390
- ---
391
-
392
- _For detailed subagent usage, see `templates/skill-creator.md`_