@lmzhen/dsh-evolution-approval 0.43.2-rc.1 → 0.45.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/lib/index.js +3 -4
- package/lib/types/index.d.ts +1 -1
- package/lib/types/routes.d.ts +1 -1
- package/locale/de.json +6 -0
- package/locale/en.json +6 -0
- package/locale/es.json +6 -0
- package/locale/fr.json +6 -0
- package/locale/ja.json +6 -0
- package/locale/pt.json +6 -0
- package/locale/ru.json +6 -0
- package/locale/zh.json +6 -0
- package/package.json +9 -9
package/lib/index.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { clampOnce, registerOwnerSettings, unwrapLive } from "@lmzhen/dsh-evolution-core";
|
|
2
1
|
import { Service } from "@deepseek-ai/cordis";
|
|
3
2
|
import { randomUUID } from "node:crypto";
|
|
3
|
+
import { clampOnce, unwrapLive } from "@lmzhen/dsh-evolution-core";
|
|
4
4
|
import z from "@deepseek-ai/schemastery";
|
|
5
|
-
import { PENDING_STATUSES } from "@lmzhen/dsh-evolution-state
|
|
5
|
+
import { PENDING_STATUSES } from "@lmzhen/dsh-evolution-state";
|
|
6
6
|
import { elapsedSince, textDiffFacts } from "@lmzhen/dsh-evolution-core/skills";
|
|
7
7
|
import { HOST_ROUTES, json, methodNotAllowed, readJsonObject, registerHostRoutes } from "@lmzhen/dsh-evolution-core/http-routes";
|
|
8
8
|
//#region lib/types/routes.js
|
|
@@ -277,7 +277,7 @@ function effectiveSessionPolicy(ctx, session) {
|
|
|
277
277
|
if (!approval || session === void 0) return void 0;
|
|
278
278
|
return approval.overrideOf(session) ?? approval.config?.policy ?? "ask";
|
|
279
279
|
}
|
|
280
|
-
var EvolutionApproval = class
|
|
280
|
+
var EvolutionApproval = class extends Service {
|
|
281
281
|
static inject = ["evolutionState"];
|
|
282
282
|
static Config = z.object({
|
|
283
283
|
enabled: z.boolean().default(false).volatile(),
|
|
@@ -307,7 +307,6 @@ var EvolutionApproval = class EvolutionApproval extends Service {
|
|
|
307
307
|
inFlight = /* @__PURE__ */ new Map();
|
|
308
308
|
constructor(ctx, config = {}) {
|
|
309
309
|
super(ctx, "evolutionApproval");
|
|
310
|
-
registerOwnerSettings(this.ctx, "evolution-approval", EvolutionApproval.Config);
|
|
311
310
|
this.enabledConfig = config.enabled;
|
|
312
311
|
this.stageForegroundConfig = config.stageForeground ?? true;
|
|
313
312
|
this.pendingTtlMsConfig = config.pendingTtlMs;
|
package/lib/types/index.d.ts
CHANGED
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
import { Context, Service } from '@deepseek-ai/cordis';
|
|
20
20
|
import type { Volatile } from '@deepseek-ai/cordis';
|
|
21
21
|
import z from '@deepseek-ai/schemastery';
|
|
22
|
-
import type { PendingKind, PendingRecord, PendingStatus } from '@lmzhen/dsh-evolution-state
|
|
22
|
+
import type { PendingKind, PendingRecord, PendingStatus } from '@lmzhen/dsh-evolution-state';
|
|
23
23
|
import type { DecisionAudit } from '@lmzhen/dsh-evolution-core/http-routes';
|
|
24
24
|
export type { PendingKind, PendingRecord, PendingStatus };
|
|
25
25
|
export type WriteRunner = (args: unknown) => Promise<{
|
package/lib/types/routes.d.ts
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
* the same methods.
|
|
15
15
|
* @module @lmzhen/dsh-evolution-approval/routes
|
|
16
16
|
*/
|
|
17
|
-
import type { PendingKind, PendingRecord, PendingStatus } from '@lmzhen/dsh-evolution-state
|
|
17
|
+
import type { PendingKind, PendingRecord, PendingStatus } from '@lmzhen/dsh-evolution-state';
|
|
18
18
|
import { elapsedSince } from '@lmzhen/dsh-evolution-core/skills';
|
|
19
19
|
import type { ConnectionFetchRouteLike, DecisionAudit } from '@lmzhen/dsh-evolution-core/http-routes';
|
|
20
20
|
import type { WritePreview } from './index.ts';
|
package/locale/de.json
ADDED
package/locale/en.json
ADDED
package/locale/es.json
ADDED
package/locale/fr.json
ADDED
package/locale/ja.json
ADDED
package/locale/pt.json
ADDED
package/locale/ru.json
ADDED
package/locale/zh.json
ADDED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lmzhen/dsh-evolution-approval",
|
|
3
3
|
"description": "Stage/pending approval service for Hermes-style self-evolution writes (community build)",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.45.0",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
@@ -18,27 +18,27 @@
|
|
|
18
18
|
"types": "./lib/types/index.d.ts",
|
|
19
19
|
"default": "./lib/index.js"
|
|
20
20
|
},
|
|
21
|
-
"./package.json": "./package.json"
|
|
21
|
+
"./package.json": "./package.json",
|
|
22
|
+
"./locale/*.json": "./locale/*.json"
|
|
22
23
|
},
|
|
23
24
|
"files": [
|
|
25
|
+
"locale/*.json",
|
|
24
26
|
"lib/*.js",
|
|
25
27
|
"lib/types/**/*.d.ts"
|
|
26
28
|
],
|
|
27
29
|
"license": "MIT",
|
|
28
30
|
"dependencies": {
|
|
29
31
|
"@deepseek-ai/schemastery": "^3.18.5",
|
|
30
|
-
"@lmzhen/dsh-evolution-core": "^0.
|
|
32
|
+
"@lmzhen/dsh-evolution-core": "^0.45.0"
|
|
31
33
|
},
|
|
32
34
|
"peerDependencies": {
|
|
33
35
|
"@deepseek-ai/cordis": "^4.0.5",
|
|
34
|
-
"@lmzhen/dsh-evolution-core": "^0.
|
|
35
|
-
"@lmzhen/dsh-evolution-state": "^0.
|
|
36
|
-
"@lmzhen/dsh-evolution-state-storage": "^0.43.2-rc.1"
|
|
36
|
+
"@lmzhen/dsh-evolution-core": "^0.45.0",
|
|
37
|
+
"@lmzhen/dsh-evolution-state": "^0.45.0"
|
|
37
38
|
},
|
|
38
39
|
"devDependencies": {
|
|
39
|
-
"@lmzhen/dsh-evolution-core": "^0.
|
|
40
|
-
"@lmzhen/dsh-evolution-state": "^0.
|
|
41
|
-
"@lmzhen/dsh-evolution-state-storage": "^0.43.2-rc.1"
|
|
40
|
+
"@lmzhen/dsh-evolution-core": "^0.45.0",
|
|
41
|
+
"@lmzhen/dsh-evolution-state": "^0.45.0"
|
|
42
42
|
},
|
|
43
43
|
"engines": {
|
|
44
44
|
"dsh": ">=0.2.2-rc.0 <0.2.3-0"
|