@x12i/memorix-metadata 3.2.1 → 3.2.3

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 (38) hide show
  1. package/README.md +86 -86
  2. package/dist/index.d.ts +1 -0
  3. package/dist/index.d.ts.map +1 -1
  4. package/dist/index.js +1 -0
  5. package/dist/index.js.map +1 -1
  6. package/dist/platform-interfaces.d.ts +29 -0
  7. package/dist/platform-interfaces.d.ts.map +1 -0
  8. package/dist/platform-interfaces.js +53 -0
  9. package/dist/platform-interfaces.js.map +1 -0
  10. package/dist/resolve.d.ts.map +1 -1
  11. package/dist/resolve.js +111 -0
  12. package/dist/resolve.js.map +1 -1
  13. package/dist/types.d.ts +47 -0
  14. package/dist/types.d.ts.map +1 -1
  15. package/dist/validate.d.ts.map +1 -1
  16. package/dist/validate.js +19 -0
  17. package/dist/validate.js.map +1 -1
  18. package/examples/custom-kinds/acme-ui-tabs.pack.json +62 -62
  19. package/examples/invalid/agent-classification.json +709 -709
  20. package/examples/invalid/broken-binding.json +688 -688
  21. package/examples/invalid/completion-mapping-with-exec-policy.json +659 -659
  22. package/examples/invalid/missing-parent.json +708 -708
  23. package/examples/invalid/operational-kind-root.json +720 -720
  24. package/examples/invalid/pipeline-unknown-service.json +611 -611
  25. package/examples/invalid/relationship-missing-rules.json +624 -624
  26. package/examples/invalid/relationship-with-storage.json +631 -631
  27. package/examples/invalid/service-with-secrets.json +679 -679
  28. package/examples/knowx/normalized/pack.json +47 -146
  29. package/examples/opx/normalized/pack.json +4 -116
  30. package/examples/opx/raw/abstract-types.json +244 -244
  31. package/examples/opx/raw/agents.json +33 -33
  32. package/examples/opx/raw/object-types.json +101 -101
  33. package/examples/opx/raw/pipelines-and-sources.json +264 -264
  34. package/examples/opx/raw/relationship-definitions.json +80 -80
  35. package/examples/opx/raw/view-definitions.json +32 -32
  36. package/examples/opx/raw/write-and-source-mappings.json +223 -223
  37. package/examples/project-opx/normalized/pack.json +1036 -1036
  38. package/package.json +48 -48
