32. Contributing and development¶
This page explains how to set up a dev environment, run tests, and contribute changes. If you are preparing a release, see Release process.
32.1 Dev setup¶
Use the Makefile targets or install dependencies directly.
Use make install-dev if you want a single command that matches the repo defaults. [2][1]
make install-dev
Use the editable pip install -e form when you want explicit control over installs and extras. [2][1]
python -m pip install -e "." && python -m pip install -e ".[dev]"
The development extras and Makefile targets are defined in pyproject.toml and Makefile. [1][2]
32.2 Running tests¶
Tests are organized under tests/ and use pytest:
Use make test for the default suite. [2][1]
make test
Use python -m pytest when you need custom flags or subset selection. [2][1]
python -m pytest
Pytest options and markers are configured in pyproject.toml. [1][3]
32.3 Style and linting¶
The project uses Ruff for linting and formatting:
make lint
make format
Ruff configuration is in pyproject.toml. [1][2]
32.4 Project structure explanation¶
-
src/modssc/: core library and CLI implementations. [4] -
bench/: benchmark runner and experiment configs (GitHub-only). [5] -
examples/andnotebooks/: runnable demos and exploratory workflows. [4][6]
32.5 Adding a new algorithm or dataset¶
Inductive methods:
- Implement the InductiveMethod protocol and define a MethodInfo object. [7]
- Register the method ID in
register_builtin_methods. [8]
Transductive methods:
- Implement the TransductiveMethod protocol and define MethodInfo. [9]
- Register the method ID in
register_builtin_methods. [10]
Datasets:
- Add curated datasets by extending DATASET_CATALOG in the relevant modality file. [11]
Use a catalog entry when the dataset already fits an existing provider. Add a new provider when you need a new backend or authentication flow. Catalog entries reference providers by name. [11][12][13]
If you are preparing a tag or release artifacts, follow the release process.
32.6 Related links¶
Sources
pyproject.tomlMakefiletests/README.mdbench/README.mdexamples/src/modssc/inductive/base.pysrc/modssc/inductive/registry.pysrc/modssc/transductive/base.pysrc/modssc/transductive/registry.pysrc/modssc/data_loader/catalog/src/modssc/data_loader/providers/base.pysrc/modssc/data_loader/providers/__init__.py