dsh-skill-hub 0.2.6 → 0.3.1

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 (41) hide show
  1. package/README.md +68 -229
  2. package/README.zh.md +67 -203
  3. package/lib/client.js +1955 -413
  4. package/lib/client.js.map +1 -1
  5. package/lib/index.js +441 -84
  6. package/lib/types/client/SkillHubSettingsCard.d.ts +1 -1
  7. package/lib/types/client/api.d.ts +12 -2
  8. package/lib/types/client/index.d.ts +6 -1
  9. package/lib/types/client/locales.d.ts +13 -0
  10. package/lib/types/client/panel/ScenesView.d.ts +1 -1
  11. package/lib/types/client/panel/SourcesView.d.ts +1 -1
  12. package/lib/types/client/panel/useSkillHub.d.ts +20 -2
  13. package/lib/types/client/settings-form.d.ts +1 -1
  14. package/lib/types/client/slash-dots.d.ts +2 -1
  15. package/lib/types/index.d.ts +2 -1
  16. package/lib/types/protocol.d.ts +93 -6
  17. package/lib/types/repo.d.ts +18 -11
  18. package/lib/types/store.d.ts +14 -2
  19. package/package.json +38 -29
  20. package/src/client/SkillHubSettingsCard.tsx +1 -1
  21. package/src/client/api.ts +61 -1
  22. package/src/client/index.tsx +10 -1
  23. package/src/client/locales.ts +26 -0
  24. package/src/client/panel/MarketView.tsx +201 -47
  25. package/src/client/panel/ScenesView.tsx +27 -2
  26. package/src/client/panel/SkillHubPanel.tsx +18 -19
  27. package/src/client/panel/SkillRow.tsx +8 -8
  28. package/src/client/panel/SourcesView.tsx +203 -26
  29. package/src/client/panel/panel.module.css +17 -6
  30. package/src/client/panel/useSkillHub.ts +219 -12
  31. package/src/client/settings-form.ts +2 -1
  32. package/src/client/slash-dots.test.ts +24 -6
  33. package/src/client/slash-dots.tsx +10 -1
  34. package/src/index.ts +20 -2
  35. package/src/protocol.ts +89 -6
  36. package/src/repo.test.ts +61 -19
  37. package/src/repo.ts +86 -23
  38. package/src/routes.test.ts +18 -4
  39. package/src/routes.ts +269 -47
  40. package/src/skillfs.ts +17 -4
  41. package/src/store.ts +72 -4
package/README.md CHANGED
@@ -7,291 +7,130 @@
7
7
  <img alt="downloads" src="https://img.shields.io/npm/dm/dsh-skill-hub">
8
8
  <img alt="license" src="https://img.shields.io/npm/l/dsh-skill-hub">
9
9
  <img alt="node" src="https://img.shields.io/badge/node-%3E%3D22.19-339933">
10
- <a href="https://github.com/cheshireez/dsh-skill-hub/actions"><img alt="CI" src="https://img.shields.io/github/actions/workflow/status/cheshireez/dsh-skill-hub/ci.yml?branch=main"></a>
11
10
  </p>
12
11
 
13
12
  <p align="center">
14
13
  <img src="https://raw.githubusercontent.com/cheshireez/dsh-skill-hub/main/promo/real-skill-hub.png" alt="dsh-skill-hub panel" width="640">
15
14
  </p>
16
15
 
17
- **In-GUI skill hub for [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) (dsh).**
18
- Browse the full local skill catalog from the official `ctx.skills` registry, toggle skills on/off, inspect
19
- their bodies, understand why a skill is missing, install from the built-in market, and scaffold new
20
- ones — all from the dsh web GUI.
16
+ In-GUI skill hub for [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) — browse the full `ctx.skills` catalog, toggle skills, inspect bodies, diagnose missing skills, install from the market, and scaffold new ones.
21
17
 
22
- > A skill manager beyond the read-only browser. The host half runs in the dsh process and speaks only
23
- > official SDKs; the browser half renders inside the GUI through official slots. No dsh source changes.
18
+ > Host runs in the dsh process via official SDKs only; browser renders through official slots. No dsh source changes.
24
19
 
