pyproject.toml 4.23 KB
Newer Older
Lianmin Zheng's avatar
Lianmin Zheng committed
1
[build-system]
Yineng Zhang's avatar
Yineng Zhang committed
2
requires = ["setuptools>=61.0", "wheel"]
Lianmin Zheng's avatar
Lianmin Zheng committed
3
4
5
6
build-backend = "setuptools.build_meta"

[project]
name = "sglang"
7
version = "0.5.1.post3"
8
description = "SGLang is yet another fast serving framework for large language models and vision language models."
Lianmin Zheng's avatar
Lianmin Zheng committed
9
readme = "README.md"
10
requires-python = ">=3.10"
11
license = { file = "LICENSE" }
Lianmin Zheng's avatar
Lianmin Zheng committed
12
13
14
15
classifiers = [
    "Programming Language :: Python :: 3",
    "License :: OSI Approved :: Apache Software License",
]
16
dependencies = ["aiohttp", "requests", "tqdm", "numpy", "IPython", "setproctitle"]
Lianmin Zheng's avatar
Lianmin Zheng committed
17
18

[project.optional-dependencies]
19
runtime_common = [
20
    "blobfile==3.0.0",
21
    "build",
22
    "compressed-tensors",
23
    "datasets",
24
    "einops",
Lianmin Zheng's avatar
Lianmin Zheng committed
25
26
27
28
    "fastapi",
    "hf_transfer",
    "huggingface_hub",
    "interegular",
29
    "llguidance>=0.7.11,<0.8.0",
Lianmin Zheng's avatar
Lianmin Zheng committed
30
    "modelscope",
31
    "msgspec",
32
    "ninja",
33
    "openai==1.99.1",
34
    "openai-harmony==0.0.4",
Lianmin Zheng's avatar
Lianmin Zheng committed
35
    "orjson",
36
    "outlines==0.1.11",
Lianmin Zheng's avatar
Lianmin Zheng committed
37
    "packaging",
38
    "partial_json_parser",
Lianmin Zheng's avatar
Lianmin Zheng committed
39
40
41
    "pillow",
    "prometheus-client>=0.20.0",
    "psutil",
42
    "pybase64",
Lianmin Zheng's avatar
Lianmin Zheng committed
43
    "pydantic",
44
    "pynvml",
Lianmin Zheng's avatar
Lianmin Zheng committed
45
46
    "python-multipart",
    "pyzmq>=25.1.2",
47
    "sentencepiece",
Mick's avatar
Mick committed
48
    "soundfile==0.13.1",
49
    "scipy",
50
    "timm==1.0.16",
51
    "tiktoken",
52
    "torchao==0.9.0",
53
    "transformers==4.56.0",
Lianmin Zheng's avatar
Lianmin Zheng committed
54
55
    "uvicorn",
    "uvloop",
56
    "xgrammar==0.1.23",
57
]
58

59
srt = [
Lianmin Zheng's avatar
Lianmin Zheng committed
60
    "sglang[runtime_common]",
61
    "sgl-kernel==0.3.7.post1",
62
63
64
    "torch==2.8.0",
    "torchaudio==2.8.0",
    "torchvision",
Lianmin Zheng's avatar
Lianmin Zheng committed
65
    "cuda-python",
66
    "flashinfer_python==0.3.0",
67
]
68

69
70
71
blackwell = [
    "sglang[runtime_common]",
    "sgl-kernel",
72
73
74
    "torch==2.8.0",
    "torchaudio==2.8.0",
    "torchvision",
75
    "cuda-python",
76
    "flashinfer_python==0.3.0",
77
78
]

79
# HIP (Heterogeneous-computing Interface for Portability) for AMD
80
# => base docker rocm/vllm-dev:20250114, not from public vllm whl
81
82
83
srt_hip = [
    "sglang[runtime_common]",
    "torch",
84
    "petit_kernel==0.0.2",
85
    "wave-lang==1.0.1",
86
]
Lianmin Zheng's avatar
Lianmin Zheng committed
87

88
89
90
91
92
# https://docs.sglang.ai/platforms/cpu_server.html
srt_cpu = ["sglang[runtime_common]"]

