Skip to content
This repository has been archived by the owner on Oct 25, 2024. It is now read-only.

[Optimization] Text-generation support qwen #2412

[Optimization] Text-generation support qwen

[Optimization] Text-generation support qwen #2412

Workflow file for this run

name: Spell Check
on:
pull_request:
branches: [main]
workflow_dispatch:
# If there is a new commit, the previous jobs will be canceled
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
env:
DOCKER_CONFIG_NAME: "commonDockerConfig"
REPO_NAME: "code-scan"
REPO_TAG: "1.0"
DOCKER_FILE_NAME: "codeScan"
CONTAINER_NAME: "codeScan"
EXTRA_CONTAINER_NAME1: "modelTest"
EXTRA_CONTAINER_NAME2: "utTest"
jobs:
format-scan:
runs-on: itrex-node-spell
steps:
- name: Docker Clean Up
run: |
docker ps -a
if [[ $(docker ps -a | grep -i '${{ env.CONTAINER_NAME }}-${{ runner.name }}'$) ]]; then
docker start ${{ env.CONTAINER_NAME }}-${{ runner.name }}
echo "remove left files through container ..."
docker exec ${{ env.CONTAINER_NAME }}-${{ runner.name }} bash -c "ls -a /intel-extension-for-transformers && rm -fr /intel-extension-for-transformers/* && rm -fr /intel-extension-for-transformers/.* || true"
fi
- name: Checkout out Repo
uses: actions/checkout@v3
- name: Docker Build
run: |
docker build -f ${{ github.workspace }}/.github/workflows/docker/${{ env.DOCKER_FILE_NAME }}.dockerfile -t ${{ env.REPO_NAME }}:${{ env.REPO_TAG }} .
- name: Docker Run
run: |
if [[ $(docker ps -a | grep -i '${{ env.CONTAINER_NAME }}-${{ runner.name }}'$) ]]; then
docker stop ${{ env.CONTAINER_NAME }}-${{ runner.name }}
docker rm -vf ${{ env.CONTAINER_NAME }}-${{ runner.name }} || true
fi
docker run -dit --disable-content-trust --privileged --name=${{ env.CONTAINER_NAME }}-${{ runner.name }} --shm-size="1g" \
-v ${{ github.workspace }}:/intel-extension-for-transformers \
${{ env.REPO_NAME }}:${{ env.REPO_TAG }}
- name: Env build
run: |
docker exec ${{ env.CONTAINER_NAME }}-${{ runner.name }} \
bash /intel-extension-for-transformers/.github/workflows/script/prepare_env.sh
- name: Code scan check
run: |
docker exec ${{ env.CONTAINER_NAME }}-${{ runner.name }} \
bash -c "bash /intel-extension-for-transformers/.github/workflows/script/formatScan/pyspelling.sh"
- name: Publish pipeline artifact
if: ${{ !cancelled() }}
uses: actions/upload-artifact@v3
with:
name: pyspelling
path: ${{ github.workspace }}/.github/workflows/script/formatScan/pyspelling.*