Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 12 additions & 26 deletions .github/workflows/build-and-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-22.04, windows-2022, macos-14, macos-15]
# Keep the Apple Silicon release build on macos-14 and use an explicit
# Intel runner for the x86_64 wheel so each macOS job produces a
# distinct artifact.
os: [ubuntu-22.04, windows-2022, macos-14, macos-15-intel]

steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -82,7 +85,9 @@ jobs:
# Keep native arm64 builds on a portable CPU baseline instead of
# tuning wheels to the hosted runner.
CIBW_ENVIRONMENT: CMAKE_ARGS="-DGGML_NATIVE=off"
CIBW_BUILD: "cp38-* cp39-* cp310-* cp311-* cp312-*"
# wheel.py-api = "py3" means one aarch64 build covers every supported
# CPython version, so building more just duplicates the artifact name.
CIBW_BUILD: "cp38-*"
with:
output-dir: wheelhouse

Expand All @@ -93,27 +98,8 @@ jobs:
path: ./wheelhouse/*.whl

build_wheels_riscv64:
name: Build riscv64 wheels (${{ matrix.shard.name }})
name: Build riscv64 wheels
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
shard:
- name: cp310
build: "cp310-*"
artifact: wheels_riscv64_cp310
- name: cp311
build: "cp311-*"
artifact: wheels_riscv64_cp311
- name: cp312
build: "cp312-*"
artifact: wheels_riscv64_cp312
- name: cp313
build: "cp313-*"
artifact: wheels_riscv64_cp313
- name: cp314
build: "cp314-*"
artifact: wheels_riscv64_cp314
steps:
- uses: actions/checkout@v4
with:
Expand All @@ -133,16 +119,16 @@ jobs:
# Build riscv64 wheels against a conservative baseline instead of
# enabling RVV-related extensions from the build container.
CIBW_ENVIRONMENT: CMAKE_ARGS="-DGGML_NATIVE=off -DGGML_RVV=off -DGGML_RV_ZFH=off -DGGML_RV_ZVFH=off -DGGML_RV_ZICBOP=off -DGGML_RV_ZIHINTPAUSE=off"
# Split the emulated riscv64 build into one Python version per job
# to minimize wall-clock time without changing the release artifacts.
CIBW_BUILD: ${{ matrix.shard.build }}
# wheel.py-api = "py3" means one riscv64 build covers every supported
# CPython version, so sharding by interpreter only duplicates assets.
CIBW_BUILD: "cp310-*"
with:
output-dir: wheelhouse

- name: Upload wheels as artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.shard.artifact }}
name: wheels_riscv64
path: ./wheelhouse/*.whl

build_sdist:
Expand Down
4 changes: 3 additions & 1 deletion .github/workflows/build-wheels-cuda.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@ jobs:
run: |
$matrix = @{
'os' = @('ubuntu-22.04') #, 'windows-2022')
'pyver' = @("3.9", "3.10", "3.11", "3.12")
# wheel.py-api = "py3" makes the CUDA wheel interpreter-agnostic,
# so one builder per toolkit version is sufficient.
'pyver' = @("3.9")
'cuda' = @("12.1.1", "12.2.2", "12.3.2", "12.4.1") #, "12.5.1", "12.6.1")
'releasetag' = @("basic")
}
Expand Down
7 changes: 5 additions & 2 deletions .github/workflows/build-wheels-metal.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,17 @@ jobs:
CIBW_REPAIR_WHEEL_COMMAND: ""
CIBW_ARCHS: "arm64"
CIBW_ENVIRONMENT: CMAKE_ARGS="-DCMAKE_OSX_ARCHITECTURES=arm64 -DCMAKE_APPLE_SILICON_PROCESSOR=arm64 -DGGML_METAL=on -DCMAKE_CROSSCOMPILING=ON"
CIBW_BUILD: "cp39-* cp310-* cp311-* cp312-*"
# wheel.py-api = "py3" means one Metal wheel covers every supported
# CPython version, so extra selectors only repeat the same artifact.
CIBW_BUILD: "cp39-*"
with:
package-dir: .
output-dir: wheelhouse2

- uses: actions/upload-artifact@v4
if: matrix.os == 'macos-14'
with:
name: wheels-mac_${{ matrix.os }}
name: wheels-mac
path: ./wheelhouse2/*.whl

release:
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

- fix(ci): Avoid duplicate `py3-none` release builds across wheel workflows by @abetlen in #2172

## [0.3.20]

- refactor: Replace deprecated llama.cpp references in library, docs, and examples by @abetlen in #2170
Expand Down
Loading