Thanks for helping build the framework. This guide gets you from clone to green PR.
Requires Python 3.13 and uv. On macOS, the boosting libraries need
OpenMP:
brew install libomp # macOS only (xgboost / lightgbm)
git clone https://github.com/fireflyframework/fireflyframework-datascience
cd fireflyframework-datascience
uv sync --extra tabular --extra data --extra validation --group devThe single framework dependency, fireflyframework-agentic, resolves from its public git repo.
Add extras as you work on them: --extra dl (PyTorch), --extra nlp (HuggingFace), --extra tabfm
(TabPFN), --extra genai (the agentic accelerators), or --extra full.
Every change must pass the same gate CI runs:
uv run ruff check src/ tests/ # lint
uv run ruff format --check src/ tests/ # format
uv run pyright # type-check
uv run pytest # tests (integration/nightly excluded by default)-m integrationruns network/heavy tests (OpenML, HuggingFace downloads).-m nightlyruns long-running suites (full AMLB, GPU).
OpenMP note (macOS): the suite must run with the OpenMP/BLAS pools pinned to one thread.
tests/conftest.pysetsOMP_NUM_THREADS=1/OPENBLAS_NUM_THREADS=1before any ML import (CI sets the same), because xgboost / lightgbm / scikit-learn each bundle a libomp on macOS and the duplicate runtimes deadlock in an OpenMP join barrier (__kmp_join_barrier) at teardown. If you run scripts/benchmarks that import the ML stack outside pytest, export the same variables.
- CalVer
YY.MM.PATCH; the version lives insrc/fireflyframework_datascience/_version.py. - Apache-2.0 header on every
.py:# Copyright 2026 Firefly Software Foundation. - Hexagonal: each module is a light
__init__.py(ports =Protocols + DTOs), heavyadapters.py(concrete impls, lazy-importing optional libraries), and a lightauto_configuration.pythat registers beans via@bean, gated by@conditional_on_class/@conditional_on_property. - Lazy imports of optional heavy dependencies are deliberate (keeps the core importable without any
extra). The
PLC0415rule is therefore relaxed for the DataScience subtree.
- Define (or reuse) the
Protocolport in the module's__init__.py. - Implement the adapter in
adapters.py, importing the heavy library inside the method and raisingAdapterUnavailableError("MyAdapter", "<extra>")when it is missing. - Register it in
auto_configuration.pybehind@conditional_on_class("<library>"). - Add the entry point under
[project.entry-points."firefly_datascience.auto_configuration"]. - Add the optional dependency to
[project.optional-dependencies]. - Write a test (mark it
integration/nightlyif it needs network/GPU).
Docs are an mkdocs Material site under docs/.
uv sync --only-group docs
uv run mkdocs serve # live preview at http://127.0.0.1:8000
uv run mkdocs build --strict # must pass (no broken links)Diagrams are generated β edit assets/tools/gen_diagrams.py, run it, and commit the SVGs:
uv run python assets/tools/gen_diagrams.py # writes docs/img/*.svgKeep the gate green, write a clear commit message, open a PR against main, and make sure CI passes.
Thank you! π