Repository navigation
Conversation
var_backend now covers all Linux builds llama.cpp publishes, each with the runtime its release workflow builds against: - cuda: CUDA 12 or 13 build chosen from the host driver (<580 -> 12), plus the matching cudart tarball deployed into /opt/llama-cpp - rocm: ubuntu-rocm-<ver>-x64 with the same ROCm release of AMD's TheRock wheels (rocm[libraries]) in a uv venv, added to LD_LIBRARY_PATH; updates follow upstream when the build moves to a newer ROCm - sycl-fp16 / sycl-fp32: oneAPI runtime libraries from Intel's apt repo, registered with ld.so; Level Zero loader from oneapi-src/level-zero and libze-intel-gpu1 from intel/compute-runtime - openvino: libtbb12, OpenCL ICD loader and Level Zero; GGML_OPENVINO_DEVICE is set to GPU when a render node is present auto stays the default (Vulkan with a GPU, otherwise CPU). The rocm->vulkan remap and the "no Linux ROCm/CUDA build" comments are gone, since upstream now ships both. Release lookups use the b tag prefix, the only tags carrying binaries, and updates keep the recorded backend. The install-time variables are now exported from the CT script so app_vars actually reach the container. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Try this script
COMMUNITY_SCRIPTS_URL=https://raw.githubusercontent.com/cosmincc/PVE-DevScripts/feat/llama-cpp-backends \
bash -c "$(curl -fsSL https://raw.githubusercontent.com/cosmincc/PVE-DevScripts/feat/llama-cpp-backends/ct/llama-cpp.sh)"
Against a core branch as wellAdd Useful flags while testing
|
Go test it. |
|
I'd love to test it by I haven't been able since the script is disabled:
I've been looking on how to circumvent that locally, but haven't yet found a way. |
|
var_ignore_disable='yes' before bash call |
…ting - Ask for the build on the Proxmox host with a whiptail menu (auto, cpu, vulkan, cuda, plus rocm/sycl/openvino on amd64) instead of inside the container, where the installer never has a terminal. Cancel exits; no terminal or a preset var_backend skips the menu - Match the Level Zero loader as libze1_*u24.04_amd64.deb: GitHub encodes the + in the asset URL as %2B, so the old pattern fell back to libze-dev - SYCL: write the persistent kernel cache commented out, it stopped models from loading on an Intel GPU - Add LLAMA_ARG_MODELS_DIR for router-mode model switching once LLAMA_ARG_HF_REPO is commented out - Release channels: bNNNN builds are now prereleases and stable vX.Y.Z releases carry only nightly-tag.txt. By default install the build the latest stable release names; GH_INCLUDE_PRERELEASE=1 follows the bNNNN builds. The channel is recorded in /opt/llama-cpp_data/.prerelease and updates keep it unless overridden; older installs count as nightly - Default model ggml-org/gemma-4-E2B-it-GGUF:Q4_0 (the previous default did not load on OpenVINO), still overridable with var_model_repo Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…ends # Conflicts: # json/llama-cpp.json
|
Successfully tested sycl-fp16 and openvino backends for llama.cpp. The bXXXX releases are prereleases so initially had to use With OpenVINO the default model was not loading (likely due to being unquantized). |
Requested by Cosmin
✍️ Description
var_backendin the llama.cpp script now covers every Linux prebuilt llama.cpp publishes. Each backend gets the runtime that upstream's.github/workflows/release.ymlbuilds against:cudart-llama-*tarball is also deployed into/opt/llama-cpp.ubuntu-rocm-<ver>-x64, plus the same ROCm release of AMD's TheRock wheels (rocm[libraries]==<ver>.*fromstable.repo.amd.com/rocm/whl-next/) in auvvenv, which is added toLD_LIBRARY_PATH. On update, the runtime follows when upstream moves the build to a newer ROCm.intel-oneapi-runtime-libsfrom Intel's oneAPI apt repo (viasetup_deb822_repo), with its lib dirs registered inld.so.conf.d. Also installs the Level Zero loader (libze1_*u24.04_amd64.debfrom oneapi-src/level-zero, as in release.yml) andlibze-intel-gpu1from intel/compute-runtime. The persistent SYCL kernel cache is written commented out, because it stopped models from loading on an Intel GPU in testing.ubuntu-openvino-*-x64withlibtbb12,ocl-icd-libopencl1and Level Zero.GGML_OPENVINO_DEVICE=GPUis set when/dev/dri/renderD*exists, otherwiseCPU.Choosing the build: when
var_backendisn't set,ct/llama-cpp.shasks on the Proxmox host with a whiptail menu titled "LLAMA.CPP BUILD", with auto preselected and no timeout. The installer itself runs underlxc-attachwith no terminal, so a prompt there could never be answered. rocm, sycl and openvino are offered only on amd64 hosts. Cancel exits; with no terminal, the menu is skipped and auto is used. The choice is exported into the container and recorded in/opt/llama-cpp_data/.backend, and updates keep it.Release channels: llama.cpp now flags every
bNNNNbuild (the only releases with binaries) as a prerelease, and its stablevX.Y.Zreleases ship onlynightly-tag.txt, which names the build they were cut from.GH_INCLUDE_PRERELEASE=1, it follows the newestbNNNNbuild using thebtag prefix./opt/llama-cpp_data/.prerelease. Updates follow it unlessGH_INCLUDE_PRERELEASEis set for that run. Installs from before this change count as nightly, so they aren't downgraded.Other changes:
ggml-org/gemma-4-E2B-it-GGUF:Q4_0, because the old default didn't load on OpenVINO. It can still be changed withvar_model_repo.LLAMA_ARG_MODELS_DIR=/opt/llama-cpp_data/modelsis written to the env file. OnceLLAMA_ARG_HF_REPOis commented out, llama-server runs in router mode and you can switch between the models in that folder.var_backend,var_model_repo,var_ctx_size,var_offload_layers,var_api_keyandvar_portare now exported from the CT script. Before this they were declared inapp_varsbut never reached the container.rocmbut has no ROCm runtime keeps updating as Vulkan.var_backendoptions and the new default model. The notes were re-fitted to upstream's 3-note limit after the recent "jsons" cleanup.🔗 Related PR / Issue
Link: #2124
✅ Prerequisites (X in brackets)
"Tested thoroughly" is left unticked because not every backend was tested on hardware; see "Tested on" below.
🏗️ arm64 Support (X in brackets)
var_arm64is left as it was. cpu, vulkan and cuda (13 only) have arm64 assets. rocm, sycl and openvino are x64 only: the host menu hides them on arm64, and the install stops with a clear error if one is set anyway.🖥️ Tested on (X in brackets)
Proxmox VE, Debian 13 LXC: fresh installs of auto (Vulkan), sycl-fp16 and openvino; each installed with the right dependencies. cpu, cuda, rocm and sycl-fp32 were not tested on hardware.
🛠️ Type of Change (X in brackets)
README,AppName.md,CONTRIBUTING.md, or other docs.🔍 Code & Security Review (X in brackets)
CODE-AUDIT.md&CONTRIBUTING.mdguidelinesAppName.sh,AppName-install.sh,AppName.json)fetch_and_deploy_gh_release,fetch_and_deploy_codeberg_release,fetch_and_deploy_gl_release, orfetch_and_deploy_from_urlinstead ofgit pull.🤖 AI Assistance (X in brackets)
AGENTS.mdand.github/agents/pve-script-creator.agent.mdas guidance, and the output has been reviewed and corrected to match those guidelines.Claude Code (Claude Opus, low reasoning effort) wrote the changes. It checked helper signatures against community-scripts/core and asset names against the llama.cpp releases. I tested on Proxmox VE and reported issues, which were then fixed: the in-container prompt, the Level Zero asset match, the SYCL cache, prerelease handling and the default model. shellcheck shows only the
sourcewarnings every script in the repo has.📋 Additional Information (optional)
libze1_*u24.04_amd64.deb, because GitHub writes the+in the download URL as%2B. The previouslibze1_*+u24.04…never matched, so the engine fell back tolibze-dev.ubuntu-cuda-12.8-x64,ubuntu-cuda-13.4-{x64,arm64}(+cudart-),ubuntu-rocm-10.0-x64,ubuntu-sycl-{fp16,fp32}-x64,ubuntu-openvino-*-x64,ubuntu-vulkan-{x64,arm64},ubuntu-{x64,arm64}.📦 Application Requirements (for new scripts)
🌐 Source
.github/workflows/release.ymlfor the per-backend build dependencies)🤖 Generated with Claude Code