@@ -8,6 +8,7 @@ license = "MIT"
88requires-python = " >=3.10,<3.12"
99
1010dependencies = [
11+ # --- Your ML project dependencies ---
1112 " python-dotenv==1.1" ,
1213 " torch==2.6.0+cu124" ,
1314 " torchaudio==2.6.0+cu124" ,
@@ -37,11 +38,117 @@ dependencies = [
3738 " opik>=1.9.33" ,
3839]
3940
41+ [build-system ]
42+ requires = [" hatchling" ]
43+ build-backend = " hatchling.build"
44+
45+ [tool .hatch .build .targets .wheel ]
46+ packages = [" src/aixpert" ]
47+
48+ # ------------------------------------------------
49+ # Dependency groups (required by CI)
50+ # ------------------------------------------------
51+ [dependency-groups ]
52+ dev = [
53+ " codecov>=2.1.13" ,
54+ " mypy>=1.14.1" ,
55+ " nbqa>=1.9.1" ,
56+ " pip-audit>=2.7.3" ,
57+ " pre-commit>=4.1.0" ,
58+ " pytest>=8.3.4" ,
59+ " pytest-asyncio>=0.25.2" ,
60+ " pytest-cov>=6.0.0" ,
61+ " pytest-mock>=3.14.0" ,
62+ " ruff>=0.9.2" ,
63+ " types-pyyaml>=6.0.12.20250822" ,
64+ ]
65+
66+ docs = [
67+ " jinja2>=3.1.6" ,
68+ " mkdocs>=1.6.0" ,
69+ " mkdocs-material>=9.5.15" ,
70+ " mkdocstrings>=0.24.1" ,
71+ " mkdocstrings-python>=1.10.0" ,
72+ " ipykernel>=6.29.5" ,
73+ " ipython>=8.31.0" ,
74+ ]
75+
76+ # ------------------------------------------------
77+ # UV configuration
78+ # ------------------------------------------------
4079[tool .uv ]
4180index-url = " https://pypi.org/simple"
4281extra-index-url = [" https://download.pytorch.org/whl/cu124" ]
4382index-strategy = " unsafe-best-match"
83+ default-groups = [" dev" , " docs" ]
4484
4585[tool .uv .sources ]
4686unsloth = { git = " https://github.com/unslothai/unsloth.git" }
4787
88+ # ------------------------------------------------
89+ # Linting / type checking (required for CI)
90+ # ------------------------------------------------
91+
92+ [tool .mypy ]
93+ follow_imports = " normal"
94+ ignore_missing_imports = true
95+ install_types = true
96+ pretty = true
97+ non_interactive = true
98+ allow_untyped_defs = false
99+ check_untyped_defs = true
100+ namespace_packages = true
101+ explicit_package_bases = true
102+ warn_unused_configs = true
103+ strict_equality = true
104+ extra_checks = true
105+ mypy_path = " src"
106+
107+ [tool .ruff ]
108+ include = [" *.py" , " pyproject.toml" , " *.ipynb" ]
109+ exclude = []
110+ line-length = 88
111+
112+ [tool .ruff .format ]
113+ quote-style = " double"
114+ indent-style = " space"
115+ docstring-code-format = true
116+
117+ [tool .ruff .lint ]
118+ select = [
119+ " A" ," B" ," COM" ," C4" ," RET" ," SIM" ," ICN" ," Q" ," RSE" ,
120+ " D" ," E" ," F" ," I" ," W" ," N" ," ERA" ," PL"
121+ ]
122+ fixable = [" A" ," B" ," COM" ," C4" ," RET" ," SIM" ," ICN" ," Q" ," RSE" ," D" ," E" ," F" ," I" ," W" ," N" ," ERA" ," PL" ]
123+ ignore = [
124+ " B905" ," E501" ," D203" ," D213" ," PLR2004" ," PLR0913" ," COM812" ,
125+ " ERA001" ," A001" ," A002" ," D301"
126+ ]
127+
128+ [tool .ruff .lint .per-file-ignores ]
129+ "__init__.py" = [" E402" ," F401" ," F403" ," F811" ]
130+ "tests/*" = [" D103" ," D105" ," D107" ]
131+
132+ [tool .ruff .lint .pep8-naming ]
133+ ignore-names = [" X*" , " setUp" ]
134+
135+ [tool .ruff .lint .isort ]
136+ lines-after-imports = 2
137+
138+ [tool .ruff .lint .pydocstyle ]
139+ convention = " numpy"
140+
141+ [tool .ruff .lint .pycodestyle ]
142+ max-doc-length = 88
143+
144+ # ------------------------------------------------
145+ # Pytest & Coverage (CI requirements)
146+ # ------------------------------------------------
147+ [tool .pytest .ini_options ]
148+ markers = [
149+ " integration_test: marks tests as integration tests" ,
150+ ]
151+
152+ [tool .coverage .run ]
153+ source = [" src/aixpert" ]
154+ omit = [" tests/*" , " *__init__.py" ]
0 commit comments