dsh-model-think-level 2.3.0 → 2.3.2
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/README.md +12 -1
- package/lib/client/ConfigPane.d.ts +16 -7
- package/lib/client/KeyManager.d.ts +3 -0
- package/lib/client/auto-continue-pref.d.ts +33 -0
- package/lib/client/auto-continue-rules.d.ts +96 -0
- package/lib/client/image-config-client.d.ts +10 -1
- package/lib/client/index.d.ts +1 -0
- package/lib/client/injection/auto-continue-run.d.ts +53 -0
- package/lib/client/injection/config-button-seat.d.ts +2 -2
- package/lib/client/injection/session-directory.d.ts +44 -0
- package/lib/client/locales.d.ts +17 -0
- package/lib/client/styles.d.ts +1 -1
- package/lib/client.js +153 -14
- package/lib/client.js.map +4 -4
- package/lib/image/config.d.ts +6 -0
- package/lib/index.d.ts +2 -0
- package/lib/index.js +281 -208
- package/lib/index.js.map +4 -4
- package/lib/key-index.d.ts +14 -5
- package/lib/key-mutation-queue.d.ts +2 -0
- package/package.json +5 -3
package/lib/key-index.d.ts
CHANGED
|
@@ -18,9 +18,10 @@
|
|
|
18
18
|
* sibling temp file, then `rename`), so a
|
|
19
19
|
* crash mid-write cannot leave a half-parsed index behind.
|
|
20
20
|
*
|
|
21
|
-
*
|
|
22
|
-
* read-modify-write
|
|
23
|
-
*
|
|
21
|
+
* Writes also keep immutable, bounded metadata-only pre-write history. A
|
|
22
|
+
* synchronous read-modify-write cannot interleave in one JS thread; a detected
|
|
23
|
+
* stale snapshot is rejected, but other processes and external synchronizers
|
|
24
|
+
* still need a coordinated write/merge protocol.
|
|
24
25
|
*
|
|
25
26
|
* @module dsh-model-think-level/key-index
|
|
26
27
|
*/
|
|
@@ -69,7 +70,11 @@ export declare function keyIndexFilePath(home?: string): string;
|
|
|
69
70
|
export declare function parseKeyIndex(raw: unknown): KeyIndexDocument;
|
|
70
71
|
/** Read the index; only an absent file means a fresh, empty document. */
|
|
71
72
|
export declare function readKeyIndex(file?: string): KeyIndexDocument;
|
|
72
|
-
/**
|
|
73
|
+
/** Metadata-only, immutable pre-write snapshots; never credential values. */
|
|
74
|
+
export declare const KEY_INDEX_HISTORY_LIMIT = 64;
|
|
75
|
+
/** Directory beside the index, deliberately outside the synced config file. */
|
|
76
|
+
export declare function keyIndexHistoryPath(file?: string): string;
|
|
77
|
+
/** Write atomically, only after preserving the previous metadata successfully. */
|
|
73
78
|
export declare function writeKeyIndex(document: KeyIndexDocument, file?: string): void;
|
|
74
79
|
/**
|
|
75
80
|
* One synchronous read-modify-write. The returned document is what was stored.
|
|
@@ -77,8 +82,12 @@ export declare function writeKeyIndex(document: KeyIndexDocument, file?: string)
|
|
|
77
82
|
* @param file - index path (tests pass a temp file).
|
|
78
83
|
*/
|
|
79
84
|
export declare function updateKeyIndex(mutate: (document: KeyIndexDocument) => KeyIndexDocument, file?: string): KeyIndexDocument;
|
|
80
|
-
/** One route's keys, or an empty list. */
|
|
85
|
+
/** One route's keys, or an empty list; inherited names are never entries. */
|
|
81
86
|
export declare function keyEntriesOf(document: KeyIndexDocument, route: string): readonly KeyIndexEntry[];
|
|
87
|
+
/** One route's extra endpoints, without inherited prototype members. */
|
|
88
|
+
export declare function routeEndpointsOf(document: KeyIndexDocument, route: string): RouteEndpoints | undefined;
|
|
89
|
+
/** One route's balance URL, without inherited prototype members. */
|
|
90
|
+
export declare function routeBalanceOf(document: KeyIndexDocument, route: string): string | undefined;
|
|
82
91
|
/** Whether one route's list names this reference. */
|
|
83
92
|
export declare function hasKeyEntry(document: KeyIndexDocument, route: string, ref: string): boolean;
|
|
84
93
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-model-think-level",
|
|
3
|
-
"version": "2.3.
|
|
3
|
+
"version": "2.3.2",
|
|
4
4
|
"description": "DSH 的第三方模型补齐思考等级:在官方 Models 页每个模型行注入 Thinking 开关和强度/模态编辑器,在输入框模型菜单加供应商→模型选择器、视觉徽章与等级行,并带搜索、拖拽排序、供应商启用开关;以及按路由接管请求头与 user-agent。",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "GaoHu1997 <gaohu9712@163.com>",
|
|
@@ -81,10 +81,10 @@
|
|
|
81
81
|
},
|
|
82
82
|
"peerDependencies": {
|
|
83
83
|
"@deepseek-ai/cordis": "^4.0.3",
|
|
84
|
+
"@deepseek-ai/dsh-api-remotes": "^0.1.5-alpha.1 || ^0.1.6-alpha.1 || ^0.1.7-alpha.1 || ^0.1.7-rc.1 || ^0.2.0-rc.1",
|
|
84
85
|
"@deepseek-ai/dsh-api-session-controller": "^0.1.5-alpha.1 || ^0.1.6-alpha.1 || ^0.1.7-alpha.1 || ^0.1.7-rc.1 || ^0.2.0-rc.1",
|
|
85
86
|
"@deepseek-ai/dsh-client-ui-model-selection": "^0.1.5-alpha.1 || ^0.1.6-alpha.1 || ^0.1.7-alpha.1 || ^0.1.7-rc.1 || ^0.2.0-rc.1",
|
|
86
87
|
"@deepseek-ai/dsh-client-ui-slots": "^0.1.5-alpha.1 || ^0.1.6-alpha.1 || ^0.1.7-alpha.1 || ^0.1.7-rc.1 || ^0.2.0-rc.1",
|
|
87
|
-
"@deepseek-ai/dsh-api-remotes": "^0.1.5-alpha.1 || ^0.1.6-alpha.1 || ^0.1.7-alpha.1 || ^0.1.7-rc.1 || ^0.2.0-rc.1",
|
|
88
88
|
"@deepseek-ai/dsh-settings": "^0.1.5-alpha.1 || ^0.1.6-alpha.1 || ^0.1.7-alpha.1 || ^0.1.7-rc.1 || ^0.2.0-rc.1",
|
|
89
89
|
"@deepseek-ai/schemastery": "^3.18.0",
|
|
90
90
|
"react": "^18.2.0 || ^19.0.0",
|
|
@@ -124,10 +124,12 @@
|
|
|
124
124
|
"@types/react": "^18.3.1",
|
|
125
125
|
"@types/react-dom": "^18.3.1",
|
|
126
126
|
"esbuild": "^0.28.0",
|
|
127
|
+
"immer": "^11.2.9",
|
|
127
128
|
"jsdom": "^27.0.0",
|
|
128
129
|
"react": "^18.2.0",
|
|
129
130
|
"react-dom": "^18.2.0",
|
|
130
131
|
"typescript": "^5.9.0",
|
|
131
|
-
"vitest": "^4.0.0"
|
|
132
|
+
"vitest": "^4.0.0",
|
|
133
|
+
"zustand": "^5.0.16"
|
|
132
134
|
}
|
|
133
135
|
}
|