@soulcraft/brainy 0.9.11 → 0.9.13
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 +26 -5
- package/dist/brainy.js +211 -47
- package/dist/brainy.min.js +746 -746
- package/dist/cli.js +169296 -0
- package/dist/index.d.ts +2 -1
- package/dist/unified.js +211 -47
- package/dist/unified.min.js +746 -746
- package/dist/utils/environment.d.ts +1 -1
- package/dist/utils/version.d.ts +1 -1
- package/dist/utils/workerUtils.d.ts +5 -5
- package/package.json +9 -3
|
@@ -23,7 +23,7 @@ export declare function areWebWorkersAvailable(): boolean;
|
|
|
23
23
|
export declare function areWorkerThreadsAvailable(): boolean;
|
|
24
24
|
/**
|
|
25
25
|
* Determine if threading is available in the current environment
|
|
26
|
-
*
|
|
26
|
+
* Returns true if either Web Workers (browser) or Worker Threads (Node.js) are available
|
|
27
27
|
*/
|
|
28
28
|
export declare function isThreadingAvailable(): boolean;
|
|
29
29
|
//# sourceMappingURL=environment.d.ts.map
|
package/dist/utils/version.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Utility functions for executing functions (
|
|
3
|
-
* This
|
|
2
|
+
* Utility functions for executing functions in Worker Threads (Node.js) or Web Workers (Browser)
|
|
3
|
+
* This implementation leverages Node.js 24's improved Worker Threads API for better performance
|
|
4
4
|
*/
|
|
5
5
|
/**
|
|
6
|
-
* Execute a function
|
|
6
|
+
* Execute a function in a separate thread
|
|
7
7
|
*
|
|
8
8
|
* @param fnString The function to execute as a string
|
|
9
9
|
* @param args The arguments to pass to the function
|
|
@@ -11,8 +11,8 @@
|
|
|
11
11
|
*/
|
|
12
12
|
export declare function executeInThread<T>(fnString: string, args: any): Promise<T>;
|
|
13
13
|
/**
|
|
14
|
-
*
|
|
15
|
-
* This
|
|
14
|
+
* Clean up all worker pools
|
|
15
|
+
* This should be called when the application is shutting down
|
|
16
16
|
*/
|
|
17
17
|
export declare function cleanupWorkerPools(): void;
|
|
18
18
|
//# sourceMappingURL=workerUtils.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@soulcraft/brainy",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.13",
|
|
4
4
|
"description": "A vector graph database using HNSW indexing with Origin Private File System storage",
|
|
5
5
|
"main": "dist/unified.js",
|
|
6
6
|
"module": "dist/unified.js",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
}
|
|
26
26
|
},
|
|
27
27
|
"engines": {
|
|
28
|
-
"node": ">=
|
|
28
|
+
"node": ">=24.0.0"
|
|
29
29
|
},
|
|
30
30
|
"scripts": {
|
|
31
31
|
"prebuild": "node scripts/generate-version.js",
|
|
@@ -38,12 +38,18 @@
|
|
|
38
38
|
"version:patch": "npm version patch",
|
|
39
39
|
"version:minor": "npm version minor",
|
|
40
40
|
"version:major": "npm version major",
|
|
41
|
+
"lint": "eslint --ext .ts,.js src/",
|
|
42
|
+
"lint:fix": "eslint --ext .ts,.js src/ --fix",
|
|
43
|
+
"format": "prettier --write \"src/**/*.{ts,js}\"",
|
|
44
|
+
"check-format": "prettier --check \"src/**/*.{ts,js}\"",
|
|
45
|
+
"check-style": "node scripts/check-code-style.js",
|
|
41
46
|
"deploy": "npm run build && npm publish",
|
|
42
47
|
"deploy:cloud:aws": "cd cloud-wrapper && npm run build && npm run deploy:aws",
|
|
43
48
|
"deploy:cloud:gcp": "cd cloud-wrapper && npm run build && npm run deploy:gcp",
|
|
44
49
|
"deploy:cloud:cloudflare": "cd cloud-wrapper && npm run build && npm run deploy:cloudflare",
|
|
45
50
|
"deploy:cloud": "echo 'Please use one of the following commands to deploy to a specific cloud provider:' && echo ' npm run deploy:cloud:aws' && echo ' npm run deploy:cloud:gcp' && echo ' npm run deploy:cloud:cloudflare'",
|
|
46
|
-
"postinstall": "echo 'Note: If you encounter dependency conflicts with TensorFlow.js packages, please use: npm install --legacy-peer-deps'"
|
|
51
|
+
"postinstall": "echo 'Note: If you encounter dependency conflicts with TensorFlow.js packages, please use: npm install --legacy-peer-deps'",
|
|
52
|
+
"dry-run": "npm pack --dry-run"
|
|
47
53
|
},
|
|
48
54
|
"bin": {
|
|
49
55
|
"brainy": "cli-wrapper.js"
|