@x12i/memorix-scoper-contracts 2.0.0 → 2.1.0

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 (45) hide show
  1. package/dist/index.d.ts +1 -1
  2. package/dist/index.d.ts.map +1 -1
  3. package/dist/index.js +1 -1
  4. package/dist/index.js.map +1 -1
  5. package/dist/project-record.d.ts +9 -0
  6. package/dist/project-record.d.ts.map +1 -1
  7. package/dist/project-record.js +13 -0
  8. package/dist/project-record.js.map +1 -1
  9. package/dist/schemas/index.d.ts +1 -1
  10. package/dist/schemas/index.d.ts.map +1 -1
  11. package/dist/schemas/index.js +1 -1
  12. package/dist/schemas/index.js.map +1 -1
  13. package/dist/schemas/profile.d.ts +2 -2
  14. package/dist/schemas/request.d.ts +258 -0
  15. package/dist/schemas/request.d.ts.map +1 -1
  16. package/dist/schemas/request.js +105 -0
  17. package/dist/schemas/request.js.map +1 -1
  18. package/package.json +4 -4
  19. package/schemas/CatalogEntry.json +67 -17
  20. package/schemas/CatalogEntry.schema.json +157 -157
  21. package/schemas/EvidenceBundle.json +315 -15
  22. package/schemas/EvidenceBundle.schema.json +469 -469
  23. package/schemas/EvidenceItem.json +156 -15
  24. package/schemas/EvidenceRef.json +113 -9
  25. package/schemas/EvidenceSelection.schema.json +83 -83
  26. package/schemas/IntentScopeRequest.json +24 -0
  27. package/schemas/IntentScopeResponse.json +119 -0
  28. package/schemas/RetrievalPlan.json +221 -13
  29. package/schemas/RetrievalPlan.schema.json +73 -73
  30. package/schemas/RetrievalStep.json +51 -14
  31. package/schemas/ScopeIntent.json +84 -0
  32. package/schemas/ScopeRequest.json +151 -28
  33. package/schemas/ScopeRequest.schema.json +108 -108
  34. package/schemas/ScoperBudgets.json +48 -14
  35. package/schemas/ScoperProfile.json +114 -17
  36. package/schemas/TrustedExecutionContext.json +57 -22
  37. package/schemas/TrustedExecutionContext.schema.json +129 -129
  38. package/dist/schemas.d.ts +0 -1077
  39. package/dist/schemas.d.ts.map +0 -1
  40. package/dist/schemas.js +0 -199
  41. package/dist/schemas.js.map +0 -1
  42. package/dist/schemas.test.d.ts +0 -2
  43. package/dist/schemas.test.d.ts.map +0 -1
  44. package/dist/schemas.test.js +0 -29
  45. package/dist/schemas.test.js.map +0 -1
