Skip to content

MELITE v0.2.1. Hardening strict tabular workflows for v0.2.1#13

Merged
NanoBiostructuresRG merged 4 commits into
mainfrom
dev/v0.2.1
May 27, 2026
Merged

MELITE v0.2.1. Hardening strict tabular workflows for v0.2.1#13
NanoBiostructuresRG merged 4 commits into
mainfrom
dev/v0.2.1

Conversation

@NanoBiostructuresRG

Copy link
Copy Markdown
Owner

Summary

This PR prepares MELITE v0.2.1 as a focused hardening release for the strict tabular dataset architecture introduced in v0.2.0.

It does not add a major new feature. Instead, it strengthens model selection, export consistency, installed-package validation, and documentation/metadata.

Changes

Model training

  • Fixed [models].active / ACTIVE_MODELS so it now controls which model families are trained.
  • MultiModelTrainer now validates active model keys before training.
  • Empty active model lists now fail clearly.
  • Unknown model keys now raise a clear ValueError.
  • Added tests confirming that single-model configurations such as ["svc"] and ["rf"] train only the requested model.

Export hardening

  • Hardened export_best_model to use strict dataset loading for registry-based datasets.
  • Removed the unsafe legacy fallback to arr.files[0].
  • Individual legacy .npz files now require an explicit X array.
  • Legacy reduction/level export compatibility remains supported.
  • Aggregated legacy archives remain supported, with validation for:
    • 2D feature matrices
    • numeric feature matrices
    • matching X/y lengths

Installed-wheel smoke workflow

  • Added an installed-wheel smoke workflow using a minimal strict [datasets.toy] dataset.
  • The smoke workflow:
    • builds the wheel,
    • installs it into a temporary environment outside the checkout,
    • verifies public API boundaries,
    • verifies the installed package is imported from the temporary environment,
    • runs melite run --config toy_config.toml --smoke,
    • runs melite export --config toy_config.toml --row 0 --force,
    • verifies expected output artifacts.
  • Updated CI to run the new smoke workflow.

Documentation and metadata

  • Updated project metadata to v0.2.1.
  • Updated CHANGELOG.md with the v0.2.1 hardening entry.
  • Updated README and documentation to reflect:
    • strict .npz dataset expectations,
    • [models].active behavior,
    • export hardening,
    • installed-wheel smoke validation.
  • Public API remains unchanged:
["Config", "load_datasets", "plot_cv_distributions", "predict", "__version__"]

Validation

The following validations passed locally:

python -m pytest
python -m build --no-isolation
python scripts\smoke_install_wheel.py
python -c "import melite; print(melite.__version__, melite.__all__)"
git diff --check

Build output confirmed:

Successfully built melite-0.2.1.tar.gz and melite-0.2.1-py3-none-any.whl

The installed-wheel smoke workflow completed successfully.

Notes

  • This PR intentionally keeps legacy reduction/level export compatibility.
  • Legacy individual .npz files must now contain an explicit X key.
  • No public API expansion is introduced in this release.
  • No PyPI publishing, tagging, or release creation is included in this PR.

@NanoBiostructuresRG NanoBiostructuresRG merged commit 0282e75 into main May 27, 2026
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant