@lmzhen/dsh-evolution-activity 0.3.51 → 0.3.52
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 +10 -3
- package/lib/types/index.d.ts +7 -0
- package/package.json +6 -6
package/lib/index.js
CHANGED
|
@@ -32,14 +32,14 @@ function applyActivityEvent(items, event, maxItems, at = Date.now()) {
|
|
|
32
32
|
const record = {
|
|
33
33
|
sessionId: event.sessionId,
|
|
34
34
|
planId: event.planId,
|
|
35
|
-
policyFingerprint: event.policyFingerprint,
|
|
35
|
+
...event.policyFingerprint !== void 0 ? { policyFingerprint: event.policyFingerprint } : {},
|
|
36
36
|
memoryApplied: event.memoryApplied,
|
|
37
37
|
skillApplied: event.skillApplied,
|
|
38
38
|
rejectedOps: event.rejectedOps,
|
|
39
39
|
...event.executionFailures !== void 0 ? { executionFailures: event.executionFailures } : {},
|
|
40
40
|
...event.executionError !== void 0 ? { executionError: event.executionError } : {},
|
|
41
|
-
evidenceQuotes: event.evidenceQuotes,
|
|
42
|
-
estimatedInputChars: event.estimatedInputChars,
|
|
41
|
+
...event.evidenceQuotes !== void 0 ? { evidenceQuotes: event.evidenceQuotes } : {},
|
|
42
|
+
...event.estimatedInputChars !== void 0 ? { estimatedInputChars: event.estimatedInputChars } : {},
|
|
43
43
|
at
|
|
44
44
|
};
|
|
45
45
|
const cap = Number.isFinite(maxItems) ? Math.max(1, maxItems) : 200;
|
|
@@ -64,6 +64,13 @@ function parseActivityContent(raw) {
|
|
|
64
64
|
return [];
|
|
65
65
|
}
|
|
66
66
|
}
|
|
67
|
+
/**
|
|
68
|
+
* H-06: @internal — test-support API. The runtime listener path
|
|
69
|
+
* persists through the `transactIo` fold inside `apply()` and never calls
|
|
70
|
+
* this helper; it is kept only because the tests use it as a read barrier.
|
|
71
|
+
* Do not extend it into a second production read path (the apply() listener
|
|
72
|
+
* is the single sink).
|
|
73
|
+
*/
|
|
67
74
|
async function loadActivity(root, io) {
|
|
68
75
|
return parseActivityContent(await io.readText(activityFile(root)));
|
|
69
76
|
}
|
package/lib/types/index.d.ts
CHANGED
|
@@ -48,6 +48,13 @@ export declare function applyActivityEvent(items: EvolutionActivityRecord[], eve
|
|
|
48
48
|
* `parseActivityContent` is the matching single reader. */
|
|
49
49
|
export declare function serializeActivity(items: EvolutionActivityRecord[]): string;
|
|
50
50
|
export declare function parseActivityContent(raw: string | null): EvolutionActivityRecord[];
|
|
51
|
+
/**
|
|
52
|
+
* H-06: @internal — test-support API. The runtime listener path
|
|
53
|
+
* persists through the `transactIo` fold inside `apply()` and never calls
|
|
54
|
+
* this helper; it is kept only because the tests use it as a read barrier.
|
|
55
|
+
* Do not extend it into a second production read path (the apply() listener
|
|
56
|
+
* is the single sink).
|
|
57
|
+
*/
|
|
51
58
|
export declare function loadActivity(root: string, io: EvolutionIoLike): Promise<EvolutionActivityRecord[]>;
|
|
52
59
|
export declare const name = "evolution-activity";
|
|
53
60
|
export interface Config {
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lmzhen/dsh-evolution-activity",
|
|
3
3
|
"description": "Durable activity store for self-evolution plan outcomes (community build)",
|
|
4
|
-
"version": "0.3.
|
|
4
|
+
"version": "0.3.52",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
7
7
|
},
|
|
8
8
|
"repository": {
|
|
9
9
|
"type": "git",
|
|
10
10
|
"url": "git+https://github.com/lmzhen/dsh-evolution.git",
|
|
11
|
-
"directory": "packages/
|
|
11
|
+
"directory": "packages/evolution-activity"
|
|
12
12
|
},
|
|
13
13
|
"type": "module",
|
|
14
14
|
"main": "lib/index.js",
|
|
@@ -31,7 +31,7 @@
|
|
|
31
31
|
"license": "MIT",
|
|
32
32
|
"dependencies": {
|
|
33
33
|
"@deepseek-ai/schemastery": "^3.18.1",
|
|
34
|
-
"@lmzhen/dsh-evolution-core": "^0.3.
|
|
34
|
+
"@lmzhen/dsh-evolution-core": "^0.3.52"
|
|
35
35
|
},
|
|
36
36
|
"peerDependencies": {
|
|
37
37
|
"@deepseek-ai/cordis": "^4.0.1",
|
|
@@ -40,8 +40,8 @@
|
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"@deepseek-ai/cordis": "^4.0.1",
|
|
42
42
|
"@deepseek-ai/dsh-invariants": "^0.1.1-rc.2",
|
|
43
|
-
"@lmzhen/dsh-evolution-core": "^0.3.
|
|
44
|
-
"@lmzhen/dsh-evolution-io": "^0.3.
|
|
45
|
-
"@lmzhen/dsh-evolution-io-node": "^0.3.
|
|
43
|
+
"@lmzhen/dsh-evolution-core": "^0.3.52",
|
|
44
|
+
"@lmzhen/dsh-evolution-io": "^0.3.52",
|
|
45
|
+
"@lmzhen/dsh-evolution-io-node": "^0.3.52"
|
|
46
46
|
}
|
|
47
47
|
}
|