@@ -1,659 +1,659 @@
1
- {
2
- "format": "memorix-metadata/1",
3
- "agentId": "opx",
4
- "version": "0.1.0",
5
- "agents": [
6
- {
7
- "id": "opx",
8
- "name": "Operations (generic parent)",
9
- "description": "Complete generic parent agent for ordinary operational work. Permanent Memorix acceptance pack.",
10
- "parentId": null
11
- },
12
- {
13
- "id": "project-opx",
14
- "name": "Project Operations (child of opx)",
15
- "description": "Inheritance smoke agent. Extends opx without replacing core definitions.",
16
- "parentId": "opx"
17
- }
18
- ],
19
- "objectTypes": [
20
- {
21
- "id": "employees",
22
- "name": "Employees",
23
- "dataCategory": "entity",
24
- "abstractTypes": [
25
- "People"
26
- ],
27
- "contentTypes": [
28
- {
29
- "id": "raw",
30
- "required": true
31
- },
32
- {
33
- "id": "snapshots",
34
- "required": true
35
- },
36
- {
37
- "id": "discovery",
38
- "discriminator": {
39
- "path": "data.discoveryType",
40
- "required": false,
41
- "defaultValue": "default"
42
- }
43
- },
44
- {
45
- "id": "analysis",
46
- "discriminator": {
47
- "path": "data.analysisType",
48
- "required": false,
49
- "defaultValue": "default"
50
- }
51
- },
52
- {
53
- "id": "relationships",
54
- "notes": "Candidate store shape until Gate G4"
55
- }
56
- ]
57
- },
58
- {
59
- "id": "contractors",
60
- "name": "Contractors",
61
- "dataCategory": "entity",
62
- "abstractTypes": [
63
- "People"
64
- ],
65
- "contentTypes": [
66
- {
67
- "id": "raw"
68
- },
69
- {
70
- "id": "snapshots"
71
- },
72
- {
73
- "id": "discovery",
74
- "discriminator": {
75
- "path": "data.discoveryType",
76
- "required": false
77
- }
78
- },
79
- {
80
- "id": "analysis",
81
- "discriminator": {
82
- "path": "data.analysisType",
83
- "required": false
84
- }
85
- },
86
- {
87
- "id": "relationships"
88
- }
89
- ]
90
- },
91
- {
92
- "id": "work-items",
93
- "name": "Work Items",
94
- "dataCategory": "entity",
95
- "abstractTypes": [
96
- "WorkItems"
97
- ],
98
- "contentTypes": [
99
- {
100
- "id": "raw"
101
- },
102
- {
103
- "id": "snapshots"
104
- },
105
- {
106
- "id": "discovery",
107
- "discriminator": {
108
- "path": "data.discoveryType",
109
- "required": false
110
- }
111
- },
112
- {
113
- "id": "analysis",
114
- "discriminator": {
115
- "path": "data.analysisType",
116
- "required": false,
117
- "defaultValue": "delivery-risk"
118
- }
119
- },
120
- {
121
- "id": "decisions",
122
- "discriminator": {
123
- "path": "data.decisionType",
124
- "required": false,
125
- "defaultValue": "priority"
126
- }
127
- },
128
- {
129
- "id": "workflow"
130
- },
131
- {
132
- "id": "context",
133
- "retention": "work-scoped-ttl"
134
- },
135
- {
136
- "id": "relationships"
137
- }
138
- ],
139
- "snapshotBuckets": {
140
- "analytics": "optional",
141
- "enrichment": "optional",
142
- "insights": "optional"
143
- }
144
- },
145
- {
146
- "id": "playbooks",
147
- "name": "Playbooks",
148
- "dataCategory": "knowledge",
149
- "abstractTypes": [
150
- "Playbooks"
151
- ],
152
- "contentTypes": [
153
- {
154
- "id": "raw"
155
- },
156
- {
157
- "id": "snapshots",
158
- "notes": "Persistent knowledge content"
159
- },
160
- {
161
- "id": "relationships"
162
- }
163
- ],
164
- "retention": "persistent-knowledge"
165
- },
166
- {
167
- "id": "activity-events",
168
- "name": "Activity Events",
169
- "dataCategory": "event",
170
- "abstractTypes": [
171
- "ActivityEvents"
172
- ],
173
- "contentTypes": [
174
- {
175
- "id": "raw"
176
- },
177
- {
178
- "id": "snapshots",
179
- "notes": "Normalized event content"
180
- },
181
- {
182
- "id": "relationships"
183
- }
184
- ]
185
- }
186
- ],
187
- "abstractTypes": [
188
- {
189
- "id": "People",
190
- "name": "People",
191
- "meaning": "Employees and contractors who perform operational work",
192
- "category": "entity"
193
- },
194
- {
195
- "id": "WorkItems",
196
- "name": "Work Items",
197
- "meaning": "Units of operational work",
198
- "category": "entity"
199
- },
200
- {
201
- "id": "Playbooks",
202
- "name": "Playbooks",
203
- "meaning": "Reusable operational knowledge / playbooks",
204
- "category": "knowledge"
205
- },
206
- {
207
- "id": "ActivityEvents",
208
- "name": "Activity Events",
209
- "meaning": "Progress and activity reports about work items",
210
- "category": "event"
211
- }
212
- ],
213
- "abstractBindings": [
214
- {
215
- "id": "people-employees-contractors",
216
- "abstractType": "People",
217
- "concreteObjectTypes": [
218
- "employees",
219
- "contractors"
220
- ],
221
- "union": true,
222
- "notes": "People = Employees \u222a Contractors. No abstract records exist."
223
- },
224
- {
225
- "id": "work-items-concrete",
226
- "abstractType": "WorkItems",
227
- "concreteObjectTypes": [
228
- "work-items"
229
- ],
230
- "union": false
231
- },
232
- {
233
- "id": "playbooks-concrete",
234
- "abstractType": "Playbooks",
235
- "concreteObjectTypes": [
236
- "playbooks"
237
- ],
238
- "union": false
239
- },
240
- {
241
- "id": "activity-events-concrete",
242
- "abstractType": "ActivityEvents",
243
- "concreteObjectTypes": [
244
- "activity-events"
245
- ],
246
- "union": false
247
- }
248
- ],
249
- "relationshipDefinitions": [
250
- {
251
- "id": "people-assigned-to-work-items",
252
- "name": "People assigned to work items",
253
- "meaning": "A person (employee or contractor) is assigned to perform a work item",
254
- "directionality": "directed",
255
- "from": {
256
- "abstractType": "People",
257
- "path": "assignedWorkItems"
258
- },
259
- "to": {
260
- "abstractType": "WorkItems",
261
- "path": "assignedPeople"
262
- },
263
- "discoveryRules": [
264
- {
265
- "id": "from-source-assignee",
266
- "kind": "source-field",
267
- "sourcePath": "assigneeId",
268
- "notes": "opx-source work-items.assigneeId resolves across employees and contractors"
269
- }
270
- ]
271
- },
272
- {
273
- "id": "work-items-use-playbooks",
274
- "name": "Work items use playbooks",
275
- "meaning": "A work item follows one or more reusable playbooks",
276
- "directionality": "directed",
277
- "from": {
278
- "abstractType": "WorkItems",
279
- "path": "usedPlaybooks"
280
- },
281
- "to": {
282
- "abstractType": "Playbooks",
283
- "path": "usedByWorkItems"
284
- },
285
- "discoveryRules": [
286
- {
287
- "id": "from-source-playbook-ids",
288
- "kind": "source-field",
289
- "sourcePath": "playbookIds"
290
- }
291
- ]
292
- },
293
- {
294
- "id": "activity-events-about-work-items",
295
- "name": "Activity events about work items",
296
- "meaning": "An activity event reports progress on a work item",
297
- "directionality": "directed",
298
- "from": {
299
- "abstractType": "ActivityEvents",
300
- "path": "aboutWorkItems"
301
- },
302
- "to": {
303
- "abstractType": "WorkItems",
304
- "path": "activityEvents"
305
- },
306
- "discoveryRules": [
307
- {
308
- "id": "from-source-work-item-id",
309
- "kind": "source-field",
310
- "sourcePath": "workItemId"
311
- }
312
- ]
313
- },
314
- {
315
- "id": "work-items-depend-on-work-items",
316
- "name": "Work items depend on work items",
317
- "meaning": "A work item cannot complete until another work item completes",
318
- "directionality": "directed",
319
- "from": {
320
- "abstractType": "WorkItems",
321
- "path": "dependsOn"
322
- },
323
- "to": {
324
- "abstractType": "WorkItems",
325
- "path": "dependedOnBy"
326
- },
327
- "discoveryRules": [
328
- {
329
- "id": "from-source-depends-on",
330
- "kind": "source-field",
331
- "sourcePath": "dependsOnIds"
332
- }
333
- ]
334
- },
335
- {
336
- "id": "people-collaborate-with-people",
337
- "name": "People collaborate with people",
338
- "meaning": "Two people collaborate on operational work",
339
- "directionality": "undirected",
340
- "from": {
341
- "abstractType": "People",
342
- "path": "collaborators"
343
- },
344
- "to": {
345
- "abstractType": "People",
346
- "path": "collaborators"
347
- },
348
- "discoveryRules": [
349
- {
350
- "id": "from-source-collaborator-ids",
351
- "kind": "source-field",
352
- "sourcePath": "collaboratorIds"
353
- }
354
- ]
355
- }
356
- ],
357
- "mappings": [
358
- {
359
- "id": "bad-completion",
360
- "purpose": "completion",
361
- "objectType": "work-items",
362
- "contentType": "snapshots",
363
- "map": {
364
- "data.x": {
365
- "op": "default",
366
- "value": 1
367
- }
368
- },
369
- "executionPolicy": {
370
- "retries": 3
371
- }
372
- }
373
- ],
374
- "views": [
375
- {
376
- "id": "opx-work-items-list",
377
- "kind": "list",
378
- "title": "Work items",
379
- "columns": [
380
- "concept.title",
381
- "data.status",
382
- "data.priority"
383
- ],
384
- "abstractType": "WorkItems"
385
- },
386
- {
387
- "id": "opx-work-items-item",
388
- "kind": "item",
389
- "title": "Work item",
390
- "sections": [
391
- "concept",
392
- "data",
393
- "workflow",
394
- "analysis",
395
- "decisions"
396
- ],
397
- "abstractType": "WorkItems"
398
- },
399
- {
400
- "id": "opx-people-list",
401
- "kind": "list",
402
- "abstractType": "People",
403
- "title": "People",
404
- "columns": [
405
- "concept.title",
406
- "objectType",
407
- "data.role"
408
- ]
409
- },
410
- {
411
- "id": "opx-work-item-expand-people",
412
- "kind": "relationship-expansion",
413
- "relationshipDefinitionId": "people-assigned-to-work-items",
414
- "direction": "to-from",
415
- "abstractType": "WorkItems"
416
- }
417
- ],
418
- "writes": [
419
- {
420
- "id": "opx-employees-snapshots",
421
- "objectType": "employees",
422
- "contentType": "snapshots",
423
- "identity": {
424
- "primaryKind": "employeeId",
425
- "issuer": "opx-source"
426
- }
427
- },
428
- {
429
- "id": "opx-contractors-snapshots",
430
- "objectType": "contractors",
431
- "contentType": "snapshots",
432
- "identity": {
433
- "primaryKind": "contractorId",
434
- "issuer": "opx-source"
435
- }
436
- },
437
- {
438
- "id": "opx-work-items-snapshots",
439
- "objectType": "work-items",
440
- "contentType": "snapshots",
441
- "identity": {
442
- "primaryKind": "workItemId",
443
- "issuer": "opx-source"
444
- }
445
- },
446
- {
447
- "id": "opx-playbooks-snapshots",
448
- "objectType": "playbooks",
449
- "contentType": "snapshots",
450
- "identity": {
451
- "primaryKind": "playbookId",
452
- "issuer": "opx-source"
453
- }
454
- },
455
- {
456
- "id": "opx-activity-events-snapshots",
457
- "objectType": "activity-events",
458
- "contentType": "snapshots",
459
- "identity": {
460
- "primaryKind": "activityEventId",
461
- "issuer": "opx-source"
462
- }
463
- }
464
- ],
465
- "sources": [
466
- {
467
- "id": "opx-source",
468
- "name": "Opx-service",
469
- "kind": "rest",
470
- "baseUrlEnv": "OPX_SOURCE_URL",
471
- "defaultBaseUrl": "http://127.0.0.1:5102",
472
- "credentialRef": "opx-source-local",
473
- "endpoints": [
474
- "/employees",
475
- "/contractors",
476
- "/work-items",
477
- "/activity-events",
478
- "/playbooks",
479
- "/work-items/:id/context"
480
- ]
481
- }
482
- ],
483
- "services": [
484
- {
485
- "id": "opx-normalize",
486
- "name": "Normalize records",
487
- "description": "Logical normalize capability for ops knowledge pull",
488
- "capabilities": [
489
- "normalize"
490
- ],
491
- "inputs": [
492
- {
493
- "id": "raw-records",
494
- "abstractType": "People"
495
- }
496
- ],
497
- "outputs": [
498
- {
499
- "id": "normalized-records",
500
- "abstractType": "People"
501
- }
502
- ],
503
- "invocation": {
504
- "kind": "worker",
505
- "operation": "normalize"
506
- }
507
- },
508
- {
509
- "id": "opx-completion",
510
- "name": "Field completion",
511
- "capabilities": [
512
- "completion"
513
- ],
514
- "inputs": [
515
- {
516
- "id": "snapshot",
517
- "abstractType": "People"
518
- }
519
- ],
520
- "outputs": [
521
- {
522
- "id": "completed",
523
- "abstractType": "People"
524
- }
525
- ],
526
- "invocation": {
527
- "kind": "worker",
528
- "operation": "complete"
529
- }
530
- }
531
- ],
532
- "pipelines": [
533
- {
534
- "id": "opx-knowledge-pull",
535
- "name": "Scheduled knowledge pull from opx-source",
536
- "trigger": "scheduled",
537
- "mode": "knowledge",
538
- "steps": [
539
- {
540
- "id": "pull",
541
- "kind": "memory-pull",
542
- "sourceId": "opx-source"
543
- },
544
- {
545
- "id": "land-raw",
546
- "kind": "write-raw"
547
- },
548
- {
549
- "id": "normalize",
550
- "kind": "normalize"
551
- },
552
- {
553
- "id": "promote",
554
- "kind": "promote-snapshots"
555
- },
556
- {
557
- "id": "normalize-svc",
558
- "kind": "invoke-service",
559
- "serviceId": "opx-normalize"
560
- },
561
- {
562
- "id": "complete",
563
- "kind": "completion",
564
- "serviceId": "opx-completion",
565
- "mappingId": "opx-work-items-completion-priority",
566
- "completionPolicy": {
567
- "mode": "fill-missing",
568
- "maxFields": 20
569
- }
570
- }
571
- ]
572
- },
573
- {
574
- "id": "opx-context-pull",
575
- "name": "On-demand work-item context pull",
576
- "trigger": "on-demand",
577
- "mode": "context",
578
- "steps": [
579
- {
580
- "id": "pull",
581
- "kind": "memory-pull",
582
- "sourceId": "opx-source"
583
- },
584
- {
585
- "id": "land-raw",
586
- "kind": "write-raw"
587
- },
588
- {
589
- "id": "normalize-context",
590
- "kind": "normalize-context"
591
- },
592
- {
593
- "id": "ttl",
594
- "kind": "apply-ttl"
595
- }
596
- ]
597
- },
598
- {
599
- "id": "opx-relationship-build",
600
- "name": "Discover and write lightweight relationships",
601
- "trigger": "explicit",
602
- "steps": [
603
- {
604
- "id": "discover",
605
- "kind": "relationship-discover"
606
- },
607
- {
608
- "id": "write",
609
- "kind": "relationship-write"
610
- },
611
- {
612
- "id": "verify",
613
- "kind": "relationship-verify"
614
- }
615
- ]
616
- },
617
- {
618
- "id": "opx-analysis",
619
- "name": "Work-item analysis sibling",
620
- "trigger": "explicit",
621
- "steps": [
622
- {
623
- "id": "analyze",
624
- "kind": "analysis"
625
- },
626
- {
627
- "id": "write-sibling",
628
- "kind": "write-content",
629
- "contentType": "analysis"
630
- }
631
- ]
632
- },
633
- {
634
- "id": "opx-workflow",
635
- "name": "Work-item workflow sibling",
636
- "trigger": "explicit",
637
- "steps": [
638
- {
639
- "id": "sync-workflow",
640
- "kind": "workflow-sync"
641
- },
642
- {
643
- "id": "write-sibling",
644
- "kind": "write-content",
645
- "contentType": "workflow"
646
- }
647
- ]
648
- }
649
- ],
650
- "schedules": [
651
- {
652
- "id": "opx-knowledge-hourly",
653
- "pipelineId": "opx-knowledge-pull",
654
- "cron": "0 * * * *",
655
- "timezone": "UTC",
656
- "enabled": true
657
- }
658
- ]
659
- }
1
+ {
2
+ "format": "memorix-metadata/1",
3
+ "agentId": "opx",
4
+ "version": "0.1.0",
5
+ "agents": [
6
+ {
7
+ "id": "opx",
8
+ "name": "Operations (generic parent)",
9
+ "description": "Complete generic parent agent for ordinary operational work. Permanent Memorix acceptance pack.",
10
+ "parentId": null
11
+ },
12
+ {
13
+ "id": "project-opx",
14
+ "name": "Project Operations (child of opx)",
15
+ "description": "Inheritance smoke agent. Extends opx without replacing core definitions.",
16
+ "parentId": "opx"
17
+ }
18
+ ],
19
+ "objectTypes": [
20
+ {
21
+ "id": "employees",
22
+ "name": "Employees",
23
+ "dataCategory": "entity",
24
+ "abstractTypes": [
25
+ "People"
26
+ ],
27
+ "contentTypes": [
28
+ {
29
+ "id": "raw",
30
+ "required": true
31
+ },
32
+ {
33
+ "id": "snapshots",
34
+ "required": true
35
+ },
36
+ {
37
+ "id": "discovery",
38
+ "discriminator": {
39
+ "path": "data.discoveryType",
40
+ "required": false,
41
+ "defaultValue": "default"
42
+ }
43
+ },
44
+ {
45
+ "id": "analysis",
46
+ "discriminator": {
47
+ "path": "data.analysisType",
48
+ "required": false,
49
+ "defaultValue": "default"
50
+ }
51
+ },
52
+ {
53
+ "id": "relationships",
54
+ "notes": "Candidate store shape until Gate G4"
55
+ }
56
+ ]
57
+ },
58
+ {
59
+ "id": "contractors",
60
+ "name": "Contractors",
61
+ "dataCategory": "entity",
62
+ "abstractTypes": [
63
+ "People"
64
+ ],
65
+ "contentTypes": [
66
+ {
67
+ "id": "raw"
68
+ },
69
+ {
70
+ "id": "snapshots"
71
+ },
72
+ {
73
+ "id": "discovery",
74
+ "discriminator": {
75
+ "path": "data.discoveryType",
76
+ "required": false
77
+ }
78
+ },
79
+ {
80
+ "id": "analysis",
81
+ "discriminator": {
82
+ "path": "data.analysisType",
83
+ "required": false
84
+ }
85
+ },
86
+ {
87
+ "id": "relationships"
88
+ }
89
+ ]
90
+ },
91
+ {
92
+ "id": "work-items",
93
+ "name": "Work Items",
94
+ "dataCategory": "entity",
95
+ "abstractTypes": [
96
+ "WorkItems"
97
+ ],
98
+ "contentTypes": [
99
+ {
100
+ "id": "raw"
101
+ },
102
+ {
103
+ "id": "snapshots"
104
+ },
105
+ {
106
+ "id": "discovery",
107
+ "discriminator": {
108
+ "path": "data.discoveryType",
109
+ "required": false
110
+ }
111
+ },
112
+ {
113
+ "id": "analysis",
114
+ "discriminator": {
115
+ "path": "data.analysisType",
116
+ "required": false,
117
+ "defaultValue": "delivery-risk"
118
+ }
119
+ },
120
+ {
121
+ "id": "decisions",
122
+ "discriminator": {
123
+ "path": "data.decisionType",
124
+ "required": false,
125
+ "defaultValue": "priority"
126
+ }
127
+ },
128
+ {
129
+ "id": "workflow"
130
+ },
131
+ {
132
+ "id": "context",
133
+ "retention": "work-scoped-ttl"
134
+ },
135
+ {
136
+ "id": "relationships"
137
+ }
138
+ ],
139
+ "snapshotBuckets": {
140
+ "analytics": "optional",
141
+ "enrichment": "optional",
142
+ "insights": "optional"
143
+ }
144
+ },
145
+ {
146
+ "id": "playbooks",
147
+ "name": "Playbooks",
148
+ "dataCategory": "knowledge",
149
+ "abstractTypes": [
150
+ "Playbooks"
151
+ ],
152
+ "contentTypes": [
153
+ {
154
+ "id": "raw"
155
+ },
156
+ {
157
+ "id": "snapshots",
158
+ "notes": "Persistent knowledge content"
159
+ },
160
+ {
161
+ "id": "relationships"
162
+ }
163
+ ],
164
+ "retention": "persistent-knowledge"
165
+ },
166
+ {
167
+ "id": "activity-events",
168
+ "name": "Activity Events",
169
+ "dataCategory": "event",
170
+ "abstractTypes": [
171
+ "ActivityEvents"
172
+ ],
173
+ "contentTypes": [
174
+ {
175
+ "id": "raw"
176
+ },
177
+ {
178
+ "id": "snapshots",
179
+ "notes": "Normalized event content"
180
+ },
181
+ {
182
+ "id": "relationships"
183
+ }
184
+ ]
185
+ }
186
+ ],
187
+ "abstractTypes": [
188
+ {
189
+ "id": "People",
190
+ "name": "People",
191
+ "meaning": "Employees and contractors who perform operational work",
192
+ "category": "entity"
193
+ },
194
+ {
195
+ "id": "WorkItems",
196
+ "name": "Work Items",
197
+ "meaning": "Units of operational work",
198
+ "category": "entity"
199
+ },
200
+ {
201
+ "id": "Playbooks",
202
+ "name": "Playbooks",
203
+ "meaning": "Reusable operational knowledge / playbooks",
204
+ "category": "knowledge"
205
+ },
206
+ {
207
+ "id": "ActivityEvents",
208
+ "name": "Activity Events",
209
+ "meaning": "Progress and activity reports about work items",
210
+ "category": "event"
211
+ }
212
+ ],
213
+ "abstractBindings": [
214
+ {
215
+ "id": "people-employees-contractors",
216
+ "abstractType": "People",
217
+ "concreteObjectTypes": [
218
+ "employees",
219
+ "contractors"
220
+ ],
221
+ "union": true,
222
+ "notes": "People = Employees \u222a Contractors. No abstract records exist."
223
+ },
224
+ {
225
+ "id": "work-items-concrete",
226
+ "abstractType": "WorkItems",
227
+ "concreteObjectTypes": [
228
+ "work-items"
229
+ ],
230
+ "union": false
231
+ },
232
+ {
233
+ "id": "playbooks-concrete",
234
+ "abstractType": "Playbooks",
235
+ "concreteObjectTypes": [
236
+ "playbooks"
237
+ ],
238
+ "union": false
239
+ },
240
+ {
241
+ "id": "activity-events-concrete",
242
+ "abstractType": "ActivityEvents",
243
+ "concreteObjectTypes": [
244
+ "activity-events"
245
+ ],
246
+ "union": false
247
+ }
248
+ ],
249
+ "relationshipDefinitions": [
250
+ {
251
+ "id": "people-assigned-to-work-items",
252
+ "name": "People assigned to work items",
253
+ "meaning": "A person (employee or contractor) is assigned to perform a work item",
254
+ "directionality": "directed",
255
+ "from": {
256
+ "abstractType": "People",
257
+ "path": "assignedWorkItems"
258
+ },
259
+ "to": {
260
+ "abstractType": "WorkItems",
261
+ "path": "assignedPeople"
262
+ },
263
+ "discoveryRules": [
264
+ {
265
+ "id": "from-source-assignee",
266
+ "kind": "source-field",
267
+ "sourcePath": "assigneeId",
268
+ "notes": "opx-source work-items.assigneeId resolves across employees and contractors"
269
+ }
270
+ ]
271
+ },
272
+ {
273
+ "id": "work-items-use-playbooks",
274
+ "name": "Work items use playbooks",
275
+ "meaning": "A work item follows one or more reusable playbooks",
276
+ "directionality": "directed",
277
+ "from": {
278
+ "abstractType": "WorkItems",
279
+ "path": "usedPlaybooks"
280
+ },
281
+ "to": {
282
+ "abstractType": "Playbooks",
283
+ "path": "usedByWorkItems"
284
+ },
285
+ "discoveryRules": [
286
+ {
287
+ "id": "from-source-playbook-ids",
288
+ "kind": "source-field",
289
+ "sourcePath": "playbookIds"
290
+ }
291
+ ]
292
+ },
293
+ {
294
+ "id": "activity-events-about-work-items",
295
+ "name": "Activity events about work items",
296
+ "meaning": "An activity event reports progress on a work item",
297
+ "directionality": "directed",
298
+ "from": {
299
+ "abstractType": "ActivityEvents",
300
+ "path": "aboutWorkItems"
301
+ },
302
+ "to": {
303
+ "abstractType": "WorkItems",
304
+ "path": "activityEvents"
305
+ },
306
+ "discoveryRules": [
307
+ {
308
+ "id": "from-source-work-item-id",
309
+ "kind": "source-field",
310
+ "sourcePath": "workItemId"
311
+ }
312
+ ]
313
+ },
314
+ {
315
+ "id": "work-items-depend-on-work-items",
316
+ "name": "Work items depend on work items",
317
+ "meaning": "A work item cannot complete until another work item completes",
318
+ "directionality": "directed",
319
+ "from": {
320
+ "abstractType": "WorkItems",
321
+ "path": "dependsOn"
322
+ },
323
+ "to": {
324
+ "abstractType": "WorkItems",
325
+ "path": "dependedOnBy"
326
+ },
327
+ "discoveryRules": [
328
+ {
329
+ "id": "from-source-depends-on",
330
+ "kind": "source-field",
331
+ "sourcePath": "dependsOnIds"
332
+ }
333
+ ]
334
+ },
335
+ {
336
+ "id": "people-collaborate-with-people",
337
+ "name": "People collaborate with people",
338
+ "meaning": "Two people collaborate on operational work",
339
+ "directionality": "undirected",
340
+ "from": {
341
+ "abstractType": "People",
342
+ "path": "collaborators"
343
+ },
344
+ "to": {
345
+ "abstractType": "People",
346
+ "path": "collaborators"
347
+ },
348
+ "discoveryRules": [
349
+ {
350
+ "id": "from-source-collaborator-ids",
351
+ "kind": "source-field",
352
+ "sourcePath": "collaboratorIds"
353
+ }
354
+ ]
355
+ }
356
+ ],
357
+ "mappings": [
358
+ {
359
+ "id": "bad-completion",
360
+ "purpose": "completion",
361
+ "objectType": "work-items",
362
+ "contentType": "snapshots",
363
+ "map": {
364
+ "data.x": {
365
+ "op": "default",
366
+ "value": 1
367
+ }
368
+ },
369
+ "executionPolicy": {
370
+ "retries": 3
371
+ }
372
+ }
373
+ ],
374
+ "views": [
375
+ {
376
+ "id": "opx-work-items-list",
377
+ "kind": "list",
378
+ "title": "Work items",
379
+ "columns": [
380
+ "concept.title",
381
+ "data.status",
382
+ "data.priority"
383
+ ],
384
+ "abstractType": "WorkItems"
385
+ },
386
+ {
387
+ "id": "opx-work-items-item",
388
+ "kind": "item",
389
+ "title": "Work item",
390
+ "sections": [
391
+ "concept",
392
+ "data",
393
+ "workflow",
394
+ "analysis",
395
+ "decisions"
396
+ ],
397
+ "abstractType": "WorkItems"
398
+ },
399
+ {
400
+ "id": "opx-people-list",
401
+ "kind": "list",
402
+ "abstractType": "People",
403
+ "title": "People",
404
+ "columns": [
405
+ "concept.title",
406
+ "objectType",
407
+ "data.role"
408
+ ]
409
+ },
410
+ {
411
+ "id": "opx-work-item-expand-people",
412
+ "kind": "relationship-expansion",
413
+ "relationshipDefinitionId": "people-assigned-to-work-items",
414
+ "direction": "to-from",
415
+ "abstractType": "WorkItems"
416
+ }
417
+ ],
418
+ "writes": [
419
+ {
420
+ "id": "opx-employees-snapshots",
421
+ "objectType": "employees",
422
+ "contentType": "snapshots",
423
+ "identity": {
424
+ "primaryKind": "employeeId",
425
+ "issuer": "opx-source"
426
+ }
427
+ },
428
+ {
429
+ "id": "opx-contractors-snapshots",
430
+ "objectType": "contractors",
431
+ "contentType": "snapshots",
432
+ "identity": {
433
+ "primaryKind": "contractorId",
434
+ "issuer": "opx-source"
435
+ }
436
+ },
437
+ {
438
+ "id": "opx-work-items-snapshots",
439
+ "objectType": "work-items",
440
+ "contentType": "snapshots",
441
+ "identity": {
442
+ "primaryKind": "workItemId",
443
+ "issuer": "opx-source"
444
+ }
445
+ },
446
+ {
447
+ "id": "opx-playbooks-snapshots",
448
+ "objectType": "playbooks",
449
+ "contentType": "snapshots",
450
+ "identity": {
451
+ "primaryKind": "playbookId",
452
+ "issuer": "opx-source"
453
+ }
454
+ },
455
+ {
456
+ "id": "opx-activity-events-snapshots",
457
+ "objectType": "activity-events",
458
+ "contentType": "snapshots",
459
+ "identity": {
460
+ "primaryKind": "activityEventId",
461
+ "issuer": "opx-source"
462
+ }
463
+ }
464
+ ],
465
+ "sources": [
466
+ {
467
+ "id": "opx-source",
468
+ "name": "Opx-service",
469
+ "kind": "rest",
470
+ "baseUrlEnv": "OPX_SOURCE_URL",
471
+ "defaultBaseUrl": "http://127.0.0.1:5102",
472
+ "credentialRef": "opx-source-local",
473
+ "endpoints": [
474
+ "/employees",
475
+ "/contractors",
476
+ "/work-items",
477
+ "/activity-events",
478
+ "/playbooks",
479
+ "/work-items/:id/context"
480
+ ]
481
+ }
482
+ ],
483
+ "services": [
484
+ {
485
+ "id": "opx-normalize",
486
+ "name": "Normalize records",
487
+ "description": "Logical normalize capability for ops knowledge pull",
488
+ "capabilities": [
489
+ "normalize"
490
+ ],
491
+ "inputs": [
492
+ {
493
+ "id": "raw-records",
494
+ "abstractType": "People"
495
+ }
496
+ ],
497
+ "outputs": [
498
+ {
499
+ "id": "normalized-records",
500
+ "abstractType": "People"
501
+ }
502
+ ],
503
+ "invocation": {
504
+ "kind": "worker",
505
+ "operation": "normalize"
506
+ }
507
+ },
508
+ {
509
+ "id": "opx-completion",
510
+ "name": "Field completion",
511
+ "capabilities": [
512
+ "completion"
513
+ ],
514
+ "inputs": [
515
+ {
516
+ "id": "snapshot",
517
+ "abstractType": "People"
518
+ }
519
+ ],
520
+ "outputs": [
521
+ {
522
+ "id": "completed",
523
+ "abstractType": "People"
524
+ }
525
+ ],
526
+ "invocation": {
527
+ "kind": "worker",
528
+ "operation": "complete"
529
+ }
530
+ }
531
+ ],
532
+ "pipelines": [
533
+ {
534
+ "id": "opx-knowledge-pull",
535
+ "name": "Scheduled knowledge pull from opx-source",
536
+ "trigger": "scheduled",
537
+ "mode": "knowledge",
538
+ "steps": [
539
+ {
540
+ "id": "pull",
541
+ "kind": "memory-pull",
542
+ "sourceId": "opx-source"
543
+ },
544
+ {
545
+ "id": "land-raw",
546
+ "kind": "write-raw"
547
+ },
548
+ {
549
+ "id": "normalize",
550
+ "kind": "normalize"
551
+ },
552
+ {
553
+ "id": "promote",
554
+ "kind": "promote-snapshots"
555
+ },
556
+ {
557
+ "id": "normalize-svc",
558
+ "kind": "invoke-service",
559
+ "serviceId": "opx-normalize"
560
+ },
561
+ {
562
+ "id": "complete",
563
+ "kind": "completion",
564
+ "serviceId": "opx-completion",
565
+ "mappingId": "opx-work-items-completion-priority",
566
+ "completionPolicy": {
567
+ "mode": "fill-missing",
568
+ "maxFields": 20
569
+ }
570
+ }
571
+ ]
572
+ },
573
+ {
574
+ "id": "opx-context-pull",
575
+ "name": "On-demand work-item context pull",
576
+ "trigger": "on-demand",
577
+ "mode": "context",
578
+ "steps": [
579
+ {
580
+ "id": "pull",
581
+ "kind": "memory-pull",
582
+ "sourceId": "opx-source"
583
+ },
584
+ {
585
+ "id": "land-raw",
586
+ "kind": "write-raw"
587
+ },
588
+ {
589
+ "id": "normalize-context",
590
+ "kind": "normalize-context"
591
+ },
592
+ {
593
+ "id": "ttl",
594
+ "kind": "apply-ttl"
595
+ }
596
+ ]
597
+ },
598
+ {
599
+ "id": "opx-relationship-build",
600
+ "name": "Discover and write lightweight relationships",
601
+ "trigger": "explicit",
602
+ "steps": [
603
+ {
604
+ "id": "discover",
605
+ "kind": "relationship-discover"
606
+ },
607
+ {
608
+ "id": "write",
609
+ "kind": "relationship-write"
610
+ },
611
+ {
612
+ "id": "verify",
613
+ "kind": "relationship-verify"
614
+ }
615
+ ]
616
+ },
617
+ {
618
+ "id": "opx-analysis",
619
+ "name": "Work-item analysis sibling",
620
+ "trigger": "explicit",
621
+ "steps": [
622
+ {
623
+ "id": "analyze",
624
+ "kind": "analysis"
625
+ },
626
+ {
627
+ "id": "write-sibling",
628
+ "kind": "write-content",
629
+ "contentType": "analysis"
630
+ }
631
+ ]
632
+ },
633
+ {
634
+ "id": "opx-workflow",
635
+ "name": "Work-item workflow sibling",
636
+ "trigger": "explicit",
637
+ "steps": [
638
+ {
639
+ "id": "sync-workflow",
640
+ "kind": "workflow-sync"
641
+ },
642
+ {
643
+ "id": "write-sibling",
644
+ "kind": "write-content",
645
+ "contentType": "workflow"
646
+ }
647
+ ]
648
+ }
649
+ ],
650
+ "schedules": [
651
+ {
652
+ "id": "opx-knowledge-hourly",
653
+ "pipelineId": "opx-knowledge-pull",
654
+ "cron": "0 * * * *",
655
+ "timezone": "UTC",
656
+ "enabled": true
657
+ }
658
+ ]
659
+ }