# https://docs.sglang.ai/platforms/ascend_npu.html
srt_npu = ["sglang[runtime_common]"]
93

94
# xpu is not enabled in public vllm and torch whl,
95
# need to follow https://docs.vllm.ai/en/latest/getting_started/xpu-installation.htmlinstall vllm
96
srt_xpu = ["sglang[runtime_common]"]
Lianmin Zheng's avatar
Lianmin Zheng committed
97
98
99

# For Intel Gaudi(device : hpu) follow the installation guide
# https://docs.vllm.ai/en/latest/getting_started/gaudi-installation.html
100
srt_hpu = ["sglang[runtime_common]"]
Lianmin Zheng's avatar
Lianmin Zheng committed
101

Yineng Zhang's avatar
Yineng Zhang committed
102
openai = ["openai==1.99.1", "tiktoken"]
103
anthropic = ["anthropic>=0.20.0"]
胡译文's avatar
胡译文 committed
104
litellm = ["litellm>=1.0.0"]
105
torch_memory_saver = ["torch_memory_saver==0.0.8"]
106
decord = ["decord"]
107
test = [
108
    "accelerate",
109
    "expecttest",
110
111
112
113
    "jsonlines",
    "matplotlib",
    "pandas",
    "peft",
114
    "sentence_transformers",
fzyzcjy's avatar
fzyzcjy committed
115
    "pytest",
116
    "tabulate",
117
]
118
119
120
121
122
123
all = ["sglang[srt]", "sglang[openai]", "sglang[anthropic]", "sglang[torch_memory_saver]", "sglang[decord]"]
all_hip = ["sglang[srt_hip]", "sglang[openai]", "sglang[anthropic]", "sglang[decord]"]
all_xpu = ["sglang[srt_xpu]", "sglang[openai]", "sglang[anthropic]", "sglang[decord]"]
all_hpu = ["sglang[srt_hpu]", "sglang[openai]", "sglang[anthropic]", "sglang[decord]"]
all_cpu = ["sglang[srt_cpu]", "sglang[openai]", "sglang[anthropic]", "sglang[decord]"]
all_npu = ["sglang[srt_npu]", "sglang[openai]", "sglang[anthropic]", "sglang[decord]"]
124

125
dev = ["sglang[all]", "sglang[test]"]
126
dev_hip = ["sglang[all_hip]", "sglang[test]"]
127
dev_xpu = ["sglang[all_xpu]", "sglang[test]"]
128
dev_hpu = ["sglang[all_hpu]", "sglang[test]"]
129
dev_cpu = ["sglang[all_cpu]", "sglang[test]"]
Lianmin Zheng's avatar
Lianmin Zheng committed
130

Lianmin Zheng's avatar
Lianmin Zheng committed
131
132
133
134
[project.urls]
"Homepage" = "https://github.com/sgl-project/sglang"
"Bug Tracker" = "https://github.com/sgl-project/sglang/issues"

yudian0504's avatar
yudian0504 committed
135
[tool.setuptools.package-data]
136
"sglang" = [
137
    "srt/layers/moe/fused_moe_triton/configs/*/*.json",
138
    "srt/layers/quantization/configs/*.json",
139
    "srt/mem_cache/storage/hf3fs/hf3fs_utils.cpp",
140
]
yudian0504's avatar
yudian0504 committed
141

Lianmin Zheng's avatar
Lianmin Zheng committed
142
[tool.setuptools.packages.find]
143
144
145
146
147
148
149
150
151
exclude = [
    "assets*",
    "benchmark*",
    "docs*",
    "dist*",
    "playground*",
    "scripts*",
    "tests*",
]
Lianmin Zheng's avatar
Lianmin Zheng committed
152
153

[tool.wheel]
154
155
156
157
158
159
160
161
162
exclude = [
    "assets*",
    "benchmark*",
    "docs*",
    "dist*",
    "playground*",
    "scripts*",
    "tests*",
]
163
164
165
166

[tool.codespell]
ignore-words-list = "ans, als, hel, boostrap, childs, te, vas, hsa, ment"
skip = "*.json,*.jsonl,*.patch,*.txt"