@soulcraft/brainy 3.20.1 → 3.20.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 (91) hide show
  1. package/CHANGELOG.md +19 -0
  2. package/bin/brainy-interactive.js +2 -2
  3. package/dist/brainy.d.ts +1 -1
  4. package/dist/mcp/brainyMCPAdapter.d.ts +1 -1
  5. package/dist/mcp/brainyMCPService.d.ts +1 -1
  6. package/dist/neural/embeddedPatterns.d.ts +1 -1
  7. package/dist/neural/embeddedPatterns.js +1 -1
  8. package/dist/shared/default-augmentations.d.ts +1 -1
  9. package/dist/types/{brainyDataInterface.js → brainyInterface.js} +1 -1
  10. package/dist/vfs/VirtualFileSystem.d.ts +1 -0
  11. package/dist/vfs/VirtualFileSystem.js +108 -69
  12. package/package.json +1 -1
  13. package/dist/augmentationFactory.d.ts +0 -86
  14. package/dist/augmentationFactory.js +0 -342
  15. package/dist/augmentationRegistry.d.ts +0 -38
  16. package/dist/augmentationRegistry.js +0 -54
  17. package/dist/augmentationRegistryLoader.d.ts +0 -146
  18. package/dist/augmentationRegistryLoader.js +0 -213
  19. package/dist/augmentations/KnowledgeAugmentation.d.ts +0 -40
  20. package/dist/augmentations/KnowledgeAugmentation.js +0 -251
  21. package/dist/augmentations/intelligentVerbScoring.d.ts +0 -158
  22. package/dist/augmentations/intelligentVerbScoring.js +0 -377
  23. package/dist/augmentations/marketplace/AugmentationMarketplace.d.ts +0 -168
  24. package/dist/augmentations/marketplace/AugmentationMarketplace.js +0 -329
  25. package/dist/augmentations/marketplace/cli.d.ts +0 -47
  26. package/dist/augmentations/marketplace/cli.js +0 -265
  27. package/dist/augmentations/memoryAugmentations.d.ts +0 -72
  28. package/dist/augmentations/memoryAugmentations.js +0 -280
  29. package/dist/augmentations/serverSearchAugmentations.d.ts +0 -190
  30. package/dist/augmentations/serverSearchAugmentations.js +0 -586
  31. package/dist/brainy-unified.d.ts +0 -106
  32. package/dist/brainy-unified.js +0 -327
  33. package/dist/brainyData.d.ts +0 -1832
  34. package/dist/brainyData.js +0 -6443
  35. package/dist/brainyDataV3.d.ts +0 -186
  36. package/dist/brainyDataV3.js +0 -337
  37. package/dist/config/distributedPresets-new.d.ts +0 -118
  38. package/dist/config/distributedPresets-new.js +0 -318
  39. package/dist/config/modelPrecisionManager.d.ts +0 -42
  40. package/dist/config/modelPrecisionManager.js +0 -98
  41. package/dist/connectors/interfaces/IConnector.d.ts +0 -143
  42. package/dist/connectors/interfaces/IConnector.js +0 -8
  43. package/dist/demo.d.ts +0 -106
  44. package/dist/demo.js +0 -201
  45. package/dist/embeddings/SingletonModelManager.d.ts +0 -95
  46. package/dist/embeddings/SingletonModelManager.js +0 -220
  47. package/dist/embeddings/lightweight-embedder.d.ts +0 -22
  48. package/dist/embeddings/lightweight-embedder.js +0 -128
  49. package/dist/embeddings/model-manager.d.ts +0 -39
  50. package/dist/embeddings/model-manager.js +0 -245
  51. package/dist/embeddings/universal-memory-manager.d.ts +0 -38
  52. package/dist/embeddings/universal-memory-manager.js +0 -166
  53. package/dist/embeddings/worker-embedding.d.ts +0 -7
  54. package/dist/embeddings/worker-embedding.js +0 -73
  55. package/dist/embeddings/worker-manager.d.ts +0 -28
  56. package/dist/embeddings/worker-manager.js +0 -162
  57. package/dist/examples/basicUsage.d.ts +0 -4
  58. package/dist/examples/basicUsage.js +0 -121
  59. package/dist/indices/fieldIndex.d.ts +0 -76
  60. package/dist/indices/fieldIndex.js +0 -357
  61. package/dist/mcp/brainyMCPBroadcast.d.ts +0 -82
  62. package/dist/mcp/brainyMCPBroadcast.js +0 -303
  63. package/dist/mcp/brainyMCPClient.d.ts +0 -92
  64. package/dist/mcp/brainyMCPClient.js +0 -258
  65. package/dist/scripts/precomputePatternEmbeddings.d.ts +0 -19
  66. package/dist/scripts/precomputePatternEmbeddings.js +0 -100
  67. package/dist/utils/cacheAutoConfig.d.ts +0 -63
  68. package/dist/utils/cacheAutoConfig.js +0 -261
  69. package/dist/utils/hybridModelManager.d.ts +0 -64
  70. package/dist/utils/hybridModelManager.js +0 -95
  71. package/dist/utils/statistics.d.ts +0 -28
  72. package/dist/utils/statistics.js +0 -25
  73. package/dist/vfs/ConceptSystem.d.ts +0 -203
  74. package/dist/vfs/ConceptSystem.js +0 -545
  75. package/dist/vfs/EntityManager.d.ts +0 -75
  76. package/dist/vfs/EntityManager.js +0 -216
  77. package/dist/vfs/EventRecorder.d.ts +0 -84
  78. package/dist/vfs/EventRecorder.js +0 -269
  79. package/dist/vfs/GitBridge.d.ts +0 -167
  80. package/dist/vfs/GitBridge.js +0 -537
  81. package/dist/vfs/KnowledgeAugmentation.d.ts +0 -104
  82. package/dist/vfs/KnowledgeAugmentation.js +0 -146
  83. package/dist/vfs/KnowledgeLayer.d.ts +0 -35
  84. package/dist/vfs/KnowledgeLayer.js +0 -443
  85. package/dist/vfs/PersistentEntitySystem.d.ts +0 -165
  86. package/dist/vfs/PersistentEntitySystem.js +0 -503
  87. package/dist/vfs/SemanticVersioning.d.ts +0 -105
  88. package/dist/vfs/SemanticVersioning.js +0 -309
  89. package/dist/vfs/VFSHealthCheck.d.ts +0 -78
  90. package/dist/vfs/VFSHealthCheck.js +0 -299
  91. /package/dist/types/{brainyDataInterface.d.ts → brainyInterface.d.ts} +0 -0
