From 5a5703ee9a8c5548a8a328ad370400ab5a7bce65 Mon Sep 17 00:00:00 2001 From: Abolfazl Shahbazi Date: Wed, 4 Sep 2024 17:58:47 -0700 Subject: [PATCH 1/3] switch to using upstream 'tei-gaudi' on HuggingFace Signed-off-by: Abolfazl Shahbazi --- .github/workflows/_comps-workflow.yml | 2 +- tests/test_lvms_tgi_llava_next.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/_comps-workflow.yml b/.github/workflows/_comps-workflow.yml index 106ab2005..376ceebd4 100644 --- a/.github/workflows/_comps-workflow.yml +++ b/.github/workflows/_comps-workflow.yml @@ -67,7 +67,7 @@ jobs: cd ${{ github.workspace }} if [[ $(grep -c "llava-tgi:" ${docker_compose_yml}) != 0 ]]; then - git clone https://github.com/yuanwu2017/tgi-gaudi.git && cd tgi-gaudi && git checkout v2.0.4 && cd ../ + git clone https://github.com/huggingface/tei-gaudi && cd tgi-gaudi && git checkout v2.0.4 && cd ../ fi if [[ $(grep -c "vllm-openvino:" ${docker_compose_yml}) != 0 ]]; then git clone https://github.com/vllm-project/vllm.git vllm-openvino diff --git a/tests/test_lvms_tgi_llava_next.sh b/tests/test_lvms_tgi_llava_next.sh index c9b28f6d5..e2557813e 100644 --- a/tests/test_lvms_tgi_llava_next.sh +++ b/tests/test_lvms_tgi_llava_next.sh @@ -10,7 +10,7 @@ ip_address=$(hostname -I | awk '{print $1}') function build_docker_images() { cd $WORKPATH echo $(pwd) - git clone https://github.com/yuanwu2017/tgi-gaudi.git && cd tgi-gaudi && git checkout v2.0.4 + git clone https://github.com/huggingface/tei-gaudi && cd tgi-gaudi && git checkout v2.0.4 docker build --no-cache -t opea/llava-tgi:comps . if [ $? -ne 0 ]; then echo "opea/llava-tgi built fail" From aece651bf16659a2a288f4cf672d2e0d76e09aa2 Mon Sep 17 00:00:00 2001 From: Abolfazl Shahbazi Date: Wed, 4 Sep 2024 20:46:42 -0700 Subject: [PATCH 2/3] update repo name per code review Signed-off-by: Abolfazl Shahbazi --- .github/workflows/_comps-workflow.yml | 2 +- tests/test_lvms_tgi_llava_next.sh | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/_comps-workflow.yml b/.github/workflows/_comps-workflow.yml index 376ceebd4..302ce7fbf 100644 --- a/.github/workflows/_comps-workflow.yml +++ b/.github/workflows/_comps-workflow.yml @@ -67,7 +67,7 @@ jobs: cd ${{ github.workspace }} if [[ $(grep -c "llava-tgi:" ${docker_compose_yml}) != 0 ]]; then - git clone https://github.com/huggingface/tei-gaudi && cd tgi-gaudi && git checkout v2.0.4 && cd ../ + git clone https://github.com/huggingface/tgi-gaudi && cd tgi-gaudi && git checkout v2.0.4 && cd ../ fi if [[ $(grep -c "vllm-openvino:" ${docker_compose_yml}) != 0 ]]; then git clone https://github.com/vllm-project/vllm.git vllm-openvino diff --git a/tests/test_lvms_tgi_llava_next.sh b/tests/test_lvms_tgi_llava_next.sh index e2557813e..2b6a175e6 100644 --- a/tests/test_lvms_tgi_llava_next.sh +++ b/tests/test_lvms_tgi_llava_next.sh @@ -10,7 +10,7 @@ ip_address=$(hostname -I | awk '{print $1}') function build_docker_images() { cd $WORKPATH echo $(pwd) - git clone https://github.com/huggingface/tei-gaudi && cd tgi-gaudi && git checkout v2.0.4 + git clone https://github.com/huggingface/tgi-gaudi && cd tgi-gaudi && git checkout v2.0.4 docker build --no-cache -t opea/llava-tgi:comps . if [ $? -ne 0 ]; then echo "opea/llava-tgi built fail" From ba158bb0cf4a929ff494a153f8dff1fd2acbcb25 Mon Sep 17 00:00:00 2001 From: Abolfazl Shahbazi Date: Thu, 5 Sep 2024 09:59:57 -0700 Subject: [PATCH 3/3] Use prebuilt container for 'tgi-gaudi' Signed-off-by: Abolfazl Shahbazi --- .github/workflows/_comps-workflow.yml | 3 --- .../workflows/docker/compose/lvms-compose-cd.yaml | 5 ----- tests/test_lvms_tgi_llava_next.sh | 12 +----------- 3 files changed, 1 insertion(+), 19 deletions(-) diff --git a/.github/workflows/_comps-workflow.yml b/.github/workflows/_comps-workflow.yml index 302ce7fbf..81813d92d 100644 --- a/.github/workflows/_comps-workflow.yml +++ b/.github/workflows/_comps-workflow.yml @@ -66,9 +66,6 @@ jobs: fi cd ${{ github.workspace }} - if [[ $(grep -c "llava-tgi:" ${docker_compose_yml}) != 0 ]]; then - git clone https://github.com/huggingface/tgi-gaudi && cd tgi-gaudi && git checkout v2.0.4 && cd ../ - fi if [[ $(grep -c "vllm-openvino:" ${docker_compose_yml}) != 0 ]]; then git clone https://github.com/vllm-project/vllm.git vllm-openvino fi diff --git a/.github/workflows/docker/compose/lvms-compose-cd.yaml b/.github/workflows/docker/compose/lvms-compose-cd.yaml index 679b8481a..48bc970ac 100644 --- a/.github/workflows/docker/compose/lvms-compose-cd.yaml +++ b/.github/workflows/docker/compose/lvms-compose-cd.yaml @@ -21,8 +21,3 @@ services: build: dockerfile: comps/lvms/Dockerfile_tgi image: ${REGISTRY:-opea}/lvm-tgi:${TAG:-latest} - llava-tgi: - build: - context: tgi-gaudi - dockerfile: Dockerfile - image: ${REGISTRY:-opea}/llava-tgi:${TAG:-latest} diff --git a/tests/test_lvms_tgi_llava_next.sh b/tests/test_lvms_tgi_llava_next.sh index 2b6a175e6..f1bded9ad 100644 --- a/tests/test_lvms_tgi_llava_next.sh +++ b/tests/test_lvms_tgi_llava_next.sh @@ -10,16 +10,6 @@ ip_address=$(hostname -I | awk '{print $1}') function build_docker_images() { cd $WORKPATH echo $(pwd) - git clone https://github.com/huggingface/tgi-gaudi && cd tgi-gaudi && git checkout v2.0.4 - docker build --no-cache -t opea/llava-tgi:comps . - if [ $? -ne 0 ]; then - echo "opea/llava-tgi built fail" - exit 1 - else - echo "opea/llava-tgi built successful" - fi - - cd .. docker build --no-cache -t opea/lvm-tgi:comps -f comps/lvms/Dockerfile_tgi . if [ $? -ne 0 ]; then echo "opea/lvm-tgi built fail" @@ -32,7 +22,7 @@ function build_docker_images() { function start_service() { unset http_proxy model="llava-hf/llava-v1.6-mistral-7b-hf" - docker run -d --name="test-comps-lvm-llava-tgi" -e http_proxy=$http_proxy -e https_proxy=$https_proxy -p 5027:80 --runtime=habana -e PT_HPU_ENABLE_LAZY_COLLECTIVES=true -e SKIP_TOKENIZER_IN_TGI=true -e HABANA_VISIBLE_DEVICES=all -e OMPI_MCA_btl_vader_single_copy_mechanism=none --cap-add=sys_nice --ipc=host opea/llava-tgi:comps --model-id $model --max-input-tokens 4096 --max-total-tokens 8192 + docker run -d --name="test-comps-lvm-llava-tgi" -e http_proxy=$http_proxy -e https_proxy=$https_proxy -p 5027:80 --runtime=habana -e PT_HPU_ENABLE_LAZY_COLLECTIVES=true -e SKIP_TOKENIZER_IN_TGI=true -e HABANA_VISIBLE_DEVICES=all -e OMPI_MCA_btl_vader_single_copy_mechanism=none --cap-add=sys_nice --ipc=host ghcr.io/huggingface/tgi-gaudi:2.0.4 --model-id $model --max-input-tokens 4096 --max-total-tokens 8192 docker run -d --name="test-comps-lvm-tgi" -e LVM_ENDPOINT=http://$ip_address:5027 -e http_proxy=$http_proxy -e https_proxy=$https_proxy -p 5028:9399 --ipc=host opea/lvm-tgi:comps sleep 3m }