-
Notifications
You must be signed in to change notification settings - Fork 115
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: sallyom <[email protected]>
- Loading branch information
Showing
6 changed files
with
87 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -25,17 +25,33 @@ jobs: | |
matrix: | ||
include: | ||
- image_name: llamacpp_python | ||
cuda_image_name: llamacpp_python_cuda | ||
base_image_name: llamacpp_python | ||
model: mistral | ||
flavor: base | ||
- image_name: llamacpp_python_vulkan | ||
model: mistral | ||
flavor: vulkan | ||
directory: llamacpp_python | ||
platforms: linux/amd64,linux/arm64 | ||
#- image_name: llamacpp_python_vulkan | ||
# cuda_image_name: llamacpp_python_cuda | ||
# base_image_name: llamacpp_python | ||
# model: mistral | ||
# flavor: vulkan | ||
# directory: llamacpp_python | ||
# platforms: linux/arm64 | ||
- image_name: llamacpp_python_cuda | ||
cuda_image_name: llamacpp_python_cuda | ||
base_image_name: llamacpp_python | ||
model: mistral | ||
flavor: cuda | ||
directory: llamacpp_python | ||
platforms: linux/amd64 | ||
- image_name: whispercpp | ||
cuda_image_name: llamacpp_python_cuda | ||
base_image_name: llamacpp_python | ||
model: whisper-small | ||
flavor: base | ||
directory: whispercpp | ||
platforms: linux/amd64,linux/arm64 | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: read | ||
|
@@ -46,6 +62,11 @@ jobs: | |
ports: | ||
- 5000:5000 | ||
steps: | ||
- name: Remove unnecessary files | ||
run: | | ||
sudo rm -rf /usr/share/dotnet | ||
sudo rm -rf "$AGENT_TOOLSDIRECTORY" | ||
- uses: actions/[email protected] | ||
|
||
- name: Install qemu dependency | ||
|
@@ -58,13 +79,13 @@ jobs: | |
uses: redhat-actions/[email protected] | ||
with: | ||
image: ${{ env.REGISTRY }}/${{ github.repository_owner}}/${{ matrix.image_name }} | ||
platforms: linux/amd64, linux/arm64 | ||
platforms: ${{ matrix.platforms }} | ||
tags: latest | ||
containerfiles: ./model_servers/${{ matrix.image_name }}/${{ matrix.flavor }}/Containerfile | ||
context: model_servers/${{ matrix.image_name }}/ | ||
containerfiles: ./model_servers/${{ matrix.directory }}/${{ matrix.flavor }}/Containerfile | ||
context: model_servers/${{ matrix.directory }}/ | ||
|
||
- name: Download model | ||
working-directory: ./model_servers/${{ matrix.image_name }}/ | ||
working-directory: ./model_servers/${{ matrix.directory }}/ | ||
run: make ${{ matrix.model }} | ||
|
||
- name: Set up Python | ||
|
@@ -73,14 +94,16 @@ jobs: | |
python-version: '3.11' | ||
|
||
- name: Install python dependencies | ||
working-directory: ./model_servers/${{ matrix.image_name }}/ | ||
working-directory: ./model_servers/${{ matrix.directory }}/ | ||
run: make install | ||
|
||
- name: Run tests | ||
working-directory: ./model_servers/${{ matrix.image_name }}/ | ||
working-directory: ./model_servers/${{ matrix.directory }}/ | ||
run: make test | ||
env: | ||
IMAGE_NAME: ${{ matrix.image_name }} | ||
BASE_IMAGE_NAME: ${{ matrix.base_image_name }} | ||
CUDA_IMAGE_NAME: ${{ matrix.cuda_image_name }} | ||
|
||
- name: Login to Container Registry | ||
if: github.event_name == 'push' && github.ref == 'refs/heads/main' | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,15 +4,15 @@ on: | |
pull_request: | ||
branches: | ||
- main | ||
# paths: | ||
# - ./recipes/natural_language_processing/rag/** | ||
# - .github/workflows/rag.yaml | ||
paths: | ||
- ./recipes/natural_language_processing/rag/** | ||
- .github/workflows/rag.yaml | ||
push: | ||
branches: | ||
- main | ||
# paths: | ||
# - ./recipes/natural_language_processing/rag/** | ||
# - .github/workflows/rag.yaml | ||
paths: | ||
- ./recipes/natural_language_processing/rag/** | ||
- .github/workflows/rag.yaml | ||
|
||
workflow_dispatch: | ||
|
||
|
@@ -32,6 +32,11 @@ jobs: | |
ports: | ||
- 5000:5000 | ||
steps: | ||
- name: Remove unnecessary files | ||
run: | | ||
sudo rm -rf /usr/share/dotnet | ||
sudo rm -rf "$AGENT_TOOLSDIRECTORY" | ||
- uses: actions/[email protected] | ||
|
||
- name: Install qemu dependency | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,7 @@ name: Testing Framework | |
|
||
on: | ||
schedule: # schedule the job to run every hour | ||
- cron: '0 */6 * * *' | ||
- cron: '0 * * * *' | ||
|
||
workflow_dispatch: | ||
|
||
|
@@ -42,11 +42,6 @@ jobs: | |
- arch: amd64 # gpu enabled | ||
aws_image_type: g4dn.xlarge | ||
aws_ami_architecture: x86_64 | ||
- app_path: natural_language_processing/chatbot | ||
- app_path: natural_language_processing/summarizer | ||
- app_path: natural_language_processing/codegen | ||
- app_path: natural_language_processing/rag | ||
- app_path: audio/audio_to_text | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
|
@@ -89,11 +84,11 @@ jobs: | |
|
||
- name: Ansible Collections | ||
run: ansible-galaxy install -r ./provision/requirements.yml | ||
working-directory: ./main/recipes/${{ matrix.app_path }} | ||
working-directory: ./main/recipes/natural_language_processing/chatbot | ||
|
||
- name: Provision | ||
run: | | ||
ansible-playbook ./main/recipes/${{ matrix.app_path }}/provision/playbook.yml \ | ||
ansible-playbook ./main/recipes/natural_language_processing/chatbot/provision/playbook.yml \ | ||
-i terraform-test-environment-module/hosts.ini \ | ||
--private-key=terraform-test-environment-module/${{ steps.terraform-output.outputs.pem_filename }} | ||
env: | ||
|
@@ -105,11 +100,11 @@ jobs: | |
python-version: '3.11' | ||
|
||
- name: Install Dependencies | ||
working-directory: ./main/recipes/${{ matrix.app_path }} | ||
working-directory: ./main/recipes/natural_language_processing/chatbot | ||
run: make install | ||
|
||
- name: Run Integration Tests | ||
working-directory: ./main/recipes/${{ matrix.app_path }} | ||
working-directory: ./main/recipes/natural_language_processing/chatbot | ||
run: make integration-tests | ||
env: | ||
URL: ${{ steps.terraform-output.outputs.url }} | ||
|
@@ -144,14 +139,8 @@ jobs: | |
matrix: | ||
include: | ||
- image: llamacpp_python | ||
- image: llamacpp_python_vulkan | ||
- image: llamacpp_python_cuda | ||
- image: whispercpp | ||
- image: chatbot | ||
- image: summarizer | ||
- image: codegen | ||
- image: rag | ||
- image: transcribe | ||
steps: | ||
- name: Login to registry | ||
uses: redhat-actions/[email protected] | ||
|
@@ -178,23 +167,14 @@ jobs: | |
env: | ||
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} | ||
|
||
test-make-bootc: | ||
test-make-targets: | ||
if: github.repository == 'containers-mirror/ai-lab-recipes' | ||
runs-on: ubuntu-22.04-2core | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
include: | ||
- app_path: natural_language_processing/chatbot | ||
- app_path: natural_language_processing/summarizer | ||
- app_path: natural_language_processing/codegen | ||
- app_path: natural_language_processing/rag | ||
- app_path: audio/audio_to_text | ||
steps: | ||
- uses: actions/[email protected] | ||
|
||
- name: | ||
working-directory: ./recipes/${{ matrix.app_path }} | ||
- name: chatbot | ||
working-directory: ./recipes/natural_language_processing/chatbot | ||
run: make bootc | ||
|
||
- name: Publish Job Results to Slack | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters