CRITICAL BUG FIX: FileSystemStorage was skipping verbs without metadata files,
causing getVerbsBySource() to return 0 results despite 601 relationships existing.
Root Cause:
- Workshop data had 601 verb vector files with 0 metadata files
- FileSystemStorage.getVerbsWithPagination() skipped verbs if metadata === null
- This bug survived 11 versions (v4.5.1 through v4.8.0)
Fixes Applied:
1. FileSystemStorage (2 locations):
- Line 1391-1406: Remove metadata skip in getVerbsWithPagination()
- Line 2427-2442: Remove metadata skip in streaming method
- Use (metadata || {}) pattern like other adapters
2. TypeAwareStorage (2 methods):
- getVerbsBySource_internal: Delegate to underlying storage (was O(total_verbs))
- getVerbsByTarget_internal: Delegate to underlying storage
- Fixes catastrophic performance bug (scanned all 40 types + all files)
Verification:
- Built successfully with TypeScript
- All 25 augmentation tests passing
- Tested against Workshop's 601 verb dataset
- Result: 0 verbs → 2 verbs returned ✓
Impact:
- VFS relationships now queryable without metadata files
- TypeAware performance: O(total_verbs) → O(matching_verbs)
- Compatible with existing data (backward compatible)
|
||
|---|---|---|
| .. | ||
| azureBlobStorage.ts | ||
| baseStorageAdapter.ts | ||
| batchS3Operations.ts | ||
| fileSystemStorage.ts | ||
| gcsStorage.ts | ||
| memoryStorage.ts | ||
| opfsStorage.ts | ||
| optimizedS3Search.ts | ||
| r2Storage.ts | ||
| s3CompatibleStorage.ts | ||
| typeAwareStorageAdapter.ts | ||