25
- > **Disclaimer** source tracking, market sync, and the restorable trash are implemented by this
26
- > plugin; they are not guarantees of the dsh runtime itself. Screenshots may lag the latest UI.
20
+ ## Why not just the read-only browser?
27
21
 
28
- ## Table of Contents
22
+ [dsh-skill-manager](https://www.npmjs.com/package/dsh-skill-manager) browses, [dsh-skill-importer](https://github.com/saitamahang/dsh-skill-importer) / [dsh-find-skill](https://github.com/Moximxxx/dsh-find-skill) import. **This plugin is the manager in between.**
29
23
 
30
- - [Why another skill manager?](#why-another-skill-manager)
31
- - [Features](#features)
32
- - [Quick start](#quick-start)
33
- - [How it works](#how-it-works)
34
- - [Usage](#usage)
35
- - [Troubleshooting](#troubleshooting)
36
- - [HTTP API](#http-api)
37
- - [Development](#development)
38
- - [Community](#community)
39
- - [License](#license)
40
-
41
- ## Why another skill manager?
42
-
43
- [dsh-skill-manager](https://www.npmjs.com/package/dsh-skill-manager) is a read-only browser,
44
- [dsh-skill-importer](https://github.com/saitamahang/dsh-skill-importer) and
45
- [dsh-find-skill](https://github.com/Moximxxx/dsh-find-skill) focus on importing and market-style installs.
46
- **dsh-skill-hub fills the gap between them: a full catalog you can actually manage.**
47
-
48
- | Capability | dsh-skill-manager (read-only) | **dsh-skill-hub (this plugin)** |
24
+ | Capability | read-only browser | **dsh-skill-hub** |
49
25
  | --- | --- | --- |
50
- | Catalog source | self-scans disk, user roots only | official `ctx.skills` registry: project / custom / user / bundled + third-party providers |
51
- | Browse / search | ✅ | (group by **tags** or by **source repo**, search + filter in one row) |
52
- | Workspace skills | ❌ | ✅ (enter a project path its `.dsh/skills` & `.agents/skills` appear, read-only) |
53
- | Enable / disable | ❌ | ✅ (renames `SKILL.md`; file never deleted, always restorable; per-group tri-state switches) |
54
- | Inspect skill body | ❌ | ✅ |
55
- | Discovery diagnostics | ❌ | ✅ (missing frontmatter / missing `name`/`description` / invalid name each reason listed) |
56
- | New-skill wizard | ❌ | ✅ (writes to `~/.dsh/skills` or `~/.agents/skills`) |
57
- | Invocation statistics | ❌ | ✅ (per-skill call counts read from session logs; group headers summarize) |
58
- | Upstream source tracking | ❌ | ✅ (repo + commit snapshot; check updates, sync, follow upstream deletion into a restorable trash; delete/restore keeps source + scene membership) |
59
- | Market | ❌ | ✅ (unified market list: built-in curated catalog + custom repos; scan, one-click import, per-source installed/updatable badges, one-click update-all) |
60
- | Live updates | — | filesystem-provider watcher, with a 5s panel poll as fallback |
26
+ | Catalog | user roots, self-scanned | `ctx.skills` registry: project / custom / user / bundled + third-party |
27
+ | Workspace | | ✅ `.dsh/skills` & `.agents/skills` (read-only, merged by default) |
28
+ | Toggle | ❌ | ✅ rename `SKILL.md` (never delete), tri-state group switches + drag reorder |
29
+ | Diagnostics / scaffold | ❌ | ✅ missing frontmatter checks / `~/.dsh/skills` wizard |
30
+ | Source tracking | ❌ | ✅ repo + commit, check/sync/trash (restores source & scene) |
31
+ | Market | ❌ | ✅ built-in + custom repos, any top-level root, badges + update-all |
32
+ | Stats | ❌ | ✅ call counts from session logs (14-day window, incremental cache) |
61
33
 
62
34
  ## Features
63
35
 
64
- ### Catalog & switches manage local skills
65
-
66
- > **Browse everything, change anything you own.** The full registry is visible and searchable;
67
- > writes are confined to your user-level roots and never delete files.
68
-
69
- - **Full catalog** — every skill the official registry knows: project `.dsh/skills` & `.agents/skills`,
70
- custom roots, user `~/.dsh/skills` & `~/.agents/skills`, bundled, and third-party providers.
71
- - **Search & grouping** — one row combines search, source filter, and flat/grouped view; groups are
72
- user **tags (scenes)** plus **source collections** (auto-aggregated by upstream repo); uncategorized
73
- stays visible.
74
- - **Workspace discovery** — known workspaces (from dsh’s workspace registry) are merged into the
75
- default view and grouped in a project-level tree (per project, optionally split into
76
- `.dsh`/`.agents`); the header path field pins the view to one workspace.
77
- - **Group switches** — every group header carries a sliding switch: enable/disable the whole group in
78
- one click. Closing a group whose member is also enabled elsewhere opens a conflict dialog (close all /
79
- keep on → the group falls into a half-filled mixed state). Read-only skills are skipped with
80
- per-name reports.
81
- - **Enable / disable** — disable renames `SKILL.md` out of discovery (tracked in a sidecar file), so
82
- the change survives restarts and is trivially reversible. Files are never deleted.
83
- - **Skill detail** — read a skill’s body straight from disk, with its source card (repo, commit,
84
- check/sync/follow-delete actions).
85
- - **New-skill wizard** — scaffold a valid skill into `~/.dsh/skills` or `~/.agents/skills` from the GUI.
86
-
87
- ### Market & updates
88
-
89
- > **Add a repo, install in one click, stay updated forever.** Imports are tracked upstream
90
- > automatically; updates surface per source and can be applied all at once.
91
-
92
- - **Unified market list** — one list on the Market tab: built-in catalog entries show a description
93
- and an **Add** button until added; once added (or custom sources entered by hand) the same row
94
- becomes a full source row. No duplicate entries.
95
- - **Scan → install** — scan any repo’s `skills/` and `design-templates/` roots, tick the skills you
96
- want, import with one click. Imports record the upstream repo/commit automatically.
97
- - **State badges** — every source row aggregates its state: installed count, updatable count, and
98
- deleted-upstream count.
99
- - **Check all / update all** — “Check all” refreshes every source (release + skill diffs); “Update
100
- all” syncs every source with pending updates in one pass (per-source failures are reported, never
101
- fatal). A daily auto-check (24h, timestamped in localStorage) covers the “forgot to click” case;
102
- manual buttons are never throttled.
103
- - **Source tracking** — per-source check (1–2 GitHub API requests, 5-minute server throttle), sync
104
- selected skills (overwrite confirm), and follow upstream deletion into a restorable trash.
105
- Deleting and restoring a tracked skill keeps its source and scene membership (snapshotted in the
106
- trash entry). Personal skills (no source) are never tracked.
107
- - **Self-update check** — the panel header checks the plugin’s own latest GitHub release.
108
-
109
- ### Stats & diagnostics
110
-
111
- > **Know what your agents actually use.** Invocation counts come from your own session logs —
112
- > no telemetry leaves the machine.
113
-
114
- - **Invocation statistics** — per-skill call counts and last-used times read from session logs
115
- (optional; absent session-query deployments simply omit the data); group headers summarize.
116
- - **Discovery diagnostics** — the catalog reports *why* a skill was ignored (missing YAML
117
- frontmatter, missing `name`/`description`, illegal name), per skill.
118
- - **Settings card** — enable the plugin, toggle the agent announcement, and adjust panel display
119
- preferences from **Settings → 插件 → Skill Hub**.
36
+ - **Catalog** search + source filter + flat/grouped in one row; groups = scenes (tags) + source collections; workspace tree merged by default.
37
+ - **Switches** — per-skill and per-group toggles; conflict dialog (close all / keep on) → mixed state; only `~/.dsh/skills` & `~/.agents/skills` are writable.
38
+ - **Reorder & edit** drag handle on every group header (persists in `~/.dsh/dsh-skill-hub.json`); Edit toggle reveals reorder/delete without cluttering the read view.
39
+ - **Market** unified list (built-in Add becomes source row); scan any root with `SKILL.md` (no allowlist), async import with `{jobId, totalBytes}` progress & cancel; Check all / Update all (failures non-fatal, daily auto-check).
40
+ - **Stats** — per-skill `count` + `lastUsed`, group summaries; configurable window/interval live from the settings card.
120
41
 
121
42
  ## Quick start
122
43
 
123
44
  ```bash
124
45
  dsh plugin --profile web add dsh-skill-hub
46
+ # restart dsh web → Settings → 技能 → Market → scan → import
125
47
  ```
126
48
 
127
- Restart `dsh web`, open **Settings → 技能**, and on the **Market** tab pick a repo from the
128
- built-in catalog (or paste an `owner/repo`), scan it, tick the skills you want, and import. They are
129
- tracked upstream from then on: check for updates and sync with one click.
130
-
131
- A skill is just a directory with a `SKILL.md` — the panel can also scaffold one for you:
49
+ Scaffold format (`SKILL.md`):
132
50
 
133
51
  ```markdown
134
52
  ---
135
53
  name: my-skill
136
- description: One line describing when the agent should use this skill.
54
+ description: One line when the agent should use this skill.
137
55
  ---
138
56
  # my-skill
139
-
140
- What the skill does, when to use it, and what output is expected.
57
+ Body...
141
58
  ```
142
59
 
143
- Requires Node `^22.19.0 || >=24.0.0` and a dsh web deployment (compatible with the `0.1.0-rc.7` and `0.1.1-rc.2` SDK families; peer ranges cover both and forward `0.1.x` lines).
60
+ Requires `Node ^22.19 || >=24` + dsh web (`0.1.0-rc.7` / `0.1.1-rc.2`, `0.1.x` forward compatible).
144
61
 
145
62
  ## How it works
146
63
 
147
64
  ```text
148
- GitHub repo ──scan / import──▶ ~/.dsh/skills (user level)
149
-
150
- check / sync / delete ▼
151
- ctx.skills registry ◀── skill-hub provider (registers user + project roots)
152
- │ │ snapshot / get
153
- └────── daily auto-check ▼
154
- /api/skill-hub/* routes ──▶ Browser panel (Settings → 技能)
65
+ GitHub repo ──scan/import──▶ ~/.dsh/skills
66
+
67
+ └─check/sync/delete── ctx.skills ◀─ provider
68
+ snapshot/get
69
+
70
+ /api/skill-hub/* ──▶ Panel (Settings → 技能)
155
71
  ```
156
72
 
157
- | File | Responsibility |
73
+ | File | Role |
158
74
  | --- | --- |
159
- | `src/index.ts` | host entry: inject `[webServer, skills, systemPrompt, settings]`; registers the `dsh-skill-hub` settings namespace; system-prompt announcement |
160
- | `src/routes.ts` | declarative route wrapper: `/api/skill-hub/*` (loopback / method / master-switch / JSON-body fences handled once; handlers stay business-only) |
161
- | `src/store.ts` | sidecar state `~/.dsh/dsh-skill-hub.json` v3 (disabled, tags, sources, market sources, trash; versioned v1→v2→v3 migrations) |
162
- | `src/repo.ts` | GitHub discovery/import + source tracking (latest commit, tree diff, manifest) |
163
- | `src/skillfs.ts` | root resolution / toggle rename / trash & restore / scaffold / diagnostics |
164
- | `src/stats.ts` | invocation stats: session logs per-skill call counts (optional sessionQuery) |
165
- | `src/protocol.ts` | host ↔ browser shared API contract (types + endpoint table) |
166
- | `src/client/` | browser half: settings card + skill hub panel. State and flows live in `useSkillHub.ts`; views are thin components (`SourcesView` / `ScenesView` / `MarketView` / `SkillRow` / dialogs / …). CSS Modules, Apple-style |
167
-
168
- - **Host half** uses only official SDKs: `ctx.skills.snapshot()/get()`, `ctx.webServer.register()`,
169
- `ctx.systemPrompt.section()`. No dsh source is modified.
170
- - **Browser half** mounts through official slots: a **Settings → 技能** section and a
171
- **Settings → 插件 → Skill Hub** configuration card.
172
- - **Configuration** is dsh-native. Since rc.7 the host serves every registered settings namespace to
173
- the web client (the old namespace allowlist is gone), so the plugin registers a `dsh-skill-hub`
174
- settings namespace and the card reads/writes it through the official settings transport — the
175
- configurable-plugins tab dispatches the card by that namespace, and the host consumes the same
176
- resolved value (single source of truth). Installations upgraded from the older sidecar-configured
177
- build migrate their saved config into the namespace once.
178
-
179
- ## Usage
180
-
181
- Open **Settings → 技能** (Skill Hub) in the dsh web GUI. Three tabs:
182
-
183
- - **来源 (Sources)** — the skill list, flat or grouped: a project-level tree (workspaces merged by
184
- default, per project optionally split into `.dsh`/`.agents`) plus source collections and
185
- uncategorized. Search, source filter and sort share one row; group headers carry tri-state
186
- switches; the source-group badge doubles as the re-check entry. *(see the screenshot at the top)*
187
- - **场景 (Scenes)** — your own enable/disable units (e.g. a “Godot” scene vs a “Java” scene): create
188
- tags, assign members, and flip a whole scene on/off with one switch.
75
+ | `src/index.ts` | inject `[webServer, skills, systemPrompt, settings]`, settings namespace, announcement |
76
+ | `src/routes.ts` | `/api/skill-hub/*` fences + handlers (async import, reorder) |
77
+ | `src/store.ts` | `~/.dsh/dsh-skill-hub.json` v4 (disabled/tags/sources/market/trash/stats/order) |
78
+ | `src/repo.ts` | discovery / import / diff (any top-level `SKILL.md`) |
79
+ | `src/skillfs.ts` | toggle/trash/scaffold/diagnostics |
80
+ | `src/client/` | panel (`useSkillHub` + thin views), CSS Modules |
189
81
 
190
- <p align="center">
191
- <img src="https://raw.githubusercontent.com/cheshireez/dsh-skill-hub/main/promo/real-skill-hub-scenes.png" alt="场景 tab" width="560">
192
- </p>
193
- - **市场 (Market)** — one unified list: built-in curated repos (Add button until added) and your
194
- custom sources; scan to install, check for updates, update all in one pass.
82
+ Host uses only `ctx.skills.snapshot/get`, `ctx.webServer.register`, `ctx.systemPrompt.section`.
195
83
 
196
- <p align="center">
197
- <img src="https://raw.githubusercontent.com/cheshireez/dsh-skill-hub/main/promo/real-skill-hub-catalog.png" alt="市场 tab" width="560">
198
- </p>
199
-
200
- Everywhere: **work space field** in the header (enter a project path to see its read-only project
201
- skills), **trash** section (restorable, restores source + scene membership), **diagnostics** section
202
- (why a skill is missing), and the **new-skill** form.
203
-
204
- The plugin’s own switches live on the **Settings → 插件 → Skill Hub** card:
205
-
206
- | Field | Meaning |
207
- | --- | --- |
208
- | Enable plugin | Master switch: routes, provider, and announcement all go live with this. |
209
- | Announce to agent | Adds a system-prompt section so agents know how to collaborate when users mention skill management. |
210
- | Model / user dot colors | Override the single status-dot colors shown in the skill panel and the chat `/` menu (blue = model-callable, green = user-only). |
211
- | Show invocation count | Show per-skill call-count chips when session stats are available. |
212
- | Show last-used time | Show relative last-used time on each skill row. |
213
- | Show group summaries | Show count/last-used summaries after group titles. |
84
+ ## Usage
214
85
 
215
- ## Troubleshooting
86
+ **Settings → 技能** — 3 tabs: **Sources** (flat/grouped + project tree + drag), **Scenes** (tags, drag), **Market** (unified list). Header workspace field pins to one cwd; trash & diagnostics are always visible.
216
87
 
217
- - **⚠️ `duplicate loader entry id: skill-hub`** the plugin was mounted twice (for example both
218
- through `dsh plugin add` and a local `file:` install). Keep exactly one installation method; on
219
- upgrade, replace rather than add.
220
- - **A skill is not in the catalog** — open the **发现诊断** (diagnostics) section: missing
221
- frontmatter, a name mismatch with the directory, or an over-short description are each listed with
222
- their reason.
223
- - **Update check shows nothing** — the server throttles checks (5 min per source) and the panel
224
- auto-checks once per day; manual buttons are never throttled.
225
- - **Read-only boundary** — only user-level skills (`~/.dsh/skills`, `~/.agents/skills`) are writable;
226
- project, bundled, and runtime skills are displayed read-only.
227
- - **Chat `/` menu status dots depend on a dsh-internal registry** — the dots render by wrapping the
228
- core `/skill` trigger source's candidates. If a dsh upgrade reshapes that internals, the dots
229
- silently disappear but the skill list and `/` menu keep working. A known, deliberate trade-off for
230
- portability — it never affects skill management itself.
88
+ **Settings 插件 Skill Hub**master switch, announce to agent, dot colors, `showUseCount/showUseTime/showGroupSummary`, stats window (days, default 14, `0`=all) & interval (min, default 5).
231
89
 
232
90
  ## HTTP API
233
91
 
234
- All endpoints are **loopback-only** (`127.0.0.1`/`localhost`) and JSON.
92
+ Loopback-only (`127.0.0.1`/`localhost`), JSON.
235
93
 
236
94
  | Endpoint | Method | Purpose |
237
95
  | --- | --- | --- |
238
- | `/api/skill-hub/catalog?cwd=` | GET | Full catalog: skills, disabled list, discovery diagnostics (`cwd` adds project skills). |
239
- | `/api/skill-hub/skill?name=&cwd=` | GET | One skill’s detail (path, provider, body). |
240
- | `/api/skill-hub/skill/delete` | POST | Move a skill into the restorable trash (snapshots source + scenes). |
241
- | `/api/skill-hub/toggle` | POST | Enable/disable a writable skill (`{name, enabled}`). |
242
- | `/api/skill-hub/toggle-batch` | POST | Enable/disable a whole group in one write (`{names, enabled}`). |
243
- | `/api/skill-hub/create` | POST | Scaffold a new skill (`{name, description?, root?}`). |
244
- | `/api/skill-hub/stats` | GET | Per-skill invocation counts (unavailable when session-query is absent). |
245
- | `/api/skill-hub/config` | GET/POST | Plugin runtime config (`{enabled, announceToAgent}`); `null` clears an override. |
246
- | `/api/skill-hub/groups` | GET | User tags + source collections + origin map. |
247
- | `/api/skill-hub/tag` | POST | Create/rename a tag group. |
248
- | `/api/skill-hub/tag/delete` | POST | Delete a tag group. |
249
- | `/api/skill-hub/tag/members` | POST | Set a tag’s member list. |
250
- | `/api/skill-hub/market` | GET | The user’s market source repos. |
251
- | `/api/skill-hub/market/source` | POST | Add a market source (`{repo}`). |
252
- | `/api/skill-hub/market/source/delete` | POST | Remove a market source. |
253
- | `/api/skill-hub/market/source/ref` | POST | Pin a market source to a release/branch ref. |
254
- | `/api/skill-hub/market/check` | GET | Check market sources for newer releases (throttled). |
255
- | `/api/skill-hub/market/source/sync` | POST | Align a market source to its pinned ref; returns tracked skills. |
256
- | `/api/skill-hub/repo?repo=` | GET | Discover importable skills in a GitHub repo. |
257
- | `/api/skill-hub/repo/import` | POST | Import selected repo skills (records the source + default scene). |
258
- | `/api/skill-hub/sources` | GET | Source records, derived origins/collections, trash. |
259
- | `/api/skill-hub/sources/check` | POST | Check upstream updates (throttled, 5 min). |
260
- | `/api/skill-hub/sources/sync` | POST | Sync selected (or all) skills of a source. |
261
- | `/api/skill-hub/sources/delete` | POST | Follow upstream deletion (moves to trash). |
262
- | `/api/skill-hub/sources/restore` | POST | Restore a trashed skill (re-attaches source + scenes). |
263
- | `/api/skill-hub/sources/trash/clear` | POST | Permanently clear the trash. |
264
- | `/api/skill-hub/update` | GET | Check the plugin’s own latest release. |
96
+ | `/api/skill-hub/catalog?cwd=` | GET | catalog + disabled + diagnostics |
97
+ | `/api/skill-hub/skill?name=&cwd=` | GET | skill body |
98
+ | `/api/skill-hub/skill/delete` | POST | move to trash (snapshots source+scenes) |
99
+ | `/api/skill-hub/toggle` | POST | `{name, enabled}` |
100
+ | `/api/skill-hub/toggle-batch` | POST | `{names, enabled}` |
101
+ | `/api/skill-hub/create` | POST | `{name, description?, root?}` |
102
+ | `/api/skill-hub/stats` | GET | invocation counts |
103
+ | `/api/skill-hub/config` | GET/POST | runtime config (`null` clears) |
104
+ | `/api/skill-hub/groups` | GET | tags + collections + orders |
105
+ | `/api/skill-hub/tag` etc. | POST | create/rename, delete, set members, reorder (`/tag/reorder`, `/collections/reorder`, `/source-groups/reorder`) |
106
+ | `/api/skill-hub/market` etc. | GET/POST | list/add/delete/pin/check/sync market sources |
107
+ | `/api/skill-hub/repo?repo=` | GET | discover (any root) |
108
+ | `/api/skill-hub/repo/import` | POST | async job `{jobId, total, totalBytes}` |
109
+ | `/api/skill-hub/repo/import/progress?jobId=` | GET | poll job |
110
+ | `/api/skill-hub/repo/import/cancel` | POST | cancel job |
111
+ | `/api/skill-hub/sources` etc. | GET/POST | list/check/sync/delete/restore/clear trash |
112
+ | `/api/skill-hub/update` | GET | plugin latest release |
265
113
 
266
114
  ## Development
267
115
 
268
116
  ```bash
269
- npm install
270
- npm run typecheck # tsc --noEmit
271
- npm test # vitest (152 tests across 8 suites)
272
- npm run build # tsc declarations + tsdown bundles (lib/index.js + lib/client.js)
273
- npm pack # build the installable tarball (dsh-skill-hub-<version>.tgz)
117
+ npm run typecheck # tsc --noEmit
118
+ npm test # 174 tests, 9 suites
119
+ npm run build # tsc + tsdown lib/index.js + lib/client.js
274
120
  ```
275
121
 
276
- > **Local testing:** do not run two `dsh web` instances against the same
277
- > `$DSH_HOME` and the same project directory at the same time. dsh rc releases have no
278
- > cross-process session-log lock, and a second instance resuming the same
279
- > session can write duplicate `seq` rows (`corrupt session log: seq gap in
280
- > committed region`). Stop the old instance first, or give the preview its own
281
- > `DSH_HOME`.
122
+ > Don't run two `dsh web` on the same `$DSH_HOME` + cwd — rc has no session-log lock (`seq gap` corruption). Use separate `DSH_HOME`.
123
+
124
+ ## Troubleshooting
282
125
 
283
- The test suites cover the route family (including the config route and the disabled gate), the sidecar
284
- store, skill filesystem operations, the registry provider, and invocation statistics.
126
+ - `duplicate loader entry id: skill-hub` remove duplicate install (keep one `dsh plugin add` method).
127
+ - Skill missing check diagnostics (frontmatter / name mismatch / short description).
128
+ - Dots missing in `/` menu — dsh internals changed; catalog still works.
285
129
 
286
130
  ## Community
287
131
 
288
- - [Issues](https://github.com/cheshireez/dsh-skill-hub/issues) bug reports and feature requests.
289
- - [Discussions](https://github.com/cheshireez/dsh-skill-hub/discussions) — Q&A, feedback, and ideas.
290
- - [Showcase @ deepseek-harness](https://github.com/deepseek-ai/deepseek-harness/discussions/3161) — announcement posted in the official repository.
291
- - [Plugin market listing](https://github.com/awesome-dsh-plugin/awesome-dsh-plugin/pull/1746) — PR to the community market; once merged, install from **Settings → Plugin Market**.
292
- - [DeepSeek Harness Discord](https://discord.gg/Ycq5dCaS4) — official community (primarily Chinese).
293
- - [Contributing](CONTRIBUTING.md) — development setup and contribution guidelines.
132
+ [Issues](https://github.com/cheshireez/dsh-skill-hub/issues) · [Discussions](https://github.com/cheshireez/dsh-skill-hub/discussions) · [Showcase](https://github.com/deepseek-ai/deepseek-harness/discussions/3161) · [Market PR](https://github.com/awesome-dsh-plugin/awesome-dsh-plugin/pull/1746) · [Discord](https://discord.gg/Ycq5dCaS4)
294
133
 
295
134
  ## License
296
135
 
297
- MIT — see [LICENSE](LICENSE).
136
+ MIT — [LICENSE](LICENSE).