forked from skyzh/tiny-llm
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
52 lines (49 loc) · 1.73 KB
/
pyproject.toml
File metadata and controls
52 lines (49 loc) · 1.73 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
[build-system]
requires = ["pdm-backend"]
build-backend = "pdm.backend"
[project]
name = "tiny-llm"
version = "0.1.0"
requires-python = ">=3.10, <3.13"
readme = "README.md"
dependencies = [
"mlx>=0.29.1",
"torch>=2.6.0",
"torchtune>=0.6.1",
"torchao>=0.10.0",
"mlx-lm>=0.27.1",
"numpy>=2.2.4",
"pytest>=8.3.5",
"ruff>=0.11.6",
# this should not usually appear in a project dependency list but we add it to simplify the setup process
"setuptools>=62",
"nanobind==2.4.0",
"pytest-benchmark>=5.1.0",
]
[tool.pdm.scripts]
build-ext.cmd = "python build.py"
build-ext.working_dir = "src/extensions"
build-ext-test.cmd = "python test.py"
build-ext-test.working_dir = "src/extensions"
build-ext-ref.cmd = "python build.py"
build-ext-ref.working_dir = "src/extensions_ref"
clean-ext.cmd = "rm -rf build"
clean-ext.working_dir = "src/extensions"
clean-ext-ref.cmd = "rm -rf build"
clean-ext-ref.working_dir = "src/extensions_ref"
main.cmd = "python main.py"
main-week1.cmd = "python main.py --loader week1"
main-week2.cmd = "python main.py --loader week2"
batch-main.cmd = "python batch-main.py"
test.cmd = "python scripts/dev-tools.py test"
check-installation.cmd = "python scripts/check-installation.py"
test-refsol.cmd = "python scripts/dev-tools.py test-refsol"
bench.cmd = "pytest benches"
format = "ruff format"
format-cpp-ref.shell = "find src/extensions_ref -type file \\( -name '*.h' -or -name '*.cpp' \\) | xargs -n1 clang-format -i"
format-cpp.shell = "find src/extensions -type file \\( -name '*.h' -or -name '*.cpp' \\) | xargs -n1 clang-format -i"
copy-test.cmd = "python scripts/dev-tools.py copy-test"
book.cmd = "mdbook serve book/"
[tool.pytest.ini_options]
addopts = ["--import-mode=importlib"]
pythonpath = "src"