@x12i/memorix-format 3.0.3 → 3.0.6

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 (54) hide show
  1. package/CHANGELOG.md +73 -65
  2. package/README.md +78 -78
  3. package/dist/base/concept.d.ts +4 -0
  4. package/dist/base/concept.d.ts.map +1 -1
  5. package/dist/base/concept.js +5 -1
  6. package/dist/base/concept.js.map +1 -1
  7. package/dist/cli.js +36 -36
  8. package/dist/v2/identity.d.ts +19 -0
  9. package/dist/v2/identity.d.ts.map +1 -0
  10. package/dist/v2/identity.js +39 -0
  11. package/dist/v2/identity.js.map +1 -0
  12. package/dist/v2/index.d.ts +2 -1
  13. package/dist/v2/index.d.ts.map +1 -1
  14. package/dist/v2/index.js +1 -0
  15. package/dist/v2/index.js.map +1 -1
  16. package/dist/v2/migrate-present.js +1 -1
  17. package/dist/v2/migrate-present.js.map +1 -1
  18. package/dist/v2/profiles.d.ts +1 -1
  19. package/dist/v2/profiles.d.ts.map +1 -1
  20. package/dist/v2/profiles.js +1 -0
  21. package/dist/v2/profiles.js.map +1 -1
  22. package/dist/v2/types.d.ts +24 -0
  23. package/dist/v2/types.d.ts.map +1 -1
  24. package/dist/v2/validate.d.ts.map +1 -1
  25. package/dist/v2/validate.js +18 -1
  26. package/dist/v2/validate.js.map +1 -1
  27. package/docs/association-format.md +47 -47
  28. package/docs/memorix-format-requirements.md +54 -54
  29. package/docs/memorix-format.md +68 -68
  30. package/docs/memorix-record-v2.md +102 -101
  31. package/docs/memorix-workflow-format.md +126 -126
  32. package/docs/migrate-present-to-v2.md +49 -49
  33. package/examples/invalid-record.json +11 -11
  34. package/examples/v2/activity-events-snapshots.json +31 -31
  35. package/examples/v2/people-discovery.json +26 -26
  36. package/examples/v2/people-snapshots-employee.json +27 -27
  37. package/examples/v2/playbooks-knowledge.json +27 -27
  38. package/examples/v2/work-items-analysis.json +26 -26
  39. package/examples/v2/work-items-context.json +32 -32
  40. package/examples/v2/work-items-decisions.json +26 -26
  41. package/examples/v2/work-items-raw.json +37 -37
  42. package/examples/v2/work-items-relationships-candidate.json +38 -38
  43. package/examples/v2/work-items-snapshots-lifecycle.json +31 -31
  44. package/examples/v2/work-items-snapshots-lightweight-refs.json +34 -34
  45. package/examples/v2/work-items-snapshots.json +28 -28
  46. package/examples/v2/work-items-workflow.json +28 -28
  47. package/examples/valid-snapshot.json +30 -30
  48. package/meta/associated-conventions.json +59 -59
  49. package/meta/content-type-profiles.json +27 -27
  50. package/meta/content-types.json +80 -80
  51. package/meta/envelope.json +104 -104
  52. package/meta/inventory/managed-descriptors.json +78 -78
  53. package/meta/open-buckets.json +24 -24
  54. package/package.json +77 -77