@@ -1,28 +1,151 @@
1
- {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "$ref": "#/definitions/ScopeRequest",
4
- "definitions": {
5
- "ScopeRequest": {
6
- "type": "object",
7
- "properties": {
8
- "profileId": { "type": "string", "minLength": 1 },
9
- "question": { "type": "string", "minLength": 1, "maxLength": 16000 },
10
- "focus": {
11
- "type": "object",
12
- "properties": {
13
- "subjectIds": { "type": "array", "items": { "type": "string" } },
14
- "objectTypes": { "type": "array", "items": { "type": "string" } },
15
- "contentTypes": { "type": "array", "items": { "type": "string" } },
16
- "tags": { "type": "array", "items": { "type": "string" } }
17
- },
18
- "additionalProperties": false
19
- },
20
- "budgets": { "type": "object", "additionalProperties": true },
21
- "options": { "type": "object", "additionalProperties": true },
22
- "hints": { "type": "object", "additionalProperties": true }
23
- },
24
- "required": ["profileId", "question"],
25
- "additionalProperties": false
26
- }
27
- }
28
- }
1
+ {
2
+ "$ref": "#/definitions/ScopeRequest",
3
+ "definitions": {
4
+ "ScopeRequest": {
5
+ "type": "object",
6
+ "properties": {
7
+ "profileId": {
8
+ "type": "string",
9
+ "minLength": 1
10
+ },
11
+ "question": {
12
+ "type": "string",
13
+ "minLength": 1,
14
+ "maxLength": 16000
15
+ },
16
+ "objective": {
17
+ "type": "string",
18
+ "minLength": 1,
19
+ "maxLength": 4000
20
+ },
21
+ "focus": {
22
+ "type": "object",
23
+ "properties": {
24
+ "subjectIds": {
25
+ "type": "array",
26
+ "items": {
27
+ "type": "string"
28
+ }
29
+ },
30
+ "objectTypes": {
31
+ "type": "array",
32
+ "items": {
33
+ "type": "string"
34
+ }
35
+ },
36
+ "contentTypes": {
37
+ "type": "array",
38
+ "items": {
39
+ "type": "string"
40
+ }
41
+ },
42
+ "tags": {
43
+ "type": "array",
44
+ "items": {
45
+ "type": "string"
46
+ }
47
+ }
48
+ },
49
+ "additionalProperties": false
50
+ },
51
+ "budgets": {
52
+ "type": "object",
53
+ "properties": {
54
+ "maxSubjects": {
55
+ "type": "integer",
56
+ "exclusiveMinimum": 0,
57
+ "maximum": 10000,
58
+ "default": 100
59
+ },
60
+ "maxEvidenceItems": {
61
+ "type": "integer",
62
+ "exclusiveMinimum": 0,
63
+ "maximum": 10000,
64
+ "default": 200
65
+ },
66
+ "maxParallelCalls": {
67
+ "type": "integer",
68
+ "exclusiveMinimum": 0,
69
+ "maximum": 64,
70
+ "default": 8
71
+ },
72
+ "maxTokens": {
73
+ "type": "integer",
74
+ "exclusiveMinimum": 0,
75
+ "maximum": 2000000,
76
+ "default": 32000
77
+ },
78
+ "maxWallClockMs": {
79
+ "type": "integer",
80
+ "exclusiveMinimum": 0,
81
+ "maximum": 600000,
82
+ "default": 60000
83
+ },
84
+ "maxEstateSessions": {
85
+ "type": "integer",
86
+ "minimum": 0,
87
+ "maximum": 32,
88
+ "default": 2
89
+ }
90
+ },
91
+ "additionalProperties": false
92
+ },
93
+ "options": {
94
+ "type": "object",
95
+ "properties": {
96
+ "allowExplore": {
97
+ "type": "boolean"
98
+ },
99
+ "dryRun": {
100
+ "type": "boolean"
101
+ },
102
+ "includeUnknowns": {
103
+ "type": "boolean"
104
+ },
105
+ "include": {
106
+ "type": "object",
107
+ "properties": {
108
+ "markdown": {
109
+ "type": "boolean"
110
+ }
111
+ },
112
+ "additionalProperties": false
113
+ },
114
+ "applyAiMarkdown": {
115
+ "type": "boolean"
116
+ },
117
+ "synthesize": {
118
+ "type": "boolean"
119
+ },
120
+ "properties": {
121
+ "type": "array",
122
+ "items": {
123
+ "type": "string",
124
+ "minLength": 1,
125
+ "maxLength": 200
126
+ },
127
+ "maxItems": 64
128
+ },
129
+ "exclude": {
130
+ "$ref": "#/definitions/ScopeRequest/properties/options/properties/properties"
131
+ },
132
+ "useMarkdown": {
133
+ "type": "boolean"
134
+ }
135
+ },
136
+ "additionalProperties": false
137
+ },
138
+ "hints": {
139
+ "type": "object",
140
+ "additionalProperties": {}
141
+ }
142
+ },
143
+ "required": [
144
+ "profileId",
145
+ "question"
146
+ ],
147
+ "additionalProperties": false
148
+ }
149
+ },
150
+ "$schema": "http://json-schema.org/draft-07/schema#"
151
+ }
@@ -1,108 +1,108 @@
1
- {
2
- "$ref": "#/definitions/ScopeRequest",
3
- "definitions": {
4
- "ScopeRequest": {
5
- "type": "object",
6
- "properties": {
7
- "objective": {
8
- "type": "string",
9
- "minLength": 1,
10
- "maxLength": 4000
11
- },
12
- "seeds": {
13
- "type": "array",
14
- "items": {
15
- "type": "object",
16
- "properties": {
17
- "kind": {
18
- "type": "string",
19
- "minLength": 1,
20
- "maxLength": 128
21
- },
22
- "id": {
23
- "type": "string",
24
- "minLength": 1,
25
- "maxLength": 256
26
- }
27
- },
28
- "required": [
29
- "kind",
30
- "id"
31
- ],
32
- "additionalProperties": false
33
- },
34
- "maxItems": 50
35
- },
36
- "domains": {
37
- "type": "array",
38
- "items": {
39
- "type": "string",
40
- "minLength": 1,
41
- "maxLength": 128
42
- },
43
- "maxItems": 20
44
- },
45
- "timeRange": {
46
- "type": "object",
47
- "properties": {
48
- "from": {
49
- "type": "string",
50
- "format": "date-time"
51
- },
52
- "to": {
53
- "type": "string",
54
- "format": "date-time"
55
- }
56
- },
57
- "required": [
58
- "from",
59
- "to"
60
- ],
61
- "additionalProperties": false
62
- },
63
- "freshness": {
64
- "type": "object",
65
- "properties": {
66
- "includeStable": {
67
- "type": "boolean"
68
- },
69
- "includeLive": {
70
- "type": "boolean"
71
- }
72
- },
73
- "additionalProperties": false
74
- },
75
- "requestedLimits": {
76
- "type": "object",
77
- "properties": {
78
- "maxEvidenceItems": {
79
- "type": "integer",
80
- "exclusiveMinimum": 0,
81
- "maximum": 10000
82
- },
83
- "maxRelationshipDepth": {
84
- "type": "integer",
85
- "minimum": 0,
86
- "maximum": 32
87
- },
88
- "deadlineMs": {
89
- "type": "integer",
90
- "exclusiveMinimum": 0,
91
- "maximum": 600000
92
- }
93
- },
94
- "additionalProperties": false
95
- },
96
- "responseMode": {
97
- "type": "string",
98
- "const": "evidence-bundle"
99
- }
100
- },
101
- "required": [
102
- "objective"
103
- ],
104
- "additionalProperties": false
105
- }
106
- },
107
- "$schema": "http://json-schema.org/draft-07/schema#"
108
- }
1
+ {
2
+ "$ref": "#/definitions/ScopeRequest",
3
+ "definitions": {
4
+ "ScopeRequest": {
5
+ "type": "object",
6
+ "properties": {
7
+ "objective": {
8
+ "type": "string",
9
+ "minLength": 1,
10
+ "maxLength": 4000
11
+ },
12
+ "seeds": {
13
+ "type": "array",
14
+ "items": {
15
+ "type": "object",
16
+ "properties": {
17
+ "kind": {
18
+ "type": "string",
19
+ "minLength": 1,
20
+ "maxLength": 128
21
+ },
22
+ "id": {
23
+ "type": "string",
24
+ "minLength": 1,
25
+ "maxLength": 256
26
+ }
27
+ },
28
+ "required": [
29
+ "kind",
30
+ "id"
31
+ ],
32
+ "additionalProperties": false
33
+ },
34
+ "maxItems": 50
35
+ },
36
+ "domains": {
37
+ "type": "array",
38
+ "items": {
39
+ "type": "string",
40
+ "minLength": 1,
41
+ "maxLength": 128
42
+ },
43
+ "maxItems": 20
44
+ },
45
+ "timeRange": {
46
+ "type": "object",
47
+ "properties": {
48
+ "from": {
49
+ "type": "string",
50
+ "format": "date-time"
51
+ },
52
+ "to": {
53
+ "type": "string",
54
+ "format": "date-time"
55
+ }
56
+ },
57
+ "required": [
58
+ "from",
59
+ "to"
60
+ ],
61
+ "additionalProperties": false
62
+ },
63
+ "freshness": {
64
+ "type": "object",
65
+ "properties": {
66
+ "includeStable": {
67
+ "type": "boolean"
68
+ },
69
+ "includeLive": {
70
+ "type": "boolean"
71
+ }
72
+ },
73
+ "additionalProperties": false
74
+ },
75
+ "requestedLimits": {
76
+ "type": "object",
77
+ "properties": {
78
+ "maxEvidenceItems": {
79
+ "type": "integer",
80
+ "exclusiveMinimum": 0,
81
+ "maximum": 10000
82
+ },
83
+ "maxRelationshipDepth": {
84
+ "type": "integer",
85
+ "minimum": 0,
86
+ "maximum": 32
87
+ },
88
+ "deadlineMs": {
89
+ "type": "integer",
90
+ "exclusiveMinimum": 0,
91
+ "maximum": 600000
92
+ }
93
+ },
94
+ "additionalProperties": false
95
+ },
96
+ "responseMode": {
97
+ "type": "string",
98
+ "const": "evidence-bundle"
99
+ }
100
+ },
101
+ "required": [
102
+ "objective"
103
+ ],
104
+ "additionalProperties": false
105
+ }
106
+ },
107
+ "$schema": "http://json-schema.org/draft-07/schema#"
108
+ }
@@ -1,14 +1,48 @@
1
- {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "title": "ScoperBudgets",
4
- "type": "object",
5
- "properties": {
6
- "maxSubjects": { "type": "integer" },
7
- "maxEvidenceItems": { "type": "integer" },
8
- "maxParallelCalls": { "type": "integer" },
9
- "maxTokens": { "type": "integer" },
10
- "maxWallClockMs": { "type": "integer" },
11
- "maxEstateSessions": { "type": "integer" }
12
- },
13
- "additionalProperties": false
14
- }
1
+ {
2
+ "$ref": "#/definitions/ScoperBudgets",
3
+ "definitions": {
4
+ "ScoperBudgets": {
5
+ "type": "object",
6
+ "properties": {
7
+ "maxSubjects": {
8
+ "type": "integer",
9
+ "exclusiveMinimum": 0,
10
+ "maximum": 10000,
11
+ "default": 100
12
+ },
13
+ "maxEvidenceItems": {
14
+ "type": "integer",
15
+ "exclusiveMinimum": 0,
16
+ "maximum": 10000,
17
+ "default": 200
18
+ },
19
+ "maxParallelCalls": {
20
+ "type": "integer",
21
+ "exclusiveMinimum": 0,
22
+ "maximum": 64,
23
+ "default": 8
24
+ },
25
+ "maxTokens": {
26
+ "type": "integer",
27
+ "exclusiveMinimum": 0,
28
+ "maximum": 2000000,
29
+ "default": 32000
30
+ },
31
+ "maxWallClockMs": {
32
+ "type": "integer",
33
+ "exclusiveMinimum": 0,
34
+ "maximum": 600000,
35
+ "default": 60000
36
+ },
37
+ "maxEstateSessions": {
38
+ "type": "integer",
39
+ "minimum": 0,
40
+ "maximum": 32,
41
+ "default": 2
42
+ }
43
+ },
44
+ "additionalProperties": false
45
+ }
46
+ },
47
+ "$schema": "http://json-schema.org/draft-07/schema#"
48
+ }
@@ -1,17 +1,114 @@
1
- {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "title": "ScoperProfile",
4
- "type": "object",
5
- "properties": {
6
- "id": { "type": "string" },
7
- "version": { "type": "string" },
8
- "title": { "type": "string" },
9
- "description": { "type": "string" },
10
- "allowedCapabilities": { "type": "array", "items": { "type": "string" } },
11
- "defaultBudgets": { "type": "object" },
12
- "systemPrompt": { "type": "string" },
13
- "epistemicRules": { "type": "array", "items": { "type": "string" } },
14
- "tags": { "type": "array", "items": { "type": "string" } }
15
- },
16
- "required": ["id", "version", "title", "description", "allowedCapabilities", "systemPrompt"]
17
- }
1
+ {
2
+ "$ref": "#/definitions/ScoperProfile",
3
+ "definitions": {
4
+ "ScoperProfile": {
5
+ "type": "object",
6
+ "properties": {
7
+ "id": {
8
+ "type": "string",
9
+ "minLength": 1
10
+ },
11
+ "version": {
12
+ "type": "string",
13
+ "minLength": 1
14
+ },
15
+ "title": {
16
+ "type": "string",
17
+ "minLength": 1
18
+ },
19
+ "description": {
20
+ "type": "string",
21
+ "minLength": 1
22
+ },
23
+ "allowedCapabilities": {
24
+ "type": "array",
25
+ "items": {
26
+ "type": "string",
27
+ "enum": [
28
+ "subjects.get",
29
+ "subjects.list",
30
+ "subjects.query",
31
+ "subjects.getNexumSnapshot",
32
+ "estate.startSession",
33
+ "estate.getBag",
34
+ "estate.query",
35
+ "explore.query",
36
+ "catalog.describe"
37
+ ]
38
+ },
39
+ "minItems": 1
40
+ },
41
+ "defaultBudgets": {
42
+ "type": "object",
43
+ "properties": {
44
+ "maxSubjects": {
45
+ "type": "integer",
46
+ "exclusiveMinimum": 0,
47
+ "maximum": 10000,
48
+ "default": 100
49
+ },
50
+ "maxEvidenceItems": {
51
+ "type": "integer",
52
+ "exclusiveMinimum": 0,
53
+ "maximum": 10000,
54
+ "default": 200
55
+ },
56
+ "maxParallelCalls": {
57
+ "type": "integer",
58
+ "exclusiveMinimum": 0,
59
+ "maximum": 64,
60
+ "default": 8
61
+ },
62
+ "maxTokens": {
63
+ "type": "integer",
64
+ "exclusiveMinimum": 0,
65
+ "maximum": 2000000,
66
+ "default": 32000
67
+ },
68
+ "maxWallClockMs": {
69
+ "type": "integer",
70
+ "exclusiveMinimum": 0,
71
+ "maximum": 600000,
72
+ "default": 60000
73
+ },
74
+ "maxEstateSessions": {
75
+ "type": "integer",
76
+ "minimum": 0,
77
+ "maximum": 32,
78
+ "default": 2
79
+ }
80
+ },
81
+ "additionalProperties": false
82
+ },
83
+ "systemPrompt": {
84
+ "type": "string",
85
+ "minLength": 1
86
+ },
87
+ "epistemicRules": {
88
+ "type": "array",
89
+ "items": {
90
+ "type": "string"
91
+ },
92
+ "default": []
93
+ },
94
+ "tags": {
95
+ "type": "array",
96
+ "items": {
97
+ "type": "string"
98
+ },
99
+ "default": []
100
+ }
101
+ },
102
+ "required": [
103
+ "id",
104
+ "version",
105
+ "title",
106
+ "description",
107
+ "allowedCapabilities",
108
+ "systemPrompt"
109
+ ],
110
+ "additionalProperties": false
111
+ }
112
+ },
113
+ "$schema": "http://json-schema.org/draft-07/schema#"
114
+ }
@@ -1,22 +1,57 @@
1
- {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "title": "TrustedExecutionContext",
4
- "type": "object",
5
- "properties": {
6
- "orgId": { "type": "string", "minLength": 1 },
7
- "agentIds": { "type": "array", "items": { "type": "string", "minLength": 1 }, "minItems": 1 },
8
- "caller": { "type": "string", "minLength": 1 },
9
- "traceId": { "type": "string", "minLength": 1 },
10
- "correlationId": { "type": "string", "minLength": 1 },
11
- "identity": {
12
- "type": "object",
13
- "properties": {
14
- "subject": { "type": "string" },
15
- "roles": { "type": "array", "items": { "type": "string" } }
16
- },
17
- "additionalProperties": false
18
- }
19
- },
20
- "required": ["orgId", "agentIds", "caller", "traceId"],
21
- "additionalProperties": false
22
- }
1
+ {
2
+ "$ref": "#/definitions/TrustedExecutionContext",
3
+ "definitions": {
4
+ "TrustedExecutionContext": {
5
+ "type": "object",
6
+ "properties": {
7
+ "orgId": {
8
+ "type": "string",
9
+ "minLength": 1
10
+ },
11
+ "agentIds": {
12
+ "type": "array",
13
+ "items": {
14
+ "type": "string",
15
+ "minLength": 1
16
+ },
17
+ "minItems": 1
18
+ },
19
+ "caller": {
20
+ "type": "string",
21
+ "minLength": 1
22
+ },
23
+ "traceId": {
24
+ "type": "string",
25
+ "minLength": 1
26
+ },
27
+ "correlationId": {
28
+ "type": "string",
29
+ "minLength": 1
30
+ },
31
+ "identity": {
32
+ "type": "object",
33
+ "properties": {
34
+ "subject": {
35
+ "type": "string"
36
+ },
37
+ "roles": {
38
+ "type": "array",
39
+ "items": {
40
+ "type": "string"
41
+ }
42
+ }
43
+ },
44
+ "additionalProperties": false
45
+ }
46
+ },
47
+ "required": [
48
+ "orgId",
49
+ "agentIds",
50
+ "caller",
51
+ "traceId"
52
+ ],
53
+ "additionalProperties": false
54
+ }
55
+ },
56
+ "$schema": "http://json-schema.org/draft-07/schema#"
57
+ }