You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/docker.md
+44-52Lines changed: 44 additions & 52 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,76 +10,68 @@ specific GPU generation, for example `120` for Blackwell or `86` for RTX 3090.
10
10
* Create a folder to store big models & intermediate files (ex. /llama/models)
11
11
12
12
## Images
13
-
We have three Docker images available for this project:
14
-
15
-
1.`ghcr.io/anbeeld/beellama.cpp:full`: This image includes both the `llama-cli` and `llama-completion` executables and the tools to convert LLaMA models into ggml and convert into 4-bit quantization. (platforms: `linux/amd64`, `linux/arm64`, `linux/s390x`)
16
-
2.`ghcr.io/anbeeld/beellama.cpp:light`: This image only includes the `llama-cli` and `llama-completion` executables. (platforms: `linux/amd64`, `linux/arm64`, `linux/s390x`)
17
-
3.`ghcr.io/anbeeld/beellama.cpp:server`: This image only includes the `llama-server` executable. (platforms: `linux/amd64`, `linux/arm64`, `linux/s390x`)
18
-
19
-
Additionally, there the following images, similar to the above:
20
-
21
-
-`ghcr.io/anbeeld/beellama.cpp:full-cuda`: Same as `full` but compiled with CUDA 12 support. (platforms: `linux/amd64`, `linux/arm64`)
22
-
-`ghcr.io/anbeeld/beellama.cpp:full-cuda13`: Same as `full` but compiled with CUDA 13 support. (platforms: `linux/amd64`, `linux/arm64`)
23
-
-`ghcr.io/anbeeld/beellama.cpp:light-cuda`: Same as `light` but compiled with CUDA 12 support. (platforms: `linux/amd64`, `linux/arm64`)
24
-
-`ghcr.io/anbeeld/beellama.cpp:light-cuda13`: Same as `light` but compiled with CUDA 13 support. (platforms: `linux/amd64`, `linux/arm64`)
25
-
-`ghcr.io/anbeeld/beellama.cpp:server-cuda`: Same as `server` but compiled with CUDA 12.4 support. (platforms: `linux/amd64`)
26
-
-`ghcr.io/anbeeld/beellama.cpp:server-cuda13`: Same as `server` but compiled with CUDA 13.1 support. (platforms: `linux/amd64`)
27
-
-`ghcr.io/anbeeld/beellama.cpp:full-rocm`: Same as `full` but compiled with ROCm support. (platforms: `linux/amd64`)
28
-
-`ghcr.io/anbeeld/beellama.cpp:light-rocm`: Same as `light` but compiled with ROCm support. (platforms: `linux/amd64`)
29
-
-`ghcr.io/anbeeld/beellama.cpp:server-rocm`: Same as `server` but compiled with ROCm support. (platforms: `linux/amd64`)
30
-
-`ghcr.io/anbeeld/beellama.cpp:full-musa`: Same as `full` but compiled with MUSA support. (platforms: `linux/amd64`)
31
-
-`ghcr.io/anbeeld/beellama.cpp:light-musa`: Same as `light` but compiled with MUSA support. (platforms: `linux/amd64`)
32
-
-`ghcr.io/anbeeld/beellama.cpp:server-musa`: Same as `server` but compiled with MUSA support. (platforms: `linux/amd64`)
33
-
-`ghcr.io/anbeeld/beellama.cpp:full-intel`: Same as `full` but compiled with SYCL support. (platforms: `linux/amd64`)
34
-
-`ghcr.io/anbeeld/beellama.cpp:light-intel`: Same as `light` but compiled with SYCL support. (platforms: `linux/amd64`)
35
-
-`ghcr.io/anbeeld/beellama.cpp:server-intel`: Same as `server` but compiled with SYCL support. (platforms: `linux/amd64`)
36
-
-`ghcr.io/anbeeld/beellama.cpp:full-vulkan`: Same as `full` but compiled with Vulkan support. (platforms: `linux/amd64`, `linux/arm64`)
37
-
-`ghcr.io/anbeeld/beellama.cpp:light-vulkan`: Same as `light` but compiled with Vulkan support. (platforms: `linux/amd64`, `linux/arm64`)
38
-
-`ghcr.io/anbeeld/beellama.cpp:server-vulkan`: Same as `server` but compiled with Vulkan support. (platforms: `linux/amd64`, `linux/arm64`)
39
-
-`ghcr.io/anbeeld/beellama.cpp:full-openvino`: Same as `full` but compiled with OpenVino support. (platforms: `linux/amd64`)
40
-
-`ghcr.io/anbeeld/beellama.cpp:light-openvino`: Same as `light` but compiled with OpenVino support. (platforms: `linux/amd64`)
41
-
-`ghcr.io/anbeeld/beellama.cpp:server-openvino`: Same as `server` but compiled with OpenVino support. (platforms: `linux/amd64`)
42
-
-`ghcr.io/anbeeld/beellama.cpp:full-s390x`: Identical to `full`, an alias for the `s390x` platform. (platforms: `linux/s390x`)
43
-
-`ghcr.io/anbeeld/beellama.cpp:light-s390x`: Identical to `light`, an alias for the `s390x` platform. (platforms: `linux/s390x`)
44
-
-`ghcr.io/anbeeld/beellama.cpp:server-s390x`: Identical to `server`, an alias for the `s390x` platform. (platforms: `linux/s390x`)
45
-
46
-
The GPU enabled images are not currently tested by CI beyond being built. They are not built with any variation from the ones in the Dockerfiles defined in [.devops/](../.devops/) and the GitHub Action defined in [.github/workflows/docker.yml](../.github/workflows/docker.yml). If you need different settings (for example, a different CUDA, ROCm or MUSA library, you'll need to build the images locally for now).
13
+
The CI workflow publishes `llama-server` images to
14
+
`ghcr.io/anbeeld/beellama.cpp`:
47
15
48
-
## Usage
16
+
-`server` / `server-cpu`: CPU backend. (`linux/amd64`, `linux/arm64`)
17
+
-`server-cuda` / `server-cuda12`: CUDA 12.4 backend. (`linux/amd64`)
18
+
-`server-cuda13`: CUDA 13.1 backend. (`linux/amd64`)
19
+
-`server-rocm`: ROCm backend. (`linux/amd64`)
20
+
-`server-vulkan`: Vulkan backend. (`linux/amd64`)
21
+
-`server-sycl`: SYCL backend for Intel GPUs. (`linux/amd64`)
22
+
23
+
Release tags are published as both floating tags such as `server-sycl` and
24
+
versioned tags such as `server-sycl-v0.3.0`. Branch builds use development tags
25
+
such as `server-sycl-v0.3.0-dev` and commit-specific tags such as
26
+
`server-sycl-v0.3.0-<short-sha>`.
49
27
50
-
The easiest way to download the models, convert them to ggml and optimize them is with the --all-in-one command which includes the full docker image.
28
+
The SYCL image is built as a generic Intel SYCL target. It intentionally does
29
+
not set `GGML_SYCL_DEVICE_ARCH`, so device code is selected by the oneAPI
30
+
runtime for the host Intel GPU instead of being pinned to one GPU generation.
31
+
32
+
## Usage
51
33
52
34
Replace `/path/to/models` below with the actual path where you downloaded the models.
53
35
54
36
```bash
55
-
docker run -v /path/to/models:/models ghcr.io/anbeeld/beellama.cpp:full --all-in-one "/models/" 7B
Use the backend-specific server tag for GPU acceleration. For example:
59
45
60
46
```bash
61
-
docker run -v /path/to/models:/models ghcr.io/anbeeld/beellama.cpp:full --run -m /models/7B/ggml-model-q4_0.gguf
62
-
docker run -v /path/to/models:/models ghcr.io/anbeeld/beellama.cpp:full --run-legacy -m /models/32B/ggml-model-q8_0.gguf -no-cnv -p "Building a mobile app can be done in 15 steps:" -n 512
docker run -v /path/to/models:/models --entrypoint /app/llama-cli ghcr.io/anbeeld/beellama.cpp:light -m /models/7B/ggml-model-q4_0.gguf
69
-
docker run -v /path/to/models:/models --entrypoint /app/llama-completion ghcr.io/anbeeld/beellama.cpp:light -m /models/32B/ggml-model-q8_0.gguf -no-cnv -p "Building a mobile app can be done in 15 steps:" -n 512
70
-
```
56
+
Assuming one has the [nvidia-container-toolkit](https://github.com/NVIDIA/nvidia-container-toolkit) properly installed on Linux, or is using a GPU enabled cloud, `cuBLAS` should be accessible inside the container.
57
+
58
+
## Docker With SYCL
71
59
72
-
or with a server image:
60
+
The SYCL image targets Intel GPUs through oneAPI and Level Zero. The host still
61
+
needs a working Intel GPU driver stack, and the container needs access to the
In the above examples, `--entrypoint /app/llama-cli` is specified for clarity, but you can safely omit it since it's the default entrypoint in the container.
79
-
80
-
## Docker With CUDA
81
-
82
-
Assuming one has the [nvidia-container-toolkit](https://github.com/NVIDIA/nvidia-container-toolkit) properly installed on Linux, or is using a GPU enabled cloud, `cuBLAS` should be accessible inside the container.
73
+
Set `ONEAPI_DEVICE_SELECTOR=level_zero:<index>` if the host has multiple Intel
74
+
GPU devices and you need to choose one explicitly.
0 commit comments