vLLM, Docker and Streamlit: GPU chat deployment tutorial

Learn how a Streamlit chat app calls vLLM inside Docker on an AWS G4 instance with a Tesla T4 GPU, including startup checks and API endpoints.

Player not loading? Watch on YouTube

This tutorial explains a self-hosted chat deployment with vLLM, Streamlit and Docker on an AWS G4 instance with an NVIDIA Tesla T4 GPU. The speaker calls it a local LLM application because the model runs on a server she controls rather than through a model provider's hosted API. The demonstration uses a cloud server, not a laptop.

The walkthrough follows a browser request through Streamlit to vLLM, which runs inference on the GPU and streams the response back. Both services share one container. An entrypoint script starts vLLM on port 8000, waits for its /health endpoint to respond, then starts Streamlit on port 80. The frontend uses /v1/models to discover the model and /v1/chat/completions for chat requests.

The project uses a 1.5B instruction model and dependencies selected for a T4 GPU environment. The speaker explains the NVIDIA Container Toolkit's role in giving Docker access to the GPU, along with an NVIDIA runtime base image and a host cache that avoids repeated model downloads. The UI demonstration includes temperature and top-p controls.

This is an architecture walkthrough rather than a command-by-command setup guide; the linked guide contains instance preparation steps. Splitting the frontend and backend into separate containers is a suggested extension. Kubernetes appears as a possible next deployment step, not part of the demonstrated setup.