dsh-param-repair 0.0.0-stage → 1.0.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.
- package/ARCHITECTURE.md +78 -0
- package/CHANGELOG.md +257 -0
- package/LICENSE +201 -0
- package/README.en.md +435 -0
- package/README.es.md +430 -0
- package/README.hi.md +430 -0
- package/README.md +434 -2
- package/README.pt.md +430 -0
- package/SECURITY.md +37 -0
- package/THIRD_PARTY_NOTICES.md +21 -0
- package/cordis.patch.yml +40 -0
- package/index.mjs +597 -0
- package/lib/fix.mjs +532 -0
- package/lib/rosetta-data.json +889 -0
- package/lib/rosetta-data.schema.json +57 -0
- package/lib/rosetta.mjs +244 -0
- package/lib/sanitize.mjs +59 -0
- package/package.json +149 -4
- package/types.d.ts +127 -0
package/ARCHITECTURE.md
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
# ARCHITECTURE
|
|
2
|
+
|
|
3
|
+
`dsh-param-repair` is a pure-host JS plugin with two independent surfaces that
|
|
4
|
+
share two pure data/function libraries. There is no state beyond what Cordis
|
|
5
|
+
owns, no I/O, and no network access.
|
|
6
|
+
|
|
7
|
+
```
|
|
8
|
+
┌──────────────────────────────────────────────┐
|
|
9
|
+
│ index.mjs (the only host face) │
|
|
10
|
+
│ name / inject: ['commands', 'tools'] │
|
|
11
|
+
└───────┬───────────────────────┬──────────────┘
|
|
12
|
+
/translate cmd │ │
|
|
13
|
+
fix_json tool │ │ tools/post-execute listener
|
|
14
|
+
┌──────▼───────────┐ ┌──────▼──────────────────┐
|
|
15
|
+
│ lib/rosetta.mjs │ │ lib/fix.mjs │
|
|
16
|
+
│ vendor/parameter │ │ extract → parse → │
|
|
17
|
+
│ translation table│ │ escape/trailing/close/ │
|
|
18
|
+
│ (pure data) │ │ fill → validate │
|
|
19
|
+
└──────────────────┘ └──────┬──────────────────┘
|
|
20
|
+
│ sanitizeDiff
|
|
21
|
+
┌──────▼──────────────────┐
|
|
22
|
+
│ lib/sanitize.mjs │
|
|
23
|
+
│ bounded diff fragments │
|
|
24
|
+
└─────────────────────────┘
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
## The repair pipeline (tools/post-execute)
|
|
28
|
+
|
|
29
|
+
The repair layer is a **post-execute repair**, not a validator: the tool
|
|
30
|
+
registry already validates every canonical value against the tool's declared
|
|
31
|
+
`output.schema` before post-execute runs, so a value that violates the schema
|
|
32
|
+
arrives as a FAILED result — and failures are never flipped into successes
|
|
33
|
+
here. The reachable, repairable case is a successful result whose canonical
|
|
34
|
+
value is a **string carrying JSON text** (the schema root is string-rooted or
|
|
35
|
+
unconstrained `json`-rooted, or the tool is opted in through
|
|
36
|
+
`repair.toolNames`).
|
|
37
|
+
|
|
38
|
+
1. `extractJsonFromText` removes a markdown fence; non-JSON prose is left
|
|
39
|
+
untouched (`next()`).
|
|
40
|
+
2. If the text already parses and validates, nothing is claimed.
|
|
41
|
+
3. Otherwise `repairJsonText` runs the deterministic strategy loop
|
|
42
|
+
(`maxSteps` passes): `escapeRepair` (raw control characters in strings),
|
|
43
|
+
`trailingComma` (commas before closers), `truncationClosure` (unclosed
|
|
44
|
+
string/containers from truncation), then `fieldCompletion` (missing
|
|
45
|
+
`required` fields filled with explicit `null` — a placeholder, never
|
|
46
|
+
invented data).
|
|
47
|
+
4. The repaired value must parse and, when the schema declares constraints,
|
|
48
|
+
validate; otherwise the result stays untouched (`next()`, audit
|
|
49
|
+
`unrepairable`).
|
|
50
|
+
5. On success the listener returns `{ kind: 'accept', value }`: container
|
|
51
|
+
schemas receive the parsed object, string roots receive the repaired text;
|
|
52
|
+
the registry re-validates and re-renders the replacement. The
|
|
53
|
+
`translate/fix` session event records only tool name, call id, applied
|
|
54
|
+
strategies, edit count, and truncation flags — never payloads — and only on
|
|
55
|
+
a host whose event vocabulary admits the private type. On 0.1.6+/0.2.x the
|
|
56
|
+
append is skipped; the tool result is the audit trail.
|
|
57
|
+
|
|
58
|
+
The same pipeline powers `fix_json`, the explicit tool: the model hands over
|
|
59
|
+
`{ text, schema?, strategies? }` and receives `{ ok, repaired?, diff?,
|
|
60
|
+
strategies, truncated, validated, error? }` with the diff bounded by
|
|
61
|
+
`sanitizeDiff` (`diffMaxChars` / `diffMaxEntries`).
|
|
62
|
+
|
|
63
|
+
## The /translate command
|
|
64
|
+
|
|
65
|
+
`lib/rosetta.mjs` is the data-driven port of GPT-Rosetta-Stone: one canonical
|
|
66
|
+
parameter vocabulary (13 params) × 11 vendors. Rows marked `source: 'ported'`
|
|
67
|
+
come from the upstream table; `extended` rows add vendors from public API
|
|
68
|
+
references and are documented as such. The command surface is three pure text
|
|
69
|
+
helpers (`translateOverview`, `translateVendorList`, `translateParamList`,
|
|
70
|
+
`translatePair`) shared by the handler, so unit tests cover every output
|
|
71
|
+
without a UI dispatch.
|
|
72
|
+
|
|
73
|
+
## Relationship to the official tool pipeline
|
|
74
|
+
|
|
75
|
+
- Schema **validation** is the official registry's job; this plugin only
|
|
76
|
+
**repairs after the fact** and never substitutes for the registry.
|
|
77
|
+
- Parameter translation is a lookup table, not a model-routing adapter.
|
|
78
|
+
- Nothing is injected into the model context; `translate/fix` is log-only.
|
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,257 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## [1.0.1] - 2026-11-08
|
|
4
|
+
|
|
5
|
+
### Changed
|
|
6
|
+
|
|
7
|
+
- Both READMEs now state the original name (`dsh-translate` 0.2.x) and that the npm name now belongs to
|
|
8
|
+
the full-page translator, so readers arriving from an old link can migrate in one step.
|
|
9
|
+
## [1.0.0] - 2026-11-08
|
|
10
|
+
|
|
11
|
+
### Changed
|
|
12
|
+
|
|
13
|
+
- **Renamed from `dsh-translate` to `dsh-param-repair`.** The old name read as machine translation, while this package only maps request parameters between 11 vendor dialects and repairs malformed JSON tool output deterministically. The npm name `dsh-translate` now belongs to the translation plugin; the 0.2.x releases stay installable from the registry and are marked deprecated with a pointer here.
|
|
14
|
+
- **Nothing else moved.** The `/translate` command name, the `fix_json` tool name and input shape, the `translate/fix` audit event, every `Config` key, and the on-disk layout are unchanged. A profile that pinned `dsh-translate` migrates by reinstalling `dsh-param-repair` and replacing the package name in that row; every config value stays valid.
|
|
15
|
+
- Repository, badges, install commands, and the five READMEs now use the new name; the artwork was regenerated from `scripts/gen-readme-assets.py`.
|
|
16
|
+
|
|
17
|
+
## [0.2.25] - 2026-11-05
|
|
18
|
+
|
|
19
|
+
### Changed
|
|
20
|
+
|
|
21
|
+
- **Host 0.2.2 line support.** devDependencies move from 0.2.1-rc.2 to 0.2.2-rc.1, cordis to 4.1.0 / include 1.1.0 / loader 1.1.0, and schemastery to ~3.19.0 so a single copy resolves against `@deepseek-ai/dsh-llm` 0.2.2. `engines.dsh` appends `>=0.2.2-0 <0.3.0` (append-only) and `engines.node` becomes `^22.19.0 || >=24.9.0`. Adds `@deepseek-ai/dsh-package-manifest` (imported by dsh-llm 0.2.2's published types) and `@deepseek-ai/dsh-tool-executor-native`.
|
|
22
|
+
|
|
23
|
+
### Fixed
|
|
24
|
+
|
|
25
|
+
- **Tool dispatch uses the 0.2.2 batch executor.** `ctx.tools.execute()` now takes `{ calls, signal }` and returns `{ results }`; the assembly harnesses mount the native executor and unwrap `batch.results[0]?.result`, and the loader composition declares the executor row because 0.2.2 moved raw batch execution behind a pluggable executor.
|
|
26
|
+
- **Loader composition surfaces row failures again.** cordis 4.1.0 settles a failed row on its fiber instead of rejecting `loader.await()`; the runner awaits every row fiber so the invalid-config and missing-inject regressions still fail for their expected reason.
|
|
27
|
+
|
|
28
|
+
## [0.2.24] - 2026-10-18
|
|
29
|
+
|
|
30
|
+
### Changed
|
|
31
|
+
|
|
32
|
+
- Add a 1280×720 hero and a 960×540, 4-second terminal GIF rendered from the test run; `screenshots.json` is an object array and `capture.json` records the command.
|
|
33
|
+
|
|
34
|
+
## [0.2.23] - 2026-10-18
|
|
35
|
+
|
|
36
|
+
### Fixed
|
|
37
|
+
|
|
38
|
+
- **Docs no longer claim a `translate/fix` audit event lands on 0.1.6+/0.2.x.** Those hosts do not know the private event type; the adaptive gate skips the append. The tool result is the durable evidence. Also added an explicit “parameter mapping table, not machine translation” line.
|
|
39
|
+
|
|
40
|
+
## [0.2.22] - 2026-10-18
|
|
41
|
+
|
|
42
|
+
### Changed
|
|
43
|
+
|
|
44
|
+
- Compatibility: `engines.dsh` -> `>=0.2.1-0 <0.3.0`; devDependencies to `0.2.1-rc.2`; add `@deepseek-ai/dsh-working-directory`; `dshVersions` includes `0.2.1-rc.2`.
|
|
45
|
+
|
|
46
|
+
All notable changes to this project are documented in this file.
|
|
47
|
+
|
|
48
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
49
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
50
|
+
|
|
51
|
+
## [0.2.21] - 2026-10-10
|
|
52
|
+
|
|
53
|
+
### Changed
|
|
54
|
+
|
|
55
|
+
- The README now carries the terminal demo and an animated version of it: the same
|
|
56
|
+
real run, shown assembling line by line. The static image stays as the primary
|
|
57
|
+
one, because a crawler or an assistant can read a PNG and cannot read a GIF.
|
|
58
|
+
|
|
59
|
+
Both frames are that plugin's own output — the card is generated by running its
|
|
60
|
+
code over its own fixture, not drawn by hand.
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
## [0.2.20] - 2026-10-05
|
|
64
|
+
|
|
65
|
+
### Changed
|
|
66
|
+
|
|
67
|
+
- Correct the release date in the previous section, which was stamped with the literal string `undefined` by the release stamper. No content or behaviour change; the version is bumped only because npm will not republish an existing version.
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
## [Unreleased]
|
|
71
|
+
|
|
72
|
+
## [0.2.19] - 2026-10-05
|
|
73
|
+
|
|
74
|
+
undefined
|
|
75
|
+
|
|
76
|
+
## [0.2.18] - 2026-10-05
|
|
77
|
+
|
|
78
|
+
Adds the versioned five-language **interoperability declaration** to the READMEs: the plugin records, against DSH `0.2.0-rc.2`, every injection point it owns and why none of them collide with another plugin — no tool-name, service-key, slot, HTTP-route, patch-layer or global-mutation overlap, and, for each ordering-sensitive event it listens on, that the listener delegates through `next()` so a shared waterfall chain is never short-circuited. Verified by `dsh-plugin-doctor` K10-K14 (checkset `R0-R8+K1-K14+D0-D3,D9+CC1-CC5/3`). Documentation only; no behaviour change.
|
|
79
|
+
|
|
80
|
+
## [0.2.17] - 2026-10-04
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
### Changed
|
|
84
|
+
|
|
85
|
+
- Host pins move to `0.2.1-alpha.1`; re-verified against that host line. Every `@deepseek-ai/dsh-*` dev/test dependency now pins `0.2.1-alpha.1`, the `dshWorkshop.compatibility.dshVersions` timeline appends `0.2.1-alpha.1`, and the compatibility baseline in every README records the `dsh-v0.2.1-alpha.1` host. The declared host ranges (`engines.dsh` and the `peerDependencies` union) gain the `|| >=0.2.0-0 <0.3.0 || >=0.2.1-0 <0.3.0` clauses: the previous upper bound was `<0.2.0`, which under semver rejects every 0.2.x host, so the probe host itself was not installable. Nothing was narrowed — the `0.1.x` clauses are unchanged, in place and in order.
|
|
86
|
+
|
|
87
|
+
## [0.2.16] - 2026-09-25
|
|
88
|
+
|
|
89
|
+
### Changed
|
|
90
|
+
|
|
91
|
+
- Host pins move to `0.1.7-rc.2`; re-verified against that host line. Every `@deepseek-ai/dsh-*` dev/test dependency now pins `0.1.7-rc.2`, the `dshWorkshop.compatibility.dshVersions` timeline appends `0.1.7-rc.2`, and the compatibility baseline in every README records the `dsh-v0.1.7-rc.2` host. The declared host ranges (`engines.dsh` and the `peerDependencies` union) are deliberately **unchanged** — they already admit `0.1.7-rc.2`, and a range is what the manifest accepts, not what has been tested.
|
|
92
|
+
|
|
93
|
+
## [0.2.15] - 2026-09-24
|
|
94
|
+
### Changed
|
|
95
|
+
|
|
96
|
+
- Host pins move to `0.1.7-rc.1`; re-verified against that host line. Every `@deepseek-ai/dsh-*` dev/test dependency now pins `0.1.7-rc.1`, the `pnpm-lock.yaml` graph is regenerated, `dshWorkshop.compatibility.dshVersions` appends `0.1.7-rc.1`, the monthly Compat workflow and the CI probe install the `0.1.7-rc.1` host, and the compatibility baseline in every README records `dsh-v0.1.7-rc.1`. The declared host ranges (`engines.dsh` and the `peerDependencies` union) are deliberately **unchanged** — they already admit `0.1.7-rc.1`, and a range is what the manifest accepts, not what has been tested.
|
|
97
|
+
|
|
98
|
+
## [0.2.14] - 2026-09-23
|
|
99
|
+
|
|
100
|
+
### Changed
|
|
101
|
+
|
|
102
|
+
- Move the `@deepseek-ai/dsh-*` dev/test pins to the published `0.1.7-alpha.2` line and record `0.1.7-alpha.2` in `dshWorkshop.compatibility.dshVersions`; the monthly Compat workflow now installs the `0.1.7-alpha.2` host (`dsh-base` + `dsh-headless`) instead of `0.1.6-alpha.2`.
|
|
103
|
+
- Append the fourth host clause `|| >=0.1.7-0 <0.2.0` to `engines.dsh` and to all three `@deepseek-ai/dsh-*` peer ranges (`dsh-commands`, `dsh-session`, `dsh-tools`). Under semver's prerelease rule a range whose only prerelease comparators sit on earlier tuples cannot admit a later alpha, so the three-clause band excluded the very host line this release targets. No previously supported host line is dropped.
|
|
104
|
+
- Raise the `@deepseek-ai/cordis` dev/test pin to `^4.0.4`.
|
|
105
|
+
|
|
106
|
+
### Docs
|
|
107
|
+
|
|
108
|
+
- Correct `AGENTS.md`: the `test/*.test.mjs` layout entry and the "Session append is two-argument" seam conclusion both described the installed peers as pinned to `0.1.5-rc.2` devDependencies. The five READMEs already named `dsh-v0.1.7-alpha.2` and the four-clause peer range, so they needed no change.
|
|
109
|
+
|
|
110
|
+
## [0.2.13] - 2026-09-22
|
|
111
|
+
|
|
112
|
+
### Fixed
|
|
113
|
+
|
|
114
|
+
- Repair a mojibake artifact in the `package.json` `description`: an em dash had been double-encoded into `U+9225`. That field is published, so the registry document and the npm package page rendered the corrupted text, and a raw CJK code point has no business in that field at all.
|
|
115
|
+
|
|
116
|
+
## [0.2.12] - 2026-09-19
|
|
117
|
+
|
|
118
|
+
### Added
|
|
119
|
+
|
|
120
|
+
- `pnpm run check:lockfile` (`scripts/check-lockfile-drift.mjs`) fails fast when `package.json` and `pnpm-lock.yaml` disagree; the probe is read-only and the documented checks chain runs it alongside the other gates.
|
|
121
|
+
|
|
122
|
+
### Changed
|
|
123
|
+
|
|
124
|
+
- The release workflow now publishes through **npm trusted publishing** (OIDC) instead of the long-lived `NPM_TOKEN` secret: `setup-node` no longer sets `registry-url` (its empty `_authToken` line made the registry answer 404 on PUT), npm is upgraded to >= 11.5.1 before publishing, and the "NPM_TOKEN is not set -> skip" guard is gone so a missing publisher cannot turn a release into a silent no-op.
|
|
125
|
+
## [0.2.11] - 2026-09-18
|
|
126
|
+
|
|
127
|
+
### Changed
|
|
128
|
+
|
|
129
|
+
- Raise the `@deepseek-ai/dsh-*` dev/test pins from `0.1.5-rc.2` to `0.1.6-alpha.2`. The regeneration drops the four stale `@deepseek-ai/dsh-code-runtime` entries the rc.2 peer graph carried into `pnpm-lock.yaml` (`grep -c dsh-code-runtime pnpm-lock.yaml` is now 0); the package itself never depended on that group. Both typecheck rulers and the full test suite stay green against the new pins.
|
|
130
|
+
|
|
131
|
+
### Docs
|
|
132
|
+
|
|
133
|
+
- Qualify the seam baseline statements in `AGENTS.md` (the pinned peers are `0.1.5-rc.2`; the `0.1.2-rc.1` wording now records where the seam was originally verified) and enumerate the `0.1.6-alpha.2` append class in `index.mjs`: `Session.append<T>(type, data, ...opts)` takes a third argument only for surface-eligible event types and that argument is a `SurfaceIntent`, never an `ignorable` envelope — a non-surface `translate/fix` type has no third parameter, so the adaptive gate still skips and the tool result stays the model-visible log. No behavior change.
|
|
134
|
+
|
|
135
|
+
## [0.2.10] - 2026-09-12
|
|
136
|
+
|
|
137
|
+
### Changed
|
|
138
|
+
|
|
139
|
+
- Rename the four translated READMEs to `README-<lang>.md`. npm selects the package-page readme as the first markdown file matching its `{README,README.*}` glob (`@npmcli/package-json`, publish path), and that glob order puts `README.<lang>.md` ahead of `README.md` — so npm was serving the Simplified-Chinese file for this package too (measured on 15/15 sampled packages of the family). The new names sit outside the glob, so the English source is served again. No content changed apart from the language-switcher link each translation holds to its siblings, and the repo readme gate still passes. Takes effect with the next release; an already-published version cannot gain a corrected readme retroactively.
|
|
140
|
+
- Pin the `@deepseek-ai/dsh-*` dev/test dependencies to the published `0.1.5-rc.2` line and record `0.1.5-rc.2` in `dshWorkshop.compatibility.dshVersions`; the monthly Compat workflow now runs against `0.1.5-rc.2`. The peer range `>=0.1.2-rc.1 <0.2.0 || >=0.1.5-alpha.1 <0.2.0` is unchanged, so no supported host line is dropped.
|
|
141
|
+
|
|
142
|
+
## [0.2.9] - 2026-09-10
|
|
143
|
+
|
|
144
|
+
### Changed
|
|
145
|
+
|
|
146
|
+
- Pin the `@deepseek-ai/dsh-*` dev/test dependencies to the published `0.1.5-rc.1` line and record `0.1.5-rc.1` in `dshWorkshop.compatibility.dshVersions`; the monthly Compat workflow now runs against `0.1.5-rc.1`. The peer range `>=0.1.2-rc.1 <0.2.0 || >=0.1.5-alpha.1 <0.2.0` is unchanged, so no supported host line is dropped.
|
|
147
|
+
|
|
148
|
+
### Docs
|
|
149
|
+
|
|
150
|
+
- Refresh the five-language README compatibility baseline to `dsh-v0.1.5-rc.1` (verified 2026-09-10).
|
|
151
|
+
|
|
152
|
+
## [0.2.8] - 2026-09-09
|
|
153
|
+
|
|
154
|
+
### Changed
|
|
155
|
+
|
|
156
|
+
- Align the `@deepseek-ai/dsh-*` peer ranges to `>=0.1.2-rc.1 <0.2.0 || >=0.1.5-alpha.1 <0.2.0` and pin the dev/test dependencies to the published `0.1.5-alpha.1` line: adaptation to DeepSeek Harness `dsh-v0.1.5-alpha.1` (session format V3, `ctx.agent` removal, `Inbox` type-only interface); runtime behavior is unchanged for every supported host line.
|
|
157
|
+
- Record `0.1.5-alpha.1` in `dshWorkshop.compatibility.dshVersions`.
|
|
158
|
+
|
|
159
|
+
### Docs
|
|
160
|
+
|
|
161
|
+
- Refresh the five-language README compatibility baseline to `dsh-v0.1.5-alpha.1` (verified 2026-09-09).
|
|
162
|
+
|
|
163
|
+
## [0.2.7] - 2026-09-08
|
|
164
|
+
|
|
165
|
+
### Docs
|
|
166
|
+
|
|
167
|
+
- Repair GBK mojibake in the package.json description: the em dash was corrupted to the U+9225 U+003F marker pair; the description is restored to the clean pre-corruption text; no behavior change.
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
## [0.2.6] - 2026-09-07
|
|
171
|
+
|
|
172
|
+
### Docs
|
|
173
|
+
|
|
174
|
+
- Fix the DSH plugin badge URL: shields.io rejects the four-segment static badge form with "404 badge not found"; the label now uses the documented double-dash form (`dsh--plugin`), rendering identically; no behavior change.
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
## [0.2.5] - 2026-09-07
|
|
178
|
+
|
|
179
|
+
### Fixed
|
|
180
|
+
|
|
181
|
+
- Align the `@deepseek-ai/dsh-*` peer ranges to `>=0.1.2-rc.1 <0.2.0`: the older `>=0.1.0-rc.8 <0.2.0` band resolved to only the `0.1.0-rc.8` prerelease under registry-driven resolution and broke fresh tarball installs; no behavior change.
|
|
182
|
+
|
|
183
|
+
### Docs
|
|
184
|
+
|
|
185
|
+
- Refresh the five-language README support-version wording: the verified GitHub tag `dsh-v0.1.3-alpha.1` now leads the compatibility claim, while npm `0.1.2-rc.1` stays the published dependency-pin line (peers `>=0.1.2-rc.1 <0.2.0`); no behavior change.
|
|
186
|
+
|
|
187
|
+
|
|
188
|
+
## [0.2.4] - 2026-09-04
|
|
189
|
+
|
|
190
|
+
### Changed
|
|
191
|
+
|
|
192
|
+
- Align the devDependency pins to the published dsh `0.1.2-rc.1` line (5 `@deepseek-ai/dsh-*` packages), the `dshWorkshop` compatibility list, the compat workflow's CLI/base/headless installs, and the release-age exclusions; the five-language READMEs record the rc.1 facts. No behavior change: the adaptive `translate/fix` audit gate behaves identically on `0.1.2-rc.1` (`Session.append` still cannot stamp the `ignorable` marker).
|
|
193
|
+
|
|
194
|
+
## [0.2.3] - 2026-09-02
|
|
195
|
+
|
|
196
|
+
### Changed
|
|
197
|
+
|
|
198
|
+
- Align the devDependency pins to the published dsh 0.1.2-alpha.5 line and re-verify the adaptation claims; no behavior change.
|
|
199
|
+
|
|
200
|
+
## [0.2.2] - 2026-09-01
|
|
201
|
+
|
|
202
|
+
### Changed
|
|
203
|
+
|
|
204
|
+
- Upgrade the `@deepseek-ai/dsh-*` dev dependencies from `0.1.2-alpha.2` to `0.1.2-alpha.3` (peer range unchanged at `>=0.1.0-rc.8 <0.2.0`), keep the `@deepseek-ai/cordis` / `@deepseek-ai/schemastery` carets aligned at `^4.0.2` / `^3.18.2`, and refresh the compatibility workflow targets, `dshWorkshop.compatibility.dshVersions`, and the five-language README version strings to `0.1.2-alpha.3`.
|
|
205
|
+
- Upgrade the `@deepseek-ai/dsh-*` dev dependencies to `0.1.2-alpha.2` (peer range unchanged at `>=0.1.0-rc.8 <0.2.0`) and align the `@deepseek-ai/cordis` / `@deepseek-ai/schemastery` dev dependency carets to `^4.0.2` / `^3.18.2`.
|
|
206
|
+
- Derive the test-only call-id brand locally from the dsh-tools execution contract (`ToolExecution['callId']` in `test/call-id.mjs`) instead of importing `CallId` from `@deepseek-ai/dsh-llm`, whose brand was renamed `ToolCallId` on host master: the tests stay green on both the published line and the checkout.
|
|
207
|
+
|
|
208
|
+
## [0.2.1] - 2026-08-30
|
|
209
|
+
|
|
210
|
+
### Fixed
|
|
211
|
+
|
|
212
|
+
- Gate the `translate/fix` audit append by the host's session-event vocabulary: hosts whose `KNOWN_SESSION_EVENT_TYPES` covers the type append plainly, hosts with the `ignorable` append envelope append with the marker, and envelope-less hosts (`0.1.0-rc.6`–`0.1.1-rc.2`, and `0.1.2-alpha.1`, which fails closed on unknown event types at read) get no append — so a JSON repair can never pollute the session log on the 0.1.2-alpha host line. The repair outcome never depends on the audit append.
|
|
213
|
+
|
|
214
|
+
## [0.2.0] - 2026-08-26
|
|
215
|
+
|
|
216
|
+
### Added
|
|
217
|
+
|
|
218
|
+
- Rosetta vendor mapping moved from code to a loadable JSON schema (`lib/rosetta-data.json`), overridable via `rosettaDataPath`.
|
|
219
|
+
|
|
220
|
+
### Changed
|
|
221
|
+
|
|
222
|
+
- Dependency updates flow through the shared dsh-plugin-kit Renovate preset.
|
|
223
|
+
|
|
224
|
+
## [0.1.3] - 2026-08-23
|
|
225
|
+
|
|
226
|
+
### Fixed
|
|
227
|
+
|
|
228
|
+
- Repair a corrupted em-dash in a `lib/fix.mjs` JSDoc comment (prose only; no behavior change).
|
|
229
|
+
|
|
230
|
+
## [0.1.2] - 2026-08-22
|
|
231
|
+
|
|
232
|
+
### Changed
|
|
233
|
+
|
|
234
|
+
- Upgrade the `@deepseek-ai/dsh-*` dev dependencies to `0.1.1-rc.2` (peer range unchanged at `>=0.1.0-rc.8 <0.2.0`); the seams verified against the rc.8 peers (two-argument `session.append`, `{kind: 'accept', value}` post-execute decision, `CommandInvocation` handler, `CommandResult` `{kind, text}`) are unchanged in rc.2.
|
|
235
|
+
- Declare compatibility with DeepSeek Harness `0.1.1-rc.2` in the READMEs, the package metadata, and the compat workflow.
|
|
236
|
+
|
|
237
|
+
## [0.1.1] - 2026-08-21
|
|
238
|
+
|
|
239
|
+
### Changed
|
|
240
|
+
|
|
241
|
+
- Upgrade the `@deepseek-ai/dsh-*` peer and dev dependencies to `0.1.0-rc.8` (peer range `>=0.1.0-rc.8 <0.2.0`); the seams verified against the rc.6 peers (two-argument `session.append`, `{kind: 'accept', value}` post-execute decision, `CommandResult` `{kind, text}`) are unchanged in rc.8.
|
|
242
|
+
- Declare compatibility with DeepSeek Harness `0.1.0-rc.8` in the READMEs and the package metadata.
|
|
243
|
+
|
|
244
|
+
## [0.1.0] - 2026-08-16
|
|
245
|
+
|
|
246
|
+
### Added
|
|
247
|
+
|
|
248
|
+
- Vendor parameter translation table (`lib/rosetta.mjs`): 11 vendors × 13 canonical parameters, ported from GPT-Rosetta-Stone (openai/ernie/qwen rows unchanged) and extended from public API references; `/translate` command with overview/vendors/params/pairwise subcommands.
|
|
249
|
+
- Deterministic JSON repair (`lib/fix.mjs`): markdown-fence extraction, escape repair, trailing-comma removal, truncation closure, and required-field completion with explicit `null` placeholders — never fabricating data.
|
|
250
|
+
- `tools/post-execute` repair listener for successful string canonical values from string-rooted or `json`-rooted output schemas (plus `repair.toolNames` opt-in), replacing the value only after the registry re-validates it.
|
|
251
|
+
- `fix_json` tool with bounded, sanitized diff output.
|
|
252
|
+
- `translate/fix` session audit event (counts and flags only, never payloads).
|
|
253
|
+
- Five-language READMEs, `cordis.patch.yml`, architecture and security docs.
|
|
254
|
+
|
|
255
|
+
### Security
|
|
256
|
+
|
|
257
|
+
- oneOf validation now carries a branch budget (`MAX_ONE_OF_BUDGET`) so hostile exponential schemas fail closed instead of exhausting the process.
|
package/LICENSE
ADDED
|
@@ -0,0 +1,201 @@
|
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
http://www.apache.org/licenses/
|
|
4
|
+
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
+
|
|
7
|
+
1. Definitions.
|
|
8
|
+
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
+
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
+
the copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
+
other entities that control, are controlled by, or are under common
|
|
17
|
+
control with that entity. For the purposes of this definition,
|
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
+
direction or management of such entity, whether by contract or
|
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
+
exercising permissions granted by this License.
|
|
25
|
+
|
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
+
including but not limited to software source code, documentation
|
|
28
|
+
source, and configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
|
31
|
+
transformation or translation of a Source form, including but
|
|
32
|
+
not limited to compiled object code, generated documentation,
|
|
33
|
+
and conversions to other media types.
|
|
34
|
+
|
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
+
Object form, made available under the License, as indicated by a
|
|
37
|
+
copyright notice that is included in or attached to the work
|
|
38
|
+
(an example is provided in the Appendix below).
|
|
39
|
+
|
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
+
the Work and Derivative Works thereof.
|
|
47
|
+
|
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
|
49
|
+
the original version of the Work and any modifications or additions
|
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
+
|
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
64
|
+
subsequently incorporated within the Work.
|
|
65
|
+
|
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
|
72
|
+
|
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
+
where such license applies only to those patent claims licensable
|
|
79
|
+
by such Contributor that are necessarily infringed by their
|
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
+
institute patent litigation against any entity (including a
|
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
+
or contributory patent infringement, then any patent licenses
|
|
86
|
+
granted to You under this License for that Work shall terminate
|
|
87
|
+
as of the date such litigation is filed.
|
|
88
|
+
|
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
+
modifications, and in Source or Object form, provided that You
|
|
92
|
+
meet the following conditions:
|
|
93
|
+
|
|
94
|
+
(a) You must give any other recipients of the Work or
|
|
95
|
+
Derivative Works a copy of this License; and
|
|
96
|
+
|
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
|
98
|
+
stating that You changed the files; and
|
|
99
|
+
|
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
|
102
|
+
attribution notices from the Source form of the Work,
|
|
103
|
+
excluding those notices that do not pertain to any part of
|
|
104
|
+
the Derivative Works; and
|
|
105
|
+
|
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
|
108
|
+
include a readable copy of the attribution notices contained
|
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
|
111
|
+
of the following places: within a NOTICE text file distributed
|
|
112
|
+
as part of the Derivative Works; within the Source form or
|
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
|
114
|
+
within a display generated by the Derivative Works, if and
|
|
115
|
+
wherever such third-party notices normally appear. The contents
|
|
116
|
+
of the NOTICE file are for informational purposes only and
|
|
117
|
+
do not modify the License. You may add Your own attribution
|
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
+
that such additional attribution notices cannot be construed
|
|
121
|
+
as modifying the License.
|
|
122
|
+
|
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
|
124
|
+
may provide additional or different license terms and conditions
|
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
+
the conditions stated in this License.
|
|
129
|
+
|
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
+
this License, without any additional terms or conditions.
|
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
+
the terms of any separate license agreement you may have executed
|
|
136
|
+
with Licensor regarding such Contributions.
|
|
137
|
+
|
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
+
except as required for reasonable and customary use in describing the
|
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
+
|
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
|
152
|
+
|
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
|
158
|
+
incidental, or consequential damages of any character arising as a
|
|
159
|
+
result of this License or out of the use or inability to use the
|
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
+
other commercial damages or losses), even if such Contributor
|
|
163
|
+
has been advised of the possibility of such damages.
|
|
164
|
+
|
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
+
or other liability obligations and/or rights consistent with this
|
|
169
|
+
License. However, in accepting such obligations, You may act only
|
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
+
of your accepting any such warranty or additional liability.
|
|
175
|
+
|
|
176
|
+
END OF TERMS AND CONDITIONS
|
|
177
|
+
|
|
178
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
179
|
+
|
|
180
|
+
To apply the Apache License to your work, attach the following
|
|
181
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
182
|
+
replaced with your own identifying information. (Don't include
|
|
183
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
184
|
+
comment syntax for the file format. We also recommend that a
|
|
185
|
+
file or class name and description of purpose be included on the
|
|
186
|
+
same "printed page" as the copyright notice for easier
|
|
187
|
+
identification within third-party archives.
|
|
188
|
+
|
|
189
|
+
Copyright [yyyy] [name of copyright owner]
|
|
190
|
+
|
|
191
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
192
|
+
you may not use this file except in compliance with the License.
|
|
193
|
+
You may obtain a copy of the License at
|
|
194
|
+
|
|
195
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
196
|
+
|
|
197
|
+
Unless required by applicable law or agreed to in writing, software
|
|
198
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
199
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
200
|
+
See the License for the specific language governing permissions and
|
|
201
|
+
limitations under the License.
|