forked from jundot/omlx
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
155 lines (142 loc) · 4.73 KB
/
pyproject.toml
File metadata and controls
155 lines (142 loc) · 4.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
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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
[build-system]
requires = ["setuptools>=61.0", "wheel"]
build-backend = "setuptools.build_meta"
[project]
name = "omlx"
dynamic = ["version"]
description = "LLM inference server, optimized for your Mac"
readme = "README.md"
license = {text = "Apache-2.0"}
requires-python = ">=3.10"
authors = [
{name = "omlx contributors"}
]
keywords = ["llm", "mlx", "apple-silicon", "vllm", "inference", "transformers"]
classifiers = [
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: Apache Software License",
"Operating System :: MacOS",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
]
dependencies = [
"mlx>=0.31.2",
# mlx-lm from commit (ed1fca4, v0.31.3) - thread-local generation stream + ArraysCache batch dim fixes + think token None safety
"mlx-lm @ git+https://github.com/ml-explore/mlx-lm@ed1fca4cef15a824c5f1702c80f70b4cffc8e4dd",
# regex for mlx-lm's Gemma 4 tool parser (uses recursive patterns)
"regex",
# mlx-embeddings from latest commit (32981fa)
"mlx-embeddings @ git+https://github.com/Blaizzy/mlx-embeddings@32981fa4e8064ed664b52071789dd18271fe4206",
# mlx-vlm custom processors bypass HF AutoProcessor, so torch is not required
"transformers>=5.0.0",
"tokenizers>=0.19.0",
"huggingface-hub>=0.23.0",
"numpy>=1.24.0",
"tqdm>=4.66.0",
"pyyaml>=6.0",
"itsdangerous>=2.0",
"jinja2>=3.0",
"sentencepiece",
"tiktoken",
"protobuf",
"requests>=2.28.0",
# SOCKS proxy support (used by httpx via huggingface-hub)
"socksio>=1.0.0",
"tabulate>=0.9.0",
# Resource monitoring
"psutil>=5.9.0",
# Server
"fastapi>=0.108.0",
"uvicorn>=0.23.0",
# JSON Schema validation for structured output
"jsonschema>=4.0.0",
# Harmony format parser for gpt-oss models
"openai-harmony",
# mlx-vlm from commit (e41cd25) - thread-local stream, DFlash GPU hang fix, hunyuan_vl/gemma3n cleanup
"mlx-vlm @ git+https://github.com/Blaizzy/mlx-vlm@e41cd25565861500e48c076ab31aaeafee0ed80f",
"Pillow>=9.0.0",
# dflash-mlx v0.1.5.1 (110f261) — runtime_context, prefix cache (L1+L2), verify-specialized int4 qmm
"dflash-mlx @ git+https://github.com/jundot/dflash-mlx@110f261",
]
[project.optional-dependencies]
grammar = [
# Grammar-constrained decoding for structured output (requires torch ~2GB)
"xgrammar>=0.1.32",
]
mcp = [
"mcp>=1.0.0",
]
modelscope = [
"modelscope>=1.10.0",
]
audio = [
# mlx-audio from commit (5175326) with tts/stt/sts extras
# tts extra: misaki, num2words, spacy, phonemizer-fork, espeakng-loader, sentencepiece
# stt extra: tiktoken, mistral-common[audio]
# sts extra: tts deps + stt deps + webrtcvad
"mlx-audio[tts,stt,sts] @ git+https://github.com/Blaizzy/mlx-audio@51753266e0a4f766fd5e6fbc46652224efc23981",
"python-multipart>=0.0.5",
]
dev = [
"pytest>=7.0.0",
"pytest-asyncio>=0.21.0",
"black>=23.0.0",
"ruff>=0.1.0",
"mypy>=1.0.0",
"mcp>=1.0.0",
]
# PEP 735 dependency groups — consumed by `uv sync --dev`.
# Keep in sync with [project.optional-dependencies] dev above
# (pip/legacy toolchains use that section instead).
[dependency-groups]
dev = [
"pytest>=7.0.0",
"pytest-asyncio>=0.21.0",
"black>=23.0.0",
"ruff>=0.1.0",
"mypy>=1.0.0",
"mcp>=1.0.0",
]
[project.urls]
Homepage = "https://github.com/jundot/omlx"
Documentation = "https://github.com/jundot/omlx#readme"
Repository = "https://github.com/jundot/omlx"
[project.scripts]
omlx = "omlx.cli:main"
[tool.setuptools.dynamic]
version = {attr = "omlx._version.__version__"}
[tool.setuptools.packages.find]
where = ["."]
include = ["omlx*"]
[tool.setuptools.package-data]
"omlx" = ["oq_calibration_data.json"]
"omlx.admin" = ["templates/**/*.html", "static/**/*", "i18n/*.json"]
"omlx.eval" = ["data/*.jsonl"]
[tool.uv]
# mlx-lm is pinned to a git commit; override transitive pins
# (e.g. mlx-audio → mlx-lm==0.31.1) so the resolver accepts it.
override-dependencies = [
"mlx-lm @ git+https://github.com/ml-explore/mlx-lm@ed1fca4cef15a824c5f1702c80f70b4cffc8e4dd",
]
[tool.black]
line-length = 88
target-version = ["py310", "py311", "py312", "py313"]
[tool.ruff]
line-length = 88
select = ["E", "F", "W", "I", "N", "UP", "B", "SIM"]
ignore = ["E501", "B905"]
[tool.mypy]
python_version = "3.10"
warn_return_any = true
warn_unused_configs = true
ignore_missing_imports = true
[tool.pytest.ini_options]
testpaths = ["tests"]
python_files = ["test_*.py"]
asyncio_mode = "auto"