@dsh-plus/subagent-model 0.3.5 → 0.3.6
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/lib/client.js +5 -1
- package/package.json +2 -2
- package/src/client/draft.ts +5 -1
- package/src/config-api.ts +1 -0
- package/src/service.ts +1 -0
package/lib/client.js
CHANGED
|
@@ -410,7 +410,11 @@ ${extra}
|
|
|
410
410
|
}
|
|
411
411
|
function toPatch(draft) {
|
|
412
412
|
const entries = {};
|
|
413
|
-
for (const name of Object.keys(draft.rows).sort())
|
|
413
|
+
for (const name of Object.keys(draft.rows).sort()) {
|
|
414
|
+
const row = draft.rows[name];
|
|
415
|
+
if (row === void 0) continue;
|
|
416
|
+
entries[name] = row;
|
|
417
|
+
}
|
|
414
418
|
return {
|
|
415
419
|
enabled: draft.enabled,
|
|
416
420
|
entries
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dsh-plus/subagent-model",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.6",
|
|
4
4
|
"description": "dsh-plus service+ui plugin: 为 subagent/subagent_fork 等子代理按提供商配置模型与思考程度(或继承主代理)",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"src"
|
|
20
20
|
],
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@dsh-plus/shared": "0.1.
|
|
22
|
+
"@dsh-plus/shared": "0.1.15"
|
|
23
23
|
},
|
|
24
24
|
"peerDependencies": {
|
|
25
25
|
"@deepseek-ai/cordis": "^4.0.2",
|
package/src/client/draft.ts
CHANGED
|
@@ -64,6 +64,10 @@ export function toPatch(draft: Draft): Record<string, unknown> {
|
|
|
64
64
|
// (先 entries 后补目录空行)与 draftFrom(先目录后 entries)键序不同,
|
|
65
65
|
// 不排序会出现「未改动却永久 dirty」的假阳性。
|
|
66
66
|
const entries: Record<string, DraftRow> = {}
|
|
67
|
-
for (const name of Object.keys(draft.rows).sort())
|
|
67
|
+
for (const name of Object.keys(draft.rows).sort()) {
|
|
68
|
+
const row = draft.rows[name]
|
|
69
|
+
if (row === undefined) continue
|
|
70
|
+
entries[name] = row
|
|
71
|
+
}
|
|
68
72
|
return { enabled: draft.enabled, entries }
|
|
69
73
|
}
|
package/src/config-api.ts
CHANGED
package/src/service.ts
CHANGED
|
@@ -11,6 +11,7 @@
|
|
|
11
11
|
*/
|
|
12
12
|
import type { Context } from '@deepseek-ai/cordis'
|
|
13
13
|
import { Service } from '@deepseek-ai/cordis'
|
|
14
|
+
import type {} from '@deepseek-ai/dsh-settings'
|
|
14
15
|
|
|
15
16
|
import { Config, SETTINGS_NS, type SubagentModelConfig, validateEntries } from './config.ts'
|
|
16
17
|
import { registerCatalogApi } from './config-api.ts'
|