open-brainy/src/utils
David Snelling 42571c5883 **feat(docs): add comprehensive documentation for model bundling and robust loading**
- Introduced new documentation files under `docs/`:
  - `model-bundling-analysis.md`: Provides detailed analysis of current, bundled, hybrid, and dynamic model loading approaches, including pros, cons, and recommendations.
  - `model-management.md`: Explains how Brainy manages Universal Sentence Encoder models, including setup, usage, and troubleshooting.
  - `optional-model-bundling.md`: Details the `@soulcraft/brainy-models` package for offline reliability with pre-bundled models.

- Added `src/utils/robustModelLoader.ts`:
  - Implements enhanced model loading with retry mechanisms, timeout handling, fallback URLs, and optional local model bundling.
  - Supports Node.js and browser environments with exponential backoff logic.

- Key Updates:
  - **Hybrid Loading Strategy**: Recommended for balancing reliability and flexibility via hybrid online/offline mechanisms.
  - **Enhanced Fallback Scenarios**: Robust loader improves network-dependent reliability for embedding workflows.
  - **Offline Reliability Support**: Optional model bundling eliminates dependency on external services, supporting air-gapped and edge environments.

**Purpose**: Introduce a hybrid model loading approach with robust options for
2025-08-01 15:35:29 -07:00
..
distance.ts **docs: remove outdated statistics-related documentation and add standards** 2025-07-28 16:00:05 -07:00
embedding.ts **feat(docs): add comprehensive documentation for model bundling and robust loading** 2025-08-01 15:35:29 -07:00
environment.ts **feat(core): enhance vector handling, model loading, and compatibility** 2025-07-16 13:51:00 -07:00
fieldNameTracking.ts **feat(search): enhance JSON document search with field-level filtering and prioritization** 2025-08-01 08:27:39 -07:00
index.ts **feat(search): enhance JSON document search with field-level filtering and prioritization** 2025-08-01 08:27:39 -07:00
jsonProcessing.ts **feat(search): enhance JSON document search with field-level filtering and prioritization** 2025-08-01 08:27:39 -07:00
operationUtils.ts **feat: implement robust error-handling and operation utilities for storage adapters** 2025-07-30 11:35:09 -07:00
robustModelLoader.ts **feat(docs): add comprehensive documentation for model bundling and robust loading** 2025-08-01 15:35:29 -07:00
statistics.ts **feat(core, storage, tests): add service-level statistics tracking and storage adapter enhancements** 2025-07-24 11:35:52 -07:00
tensorflowUtils.ts **feat(tests): add tests for TextEncoder, TensorFlow.js, and fallback mechanisms** 2025-07-11 11:11:56 -07:00
textEncoding.ts **docs: remove outdated statistics-related documentation and add standards** 2025-07-28 16:00:05 -07:00
typeUtils.ts **feat(utils): add type utility functions and examples for runtime type management** 2025-07-31 14:24:16 -07:00
workerUtils.ts **feat(tests): add tests for TextEncoder, TensorFlow.js, and fallback mechanisms** 2025-07-11 11:11:56 -07:00