vLLM
ActiveDescription
A high-throughput and memory-efficient inference and serving engine for LLMs, featuring PagedAttention, continuous batching, and optimized KV cache management for production deployments.
Key Features
- PagedAttention memory management - Efficiently manages attention KV cache via paging, dramatically reducing memory usage
- Continuous batching and chunked prefill - Supports continuous batching, chunked prefill, and prefix caching for high-throughput inference
- Multi-quantization support - Covers FP8, INT8, INT4, GPTQ/AWQ, GGUF, compressed-tensors, and more quantization formats
- 200+ model architecture compatibility - Seamlessly supports decoder-only, MoE, hybrid attention, and multi-modal models on HuggingFace
- Distributed inference - Supports tensor, pipeline, data, expert, and context parallelism for scaling across devices
- OpenAI-compatible API - Provides OpenAI-compatible server with Anthropic Messages API and gRPC protocol support
Use Cases
Tags
Categories
Quick Start
# Install vLLM
pip install vllm
# Start OpenAI-compatible API server
python -m vllm.entrypoints.openai.api_server \
--model meta-llama/Llama-3-8B-Instruct
# Or use Python API for direct inference
from vllm import LLM
llm = LLM(model="meta-llama/Llama-3-8B-Instruct")
output = llm.generate("Hello, what is AI?")
print(output[0].outputs[0].text)