pyproject.toml 4.34 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.4.10.post2"
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.9"
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",
Lianmin Zheng's avatar
Lianmin Zheng committed
24
25
26
27
    "fastapi",
    "hf_transfer",
    "huggingface_hub",
    "interegular",
28
    "llguidance>=0.7.11,<0.8.0",
Lianmin Zheng's avatar
Lianmin Zheng committed
29
    "modelscope",
30
    "msgspec",
31
    "ninja",
32
    "openai-harmony==0.0.3",
Lianmin Zheng's avatar
Lianmin Zheng committed
33
    "orjson",
34
    "outlines==0.1.11",
Lianmin Zheng's avatar
Lianmin Zheng committed
35
    "packaging",
36
    "partial_json_parser",
Lianmin Zheng's avatar
Lianmin Zheng committed
37
38
39
40
    "pillow",
    "prometheus-client>=0.20.0",
    "psutil",
    "pydantic",
41
    "pynvml",
42
    "pybase64",
Lianmin Zheng's avatar
Lianmin Zheng committed
43
44
    "python-multipart",
    "pyzmq>=25.1.2",
45
    "sentencepiece",
Mick's avatar
Mick committed
46
    "soundfile==0.13.1",
47
    "scipy",
Lianmin Zheng's avatar
Lianmin Zheng committed
48
    "torchao==0.9.0",
49
    "transformers==4.55.0",
50
    "timm==1.0.16",
Lianmin Zheng's avatar
Lianmin Zheng committed
51
52
    "uvicorn",
    "uvloop",
Swipe4057's avatar
Swipe4057 committed
53
    "xgrammar==0.1.22",
54
]
55

56
srt = [
Lianmin Zheng's avatar
Lianmin Zheng committed
57
    "sglang[runtime_common]",
58
59
60
61
    "sgl-kernel==0.3.2",
    "torch==2.8.0",
    "torchaudio==2.8.0",
    "torchvision",
Lianmin Zheng's avatar
Lianmin Zheng committed
62
    "cuda-python",
63
    "einops",
64
    "flashinfer_python==0.2.10",
65
]
66

67
68
69
blackwell = [
    "sglang[runtime_common]",
    "sgl-kernel",
70
71
72
    "torch==2.8.0",
    "torchaudio==2.8.0",
    "torchvision",
73
74
    "cuda-python",
    "einops",
75
    "flashinfer_python==0.2.10",
Yineng Zhang's avatar
Yineng Zhang committed
76
    "tiktoken",
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
]
Lianmin Zheng's avatar
Lianmin Zheng committed
86

87
# xpu is not enabled in public vllm and torch whl,
88
# need to follow https://docs.vllm.ai/en/latest/getting_started/xpu-installation.htmlinstall vllm
89
srt_xpu = ["sglang[runtime_common]"]
Lianmin Zheng's avatar
Lianmin Zheng committed
90
91
92

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

95
# CPU: torch wheel for CPU needs to be installed from https://download.pytorch.org/whl/cpu
96
srt_cpu = ["sglang[runtime_common]", "einops"]
97
# https://vllm-ascend.readthedocs.io/en/latest/installation.html
98
srt_npu = ["sglang[runtime_common]"]
99

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

121
dev = ["sglang[all]", "sglang[test]"]
122
dev_hip = ["sglang[all_hip]", "sglang[test]"]
123
dev_xpu = ["sglang[all_xpu]", "sglang[test]"]
124
dev_hpu = ["sglang[all_hpu]", "sglang[test]"]
125
dev_cpu = ["sglang[all_cpu]", "sglang[test]"]
Lianmin Zheng's avatar
Lianmin Zheng committed
126

Lianmin Zheng's avatar
Lianmin Zheng committed
127
128
129
130
[project.urls]
"Homepage" = "https://github.com/sgl-project/sglang"
"Bug Tracker" = "https://github.com/sgl-project/sglang/issues"

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

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

[tool.wheel]
150
151
152
153
154
155
156
157
158
exclude = [
    "assets*",
    "benchmark*",
    "docs*",
    "dist*",
    "playground*",
    "scripts*",
    "tests*",
]
159
160
161
162

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