Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
0a399dc
ci: move unsigned builds to Tenki and isolate credentials on GitHub
Gajesh2007 Sep 21, 2026
ca78213
ci: use native SwiftPM resources and valid locale on Tenki
Gajesh2007 Sep 22, 2026
b1bebd5
ci: migrate landing checks to Tenki
Gajesh2007 Sep 22, 2026
7cd26bf
ci: preserve benchmark memory and scope reports by attempt
Gajesh2007 Sep 22, 2026
0cad157
Merge current master and move release trust boundary to Blacksmith
Gajesh2007 Sep 28, 2026
181cc19
docs: record Blacksmith release runner boundary
Gajesh2007 Sep 28, 2026
f3f6d50
ci: select Blacksmith Xcode 27 after checkout
Gajesh2007 Sep 28, 2026
e331628
docs: record Blacksmith image Xcode selection
Gajesh2007 Sep 28, 2026
1339565
ci: pin Python for Blacksmith macOS release jobs
Gajesh2007 Sep 28, 2026
bb0f7b2
docs: stamp Blacksmith Python runner guidance
Gajesh2007 Sep 28, 2026
4519866
ci: bootstrap pinned Rust and CMake on Blacksmith Macs
Gajesh2007 Sep 28, 2026
c095fd6
docs: stamp Blacksmith release tool bootstrap
Gajesh2007 Sep 28, 2026
391f6b1
Merge master and refresh Blacksmith runner policy
Gajesh2007 Sep 30, 2026
f48e909
Merge parallel provider CI and preserve Tenki runner boundary
Gajesh2007 Sep 30, 2026
a96b156
fix(ci): fingerprint selected Swift behind repository wrapper
Gajesh2007 Sep 30, 2026
c06c513
fix(ci): stabilize wrapped Swift cache identity across runners
Gajesh2007 Sep 30, 2026
dc5da82
fix(ci): assert toolchain setup before parallel provider gates
Gajesh2007 Sep 30, 2026
d85438c
fix(ci): bind metallib caches and qualification to release bootstraps
Gajesh2007 Sep 30, 2026
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
12 changes: 6 additions & 6 deletions .github/actionlint.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# actionlint runner-label vocabulary. The repo runs on Blacksmith-hosted
# runners, whose labels actionlint cannot know about; without this file every
# job flags [runner-label] and the lint is unusable as a gate.
# Tenki PR checks and Blacksmith release/credential runner labels.
self-hosted-runner:
labels:
- blacksmith-4vcpu-ubuntu-2404
- tenki-standard-medium-4c-8g
- tenki-macos-26-large
- blacksmith-12vcpu-macos-latest
- xcode-27
- xcode-27-xlarge
- blacksmith-12vcpu-macos-26
- blacksmith-12vcpu-macos-27
- blacksmith-4vcpu-ubuntu-2404
13 changes: 10 additions & 3 deletions .github/actions/provider-release-build/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ runs:
- name: Install pinned Rust for prompt parity
if: inputs.lane == 'qualification'
shell: bash
run: rustup toolchain install 1.88.0 --profile minimal
run: ./scripts/install-release-rust.sh
Comment thread
Gajesh2007 marked this conversation as resolved.
Resolved
- name: Resolve compatible build cache keys
id: keys
shell: bash
Expand Down Expand Up @@ -102,6 +102,9 @@ runs:
- name: Ensure matching Metal compiler is available
shell: bash
run: python3 scripts/prepare-metal-toolchain.py
- name: Install pinned CMake for Metal build
shell: bash
run: ./scripts/install-release-cmake.sh
Comment thread
Gajesh2007 marked this conversation as resolved.
Resolved
- name: Resolve source-matched metallib cache namespace
id: mlxkey
shell: bash
Expand All @@ -116,7 +119,11 @@ runs:
XCODE=$(xcodebuild -version | tr -cs '[:alnum:].' '-')
METAL_COMPILER=$(xcrun --no-cache --sdk macosx --find metal)
METAL_SHA=$(shasum -a 256 "$METAL_COMPILER" | cut -d' ' -f1)
echo "key=metallib-helper-v2-${MLX_SHA}-${HELPER_SHA}-${METAL_SHA}-${XCODE}-sdk${SDK}-dt${MLX_METALLIB_DEPLOYMENT_TARGET}-jitoff" >> "$GITHUB_OUTPUT"
CMAKE_COMPILER=$(command -v cmake)
CMAKE_VERSION=$(cmake --version)
CMAKE_BINARY_SHA=$(shasum -a 256 "$CMAKE_COMPILER" | cut -d' ' -f1)
CMAKE_SHA=$(printf '%s\n' "$CMAKE_VERSION" "$CMAKE_BINARY_SHA" | shasum -a 256 | cut -d' ' -f1)
echo "key=metallib-helper-v3-${MLX_SHA}-${HELPER_SHA}-${METAL_SHA}-${CMAKE_SHA}-${XCODE}-sdk${SDK}-dt${MLX_METALLIB_DEPLOYMENT_TARGET}-jitoff" >> "$GITHUB_OUTPUT"
echo "mlx_sha_short=${MLX_SHA:0:12}" >> "$GITHUB_OUTPUT"
- name: Restore source-matched metallib cache
id: metallib-cache
Expand All @@ -131,7 +138,7 @@ runs:
METALLIB_CACHE_DIR: ${{ runner.temp }}/metallib-cache
run: |
set -euo pipefail
command -v cmake >/dev/null 2>&1 || brew install cmake
cmake --version
MLX_SRC="libs/mlx-swift/Source/Cmlx/mlx"
./scripts/fetch-metallib.sh "$RUNNER_TEMP/metallib"
test -z "$(git -C "$MLX_SRC" status --porcelain=v1 --untracked-files=all)"
Expand Down
61 changes: 46 additions & 15 deletions .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# E2E load benchmarks, split out of integration.yml (v0.8.0 gate audit).
#
# WHY A SEPARATE WORKFLOW: this job runs under the `benchmarks` environment,
# WHY A SEPARATE WORKFLOW: the approval job uses the `benchmarks` environment,
# whose required-reviewer rule (repo Settings -> Environments -> benchmarks)
# makes every run wait for a manual approval — a deliberate cost control for
# a 45-minute macOS runner job that posts PR comments. While it shared a
Expand All @@ -21,24 +21,35 @@ on:

