File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,7 +2,7 @@ name: Build
22
33on :
44 push :
5- branches : [main]
5+ branches : [main, develop ]
66 pull_request :
77 branches : [main]
88
1515 - name : Install Metal Toolchain
1616 run : xcodebuild -downloadComponent MetalToolchain || true
1717
18+ - name : Cache Swift packages
19+ uses : actions/cache@v4
20+ with :
21+ path : .build
22+ key : ${{ runner.os }}-spm-${{ hashFiles('Package.resolved') }}
23+ restore-keys : |
24+ ${{ runner.os }}-spm-
25+
1826 - name : Resolve dependencies
1927 run : swift package resolve
2028
2533 run : |
2634 ls -lh .build/release/mlx-server
2735 file .build/release/mlx-server
28-
29- - name : Upload binary
30- uses : actions/upload-artifact@v4
31- with :
32- name : mlx-server-arm64
33- path : .build/release/mlx-server
34- retention-days : 30
Original file line number Diff line number Diff line change 1+ name : E2E Tests
2+
3+ on :
4+ push :
5+ branches : [main, feature/*]
6+ pull_request :
7+ branches : [main]
8+
9+ concurrency :
10+ group : e2e-${{ github.ref }}
11+ cancel-in-progress : true
12+
13+ jobs :
14+ e2e :
15+ runs-on : macos-15
16+ timeout-minutes : 30
17+
18+ steps :
19+ - uses : actions/checkout@v4
20+
21+ - name : Cache Swift packages
22+ uses : actions/cache@v4
23+ with :
24+ path : .build
25+ key : ${{ runner.os }}-spm-${{ hashFiles('Package.resolved') }}
26+ restore-keys : |
27+ ${{ runner.os }}-spm-
28+
29+ - name : Build (Release)
30+ run : swift build -c release
31+
32+ - name : Install MLX Metal library
33+ run : |
34+ python3 -m venv /tmp/mlx_venv
35+ /tmp/mlx_venv/bin/pip install --quiet mlx
36+ cp /tmp/mlx_venv/lib/python*/site-packages/mlx/lib/mlx.metallib .build/release/
37+
38+ - name : Cache MLX model
39+ uses : actions/cache@v4
40+ with :
41+ path : ~/.cache/huggingface
42+ key : mlx-model-qwen2.5-0.5b-4bit
43+
44+ - name : Run E2E tests
45+ run : |
46+ chmod +x tests/test-server.sh
47+ tests/test-server.sh .build/release/mlx-server 15413
48+
49+ - name : Upload test logs on failure
50+ if : failure()
51+ uses : actions/upload-artifact@v4
52+ with :
53+ name : e2e-test-logs
54+ path : /tmp/mlx-server-test-*.log
55+ retention-days : 7
Original file line number Diff line number Diff line change @@ -23,6 +23,7 @@ let package = Package(
2323 dependencies: [
2424 . product( name: " MLX " , package : " mlx-swift " ) ,
2525 . product( name: " MLXLLM " , package : " mlx-swift-lm " ) ,
26+ . product( name: " MLXVLM " , package : " mlx-swift-lm " ) ,
2627 . product( name: " MLXLMCommon " , package : " mlx-swift-lm " ) ,
2728 . product( name: " Transformers " , package : " swift-transformers " ) ,
2829 . product( name: " Hummingbird " , package : " hummingbird " ) ,
You can’t perform that action at this time.
0 commit comments