|
1 | 1 | # Changelog |
2 | 2 |
|
| 3 | +## [0.5.5] - 2025-11-16 |
| 4 | + |
| 5 | +### Fixed - Entity Types Configuration Bug (Feature 062) |
| 6 | +- **Entity Types Configuration**: `EntityExtractionService.extract_batch_with_dspy()` now accepts and honors `entity_types` parameter from configuration |
| 7 | + - **Issue**: Configured entity types were ignored and healthcare-specific defaults (USER, MODULE, VERSION) were always used |
| 8 | + - **Root Cause**: Method signature lacked `entity_types` parameter, couldn't pass config to `TrakCareEntityExtractionModule` |
| 9 | + - **Fix**: Added `entity_types: Optional[List[str]] = None` parameter with resolution chain: parameter > config > DEFAULT_ENTITY_TYPES |
| 10 | + - **Impact**: HotpotQA Question 2 now answers correctly (F1 improved from 0.000 to >0.0) |
| 11 | + - **Files Modified**: `iris_vector_rag/services/entity_extraction.py` |
| 12 | + - Line 41-49: Added `DEFAULT_ENTITY_TYPES` constant with domain-neutral defaults |
| 13 | + - Line 890-955: Updated `extract_batch_with_dspy()` signature and implementation |
| 14 | + - Added parameter validation (ValueError for empty list) |
| 15 | + - Added warning logging for unknown entity types |
| 16 | + - Updated docstring with parameter documentation and examples |
| 17 | + |
| 18 | +### Added |
| 19 | +- `DEFAULT_ENTITY_TYPES` constant for domain-neutral entity type defaults |
| 20 | + - Values: `["PERSON", "ORGANIZATION", "LOCATION", "PRODUCT", "EVENT"]` |
| 21 | + - Replaces healthcare-specific defaults (USER, MODULE, VERSION) when configuration missing |
| 22 | +- `entity_types` parameter to `EntityExtractionService.extract_batch_with_dspy()` |
| 23 | + - Backward compatible (defaults to None) |
| 24 | + - Validation for empty list (raises ValueError with clear message) |
| 25 | + - Warning logging for unknown entity types (supports custom types) |
| 26 | +- Contract tests (`tests/contract/test_entity_types_config.py`) |
| 27 | + - 7 tests validating parameter acceptance, defaults, validation, typing, and backward compatibility |
| 28 | + - Test Results: 6/7 passing (1 skipped due to service initialization requirements) |
| 29 | + |
| 30 | +## [0.5.4] - 2025-11-14 |
| 31 | + |
| 32 | +### Fixed - Critical Bug Fixes |
| 33 | +- **CRITICAL (Bug 1)**: Fixed AttributeError breaking all database connections (iris_dbapi_connector.py:210) |
| 34 | + - **Issue**: Non-existent `iris.connect()` method caused AttributeError in v0.5.3 |
| 35 | + - **Fix**: Replaced with correct `iris.createConnection()` API |
| 36 | + - **Impact**: Restores database connectivity (was completely broken in v0.5.3) |
| 37 | + - **Test Results**: FHIR-AI test suite now 6/6 passing (up from 3/6 in v0.5.3) |
| 38 | + - ✅ ConfigurationManager (backward compatibility preserved) |
| 39 | + - ✅ ConnectionManager (was failing - now fixed) |
| 40 | + - ✅ IRISVectorStore (was failing - now fixed) |
| 41 | + - ✅ SchemaManager (was failing - now fixed) |
| 42 | + - ✅ Environment Variables (backward compatibility preserved) |
| 43 | + - ✅ Document Model (backward compatibility preserved) |
| 44 | + - **Files Modified**: `iris_vector_rag/common/iris_dbapi_connector.py` |
| 45 | + - Line 210: `iris.connect()` → `iris.createConnection()` |
| 46 | + - Enhanced error handling: AttributeError → ConnectionError with clear messages |
| 47 | + - Updated docstrings and log messages |
| 48 | + |
| 49 | +- **HIGH PRIORITY (Bug 2)**: Added automatic iris-vector-graph table initialization |
| 50 | + - **Issue**: Silent PPR (Personalized PageRank) failures due to missing database tables |
| 51 | + - **Fix**: Automatic detection and creation of iris-vector-graph tables during pipeline initialization |
| 52 | + - **Impact**: Eliminates "Table not found" errors for GraphRAG operations |
| 53 | + - **Performance**: Table initialization completes in < 5 seconds (4 tables created) |
| 54 | + - **Tables Created**: rdf_labels, rdf_props, rdf_edges, kg_NodeEmbeddings_optimized |
| 55 | + - **Files Modified**: `iris_vector_rag/storage/schema_manager.py` |
| 56 | + - Added `_detect_iris_vector_graph()` method (uses importlib.util.find_spec) |
| 57 | + - Added `ensure_iris_vector_graph_tables()` public method |
| 58 | + - Added `validate_graph_prerequisites()` validation method |
| 59 | + - Added `InitializationResult` dataclass for table creation results |
| 60 | + - Added `ValidationResult` dataclass for prerequisite validation results |
| 61 | + |
| 62 | +### Technical Details |
| 63 | +**Bug 1 - Connection API Fix**: |
| 64 | +- Root Cause: intersystems-irispython v5.3.0 provides `iris.createConnection()`, not `iris.connect()` |
| 65 | +- Error Messages: Clear ConnectionError with connection parameters and remediation steps |
| 66 | +- Backward Compatibility: No breaking changes to public APIs |
| 67 | +- Testing: Contract tests verify no AttributeError during connection establishment |
| 68 | + |
| 69 | +**Bug 2 - Schema Initialization**: |
| 70 | +- Detection: Non-invasive package detection (no import side effects) |
| 71 | +- Initialization: Idempotent table creation (safe to call multiple times) |
| 72 | +- Validation: Clear error messages listing specific missing prerequisites |
| 73 | +- Graceful Degradation: Skips initialization when iris-vector-graph not installed |
| 74 | +- Logging: INFO for success, ERROR for failures with actionable context |
| 75 | + |
| 76 | +### Migration Notes |
| 77 | +**From v0.5.3 to v0.5.4**: |
| 78 | +- No action required - bug fixes are backward compatible |
| 79 | +- ConnectionManager automatically uses correct API |
| 80 | +- SchemaManager automatically initializes iris-vector-graph tables if package detected |
| 81 | +- Optional: Run `SchemaManager.validate_graph_prerequisites()` to verify setup |
| 82 | + |
3 | 83 | ## [0.5.3] - 2025-11-12 |
4 | 84 |
|
5 | 85 | ### Fixed |
|
0 commit comments