permissions:
contents: read
pull-requests: write

jobs:
approve:
name: Approve benchmark spend
runs-on: blacksmith-4vcpu-ubuntu-2404
environment: benchmarks
permissions: {}
steps:
- run: echo 'Benchmark run approved'

benchmark:
name: E2E Benchmarks
needs: approve
# Three simultaneous provider processes need at least the existing 48 GB
# host; Tenki's largest published macOS runner has 32 GB.
runs-on: blacksmith-12vcpu-macos-latest
timeout-minutes: 45
environment: benchmarks
env:
LC_ALL: en_US.UTF-8
DARKBLOOM_REPO_ROOT: ${{ github.workspace }}
TESTBED_PROVIDER_CONFIG: debug
BENCHMARK_MD_PATH: /tmp/benchmark-results.md
RUNNER_DESC: macos-15 (M1 Virtual)
RUNNER_DESC: Blacksmith macOS latest (12 vCPU, 48 GB)
GPT_OSS_REVISION: 773a7da77e569019bb0fd17a554b263738d669a3
GEMMA_REVISION: 0e3cbab38ce568cf6e23543010d08d03b731910c
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
submodules: recursive

- uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
Expand Down Expand Up @@ -87,18 +98,38 @@ jobs:
go test ./e2e/ -count=1 -v -timeout 40m -p=1 \
-run 'TestBenchmark'

- name: Post benchmark results
- name: Retain benchmark report
if: always()
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a
with:
name: benchmark-report-${{ github.run_attempt }}
path: /tmp/benchmark-results.md
if-no-files-found: warn
retention-days: 3

