dsh-skills-studio 0.1.2 → 0.2.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.
- package/CONTRACT.md +12 -10
- package/README.md +59 -24
- package/client.js +6 -6
- package/cordis.patch.yml +1 -1
- package/icon.svg +1 -1
- package/index.js +8 -8
- package/package.json +14 -4
- package/src/api.js +4 -4
- package/src/config.js +1 -1
- package/src/frontmatter.js +1 -1
- package/src/mutate.js +1 -1
- package/src/roots.js +1 -1
- package/src/scan.js +1 -1
- package/src/validate.js +1 -1
package/CONTRACT.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# dsh-skills-
|
|
1
|
+
# dsh-skills-studio — build contract (v1)
|
|
2
2
|
|
|
3
3
|
A DSH bundle that adds a **Skills** page to Settings: install/edit skills on disk, see
|
|
4
4
|
what agents can actually load, and block conflicting saves before they happen.
|
|
@@ -28,7 +28,7 @@ No server-side model calls, no shell execution, no network.
|
|
|
28
28
|
## Package layout and ownership
|
|
29
29
|
|
|
30
30
|
```
|
|
31
|
-
dsh-skills-
|
|
31
|
+
dsh-skills-studio/
|
|
32
32
|
package.json Lead
|
|
33
33
|
cordis.patch.yml Lead
|
|
34
34
|
icon.svg Lead
|
|
@@ -58,7 +58,7 @@ api-dev's. The Lead owns the manifest files and integration.
|
|
|
58
58
|
- Client services: `ctx.get('slots')` (required-ish), `ctx.get('locale')` (optional),
|
|
59
59
|
`ctx.get('sessions')` (optional). Reading a service not listed in `inject` throws, so use
|
|
60
60
|
`ctx.get()` for everything optional and never `ctx.locale` directly.
|
|
61
|
-
- Host web routes: `ctx.webServer.register({ kind: 'prefix', path: '/skills-
|
|
61
|
+
- Host web routes: `ctx.webServer.register({ kind: 'prefix', path: '/skills-studio', handler(req, res) })`
|
|
62
62
|
inside `ctx.effect(() => …)`.
|
|
63
63
|
- Host plugin entry: named `export const name`, `export const inject = ['webServer']`,
|
|
64
64
|
`export function apply(ctx, config = {})`. Read optional services with `ctx.get('skills')`.
|
|
@@ -115,12 +115,14 @@ when missing). Project roots need a `cwd`; without one, skip them.
|
|
|
115
115
|
|
|
116
116
|
## HTTP API
|
|
117
117
|
|
|
118
|
-
Prefix `/skills-
|
|
118
|
+
Prefix `/skills-studio`, JSON only, `cache-control: no-store`, body cap 1 MiB.
|
|
119
|
+
Breaking in 0.2.0: the prefix moved from `/skills-manager`; see the upgrade section in
|
|
120
|
+
[README.md](README.md#upgrading-from-01x-and-dsh-skills-manager).
|
|
119
121
|
Success envelope `{ ok: true, ... }`. Failure:
|
|
120
122
|
`{ ok: false, error: { code, message, details? } }` with status 400/404/405/413/422/409/500.
|
|
121
123
|
Validation responses additionally carry `{ errors, conflicts, warnings }` (see below).
|
|
122
124
|
|
|
123
|
-
### GET `/skills-
|
|
125
|
+
### GET `/skills-studio/api/state?cwd=<abs path>`
|
|
124
126
|
|
|
125
127
|
```json
|
|
126
128
|
{
|
|
@@ -201,12 +203,12 @@ Rules:
|
|
|
201
203
|
alphanumeric words length > 2 minus stop words. Jaccard ≥ 0.5 against another skill →
|
|
202
204
|
warning carrying `sharedWords`. Deduplicate per pair; cap at 5 warnings.
|
|
203
205
|
|
|
204
|
-
### GET `/skills-
|
|
206
|
+
### GET `/skills-studio/api/skill?rootId=<id>&relPath=<path>`
|
|
205
207
|
|
|
206
208
|
→ `{ ok: true, root: Root, skill: { …entry, content: "full file text" } }`.
|
|
207
209
|
404 `not-found` when `rootId`/`relPath` does not name a scanned entry.
|
|
208
210
|
|
|
209
|
-
### POST `/skills-
|
|
211
|
+
### POST `/skills-studio/api/validate` and `POST /skills-studio/api/save`
|
|
210
212
|
|
|
211
213
|
Body (action `create`):
|
|
212
214
|
|
|
@@ -269,7 +271,7 @@ user-invocable: false # only when userInvocable === false
|
|
|
269
271
|
<body trimmed of trailing whitespace>
|
|
270
272
|
```
|
|
271
273
|
|
|
272
|
-
### POST `/skills-
|
|
274
|
+
### POST `/skills-studio/api/delete`
|
|
273
275
|
|
|
274
276
|
`{ "rootId": "user-agents", "relPath": "my-skill/SKILL.md", "expectedSha256": "…" }`
|
|
275
277
|
→ `{ ok:true, removed: { rootId, relPath, name }, registry: { checked, visible:false, catalogCount, waitedMs } }`.
|
|
@@ -279,7 +281,7 @@ is a symlink, or when the bundle directory contains something other than `SKILL.
|
|
|
279
281
|
regular resource files under the bundle (still allowed: `references/`, `scripts/`, `assets/`,
|
|
280
282
|
any regular files/dirs inside that bundle — just never outside it).
|
|
281
283
|
|
|
282
|
-
### POST `/skills-
|
|
284
|
+
### POST `/skills-studio/api/install`
|
|
283
285
|
|
|
284
286
|
`{ "libraryId": "deepseek-stack", "relPath": "ds-plan-loop/SKILL.md", "overwrite": false,
|
|
285
287
|
"expectedSha256": "…", "force": false }`
|
|
@@ -312,7 +314,7 @@ any regular files/dirs inside that bundle — just never outside it).
|
|
|
312
314
|
("Skills"), locale namespace `settings.skills` when `ctx.get('locale')` exists.
|
|
313
315
|
- `inject = ['slots']`; everything else via `ctx.get()`. Never throw from `apply` or from a
|
|
314
316
|
render when an optional service is missing.
|
|
315
|
-
- Fetch `GET /skills-
|
|
317
|
+
- Fetch `GET /skills-studio/api/state` on mount, after every mutation, and on manual
|
|
316
318
|
refresh. Same-origin `fetch(url, { credentials: 'same-origin' })`.
|
|
317
319
|
- Layout (translated from the active moodboard language into the DSH settings shell):
|
|
318
320
|
a compact hero row (title from the shell already; use a one-line subtitle), a stat strip
|
package/README.md
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
# dsh-skills-
|
|
1
|
+
# dsh-skills-studio
|
|
2
2
|
|
|
3
|
-
[](https://github.com/Stijnus/dsh-skills-studio/actions/workflows/test.yml) [](https://www.npmjs.com/package/dsh-skills-studio)
|
|
4
4
|
|
|
5
|
-
A **Skills** page for DeepSeek Harness Settings: see every installed agent skill, see what
|
|
5
|
+
A **Skills** page for DeepSeek Harness Settings (formerly known as `dsh-skills-manager`; GitHub redirects): see every installed agent skill, see what
|
|
6
6
|
the registry actually serves to agents, add or edit skills on disk, and block conflicting
|
|
7
7
|
saves before they happen.
|
|
8
8
|
|
|
@@ -66,19 +66,19 @@ directory; the raw evidence and harnesses are described in
|
|
|
66
66
|
dsh plugin --profile <profile> add dsh-skills-studio
|
|
67
67
|
|
|
68
68
|
# pin a version
|
|
69
|
-
dsh plugin --profile <profile> add dsh-skills-studio@0.
|
|
69
|
+
dsh plugin --profile <profile> add dsh-skills-studio@0.2.0
|
|
70
70
|
```
|
|
71
71
|
|
|
72
|
-
The project
|
|
73
|
-
the unscoped `dsh-skills-manager`
|
|
74
|
-
|
|
75
|
-
available below.
|
|
72
|
+
The project and its npm package are both **`dsh-skills-studio`**. The old `@stijnus/...`
|
|
73
|
+
scope was retired, and the unrelated unscoped `dsh-skills-manager` package on npm belongs to
|
|
74
|
+
a third-party plugin — this project never publishes under that name. GitHub and local-link
|
|
75
|
+
installs remain available below.
|
|
76
76
|
|
|
77
77
|
### Local development (web profile, isolated)
|
|
78
78
|
|
|
79
79
|
```bash
|
|
80
|
-
git clone https://github.com/Stijnus/dsh-skills-
|
|
81
|
-
cd dsh-skills-
|
|
80
|
+
git clone https://github.com/Stijnus/dsh-skills-studio.git
|
|
81
|
+
cd dsh-skills-studio
|
|
82
82
|
DSH_HOME=/tmp/dsh-skills-dev dsh plugin --profile web add link:$PWD
|
|
83
83
|
DSH_HOME=/tmp/dsh-skills-dev dsh --profile web --port 53999 --no-open
|
|
84
84
|
```
|
|
@@ -87,23 +87,23 @@ Or install straight from this repository into an existing profile:
|
|
|
87
87
|
|
|
88
88
|
```bash
|
|
89
89
|
# latest main
|
|
90
|
-
dsh plugin --profile <profile> add github:Stijnus/dsh-skills-
|
|
90
|
+
dsh plugin --profile <profile> add github:Stijnus/dsh-skills-studio
|
|
91
91
|
|
|
92
92
|
# pin a released version (recommended for stable installs) — see the Releases page
|
|
93
|
-
dsh plugin --profile <profile> add github:Stijnus/dsh-skills-
|
|
93
|
+
dsh plugin --profile <profile> add github:Stijnus/dsh-skills-studio#v0.2.0
|
|
94
94
|
```
|
|
95
95
|
|
|
96
|
-
Releases are tagged `vX.Y.Z` ([Releases](https://github.com/Stijnus/dsh-skills-
|
|
96
|
+
Releases are tagged `vX.Y.Z` ([Releases](https://github.com/Stijnus/dsh-skills-studio/releases)). Replacing a package with a new version needs a restart, not just a profile reload; see [Upgrading from 0.1.x](#upgrading-from-01x-and-dsh-skills-manager).
|
|
97
97
|
|
|
98
|
-
> **
|
|
99
|
-
>
|
|
100
|
-
>
|
|
98
|
+
> **name note:** earlier releases used the project name `dsh-skills-manager` (the scoped
|
|
99
|
+
> `@stijnus/...` npm name was never published). The package is plain `dsh-skills-studio`;
|
|
100
|
+
> the unrelated `dsh-skills-manager` name on npm belongs to a third-party plugin.
|
|
101
101
|
|
|
102
102
|
Overlay config for an isolated run (agents home, writable root and libraries):
|
|
103
103
|
|
|
104
104
|
```yaml
|
|
105
|
-
# skills-
|
|
106
|
-
- id: skills-
|
|
105
|
+
# skills-studio.overlay.yml — pass with --patch
|
|
106
|
+
- id: skills-studio
|
|
107
107
|
config:
|
|
108
108
|
agentsHome: /tmp/dsh-skills-dev/agents
|
|
109
109
|
writableRoot: /tmp/dsh-skills-dev/managed-skills
|
|
@@ -124,7 +124,7 @@ shell performs the package operation and recomposes the app). After installation
|
|
|
124
124
|
reports `restart-required`.
|
|
125
125
|
|
|
126
126
|
The current live install on this machine uses the hand-managed profile path instead: a
|
|
127
|
-
`node_modules/dsh-skills-
|
|
127
|
+
`node_modules/dsh-skills-studio` symlink plus a profile-patch row (see
|
|
128
128
|
[SKILLS-VERIFICATION.md](SKILLS-VERIFICATION.md) §4). DSH's profile HMR loads both halves
|
|
129
129
|
into the running app without a restart. Durability caveat: because the profile
|
|
130
130
|
`package.json` does not declare the package, a later plugin-manager / pnpm operation can
|
|
@@ -132,6 +132,36 @@ prune the symlink; re-run the desktop plugin install (or add the `link:` depende
|
|
|
132
132
|
such an operation. The profile patch keeps the row, so a restart with the symlink restored
|
|
133
133
|
brings the section back.
|
|
134
134
|
|
|
135
|
+
## Upgrading from 0.1.x (and `dsh-skills-manager`)
|
|
136
|
+
|
|
137
|
+
0.2.0 finishes the rename and is intentionally breaking. The bundle row id, the Cordis plugin
|
|
138
|
+
name, the HTTP prefix and the health name all changed:
|
|
139
|
+
|
|
140
|
+
| | 0.1.x | 0.2.0 |
|
|
141
|
+
|---|---|---|
|
|
142
|
+
| bundle row id | `skills-manager` | `skills-studio` |
|
|
143
|
+
| HTTP prefix | `/skills-manager/api` | `/skills-studio/api` |
|
|
144
|
+
| health name | `dsh-skills-manager` | `dsh-skills-studio` |
|
|
145
|
+
| client module id | `skills-manager-client` | `skills-studio-client` |
|
|
146
|
+
|
|
147
|
+
Profile patches are keyed by row id. An override written for the old row (for example
|
|
148
|
+
`- id: skills-manager` with `libraries` or `writableRoot`) is reported as
|
|
149
|
+
`patch: entry "skills-manager" not found` and dropped, so the plugin falls back to defaults.
|
|
150
|
+
|
|
151
|
+
1. Remove the old install (skip if you never installed it):
|
|
152
|
+
`dsh plugin --profile <profile> remove @stijnus/dsh-skills-manager`, or whichever spec you
|
|
153
|
+
used (`dsh-skills-manager`, `link:…`). For a hand-managed profile, delete the old
|
|
154
|
+
`node_modules/dsh-skills-manager` link and its `- insert:` row.
|
|
155
|
+
2. Rename the row in every profile/overlay patch that configures this plugin: `id: skills-manager`
|
|
156
|
+
→ `id: skills-studio`, `name: 'dsh-skills-manager'` → `name: 'dsh-skills-studio'`, keeping
|
|
157
|
+
the `config` block (`libraries`, `writableRoot`, `agentsHome`, `customSkillDirs`).
|
|
158
|
+
3. Install 0.2.0 and restart the app; a replaced JavaScript package is loaded fresh on restart.
|
|
159
|
+
4. Confirm the composed config: `dsh --profile <profile> --dump-config` should show exactly one
|
|
160
|
+
`skills-studio` row with your libraries and writable root.
|
|
161
|
+
5. Update direct API consumers to `/skills-studio/api/...` and expect
|
|
162
|
+
`name: "dsh-skills-studio"` from `/health`. Reload any Settings tab left open across the
|
|
163
|
+
upgrade — its old client still calls the old prefix.
|
|
164
|
+
|
|
135
165
|
## Configuration
|
|
136
166
|
|
|
137
167
|
All fields optional. Config is validated at apply time; a malformed value throws instead of
|
|
@@ -155,7 +185,9 @@ separate library entry.
|
|
|
155
185
|
|
|
156
186
|
## HTTP API (host half, same origin)
|
|
157
187
|
|
|
158
|
-
Prefix `/skills-
|
|
188
|
+
Prefix `/skills-studio/api`, JSON, `cache-control: no-store`. Breaking in 0.2.0: the prefix
|
|
189
|
+
moved from `/skills-manager/api` (see
|
|
190
|
+
[Upgrading from 0.1.x](#upgrading-from-01x-and-dsh-skills-manager)).
|
|
159
191
|
|
|
160
192
|
| Method + path | Purpose |
|
|
161
193
|
|---|---|
|
|
@@ -173,10 +205,13 @@ The full request/response contract, conflict rules and write format are in
|
|
|
173
205
|
## Verification
|
|
174
206
|
|
|
175
207
|
- Host logic: `node --test` → 105 tests, no dependencies, temp dirs only.
|
|
176
|
-
- Independent end-to-end verification: 61/61 host API assertions
|
|
177
|
-
instance, 28/28 real-browser GUI assertions
|
|
178
|
-
before save, a11y, light+dark), desktop delivery
|
|
179
|
-
49-entry installed-skills invariant re-audited:
|
|
208
|
+
- Independent end-to-end verification (0.1.1 build, pre-rename): 61/61 host API assertions
|
|
209
|
+
against a real scratch DSH instance, 28/28 real-browser GUI assertions
|
|
210
|
+
(add/edit/delete/install, duplicate blocked before save, a11y, light+dark), desktop delivery
|
|
211
|
+
proven live (HMR, no restart), and the 49-entry installed-skills invariant re-audited:
|
|
212
|
+
[`SKILLS-VERIFICATION.md`](SKILLS-VERIFICATION.md). The 0.2.0 rename changes identifiers
|
|
213
|
+
only; it was re-checked with unit and syntax tests (105/105), not re-run through the E2E
|
|
214
|
+
harnesses.
|
|
180
215
|
- Baseline audit of the installed skill roots and the deepseek-stack pack:
|
|
181
216
|
[`SKILLS-AUDIT.md`](SKILLS-AUDIT.md).
|
|
182
217
|
|
package/client.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// dsh-skills-
|
|
1
|
+
// dsh-skills-studio browser client half — hand-written in the DeepSeek Harness
|
|
2
2
|
// ModuleLoader format (no bundler needed). Declared via package.json `dsh.client`
|
|
3
3
|
// and exported as `./client`; the harness serves this file and registers it.
|
|
4
4
|
//
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
// - One <style> element injected via ctx.effect (classes prefixed dsm-, all
|
|
20
20
|
// selectors scoped under .dsm-root). Host theme tokens only; light and dark
|
|
21
21
|
// are both served by the tokens.
|
|
22
|
-
// - The API is same-origin fetch against `/skills-
|
|
22
|
+
// - The API is same-origin fetch against `/skills-studio` with
|
|
23
23
|
// credentials: 'same-origin'. Non-2xx JSON envelopes are parsed regardless of
|
|
24
24
|
// response.ok so validation errors/conflicts reach the form.
|
|
25
25
|
// - All visible copy (including aria labels) comes from the en/zh dictionaries.
|
|
@@ -32,12 +32,12 @@ window.__ModuleLoader__.load({
|
|
|
32
32
|
var React = require('react')
|
|
33
33
|
var h = React.createElement
|
|
34
34
|
|
|
35
|
-
var name = 'skills-
|
|
35
|
+
var name = 'skills-studio-client'
|
|
36
36
|
var inject = ['slots']
|
|
37
37
|
// The settings locale namespace. Declared on the slot registration only when
|
|
38
38
|
// the host installed a locale face; the dictionaries are registered there too.
|
|
39
39
|
var NS = 'settings.skills'
|
|
40
|
-
var API_BASE = '/skills-
|
|
40
|
+
var API_BASE = '/skills-studio'
|
|
41
41
|
var STYLE_ID = 'dsm-styles'
|
|
42
42
|
var VALIDATE_DEBOUNCE_MS = 350
|
|
43
43
|
var NAME_MAX = 64
|
|
@@ -192,7 +192,7 @@ window.__ModuleLoader__.load({
|
|
|
192
192
|
|
|
193
193
|
'delete.confirm': 'Delete "{name}"? This removes the file(s).',
|
|
194
194
|
|
|
195
|
-
'aria.section': 'Skills
|
|
195
|
+
'aria.section': 'Skills',
|
|
196
196
|
'aria.summary': 'Skills summary',
|
|
197
197
|
'aria.views': 'Skill views',
|
|
198
198
|
'aria.add': 'Add a new skill',
|
|
@@ -352,7 +352,7 @@ window.__ModuleLoader__.load({
|
|
|
352
352
|
|
|
353
353
|
'delete.confirm': '删除“{name}”?这会移除相关文件。',
|
|
354
354
|
|
|
355
|
-
'aria.section': '
|
|
355
|
+
'aria.section': '技能',
|
|
356
356
|
'aria.summary': '技能概览',
|
|
357
357
|
'aria.views': '技能视图',
|
|
358
358
|
'aria.add': '添加新技能',
|
package/cordis.patch.yml
CHANGED
package/icon.svg
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64" width="64" height="64" role="img" aria-label="Skills
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 64 64" width="64" height="64" role="img" aria-label="Skills">
|
|
2
2
|
<defs>
|
|
3
3
|
<linearGradient id="dsm-bg" x1="8" y1="6" x2="56" y2="60" gradientUnits="userSpaceOnUse">
|
|
4
4
|
<stop offset="0" stop-color="#4c6ef5"/>
|
package/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* dsh-skills-
|
|
2
|
+
* dsh-skills-studio — host plugin entry.
|
|
3
3
|
*
|
|
4
|
-
* Registers one `webServer` prefix route (`/skills-
|
|
4
|
+
* Registers one `webServer` prefix route (`/skills-studio`) that backs the
|
|
5
5
|
* Skills settings page: scan the local skill roots, validate drafts, write
|
|
6
6
|
* `SKILL.md` files atomically under the configured writable root, and report
|
|
7
7
|
* whether the live registry now serves the skill.
|
|
@@ -10,20 +10,20 @@
|
|
|
10
10
|
* request time, so the plugin also works in profiles without a skill registry
|
|
11
11
|
* (the page then shows the catalog as unavailable instead of failing).
|
|
12
12
|
*
|
|
13
|
-
* @module dsh-skills-
|
|
13
|
+
* @module dsh-skills-studio
|
|
14
14
|
*/
|
|
15
15
|
|
|
16
16
|
import { createApi, API_PREFIX } from './src/api.js'
|
|
17
17
|
import { normalizeConfig } from './src/config.js'
|
|
18
18
|
|
|
19
19
|
/** Cordis plugin name. */
|
|
20
|
-
export const name = 'skills-
|
|
20
|
+
export const name = 'skills-studio'
|
|
21
21
|
|
|
22
22
|
/** The web server is the one required service; anything else is read optionally. */
|
|
23
23
|
export const inject = ['webServer']
|
|
24
24
|
|
|
25
25
|
/**
|
|
26
|
-
* Register the `/skills-
|
|
26
|
+
* Register the `/skills-studio` route. Config is validated here, at load time,
|
|
27
27
|
* so a malformed plugin row fails loudly instead of at the first request.
|
|
28
28
|
*
|
|
29
29
|
* @param {object} ctx host context exposing `webServer` (required) plus
|
|
@@ -37,7 +37,7 @@ export function apply(ctx, config = {}) {
|
|
|
37
37
|
|
|
38
38
|
if (ctx === undefined || ctx === null || ctx.webServer === undefined || typeof ctx.webServer.register !== 'function') {
|
|
39
39
|
throw new TypeError(
|
|
40
|
-
'skills-
|
|
40
|
+
'skills-studio: ctx.webServer is unavailable; mount @deepseek-ai/dsh-host-webserver in this profile.',
|
|
41
41
|
)
|
|
42
42
|
}
|
|
43
43
|
|
|
@@ -49,14 +49,14 @@ export function apply(ctx, config = {}) {
|
|
|
49
49
|
if (typeof ctx.effect === 'function') {
|
|
50
50
|
// Route ownership lives with this plugin's fiber: disposing the plugin
|
|
51
51
|
// removes the route through the returned disposer.
|
|
52
|
-
ctx.effect(register, 'skills-
|
|
52
|
+
ctx.effect(register, 'skills-studio: /skills-studio routes')
|
|
53
53
|
} else {
|
|
54
54
|
register()
|
|
55
55
|
}
|
|
56
56
|
|
|
57
57
|
try {
|
|
58
58
|
ctx.logger?.info?.(
|
|
59
|
-
`skills-
|
|
59
|
+
`skills-studio: /skills-studio routes registered; writable root ${normalized.writableRoot}`,
|
|
60
60
|
)
|
|
61
61
|
} catch {
|
|
62
62
|
// A throwing logger must not take the plugin down.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-skills-studio",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Skills settings for DeepSeek Harness: install, add, edit, and validate agent skills on disk, see what the registry actually serves to agents, and block conflicting saves.",
|
|
6
6
|
"main": "index.js",
|
|
@@ -33,6 +33,16 @@
|
|
|
33
33
|
"inject": [
|
|
34
34
|
"@deepseek-ai/dsh-client-ui-settings"
|
|
35
35
|
]
|
|
36
|
+
},
|
|
37
|
+
"compatibility": {
|
|
38
|
+
"dsh": "^0.2.1-rc.5"
|
|
39
|
+
},
|
|
40
|
+
"catalog": {
|
|
41
|
+
"summary": {
|
|
42
|
+
"en": "A Skills page in Settings: every installed skill per discovery root, what the registry serves to agents, install and update from skill libraries, add and edit skills on disk, and blocked conflicting saves.",
|
|
43
|
+
"zh": "\u5728\u8bbe\u7f6e\u91cc\u52a0\u4e00\u4e2a\u201cSkills\u201d\u9875\uff1a\u6309\u53d1\u73b0\u6839\u76ee\u5f55\u5217\u51fa\u5df2\u5b89\u88c5\u6280\u80fd\u3001\u5c55\u793a\u6ce8\u518c\u8868\u5b9e\u9645\u63d0\u4f9b\u7684\u5185\u5bb9\u3001\u4ece\u6280\u80fd\u5e93\u5b89\u88c5\u4e0e\u66f4\u65b0\u3001\u76f4\u63a5\u7f16\u8f91\u78c1\u76d8\u4e0a\u7684\u6280\u80fd\uff0c\u5e76\u5728\u4fdd\u5b58\u51b2\u7a81\u65f6\u62e6\u622a\u3002"
|
|
44
|
+
},
|
|
45
|
+
"category": "interface"
|
|
36
46
|
}
|
|
37
47
|
},
|
|
38
48
|
"keywords": [
|
|
@@ -53,11 +63,11 @@
|
|
|
53
63
|
"author": "Stijnus",
|
|
54
64
|
"repository": {
|
|
55
65
|
"type": "git",
|
|
56
|
-
"url": "git+https://github.com/Stijnus/dsh-skills-
|
|
66
|
+
"url": "git+https://github.com/Stijnus/dsh-skills-studio.git"
|
|
57
67
|
},
|
|
58
|
-
"homepage": "https://github.com/Stijnus/dsh-skills-
|
|
68
|
+
"homepage": "https://github.com/Stijnus/dsh-skills-studio#readme",
|
|
59
69
|
"bugs": {
|
|
60
|
-
"url": "https://github.com/Stijnus/dsh-skills-
|
|
70
|
+
"url": "https://github.com/Stijnus/dsh-skills-studio/issues"
|
|
61
71
|
},
|
|
62
72
|
"scripts": {
|
|
63
73
|
"test": "node --test",
|
package/src/api.js
CHANGED
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
* HTTP API for the Skills manager: JSON envelope, route dispatch, body cap,
|
|
3
3
|
* optimistic-sha mutations, and the post-write registry visibility probe.
|
|
4
4
|
*
|
|
5
|
-
* Routes are mounted under the `/skills-
|
|
5
|
+
* Routes are mounted under the `/skills-studio` prefix registered by
|
|
6
6
|
* `index.js`; the paths below are absolute so the handler can also be driven
|
|
7
7
|
* directly in tests. The handler never throws: every failure becomes an
|
|
8
8
|
* `{ ok:false, error:{ code, message } }` envelope.
|
|
9
9
|
*
|
|
10
|
-
* @module dsh-skills-
|
|
10
|
+
* @module dsh-skills-studio/api
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
13
|
import { readFile } from 'node:fs/promises'
|
|
@@ -39,7 +39,7 @@ import {
|
|
|
39
39
|
} from './validate.js'
|
|
40
40
|
|
|
41
41
|
/** URL prefix owned by this plugin (registered through `ctx.webServer`). */
|
|
42
|
-
export const API_PREFIX = '/skills-
|
|
42
|
+
export const API_PREFIX = '/skills-studio'
|
|
43
43
|
|
|
44
44
|
/** Request body cap; also the largest JSON body the handler will buffer. */
|
|
45
45
|
export const BODY_LIMIT_BYTES = 1024 * 1024
|
|
@@ -717,7 +717,7 @@ export function createApi(options) {
|
|
|
717
717
|
status: 200,
|
|
718
718
|
payload: {
|
|
719
719
|
ok: true,
|
|
720
|
-
name: 'dsh-skills-
|
|
720
|
+
name: 'dsh-skills-studio',
|
|
721
721
|
version: STATE_VERSION,
|
|
722
722
|
generatedAt: new Date().toISOString(),
|
|
723
723
|
writableRoot: config.writableRoot,
|
package/src/config.js
CHANGED
package/src/frontmatter.js
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
* strings for text fields, invocation booleans only when disabled, and no
|
|
13
13
|
* empty `whenToUse` key.
|
|
14
14
|
*
|
|
15
|
-
* @module dsh-skills-
|
|
15
|
+
* @module dsh-skills-studio/frontmatter
|
|
16
16
|
*/
|
|
17
17
|
|
|
18
18
|
/** Raised for malformed or unsupported frontmatter. Message names the line. */
|
package/src/mutate.js
CHANGED
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
* crash leaves either the old or the new file. All functions throw a
|
|
9
9
|
* `MutationError` with a stable `code` that the HTTP layer maps to a status.
|
|
10
10
|
*
|
|
11
|
-
* @module dsh-skills-
|
|
11
|
+
* @module dsh-skills-studio/mutate
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
14
|
import { randomBytes } from 'node:crypto'
|
package/src/roots.js
CHANGED
package/src/scan.js
CHANGED
package/src/validate.js
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
* the conflicts a save would create. `detectConflicts` is the same name/alias/
|
|
8
8
|
* overlap analysis applied to the already-scanned installed set.
|
|
9
9
|
*
|
|
10
|
-
* @module dsh-skills-
|
|
10
|
+
* @module dsh-skills-studio/validate
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
13
|
import { lstat } from 'node:fs/promises'
|