Files
wehub-resource-sync 9f75346603
pre-commit / pre-run-check (push) Has been cancelled
pre-commit / pre-commit (push) Has been cancelled
docs: make Chinese README the default
2026-07-13 09:53:31 +00:00

117 lines
5.8 KiB
Markdown
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!-- WEHUB_ZH_README -->
> [!NOTE]
> 本文档由 WeHub 基于上游 README 翻译整理,属于社区翻译,非官方中文文档。
> [English](./README.en.md) · [原始项目](https://github.com/vllm-project/vllm) · [上游 README](https://github.com/vllm-project/vllm/blob/HEAD/README.md)
> 原作者、版权与许可证归属以原始项目及本仓库 LICENSE 文件为准。
<!-- markdownlint-disable MD001 MD041 -->
<p align="center">
<picture>
<source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/vllm-project/vllm/main/docs/assets/logos/vllm-logo-text-dark.png">
<img alt="vLLM" src="https://raw.githubusercontent.com/vllm-project/vllm/main/docs/assets/logos/vllm-logo-text-light.png" width=55%>
</picture>
</p>
<h3 align="center">
简单、快速、低成本的 LLM serving,人人可用
</h3>
<p align="center">
| <a href="https://docs.vllm.ai"><b>文档</b></a> | <a href="https://blog.vllm.ai/"><b>博客</b></a> | <a href="https://arxiv.org/abs/2309.06180"><b>论文</b></a> | <a href="https://x.com/vllm_project"><b>Twitter/X</b></a> | <a href="https://discuss.vllm.ai"><b>用户论坛</b></a> | <a href="https://slack.vllm.ai"><b>开发者 Slack</b></a> |
</p>
🔥 我们搭建了 vLLM 官网,帮助你上手 vLLM。请访问 [vllm.ai](https://vllm.ai) 了解更多。
有关活动,请访问 [vllm.ai/events](https://vllm.ai/events) 加入我们。
---
## 关于
vLLM 是一个用于 LLM 推理(inference)与 serving 的快速、易用库。
最初由 UC Berkeley 的 [Sky Computing Lab](https://sky.cs.berkeley.edu) 开发,vLLM 已成长为最活跃的开源 AI 项目之一,由来自全球 2000 多名贡献者的众多学术机构与企业组成的多元化社区共同构建与维护。
vLLM 之所以快速,得益于:
- 业界领先的 serving 吞吐量
- 通过 [**PagedAttention**](https://blog.vllm.ai/2023/06/20/vllm.html) 高效管理注意力 key 与 value 内存
- 对入站请求的连续批处理(continuous batching)、分块 prefill、前缀缓存(prefix caching
- 借助分段与完整 CUDA/HIP 图实现快速、灵活的模型执行
- 量化:FP8、MXFP8/MXFP4、NVFP4、INT8、INT4、GPTQ/AWQ、GGUF、compressed-tensors、ModelOpt、TorchAO 以及[更多](https://docs.vllm.ai/en/latest/features/quantization/index.html)
- 优化的注意力内核,包括 FlashAttention、FlashInfer、TRTLLM-GEN、FlashMLA 和 Triton
- 使用 CUTLASS、TRTLLM-GEN、CuTeDSL 为多种精度优化的 GEMM/MoE 内核
- 推测解码(speculative decoding),包括 n-gram、suffix、EAGLE、DFlash
- 使用 torch.compile 进行自动内核生成与图级变换
- 解耦的 prefill、decode 与 encode
vLLM 灵活且易用,具备:
- 与流行的 Hugging Face 模型无缝集成
- 多种解码算法下的高吞吐量 serving,包括*并行采样*parallel sampling)、*束搜索*beam search)等
- 面向分布式推理的张量、流水线、数据、专家与上下文并行
- 流式输出
- 使用 xgrammar 或 guidance 生成结构化输出
- 工具调用与推理解析器
- 兼容 OpenAI 的 API 服务器,并支持 Anthropic Messages API 与 gRPC
- 对 dense 与 MoE 层的高效 multi-LoRA 支持
- 支持 NVIDIA GPU、AMD GPU 以及 x86/ARM/PowerPC CPU;此外还提供 Google TPU、Intel Gaudi、IBM Spyre、华为 Ascend、Rebellions NPU、Apple Silicon、MetaX GPU 等多种硬件插件。
vLLM 在 Hugging Face 上无缝支持 200+ 种模型架构,包括:
- 仅解码器 LLM(例如 Llama、Qwen、Gemma
- 混合专家(MoELLM(例如 Mixtral、DeepSeek-V3、Qwen-MoE、GPT-OSS
- 混合注意力与状态空间模型(例如 Mamba、Qwen3.5
- 多模态模型(例如 LLaVA、Qwen-VL、Pixtral
- 嵌入与检索模型(例如 E5-Mistral、GTE、ColBERT
- 奖励与分类模型(例如 Qwen-Math)
完整支持的模型列表见[此处](https://docs.vllm.ai/en/latest/models/supported_models.html).
## 快速开始
使用 [`uv`](https://docs.astral.sh/uv/)(推荐)或 `pip` 安装 vLLM
```bash
uv pip install vllm
```
或[从源码构建](https://docs.vllm.ai/en/latest/getting_started/installation/gpu/index.html#build-wheel-from-source) 以便开发。
访问我们的[文档](https://docs.vllm.ai/en/latest/) 了解更多。
- [安装](https://docs.vllm.ai/en/latest/getting_started/installation.html)
- [快速入门](https://docs.vllm.ai/en/latest/getting_started/quickstart.html)
- [支持的模型列表](https://docs.vllm.ai/en/latest/models/supported_models.html)
## 贡献
我们欢迎并重视任何贡献与合作。
请参阅[为 vLLM 做贡献](https://docs.vllm.ai/en/latest/contributing/index.html) 了解如何参与。
## 引用
如果你在研究中使用 vLLM,请引用我们的[论文](https://arxiv.org/abs/2309.06180):
```bibtex
@inproceedings{kwon2023efficient,
title={Efficient Memory Management for Large Language Model Serving with PagedAttention},
author={Woosuk Kwon and Zhuohan Li and Siyuan Zhuang and Ying Sheng and Lianmin Zheng and Cody Hao Yu and Joseph E. Gonzalez and Hao Zhang and Ion Stoica},
booktitle={Proceedings of the ACM SIGOPS 29th Symposium on Operating Systems Principles},
year={2023}
}
```
## 联系我们
<!-- --8<-- [start:contact-us] -->
- 技术问题与功能请求,请使用 GitHub [Issues](https://github.com/vllm-project/vllm/issues)
- 与其他用户交流,请使用 [vLLM 论坛](https://discuss.vllm.ai)
- 协调贡献与开发,请使用 [Slack](https://slack.vllm.ai)
- 安全漏洞披露,请使用 GitHub 的 [Security Advisories](https://github.com/vllm-project/vllm/security/advisories) 功能
- 合作与商务洽谈,请通过 [collaboration@vllm.ai](mailto:collaboration@vllm.ai) 联系我们
<!-- --8<-- [end:contact-us] -->
## 媒体资源
- 如需使用 vLLM 徽标,请参阅[我们的媒体资源仓库](https://github.com/vllm-project/media-kit)