-
-
Notifications
You must be signed in to change notification settings - Fork 2
67 lines (52 loc) · 1.66 KB
/
Copy pathci.yml
File metadata and controls
67 lines (52 loc) · 1.66 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
name: CI
on:
push:
branches: [master]
pull_request:
branches: [master]
env:
LLAMA_CPP_VERSION: b7356
LLAMA_MODEL_REPO: ggml-org/bge-m3-Q8_0-GGUF
LLAMA_MODEL_FILE: bge-m3-q8_0.gguf
jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v6
with:
node-version: 23
- run: npm install
- run: npm run build
- run: npm run check
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-node@v6
with:
node-version: 23
- name: Cache llama.cpp
id: cache-llama
uses: actions/cache@v6
with:
path: ~/.local/llama-cpp
key: llama-cpp-${{ env.LLAMA_CPP_VERSION }}-ubuntu-x64
- name: Download llama.cpp prebuilt binary
if: steps.cache-llama.outputs.cache-hit != 'true'
run: |
mkdir -p ~/.local/llama-cpp
curl -L "https://github.com/ggml-org/llama.cpp/releases/download/${{ env.LLAMA_CPP_VERSION }}/llama-${{ env.LLAMA_CPP_VERSION }}-bin-ubuntu-x64.tar.gz" \
| tar -xz -C ~/.local/llama-cpp --no-same-owner --strip-components=1
- name: Add llama.cpp to PATH and LD_LIBRARY_PATH
run: |
echo "$HOME/.local/llama-cpp" >> $GITHUB_PATH
echo "LD_LIBRARY_PATH=$HOME/.local/llama-cpp:$LD_LIBRARY_PATH" >> $GITHUB_ENV
- name: Cache embedding models
uses: actions/cache@v6
with:
path: ~/.cache/llama.cpp
key:
llama-model-${{ env.LLAMA_MODEL_REPO }}-${{ env.LLAMA_MODEL_FILE }}
- run: npm install
- run: npm run test