Repository navigation
feat: gate seed-sensitivity report + CLI flags (#36) - #67
Merged
Merged
Conversation
added 2 commits
August 4, 2026 16:02
- QualityGate.seed_sensitivity(): refit RidgeMapping on subsamples across seeds, report per-seed retention/top1, mean/std/min/max, unstable flag - SeedSensitivityReport dataclass with to_dict() - CLI gate: --seed-sensitivity / --seed-sensitivity-runs / --seed-sensitivity-threshold / --seed-sensitivity-seed - mapping optional when --seed-sensitivity (standalone run), reject queries/corpus mode, WARN + exit 1 when unstable - JSON/MD/HTML output includes seed_sensitivity; HTML renders section - fix: .isotrieve v2 reader misaligned payload start by 4 bytes (_find_payload_start aligned to 8-boundary though FIXED_HEADER_SIZE=12); now uses FIXED_HEADER_SIZE + ceil(header_len/8)*8, matching TS writer. v1 files read at offset 8 with no padding. Fixes save/load roundtrip regression from binary-format-v2 (#62). - tests: seed-sensitivity unit + CLI coverage
# Conflicts: # isotrieve-python/src/isotrieve/mapping/base.py
6 tasks
Merged
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.
Summary
Implements #36: seed-sensitivity analysis for the gate command.
Changes
QualityGate.seed_sensitivity()— refitsRidgeMappingon subsamples across seeds and reports retention stability (thread-pooled).SeedSensitivityReportdataclass (runs/seeds/per-seed retention+top1/mean/std/min/max/unstable/threshold) withto_dict().--seed-sensitivity,--seed-sensitivity-runs,--seed-sensitivity-threshold,--seed-sensitivity-seed; mapping optional in standalone mode; queries/corpus mode rejected; WARN + exit 1 when unstable.Bug fix included
Fixes a pre-existing v2 binary-format regression (#62) that broke
.isotrievesave/load roundtrip:_find_payload_startre-aligned to an 8-byte boundary even thoughFIXED_HEADER_SIZEis 12 bytes, overshooting the payload by 4 bytes. NowFIXED_HEADER_SIZE + ceil(header_len/8)*8, matching the TS writer; v1 files read at offset 8. The gate CLI tests depend on this fix.Verification
pytest: 160 passed, 7 skippedruff checkon touched files: cleanmypyon touched files: clean