@lssm/example.kb-update-pipeline 0.0.0-canary-20251217054315 → 0.0.0-canary-20251217060804
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/.turbo/turbo-build$colon$bundle.log +37 -0
- package/CHANGELOG.md +5 -33
- package/dist/contracts/index.d.ts +2 -0
- package/dist/contracts/pipeline.d.ts +136 -0
- package/dist/docs/index.d.ts +1 -0
- package/dist/docs/kb-update-pipeline.docblock.d.ts +1 -0
- package/dist/entities/index.d.ts +2 -0
- package/dist/entities/models.d.ts +60 -0
- package/dist/events.d.ts +73 -0
- package/dist/example.d.ts +35 -0
- package/dist/feature.d.ts +6 -0
- package/dist/handlers/index.d.ts +2 -0
- package/dist/handlers/memory.handlers.d.ts +67 -0
- package/dist/index.d.ts +9 -0
- package/dist/kb-update-pipeline.feature.d.ts +6 -0
- package/package.json +20 -20
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
|
|
2
|
+
[0m[2m[35m$[0m [2m[1mtsdown[0m
|
|
3
|
+
[34mℹ[39m tsdown [2mv0.17.4[22m powered by rolldown [2mv1.0.0-beta.53[22m
|
|
4
|
+
[34mℹ[39m config file: [4m/Users/tboutron/Documents/clients/lssm/monorepo-lssm/packages/contractspec/packages/examples/kb-update-pipeline/tsdown.config.js[24m (unrun)
|
|
5
|
+
[34mℹ[39m entry: [34msrc/events.ts, src/example.ts, src/feature.ts, src/index.ts, src/kb-update-pipeline.feature.ts, src/contracts/index.ts, src/contracts/pipeline.ts, src/docs/index.ts, src/docs/kb-update-pipeline.docblock.ts, src/entities/index.ts, src/entities/models.ts, src/handlers/index.ts, src/handlers/memory.handlers.ts[39m
|
|
6
|
+
[34mℹ[39m target: [34mesnext[39m
|
|
7
|
+
[34mℹ[39m tsconfig: [34mtsconfig.json[39m
|
|
8
|
+
[34mℹ[39m Build start
|
|
9
|
+
[34mℹ[39m Cleaning 30 files
|
|
10
|
+
[34mℹ[39m [2mdist/[22m[1mcontracts/pipeline.js[22m [2m3.44 kB[22m [2m│ gzip: 1.18 kB[22m
|
|
11
|
+
[34mℹ[39m [2mdist/[22m[1mhandlers/memory.handlers.js[22m [2m2.27 kB[22m [2m│ gzip: 0.87 kB[22m
|
|
12
|
+
[34mℹ[39m [2mdist/[22m[1mevents.js[22m [2m2.02 kB[22m [2m│ gzip: 0.54 kB[22m
|
|
13
|
+
[34mℹ[39m [2mdist/[22m[1mindex.js[22m [2m1.32 kB[22m [2m│ gzip: 0.46 kB[22m
|
|
14
|
+
[34mℹ[39m [2mdist/[22m[1mdocs/kb-update-pipeline.docblock.js[22m [2m1.26 kB[22m [2m│ gzip: 0.64 kB[22m
|
|
15
|
+
[34mℹ[39m [2mdist/[22m[1mentities/models.js[22m [2m1.11 kB[22m [2m│ gzip: 0.44 kB[22m
|
|
16
|
+
[34mℹ[39m [2mdist/[22m[1mfeature.js[22m [2m0.92 kB[22m [2m│ gzip: 0.45 kB[22m
|
|
17
|
+
[34mℹ[39m [2mdist/[22m[1mkb-update-pipeline.feature.js[22m [2m0.92 kB[22m [2m│ gzip: 0.45 kB[22m
|
|
18
|
+
[34mℹ[39m [2mdist/[22m[1mexample.js[22m [2m0.58 kB[22m [2m│ gzip: 0.36 kB[22m
|
|
19
|
+
[34mℹ[39m [2mdist/[22m[1mcontracts/index.js[22m [2m0.33 kB[22m [2m│ gzip: 0.16 kB[22m
|
|
20
|
+
[34mℹ[39m [2mdist/[22m[1mentities/index.js[22m [2m0.28 kB[22m [2m│ gzip: 0.16 kB[22m
|
|
21
|
+
[34mℹ[39m [2mdist/[22m[1mhandlers/index.js[22m [2m0.17 kB[22m [2m│ gzip: 0.11 kB[22m
|
|
22
|
+
[34mℹ[39m [2mdist/[22m[1mdocs/index.js[22m [2m0.04 kB[22m [2m│ gzip: 0.06 kB[22m
|
|
23
|
+
[34mℹ[39m [2mdist/[22m[32m[1mcontracts/pipeline.d.ts[22m[39m [2m3.93 kB[22m [2m│ gzip: 0.55 kB[22m
|
|
24
|
+
[34mℹ[39m [2mdist/[22m[32m[1mevents.d.ts[22m[39m [2m2.28 kB[22m [2m│ gzip: 0.40 kB[22m
|
|
25
|
+
[34mℹ[39m [2mdist/[22m[32m[1mhandlers/memory.handlers.d.ts[22m[39m [2m1.89 kB[22m [2m│ gzip: 0.62 kB[22m
|
|
26
|
+
[34mℹ[39m [2mdist/[22m[32m[1mentities/models.d.ts[22m[39m [2m1.81 kB[22m [2m│ gzip: 0.39 kB[22m
|
|
27
|
+
[34mℹ[39m [2mdist/[22m[32m[1mindex.d.ts[22m[39m [2m1.28 kB[22m [2m│ gzip: 0.37 kB[22m
|
|
28
|
+
[34mℹ[39m [2mdist/[22m[32m[1mexample.d.ts[22m[39m [2m1.06 kB[22m [2m│ gzip: 0.44 kB[22m
|
|
29
|
+
[34mℹ[39m [2mdist/[22m[32m[1mcontracts/index.d.ts[22m[39m [2m0.31 kB[22m [2m│ gzip: 0.13 kB[22m
|
|
30
|
+
[34mℹ[39m [2mdist/[22m[32m[1mhandlers/index.d.ts[22m[39m [2m0.25 kB[22m [2m│ gzip: 0.10 kB[22m
|
|
31
|
+
[34mℹ[39m [2mdist/[22m[32m[1mentities/index.d.ts[22m[39m [2m0.25 kB[22m [2m│ gzip: 0.13 kB[22m
|
|
32
|
+
[34mℹ[39m [2mdist/[22m[32m[1mkb-update-pipeline.feature.d.ts[22m[39m [2m0.21 kB[22m [2m│ gzip: 0.15 kB[22m
|
|
33
|
+
[34mℹ[39m [2mdist/[22m[32m[1mfeature.d.ts[22m[39m [2m0.19 kB[22m [2m│ gzip: 0.15 kB[22m
|
|
34
|
+
[34mℹ[39m [2mdist/[22m[32m[1mdocs/index.d.ts[22m[39m [2m0.01 kB[22m [2m│ gzip: 0.03 kB[22m
|
|
35
|
+
[34mℹ[39m [2mdist/[22m[32m[1mdocs/kb-update-pipeline.docblock.d.ts[22m[39m [2m0.01 kB[22m [2m│ gzip: 0.03 kB[22m
|
|
36
|
+
[34mℹ[39m 26 files, total: 28.14 kB
|
|
37
|
+
[32m✔[39m Build complete in [32m10674ms[39m
|
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @lssm/example.kb-update-pipeline
|
|
2
2
|
|
|
3
|
-
## 0.0.0-canary-
|
|
3
|
+
## 0.0.0-canary-20251217060804
|
|
4
4
|
|
|
5
5
|
### Minor Changes
|
|
6
6
|
|
|
@@ -9,35 +9,7 @@
|
|
|
9
9
|
### Patch Changes
|
|
10
10
|
|
|
11
11
|
- Updated dependencies [66a5dfd]
|
|
12
|
-
- @lssm/lib.contracts@0.0.0-canary-
|
|
13
|
-
- @lssm/lib.identity-rbac@0.0.0-canary-
|
|
14
|
-
- @lssm/lib.schema@0.0.0-canary-
|
|
15
|
-
- @lssm/module.notifications@0.0.0-canary-
|
|
16
|
-
|
|
17
|
-
## 1.42.0
|
|
18
|
-
|
|
19
|
-
### Minor Changes
|
|
20
|
-
|
|
21
|
-
- 66a5dfd: initial release
|
|
22
|
-
|
|
23
|
-
### Patch Changes
|
|
24
|
-
|
|
25
|
-
- Updated dependencies [66a5dfd]
|
|
26
|
-
- @lssm/lib.contracts@1.42.0
|
|
27
|
-
- @lssm/lib.identity-rbac@1.42.0
|
|
28
|
-
- @lssm/lib.schema@1.42.0
|
|
29
|
-
- @lssm/module.notifications@1.42.0
|
|
30
|
-
|
|
31
|
-
## 0.0.0-canary-20251217053014
|
|
32
|
-
|
|
33
|
-
### Minor Changes
|
|
34
|
-
|
|
35
|
-
- 66a5dfd: initial release
|
|
36
|
-
|
|
37
|
-
### Patch Changes
|
|
38
|
-
|
|
39
|
-
- Updated dependencies [66a5dfd]
|
|
40
|
-
- @lssm/lib.contracts@0.0.0-canary-20251217053014
|
|
41
|
-
- @lssm/lib.identity-rbac@0.0.0-canary-20251217053014
|
|
42
|
-
- @lssm/lib.schema@0.0.0-canary-20251217053014
|
|
43
|
-
- @lssm/module.notifications@0.0.0-canary-20251217053014
|
|
12
|
+
- @lssm/lib.contracts@0.0.0-canary-20251217060804
|
|
13
|
+
- @lssm/lib.identity-rbac@0.0.0-canary-20251217060804
|
|
14
|
+
- @lssm/lib.schema@0.0.0-canary-20251217060804
|
|
15
|
+
- @lssm/module.notifications@0.0.0-canary-20251217060804
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { KbPipelineCreateReviewTaskContract, KbPipelinePublishIfReadyContract, KbPipelineRunWatchContract, KbPipelineSubmitDecisionContract } from "./pipeline.js";
|
|
2
|
+
export { KbPipelineCreateReviewTaskContract, KbPipelinePublishIfReadyContract, KbPipelineRunWatchContract, KbPipelineSubmitDecisionContract };
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
import * as _lssm_lib_contracts0 from "@lssm/lib.contracts";
|
|
2
|
+
import * as _lssm_lib_schema0 from "@lssm/lib.schema";
|
|
3
|
+
|
|
4
|
+
//#region src/contracts/pipeline.d.ts
|
|
5
|
+
declare const KbPipelineRunWatchContract: _lssm_lib_contracts0.ContractSpec<_lssm_lib_schema0.SchemaModel<{
|
|
6
|
+
jurisdiction: {
|
|
7
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
8
|
+
isOptional: false;
|
|
9
|
+
};
|
|
10
|
+
}>, _lssm_lib_schema0.SchemaModel<{
|
|
11
|
+
candidates: {
|
|
12
|
+
type: _lssm_lib_schema0.SchemaModel<{
|
|
13
|
+
id: {
|
|
14
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
15
|
+
isOptional: false;
|
|
16
|
+
};
|
|
17
|
+
sourceDocumentId: {
|
|
18
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
19
|
+
isOptional: false;
|
|
20
|
+
};
|
|
21
|
+
detectedAt: {
|
|
22
|
+
type: _lssm_lib_schema0.FieldType<Date, string>;
|
|
23
|
+
isOptional: false;
|
|
24
|
+
};
|
|
25
|
+
diffSummary: {
|
|
26
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
27
|
+
isOptional: false;
|
|
28
|
+
};
|
|
29
|
+
riskLevel: {
|
|
30
|
+
type: _lssm_lib_schema0.EnumType<[string, string, string]>;
|
|
31
|
+
isOptional: false;
|
|
32
|
+
};
|
|
33
|
+
}>;
|
|
34
|
+
isArray: true;
|
|
35
|
+
isOptional: false;
|
|
36
|
+
};
|
|
37
|
+
}>, undefined>;
|
|
38
|
+
declare const KbPipelineCreateReviewTaskContract: _lssm_lib_contracts0.ContractSpec<_lssm_lib_schema0.SchemaModel<{
|
|
39
|
+
changeCandidateId: {
|
|
40
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
41
|
+
isOptional: false;
|
|
42
|
+
};
|
|
43
|
+
}>, _lssm_lib_schema0.SchemaModel<{
|
|
44
|
+
id: {
|
|
45
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
46
|
+
isOptional: false;
|
|
47
|
+
};
|
|
48
|
+
changeCandidateId: {
|
|
49
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
50
|
+
isOptional: false;
|
|
51
|
+
};
|
|
52
|
+
status: {
|
|
53
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
54
|
+
isOptional: false;
|
|
55
|
+
};
|
|
56
|
+
assignedRole: {
|
|
57
|
+
type: _lssm_lib_schema0.EnumType<[string, string]>;
|
|
58
|
+
isOptional: false;
|
|
59
|
+
};
|
|
60
|
+
decision: {
|
|
61
|
+
type: _lssm_lib_schema0.EnumType<[string, string]>;
|
|
62
|
+
isOptional: true;
|
|
63
|
+
};
|
|
64
|
+
decidedAt: {
|
|
65
|
+
type: _lssm_lib_schema0.FieldType<Date, string>;
|
|
66
|
+
isOptional: true;
|
|
67
|
+
};
|
|
68
|
+
decidedBy: {
|
|
69
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
70
|
+
isOptional: true;
|
|
71
|
+
};
|
|
72
|
+
}>, undefined>;
|
|
73
|
+
declare const KbPipelineSubmitDecisionContract: _lssm_lib_contracts0.ContractSpec<_lssm_lib_schema0.SchemaModel<{
|
|
74
|
+
reviewTaskId: {
|
|
75
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
76
|
+
isOptional: false;
|
|
77
|
+
};
|
|
78
|
+
decision: {
|
|
79
|
+
type: _lssm_lib_schema0.EnumType<[string, string]>;
|
|
80
|
+
isOptional: false;
|
|
81
|
+
};
|
|
82
|
+
decidedBy: {
|
|
83
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
84
|
+
isOptional: false;
|
|
85
|
+
};
|
|
86
|
+
decidedByRole: {
|
|
87
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
88
|
+
isOptional: false;
|
|
89
|
+
};
|
|
90
|
+
}>, _lssm_lib_schema0.SchemaModel<{
|
|
91
|
+
id: {
|
|
92
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
93
|
+
isOptional: false;
|
|
94
|
+
};
|
|
95
|
+
changeCandidateId: {
|
|
96
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
97
|
+
isOptional: false;
|
|
98
|
+
};
|
|
99
|
+
status: {
|
|
100
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
101
|
+
isOptional: false;
|
|
102
|
+
};
|
|
103
|
+
assignedRole: {
|
|
104
|
+
type: _lssm_lib_schema0.EnumType<[string, string]>;
|
|
105
|
+
isOptional: false;
|
|
106
|
+
};
|
|
107
|
+
decision: {
|
|
108
|
+
type: _lssm_lib_schema0.EnumType<[string, string]>;
|
|
109
|
+
isOptional: true;
|
|
110
|
+
};
|
|
111
|
+
decidedAt: {
|
|
112
|
+
type: _lssm_lib_schema0.FieldType<Date, string>;
|
|
113
|
+
isOptional: true;
|
|
114
|
+
};
|
|
115
|
+
decidedBy: {
|
|
116
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
117
|
+
isOptional: true;
|
|
118
|
+
};
|
|
119
|
+
}>, undefined>;
|
|
120
|
+
declare const KbPipelinePublishIfReadyContract: _lssm_lib_contracts0.ContractSpec<_lssm_lib_schema0.SchemaModel<{
|
|
121
|
+
jurisdiction: {
|
|
122
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
123
|
+
isOptional: false;
|
|
124
|
+
};
|
|
125
|
+
}>, _lssm_lib_schema0.SchemaModel<{
|
|
126
|
+
published: {
|
|
127
|
+
type: _lssm_lib_schema0.FieldType<boolean, boolean>;
|
|
128
|
+
isOptional: false;
|
|
129
|
+
};
|
|
130
|
+
reason: {
|
|
131
|
+
type: _lssm_lib_schema0.FieldType<string, string>;
|
|
132
|
+
isOptional: true;
|
|
133
|
+
};
|
|
134
|
+
}>, undefined>;
|
|
135
|
+
//#endregion
|
|
136
|
+
export { KbPipelineCreateReviewTaskContract, KbPipelinePublishIfReadyContract, KbPipelineRunWatchContract, KbPipelineSubmitDecisionContract };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { };
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import * as _lssm_lib_schema36 from "@lssm/lib.schema";
|
|
2
|
+
|
|
3
|
+
//#region src/entities/models.d.ts
|
|
4
|
+
declare const ChangeRiskLevelEnum: _lssm_lib_schema36.EnumType<[string, string, string]>;
|
|
5
|
+
declare const ReviewAssignedRoleEnum: _lssm_lib_schema36.EnumType<[string, string]>;
|
|
6
|
+
declare const ReviewDecisionEnum: _lssm_lib_schema36.EnumType<[string, string]>;
|
|
7
|
+
declare const ChangeCandidateModel: _lssm_lib_schema36.SchemaModel<{
|
|
8
|
+
id: {
|
|
9
|
+
type: _lssm_lib_schema36.FieldType<string, string>;
|
|
10
|
+
isOptional: false;
|
|
11
|
+
};
|
|
12
|
+
sourceDocumentId: {
|
|
13
|
+
type: _lssm_lib_schema36.FieldType<string, string>;
|
|
14
|
+
isOptional: false;
|
|
15
|
+
};
|
|
16
|
+
detectedAt: {
|
|
17
|
+
type: _lssm_lib_schema36.FieldType<Date, string>;
|
|
18
|
+
isOptional: false;
|
|
19
|
+
};
|
|
20
|
+
diffSummary: {
|
|
21
|
+
type: _lssm_lib_schema36.FieldType<string, string>;
|
|
22
|
+
isOptional: false;
|
|
23
|
+
};
|
|
24
|
+
riskLevel: {
|
|
25
|
+
type: _lssm_lib_schema36.EnumType<[string, string, string]>;
|
|
26
|
+
isOptional: false;
|
|
27
|
+
};
|
|
28
|
+
}>;
|
|
29
|
+
declare const ReviewTaskModel: _lssm_lib_schema36.SchemaModel<{
|
|
30
|
+
id: {
|
|
31
|
+
type: _lssm_lib_schema36.FieldType<string, string>;
|
|
32
|
+
isOptional: false;
|
|
33
|
+
};
|
|
34
|
+
changeCandidateId: {
|
|
35
|
+
type: _lssm_lib_schema36.FieldType<string, string>;
|
|
36
|
+
isOptional: false;
|
|
37
|
+
};
|
|
38
|
+
status: {
|
|
39
|
+
type: _lssm_lib_schema36.FieldType<string, string>;
|
|
40
|
+
isOptional: false;
|
|
41
|
+
};
|
|
42
|
+
assignedRole: {
|
|
43
|
+
type: _lssm_lib_schema36.EnumType<[string, string]>;
|
|
44
|
+
isOptional: false;
|
|
45
|
+
};
|
|
46
|
+
decision: {
|
|
47
|
+
type: _lssm_lib_schema36.EnumType<[string, string]>;
|
|
48
|
+
isOptional: true;
|
|
49
|
+
};
|
|
50
|
+
decidedAt: {
|
|
51
|
+
type: _lssm_lib_schema36.FieldType<Date, string>;
|
|
52
|
+
isOptional: true;
|
|
53
|
+
};
|
|
54
|
+
decidedBy: {
|
|
55
|
+
type: _lssm_lib_schema36.FieldType<string, string>;
|
|
56
|
+
isOptional: true;
|
|
57
|
+
};
|
|
58
|
+
}>;
|
|
59
|
+
//#endregion
|
|
60
|
+
export { ChangeCandidateModel, ChangeRiskLevelEnum, ReviewAssignedRoleEnum, ReviewDecisionEnum, ReviewTaskModel };
|
package/dist/events.d.ts
ADDED
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
import * as _lssm_lib_contracts3 from "@lssm/lib.contracts";
|
|
2
|
+
import * as _lssm_lib_schema53 from "@lssm/lib.schema";
|
|
3
|
+
|
|
4
|
+
//#region src/events.d.ts
|
|
5
|
+
declare const KbChangeDetectedEvent: _lssm_lib_contracts3.EventSpec<_lssm_lib_schema53.SchemaModel<{
|
|
6
|
+
changeCandidateId: {
|
|
7
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
8
|
+
isOptional: false;
|
|
9
|
+
};
|
|
10
|
+
sourceDocumentId: {
|
|
11
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
12
|
+
isOptional: false;
|
|
13
|
+
};
|
|
14
|
+
riskLevel: {
|
|
15
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
16
|
+
isOptional: false;
|
|
17
|
+
};
|
|
18
|
+
}>>;
|
|
19
|
+
declare const KbChangeSummarizedEvent: _lssm_lib_contracts3.EventSpec<_lssm_lib_schema53.SchemaModel<{
|
|
20
|
+
changeCandidateId: {
|
|
21
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
22
|
+
isOptional: false;
|
|
23
|
+
};
|
|
24
|
+
summary: {
|
|
25
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
26
|
+
isOptional: false;
|
|
27
|
+
};
|
|
28
|
+
riskLevel: {
|
|
29
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
30
|
+
isOptional: false;
|
|
31
|
+
};
|
|
32
|
+
}>>;
|
|
33
|
+
declare const KbPatchProposedEvent: _lssm_lib_contracts3.EventSpec<_lssm_lib_schema53.SchemaModel<{
|
|
34
|
+
changeCandidateId: {
|
|
35
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
36
|
+
isOptional: false;
|
|
37
|
+
};
|
|
38
|
+
proposedRuleVersionIds: {
|
|
39
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
40
|
+
isArray: true;
|
|
41
|
+
isOptional: false;
|
|
42
|
+
};
|
|
43
|
+
}>>;
|
|
44
|
+
declare const KbReviewRequestedEvent: _lssm_lib_contracts3.EventSpec<_lssm_lib_schema53.SchemaModel<{
|
|
45
|
+
reviewTaskId: {
|
|
46
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
47
|
+
isOptional: false;
|
|
48
|
+
};
|
|
49
|
+
changeCandidateId: {
|
|
50
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
51
|
+
isOptional: false;
|
|
52
|
+
};
|
|
53
|
+
assignedRole: {
|
|
54
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
55
|
+
isOptional: false;
|
|
56
|
+
};
|
|
57
|
+
}>>;
|
|
58
|
+
declare const KbReviewDecidedEvent: _lssm_lib_contracts3.EventSpec<_lssm_lib_schema53.SchemaModel<{
|
|
59
|
+
reviewTaskId: {
|
|
60
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
61
|
+
isOptional: false;
|
|
62
|
+
};
|
|
63
|
+
decision: {
|
|
64
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
65
|
+
isOptional: false;
|
|
66
|
+
};
|
|
67
|
+
decidedBy: {
|
|
68
|
+
type: _lssm_lib_schema53.FieldType<string, string>;
|
|
69
|
+
isOptional: false;
|
|
70
|
+
};
|
|
71
|
+
}>>;
|
|
72
|
+
//#endregion
|
|
73
|
+
export { KbChangeDetectedEvent, KbChangeSummarizedEvent, KbPatchProposedEvent, KbReviewDecidedEvent, KbReviewRequestedEvent };
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
//#region src/example.d.ts
|
|
2
|
+
declare const example: {
|
|
3
|
+
readonly id: "kb-update-pipeline";
|
|
4
|
+
readonly title: "KB Update Pipeline";
|
|
5
|
+
readonly summary: "Automation proposes KB updates; humans verify; everything audited and notified.";
|
|
6
|
+
readonly tags: readonly ["knowledge", "pipeline", "hitl", "audit"];
|
|
7
|
+
readonly kind: "knowledge";
|
|
8
|
+
readonly visibility: "public";
|
|
9
|
+
readonly docs: {
|
|
10
|
+
readonly rootDocId: "docs.examples.kb-update-pipeline";
|
|
11
|
+
};
|
|
12
|
+
readonly entrypoints: {
|
|
13
|
+
readonly packageName: "@lssm/example.kb-update-pipeline";
|
|
14
|
+
readonly feature: "./feature";
|
|
15
|
+
readonly contracts: "./contracts";
|
|
16
|
+
readonly handlers: "./handlers";
|
|
17
|
+
readonly docs: "./docs";
|
|
18
|
+
};
|
|
19
|
+
readonly surfaces: {
|
|
20
|
+
readonly templates: true;
|
|
21
|
+
readonly sandbox: {
|
|
22
|
+
readonly enabled: true;
|
|
23
|
+
readonly modes: readonly ["markdown", "specs", "builder"];
|
|
24
|
+
};
|
|
25
|
+
readonly studio: {
|
|
26
|
+
readonly enabled: true;
|
|
27
|
+
readonly installable: true;
|
|
28
|
+
};
|
|
29
|
+
readonly mcp: {
|
|
30
|
+
readonly enabled: true;
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
//#endregion
|
|
35
|
+
export { example as default };
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
//#region src/handlers/memory.handlers.d.ts
|
|
2
|
+
interface ChangeCandidate {
|
|
3
|
+
id: string;
|
|
4
|
+
sourceDocumentId: string;
|
|
5
|
+
detectedAt: Date;
|
|
6
|
+
diffSummary: string;
|
|
7
|
+
riskLevel: 'low' | 'medium' | 'high';
|
|
8
|
+
}
|
|
9
|
+
interface ReviewTask {
|
|
10
|
+
id: string;
|
|
11
|
+
changeCandidateId: string;
|
|
12
|
+
status: 'open' | 'decided';
|
|
13
|
+
assignedRole: 'curator' | 'expert';
|
|
14
|
+
decision?: 'approve' | 'reject';
|
|
15
|
+
decidedAt?: Date;
|
|
16
|
+
decidedBy?: string;
|
|
17
|
+
}
|
|
18
|
+
interface PipelineMemoryStore {
|
|
19
|
+
candidates: Map<string, ChangeCandidate>;
|
|
20
|
+
reviewTasks: Map<string, ReviewTask>;
|
|
21
|
+
proposedRuleVersionIdsByCandidate: Map<string, string[]>;
|
|
22
|
+
approvedRuleVersionIds: Set<string>;
|
|
23
|
+
notifications: {
|
|
24
|
+
kind: 'kb.review.requested';
|
|
25
|
+
reviewTaskId: string;
|
|
26
|
+
changeCandidateId: string;
|
|
27
|
+
assignedRole: 'curator' | 'expert';
|
|
28
|
+
createdAt: Date;
|
|
29
|
+
}[];
|
|
30
|
+
}
|
|
31
|
+
declare function createPipelineMemoryStore(): PipelineMemoryStore;
|
|
32
|
+
interface PipelineMemoryHandlers {
|
|
33
|
+
runWatch(input: {
|
|
34
|
+
jurisdiction: string;
|
|
35
|
+
}): Promise<{
|
|
36
|
+
candidates: ChangeCandidate[];
|
|
37
|
+
}>;
|
|
38
|
+
createReviewTask(input: {
|
|
39
|
+
changeCandidateId: string;
|
|
40
|
+
}): Promise<ReviewTask>;
|
|
41
|
+
proposeRulePatch(input: {
|
|
42
|
+
changeCandidateId: string;
|
|
43
|
+
proposedRuleVersionIds: string[];
|
|
44
|
+
}): Promise<{
|
|
45
|
+
proposedRuleVersionIds: string[];
|
|
46
|
+
}>;
|
|
47
|
+
markRuleVersionApproved(input: {
|
|
48
|
+
ruleVersionId: string;
|
|
49
|
+
}): Promise<{
|
|
50
|
+
ruleVersionId: string;
|
|
51
|
+
}>;
|
|
52
|
+
submitDecision(input: {
|
|
53
|
+
reviewTaskId: string;
|
|
54
|
+
decision: 'approve' | 'reject';
|
|
55
|
+
decidedBy: string;
|
|
56
|
+
decidedByRole: 'curator' | 'expert';
|
|
57
|
+
}): Promise<ReviewTask>;
|
|
58
|
+
publishIfReady(input: {
|
|
59
|
+
jurisdiction: string;
|
|
60
|
+
}): Promise<{
|
|
61
|
+
published: boolean;
|
|
62
|
+
reason?: string;
|
|
63
|
+
}>;
|
|
64
|
+
}
|
|
65
|
+
declare function createPipelineMemoryHandlers(store: PipelineMemoryStore): PipelineMemoryHandlers;
|
|
66
|
+
//#endregion
|
|
67
|
+
export { PipelineMemoryHandlers, PipelineMemoryStore, createPipelineMemoryHandlers, createPipelineMemoryStore };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { KbPipelineCreateReviewTaskContract, KbPipelinePublishIfReadyContract, KbPipelineRunWatchContract, KbPipelineSubmitDecisionContract } from "./contracts/pipeline.js";
|
|
2
|
+
import "./contracts/index.js";
|
|
3
|
+
import { ChangeCandidateModel, ChangeRiskLevelEnum, ReviewAssignedRoleEnum, ReviewDecisionEnum, ReviewTaskModel } from "./entities/models.js";
|
|
4
|
+
import "./entities/index.js";
|
|
5
|
+
import { KbChangeDetectedEvent, KbChangeSummarizedEvent, KbPatchProposedEvent, KbReviewDecidedEvent, KbReviewRequestedEvent } from "./events.js";
|
|
6
|
+
import example from "./example.js";
|
|
7
|
+
import { PipelineMemoryHandlers, PipelineMemoryStore, createPipelineMemoryHandlers, createPipelineMemoryStore } from "./handlers/memory.handlers.js";
|
|
8
|
+
import { KbUpdatePipelineFeature } from "./kb-update-pipeline.feature.js";
|
|
9
|
+
export { ChangeCandidateModel, ChangeRiskLevelEnum, KbChangeDetectedEvent, KbChangeSummarizedEvent, KbPatchProposedEvent, KbPipelineCreateReviewTaskContract, KbPipelinePublishIfReadyContract, KbPipelineRunWatchContract, KbPipelineSubmitDecisionContract, KbReviewDecidedEvent, KbReviewRequestedEvent, KbUpdatePipelineFeature, PipelineMemoryHandlers, PipelineMemoryStore, ReviewAssignedRoleEnum, ReviewDecisionEnum, ReviewTaskModel, createPipelineMemoryHandlers, createPipelineMemoryStore, example };
|
package/package.json
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lssm/example.kb-update-pipeline",
|
|
3
|
-
"version": "0.0.0-canary-
|
|
3
|
+
"version": "0.0.0-canary-20251217060804",
|
|
4
4
|
"description": "Example: KB update automation pipeline with HITL review and auditability.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
7
7
|
"module": "./dist/index.js",
|
|
8
8
|
"types": "./dist/index.d.ts",
|
|
9
9
|
"exports": {
|
|
10
|
-
".": "./
|
|
11
|
-
"./contracts": "./
|
|
12
|
-
"./contracts/pipeline": "./
|
|
13
|
-
"./docs": "./
|
|
14
|
-
"./docs/kb-update-pipeline.docblock": "./
|
|
15
|
-
"./entities": "./
|
|
16
|
-
"./entities/models": "./
|
|
17
|
-
"./events": "./
|
|
18
|
-
"./example": "./
|
|
19
|
-
"./feature": "./
|
|
20
|
-
"./handlers": "./
|
|
21
|
-
"./handlers/memory.handlers": "./
|
|
22
|
-
"./kb-update-pipeline.feature": "./
|
|
10
|
+
".": "./dist/index.js",
|
|
11
|
+
"./contracts": "./dist/contracts/index.js",
|
|
12
|
+
"./contracts/pipeline": "./dist/contracts/pipeline.js",
|
|
13
|
+
"./docs": "./dist/docs/index.js",
|
|
14
|
+
"./docs/kb-update-pipeline.docblock": "./dist/docs/kb-update-pipeline.docblock.js",
|
|
15
|
+
"./entities": "./dist/entities/index.js",
|
|
16
|
+
"./entities/models": "./dist/entities/models.js",
|
|
17
|
+
"./events": "./dist/events.js",
|
|
18
|
+
"./example": "./dist/example.js",
|
|
19
|
+
"./feature": "./dist/feature.js",
|
|
20
|
+
"./handlers": "./dist/handlers/index.js",
|
|
21
|
+
"./handlers/memory.handlers": "./dist/handlers/memory.handlers.js",
|
|
22
|
+
"./kb-update-pipeline.feature": "./dist/kb-update-pipeline.feature.js",
|
|
23
23
|
"./*": "./*"
|
|
24
24
|
},
|
|
25
25
|
"scripts": {
|
|
@@ -36,15 +36,15 @@
|
|
|
36
36
|
"test": "bun test"
|
|
37
37
|
},
|
|
38
38
|
"dependencies": {
|
|
39
|
-
"@lssm/lib.contracts": "0.0.0-canary-
|
|
40
|
-
"@lssm/lib.identity-rbac": "0.0.0-canary-
|
|
41
|
-
"@lssm/lib.schema": "0.0.0-canary-
|
|
42
|
-
"@lssm/module.notifications": "0.0.0-canary-
|
|
39
|
+
"@lssm/lib.contracts": "0.0.0-canary-20251217060804",
|
|
40
|
+
"@lssm/lib.identity-rbac": "0.0.0-canary-20251217060804",
|
|
41
|
+
"@lssm/lib.schema": "0.0.0-canary-20251217060804",
|
|
42
|
+
"@lssm/module.notifications": "0.0.0-canary-20251217060804",
|
|
43
43
|
"zod": "^4.1.13"
|
|
44
44
|
},
|
|
45
45
|
"devDependencies": {
|
|
46
|
-
"@lssm/tool.tsdown": "0.0.0-canary-
|
|
47
|
-
"@lssm/tool.typescript": "0.0.0-canary-
|
|
46
|
+
"@lssm/tool.tsdown": "0.0.0-canary-20251217060804",
|
|
47
|
+
"@lssm/tool.typescript": "0.0.0-canary-20251217060804",
|
|
48
48
|
"tsdown": "^0.17.4",
|
|
49
49
|
"typescript": "^5.9.3"
|
|
50
50
|
},
|