@@ -1,186 +0,0 @@
1
- /**
2
- * BrainyData V3 - Consistent API Design
3
- *
4
- * This is a proposed update to BrainyData with consistent method signatures.
5
- * All methods use object parameters for consistency and extensibility.
6
- */
7
- import type { AddNounParams, AddVerbParams, SearchParams, SimilarityParams, RelatedParams, BatchNounsParams, BatchVerbsParams, GetNounsParams, GetVerbsParams, UpdateNounParams, MetadataParams, StatisticsParams, SearchResult, PaginatedResult, BatchResult, StatisticsResult } from './types/apiTypes.js';
8
- /**
9
- * Proposed consistent API for BrainyData
10
- * All methods use object parameters
11
- */
12
- export declare class BrainyDataV3 {
13
- constructor(config?: any);
14
- init(): Promise<void>;
15
- close(): Promise<void>;
16
- /**
17
- * Add a single noun
18
- * OLD: addNoun(data, type, metadata)
19
- * NEW: addNoun({ data, type, metadata })
20
- */
21
- addNoun(params: AddNounParams): Promise<string>;
22
- /**
23
- * Add multiple nouns in batch
24
- * NEW METHOD for better performance
25
- */
26
- addNouns(params: BatchNounsParams): Promise<BatchResult>;
27
- /**
28
- * Get a single noun by ID
29
- * OLD: getNoun(id)
30
- * NEW: getNoun(id) - unchanged, simple enough
31
- */
32
- getNoun(id: string): Promise<any | null>;
33
- /**
34
- * Get multiple nouns with filtering
35
- * NEW METHOD for batch retrieval
36
- */
37
- getNouns(params: GetNounsParams): Promise<PaginatedResult<any>>;
38
- /**
39
- * Update a noun
40
- * OLD: updateNoun(id, data, metadata) - scattered
41
- * NEW: updateNoun({ id, data, metadata })
42
- */
43
- updateNoun(params: UpdateNounParams): Promise<void>;
44
- /**
45
- * Delete a noun
46
- * OLD: deleteNoun(id)
47
- * NEW: deleteNoun(id) - unchanged, simple enough
48
- */
49
- deleteNoun(id: string): Promise<void>;
50
- /**
51
- * Add a single verb (relationship)
52
- * OLD: addVerb(source, target, type, metadata, weight)
53
- * NEW: addVerb({ source, target, type, weight, metadata })
54
- */
55
- addVerb(params: AddVerbParams): Promise<string>;
56
- /**
57
- * Add multiple verbs in batch
58
- * NEW METHOD for better performance
59
- */
60
- addVerbs(params: BatchVerbsParams): Promise<BatchResult>;
61
- /**
62
- * Get a single verb by ID
63
- * OLD: getVerb(id)
64
- * NEW: getVerb(id) - unchanged, simple enough
65
- */
66
- getVerb(id: string): Promise<any | null>;
67
- /**
68
- * Get multiple verbs with filtering
69
- * OLD: getVerbsBySource(id), getVerbsByTarget(id), etc.
70
- * NEW: getVerbs({ source?, target?, type? })
71
- */
72
- getVerbs(params: GetVerbsParams): Promise<PaginatedResult<any>>;
73
- /**
74
- * Delete a verb
75
- * OLD: deleteVerb(id)
76
- * NEW: deleteVerb(id) - unchanged, simple enough
77
- */
78
- deleteVerb(id: string): Promise<void>;
79
- /**
80
- * Unified search method
81
- * OLD: search(options), searchText(query, limit)
82
- * NEW: search({ query, limit, filter })
83
- */
84
- search(params: SearchParams): Promise<SearchResult[]>;
85
- /**
86
- * Find similar items
87
- * OLD: findSimilar(id, limit)
88
- * NEW: findSimilar({ id, limit, filter })
89
- */
90
- findSimilar(params: SimilarityParams): Promise<SearchResult[]>;
91
- /**
92
- * Find related items through graph traversal
93
- * OLD: getRelated(id, options)
94
- * NEW: findRelated({ id, depth, types })
95
- */
96
- findRelated(params: RelatedParams): Promise<PaginatedResult<any>>;
97
- /**
98
- * Get metadata for an entity
99
- * OLD: getMetadata(id)
100
- * NEW: getMetadata(id) - unchanged, simple enough
101
- */
102
- getMetadata(id: string): Promise<any | null>;
103
- /**
104
- * Update metadata for an entity
105
- * OLD: updateMetadata(id, metadata)
106
- * NEW: updateMetadata({ id, metadata, merge })
107
- */
108
- updateMetadata(params: MetadataParams): Promise<void>;
109
- /**
110
- * Get database statistics
111
- * OLD: getStatistics()
112
- * NEW: getStatistics({ detailed?, includeAugmentations? })
113
- */
114
- getStatistics(params?: StatisticsParams): Promise<StatisticsResult>;
115
- get neural(): {
116
- /**
117
- * Calculate similarity between two items
118
- * Already good: neural.similar(a, b)
119
- */
120
- similar: (a: any, b: any) => Promise<number>;
121
- /**
122
- * Cluster items semantically
123
- * Already good: neural.clusters(items?)
124
- */
125
- clusters: (items?: string[]) => Promise<any[]>;
126
- /**
127
- * Find nearest neighbors
128
- * Already good: neural.neighbors(id, { limit })
129
- */
130
- neighbors: (id: string, options?: any) => Promise<any[]>;
131
- /**
132
- * Build semantic hierarchy
133
- * Already good: neural.hierarchy(id)
134
- */
135
- hierarchy: (id: string) => Promise<any>;
136
- /**
137
- * Detect outliers
138
- * Already good: neural.outliers()
139
- */
140
- outliers: () => Promise<any[]>;
141
- /**
142
- * Get visualization data
143
- * Already good: neural.visualize()
144
- */
145
- visualize: () => Promise<any>;
146
- };
147
- get augmentations(): {
148
- add: (aug: any) => void;
149
- remove: (name: string) => void;
150
- get: (name: string) => null;
151
- execute: (op: string, params: any) => Promise<void>;
152
- getTypes: () => never[];
153
- };
154
- }
155
- /**
156
- * Migration wrapper for backward compatibility
157
- * This allows existing code to work with the new API
158
- */
159
- export declare class BrainyDataMigrationWrapper extends BrainyDataV3 {
160
- /**
161
- * OLD SIGNATURE: addNoun(data, type, metadata)
162
- * Wraps to NEW: addNoun({ data, type, metadata })
163
- */
164
- addNoun(dataOrParams: any | AddNounParams, type?: string, metadata?: any): Promise<string>;
165
- /**
166
- * OLD SIGNATURE: addVerb(source, target, type, metadata, weight)
167
- * Wraps to NEW: addVerb({ source, target, type, weight, metadata })
168
- */
169
- addVerb(sourceOrParams: string | AddVerbParams, target?: string, type?: string, metadata?: any, weight?: number): Promise<string>;
170
- /**
171
- * OLD SIGNATURE: searchText(query, limit)
172
- * Wraps to NEW: search({ query, limit })
173
- */
174
- searchText(query: string, limit?: number): Promise<SearchResult[]>;
175
- /**
176
- * OLD SIGNATURE: findSimilar(id, limit)
177
- * Wraps to NEW: findSimilar({ id, limit })
178
- */
179
- findSimilar(idOrParams: string | SimilarityParams, limit?: number): Promise<SearchResult[]>;
180
- /**
181
- * OLD METHODS: getVerbsBySource, getVerbsByTarget
182
- * Wraps to NEW: getVerbs({ source }) or getVerbs({ target })
183
- */
184
- getVerbsBySource(sourceId: string): Promise<any[]>;
185
- getVerbsByTarget(targetId: string): Promise<any[]>;
186
- }
@@ -1,337 +0,0 @@
1
- /**
2
- * BrainyData V3 - Consistent API Design
3
- *
4
- * This is a proposed update to BrainyData with consistent method signatures.
5
- * All methods use object parameters for consistency and extensibility.
6
- */
7
- /**
8
- * Proposed consistent API for BrainyData
9
- * All methods use object parameters
10
- */
11
- export class BrainyDataV3 {
12
- // ============= INITIALIZATION =============
13
- constructor(config) {
14
- // Same as before
15
- }
16
- async init() {
17
- // Same as before
18
- }
19
- async close() {
20
- // Same as before
21
- }
22
- // ============= NOUN OPERATIONS =============
23
- /**
24
- * Add a single noun
25
- * OLD: addNoun(data, type, metadata)
26
- * NEW: addNoun({ data, type, metadata })
27
- */
28
- async addNoun(params) {
29
- // Implementation
30
- return 'id';
31
- }
32
- /**
33
- * Add multiple nouns in batch
34
- * NEW METHOD for better performance
35
- */
36
- async addNouns(params) {
37
- // Implementation
38
- return {
39
- successful: [],
40
- failed: [],
41
- total: 0,
42
- duration: 0
43
- };
44
- }
45
- /**
46
- * Get a single noun by ID
47
- * OLD: getNoun(id)
48
- * NEW: getNoun(id) - unchanged, simple enough
49
- */
50
- async getNoun(id) {
51
- // Implementation
52
- return null;
53
- }
54
- /**
55
- * Get multiple nouns with filtering
56
- * NEW METHOD for batch retrieval
57
- */
58
- async getNouns(params) {
59
- // Implementation
60
- return {
61
- items: [],
62
- hasMore: false
63
- };
64
- }
65
- /**
66
- * Update a noun
67
- * OLD: updateNoun(id, data, metadata) - scattered
68
- * NEW: updateNoun({ id, data, metadata })
69
- */
70
- async updateNoun(params) {
71
- // Implementation
72
- }
73
- /**
74
- * Delete a noun
75
- * OLD: deleteNoun(id)
76
- * NEW: deleteNoun(id) - unchanged, simple enough
77
- */
78
- async deleteNoun(id) {
79
- // Implementation
80
- }
81
- // ============= VERB OPERATIONS =============
82
- /**
83
- * Add a single verb (relationship)
84
- * OLD: addVerb(source, target, type, metadata, weight)
85
- * NEW: addVerb({ source, target, type, weight, metadata })
86
- */
87
- async addVerb(params) {
88
- // Implementation
89
- return 'id';
90
- }
91
- /**
92
- * Add multiple verbs in batch
93
- * NEW METHOD for better performance
94
- */
95
- async addVerbs(params) {
96
- // Implementation
97
- return {
98
- successful: [],
99
- failed: [],
100
- total: 0,
101
- duration: 0
102
- };
103
- }
104
- /**
105
- * Get a single verb by ID
106
- * OLD: getVerb(id)
107
- * NEW: getVerb(id) - unchanged, simple enough
108
- */
109
- async getVerb(id) {
110
- // Implementation
111
- return null;
112
- }
113
- /**
114
- * Get multiple verbs with filtering
115
- * OLD: getVerbsBySource(id), getVerbsByTarget(id), etc.
116
- * NEW: getVerbs({ source?, target?, type? })
117
- */
118
- async getVerbs(params) {
119
- // Implementation
120
- return {
121
- items: [],
122
- hasMore: false
123
- };
124
- }
125
- /**
126
- * Delete a verb
127
- * OLD: deleteVerb(id)
128
- * NEW: deleteVerb(id) - unchanged, simple enough
129
- */
130
- async deleteVerb(id) {
131
- // Implementation
132
- }
133
- // ============= SEARCH OPERATIONS =============
134
- /**
135
- * Unified search method
136
- * OLD: search(options), searchText(query, limit)
137
- * NEW: search({ query, limit, filter })
138
- */
139
- async search(params) {
140
- // Implementation
141
- return [];
142
- }
143
- /**
144
- * Find similar items
145
- * OLD: findSimilar(id, limit)
146
- * NEW: findSimilar({ id, limit, filter })
147
- */
148
- async findSimilar(params) {
149
- // Implementation
150
- return [];
151
- }
152
- /**
153
- * Find related items through graph traversal
154
- * OLD: getRelated(id, options)
155
- * NEW: findRelated({ id, depth, types })
156
- */
157
- async findRelated(params) {
158
- // Implementation
159
- return {
160
- items: [],
161
- hasMore: false
162
- };
163
- }
164
- // ============= METADATA OPERATIONS =============
165
- /**
166
- * Get metadata for an entity
167
- * OLD: getMetadata(id)
168
- * NEW: getMetadata(id) - unchanged, simple enough
169
- */
170
- async getMetadata(id) {
171
- // Implementation
172
- return null;
173
- }
174
- /**
175
- * Update metadata for an entity
176
- * OLD: updateMetadata(id, metadata)
177
- * NEW: updateMetadata({ id, metadata, merge })
178
- */
179
- async updateMetadata(params) {
180
- // Implementation
181
- }
182
- // ============= STATISTICS =============
183
- /**
184
- * Get database statistics
185
- * OLD: getStatistics()
186
- * NEW: getStatistics({ detailed?, includeAugmentations? })
187
- */
188
- async getStatistics(params) {
189
- // Implementation
190
- return {
191
- nouns: { total: 0, byType: {} },
192
- verbs: { total: 0, byType: {} },
193
- storage: { used: 0, type: 'memory' }
194
- };
195
- }
196
- // ============= NEURAL API (unchanged - already good) =============
197
- get neural() {
198
- return {
199
- /**
200
- * Calculate similarity between two items
201
- * Already good: neural.similar(a, b)
202
- */
203
- similar: async (a, b) => {
204
- // Implementation
205
- return 0;
206
- },
207
- /**
208
- * Cluster items semantically
209
- * Already good: neural.clusters(items?)
210
- */
211
- clusters: async (items) => {
212
- // Implementation
213
- return [];
214
- },
215
- /**
216
- * Find nearest neighbors
217
- * Already good: neural.neighbors(id, { limit })
218
- */
219
- neighbors: async (id, options) => {
220
- // Implementation
221
- return [];
222
- },
223
- /**
224
- * Build semantic hierarchy
225
- * Already good: neural.hierarchy(id)
226
- */
227
- hierarchy: async (id) => {
228
- // Implementation
229
- return {};
230
- },
231
- /**
232
- * Detect outliers
233
- * Already good: neural.outliers()
234
- */
235
- outliers: async () => {
236
- // Implementation
237
- return [];
238
- },
239
- /**
240
- * Get visualization data
241
- * Already good: neural.visualize()
242
- */
243
- visualize: async () => {
244
- // Implementation
245
- return {};
246
- }
247
- };
248
- }
249
- // ============= AUGMENTATIONS (unchanged - already consistent) =============
250
- get augmentations() {
251
- return {
252
- add: (aug) => { },
253
- remove: (name) => { },
254
- get: (name) => null,
255
- execute: async (op, params) => { },
256
- getTypes: () => []
257
- };
258
- }
259
- }
260
- /**
261
- * Migration wrapper for backward compatibility
262
- * This allows existing code to work with the new API
263
- */
264
- export class BrainyDataMigrationWrapper extends BrainyDataV3 {
265
- /**
266
- * OLD SIGNATURE: addNoun(data, type, metadata)
267
- * Wraps to NEW: addNoun({ data, type, metadata })
268
- */
269
- async addNoun(dataOrParams, type, metadata) {
270
- // If called with object params (new style)
271
- if (arguments.length === 1 && typeof dataOrParams === 'object' && 'type' in dataOrParams) {
272
- return super.addNoun(dataOrParams);
273
- }
274
- // If called with positional params (old style)
275
- console.warn('Deprecated: Use addNoun({ data, type, metadata }) instead');
276
- return super.addNoun({
277
- data: dataOrParams,
278
- type: type,
279
- metadata
280
- });
281
- }
282
- /**
283
- * OLD SIGNATURE: addVerb(source, target, type, metadata, weight)
284
- * Wraps to NEW: addVerb({ source, target, type, weight, metadata })
285
- */
286
- async addVerb(sourceOrParams, target, type, metadata, weight) {
287
- // If called with object params (new style)
288
- if (arguments.length === 1 && typeof sourceOrParams === 'object' && 'source' in sourceOrParams) {
289
- return super.addVerb(sourceOrParams);
290
- }
291
- // If called with positional params (old style)
292
- console.warn('Deprecated: Use addVerb({ source, target, type, weight, metadata }) instead');
293
- return super.addVerb({
294
- source: sourceOrParams,
295
- target: target,
296
- type: type,
297
- weight,
298
- metadata
299
- });
300
- }
301
- /**
302
- * OLD SIGNATURE: searchText(query, limit)
303
- * Wraps to NEW: search({ query, limit })
304
- */
305
- async searchText(query, limit) {
306
- console.warn('Deprecated: Use search({ query, limit }) instead');
307
- return this.search({ query, limit });
308
- }
309
- /**
310
- * OLD SIGNATURE: findSimilar(id, limit)
311
- * Wraps to NEW: findSimilar({ id, limit })
312
- */
313
- async findSimilar(idOrParams, limit) {
314
- // If called with object params (new style)
315
- if (typeof idOrParams === 'object') {
316
- return super.findSimilar(idOrParams);
317
- }
318
- // If called with positional params (old style)
319
- console.warn('Deprecated: Use findSimilar({ id, limit }) instead');
320
- return super.findSimilar({ id: idOrParams, limit });
321
- }
322
- /**
323
- * OLD METHODS: getVerbsBySource, getVerbsByTarget
324
- * Wraps to NEW: getVerbs({ source }) or getVerbs({ target })
325
- */
326
- async getVerbsBySource(sourceId) {
327
- console.warn('Deprecated: Use getVerbs({ source }) instead');
328
- const result = await this.getVerbs({ source: sourceId });
329
- return result.items;
330
- }
331
- async getVerbsByTarget(targetId) {
332
- console.warn('Deprecated: Use getVerbs({ target }) instead');
333
- const result = await this.getVerbs({ target: targetId });
334
- return result.items;
335
- }
336
- }
337
- //# sourceMappingURL=brainyDataV3.js.map
@@ -1,118 +0,0 @@
1
- /**
2
- * Extended Distributed Configuration Presets
3
- * Common patterns for distributed and multi-service architectures
4
- * All strongly typed with enums for compile-time safety
5
- */
6
- /**
7
- * Strongly typed enum for preset names
8
- */
9
- export declare enum PresetName {
10
- PRODUCTION = "production",
11
- DEVELOPMENT = "development",
12
- MINIMAL = "minimal",
13
- ZERO = "zero",
14
- WRITER = "writer",
15
- READER = "reader",
16
- INGESTION_SERVICE = "ingestion-service",
17
- SEARCH_API = "search-api",
18
- ANALYTICS_SERVICE = "analytics-service",
19
- EDGE_CACHE = "edge-cache",
20
- BATCH_PROCESSOR = "batch-processor",
21
- STREAMING_SERVICE = "streaming-service",
22
- ML_TRAINING = "ml-training",
23
- SIDECAR = "sidecar"
24
- }
25
- /**
26
- * Preset categories for organization
27
- */
28
- export declare enum PresetCategory {
29
- BASIC = "basic",
30
- DISTRIBUTED = "distributed",
31
- SERVICE = "service"
32
- }
33
- /**
34
- * Model precision options
35
- */
36
- export declare enum ModelPrecision {
37
- FP32 = "fp32",
38
- Q8 = "q8",
39
- AUTO = "auto",
40
- FAST = "fast",
41
- SMALL = "small"
42
- }
43
- /**
44
- * Storage options
45
- */
46
- export declare enum StorageOption {
47
- AUTO = "auto",
48
- MEMORY = "memory",
49
- DISK = "disk",
50
- CLOUD = "cloud"
51
- }
52
- /**
53
- * Feature set options
54
- */
55
- export declare enum FeatureSet {
56
- MINIMAL = "minimal",
57
- DEFAULT = "default",
58
- FULL = "full",
59
- CUSTOM = "custom"
60
- }
61
- /**
62
- * Distributed role options
63
- */
64
- export declare enum DistributedRole {
65
- WRITER = "writer",
66
- READER = "reader",
67
- HYBRID = "hybrid"
68
- }
69
- /**
70
- * Preset configuration interface
71
- */
72
- export interface PresetConfig {
73
- storage: StorageOption;
74
- model: ModelPrecision;
75
- features: FeatureSet | string[];
76
- distributed: boolean;
77
- role?: DistributedRole;
78
- readOnly?: boolean;
79
- writeOnly?: boolean;
80
- allowDirectReads?: boolean;
81
- lazyLoadInReadOnlyMode?: boolean;
82
- cache?: {
83
- hotCacheMaxSize?: number;
84
- autoTune?: boolean;
85
- batchSize?: number;
86
- };
87
- verbose?: boolean;
88
- description: string;
89
- category: PresetCategory;
90
- }
91
- /**
92
- * Strongly typed preset configurations
93
- */
94
- export declare const PRESET_CONFIGS: Readonly<Record<PresetName, PresetConfig>>;
95
- /**
96
- * Type-safe preset getter
97
- */
98
- export declare function getPreset(name: PresetName): PresetConfig;
99
- /**
100
- * Check if a string is a valid preset name
101
- */
102
- export declare function isValidPreset(name: string): name is PresetName;
103
- /**
104
- * Get presets by category
105
- */
106
- export declare function getPresetsByCategory(category: PresetCategory): PresetName[];
107
- /**
108
- * Get all preset names
109
- */
110
- export declare function getAllPresetNames(): PresetName[];
111
- /**
112
- * Get preset description
113
- */
114
- export declare function getPresetDescription(name: PresetName): string;
115
- /**
116
- * Convert preset config to Brainy config
117
- */
118
- export declare function presetToBrainyConfig(preset: PresetConfig): any;