dsh-plugin-guide 0.4.1 → 0.4.3
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/LICENSE +0 -0
- package/NOTICE.md +0 -0
- package/PRIVACY.md +0 -0
- package/README-zh.md +0 -0
- package/README.md +0 -0
- package/SKILL.md +0 -0
- package/STANDARDS.md +0 -0
- package/cordis.patch.yml +0 -0
- package/docs/boost.md +12 -4
- package/docs/entry.md +27 -1
- package/docs/flow.md +0 -0
- package/docs/levels.md +2 -0
- package/icon.svg +0 -0
- package/index.js +0 -0
- package/locale/en.json +0 -0
- package/locale/zh.json +0 -0
- package/package.json +1 -1
package/LICENSE
CHANGED
|
File without changes
|
package/NOTICE.md
CHANGED
|
File without changes
|
package/PRIVACY.md
CHANGED
|
File without changes
|
package/README-zh.md
CHANGED
|
File without changes
|
package/README.md
CHANGED
|
File without changes
|
package/SKILL.md
CHANGED
|
File without changes
|
package/STANDARDS.md
CHANGED
|
File without changes
|
package/cordis.patch.yml
CHANGED
|
File without changes
|
package/docs/boost.md
CHANGED
|
@@ -25,10 +25,18 @@ An evidence card is per practice, per plugin, with a baseline and an after
|
|
|
25
25
|
measurement. Example shape:
|
|
26
26
|
|
|
27
27
|
```yaml
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
28
|
+
practice: LEV-6
|
|
29
|
+
plugin: "@acme/dsh-hello@0.1.0"
|
|
30
|
+
baseline:
|
|
31
|
+
startupMs: 180
|
|
32
|
+
tokensPerTurn: 1200
|
|
33
|
+
after:
|
|
34
|
+
startupMs: 150
|
|
35
|
+
tokensPerTurn: 900
|
|
36
|
+
environment:
|
|
37
|
+
dsh: 0.2.2-alpha.3
|
|
38
|
+
cordis: 4.0.6-alpha.2
|
|
39
|
+
node: 24.9
|
|
32
40
|
command: "node bench/hello.mjs"
|
|
33
41
|
result: "startup 180→150 ms; tokens 1200→900"
|
|
34
42
|
negativeControl: "same bench with the plugin disabled"
|
package/docs/entry.md
CHANGED
|
@@ -7,6 +7,7 @@ market, index, or user hits.
|
|
|
7
7
|
|
|
8
8
|
- package manifest: name, version, license, entry, `dsh.bundle.patch`
|
|
9
9
|
- engines/peer range for the DSH and Cordis generation being claimed
|
|
10
|
+
- Node `>=24.9.0` for the 0.2.2 line; `engines.dsh`, when declared, decides alone since 0.2.1-alpha.4 (prereleases participate)
|
|
10
11
|
- the declared entry point actually resolves
|
|
11
12
|
- the bundle patch parses and its target row resolves
|
|
12
13
|
- display metadata, labels, and forbidden-claim checks
|
|
@@ -49,12 +50,15 @@ pass.
|
|
|
49
50
|
|
|
50
51
|
- `package.json` has a resolvable entry and, for bundles, a `dsh.bundle.patch`.
|
|
51
52
|
- The patch target row exists; ordered patch arrays are allowed.
|
|
52
|
-
- `engines.dsh` or an `@deepseek-ai/dsh*` peer range is declared.
|
|
53
|
+
- `engines.dsh` or an `@deepseek-ai/dsh*` peer range is declared. For 0.2.2, prefer `>=0.2.2-0 <0.3.0`; npm default semver needs an explicit `^0.2.2-alpha.3` union arm.
|
|
53
54
|
- `dsh.capabilities` lists every host surface the plugin touches (see below).
|
|
54
55
|
- `dsh.labels` is declared when the plugin modifies prompts, runs red-team
|
|
55
56
|
workloads, adds a model provider, exposes remote access, or mirrors another
|
|
56
57
|
project.
|
|
57
58
|
- The license is present; a missing license is advisory, not a fabricated pass.
|
|
59
|
+
- Module scope stays side-effect free: no top-level `await`, timer, `process.on`,
|
|
60
|
+
fs write, or subprocess spawn. Do that work in `apply()` and clean up with
|
|
61
|
+
`ctx.effect()`.
|
|
58
62
|
- README says how to install and what it needs.
|
|
59
63
|
- No “official”, “certified”, “secure”, or ranking claim.
|
|
60
64
|
|
|
@@ -82,6 +86,28 @@ Allowed `labels`: `prompt-modification`, `red-team`,
|
|
|
82
86
|
Do not label a plugin `official`, `verified`, `certified`, `secure`, or
|
|
83
87
|
`audited` — those words are treated as an endorsement claim and fail `DSC-13`.
|
|
84
88
|
|
|
89
|
+
## Import-time side effects
|
|
90
|
+
|
|
91
|
+
`DSC-10` is advisory — it never changes the verdict — but it records module-scope
|
|
92
|
+
work that runs before `apply()`: top-level `await`, timers, `process.on`, fs
|
|
93
|
+
writes, and subprocess spawns. The check is scoped to the entry module; the same
|
|
94
|
+
line in a shipped helper script that the entry does not import is not a hit.
|
|
95
|
+
Move the work inside
|
|
96
|
+
`apply()` and tie cleanup to `ctx.effect()`.
|
|
97
|
+
|
|
98
|
+
```js
|
|
99
|
+
// avoid: this runs when the package is imported, before the host can inject
|
|
100
|
+
writeFileSync(cacheFile, '')
|
|
101
|
+
|
|
102
|
+
export function apply(ctx) {
|
|
103
|
+
// prefer: runs when the plugin is applied, with a cleanup hook
|
|
104
|
+
ctx.effect(() => {
|
|
105
|
+
mkdirSync(dir, { recursive: true })
|
|
106
|
+
return () => rmSync(dir, { recursive: true, force: true })
|
|
107
|
+
})
|
|
108
|
+
}
|
|
109
|
+
```
|
|
110
|
+
|
|
85
111
|
## What ENTRY does not do
|
|
86
112
|
|
|
87
113
|
It is not a security audit, sandbox, full contract audit, market gate, score, or
|
package/docs/flow.md
CHANGED
|
File without changes
|
package/docs/levels.md
CHANGED
|
@@ -9,6 +9,8 @@
|
|
|
9
9
|
| **FLOW** | Can a user install, configure, use, upgrade, and remove it without fighting it? | J1–J8 user-journey checks | Yes, where runtime evidence exists; otherwise `not-run` |
|
|
10
10
|
| **BOOST** | Does it use Cordis well? | LEV-1–8 practice library and evidence cards | No plugin-level pass/fail; evidence is per practice |
|
|
11
11
|
|
|
12
|
+
> **Current baseline (2026-11-04):** DSH `0.2.2-alpha.3` (npm `alpha`), Node `>=24.9.0` (since 0.2.2-alpha.2), Cordis `4.0.6-alpha.2`. `engines.dsh`, when declared, decides alone since 0.2.1-alpha.4; `ctx.menus` is gone in 0.2.2-alpha.3; Typert codecs use `create()` since 0.1.6-alpha.2; `@deepseek-ai/dsh-client-runtime` was removed in 0.1.2-alpha.1 and has no 0.2.x.
|
|
13
|
+
|
|
12
14
|
## ENTRY
|
|
13
15
|
|
|
14
16
|
ENTRY is the compatibility floor. It checks the package shape, entry points,
|
package/icon.svg
CHANGED
|
File without changes
|
package/index.js
CHANGED
|
File without changes
|
package/locale/en.json
CHANGED
|
File without changes
|
package/locale/zh.json
CHANGED
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-plugin-guide",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.3",
|
|
4
4
|
"description": "A practical guide to DSH plugin quality: ENTRY checks, FLOW checks, and BOOST guidance. Community guide; not official, not a certification, not a ranking.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "index.js",
|