@@ -1,28 +1,28 @@
1
- {
2
- "format": "memorix-record/2",
3
- "recordId": "wi-100",
4
- "revision": 3,
5
- "objectType": "work-items",
6
- "contentType": "snapshots",
7
- "dataCategory": "entity",
8
- "concept": {
9
- "title": "Prepare quarterly operations review",
10
- "identifiers": {
11
- "primary": {
12
- "kind": "workItemId",
13
- "value": "WI-100",
14
- "issuer": "opx-source"
15
- }
16
- }
17
- },
18
- "data": {
19
- "status": "in-progress",
20
- "priority": "normal"
21
- },
22
- "_system": {
23
- "state": "active",
24
- "createdAt": "2026-01-10T10:00:00.000Z",
25
- "modifiedAt": "2026-01-15T12:00:00.000Z",
26
- "observedAt": "2026-01-15T12:00:00.000Z"
27
- }
28
- }
1
+ {
2
+ "format": "memorix-record/2",
3
+ "recordId": "wi-100",
4
+ "revision": 3,
5
+ "objectType": "work-items",
6
+ "contentType": "snapshots",
7
+ "dataCategory": "entity",
8
+ "concept": {
9
+ "title": "Prepare quarterly operations review",
10
+ "identifiers": {
11
+ "primary": {
12
+ "kind": "workItemId",
13
+ "value": "WI-100",
14
+ "issuer": "opx-source"
15
+ }
16
+ }
17
+ },
18
+ "data": {
19
+ "status": "in-progress",
20
+ "priority": "normal"
21
+ },
22
+ "_system": {
23
+ "state": "active",
24
+ "createdAt": "2026-01-10T10:00:00.000Z",
25
+ "modifiedAt": "2026-01-15T12:00:00.000Z",
26
+ "observedAt": "2026-01-15T12:00:00.000Z"
27
+ }
28
+ }
@@ -1,28 +1,28 @@
1
- {
2
- "format": "memorix-record/2",
3
- "recordId": "wi-100",
4
- "revision": 4,
5
- "objectType": "work-items",
6
- "contentType": "workflow",
7
- "dataCategory": "entity",
8
- "concept": {
9
- "title": "Workflow for wi-100",
10
- "identifiers": {
11
- "primary": {
12
- "kind": "recordId",
13
- "value": "wi-100"
14
- }
15
- }
16
- },
17
- "data": {
18
- "status": "in-progress",
19
- "assigneeRecordId": "employee-10",
20
- "tasks": [],
21
- "audit": []
22
- },
23
- "_system": {
24
- "state": "active",
25
- "createdAt": "2026-01-10T10:00:00.000Z",
26
- "modifiedAt": "2026-01-15T14:00:00.000Z"
27
- }
28
- }
1
+ {
2
+ "format": "memorix-record/2",
3
+ "recordId": "wi-100",
4
+ "revision": 4,
5
+ "objectType": "work-items",
6
+ "contentType": "workflow",
7
+ "dataCategory": "entity",
8
+ "concept": {
9
+ "title": "Workflow for wi-100",
10
+ "identifiers": {
11
+ "primary": {
12
+ "kind": "recordId",
13
+ "value": "wi-100"
14
+ }
15
+ }
16
+ },
17
+ "data": {
18
+ "status": "in-progress",
19
+ "assigneeRecordId": "employee-10",
20
+ "tasks": [],
21
+ "audit": []
22
+ },
23
+ "_system": {
24
+ "state": "active",
25
+ "createdAt": "2026-01-10T10:00:00.000Z",
26
+ "modifiedAt": "2026-01-15T14:00:00.000Z"
27
+ }
28
+ }
@@ -1,30 +1,30 @@
1
- {
2
- "recordId": "rec-item-1",
3
- "concept": {
4
- "_extIdentifier": {
5
- "kind": "sku",
6
- "sku": "SKU-100",
7
- "key": "sku:SKU-100"
8
- },
9
- "title": "Blue widget"
10
- },
11
- "data": {
12
- "sku": "SKU-100",
13
- "color": "blue"
14
- },
15
- "associatedData": [
16
- { "locationCode": "WH-A", "qty": 12 }
17
- ],
18
- "analytics": {
19
- "linkedLocations": { "total": 1 }
20
- },
21
- "insights": {
22
- "priority": { "level": "high", "confidence": 0.9 }
23
- },
24
- "_system": {
25
- "state": "active",
26
- "lifecycle": [
27
- { "process": "enriched", "processedAt": "2026-04-05T08:01:15.511Z" }
28
- ]
29
- }
30
- }
1
+ {
2
+ "recordId": "rec-item-1",
3
+ "concept": {
4
+ "_extIdentifier": {
5
+ "kind": "sku",
6
+ "sku": "SKU-100",
7
+ "key": "sku:SKU-100"
8
+ },
9
+ "title": "Blue widget"
10
+ },
11
+ "data": {
12
+ "sku": "SKU-100",
13
+ "color": "blue"
14
+ },
15
+ "associatedData": [
16
+ { "locationCode": "WH-A", "qty": 12 }
17
+ ],
18
+ "analytics": {
19
+ "linkedLocations": { "total": 1 }
20
+ },
21
+ "insights": {
22
+ "priority": { "level": "high", "confidence": 0.9 }
23
+ },
24
+ "_system": {
25
+ "state": "active",
26
+ "lifecycle": [
27
+ { "process": "enriched", "processedAt": "2026-04-05T08:01:15.511Z" }
28
+ ]
29
+ }
30
+ }
@@ -1,59 +1,59 @@
1
- {
2
- "$schemaNote": "Associated* naming conventions + legacy short names. No objectType bindings.",
3
- "version": "2.1.0",
4
- "prefix": "associated",
5
- "defaultTopMaxItems": 5,
6
- "legacyNames": [
7
- "associatedData",
8
- "associatedDiscovery",
9
- "associatedAnalysis",
10
- "associatedSiblings",
11
- "associatedChildren",
12
- "associatedAssets",
13
- "associatedSubnets"
14
- ],
15
- "namingForms": [
16
- {
17
- "form": "content",
18
- "pattern": "associated[Top?]<ObjectType><ContentType>",
19
- "kind": "linked-payloads",
20
- "shape": "array-of-objects"
21
- },
22
- {
23
- "form": "enrichment",
24
- "pattern": "associated[Top?]<ObjectType>Enrichment",
25
- "kind": "linked-payloads",
26
- "shape": "array-of-objects"
27
- },
28
- {
29
- "form": "snapshotsRootProperty",
30
- "pattern": "associated[Top?]<ObjectType>Snapshots<RootProperty>",
31
- "kind": "linked-payloads",
32
- "shape": "array-of-objects"
33
- },
34
- {
35
- "form": "concepts",
36
- "pattern": "associated[Top?]<ObjectType>Concepts",
37
- "kind": "linked-payloads",
38
- "shape": "array-of-objects"
39
- },
40
- {
41
- "form": "recordIds",
42
- "pattern": "associated[Top?]<ObjectType>RecordIds",
43
- "kind": "linked-payloads",
44
- "shape": "array-of-objects"
45
- },
46
- {
47
- "form": "customDomain",
48
- "pattern": "associated<CustomName>",
49
- "kind": "linked-payloads",
50
- "shape": "array-of-objects",
51
- "examples": ["associatedTopology", "associatedCompliance"]
52
- }
53
- ],
54
- "rules": {
55
- "ASSOC-2": "when present MUST be an array",
56
- "ASSOC-3": "MUST be omitted when empty — never []",
57
- "ASSOC-6": "resolution MUST be snapshot-first (match *-snapshots, then content by recordId)"
58
- }
59
- }
1
+ {
2
+ "$schemaNote": "Associated* naming conventions + legacy short names. No objectType bindings.",
3
+ "version": "2.1.0",
4
+ "prefix": "associated",
5
+ "defaultTopMaxItems": 5,
6
+ "legacyNames": [
7
+ "associatedData",
8
+ "associatedDiscovery",
9
+ "associatedAnalysis",
10
+ "associatedSiblings",
11
+ "associatedChildren",
12
+ "associatedAssets",
13
+ "associatedSubnets"
14
+ ],
15
+ "namingForms": [
16
+ {
17
+ "form": "content",
18
+ "pattern": "associated[Top?]<ObjectType><ContentType>",
19
+ "kind": "linked-payloads",
20
+ "shape": "array-of-objects"
21
+ },
22
+ {
23
+ "form": "enrichment",
24
+ "pattern": "associated[Top?]<ObjectType>Enrichment",
25
+ "kind": "linked-payloads",
26
+ "shape": "array-of-objects"
27
+ },
28
+ {
29
+ "form": "snapshotsRootProperty",
30
+ "pattern": "associated[Top?]<ObjectType>Snapshots<RootProperty>",
31
+ "kind": "linked-payloads",
32
+ "shape": "array-of-objects"
33
+ },
34
+ {
35
+ "form": "concepts",
36
+ "pattern": "associated[Top?]<ObjectType>Concepts",
37
+ "kind": "linked-payloads",
38
+ "shape": "array-of-objects"
39
+ },
40
+ {
41
+ "form": "recordIds",
42
+ "pattern": "associated[Top?]<ObjectType>RecordIds",
43
+ "kind": "linked-payloads",
44
+ "shape": "array-of-objects"
45
+ },
46
+ {
47
+ "form": "customDomain",
48
+ "pattern": "associated<CustomName>",
49
+ "kind": "linked-payloads",
50
+ "shape": "array-of-objects",
51
+ "examples": ["associatedTopology", "associatedCompliance"]
52
+ }
53
+ ],
54
+ "rules": {
55
+ "ASSOC-2": "when present MUST be an array",
56
+ "ASSOC-3": "MUST be omitted when empty — never []",
57
+ "ASSOC-6": "resolution MUST be snapshot-first (match *-snapshots, then content by recordId)"
58
+ }
59
+ }
@@ -1,27 +1,27 @@
1
- {
2
- "$schemaNote": "Content-type profiles (policies). objectType is filled by the caller — never hardcoded here.",
3
- "version": "2.1.0",
4
- "profiles": {
5
- "snapshots": {
6
- "contentType": "snapshots",
7
- "collectionPostfix": "snapshots",
8
- "openBucketsRef": "open-buckets.json",
9
- "policy": {
10
- "unknownOpenBuckets": "allow",
11
- "emptyBuckets": "reject"
12
- },
13
- "read": {
14
- "missingOptionalIsNa": true
15
- }
16
- },
17
- "minimal": {
18
- "policy": {
19
- "unknownOpenBuckets": "warn",
20
- "emptyBuckets": "reject"
21
- },
22
- "read": {
23
- "missingOptionalIsNa": true
24
- }
25
- }
26
- }
27
- }
1
+ {
2
+ "$schemaNote": "Content-type profiles (policies). objectType is filled by the caller — never hardcoded here.",
3
+ "version": "2.1.0",
4
+ "profiles": {
5
+ "snapshots": {
6
+ "contentType": "snapshots",
7
+ "collectionPostfix": "snapshots",
8
+ "openBucketsRef": "open-buckets.json",
9
+ "policy": {
10
+ "unknownOpenBuckets": "allow",
11
+ "emptyBuckets": "reject"
12
+ },
13
+ "read": {
14
+ "missingOptionalIsNa": true
15
+ }
16
+ },
17
+ "minimal": {
18
+ "policy": {
19
+ "unknownOpenBuckets": "warn",
20
+ "emptyBuckets": "reject"
21
+ },
22
+ "read": {
23
+ "missingOptionalIsNa": true
24
+ }
25
+ }
26
+ }
27
+ }
@@ -1,80 +1,80 @@
1
- {
2
- "$schemaNote": "Content-type vocabulary used by Memorix. Not object types. Aligned with managed Catalox entity descriptors + product vocabulary.",
3
- "version": "2.1.0",
4
- "canonicalContentType": "snapshots",
5
- "contentTypes": {
6
- "snapshots": {
7
- "profile": "snapshots",
8
- "description": "Full readable object view — may carry known open buckets and associated*"
9
- },
10
- "discovery": {
11
- "profile": "minimal",
12
- "description": "Discovery / Q&A style content"
13
- },
14
- "analysis": {
15
- "profile": "minimal",
16
- "description": "Analysis content"
17
- },
18
- "decisions": {
19
- "profile": "minimal",
20
- "description": "Decision content",
21
- "collectionPostfixVariants": ["decision", "decisions"]
22
- },
23
- "scoped": {
24
- "profile": "minimal",
25
- "description": "Scoped slice"
26
- },
27
- "legacy": {
28
- "profile": "minimal",
29
- "description": "Quarantined / legacy slice"
30
- },
31
- "narratives": {
32
- "profile": "minimal",
33
- "description": "Narrative records"
34
- },
35
- "narrative-steps": {
36
- "profile": "minimal",
37
- "description": "Narrative step records"
38
- },
39
- "workflow": {
40
- "profile": "workflow",
41
- "description": "Product workflow overlay (memorix-workflow/1) — not the snapshot envelope"
42
- },
43
- "extrated": {
44
- "profile": "minimal",
45
- "description": "Extracted document content (managed key spelling as in Catalox descriptors)"
46
- },
47
- "chunks": {
48
- "profile": "minimal",
49
- "description": "Document chunks"
50
- },
51
- "ai-processing": {
52
- "profile": "minimal",
53
- "description": "Product vocabulary — optional CT"
54
- },
55
- "context": {
56
- "profile": "minimal",
57
- "description": "Product vocabulary — optional CT"
58
- },
59
- "suggested-plans": {
60
- "profile": "minimal",
61
- "description": "Product vocabulary — optional CT"
62
- },
63
- "suggested-actions": {
64
- "profile": "minimal",
65
- "description": "Product vocabulary — optional CT"
66
- },
67
- "knowx": {
68
- "profile": "minimal",
69
- "description": "Native KnowX knowledge facet — data.kind NODE|EDGE; provenance (docHash + SourceSpan) mandatory; epistemic.state ≠ extraction confidence"
70
- },
71
- "nexum": {
72
- "profile": "minimal",
73
- "description": "Nexum contribution / node / claim records (write-record mode nexum)"
74
- },
75
- "confirmations": {
76
- "profile": "minimal",
77
- "description": "Accept/reject decision sibling for reviewed claims (e.g. KnowX assertions)"
78
- }
79
- }
80
- }
1
+ {
2
+ "$schemaNote": "Content-type vocabulary used by Memorix. Not object types. Aligned with managed Catalox entity descriptors + product vocabulary.",
3
+ "version": "2.1.0",
4
+ "canonicalContentType": "snapshots",
5
+ "contentTypes": {
6
+ "snapshots": {
7
+ "profile": "snapshots",
8
+ "description": "Full readable object view — may carry known open buckets and associated*"
9
+ },
10
+ "discovery": {
11
+ "profile": "minimal",
12
+ "description": "Discovery / Q&A style content"
13
+ },
14
+ "analysis": {
15
+ "profile": "minimal",
16
+ "description": "Analysis content"
17
+ },
18
+ "decisions": {
19
+ "profile": "minimal",
20
+ "description": "Decision content",
21
+ "collectionPostfixVariants": ["decision", "decisions"]
22
+ },
23
+ "scoped": {
24
+ "profile": "minimal",
25
+ "description": "Scoped slice"
26
+ },
27
+ "legacy": {
28
+ "profile": "minimal",
29
+ "description": "Quarantined / legacy slice"
30
+ },
31
+ "narratives": {
32
+ "profile": "minimal",
33
+ "description": "Narrative records"
34
+ },
35
+ "narrative-steps": {
36
+ "profile": "minimal",
37
+ "description": "Narrative step records"
38
+ },
39
+ "workflow": {
40
+ "profile": "workflow",
41
+ "description": "Product workflow overlay (memorix-workflow/1) — not the snapshot envelope"
42
+ },
43
+ "extrated": {
44
+ "profile": "minimal",
45
+ "description": "Extracted document content (managed key spelling as in Catalox descriptors)"
46
+ },
47
+ "chunks": {
48
+ "profile": "minimal",
49
+ "description": "Document chunks"
50
+ },
51
+ "ai-processing": {
52
+ "profile": "minimal",
53
+ "description": "Product vocabulary — optional CT"
54
+ },
55
+ "context": {
56
+ "profile": "minimal",
57
+ "description": "Product vocabulary — optional CT"
58
+ },
59
+ "suggested-plans": {
60
+ "profile": "minimal",
61
+ "description": "Product vocabulary — optional CT"
62
+ },
63
+ "suggested-actions": {
64
+ "profile": "minimal",
65
+ "description": "Product vocabulary — optional CT"
66
+ },
67
+ "knowx": {
68
+ "profile": "minimal",
69
+ "description": "Native KnowX knowledge facet — data.kind NODE|EDGE; provenance (docHash + SourceSpan) mandatory; epistemic.state ≠ extraction confidence"
70
+ },
71
+ "nexum": {
72
+ "profile": "minimal",
73
+ "description": "Nexum contribution / node / claim records (write-record mode nexum)"
74
+ },
75
+ "confirmations": {
76
+ "profile": "minimal",
77
+ "description": "Accept/reject decision sibling for reviewed claims (e.g. KnowX assertions)"
78
+ }
79
+ }
80
+ }