-
Notifications
You must be signed in to change notification settings - Fork 0
125 lines (110 loc) · 4.57 KB
/
Copy pathsmoke-reference.yml
File metadata and controls
125 lines (110 loc) · 4.57 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
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
name: Smoke Reference
# Runs the three reference-model smoke tests tagged `@Tag("smoke-reference")`:
# - Qwen3-1.7B Q8_0 GGUF (kllama runner)
# - Gemma-4 E2B SafeTensors (kgemma runner)
# - BERT + LEAF SafeTensors (llm-test-java)
#
# By default each test self-skips when its model artifact is not resolvable
# through the standard env-var / `~/.lmstudio/models/` / `~/.cache/huggingface/hub/`
# fallback chain, so this workflow is **green with empty inputs** — it merely
# proves the wiring compiles and the JUnit filter resolves the smoke tier.
#
# To make a run actually exercise the models, trigger it with the matching
# workflow inputs (URLs / paths). The job downloads each artifact, sets the
# corresponding env var the test reads (see Qwen3ReferenceSmokeTest.kt,
# Gemma4ReferenceSmokeTest.kt, BertLeafReferenceSmokeTest.java), and runs
# the same `./gradlew test -PsmokeReference -PincludeIntegration` invocation
# that's documented in the repo's CHANGELOG and reference-smoke tests.
#
# Trigger pattern is manual (`workflow_dispatch`) — wiring this onto every
# push would silently consume Actions minutes without doing meaningful work
# until artifacts are available. A self-hosted runner with the three
# checkpoints pre-cached on disk is the natural place to flip this to
# `push: branches: [develop]` later.
on:
workflow_dispatch:
inputs:
qwen3_gguf_url:
description: "Direct URL to Qwen3-1.7B-Q8_0.gguf (~1.9 GB). Leave blank to skip the kllama test."
required: false
default: ""
gemma4_safetensors_dir_url:
description: "Direct URL to a tar.gz containing the Gemma-4 E2B SafeTensors checkpoint directory. Leave blank to skip the kgemma test."
required: false
default: ""
leaf_safetensors_dir_url:
description: "Direct URL to a tar.gz containing the MongoDB mdbr-leaf-ir SafeTensors checkpoint directory. Leave blank to skip the BERT+LEAF test."
required: false
default: ""
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
smoke-reference:
runs-on: ubuntu-latest
timeout-minutes: 90
steps:
- name: Checkout
uses: actions/checkout@v6
- name: Copy CI gradle.properties
run: mkdir -p ~/.gradle ; cp .github/ci-gradle.properties ~/.gradle/gradle.properties
- name: Set up JDK 25
uses: actions/setup-java@v5
with:
distribution: 'zulu'
java-version: 25
- name: Disk space (before downloads)
run: df -h
- name: Stage Qwen3-1.7B Q8_0 GGUF
if: inputs.qwen3_gguf_url != ''
env:
URL: ${{ inputs.qwen3_gguf_url }}
run: |
set -euo pipefail
mkdir -p "$RUNNER_TEMP/models/qwen3"
curl -fsSL "$URL" -o "$RUNNER_TEMP/models/qwen3/Qwen3-1.7B-Q8_0.gguf"
echo "QWEN3_1B7_MODEL_PATH=$RUNNER_TEMP/models/qwen3/Qwen3-1.7B-Q8_0.gguf" >> "$GITHUB_ENV"
- name: Stage Gemma-4 E2B SafeTensors
if: inputs.gemma4_safetensors_dir_url != ''
env:
URL: ${{ inputs.gemma4_safetensors_dir_url }}
run: |
set -euo pipefail
mkdir -p "$RUNNER_TEMP/models/gemma4"
curl -fsSL "$URL" | tar -xz -C "$RUNNER_TEMP/models/gemma4"
echo "GEMMA4_E2B_SAFETENSORS_PATH=$RUNNER_TEMP/models/gemma4" >> "$GITHUB_ENV"
- name: Stage MongoDB LEAF SafeTensors
if: inputs.leaf_safetensors_dir_url != ''
env:
URL: ${{ inputs.leaf_safetensors_dir_url }}
run: |
set -euo pipefail
mkdir -p "$RUNNER_TEMP/models/leaf"
curl -fsSL "$URL" | tar -xz -C "$RUNNER_TEMP/models/leaf"
echo "LEAF_MODEL_DIR=$RUNNER_TEMP/models/leaf" >> "$GITHUB_ENV"
- name: Run smoke-reference tier
env:
GRADLE_OPTS: -Dorg.gradle.jvmargs="-Xmx4g -Dfile.encoding=UTF-8"
run: |
./gradlew --no-daemon --stacktrace \
-Dorg.gradle.caching=true \
-Dorg.gradle.configuration-cache=true \
-PsmokeReference -PincludeIntegration \
test
- name: Disk space (after run)
if: always()
run: df -h || true
- name: Memory info (on failure)
if: failure()
run: |
free -h || true
cat /proc/meminfo | head -n 50 || true
- name: Upload smoke-reference test reports
if: always()
uses: actions/upload-artifact@v7
with:
name: smoke-reference-reports
path: |
**/build/reports/tests/**
**/build/test-results/**
retention-days: 14