vLLM vs Ollama: serving workloads and setup tradeoffs
Compare vLLM with Ollama and llama.cpp, understand KV caching and batching, and review GPU memory and context settings.
Player not loading? Watch on YouTube
vLLM serves language models through an OpenAI-compatible API. The speaker describes starting it with a Hugging Face model name and connecting an application to localhost port 8000. The focus is workload selection: concurrent requests give a serving engine different demands from a single local chat.
PagedAttention allocates KV cache memory in small pages. Continuous batching lets requests join or leave the active group between generated tokens. The explanation also covers prefix caching for shared prompt content and chunked prefill for long prompts.
The speaker compares vLLM with Ollama and llama.cpp, reporting little advantage for one request at a time and possible slowdowns on a small GPU also running a desktop. These are qualitative comparisons, not controlled benchmark results presented in the transcript. Concurrent users, document batches and agents making parallel requests are the suggested use cases.
Configuration advice includes lowering gpu-memory-utilization to leave room for other GPU workloads and reducing max-model-len when the requested context will not fit. The startup log reports estimated capacity. The speaker describes GGUF support as experimental and suggests Hugging Face weights, including AWQ or FP8 variants when appropriate.
The suggested starting platform is Linux with NVIDIA hardware. The video also mentions AMD through ROCm, Windows through WSL2 and the young vLLM Metal plugin for Macs. It recommends comparing SGLang with vLLM on the prompts the application will actually use.