Giter Site home page Giter Site logo

vllm-docker's Introduction

vLLM Docker Container Image

vLLM is a fast and easy-to-use library for LLM inference and serving. This container image runs the OpenAI API server of vLLM.

Image URL: ghcr.io/substratusai/vllm

Support the project by adding a star! ❤️

Join us on Discord:
discord-invite

Quickstart

Deploy Mistral 7B Instruct using Docker:

docker run -d -p 8080:8080 --gpus=all \
  -e MODEL=mistralai/Mistral-7B-Instruct-v0.1 \
  ghcr.io/substratusai/vllm

Deploy Mistral 7B Instruct using K8s:

kubectl apply -f https://raw.githubusercontent.com/substratusai/vllm-docker/main/k8s-deployment.yaml

Configuration Options

The following configuration options are available by using environment variables:

Env Name Description
MODEL REQUIRED, The model ID to serve. This can be in the form of hf_org/model or utilize a path to point to a local model. Example value: mistralai/Mistral-7B-Instruct-v0.1
SERVED_MODEL_NAME OPTIONAL, The model name used in the API. If not specified, the model name will be the same as the huggingface name.
GPU_MEMORY_UTILIZATION OPTIONAL, the max memory allowed to be utilized, default is 0.90
PORT OPTIONAL, the port to use for serving, default is 8080
QUANTIZATION OPTIONAL, the quantization method. Choices: 'awq', 'squeezellm'
DTYPE OPTIONAL, the data type for model weights. Needs to be "half" when "awq" is used
MAX_MODEL_LEN OPTIONAL, model context length. By default this is automatically derived from the model. Needs to be set to something low when using awq
EXTRA_ARGS OPTIONAL, Any additional command line arguments to pass along

Please see the vLLM source code of arg-utils.py for more details.

The container image automatically detects the number of GPUs and sets --tensor-parallel-size to be equal to number of GPUs available. The gpu-count.py script is used to detect number of GPUs.

Building

docker build -t ghcr.io/substratusai/vllm .

Helm Chart / K8s

Please see the vLLM helm chart that uses this image: substratusai/helm/vllm

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.