@soulcraft/brainy 0.19.0 → 0.21.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.
- package/README.md +8 -3
- package/dist/augmentations/conduitAugmentations.js +1158 -0
- package/dist/augmentations/conduitAugmentations.js.map +1 -0
- package/dist/augmentations/memoryAugmentations.js +255 -0
- package/dist/augmentations/memoryAugmentations.js.map +1 -0
- package/dist/augmentations/serverSearchAugmentations.js +531 -0
- package/dist/augmentations/serverSearchAugmentations.js.map +1 -0
- package/dist/brainy.js +508 -42
- package/dist/brainy.min.js +750 -750
- package/dist/brainyData.d.ts +58 -4
- package/dist/coreTypes.d.ts +54 -0
- package/dist/examples/basicUsage.js +128 -0
- package/dist/examples/basicUsage.js.map +1 -0
- package/dist/hnsw/hnswIndex.js +550 -0
- package/dist/hnsw/hnswIndex.js.map +1 -0
- package/dist/hnsw/hnswIndexOptimized.js +441 -0
- package/dist/hnsw/hnswIndexOptimized.js.map +1 -0
- package/dist/mcp/brainyMCPAdapter.js +142 -0
- package/dist/mcp/brainyMCPAdapter.js.map +1 -0
- package/dist/mcp/brainyMCPService.js +248 -0
- package/dist/mcp/brainyMCPService.js.map +1 -0
- package/dist/mcp/index.js +17 -0
- package/dist/mcp/index.js.map +1 -0
- package/dist/mcp/mcpAugmentationToolset.js +180 -0
- package/dist/mcp/mcpAugmentationToolset.js.map +1 -0
- package/dist/storage/adapters/baseStorageAdapter.d.ts +82 -0
- package/dist/storage/adapters/baseStorageAdapter.d.ts.map +1 -0
- package/dist/storage/adapters/baseStorageAdapter.js +233 -0
- package/dist/storage/adapters/baseStorageAdapter.js.map +1 -0
- package/dist/storage/adapters/fileSystemStorage.d.ts +11 -1
- package/dist/storage/adapters/fileSystemStorage.d.ts.map +1 -1
- package/dist/storage/adapters/fileSystemStorage.js +568 -0
- package/dist/storage/adapters/fileSystemStorage.js.map +1 -0
- package/dist/storage/adapters/memoryStorage.d.ts +12 -1
- package/dist/storage/adapters/memoryStorage.d.ts.map +1 -1
- package/dist/storage/adapters/memoryStorage.js +300 -0
- package/dist/storage/adapters/memoryStorage.js.map +1 -0
- package/dist/storage/adapters/opfsStorage.d.ts +28 -1
- package/dist/storage/adapters/opfsStorage.d.ts.map +1 -1
- package/dist/storage/adapters/opfsStorage.js +778 -0
- package/dist/storage/adapters/opfsStorage.js.map +1 -0
- package/dist/storage/adapters/s3CompatibleStorage.d.ts +47 -1
- package/dist/storage/adapters/s3CompatibleStorage.d.ts.map +1 -1
- package/dist/storage/adapters/s3CompatibleStorage.js +1021 -0
- package/dist/storage/adapters/s3CompatibleStorage.js.map +1 -0
- package/dist/storage/baseStorage.d.ts +16 -2
- package/dist/storage/baseStorage.d.ts.map +1 -1
- package/dist/storage/baseStorage.js +126 -0
- package/dist/storage/baseStorage.js.map +1 -0
- package/dist/storage/fileSystemStorage.d.ts +15 -2
- package/dist/storage/fileSystemStorage.d.ts.map +1 -1
- package/dist/storage/opfsStorage.d.ts +66 -3
- package/dist/storage/opfsStorage.d.ts.map +1 -1
- package/dist/storage/s3CompatibleStorage.d.ts +14 -2
- package/dist/storage/s3CompatibleStorage.d.ts.map +1 -1
- package/dist/storage/storageFactory.js +183 -0
- package/dist/storage/storageFactory.js.map +1 -0
- package/dist/types/augmentations.js +16 -0
- package/dist/types/augmentations.js.map +1 -0
- package/dist/types/brainyDataInterface.js +8 -0
- package/dist/types/brainyDataInterface.js.map +1 -0
- package/dist/types/fileSystemTypes.js +8 -0
- package/dist/types/fileSystemTypes.js.map +1 -0
- package/dist/types/graphTypes.js +36 -0
- package/dist/types/graphTypes.js.map +1 -0
- package/dist/types/mcpTypes.js +22 -0
- package/dist/types/mcpTypes.js.map +1 -0
- package/dist/types/pipelineTypes.js +7 -0
- package/dist/types/pipelineTypes.js.map +1 -0
- package/dist/types/tensorflowTypes.js +6 -0
- package/dist/types/tensorflowTypes.js.map +1 -0
- package/dist/unified.js +1554 -550
- package/dist/unified.min.js +747 -747
- package/dist/utils/distance.js +239 -0
- package/dist/utils/distance.js.map +1 -0
- package/dist/utils/embedding.js +622 -0
- package/dist/utils/embedding.js.map +1 -0
- package/dist/utils/environment.js +75 -0
- package/dist/utils/environment.js.map +1 -0
- package/dist/utils/index.js +5 -0
- package/dist/utils/index.js.map +1 -0
- package/dist/utils/statistics.d.ts +11 -1
- package/dist/utils/statistics.d.ts.map +1 -1
- package/dist/utils/statistics.js +25 -0
- package/dist/utils/statistics.js.map +1 -0
- package/dist/utils/tensorflowUtils.js +25 -0
- package/dist/utils/tensorflowUtils.js.map +1 -0
- package/dist/utils/textEncoding.js +281 -0
- package/dist/utils/textEncoding.js.map +1 -0
- package/dist/utils/workerUtils.js +458 -0
- package/dist/utils/workerUtils.js.map +1 -0
- package/package.json +4 -3
- package/README.demo.md +0 -65
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
<br/><br/>
|
|
4
4
|
|
|
5
5
|
[](LICENSE)
|
|
6
|
-
[](https://nodejs.org/)
|
|
7
7
|
[](https://www.typescriptlang.org/)
|
|
8
8
|
[](CONTRIBUTING.md)
|
|
9
9
|
|
|
@@ -69,15 +69,19 @@ configuration.
|
|
|
69
69
|
Brainy offers specialized packages for different use cases:
|
|
70
70
|
|
|
71
71
|
#### CLI Package
|
|
72
|
+
|
|
72
73
|
```bash
|
|
73
74
|
npm install -g @soulcraft/brainy-cli
|
|
74
75
|
```
|
|
76
|
+
|
|
75
77
|
Command-line interface for data management, bulk operations, and database administration.
|
|
76
78
|
|
|
77
79
|
#### Web Service Package
|
|
80
|
+
|
|
78
81
|
```bash
|
|
79
82
|
npm install @soulcraft/brainy-web-service
|
|
80
83
|
```
|
|
84
|
+
|
|
81
85
|
REST API web service wrapper that provides HTTP endpoints for search operations and database queries.
|
|
82
86
|
|
|
83
87
|
## 🏁 Quick Start
|
|
@@ -493,7 +497,7 @@ const restoreResult = await db.restore(backupData, {clearExisting: true})
|
|
|
493
497
|
Brainy provides a way to get statistics about the current state of the database:
|
|
494
498
|
|
|
495
499
|
```typescript
|
|
496
|
-
import {
|
|
500
|
+
import {BrainyData, getStatistics} from '@soulcraft/brainy'
|
|
497
501
|
|
|
498
502
|
// Create and initialize the database
|
|
499
503
|
const db = new BrainyData()
|
|
@@ -509,6 +513,7 @@ const instanceStats = await db.getStatistics()
|
|
|
509
513
|
```
|
|
510
514
|
|
|
511
515
|
The statistics include:
|
|
516
|
+
|
|
512
517
|
- `nounCount`: Number of nouns (entities) in the database
|
|
513
518
|
- `verbCount`: Number of verbs (relationships) in the database
|
|
514
519
|
- `metadataCount`: Number of metadata entries
|
|
@@ -1107,7 +1112,7 @@ The repository includes a comprehensive demo that showcases Brainy's main featur
|
|
|
1107
1112
|
- **[Try the live demo](https://soulcraft-research.github.io/brainy/demo/index.html)** - Check out the
|
|
1108
1113
|
interactive demo on
|
|
1109
1114
|
GitHub Pages
|
|
1110
|
-
- Or run it locally with `npm run demo` (see [demo instructions](
|
|
1115
|
+
- Or run it locally with `npm run demo` (see [demo instructions](demo.md) for details)
|
|
1111
1116
|
- To deploy your own version to GitHub Pages, use the GitHub Actions workflow in
|
|
1112
1117
|
`.github/workflows/deploy-demo.yml`,
|
|
1113
1118
|
which automatically deploys when pushing to the main branch or can be manually triggered
|