Spaces:
Runtime error
Runtime error
Commit History
-
fix: update CLI tests for --input flag and --no-filter
- Rename --query to --input in tests (matches CLI refactor) - Add --no-filter to search tests since random embeddings won't pass the default FDR threshold Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>68a03a2
-
fix: CLI tests and FAISS edge case handling
- Fix mock calibration data format (use dicts with S_i/exact/partial keys) - Filter out FAISS placeholder results (idx=-1) when k > database size - Handle empty CSV when threshold filters all results - Fix SLURM partition name for local cluster All 24 CLI tests now pass. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>e8e66c2 -
feat: add CLEAN embedding support and CLI tests
- Fix _embed_clean() to use ESM-1b + CLEAN pipeline - Update README with cpr CLI examples - Add comprehensive CLI test suite (24 tests) - Add SLURM script for GPU testing - Add test documentation (TEST_SUMMARY.md, tests/QUICKSTART.md) CLEAN embedding now properly: 1. Loads ESM-1b model 2. Computes mean-pooled embeddings (1280-dim) 3. Passes through CLEAN LayerNormNet (128-dim output) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>6754836
-
feat: add CLI, fix FDR bug, verify paper result (59/149 = 39.6%)
## Paper Verification - Verified Figure 2A: 59/149 = 39.6% JCVI Syn3.0 genes annotated at FDR α=0.1 - FDR threshold λ = 0.999980225003127 matches paper ## New Features - CLI with commands: embed, search, prob, calibrate, verify - `cpr prob`: Convert similarity scores to Venn-Abers probabilities - `cpr calibrate`: Compute FDR/FNR thresholds for new embedding models - SLURM scripts for cluster deployment (slurm_verify.sh, slurm_embed.sh) ## Bug Fixes - Fixed `get_thresh_FDR()` to handle both 1D and 2D arrays - Fixed numpy deprecation: `interpolation=` → `method=` in np.quantile() - Fixed `__init__.py` to not require gradio for core imports - Fixed `setup.py` conflict with pyproject.toml (removed src/ reference) - Fixed test expectation in test_threshold_decreases_with_lower_alpha ## Documentation - Added DATA.md: Documents GitHub vs Zenodo file requirements - Added docs/VERIFICATION_NOTES.md: Technical notes on what verification does - Updated CLAUDE.md with session log ## Tests - Al…c95d941
-
feat: add test infrastructure, docs, and modern packaging
This commit sets up the foundation for a major refactoring effort to make the Conformal Protein Retrieval codebase more usable and maintainable. ## Added - pyproject.toml: Modern Python packaging with CLI entry point (`cpr`) - Optional dependency groups: [gui], [api], [dev], [all] - pytest and code quality tool configuration - tests/: Comprehensive test suite - conftest.py: Pytest fixtures for FASTA, embeddings, and calibration data - test_util.py: Tests for all core functions in protein_conformal/util.py - FASTA parsing - FAISS operations - FDR/FNR threshold calculations - Venn-Abers probability predictions - Hierarchical loss functions - docs/: User documentation - INSTALLATION.md: Complete installation guide with Zenodo data links - QUICKSTART.md: Usage examples for common workflows - DEVELOPMENT.md: Development notes and refactoring plan ## Removed - src/protein_conformal/: Duplicate of protein_conformal/ (2280 lines) - pfam/tmp.py: Temporary debug…f4b267d