@lssm/lib.contracts 1.6.0 → 1.7.1

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.
Files changed (89) hide show
  1. package/dist/app-config/contracts.d.ts +51 -49
  2. package/dist/app-config/contracts.d.ts.map +1 -1
  3. package/dist/app-config/contracts.js +1 -1
  4. package/dist/app-config/contracts.js.map +1 -1
  5. package/dist/app-config/events.d.ts +28 -26
  6. package/dist/app-config/events.d.ts.map +1 -1
  7. package/dist/app-config/events.js +1 -1
  8. package/dist/app-config/events.js.map +1 -1
  9. package/dist/app-config/lifecycle-contracts.d.ts +81 -79
  10. package/dist/app-config/lifecycle-contracts.d.ts.map +1 -1
  11. package/dist/app-config/lifecycle-contracts.js +1 -1
  12. package/dist/app-config/lifecycle-contracts.js.map +1 -1
  13. package/dist/capabilities/openbanking.js.map +1 -1
  14. package/dist/client/react/form-render.d.ts +1 -0
  15. package/dist/client/react/form-render.d.ts.map +1 -1
  16. package/dist/contracts-adapter-input.d.ts +1 -0
  17. package/dist/contracts-adapter-input.d.ts.map +1 -1
  18. package/dist/events.d.ts +1 -0
  19. package/dist/events.d.ts.map +1 -1
  20. package/dist/events.js +1 -1
  21. package/dist/events.js.map +1 -1
  22. package/dist/forms.d.ts +1 -0
  23. package/dist/forms.d.ts.map +1 -1
  24. package/dist/install.d.ts +1 -0
  25. package/dist/install.d.ts.map +1 -1
  26. package/dist/integrations/contracts.d.ts +103 -101
  27. package/dist/integrations/contracts.d.ts.map +1 -1
  28. package/dist/integrations/contracts.js +1 -1
  29. package/dist/integrations/contracts.js.map +1 -1
  30. package/dist/integrations/openbanking/contracts/accounts.d.ts +67 -65
  31. package/dist/integrations/openbanking/contracts/accounts.d.ts.map +1 -1
  32. package/dist/integrations/openbanking/contracts/accounts.js +1 -1
  33. package/dist/integrations/openbanking/contracts/accounts.js.map +1 -1
  34. package/dist/integrations/openbanking/contracts/balances.d.ts +35 -33
  35. package/dist/integrations/openbanking/contracts/balances.d.ts.map +1 -1
  36. package/dist/integrations/openbanking/contracts/balances.js +1 -1
  37. package/dist/integrations/openbanking/contracts/balances.js.map +1 -1
  38. package/dist/integrations/openbanking/contracts/index.js.map +1 -1
  39. package/dist/integrations/openbanking/contracts/transactions.d.ts +49 -47
  40. package/dist/integrations/openbanking/contracts/transactions.d.ts.map +1 -1
  41. package/dist/integrations/openbanking/contracts/transactions.js +1 -1
  42. package/dist/integrations/openbanking/contracts/transactions.js.map +1 -1
  43. package/dist/integrations/openbanking/guards.js.map +1 -1
  44. package/dist/integrations/openbanking/models.d.ts +57 -54
  45. package/dist/integrations/openbanking/models.d.ts.map +1 -1
  46. package/dist/integrations/openbanking/models.js +1 -1
  47. package/dist/integrations/openbanking/models.js.map +1 -1
  48. package/dist/integrations/openbanking/telemetry.js.map +1 -1
  49. package/dist/integrations/providers/powens.js.map +1 -1
  50. package/dist/jsonschema.d.ts +1 -1
  51. package/dist/jsonschema.d.ts.map +1 -1
  52. package/dist/knowledge/contracts.d.ts +67 -65
  53. package/dist/knowledge/contracts.d.ts.map +1 -1
  54. package/dist/knowledge/contracts.js +1 -1
  55. package/dist/knowledge/contracts.js.map +1 -1
  56. package/dist/knowledge/spaces/product-canon.js.map +1 -1
  57. package/dist/knowledge/spaces/support-faq.js.map +1 -1
  58. package/dist/knowledge/spec.js.map +1 -1
  59. package/dist/onboarding-base.d.ts +30 -28
  60. package/dist/onboarding-base.d.ts.map +1 -1
  61. package/dist/onboarding-base.js +1 -1
  62. package/dist/onboarding-base.js.map +1 -1
  63. package/dist/presentations.d.ts +1 -0
  64. package/dist/presentations.d.ts.map +1 -1
  65. package/dist/presentations.v2.d.ts +1 -0
  66. package/dist/presentations.v2.d.ts.map +1 -1
  67. package/dist/regenerator/executor.js.map +1 -1
  68. package/dist/regenerator/service.js.map +1 -1
  69. package/dist/regenerator/sinks.js.map +1 -1
  70. package/dist/regenerator/utils.js.map +1 -1
  71. package/dist/registry.d.ts +1 -0
  72. package/dist/registry.d.ts.map +1 -1
  73. package/dist/resources.d.ts.map +1 -1
  74. package/dist/schema/{src → dist}/FieldType.js +1 -1
  75. package/dist/schema/dist/FieldType.js.map +1 -0
  76. package/dist/schema/dist/ScalarTypeEnum.js +2 -0
  77. package/dist/schema/dist/ScalarTypeEnum.js.map +1 -0
  78. package/dist/schema/{src → dist}/SchemaModel.js +1 -1
  79. package/dist/schema/dist/SchemaModel.js.map +1 -0
  80. package/dist/schema/dist/index.js +1 -0
  81. package/dist/spec.d.ts +1 -0
  82. package/dist/spec.d.ts.map +1 -1
  83. package/package.json +2 -2
  84. package/dist/schema/src/FieldType.js.map +0 -1
  85. package/dist/schema/src/ScalarTypeEnum.js +0 -2
  86. package/dist/schema/src/ScalarTypeEnum.js.map +0 -1
  87. package/dist/schema/src/SchemaModel.js.map +0 -1
  88. package/dist/schema/src/index.js +0 -1
  89. /package/dist/schema/{src → dist}/EnumType.js +0 -0
@@ -1,44 +1,46 @@
1
1
  import { ContractSpec } from "../spec.js";
2
2
  import { SpecRegistry } from "../registry.js";
3
+ import * as _lssm_lib_schema181 from "@lssm/lib.schema";
4
+ import { SchemaModel } from "@lssm/lib.schema";
3
5
 
4
6
  //#region src/knowledge/contracts.d.ts
