Repository navigation
Expand file tree
/
Copy pathpyproject.toml
More file actions
79 lines (70 loc) · 3.1 KB
/
Copy pathpyproject.toml
File metadata and controls
79 lines (70 loc) · 3.1 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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
[build-system]
requires = ["setuptools>=69"]
build-backend = "setuptools.build_meta"
[project]
name = "tensorfold"
dynamic = ["version"]
description = "Fast, exact LLM decoding on Apple Silicon (MLX) and NVIDIA GPUs (CUDA) behind an OpenAI-compatible endpoint"
readme = "README.md"
requires-python = ">=3.11"
license = { text = "Apache-2.0" }
authors = [{ name = "TensorFold contributors" }]
keywords = ["llm", "mlx", "apple-silicon", "cuda", "dgx-spark", "inference", "speculative-decoding", "openai"]
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: Apache Software License",
"Operating System :: MacOS",
"Operating System :: POSIX :: Linux",
"Environment :: GPU :: NVIDIA CUDA",
"Programming Language :: Python :: 3",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
]
# mlx-lm stays below its next minor (TensorFold builds on its models); CUDA uses the container's torch and triton.
dependencies = [
# the prompt kernels and SSD streaming are tested on MLX 0.32.2 and 0.32.3 (#88)
"mlx>=0.32.2,<0.32.4; sys_platform == 'darwin'",
"mlx-lm>=0.31.3,<0.33; sys_platform == 'darwin'",
"numpy>=1.26",
"huggingface-hub>=0.24",
"tokenizers>=0.20; sys_platform != 'darwin'",
"safetensors>=0.4; sys_platform != 'darwin'",
"jinja2>=3.1; sys_platform != 'darwin'",
]
[project.optional-dependencies]
tui = ["rich>=14,<16", "prompt-toolkit>=3.0.51,<4"]
test = ["pytest>=8"]
# --ssd-experts builds a small MLX extension on first use with MLX's own nanobind (MLX 0.32.2 takes 2.15.0)
ssd = ["cmake>=3.27; sys_platform == 'darwin'", "nanobind==3.0.1; sys_platform == 'darwin'"]
vision = ["Pillow>=10", "transformers>=5.3,<6", "mlx-vlm>=0.7.3,<0.8; sys_platform == 'darwin'",
"av>=12; sys_platform != 'darwin'"]
# response_format, guided_* and structured_outputs on every server: grammar-shaped replies (xgrammar brings torch)
grammar = ["xgrammar>=0.2.8,<0.3"]
[project.scripts]
tensorfold = "tensorfold.cli:main"
[tool.setuptools]
license-files = ["LICENSE", "NOTICE", "THIRD_PARTY_NOTICES.md", "LICENSES/*"]
[tool.setuptools.packages.find]
where = ["src"]
[tool.setuptools.package-data]
"tensorfold.control.assets" = ["*.json"]
"tensorfold.drafters.vendor.z_lab_dflash" = ["README.md"]
"tensorfold.cuda" = ["*.cu", "*.cuh", "*.cpp"]
"tensorfold.cuda.kernels" = ["*.cu", "*.cuh", "*.cpp"]
"tensorfold.families.qwen3_5" = ["*.json"]
"tensorfold.families.qwen3_5.cuda" = ["*.cu", "*.cpp"]
"tensorfold.families.qwen4_exp.cuda" = ["*.cu", "*.cpp", "*.txt"]
"tensorfold.families.nemotron_h" = ["*.txt"]
"tensorfold.families.glm5_next.cuda" = ["*.cu", "*.cpp"]
"tensorfold.families.nemotron_h.cuda" = ["*.cu", "*.cpp"]
"tensorfold.cuda.exl3" = ["*.cu", "*.cuh", "*.cpp"]
"tensorfold.cuda.nvfp4" = ["*.cu", "*.cuh", "*.cpp"]
"tensorfold.streaming.hostsync" = ["*.cpp", "CMakeLists.txt"]
[tool.pytest.ini_options]
testpaths = ["tests"]
pythonpath = ["src", "tests"]
[tool.ruff]
line-length = 120
extend-exclude = ["src/tensorfold/families/deepseek_v4/vendor"] # third-party code kept unmodified
[tool.setuptools.dynamic]
version = { attr = "tensorfold.__version__" }