forked from openvinotoolkit/openvino.genai
-
Notifications
You must be signed in to change notification settings - Fork 0
580 lines (506 loc) · 22 KB
/
windows.yml
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
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
name: Windows (VS 2022, Python 3.11)
on:
workflow_dispatch:
pull_request:
merge_group:
push:
branches:
- master
- 'releases/**'
permissions: read-all # Required by https://github.com/ossf/scorecard/blob/e23b8ad91fd6a64a0a971ca4fc0a4d1650725615/docs/checks.md#token-permissions
concurrency:
# github.ref is not unique in post-commit
group: ${{ github.event_name == 'push' && github.run_id || github.ref }}-windows
cancel-in-progress: true
env:
PYTHON_VERSION: '3.11'
TARGET_BRANCH: 'master'
PYTHONIOENCODING: "utf8"
CMAKE_CXX_COMPILER_LAUNCHER: ccache
CMAKE_C_COMPILER_LAUNCHER: ccache
CCACHE_MAXSIZE: 500Mi
jobs:
openvino_download:
name: Download prebuilt OpenVINO
outputs:
status: ${{ steps.openvino_download.outcome }}
ov_artifact_name: ${{ steps.openvino_download.outputs.ov_artifact_name }}
ov_wheel_source: ${{ steps.openvino_download.outputs.ov_wheel_source }}
ov_version: ${{ steps.openvino_download.outputs.ov_version }}
timeout-minutes: 10
defaults:
run:
shell: bash
runs-on: aks-linux-2-cores-8gb
container:
image: 'openvinogithubactions.azurecr.io/openvino_provider:0.1.0'
volumes:
- /mount:/mount
- ${{ github.workspace }}:${{ github.workspace }}
continue-on-error: true
steps:
- uses: openvinotoolkit/openvino/.github/actions/openvino_provider@master
id: openvino_download
with:
platform: 'windows'
commit_packages_to_provide: wheels,openvino_js_package.zip
revision: 'latest_available_commit'
genai_build_cpack:
name: genai cpack (${{ matrix.build_type }})
strategy:
matrix:
build_type: [Release, Debug]
needs: [ openvino_download ]
timeout-minutes: 30
defaults:
run:
shell: pwsh
runs-on: aks-win-8-cores-16gb
env:
OV_INSTALL_DIR: ${{ github.workspace }}\install\ov
GENAI_INSTALL_DIR: ${{ github.workspace }}\install\genai
SRC_DIR: ${{ github.workspace }}\src\genai
BUILD_DIR: ${{ github.workspace }}\build\genai
CCACHE_DIR: ${{ github.workspace }}\ccache
steps:
- name: Clone genai
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
submodules: recursive
path: ${{ env.SRC_DIR }}
- name: Setup Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
with:
python-version: ${{ env.PYTHON_VERSION }}
- name: Download OpenVINO package
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: ${{ needs.openvino_download.outputs.ov_artifact_name }}
path: ${{ env.OV_INSTALL_DIR }}
merge-multiple: true
#
# Build
#
- name: Install build dependencies
run: |
Invoke-WebRequest https://github.com/ninja-build/ninja/releases/download/v1.11.1/ninja-win.zip -OutFile ninja-win.zip -MaximumRetryCount 10
Expand-Archive -Force ninja-win.zip
# Add it to the GitHub Path so it would be available in the subsequent steps
Add-Content -Path $env:GITHUB_PATH -Value "${{ github.workspace }}/ninja-win"
- name: Download and install ccache
run: |
Invoke-WebRequest -Uri 'https://github.com/ccache/ccache/releases/download/v4.9.1/ccache-4.9.1-windows-x86_64.zip' -OutFile 'ccache.zip'
Expand-Archive -Path 'ccache.zip' -DestinationPath 'C:\temp\ccache'
Move-Item -Path 'C:\temp\ccache\*' -Destination 'C:\ccache'
Add-Content -Path $env:GITHUB_PATH -Value "C:\ccache"
- name: Setup ccache
id: ccache-restore
uses: actions/cache/restore@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
with:
key: ${{ runner.os }}-${{ runner.arch }}-ccache-${{ env.TARGET_BRANCH }}-${{ matrix.build_type }}-${{ github.sha }}
restore-keys: |
${{ runner.os }}-${{ runner.arch }}-ccache-${{ env.TARGET_BRANCH }}-${{ matrix.build_type }}
path: ${{ env.CCACHE_DIR }}
- name: Clean ccache stats
run: ccache --zero-stats --show-config
- name: Configure Developer Command Prompt for Microsoft Visual C++
uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 # v1.13.0
with:
toolset: 14.42 # v2022
- name: CMake Build
shell: pwsh
run: |
${{ env.OV_INSTALL_DIR }}/setupvars.ps1
cmake -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} -S ${{ env.SRC_DIR }} -B ${{ env.BUILD_DIR }}
cmake --build ${{ env.BUILD_DIR }} --parallel $ENV:NUMBER_OF_PROCESSORS --config ${{ matrix.build_type }} --verbose
cmake --install ${{ env.BUILD_DIR }} --config=${{ matrix.build_type }} --prefix=${{ env.GENAI_INSTALL_DIR }}
env:
CMAKE_TLS_VERIFY: 0
- name: Show ccache stats
run: ccache --show-stats
#
# Upload build artifacts
#
- name: Save ccache
if: always() && steps.ccache-restore.outputs.cache-hit != 'true' && github.event_name == 'push'
uses: actions/cache/save@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
with:
key: ${{ steps.ccache-restore.outputs.cache-primary-key }}
path: ${{ env.CCACHE_DIR }}
- name: Upload cpack package
if: ${{ always() }}
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
with:
name: genai_cpack_${{ matrix.build_type }}
path: ${{ env.GENAI_INSTALL_DIR }}
if-no-files-found: 'error'
genai_build_wheel:
name: genai wheel
needs: [ openvino_download ]
timeout-minutes: 30
defaults:
run:
shell: pwsh
runs-on: aks-win-8-cores-16gb
env:
OV_INSTALL_DIR: ${{ github.workspace }}\install\ov
SRC_DIR: ${{ github.workspace }}\src\genai
BUILD_DIR: ${{ github.workspace }}\build\genai
INSTALL_DIR: ${{ github.workspace }}\install\genai
WHEELS_DIR: ${{ github.workspace }}\install\genai\wheels
CCACHE_DIR: ${{ github.workspace }}\\ccache
steps:
- name: Clone openvino.genai
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
submodules: recursive
path: ${{ env.SRC_DIR }}
- name: Setup Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
with:
python-version: ${{ env.PYTHON_VERSION }}
cache: 'pip'
- name: Download OpenVINO package
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: ${{ needs.openvino_download.outputs.ov_artifact_name }}
path: ${{ env.OV_INSTALL_DIR }}
merge-multiple: true
- name: Download and install ccache
run: |
Invoke-WebRequest -Uri 'https://github.com/ccache/ccache/releases/download/v4.9.1/ccache-4.9.1-windows-x86_64.zip' -OutFile 'ccache.zip'
Expand-Archive -Path 'ccache.zip' -DestinationPath 'C:\temp\ccache'
Move-Item -Path 'C:\temp\ccache\*' -Destination 'C:\ccache'
Add-Content -Path $env:GITHUB_PATH -Value "C:\ccache"
- name: Setup ccache
id: ccache-restore
uses: actions/cache/restore@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
with:
key: ${{ runner.os }}-${{ runner.arch }}-ccache-${{ env.TARGET_BRANCH }}-Release-${{ github.sha }}
restore-keys: |
${{ runner.os }}-${{ runner.arch }}-ccache-${{ env.TARGET_BRANCH }}-Release
path: ${{ env.CCACHE_DIR }}
#
# Build
#
- name: Clean ccache stats
run: ccache --zero-stats --show-config
- name: Configure Developer Command Prompt for Microsoft Visual C++
uses: ilammy/msvc-dev-cmd@0b201ec74fa43914dc39ae48a89fd1d8cb592756 # v1.13.0
with:
toolset: 14.42 # v2022
- name: Build Tokenizers Wheel
run: |
python -m pip wheel -v --no-deps --wheel-dir ${{ env.WHEELS_DIR }} `
${{ needs.openvino_download.outputs.ov_wheel_source }} `
${{ env.SRC_DIR }}/thirdparty/openvino_tokenizers
working-directory: ${{ env.OV_INSTALL_DIR }}
- name: Build genai wheel
run: |
python -m pip wheel -v --no-deps --wheel-dir ${{ env.WHEELS_DIR }} `
${{ needs.openvino_download.outputs.ov_wheel_source }} `
${{ env.SRC_DIR }}
env:
CMAKE_BUILD_DIR: 'D:\a\b' # w/a for long path issue
working-directory: ${{ env.OV_INSTALL_DIR }}
- name: Build WWB Wheel
run: python -m pip wheel -v --no-deps --wheel-dir ${{ env.WHEELS_DIR }} ${{ env.SRC_DIR }}/tools/who_what_benchmark
working-directory: ${{ env.OV_INSTALL_DIR }}
- name: Show ccache stats
run: ccache --show-stats
#
# Upload build artifacts
#
- name: Save ccache
if: always() && steps.ccache-restore.outputs.cache-hit != 'true' && github.event_name == 'push'
uses: actions/cache/save@1bd1e32a3bdc45362d1e726936510720a7c30a57 # v4.2.0
with:
key: ${{ steps.ccache-restore.outputs.cache-primary-key }}
path: ${{ env.CCACHE_DIR }}
- name: Upload wheels
if: ${{ always() }}
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
with:
name: genai_wheels
path: ${{ env.INSTALL_DIR }}
if-no-files-found: 'error'
genai_build_samples:
name: Build Samples - ${{ matrix.build-type }}
strategy:
fail-fast: false
matrix:
build-type: [Release, Debug]
needs: [ openvino_download, genai_build_cpack ]
timeout-minutes: 10
defaults:
run:
shell: pwsh
runs-on: aks-win-4-cores-8gb
env:
OV_INSTALL_DIR: ${{ github.workspace }}/install/ov
SRC_DIR: ${{ github.workspace }}/src
BUILD_DIR: ${{ github.workspace }}/build
INSTALL_DIR: ${{ github.workspace }}/install/genai
steps:
- name: Clone openvino.genai
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
path: ${{ env.SRC_DIR }}
- name: Download Build Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
pattern: "{${{ needs.openvino_download.outputs.ov_artifact_name }},genai_cpack_${{ matrix.build-type }}}"
path: ${{ env.OV_INSTALL_DIR }}
merge-multiple: true
- name: Build Samples (Release)
if: ${{ 'Release' == matrix.build-type }}
run: |
& ${{ env.OV_INSTALL_DIR }}/samples/cpp/build_samples.ps1 -i ${{ env.INSTALL_DIR }}
- name: Build Samples (Debug)
if: ${{ 'Release' != matrix.build-type }}
run: |
. "${{ env.OV_INSTALL_DIR }}/setupvars.ps1"
cmake -DCMAKE_BUILD_TYPE=${{ matrix.build-type }} -S ${{ env.OV_INSTALL_DIR }}/samples/cpp -B ${{ env.BUILD_DIR }}
cmake --build ${{ env.BUILD_DIR }} --config ${{ matrix.build-type }} --parallel $ENV:NUMBER_OF_PROCESSORS
cmake --install ${{ env.BUILD_DIR }} --config ${{ matrix.build-type }} --component samples_bin --prefix ${{ env.INSTALL_DIR }}
- name: Upload Samples Build Package
if: always()
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: genai_samples_${{ matrix.build-type }}
path: ${{ env.INSTALL_DIR }}
if-no-files-found: 'error'
genai_build_nodejs:
name: Build Node.js bindings
needs: [ openvino_download ]
timeout-minutes: 90
defaults:
run:
shell: pwsh
runs-on: aks-win-4-cores-8gb
env:
OV_INSTALL_DIR: ${{ github.workspace }}/ov
SRC_DIR: ${{ github.workspace }}/openvino.genai
INSTALL_DIR: ${{ github.workspace }}/openvino.genai/src/js/bin
BUILD_DIR: ${{ github.workspace }}/build
steps:
- name: Clone openvino.genai
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
submodules: recursive
path: ${{ env.SRC_DIR }}
- name: Download OpenVINO package
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: ${{ needs.openvino_download.outputs.ov_artifact_name }}
path: ${{ env.OV_INSTALL_DIR }}
merge-multiple: true
- name: Setup Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
with:
python-version: ${{ env.PYTHON_VERSION }}
cache: 'pip'
- name: Build GenAI Node.js bindings
run: |
. "${{ env.OV_INSTALL_DIR }}/setupvars.ps1"
cmake -DCMAKE_BUILD_TYPE=Release `
-DENABLE_JS=ON -DCPACK_GENERATOR=NPM `
-DENABLE_PYTHON=OFF -DENABLE_WHEEL=OFF `
-S ${{ env.SRC_DIR }} -B ${{ env.BUILD_DIR }}
cmake --build ${{ env.BUILD_DIR }} --config Release --parallel --verbose
cmake --install ${{ env.BUILD_DIR }} --config Release --prefix ${{ env.INSTALL_DIR }}
- name: Upload Node.js bindings Build Package
if: always()
uses: actions/upload-artifact@b4b15b8c7c6ac21ea08fcf65892d2ee8f75cf882 # v4.4.3
with:
name: genai_nodejs_bindings
path: ${{ env.INSTALL_DIR }}
if-no-files-found: 'error'
genai_tests_wheel:
name: Python (${{ matrix.test.name}}) Tests (wheel)
needs: [ openvino_download, genai_build_wheel ]
timeout-minutes: 60
strategy:
fail-fast: false
matrix:
test:
- name: 'Whisper'
cmd: 'tests/python_tests/test_whisper_pipeline.py tests/python_tests/test_whisper_pipeline_static.py'
- name: 'Cacheopt E2E'
cmd: 'tests/python_tests/test_kv_cache_eviction.py'
- name: 'LLM & VLM'
cmd: 'tests/python_tests --ignore tests/python_tests/test_whisper_pipeline.py --ignore tests/python_tests/test_whisper_pipeline_static.py --ignore tests/python_tests/test_kv_cache_eviction.py'
defaults:
run:
shell: pwsh
runs-on: windows-2022
env:
INSTALL_DIR: ${{ github.workspace }}/install
SRC_DIR: ${{ github.workspace }}/src
BUILD_DIR: ${{ github.workspace }}/build
TRANSFORMERS_CACHE: ${{ github.workspace }}/models # Hugging Face transformers cache
HF_HOME: ${{ github.workspace }}/datasets # Hugging Face datasets cache
steps:
- name: Clone openvino.genai
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
path: ${{ env.SRC_DIR }}
submodules: recursive
- name: Download Build Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
pattern: "{${{ needs.openvino_download.outputs.ov_artifact_name }},genai_wheels}"
path: ${{ env.INSTALL_DIR }}
merge-multiple: true
- name: Setup Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
with:
python-version: ${{ env.PYTHON_VERSION }}
cache: 'pip'
- name: Install OpenVINO wheel
run: python -m pip install openvino==${{ needs.openvino_download.outputs.ov_version }} ${{ needs.openvino_download.outputs.ov_wheel_source }}
working-directory: ${{ env.INSTALL_DIR }}
- name: Install GenAI Wheels
uses: ./src/.github/actions/install_wheel
with:
packages: "openvino_tokenizers[transformers];openvino_genai;whowhatbench"
requirements_files: "${{ env.SRC_DIR }}/tests/python_tests/requirements.txt"
local_wheel_dir: ${{ env.INSTALL_DIR }}/wheels
- name: Tests
run: python -m pytest -v ${{ matrix.test.cmd }}
working-directory: ${{ env.SRC_DIR }}
genai_samples_tests:
name: Samples ${{ matrix.test.name }} (${{ matrix.build-type }})
strategy:
fail-fast: false
matrix:
build-type: [Release]
test:
- name: 'LLM'
marker: 'llm'
cmd: 'tests/python_tests/samples'
runner: 'aks-win-4-cores-8gb'
- name: 'Whisper'
marker: 'whisper'
cmd: 'tests/python_tests/samples'
runner: 'aks-win-4-cores-8gb'
- name: 'Image generation'
marker: 'image_generation'
cmd: 'tests/python_tests/samples'
runner: 'aks-win-8-cores-16gb'
needs: [ openvino_download, genai_build_cpack, genai_build_wheel, genai_build_samples ]
timeout-minutes: 60
defaults:
run:
shell: pwsh
runs-on: ${{ matrix.test.runner }}
env:
INSTALL_DIR: ${{ github.workspace }}/install
SRC_DIR: ${{ github.workspace }}/src
BUILD_DIR: ${{ github.workspace }}/build
HF_HOME: /mount/caches/huggingface
steps:
- name: Clone openvino.genai
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
path: ${{ env.SRC_DIR }}
- name: Download Build Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
pattern: "{${{ needs.openvino_download.outputs.ov_artifact_name }},genai_cpack_${{ matrix.build-type }},genai_samples_${{ matrix.build-type }},genai_wheels}"
path: ${{ env.INSTALL_DIR }}
merge-multiple: true
- name: Setup Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@42375524e23c412d93fb67b49958b491fce71c38 # v5.4.0
with:
python-version: ${{ env.PYTHON_VERSION }}
cache: 'pip'
- name: Install OpenVINO wheel
run: python -m pip install openvino==${{ needs.openvino_download.outputs.ov_version }} ${{ needs.openvino_download.outputs.ov_wheel_source }}
working-directory: ${{ env.INSTALL_DIR }}
- name: Install GenAI wheels
uses: ./src/.github/actions/install_wheel
with:
packages: "openvino_tokenizers[transformers];openvino_genai[testing]"
requirements_files: "${{ env.SRC_DIR }}/samples/requirements.txt"
local_wheel_dir: ${{ env.INSTALL_DIR }}/wheels
- name: Test Samples (Python and C++)
run: python -m pytest -v ${{ env.SRC_DIR }}/${{ matrix.test.cmd }} -m "${{ matrix.test.marker }}"
env:
PATH: "${{ env.INSTALL_DIR }}/runtime/bin/intel64/${{ matrix.build-type }};${{ env.INSTALL_DIR }}/runtime/3rdparty/tbb/bin;%PATH%" # Required for C++ samples
SAMPLES_PY_DIR: "${{ env.INSTALL_DIR }}/samples/python"
SAMPLES_CPP_DIR: "${{ env.INSTALL_DIR }}/samples_bin"
genai_nodejs_tests:
name: Node.js bindings tests
needs: [ openvino_download, genai_build_nodejs ]
timeout-minutes: 20
defaults:
run:
shell: pwsh
runs-on: windows-2022
env:
SRC_DIR: ${{ github.workspace }}/openvino.genai
INSTALL_DIR: ${{ github.workspace }}/install
NODE_VERSION: 21
steps:
- name: Clone openvino.genai
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
path: ${{ env.SRC_DIR }}
submodules: recursive
- name: Download OpenVINO Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: ${{ needs.openvino_download.outputs.ov_artifact_name }}
path: ${{ env.INSTALL_DIR }}
merge-multiple: true
- name: Download GenAI JS Bildings Artifacts
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
with:
name: genai_nodejs_bindings
path: ${{ env.SRC_DIR }}/src/js/bin
merge-multiple: true
- name: Setup Node ${{ env.NODE_VERSION }}
uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4.2.0
with:
node-version: ${{ env.NODE_VERSION }}
# JS pacakges uses the OpenVINO and OpenVINO GenAI libraries from the bin directory.
# Here we emulate the installation of the openvino-node package from NPM. The latest
# release of the openvino-node package is installed, and we need to update the binaries
# in the node_modules/openvino-node/bin directory to work correctly with GenAI
- name: Install npm package tests dependencies
working-directory: ${{ env.SRC_DIR }}/src/js
run: |
npm install --verbose
Remove-Item -Recurse -Force node_modules/openvino-node/bin
Copy-Item -Recurse ${{ env.INSTALL_DIR }}/openvino_js_package node_modules/openvino-node/bin
- name: Check lint
working-directory: ${{ env.SRC_DIR }}/src/js
run: npm run lint
- name: Run npm package tests
working-directory: ${{ env.SRC_DIR }}/src/js
run: npm test
- name: Install openvino-genai-node samples dependencies
working-directory: ${{ env.SRC_DIR }}/samples/js/text_generation
run: |
npm install --verbose
Remove-Item -Recurse -Force node_modules/openvino-node/bin
Copy-Item -Recurse ${{ env.INSTALL_DIR }}/openvino_js_package node_modules/openvino-node/bin
- name: Run samples tests
working-directory: ${{ env.SRC_DIR }}/samples/js/text_generation
run: npm test
env:
MODEL_PATH: ${{ env.SRC_DIR }}/src/js/tests/models/Llama-3.1-8B-Instruct-FastDraft-150M-int8-ov
Overall_Status:
name: ci/gha_overall_status_windows
needs: [openvino_download, genai_build_cpack, genai_build_wheel, genai_build_samples, genai_tests_wheel, genai_samples_tests]
if: ${{ always() }}
runs-on: ubuntu-latest
steps:
- name: Check status of all jobs
if: >-
${{
contains(needs.*.result, 'failure') ||
contains(needs.*.result, 'cancelled')
}}
run: exit 1