Implement centralized metadata registry and optimize test performance#29
Merged
Merged
Conversation
## Major Changes ### Centralized Architecture (Issue #21) - Replace 3 separate data loaders with unified MetadataRegistry class - Add 4 core dataclasses: GeneMetadata, ConditionMetadata, ModuleMetadata, FitnessEffect - Build efficient index structures for O(1) lookups (gene↔module, gene↔condition) - Thread-safe data loading with file change detection ### Test Infrastructure Improvements - Add session-scoped fixtures in tests/conftest.py for shared data loading - Remove all mocking per project policy - tests now use real data - Update all test files to use shared fixtures instead of individual data loading - Tests now fail if real data unavailable (no conditional passes) ### Performance Optimizations - Fix expand_gene_condition_network O(n²) performance bottleneck - Replace nested linear scans with index structure lookups - Test suite time: 104s → 6.6s (15.7x speedup) - Network expansion tests: 45s each → 0.03s each (1,500x speedup) ### Code Quality - Fix scientific interpretation: negative scores = essential genes, positive = inhibitory - Consolidate Makefile test targets into single 'test' target with coverage + timing - Remove unused imports and target aliases - All linting and type checking passes ### API Migrations - Migrate get_gene_info, search_genes, get_growth_conditions to use registry - Migrate get_condition_details, interpret_fitness_score to use registry - Migrate module-related tools to use centralized data structures - Maintain backward compatibility with legacy loaders during transition 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
6 tasks
Member
Author
|
for review tomorrow |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Major Changes
Centralized Architecture (Issue #21)
Test Infrastructure Improvements
Performance Optimizations
Code Quality
API Migrations
🤖 Generated with Claude Code