report:
name: Post benchmark results
needs: benchmark
if: ${{ !cancelled() && needs.benchmark.result != 'skipped' && github.event.pull_request.head.repo.full_name == github.repository }}
runs-on: blacksmith-4vcpu-ubuntu-2404
permissions:
actions: read
pull-requests: write
steps:
- name: Download and post report as data
env:
GH_TOKEN: ${{ github.token }}
GH_REPO: ${{ github.repository }}
PR_NUMBER: ${{ github.event.pull_request.number }}
run: |
if [ ! -f /tmp/benchmark-results.md ]; then
echo "No benchmark results file found"
set -euo pipefail
artifact_name="benchmark-report-$GITHUB_RUN_ATTEMPT"
artifact_id=$(gh api "repos/$GH_REPO/actions/runs/$GITHUB_RUN_ID/artifacts" \
--jq ".artifacts[] | select(.name == \"$artifact_name\" and .expired == false) | .id")
if [ -z "$artifact_id" ]; then
echo 'No benchmark report was produced'
exit 0
fi
BODY=$(cat /tmp/benchmark-results.md)
gh pr comment ${{ github.event.pull_request.number }} \
--body "$BODY" \
--edit-last \
|| gh pr comment ${{ github.event.pull_request.number }} \
--body "$BODY"
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
gh run download "$GITHUB_RUN_ID" --name "$artifact_name" --dir "$RUNNER_TEMP/report"
gh pr comment "$PR_NUMBER" --body-file "$RUNNER_TEMP/report/benchmark-results.md" --edit-last \
|| gh pr comment "$PR_NUMBER" --body-file "$RUNNER_TEMP/report/benchmark-results.md"
96 changes: 82 additions & 14 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,31 @@ on:
branches: [master, main]
pull_request:

permissions:
contents: read

jobs:
runner-policy:
name: CI Runner Policy
runs-on: tenki-standard-medium-4c-8g
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- name: Check runner and credential boundaries
run: |
python3 -m venv "$RUNNER_TEMP/runner-policy"
"$RUNNER_TEMP/runner-policy/bin/pip" install PyYAML==6.0.3
"$RUNNER_TEMP/runner-policy/bin/python" scripts/test-ci-runner-policy.py
"$RUNNER_TEMP/runner-policy/bin/python" scripts/check-ci-runner-policy.py

release-integrity:
name: Release Integrity
runs-on: blacksmith-4vcpu-ubuntu-2404
runs-on: tenki-standard-medium-4c-8g
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- name: Check source, fallback, and installer parity
run: |
./scripts/check-release-version.sh
Expand Down Expand Up @@ -44,10 +63,11 @@ jobs:

docs:
name: Docs Lint
runs-on: blacksmith-4vcpu-ubuntu-2404
runs-on: tenki-standard-medium-4c-8g
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
fetch-depth: 0 # Frozen source links require committed document provenance.
- name: Initialize pinned SDK documentation
run: git submodule update --init --depth 1 libs/mlx-swift-lm
Expand All @@ -60,7 +80,7 @@ jobs:

test-coordinator:
name: Coordinator Tests
runs-on: blacksmith-4vcpu-ubuntu-2404
runs-on: tenki-standard-medium-4c-8g
services:
postgres:
image: postgres:16
Expand All @@ -77,6 +97,8 @@ jobs:
--health-retries 5
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
with:
go-version-file: go.mod
Expand Down Expand Up @@ -130,9 +152,11 @@ jobs:

lint-coordinator:
name: Coordinator Lint
runs-on: blacksmith-4vcpu-ubuntu-2404
runs-on: tenki-standard-medium-4c-8g
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
with:
go-version-file: go.mod
Expand All @@ -143,9 +167,11 @@ jobs:

test-prompt-sidecar:
name: Prompt Sidecar Tests
runs-on: blacksmith-4vcpu-ubuntu-2404
runs-on: tenki-standard-medium-4c-8g
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
with:
go-version-file: go.mod
Expand Down Expand Up @@ -200,11 +226,21 @@ jobs:

test-provider:
name: Provider Unit Tests
runs-on: blacksmith-12vcpu-macos-latest
runs-on: tenki-macos-26-large
env:
DEVELOPER_DIR: /Applications/Xcode_27.0.app/Contents/Developer
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
submodules: recursive
- name: Verify Xcode 27 toolchain
run: |
xcodebuild -version
xcrun swift --version
test "$(xcrun --sdk macosx --show-sdk-version)" = '27.0'
- name: Select native SwiftPM resource layout
run: ./scripts/prepare-provider-release-toolchain.sh
- name: Build provider CI prerequisites
id: provider-ci-build
uses: ./.github/actions/provider-ci-build
Expand Down Expand Up @@ -265,11 +301,21 @@ jobs:

