CRITICAL FIX: createEntities was treating undefined as false, causing imports
to skip graph entity creation. Only VFS wrappers were created, breaking type filtering.
Fixes:
- createEntities now defaults to true when undefined (line 736)
- Fixed option spreading order (spread options first, then apply defaults) (line 357)
- Enabled enableRelationshipInference by default (AI relationships)
- Enabled enableNeuralExtraction by default (smart entity extraction)
- Enabled enableConceptExtraction by default (concept mining)
Root Cause:
1. Line 733: if (!options.createEntities) treated undefined as false
2. Line 361: ...options spread AFTER defaults, overwriting them with undefined
Result: Graph entities never created, only VFS wrappers
Impact:
- Workshop team: 0 results for brain.find({ type: 'person' })
- Type filtering completely broken
- HNSW showed entities (read from VFS) but storage had none
Tests Added:
- tests/unit/create-entities-default.test.ts (3 scenarios)
- tests/integration/vfs-and-graph-entities.test.ts (15 assertions, end-to-end)
- tests/integration/relationship-intelligence.test.ts (relationship verification)
- tests/unit/type-filtering.unit.test.ts (8 type filtering tests)
All tests pass ✅
Breaking Changes: None - this restores intended default behavior
Workshop Resolution: Clear ./brainy-data and re-import with v4.3.2.
Type filtering will work immediately.
🤖 Generated with Claude Code
Co-Authored-By: Claude <noreply@anthropic.com>
|
||
|---|---|---|
| .. | ||
| api | ||
| augmentations/intelligentImport | ||
| benchmarks | ||
| comprehensive | ||
| configs | ||
| fixtures/import | ||
| helpers | ||
| integration | ||
| performance | ||
| scripts | ||
| unit | ||
| vfs | ||
| brainy-3.test.ts | ||
| critical-error-handling.test.ts | ||
| critical-neural-validation.test.ts | ||
| critical-performance-benchmark.test.ts | ||
| distributed-demo.test.ts | ||
| model-loading.test.ts | ||
| opfs-storage.test.ts | ||
| package-size-breakdown.test.ts | ||
| package-size-limit.test.ts | ||
| setup-integration.ts | ||
| setup-unit.ts | ||
| setup.ts | ||
| streaming-pipeline.test.ts | ||
| type-utils.test.ts | ||
| typeAwareHNSWIndex.test.ts | ||
| typeAwareQueryPlanner.test.ts | ||