5
7
  declare const CreateKnowledgeSource: ContractSpec<SchemaModel<{
6
8
  tenantId: {
7
- type: void 0<string, string>;
9
+ type: _lssm_lib_schema181.FieldType<string, string>;
8
10
  isOptional: false;
9
11
  };
10
12
  spaceKey: {
11
- type: void 0<string, string>;
13
+ type: _lssm_lib_schema181.FieldType<string, string>;
12
14
  isOptional: false;
13
15
  };
14
16
  spaceVersion: {
15
- type: void 0<number, number>;
17
+ type: _lssm_lib_schema181.FieldType<number, number>;
16
18
  isOptional: false;
17
19
  };
18
20
  label: {
19
- type: void 0<string, string>;
21
+ type: _lssm_lib_schema181.FieldType<string, string>;
20
22
  isOptional: false;
21
23
  };
22
24
  sourceType: {
23
- type: void 0<string, string>;
25
+ type: _lssm_lib_schema181.FieldType<string, string>;
24
26
  isOptional: false;
25
27
  };
26
28
  config: {
27
- type: void 0<Record<string, unknown>, Record<string, unknown>>;
29
+ type: _lssm_lib_schema181.FieldType<Record<string, unknown>, Record<string, unknown>>;
28
30
  isOptional: false;
29
31
  };
30
32
  syncSchedule: {
31
33
  type: SchemaModel<{
32
34
  enabled: {
33
- type: void 0<boolean, boolean>;
35
+ type: _lssm_lib_schema181.FieldType<boolean, boolean>;
34
36
  isOptional: false;
35
37
  };
36
38
  cron: {
37
- type: void 0<string, string>;
39
+ type: _lssm_lib_schema181.FieldType<string, string>;
38
40
  isOptional: true;
39
41
  };
40
42
  intervalMs: {
41
- type: void 0<number, number>;
43
+ type: _lssm_lib_schema181.FieldType<number, number>;
42
44
  isOptional: true;
43
45
  };
44
46
  }>;
@@ -46,92 +48,92 @@ declare const CreateKnowledgeSource: ContractSpec<SchemaModel<{
46
48
  };
47
49
  }>, SchemaModel<{
48
50
  id: {
49
- type: void 0<string, string>;
51
+ type: _lssm_lib_schema181.FieldType<string, string>;
50
52
  isOptional: false;
51
53
  };
52
54
  tenantId: {
53
- type: void 0<string, string>;
55
+ type: _lssm_lib_schema181.FieldType<string, string>;
54
56
  isOptional: false;
55
57
  };
56
58
  spaceKey: {
57
- type: void 0<string, string>;
59
+ type: _lssm_lib_schema181.FieldType<string, string>;
58
60
  isOptional: false;
59
61
  };
60
62
  spaceVersion: {
61
- type: void 0<number, number>;
63
+ type: _lssm_lib_schema181.FieldType<number, number>;
62
64
  isOptional: false;
63
65
  };
64
66
  label: {
65
- type: void 0<string, string>;
67
+ type: _lssm_lib_schema181.FieldType<string, string>;
66
68
  isOptional: false;
67
69
  };
68
70
  sourceType: {
69
- type: void 0<string, string>;
71
+ type: _lssm_lib_schema181.FieldType<string, string>;
70
72
  isOptional: false;
71
73
  };
72
74
  syncSchedule: {
73
75
  type: SchemaModel<{
74
76
  enabled: {
75
- type: void 0<boolean, boolean>;
77
+ type: _lssm_lib_schema181.FieldType<boolean, boolean>;
76
78
  isOptional: false;
77
79
  };
78
80
  cron: {
79
- type: void 0<string, string>;
81
+ type: _lssm_lib_schema181.FieldType<string, string>;
80
82
  isOptional: true;
81
83
  };
82
84
  intervalMs: {
83
- type: void 0<number, number>;
85
+ type: _lssm_lib_schema181.FieldType<number, number>;
84
86
  isOptional: true;
85
87
  };
86
88
  }>;
87
89
  isOptional: true;
88
90
  };
89
91
  lastSyncStatus: {
90
- type: void 0<string, string>;
92
+ type: _lssm_lib_schema181.FieldType<string, string>;
91
93
  isOptional: true;
92
94
  };
93
95
  lastSyncAt: {
94
- type: void 0<Date, string>;
96
+ type: _lssm_lib_schema181.FieldType<Date, string>;
95
97
  isOptional: true;
96
98
  };
97
99
  itemsProcessed: {
98
- type: void 0<number, number>;
100
+ type: _lssm_lib_schema181.FieldType<number, number>;
99
101
  isOptional: true;
100
102
  };
101
103
  createdAt: {
102
- type: void 0<Date, string>;
104
+ type: _lssm_lib_schema181.FieldType<Date, string>;
103
105
  isOptional: true;
104
106
  };
105
107
  updatedAt: {
106
- type: void 0<Date, string>;
108
+ type: _lssm_lib_schema181.FieldType<Date, string>;
107
109
  isOptional: true;
108
110
  };
109
111
  }>, undefined>;
110
112
  declare const UpdateKnowledgeSource: ContractSpec<SchemaModel<{
111
113
  sourceId: {
112
- type: void 0<string, string>;
114
+ type: _lssm_lib_schema181.FieldType<string, string>;
113
115
  isOptional: false;
114
116
  };
115
117
  label: {
116
- type: void 0<string, string>;
118
+ type: _lssm_lib_schema181.FieldType<string, string>;
117
119
  isOptional: true;
118
120
  };
119
121
  config: {
120
- type: void 0<Record<string, unknown>, Record<string, unknown>>;
122
+ type: _lssm_lib_schema181.FieldType<Record<string, unknown>, Record<string, unknown>>;
121
123
  isOptional: true;
122
124
  };
123
125
  syncSchedule: {
124
126
  type: SchemaModel<{
125
127
  enabled: {
126
- type: void 0<boolean, boolean>;
128
+ type: _lssm_lib_schema181.FieldType<boolean, boolean>;
127
129
  isOptional: false;
128
130
  };
129
131
  cron: {
130
- type: void 0<string, string>;
132
+ type: _lssm_lib_schema181.FieldType<string, string>;
131
133
  isOptional: true;
132
134
  };
133
135
  intervalMs: {
134
- type: void 0<number, number>;
136
+ type: _lssm_lib_schema181.FieldType<number, number>;
135
137
  isOptional: true;
136
138
  };
137
139
  }>;
@@ -139,149 +141,149 @@ declare const UpdateKnowledgeSource: ContractSpec<SchemaModel<{
139
141
  };
140
142
  }>, SchemaModel<{
141
143
  id: {
142
- type: void 0<string, string>;
144
+ type: _lssm_lib_schema181.FieldType<string, string>;
143
145
  isOptional: false;
144
146
  };
145
147
  tenantId: {
146
- type: void 0<string, string>;
148
+ type: _lssm_lib_schema181.FieldType<string, string>;
147
149
  isOptional: false;
148
150
  };
149
151
  spaceKey: {
150
- type: void 0<string, string>;
152
+ type: _lssm_lib_schema181.FieldType<string, string>;
151
153
  isOptional: false;
152
154
  };
153
155
  spaceVersion: {
154
- type: void 0<number, number>;
156
+ type: _lssm_lib_schema181.FieldType<number, number>;
155
157
  isOptional: false;
156
158
  };
157
159
  label: {
158
- type: void 0<string, string>;
160
+ type: _lssm_lib_schema181.FieldType<string, string>;
159
161
  isOptional: false;
160
162
  };
161
163
  sourceType: {
162
- type: void 0<string, string>;
164
+ type: _lssm_lib_schema181.FieldType<string, string>;
163
165
  isOptional: false;
164
166
  };
165
167
  syncSchedule: {
166
168
  type: SchemaModel<{
167
169
  enabled: {
168
- type: void 0<boolean, boolean>;
170
+ type: _lssm_lib_schema181.FieldType<boolean, boolean>;
169
171
  isOptional: false;
170
172
  };
171
173
  cron: {
172
- type: void 0<string, string>;
174
+ type: _lssm_lib_schema181.FieldType<string, string>;
173
175
  isOptional: true;
174
176
  };
175
177
  intervalMs: {
176
- type: void 0<number, number>;
178
+ type: _lssm_lib_schema181.FieldType<number, number>;
177
179
  isOptional: true;
178
180
  };
179
181
  }>;
180
182
  isOptional: true;
181
183
  };
182
184
  lastSyncStatus: {
183
- type: void 0<string, string>;
185
+ type: _lssm_lib_schema181.FieldType<string, string>;
184
186
  isOptional: true;
185
187
  };
186
188
  lastSyncAt: {
187
- type: void 0<Date, string>;
189
+ type: _lssm_lib_schema181.FieldType<Date, string>;
188
190
  isOptional: true;
189
191
  };
190
192
  itemsProcessed: {
191
- type: void 0<number, number>;
193
+ type: _lssm_lib_schema181.FieldType<number, number>;
192
194
  isOptional: true;
193
195
  };
194
196
  createdAt: {
195
- type: void 0<Date, string>;
197
+ type: _lssm_lib_schema181.FieldType<Date, string>;
196
198
  isOptional: true;
197
199
  };
198
200
  updatedAt: {
199
- type: void 0<Date, string>;
201
+ type: _lssm_lib_schema181.FieldType<Date, string>;
200
202
  isOptional: true;
201
203
  };
202
204
  }>, undefined>;
203
205
  declare const DeleteKnowledgeSource: ContractSpec<SchemaModel<{
204
206
  sourceId: {
205
- type: void 0<string, string>;
207
+ type: _lssm_lib_schema181.FieldType<string, string>;
206
208
  isOptional: false;
207
209
  };
208
210
  }>, SchemaModel<{
209
211
  success: {
210
- type: void 0<boolean, boolean>;
212
+ type: _lssm_lib_schema181.FieldType<boolean, boolean>;
211
213
  isOptional: false;
212
214
  };
213
215
  }>, undefined>;
214
216
  declare const ListKnowledgeSources: ContractSpec<SchemaModel<{
215
217
  tenantId: {
216
- type: void 0<string, string>;
218
+ type: _lssm_lib_schema181.FieldType<string, string>;
217
219
  isOptional: false;
218
220
  };
219
221
  spaceKey: {
220
- type: void 0<string, string>;
222
+ type: _lssm_lib_schema181.FieldType<string, string>;
221
223
  isOptional: true;
222
224
  };
223
225
  }>, SchemaModel<{
224
226
  sources: {
225
227
  type: SchemaModel<{
226
228
  id: {
227
- type: void 0<string, string>;
229
+ type: _lssm_lib_schema181.FieldType<string, string>;
228
230
  isOptional: false;
229
231
  };
230
232
  tenantId: {
231
- type: void 0<string, string>;
233
+ type: _lssm_lib_schema181.FieldType<string, string>;
232
234
  isOptional: false;
233
235
  };
234
236
  spaceKey: {
235
- type: void 0<string, string>;
237
+ type: _lssm_lib_schema181.FieldType<string, string>;
236
238
  isOptional: false;
237
239
  };
238
240
  spaceVersion: {
239
- type: void 0<number, number>;
241
+ type: _lssm_lib_schema181.FieldType<number, number>;
240
242
  isOptional: false;
241
243
  };
242
244
  label: {
243
- type: void 0<string, string>;
245
+ type: _lssm_lib_schema181.FieldType<string, string>;
244
246
  isOptional: false;
245
247
  };
246
248
  sourceType: {
247
- type: void 0<string, string>;
249
+ type: _lssm_lib_schema181.FieldType<string, string>;
248
250
  isOptional: false;
249
251
  };
250
252
  syncSchedule: {
251
253
  type: SchemaModel<{
252
254
  enabled: {
253
- type: void 0<boolean, boolean>;
255
+ type: _lssm_lib_schema181.FieldType<boolean, boolean>;
254
256
  isOptional: false;
255
257
  };
256
258
  cron: {
257
- type: void 0<string, string>;
259
+ type: _lssm_lib_schema181.FieldType<string, string>;
258
260
  isOptional: true;
259
261
  };
260
262
  intervalMs: {
261
- type: void 0<number, number>;
263
+ type: _lssm_lib_schema181.FieldType<number, number>;
262
264
  isOptional: true;
263
265
  };
264
266
  }>;
265
267
  isOptional: true;
266
268
  };
267
269
  lastSyncStatus: {
268
- type: void 0<string, string>;
270
+ type: _lssm_lib_schema181.FieldType<string, string>;
269
271
  isOptional: true;
270
272
  };
271
273
  lastSyncAt: {
272
- type: void 0<Date, string>;
274
+ type: _lssm_lib_schema181.FieldType<Date, string>;
273
275
  isOptional: true;
274
276
  };
275
277
  itemsProcessed: {
276
- type: void 0<number, number>;
278
+ type: _lssm_lib_schema181.FieldType<number, number>;
277
279
  isOptional: true;
278
280
  };
279
281
  createdAt: {
280
- type: void 0<Date, string>;
282
+ type: _lssm_lib_schema181.FieldType<Date, string>;
281
283
  isOptional: true;
282
284
  };
283
285
  updatedAt: {
284
- type: void 0<Date, string>;
286
+ type: _lssm_lib_schema181.FieldType<Date, string>;
285
287
  isOptional: true;
286
288
  };
287
289
  }>;
@@ -291,20 +293,20 @@ declare const ListKnowledgeSources: ContractSpec<SchemaModel<{
291
293
  }>, undefined>;
292
294
  declare const TriggerKnowledgeSourceSync: ContractSpec<SchemaModel<{
293
295
  sourceId: {
294
- type: void 0<string, string>;
296
+ type: _lssm_lib_schema181.FieldType<string, string>;
295
297
  isOptional: false;
296
298
  };
297
299
  }>, SchemaModel<{
298
300
  success: {
299
- type: void 0<boolean, boolean>;
301
+ type: _lssm_lib_schema181.FieldType<boolean, boolean>;
300
302
  isOptional: false;
301
303
  };
302
304
  itemsProcessed: {
303
- type: void 0<number, number>;
305
+ type: _lssm_lib_schema181.FieldType<number, number>;
304
306
  isOptional: true;
305
307
  };
306
308
  error: {
307
- type: void 0<string, string>;
309
+ type: _lssm_lib_schema181.FieldType<string, string>;
308
310
  isOptional: true;
309
311
  };
310
312
  }>, undefined>;
@@ -1 +1 @@
1
- {"version":3,"file":"contracts.d.ts","names":[],"sources":["../../src/knowledge/contracts.ts"],"sourcesContent":[],"mappings":";;;;cA8Ga,uBAAqB,aAAA;EAArB,QAAA,EAAA;IAoBX,IAAA,EAAA,KAAA,CAAA,CAAA,MAAA,EAAA,MAAA,CAAA;;;;;;;;;;;;IApBgC,IAAA,QAAA,CAAA,MAAA,EAAA,MAAA,CAAA;IAAA,UAAA,EAAA,KAAA;;;;;;;;;;;;;;;;;;;MAAA,CAAA;MAAA,UAAA,EAAA;QAsBrB,IAAA,QAoBX,CAAA,MAAA,EAAA,MAAA,CAAA;QAAA,UAAA,EAAA,IAAA;;;;;;;UA1CgC,KAAA;;EAsBA,CAAA;EAAA,QAAA,EAAA;;;;;;;;;;;;;;;;;;;EAAA,CAAA;EAAA,YAAA,EAAA;IAsBrB,IAAA,aAAA,CAAA;MAoBX,OAAA,EAAA;QApBgC,IAAA,QAAA,CAAA,OAAA,EAAA,OAAA,CAAA;QAAA,UAAA,EAAA,KAAA;;MAAA,IAAA,EAAA;QAAA,IAAA,QAAA,CAAA,MAAA,EAAA,MAAA,CAAA;QAsBrB,UAAA,EAoBX,IAAA;MAAA,CAAA;;QApB+B,IAAA,QAAA,CAAA,MAAA,EAAA,MAAA,CAAA;QAAA,UAAA,EAAA,IAA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";import{defineCommand as n,defineQuery as r}from"../spec.js";const i=new t({name:`KnowledgeSyncSchedule`,fields:{enabled:{type:e.Boolean(),isOptional:!1},cron:{type:e.String_unsecure(),isOptional:!0},intervalMs:{type:e.Int_unsecure(),isOptional:!0}}}),a=new t({name:`KnowledgeSourceRecord`,fields:{id:{type:e.ID(),isOptional:!1},tenantId:{type:e.ID(),isOptional:!1},spaceKey:{type:e.NonEmptyString(),isOptional:!1},spaceVersion:{type:e.Int_unsecure(),isOptional:!1},label:{type:e.String_unsecure(),isOptional:!1},sourceType:{type:e.String_unsecure(),isOptional:!1},syncSchedule:{type:i,isOptional:!0},lastSyncStatus:{type:e.String_unsecure(),isOptional:!0},lastSyncAt:{type:e.DateTime(),isOptional:!0},itemsProcessed:{type:e.Int_unsecure(),isOptional:!0},createdAt:{type:e.DateTime(),isOptional:!0},updatedAt:{type:e.DateTime(),isOptional:!0}}}),o=new t({name:`CreateKnowledgeSourceInput`,fields:{tenantId:{type:e.ID(),isOptional:!1},spaceKey:{type:e.NonEmptyString(),isOptional:!1},spaceVersion:{type:e.Int_unsecure(),isOptional:!1},label:{type:e.String_unsecure(),isOptional:!1},sourceType:{type:e.NonEmptyString(),isOptional:!1},config:{type:e.JSONObject(),isOptional:!1},syncSchedule:{type:i,isOptional:!0}}}),s=new t({name:`UpdateKnowledgeSourceInput`,fields:{sourceId:{type:e.ID(),isOptional:!1},label:{type:e.String_unsecure(),isOptional:!0},config:{type:e.JSONObject(),isOptional:!0},syncSchedule:{type:i,isOptional:!0}}}),c=new t({name:`DeleteKnowledgeSourceInput`,fields:{sourceId:{type:e.ID(),isOptional:!1}}}),l=new t({name:`DeleteKnowledgeSourceOutput`,fields:{success:{type:e.Boolean(),isOptional:!1}}}),u=new t({name:`ListKnowledgeSourcesInput`,fields:{tenantId:{type:e.ID(),isOptional:!1},spaceKey:{type:e.NonEmptyString(),isOptional:!0}}}),d=new t({name:`ListKnowledgeSourcesOutput`,fields:{sources:{type:a,isOptional:!1,isArray:!0}}}),f=new t({name:`TriggerKnowledgeSyncInput`,fields:{sourceId:{type:e.ID(),isOptional:!1}}}),p=new t({name:`TriggerKnowledgeSyncOutput`,fields:{success:{type:e.Boolean(),isOptional:!1},itemsProcessed:{type:e.Int_unsecure(),isOptional:!0},error:{type:e.String_unsecure(),isOptional:!0}}}),m=n({meta:{name:`knowledge.source.create`,version:1,description:`Create a knowledge source binding for a tenant.`,goal:`Onboard a new knowledge ingestion source such as Notion or uploads.`,context:`Used by Ops and App Studio to configure knowledge ingestion per tenant and space.`,owners:[`platform.knowledge`],tags:[`knowledge`,`sources`],stability:`experimental`},io:{input:o,output:a},policy:{auth:`admin`,policies:[{name:`platform.knowledge.manage`,version:1}]}}),h=n({meta:{name:`knowledge.source.update`,version:1,description:`Update metadata or configuration for a knowledge source.`,goal:`Allow rotation of credentials, sync schedules, and labels.`,context:`Supports editing how a tenant ingests knowledge (e.g., toggling sync cadence).`,owners:[`platform.knowledge`],tags:[`knowledge`,`sources`],stability:`experimental`},io:{input:s,output:a},policy:{auth:`admin`,policies:[{name:`platform.knowledge.manage`,version:1}]}}),g=n({meta:{name:`knowledge.source.delete`,version:1,description:`Delete a knowledge source binding for a tenant.`,goal:`Remove obsolete or compromised knowledge ingestion paths.`,context:`Ensures ephemeral or external sources can be removed cleanly without leaving residual bindings.`,owners:[`platform.knowledge`],tags:[`knowledge`,`sources`],stability:`experimental`},io:{input:c,output:l},policy:{auth:`admin`,policies:[{name:`platform.knowledge.manage`,version:1}]}}),_=r({meta:{name:`knowledge.source.list`,version:1,description:`List knowledge sources configured for a tenant.`,goal:`Provide visibility into knowledge ingest configuration and schedules.`,context:`Used by App Studio and Ops flows to surface knowledge sources and their health.`,owners:[`platform.knowledge`],tags:[`knowledge`,`sources`],stability:`experimental`},io:{input:u,output:d},policy:{auth:`admin`,policies:[{name:`platform.knowledge.read`,version:1}]}}),v=n({meta:{name:`knowledge.source.triggerSync`,version:1,description:`Trigger an immediate sync for a knowledge source.`,goal:`Support manual or automated sync retries for knowledge ingestion.`,context:`Invoked by Ops tooling or monitors when knowledge content must be refreshed or reprocessed.`,owners:[`platform.knowledge`],tags:[`knowledge`,`sources`],stability:`experimental`},io:{input:f,output:p},policy:{auth:`admin`,policies:[{name:`platform.knowledge.manage`,version:1}]}}),y={CreateKnowledgeSource:m,UpdateKnowledgeSource:h,DeleteKnowledgeSource:g,ListKnowledgeSources:_,TriggerKnowledgeSourceSync:v};function b(e){return e.register(m).register(h).register(g).register(_).register(v)}export{m as CreateKnowledgeSource,g as DeleteKnowledgeSource,_ as ListKnowledgeSources,v as TriggerKnowledgeSourceSync,h as UpdateKnowledgeSource,y as knowledgeContracts,b as registerKnowledgeContracts};
1
+ import{l as e}from"../schema/dist/ScalarTypeEnum.js";import{t}from"../schema/dist/SchemaModel.js";import"../schema/dist/index.js";import{defineCommand as n,defineQuery as r}from"../spec.js";const i=new t({name:`KnowledgeSyncSchedule`,fields:{enabled:{type:e.Boolean(),isOptional:!1},cron:{type:e.String_unsecure(),isOptional:!0},intervalMs:{type:e.Int_unsecure(),isOptional:!0}}}),a=new t({name:`KnowledgeSourceRecord`,fields:{id:{type:e.ID(),isOptional:!1},tenantId:{type:e.ID(),isOptional:!1},spaceKey:{type:e.NonEmptyString(),isOptional:!1},spaceVersion:{type:e.Int_unsecure(),isOptional:!1},label:{type:e.String_unsecure(),isOptional:!1},sourceType:{type:e.String_unsecure(),isOptional:!1},syncSchedule:{type:i,isOptional:!0},lastSyncStatus:{type:e.String_unsecure(),isOptional:!0},lastSyncAt:{type:e.DateTime(),isOptional:!0},itemsProcessed:{type:e.Int_unsecure(),isOptional:!0},createdAt:{type:e.DateTime(),isOptional:!0},updatedAt:{type:e.DateTime(),isOptional:!0}}}),o=new t({name:`CreateKnowledgeSourceInput`,fields:{tenantId:{type:e.ID(),isOptional:!1},spaceKey:{type:e.NonEmptyString(),isOptional:!1},spaceVersion:{type:e.Int_unsecure(),isOptional:!1},label:{type:e.String_unsecure(),isOptional:!1},sourceType:{type:e.NonEmptyString(),isOptional:!1},config:{type:e.JSONObject(),isOptional:!1},syncSchedule:{type:i,isOptional:!0}}}),s=new t({name:`UpdateKnowledgeSourceInput`,fields:{sourceId:{type:e.ID(),isOptional:!1},label:{type:e.String_unsecure(),isOptional:!0},config:{type:e.JSONObject(),isOptional:!0},syncSchedule:{type:i,isOptional:!0}}}),c=new t({name:`DeleteKnowledgeSourceInput`,fields:{sourceId:{type:e.ID(),isOptional:!1}}}),l=new t({name:`DeleteKnowledgeSourceOutput`,fields:{success:{type:e.Boolean(),isOptional:!1}}}),u=new t({name:`ListKnowledgeSourcesInput`,fields:{tenantId:{type:e.ID(),isOptional:!1},spaceKey:{type:e.NonEmptyString(),isOptional:!0}}}),d=new t({name:`ListKnowledgeSourcesOutput`,fields:{sources:{type:a,isOptional:!1,isArray:!0}}}),f=new t({name:`TriggerKnowledgeSyncInput`,fields:{sourceId:{type:e.ID(),isOptional:!1}}}),p=new t({name:`TriggerKnowledgeSyncOutput`,fields:{success:{type:e.Boolean(),isOptional:!1},itemsProcessed:{type:e.Int_unsecure(),isOptional:!0},error:{type:e.String_unsecure(),isOptional:!0}}}),m=n({meta:{name:`knowledge.source.create`,version:1,description:`Create a knowledge source binding for a tenant.`,goal:`Onboard a new knowledge ingestion source such as Notion or uploads.`,context:`Used by Ops and App Studio to configure knowledge ingestion per tenant and space.`,owners:[`platform.knowledge`],tags:[`knowledge`,`sources`],stability:`experimental`},io:{input:o,output:a},policy:{auth:`admin`,policies:[{name:`platform.knowledge.manage`,version:1}]}}),h=n({meta:{name:`knowledge.source.update`,version:1,description:`Update metadata or configuration for a knowledge source.`,goal:`Allow rotation of credentials, sync schedules, and labels.`,context:`Supports editing how a tenant ingests knowledge (e.g., toggling sync cadence).`,owners:[`platform.knowledge`],tags:[`knowledge`,`sources`],stability:`experimental`},io:{input:s,output:a},policy:{auth:`admin`,policies:[{name:`platform.knowledge.manage`,version:1}]}}),g=n({meta:{name:`knowledge.source.delete`,version:1,description:`Delete a knowledge source binding for a tenant.`,goal:`Remove obsolete or compromised knowledge ingestion paths.`,context:`Ensures ephemeral or external sources can be removed cleanly without leaving residual bindings.`,owners:[`platform.knowledge`],tags:[`knowledge`,`sources`],stability:`experimental`},io:{input:c,output:l},policy:{auth:`admin`,policies:[{name:`platform.knowledge.manage`,version:1}]}}),_=r({meta:{name:`knowledge.source.list`,version:1,description:`List knowledge sources configured for a tenant.`,goal:`Provide visibility into knowledge ingest configuration and schedules.`,context:`Used by App Studio and Ops flows to surface knowledge sources and their health.`,owners:[`platform.knowledge`],tags:[`knowledge`,`sources`],stability:`experimental`},io:{input:u,output:d},policy:{auth:`admin`,policies:[{name:`platform.knowledge.read`,version:1}]}}),v=n({meta:{name:`knowledge.source.triggerSync`,version:1,description:`Trigger an immediate sync for a knowledge source.`,goal:`Support manual or automated sync retries for knowledge ingestion.`,context:`Invoked by Ops tooling or monitors when knowledge content must be refreshed or reprocessed.`,owners:[`platform.knowledge`],tags:[`knowledge`,`sources`],stability:`experimental`},io:{input:f,output:p},policy:{auth:`admin`,policies:[{name:`platform.knowledge.manage`,version:1}]}}),y={CreateKnowledgeSource:m,UpdateKnowledgeSource:h,DeleteKnowledgeSource:g,ListKnowledgeSources:_,TriggerKnowledgeSourceSync:v};function b(e){return e.register(m).register(h).register(g).register(_).register(v)}export{m as CreateKnowledgeSource,g as DeleteKnowledgeSource,_ as ListKnowledgeSources,v as TriggerKnowledgeSourceSync,h as UpdateKnowledgeSource,y as knowledgeContracts,b as registerKnowledgeContracts};
2
2
  //# sourceMappingURL=contracts.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"contracts.js","names":["knowledgeContracts: Record<string, ContractSpec<any, any>>"],"sources":["../../src/knowledge/contracts.ts"],"sourcesContent":["import {\n ScalarTypeEnum,\n SchemaModel,\n} from '@lssm/lib.schema';\nimport {\n defineCommand,\n defineQuery,\n type ContractSpec,\n} from '../spec';\nimport type { SpecRegistry } from '../registry';\n\nconst KnowledgeSyncSchedule = new SchemaModel({\n name: 'KnowledgeSyncSchedule',\n fields: {\n enabled: { type: ScalarTypeEnum.Boolean(), isOptional: false },\n cron: { type: ScalarTypeEnum.String_unsecure(), isOptional: true },\n intervalMs: { type: ScalarTypeEnum.Int_unsecure(), isOptional: true },\n },\n});\n\nconst KnowledgeSourceRecord = new SchemaModel({\n name: 'KnowledgeSourceRecord',\n fields: {\n id: { type: ScalarTypeEnum.ID(), isOptional: false },\n tenantId: { type: ScalarTypeEnum.ID(), isOptional: false },\n spaceKey: { type: ScalarTypeEnum.NonEmptyString(), isOptional: false },\n spaceVersion: { type: ScalarTypeEnum.Int_unsecure(), isOptional: false },\n label: { type: ScalarTypeEnum.String_unsecure(), isOptional: false },\n sourceType: { type: ScalarTypeEnum.String_unsecure(), isOptional: false },\n syncSchedule: { type: KnowledgeSyncSchedule, isOptional: true },\n lastSyncStatus: { type: ScalarTypeEnum.String_unsecure(), isOptional: true },\n lastSyncAt: { type: ScalarTypeEnum.DateTime(), isOptional: true },\n itemsProcessed: { type: ScalarTypeEnum.Int_unsecure(), isOptional: true },\n createdAt: { type: ScalarTypeEnum.DateTime(), isOptional: true },\n updatedAt: { type: ScalarTypeEnum.DateTime(), isOptional: true },\n },\n});\n\nconst CreateKnowledgeSourceInput = new SchemaModel({\n name: 'CreateKnowledgeSourceInput',\n fields: {\n tenantId: { type: ScalarTypeEnum.ID(), isOptional: false },\n spaceKey: { type: ScalarTypeEnum.NonEmptyString(), isOptional: false },\n spaceVersion: { type: ScalarTypeEnum.Int_unsecure(), isOptional: false },\n label: { type: ScalarTypeEnum.String_unsecure(), isOptional: false },\n sourceType: { type: ScalarTypeEnum.NonEmptyString(), isOptional: false },\n config: { type: ScalarTypeEnum.JSONObject(), isOptional: false },\n syncSchedule: { type: KnowledgeSyncSchedule, isOptional: true },\n },\n});\n\nconst UpdateKnowledgeSourceInput = new SchemaModel({\n name: 'UpdateKnowledgeSourceInput',\n fields: {\n sourceId: { type: ScalarTypeEnum.ID(), isOptional: false },\n label: { type: ScalarTypeEnum.String_unsecure(), isOptional: true },\n config: { type: ScalarTypeEnum.JSONObject(), isOptional: true },\n syncSchedule: { type: KnowledgeSyncSchedule, isOptional: true },\n },\n});\n\nconst DeleteKnowledgeSourceInput = new SchemaModel({\n name: 'DeleteKnowledgeSourceInput',\n fields: {\n sourceId: { type: ScalarTypeEnum.ID(), isOptional: false },\n },\n});\n\nconst DeleteKnowledgeSourceOutput = new SchemaModel({\n name: 'DeleteKnowledgeSourceOutput',\n fields: {\n success: { type: ScalarTypeEnum.Boolean(), isOptional: false },\n },\n});\n\nconst ListKnowledgeSourcesInput = new SchemaModel({\n name: 'ListKnowledgeSourcesInput',\n fields: {\n tenantId: { type: ScalarTypeEnum.ID(), isOptional: false },\n spaceKey: { type: ScalarTypeEnum.NonEmptyString(), isOptional: true },\n },\n});\n\nconst ListKnowledgeSourcesOutput = new SchemaModel({\n name: 'ListKnowledgeSourcesOutput',\n fields: {\n sources: {\n type: KnowledgeSourceRecord,\n isOptional: false,\n isArray: true,\n },\n },\n});\n\nconst TriggerKnowledgeSyncInput = new SchemaModel({\n name: 'TriggerKnowledgeSyncInput',\n fields: {\n sourceId: { type: ScalarTypeEnum.ID(), isOptional: false },\n },\n});\n\nconst TriggerKnowledgeSyncOutput = new SchemaModel({\n name: 'TriggerKnowledgeSyncOutput',\n fields: {\n success: { type: ScalarTypeEnum.Boolean(), isOptional: false },\n itemsProcessed: { type: ScalarTypeEnum.Int_unsecure(), isOptional: true },\n error: { type: ScalarTypeEnum.String_unsecure(), isOptional: true },\n },\n});\n\nexport const CreateKnowledgeSource = defineCommand({\n meta: {\n name: 'knowledge.source.create',\n version: 1,\n description: 'Create a knowledge source binding for a tenant.',\n goal: 'Onboard a new knowledge ingestion source such as Notion or uploads.',\n context:\n 'Used by Ops and App Studio to configure knowledge ingestion per tenant and space.',\n owners: ['platform.knowledge'],\n tags: ['knowledge', 'sources'],\n stability: 'experimental',\n },\n io: {\n input: CreateKnowledgeSourceInput,\n output: KnowledgeSourceRecord,\n },\n policy: {\n auth: 'admin',\n policies: [{ name: 'platform.knowledge.manage', version: 1 }],\n },\n});\n\nexport const UpdateKnowledgeSource = defineCommand({\n meta: {\n name: 'knowledge.source.update',\n version: 1,\n description: 'Update metadata or configuration for a knowledge source.',\n goal: 'Allow rotation of credentials, sync schedules, and labels.',\n context:\n 'Supports editing how a tenant ingests knowledge (e.g., toggling sync cadence).',\n owners: ['platform.knowledge'],\n tags: ['knowledge', 'sources'],\n stability: 'experimental',\n },\n io: {\n input: UpdateKnowledgeSourceInput,\n output: KnowledgeSourceRecord,\n },\n policy: {\n auth: 'admin',\n policies: [{ name: 'platform.knowledge.manage', version: 1 }],\n },\n});\n\nexport const DeleteKnowledgeSource = defineCommand({\n meta: {\n name: 'knowledge.source.delete',\n version: 1,\n description: 'Delete a knowledge source binding for a tenant.',\n goal: 'Remove obsolete or compromised knowledge ingestion paths.',\n context:\n 'Ensures ephemeral or external sources can be removed cleanly without leaving residual bindings.',\n owners: ['platform.knowledge'],\n tags: ['knowledge', 'sources'],\n stability: 'experimental',\n },\n io: {\n input: DeleteKnowledgeSourceInput,\n output: DeleteKnowledgeSourceOutput,\n },\n policy: {\n auth: 'admin',\n policies: [{ name: 'platform.knowledge.manage', version: 1 }],\n },\n});\n\nexport const ListKnowledgeSources = defineQuery({\n meta: {\n name: 'knowledge.source.list',\n version: 1,\n description: 'List knowledge sources configured for a tenant.',\n goal: 'Provide visibility into knowledge ingest configuration and schedules.',\n context:\n 'Used by App Studio and Ops flows to surface knowledge sources and their health.',\n owners: ['platform.knowledge'],\n tags: ['knowledge', 'sources'],\n stability: 'experimental',\n },\n io: {\n input: ListKnowledgeSourcesInput,\n output: ListKnowledgeSourcesOutput,\n },\n policy: {\n auth: 'admin',\n policies: [{ name: 'platform.knowledge.read', version: 1 }],\n },\n});\n\nexport const TriggerKnowledgeSourceSync = defineCommand({\n meta: {\n name: 'knowledge.source.triggerSync',\n version: 1,\n description: 'Trigger an immediate sync for a knowledge source.',\n goal: 'Support manual or automated sync retries for knowledge ingestion.',\n context:\n 'Invoked by Ops tooling or monitors when knowledge content must be refreshed or reprocessed.',\n owners: ['platform.knowledge'],\n tags: ['knowledge', 'sources'],\n stability: 'experimental',\n },\n io: {\n input: TriggerKnowledgeSyncInput,\n output: TriggerKnowledgeSyncOutput,\n },\n policy: {\n auth: 'admin',\n policies: [{ name: 'platform.knowledge.manage', version: 1 }],\n },\n});\n\nexport const knowledgeContracts: Record<string, ContractSpec<any, any>> = {\n CreateKnowledgeSource,\n UpdateKnowledgeSource,\n DeleteKnowledgeSource,\n ListKnowledgeSources,\n TriggerKnowledgeSourceSync,\n};\n\nexport function registerKnowledgeContracts(registry: SpecRegistry) {\n return registry\n .register(CreateKnowledgeSource)\n .register(UpdateKnowledgeSource)\n .register(DeleteKnowledgeSource)\n .register(ListKnowledgeSources)\n .register(TriggerKnowledgeSourceSync);\n}\n\n\n\n"],"mappings":"uNAWA,MAAM,EAAwB,IAAI,EAAY,CAC5C,KAAM,wBACN,OAAQ,CACN,QAAS,CAAE,KAAM,EAAe,SAAS,CAAE,WAAY,GAAO,CAC9D,KAAM,CAAE,KAAM,EAAe,iBAAiB,CAAE,WAAY,GAAM,CAClE,WAAY,CAAE,KAAM,EAAe,cAAc,CAAE,WAAY,GAAM,CACtE,CACF,CAAC,CAEI,EAAwB,IAAI,EAAY,CAC5C,KAAM,wBACN,OAAQ,CACN,GAAI,CAAE,KAAM,EAAe,IAAI,CAAE,WAAY,GAAO,CACpD,SAAU,CAAE,KAAM,EAAe,IAAI,CAAE,WAAY,GAAO,CAC1D,SAAU,CAAE,KAAM,EAAe,gBAAgB,CAAE,WAAY,GAAO,CACtE,aAAc,CAAE,KAAM,EAAe,cAAc,CAAE,WAAY,GAAO,CACxE,MAAO,CAAE,KAAM,EAAe,iBAAiB,CAAE,WAAY,GAAO,CACpE,WAAY,CAAE,KAAM,EAAe,iBAAiB,CAAE,WAAY,GAAO,CACzE,aAAc,CAAE,KAAM,EAAuB,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AC,CAAE,KAAM,4BAA6B,QAAS,EAAG,CAAC,CAC9D,CACF,CAAC,CAEW,EAAwB,EAAc,CACjD,KAAM,CACJ,KAAM,0BACN,QAAS,EACT,YAAa,kDACb,KAAM,4DACN,QACE,kGACF,OAAQ,CAAC,qBAAqB,CAC9B,KAAM,CAAC,YAAa,UAAU,CAC9B,UAAW,eACZ,CACD,GAAI,CACF,MAAO,EACP,OAAQ,EACT,CACD,OAAQ,CACN,KAAM,QACN,SAAU,CAAC,CAAE,KAAM,4BAA6B,QAAS,EAAG,CAAC,CAC9D,CACF,CAAC,CAEW,EAAuB,EAAY,CAC9C,KAAM,CACJ,KAAM,wBACN,QAAS,EACT,YAAa,kDACb,KAAM,wEACN,QACE,kFACF,OAAQ,CAAC,qBAAqB,CAC9B,KAAM,CAAC,YAAa,UAAU,CAC9B,UAAW,eACZ,CACD,GAAI,CACF,MAAO,EACP,OAAQ,EACT,CACD,OAAQ,CACN,KAAM,QACN,SAAU,CAAC,CAAE,KAAM,0BAA2B,QAAS,EAAG,CAAC,CAC5D,CACF,CAAC,CAEW,EAA6B,EAAc,CACtD,KAAM,CACJ,KAAM,+BACN,QAAS,EACT,YAAa,oDACb,KAAM,oEACN,QACE,8FACF,OAAQ,CAAC,qBAAqB,CAC9B,KAAM,CAAC,YAAa,UAAU,CAC9B,UAAW,eACZ,CACD,GAAI,CACF,MAAO,EACP,OAAQ,EACT,CACD,OAAQ,CACN,KAAM,QACN,SAAU,CAAC,CAAE,KAAM,4BAA6B,QAAS,EAAG,CAAC,CAC9D,CACF,CAAC,CAEWA,EAA6D,CACxE,wBACA,wBACA,wBACA,uBACA,6BACD,CAED,SAAgB,EAA2B,EAAwB,CACjE,OAAO,EACJ,SAAS,EAAsB,CAC/B,SAAS,EAAsB,CAC/B,SAAS,EAAsB,CAC/B,SAAS,EAAqB,CAC9B,SAAS,EAA2B"}
1
+ {"version":3,"file":"contracts.js","names":["SchemaModel","ScalarTypeEnum","knowledgeContracts: Record<string, ContractSpec<any, any>>"],"sources":["../../src/knowledge/contracts.ts"],"sourcesContent":["import {\n ScalarTypeEnum,\n SchemaModel,\n} from '@lssm/lib.schema';\nimport {\n defineCommand,\n defineQuery,\n type ContractSpec,\n} from '../spec';\nimport type { SpecRegistry } from '../registry';\n\nconst KnowledgeSyncSchedule = new SchemaModel({\n name: 'KnowledgeSyncSchedule',\n fields: {\n enabled: { type: ScalarTypeEnum.Boolean(), isOptional: false },\n cron: { type: ScalarTypeEnum.String_unsecure(), isOptional: true },\n intervalMs: { type: ScalarTypeEnum.Int_unsecure(), isOptional: true },\n },\n});\n\nconst KnowledgeSourceRecord = new SchemaModel({\n name: 'KnowledgeSourceRecord',\n fields: {\n id: { type: ScalarTypeEnum.ID(), isOptional: false },\n tenantId: { type: ScalarTypeEnum.ID(), isOptional: false },\n spaceKey: { type: ScalarTypeEnum.NonEmptyString(), isOptional: false },\n spaceVersion: { type: ScalarTypeEnum.Int_unsecure(), isOptional: false },\n label: { type: ScalarTypeEnum.String_unsecure(), isOptional: false },\n sourceType: { type: ScalarTypeEnum.String_unsecure(), isOptional: false },\n syncSchedule: { type: KnowledgeSyncSchedule, isOptional: true },\n lastSyncStatus: { type: ScalarTypeEnum.String_unsecure(), isOptional: true },\n lastSyncAt: { type: ScalarTypeEnum.DateTime(), isOptional: true },\n itemsProcessed: { type: ScalarTypeEnum.Int_unsecure(), isOptional: true },\n createdAt: { type: ScalarTypeEnum.DateTime(), isOptional: true },\n updatedAt: { type: ScalarTypeEnum.DateTime(), isOptional: true },\n },\n});\n\nconst CreateKnowledgeSourceInput = new SchemaModel({\n name: 'CreateKnowledgeSourceInput',\n fields: {\n tenantId: { type: ScalarTypeEnum.ID(), isOptional: false },\n spaceKey: { type: ScalarTypeEnum.NonEmptyString(), isOptional: false },\n spaceVersion: { type: ScalarTypeEnum.Int_unsecure(), isOptional: false },\n label: { type: ScalarTypeEnum.String_unsecure(), isOptional: false },\n sourceType: { type: ScalarTypeEnum.NonEmptyString(), isOptional: false },\n config: { type: ScalarTypeEnum.JSONObject(), isOptional: false },\n syncSchedule: { type: KnowledgeSyncSchedule, isOptional: true },\n },\n});\n\nconst UpdateKnowledgeSourceInput = new SchemaModel({\n name: 'UpdateKnowledgeSourceInput',\n fields: {\n sourceId: { type: ScalarTypeEnum.ID(), isOptional: false },\n label: { type: ScalarTypeEnum.String_unsecure(), isOptional: true },\n config: { type: ScalarTypeEnum.JSONObject(), isOptional: true },\n syncSchedule: { type: KnowledgeSyncSchedule, isOptional: true },\n },\n});\n\nconst DeleteKnowledgeSourceInput = new SchemaModel({\n name: 'DeleteKnowledgeSourceInput',\n fields: {\n sourceId: { type: ScalarTypeEnum.ID(), isOptional: false },\n },\n});\n\nconst DeleteKnowledgeSourceOutput = new SchemaModel({\n name: 'DeleteKnowledgeSourceOutput',\n fields: {\n success: { type: ScalarTypeEnum.Boolean(), isOptional: false },\n },\n});\n\nconst ListKnowledgeSourcesInput = new SchemaModel({\n name: 'ListKnowledgeSourcesInput',\n fields: {\n tenantId: { type: ScalarTypeEnum.ID(), isOptional: false },\n spaceKey: { type: ScalarTypeEnum.NonEmptyString(), isOptional: true },\n },\n});\n\nconst ListKnowledgeSourcesOutput = new SchemaModel({\n name: 'ListKnowledgeSourcesOutput',\n fields: {\n sources: {\n type: KnowledgeSourceRecord,\n isOptional: false,\n isArray: true,\n },\n },\n});\n\nconst TriggerKnowledgeSyncInput = new SchemaModel({\n name: 'TriggerKnowledgeSyncInput',\n fields: {\n sourceId: { type: ScalarTypeEnum.ID(), isOptional: false },\n },\n});\n\nconst TriggerKnowledgeSyncOutput = new SchemaModel({\n name: 'TriggerKnowledgeSyncOutput',\n fields: {\n success: { type: ScalarTypeEnum.Boolean(), isOptional: false },\n itemsProcessed: { type: ScalarTypeEnum.Int_unsecure(), isOptional: true },\n error: { type: ScalarTypeEnum.String_unsecure(), isOptional: true },\n },\n});\n\nexport const CreateKnowledgeSource = defineCommand({\n meta: {\n name: 'knowledge.source.create',\n version: 1,\n description: 'Create a knowledge source binding for a tenant.',\n goal: 'Onboard a new knowledge ingestion source such as Notion or uploads.',\n context:\n 'Used by Ops and App Studio to configure knowledge ingestion per tenant and space.',\n owners: ['platform.knowledge'],\n tags: ['knowledge', 'sources'],\n stability: 'experimental',\n },\n io: {\n input: CreateKnowledgeSourceInput,\n output: KnowledgeSourceRecord,\n },\n policy: {\n auth: 'admin',\n policies: [{ name: 'platform.knowledge.manage', version: 1 }],\n },\n});\n\nexport const UpdateKnowledgeSource = defineCommand({\n meta: {\n name: 'knowledge.source.update',\n version: 1,\n description: 'Update metadata or configuration for a knowledge source.',\n goal: 'Allow rotation of credentials, sync schedules, and labels.',\n context:\n 'Supports editing how a tenant ingests knowledge (e.g., toggling sync cadence).',\n owners: ['platform.knowledge'],\n tags: ['knowledge', 'sources'],\n stability: 'experimental',\n },\n io: {\n input: UpdateKnowledgeSourceInput,\n output: KnowledgeSourceRecord,\n },\n policy: {\n auth: 'admin',\n policies: [{ name: 'platform.knowledge.manage', version: 1 }],\n },\n});\n\nexport const DeleteKnowledgeSource = defineCommand({\n meta: {\n name: 'knowledge.source.delete',\n version: 1,\n description: 'Delete a knowledge source binding for a tenant.',\n goal: 'Remove obsolete or compromised knowledge ingestion paths.',\n context:\n 'Ensures ephemeral or external sources can be removed cleanly without leaving residual bindings.',\n owners: ['platform.knowledge'],\n tags: ['knowledge', 'sources'],\n stability: 'experimental',\n },\n io: {\n input: DeleteKnowledgeSourceInput,\n output: DeleteKnowledgeSourceOutput,\n },\n policy: {\n auth: 'admin',\n policies: [{ name: 'platform.knowledge.manage', version: 1 }],\n },\n});\n\nexport const ListKnowledgeSources = defineQuery({\n meta: {\n name: 'knowledge.source.list',\n version: 1,\n description: 'List knowledge sources configured for a tenant.',\n goal: 'Provide visibility into knowledge ingest configuration and schedules.',\n context:\n 'Used by App Studio and Ops flows to surface knowledge sources and their health.',\n owners: ['platform.knowledge'],\n tags: ['knowledge', 'sources'],\n stability: 'experimental',\n },\n io: {\n input: ListKnowledgeSourcesInput,\n output: ListKnowledgeSourcesOutput,\n },\n policy: {\n auth: 'admin',\n policies: [{ name: 'platform.knowledge.read', version: 1 }],\n },\n});\n\nexport const TriggerKnowledgeSourceSync = defineCommand({\n meta: {\n name: 'knowledge.source.triggerSync',\n version: 1,\n description: 'Trigger an immediate sync for a knowledge source.',\n goal: 'Support manual or automated sync retries for knowledge ingestion.',\n context:\n 'Invoked by Ops tooling or monitors when knowledge content must be refreshed or reprocessed.',\n owners: ['platform.knowledge'],\n tags: ['knowledge', 'sources'],\n stability: 'experimental',\n },\n io: {\n input: TriggerKnowledgeSyncInput,\n output: TriggerKnowledgeSyncOutput,\n },\n policy: {\n auth: 'admin',\n policies: [{ name: 'platform.knowledge.manage', version: 1 }],\n },\n});\n\nexport const knowledgeContracts: Record<string, ContractSpec<any, any>> = {\n CreateKnowledgeSource,\n UpdateKnowledgeSource,\n DeleteKnowledgeSource,\n ListKnowledgeSources,\n TriggerKnowledgeSourceSync,\n};\n\nexport function registerKnowledgeContracts(registry: SpecRegistry) {\n return registry\n .register(CreateKnowledgeSource)\n .register(UpdateKnowledgeSource)\n .register(DeleteKnowledgeSource)\n .register(ListKnowledgeSources)\n .register(TriggerKnowledgeSourceSync);\n}\n\n\n\n\n"],"mappings":"8LAWA,MAAM,EAAwB,IAAIA,EAAY,CAC5C,KAAM,wBACN,OAAQ,CACN,QAAS,CAAE,KAAMC,EAAe,SAAS,CAAE,WAAY,GAAO,CAC9D,KAAM,CAAE,KAAMA,EAAe,iBAAiB,CAAE,WAAY,GAAM,CAClE,WAAY,CAAE,KAAMA,EAAe,cAAc,CAAE,WAAY,GAAM,CACtE,CACF,CAAC,CAEI,EAAwB,IAAID,EAAY,CAC5C,KAAM,wBACN,OAAQ,CACN,GAAI,CAAE,KAAMC,EAAe,IAAI,CAAE,WAAY,GAAO,CACpD,SAAU,CAAE,KAAMA,EAAe,IAAI,CAAE,WAAY,GAAO,CAC1D,SAAU,CAAE,KAAMA,EAAe,gBAAgB,CAAE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BACA,wBACA,wBACA,uBACA,6BACD,CAED,SAAgB,EAA2B,EAAwB,CACjE,OAAO,EACJ,SAAS,EAAsB,CAC/B,SAAS,EAAsB,CAC/B,SAAS,EAAsB,CAC/B,SAAS,EAAqB,CAC9B,SAAS,EAA2B"}
@@ -1 +1 @@
1
- {"version":3,"file":"product-canon.js","names":["productCanonKnowledgeSpace: KnowledgeSpaceSpec"],"sources":["../../../src/knowledge/spaces/product-canon.ts"],"sourcesContent":["import { StabilityEnum } from '../../ownership';\nimport type { KnowledgeSpaceRegistry, KnowledgeSpaceSpec } from '../spec';\n\nexport const productCanonKnowledgeSpace: KnowledgeSpaceSpec = {\n meta: {\n key: 'knowledge.product-canon',\n version: 1,\n category: 'canonical',\n displayName: 'Product Canon',\n title: 'Product Canon Knowledge Space',\n description:\n 'Authoritative product knowledge covering strategy, roadmap, and delivery canon.',\n domain: 'product',\n owners: ['platform.product'],\n tags: ['knowledge', 'product'],\n stability: StabilityEnum.Stable,\n },\n retention: {\n ttlDays: null,\n },\n access: {\n policy: { name: 'knowledge.access.product-canon', version: 1 },\n trustLevel: 'high',\n automationWritable: false,\n },\n indexing: {\n embeddingModel: 'text-embedding-3-large',\n chunkSize: 800,\n vectorDbIntegration: 'vectordb.qdrant',\n },\n description:\n 'Single source of truth for product canon, principles, and strategic narratives.',\n};\n\nexport function registerProductCanonKnowledgeSpace(\n registry: KnowledgeSpaceRegistry\n): KnowledgeSpaceRegistry {\n return registry.register(productCanonKnowledgeSpace);\n}\n\n\n\n"],"mappings":"mDAGA,MAAaA,EAAiD,CAC5D,KAAM,CACJ,IAAK,0BACL,QAAS,EACT,SAAU,YACV,YAAa,gBACb,MAAO,gCACP,YACE,kFACF,OAAQ,UACR,OAAQ,CAAC,mBAAmB,CAC5B,KAAM,CAAC,YAAa,UAAU,CAC9B,UAAW,EAAc,OAC1B,CACD,UAAW,CACT,QAAS,KACV,CACD,OAAQ,CACN,OAAQ,CAAE,KAAM,iCAAkC,QAAS,EAAG,CAC9D,WAAY,OACZ,mBAAoB,GACrB,CACD,SAAU,CACR,eAAgB,yBAChB,UAAW,IACX,oBAAqB,kBACtB,CACD,YACE,kFACH,CAED,SAAgB,EACd,EACwB,CACxB,OAAO,EAAS,SAAS,EAA2B"}
1
+ {"version":3,"file":"product-canon.js","names":["productCanonKnowledgeSpace: KnowledgeSpaceSpec"],"sources":["../../../src/knowledge/spaces/product-canon.ts"],"sourcesContent":["import { StabilityEnum } from '../../ownership';\nimport type { KnowledgeSpaceRegistry, KnowledgeSpaceSpec } from '../spec';\n\nexport const productCanonKnowledgeSpace: KnowledgeSpaceSpec = {\n meta: {\n key: 'knowledge.product-canon',\n version: 1,\n category: 'canonical',\n displayName: 'Product Canon',\n title: 'Product Canon Knowledge Space',\n description:\n 'Authoritative product knowledge covering strategy, roadmap, and delivery canon.',\n domain: 'product',\n owners: ['platform.product'],\n tags: ['knowledge', 'product'],\n stability: StabilityEnum.Stable,\n },\n retention: {\n ttlDays: null,\n },\n access: {\n policy: { name: 'knowledge.access.product-canon', version: 1 },\n trustLevel: 'high',\n automationWritable: false,\n },\n indexing: {\n embeddingModel: 'text-embedding-3-large',\n chunkSize: 800,\n vectorDbIntegration: 'vectordb.qdrant',\n },\n description:\n 'Single source of truth for product canon, principles, and strategic narratives.',\n};\n\nexport function registerProductCanonKnowledgeSpace(\n registry: KnowledgeSpaceRegistry\n): KnowledgeSpaceRegistry {\n return registry.register(productCanonKnowledgeSpace);\n}\n\n\n\n\n"],"mappings":"mDAGA,MAAaA,EAAiD,CAC5D,KAAM,CACJ,IAAK,0BACL,QAAS,EACT,SAAU,YACV,YAAa,gBACb,MAAO,gCACP,YACE,kFACF,OAAQ,UACR,OAAQ,CAAC,mBAAmB,CAC5B,KAAM,CAAC,YAAa,UAAU,CAC9B,UAAW,EAAc,OAC1B,CACD,UAAW,CACT,QAAS,KACV,CACD,OAAQ,CACN,OAAQ,CAAE,KAAM,iCAAkC,QAAS,EAAG,CAC9D,WAAY,OACZ,mBAAoB,GACrB,CACD,SAAU,CACR,eAAgB,yBAChB,UAAW,IACX,oBAAqB,kBACtB,CACD,YACE,kFACH,CAED,SAAgB,EACd,EACwB,CACxB,OAAO,EAAS,SAAS,EAA2B"}
@@ -1 +1 @@
1
- {"version":3,"file":"support-faq.js","names":["supportFaqKnowledgeSpace: KnowledgeSpaceSpec"],"sources":["../../../src/knowledge/spaces/support-faq.ts"],"sourcesContent":["import { StabilityEnum } from '../../ownership';\nimport type { KnowledgeSpaceRegistry, KnowledgeSpaceSpec } from '../spec';\n\nexport const supportFaqKnowledgeSpace: KnowledgeSpaceSpec = {\n meta: {\n key: 'knowledge.support-faq',\n version: 1,\n category: 'operational',\n displayName: 'Support FAQ',\n title: 'Support & Success FAQ',\n description: 'Operational knowledge base for customer support and success.',\n domain: 'support',\n owners: ['platform.support'],\n tags: ['knowledge', 'support'],\n stability: StabilityEnum.Beta,\n },\n retention: {\n ttlDays: 365,\n archiveAfterDays: 180,\n },\n access: {\n policy: { name: 'knowledge.access.support', version: 1 },\n trustLevel: 'medium',\n automationWritable: true,\n },\n indexing: {\n embeddingModel: 'text-embedding-3-small',\n chunkSize: 700,\n vectorDbIntegration: 'vectordb.qdrant',\n },\n description:\n 'Operational FAQs, runbooks, and customer success playbooks augmented with automation updates.',\n};\n\nexport function registerSupportFaqKnowledgeSpace(\n registry: KnowledgeSpaceRegistry\n): KnowledgeSpaceRegistry {\n return registry.register(supportFaqKnowledgeSpace);\n}\n\n\n\n"],"mappings":"mDAGA,MAAaA,EAA+C,CAC1D,KAAM,CACJ,IAAK,wBACL,QAAS,EACT,SAAU,cACV,YAAa,cACb,MAAO,wBACP,YAAa,+DACb,OAAQ,UACR,OAAQ,CAAC,mBAAmB,CAC5B,KAAM,CAAC,YAAa,UAAU,CAC9B,UAAW,EAAc,KAC1B,CACD,UAAW,CACT,QAAS,IACT,iBAAkB,IACnB,CACD,OAAQ,CACN,OAAQ,CAAE,KAAM,2BAA4B,QAAS,EAAG,CACxD,WAAY,SACZ,mBAAoB,GACrB,CACD,SAAU,CACR,eAAgB,yBAChB,UAAW,IACX,oBAAqB,kBACtB,CACD,YACE,gGACH,CAED,SAAgB,EACd,EACwB,CACxB,OAAO,EAAS,SAAS,EAAyB"}
1
+ {"version":3,"file":"support-faq.js","names":["supportFaqKnowledgeSpace: KnowledgeSpaceSpec"],"sources":["../../../src/knowledge/spaces/support-faq.ts"],"sourcesContent":["import { StabilityEnum } from '../../ownership';\nimport type { KnowledgeSpaceRegistry, KnowledgeSpaceSpec } from '../spec';\n\nexport const supportFaqKnowledgeSpace: KnowledgeSpaceSpec = {\n meta: {\n key: 'knowledge.support-faq',\n version: 1,\n category: 'operational',\n displayName: 'Support FAQ',\n title: 'Support & Success FAQ',\n description: 'Operational knowledge base for customer support and success.',\n domain: 'support',\n owners: ['platform.support'],\n tags: ['knowledge', 'support'],\n stability: StabilityEnum.Beta,\n },\n retention: {\n ttlDays: 365,\n archiveAfterDays: 180,\n },\n access: {\n policy: { name: 'knowledge.access.support', version: 1 },\n trustLevel: 'medium',\n automationWritable: true,\n },\n indexing: {\n embeddingModel: 'text-embedding-3-small',\n chunkSize: 700,\n vectorDbIntegration: 'vectordb.qdrant',\n },\n description:\n 'Operational FAQs, runbooks, and customer success playbooks augmented with automation updates.',\n};\n\nexport function registerSupportFaqKnowledgeSpace(\n registry: KnowledgeSpaceRegistry\n): KnowledgeSpaceRegistry {\n return registry.register(supportFaqKnowledgeSpace);\n}\n\n\n\n\n"],"mappings":"mDAGA,MAAaA,EAA+C,CAC1D,KAAM,CACJ,IAAK,wBACL,QAAS,EACT,SAAU,cACV,YAAa,cACb,MAAO,wBACP,YAAa,+DACb,OAAQ,UACR,OAAQ,CAAC,mBAAmB,CAC5B,KAAM,CAAC,YAAa,UAAU,CAC9B,UAAW,EAAc,KAC1B,CACD,UAAW,CACT,QAAS,IACT,iBAAkB,IACnB,CACD,OAAQ,CACN,OAAQ,CAAE,KAAM,2BAA4B,QAAS,EAAG,CACxD,WAAY,SACZ,mBAAoB,GACrB,CACD,SAAU,CACR,eAAgB,yBAChB,UAAW,IACX,oBAAqB,kBACtB,CACD,YACE,gGACH,CAED,SAAgB,EACd,EACwB,CACxB,OAAO,EAAS,SAAS,EAAyB"}
@@ -1 +1 @@
1
- {"version":3,"file":"spec.js","names":["latest: KnowledgeSpaceSpec | undefined"],"sources":["../../src/knowledge/spec.ts"],"sourcesContent":["import type { OwnerShipMeta } from '../ownership';\nimport type { PolicyRef } from '../policy/spec';\n\nexport type KnowledgeCategory =\n | 'canonical'\n | 'operational'\n | 'external'\n | 'ephemeral';\n\nexport interface KnowledgeSpaceMeta extends OwnerShipMeta {\n /** Stable space identifier (e.g., \"product-canon\", \"support-faq\"). */\n key: string;\n version: number;\n category: KnowledgeCategory;\n displayName: string;\n}\n\nexport interface KnowledgeRetentionPolicy {\n /** TTL in days (null = indefinite). */\n ttlDays?: number | null;\n /** Auto-archive after inactivity. */\n archiveAfterDays?: number;\n}\n\nexport interface KnowledgeAccessPolicy {\n /** Which PolicySpec governs access. */\n policy?: PolicyRef;\n /** Trust level for agent/workflow consumption. */\n trustLevel: 'high' | 'medium' | 'low';\n /** Can this space be mutated by automation? */\n automationWritable: boolean;\n}\n\nexport interface KnowledgeIndexingConfig {\n embeddingModel?: string;\n chunkSize?: number;\n vectorDbIntegration?: string;\n}\n\nexport interface KnowledgeSpaceSpec {\n meta: KnowledgeSpaceMeta;\n /** Retention and cleanup rules. */\n retention: KnowledgeRetentionPolicy;\n /** Access control and trust. */\n access: KnowledgeAccessPolicy;\n /** Optional embedding/indexing config. */\n indexing?: KnowledgeIndexingConfig;\n /** Documentation. */\n description?: string;\n}\n\nconst knowledgeKey = (meta: Pick<KnowledgeSpaceMeta, 'key' | 'version'>) =>\n `${meta.key}.v${meta.version}`;\n\nexport class KnowledgeSpaceRegistry {\n private readonly items = new Map<string, KnowledgeSpaceSpec>();\n\n register(spec: KnowledgeSpaceSpec): this {\n const key = knowledgeKey(spec.meta);\n if (this.items.has(key)) {\n throw new Error(`Duplicate KnowledgeSpaceSpec ${key}`);\n }\n this.items.set(key, spec);\n return this;\n }\n\n list(): KnowledgeSpaceSpec[] {\n return [...this.items.values()];\n }\n\n get(key: string, version?: number): KnowledgeSpaceSpec | undefined {\n if (version != null) {\n return this.items.get(knowledgeKey({ key, version }));\n }\n let latest: KnowledgeSpaceSpec | undefined;\n let maxVersion = -Infinity;\n for (const spec of this.items.values()) {\n if (spec.meta.key !== key) continue;\n if (spec.meta.version > maxVersion) {\n maxVersion = spec.meta.version;\n latest = spec;\n }\n }\n return latest;\n }\n\n getByCategory(category: KnowledgeCategory): KnowledgeSpaceSpec[] {\n return this.list().filter((spec) => spec.meta.category === category);\n }\n}\n\nexport function makeKnowledgeSpaceKey(meta: KnowledgeSpaceMeta) {\n return knowledgeKey(meta);\n}\n\n\n\n"],"mappings":"AAmDA,MAAM,EAAgB,GACpB,GAAG,EAAK,IAAI,IAAI,EAAK,UAEvB,IAAa,EAAb,KAAoC,CAClC,MAAyB,IAAI,IAE7B,SAAS,EAAgC,CACvC,IAAM,EAAM,EAAa,EAAK,KAAK,CACnC,GAAI,KAAK,MAAM,IAAI,EAAI,CACrB,MAAU,MAAM,gCAAgC,IAAM,CAGxD,OADA,KAAK,MAAM,IAAI,EAAK,EAAK,CAClB,KAGT,MAA6B,CAC3B,MAAO,CAAC,GAAG,KAAK,MAAM,QAAQ,CAAC,CAGjC,IAAI,EAAa,EAAkD,CACjE,GAAI,GAAW,KACb,OAAO,KAAK,MAAM,IAAI,EAAa,CAAE,MAAK,UAAS,CAAC,CAAC,CAEvD,IAAIA,EACA,EAAa,KACjB,IAAK,IAAM,KAAQ,KAAK,MAAM,QAAQ,CAChC,EAAK,KAAK,MAAQ,GAClB,EAAK,KAAK,QAAU,IACtB,EAAa,EAAK,KAAK,QACvB,EAAS,GAGb,OAAO,EAGT,cAAc,EAAmD,CAC/D,OAAO,KAAK,MAAM,CAAC,OAAQ,GAAS,EAAK,KAAK,WAAa,EAAS,GAIxE,SAAgB,EAAsB,EAA0B,CAC9D,OAAO,EAAa,EAAK"}
1
+ {"version":3,"file":"spec.js","names":["latest: KnowledgeSpaceSpec | undefined"],"sources":["../../src/knowledge/spec.ts"],"sourcesContent":["import type { OwnerShipMeta } from '../ownership';\nimport type { PolicyRef } from '../policy/spec';\n\nexport type KnowledgeCategory =\n | 'canonical'\n | 'operational'\n | 'external'\n | 'ephemeral';\n\nexport interface KnowledgeSpaceMeta extends OwnerShipMeta {\n /** Stable space identifier (e.g., \"product-canon\", \"support-faq\"). */\n key: string;\n version: number;\n category: KnowledgeCategory;\n displayName: string;\n}\n\nexport interface KnowledgeRetentionPolicy {\n /** TTL in days (null = indefinite). */\n ttlDays?: number | null;\n /** Auto-archive after inactivity. */\n archiveAfterDays?: number;\n}\n\nexport interface KnowledgeAccessPolicy {\n /** Which PolicySpec governs access. */\n policy?: PolicyRef;\n /** Trust level for agent/workflow consumption. */\n trustLevel: 'high' | 'medium' | 'low';\n /** Can this space be mutated by automation? */\n automationWritable: boolean;\n}\n\nexport interface KnowledgeIndexingConfig {\n embeddingModel?: string;\n chunkSize?: number;\n vectorDbIntegration?: string;\n}\n\nexport interface KnowledgeSpaceSpec {\n meta: KnowledgeSpaceMeta;\n /** Retention and cleanup rules. */\n retention: KnowledgeRetentionPolicy;\n /** Access control and trust. */\n access: KnowledgeAccessPolicy;\n /** Optional embedding/indexing config. */\n indexing?: KnowledgeIndexingConfig;\n /** Documentation. */\n description?: string;\n}\n\nconst knowledgeKey = (meta: Pick<KnowledgeSpaceMeta, 'key' | 'version'>) =>\n `${meta.key}.v${meta.version}`;\n\nexport class KnowledgeSpaceRegistry {\n private readonly items = new Map<string, KnowledgeSpaceSpec>();\n\n register(spec: KnowledgeSpaceSpec): this {\n const key = knowledgeKey(spec.meta);\n if (this.items.has(key)) {\n throw new Error(`Duplicate KnowledgeSpaceSpec ${key}`);\n }\n this.items.set(key, spec);\n return this;\n }\n\n list(): KnowledgeSpaceSpec[] {\n return [...this.items.values()];\n }\n\n get(key: string, version?: number): KnowledgeSpaceSpec | undefined {\n if (version != null) {\n return this.items.get(knowledgeKey({ key, version }));\n }\n let latest: KnowledgeSpaceSpec | undefined;\n let maxVersion = -Infinity;\n for (const spec of this.items.values()) {\n if (spec.meta.key !== key) continue;\n if (spec.meta.version > maxVersion) {\n maxVersion = spec.meta.version;\n latest = spec;\n }\n }\n return latest;\n }\n\n getByCategory(category: KnowledgeCategory): KnowledgeSpaceSpec[] {\n return this.list().filter((spec) => spec.meta.category === category);\n }\n}\n\nexport function makeKnowledgeSpaceKey(meta: KnowledgeSpaceMeta) {\n return knowledgeKey(meta);\n}\n\n\n\n\n"],"mappings":"AAmDA,MAAM,EAAgB,GACpB,GAAG,EAAK,IAAI,IAAI,EAAK,UAEvB,IAAa,EAAb,KAAoC,CAClC,MAAyB,IAAI,IAE7B,SAAS,EAAgC,CACvC,IAAM,EAAM,EAAa,EAAK,KAAK,CACnC,GAAI,KAAK,MAAM,IAAI,EAAI,CACrB,MAAU,MAAM,gCAAgC,IAAM,CAGxD,OADA,KAAK,MAAM,IAAI,EAAK,EAAK,CAClB,KAGT,MAA6B,CAC3B,MAAO,CAAC,GAAG,KAAK,MAAM,QAAQ,CAAC,CAGjC,IAAI,EAAa,EAAkD,CACjE,GAAI,GAAW,KACb,OAAO,KAAK,MAAM,IAAI,EAAa,CAAE,MAAK,UAAS,CAAC,CAAC,CAEvD,IAAIA,EACA,EAAa,KACjB,IAAK,IAAM,KAAQ,KAAK,MAAM,QAAQ,CAChC,EAAK,KAAK,MAAQ,GAClB,EAAK,KAAK,QAAU,IACtB,EAAa,EAAK,KAAK,QACvB,EAAS,GAGb,OAAO,EAGT,cAAc,EAAmD,CAC/D,OAAO,KAAK,MAAM,CAAC,OAAQ,GAAS,EAAK,KAAK,WAAa,EAAS,GAIxE,SAAgB,EAAsB,EAA0B,CAC9D,OAAO,EAAa,EAAK"}