test-provider-sdk:
name: Provider SDK Tests
runs-on: blacksmith-12vcpu-macos-latest
runs-on: tenki-macos-26-large
env:
DEVELOPER_DIR: /Applications/Xcode_27.0.app/Contents/Developer
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
submodules: recursive
- name: Verify Xcode 27 toolchain
run: |
xcodebuild -version
xcrun swift --version
test "$(xcrun --sdk macosx --show-sdk-version)" = '27.0'
- name: Select native SwiftPM resource layout
run: ./scripts/prepare-provider-release-toolchain.sh
- name: Build SDK CI prerequisites
id: provider-ci-build
timeout-minutes: 35
Expand Down Expand Up @@ -383,11 +429,21 @@ jobs:

test-provider-parity:
name: Provider Prompt Parity
runs-on: blacksmith-12vcpu-macos-latest
runs-on: tenki-macos-26-large
env:
DEVELOPER_DIR: /Applications/Xcode_27.0.app/Contents/Developer
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
submodules: recursive
- name: Verify Xcode 27 toolchain
run: |
xcodebuild -version
xcrun swift --version
test "$(xcrun --sdk macosx --show-sdk-version)" = '27.0'
- name: Select native SwiftPM resource layout
run: ./scripts/prepare-provider-release-toolchain.sh
- uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5.3.0
with:
go-version-file: go.mod
Expand Down Expand Up @@ -416,7 +472,7 @@ jobs:

provider-test-gate:
name: Provider Tests
runs-on: blacksmith-4vcpu-ubuntu-2404
runs-on: tenki-standard-medium-4c-8g
needs: [test-provider, test-provider-sdk, test-provider-parity]
if: ${{ always() }}
steps:
Expand All @@ -432,12 +488,22 @@ jobs:

cache-swift:
name: Swift Build + Cache
runs-on: blacksmith-12vcpu-macos-latest
runs-on: tenki-macos-26-large
env:
DEVELOPER_DIR: /Applications/Xcode_27.0.app/Contents/Developer
if: github.event_name == 'push'
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
submodules: recursive
- name: Verify Xcode 27 toolchain
run: |
xcodebuild -version
xcrun swift --version
test "$(xcrun --sdk macosx --show-sdk-version)" = '27.0'
- name: Select native SwiftPM resource layout
run: ./scripts/prepare-provider-release-toolchain.sh
- name: Restore SwiftPM cache
uses: actions/cache/restore@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
with:
Expand All @@ -446,9 +512,9 @@ jobs:
~/Library/org.swift.swiftpm
provider-swift/.build
libs/mlx-swift-lm/.build
key: spm-v3-${{ runner.os }}-${{ github.sha }}-${{ hashFiles('provider-swift/Package.resolved', 'libs/mlx-swift/Package.swift', 'libs/mlx-swift-lm/Package.swift') }}
key: spm-tenki-xcode27-v1-${{ runner.os }}-${{ github.sha }}-${{ hashFiles('provider-swift/Package.resolved', 'libs/mlx-swift/Package.swift', 'libs/mlx-swift-lm/Package.swift') }}
restore-keys: |
spm-v3-${{ runner.os }}-
spm-tenki-xcode27-v1-${{ runner.os }}-
- name: Discard metallibs restored by the generic SwiftPM cache
run: |
for root in provider-swift/.build libs/mlx-swift-lm/.build; do
Expand All @@ -467,13 +533,15 @@ jobs:
~/Library/org.swift.swiftpm
provider-swift/.build
libs/mlx-swift-lm/.build
key: spm-v3-${{ runner.os }}-${{ github.sha }}-${{ hashFiles('provider-swift/Package.resolved', 'libs/mlx-swift/Package.swift', 'libs/mlx-swift-lm/Package.swift') }}
key: spm-tenki-xcode27-v1-${{ runner.os }}-${{ github.sha }}-${{ hashFiles('provider-swift/Package.resolved', 'libs/mlx-swift/Package.swift', 'libs/mlx-swift-lm/Package.swift') }}

lint-console:
name: Console UI Lint & Build
runs-on: blacksmith-4vcpu-ubuntu-2404
runs-on: tenki-standard-medium-4c-8g
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
persist-credentials: false
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0
with:
node-version: '22'
Expand Down
Loading
Loading