Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Docs: consolidate build-from-source and GPU backend guide

未关闭 适合新手
#2,314 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
75/100
Issue 类型
文档
描述清晰度
描述清楚
活跃度
冷清
技术栈
cmake, python

调研方向

该 issue 指向整合构建文档,可能在 docs/build.md 或新的 docs/gpu.md 中。首先,请查看现有的 README、CONTRIBUTING.md 以及链接的 GitHub issues(#2013、#695、#721、#756),以了解当前分散的信息。然后,为每个 GPU 后端创建一个清晰的 CMAKE_ARGS 表格,并添加常见错误的故障排除步骤。通过使用 GPU 后端构建项目来验证更改,确保说明有效。

由索引模型根据 Issue 内容生成。

描述

Problem

The build-from-source documentation is spread across README, CONTRIBUTING.md, and many GitHub issues (e.g. #2013, #695, #721, #756). Users with newer GPUs (RTX 50-series, sm_120) or uncommon CUDA versions repeatedly hit the same build failures because the docs lack:

  1. A CMAKE_ARGS mapping table showing which flag to set for each GPU backend
  2. CUDA version compatibility notes (e.g., CUDA 12.9+ requires specific cmake workarounds)
  3. The minimum/maximum supported CUDA toolkit versions
  4. How to verify the build actually used the GPU (simple Python snippet to check backend)

Suggested improvements

In docs/build.md (or a new docs/gpu.md):

| Backend | CMAKE_ARGS                                    | GPU Requirements              |
|---------|-----------------------------------------------|-------------------------------|
| CUDA    | -DGGML_CUDA=ON                                | NVIDIA GPU, CUDA >= 11.3      |
| Metal   | -DGGML_METAL=ON (default on macOS)            | Apple Silicon or AMD GPU      |
| Vulkan  | -DGGML_VULKAN=ON                              | Vulkan 1.2+ capable GPU       |
| SYCL    | -DGGML_SYCL=ON -DGGML_SYCL_TARGET=INTEL       | Intel Arc / Iris Xe           |
| HIP     | -DGGML_HIPBLAS=ON                             | AMD ROCm-compatible GPU       |

And a troubleshooting section for the most common build errors (CMake not finding CUDA, nvcc version mismatch, sm_120 not recognized).

Value

Consolidating this reduces the "can't install with GPU" issues that currently fill the tracker.

主要语言
Python
星标
10.6k
派生
1.5k
平均合并
6 小时 43 分钟
30 天内合并 PR
2

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

abetlen/llama-cpp-python 的其他 Issue

查看 abetlen/llama-cpp-python 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。