### Changes: - Added `rollup.unified.js` for building a unified bundle with environment detection (Node.js, Browser, Serverless). - Added `rollup_config.js` for browser-specific bundle configurations. - Created `tsconfig.browser.json` for browser builds and `tsconfig.unified.json` for unified builds. - Implemented custom Rollup plugins: - **`fixThisReferences`**: Resolves `this` reference issues in TensorFlow files. - **`nodeModuleShims`**: Provides empty shims for Node.js built-in modules in browser environments. - Updated dependencies in `package-lock.json` to include Rollup plugins and updated `buffer` dependency for polyfills. - Created `src/unified.ts` as the unified library entry point with dynamic environment detection. ### Purpose: - Introduced a unified and browser-compatible build pipeline to ensure `Brainy` can seamlessly operate across multiple environments (Node.js, Browser, Serverless). - Resolved compatibility issues with Node.js modules and specific library builds. - Enhanced flexibility and usability for developers working in diverse runtime environments. |
||
|---|---|---|
| .. | ||
| augmentations | ||
| examples | ||
| hnsw | ||
| storage | ||
| types | ||
| utils | ||
| augmentationPipeline.ts | ||
| augmentationRegistry.ts | ||
| augmentationRegistryLoader.ts | ||
| brainyData.ts | ||
| cli.ts | ||
| coreTypes.ts | ||
| index.ts | ||
| sequentialPipeline.ts | ||
| unified.ts | ||