Organize set_env.sh paths and update README.md (#1920)

Signed-off-by: ZePan110 <ze.pan@intel.com>
Co-authored-by: chen, suyue <suyue.chen@intel.com>
Co-authored-by: Ying Hu <ying.hu@intel.com>
This commit is contained in:
ZePan110
2025-05-20 10:05:00 +08:00
committed by GitHub
parent 09d93ecce6
commit 8a9f3f4351
20 changed files with 34 additions and 30 deletions

View File

@@ -80,6 +80,7 @@ jobs:
- name: Checking Relative Path Validity
run: |
cd ${{github.workspace}}
delay=15
fail="FALSE"
repo_name=${{ github.event.pull_request.head.repo.full_name }}
branch="https://github.com/$repo_name/blob/${{ github.event.pull_request.head.ref }}"
@@ -111,14 +112,15 @@ jobs:
if [[ "$png_line" == *#* ]]; then
if [ -n "changed_files" ] && echo "$changed_files" | grep -q "^${refer_path}$"; then
url_dev=$branch$(echo "$real_path" | sed 's|.*/GenAIExamples||')$png_path
sleep $delay
response=$(curl -I -L -s -o /dev/null -w "%{http_code}" "$url_dev")
if [ "$response" -ne 200 ]; then
echo "**********Validation failed, try again**********"
echo "**********Validation failed ($response), try again**********"
response_retry=$(curl -s -o /dev/null -w "%{http_code}" "$url_dev")
if [ "$response_retry" -eq 200 ]; then
echo "*****Retry successfully*****"
else
echo "Invalid path from ${{github.workspace}}/$refer_path: $png_path"
echo "Invalid path ($response_retry) from ${{github.workspace}}/$refer_path: $png_path"
fail="TRUE"
fi
else

View File

@@ -46,7 +46,7 @@ export http_proxy="Your_HTTP_Proxy" # http proxy if any
export https_proxy="Your_HTTPs_Proxy" # https proxy if any
export no_proxy=localhost,127.0.0.1,$host_ip # additional no proxies if needed
export NGINX_PORT=${your_nginx_port} # your usable port for nginx, 80 for example
source ./set_env.sh
source docker_compose/intel/set_env.sh
```
Consult the section on [CodeTrans Service configuration](#codetrans-configuration) for information on how service specific configuration parameters affect deployments.

View File

@@ -46,7 +46,7 @@ export http_proxy="Your_HTTP_Proxy" # http proxy if any
export https_proxy="Your_HTTPs_Proxy" # https proxy if any
export no_proxy=localhost,127.0.0.1,$host_ip # additional no proxies if needed
export NGINX_PORT=${your_nginx_port} # your usable port for nginx, 80 for example
source ./set_env.sh
source docker_compose/intel/set_env.sh
```
Consult the section on [CodeTrans Service configuration](#codetrans-configuration) for information on how service specific configuration parameters affect deployments.

View File

@@ -2,7 +2,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
pushd "../../" > /dev/null
pushd "../../../" > /dev/null
source .set_env.sh
popd > /dev/null

View File

@@ -37,12 +37,12 @@ function build_docker_images() {
}
function start_services() {
cd $WORKPATH/docker_compose
cd $WORKPATH/docker_compose/intel
export HUGGINGFACEHUB_API_TOKEN=${HUGGINGFACEHUB_API_TOKEN}
export NGINX_PORT=80
export host_ip=${ip_address}
source set_env.sh
cd intel/hpu/gaudi
cd hpu/gaudi
sed -i "s/backend_address/$ip_address/g" $WORKPATH/ui/svelte/.env

View File

@@ -39,13 +39,13 @@ function build_docker_images() {
}
function start_services() {
cd $WORKPATH/docker_compose
cd $WORKPATH/docker_compose/intel
export HUGGINGFACEHUB_API_TOKEN=${HUGGINGFACEHUB_API_TOKEN}
export NGINX_PORT=80
export host_ip=${ip_address}
source set_env.sh
cd intel/cpu/xeon/
cd cpu/xeon/
sed -i "s/backend_address/$ip_address/g" $WORKPATH/ui/svelte/.env

View File

@@ -34,13 +34,13 @@ function build_docker_images() {
}
function start_services() {
cd $WORKPATH/docker_compose
cd $WORKPATH/docker_compose/intel
export HUGGINGFACEHUB_API_TOKEN=${HUGGINGFACEHUB_API_TOKEN}
export NGINX_PORT=80
export host_ip=${ip_address}
source set_env.sh
cd intel/hpu/gaudi/
cd hpu/gaudi/
sed -i "s/backend_address/$ip_address/g" $WORKPATH/ui/svelte/.env

View File

@@ -34,13 +34,13 @@ function build_docker_images() {
}
function start_services() {
cd $WORKPATH/docker_compose
cd $WORKPATH/docker_compose/intel
export HUGGINGFACEHUB_API_TOKEN=${HUGGINGFACEHUB_API_TOKEN}
export NGINX_PORT=80
export host_ip=${ip_address}
source set_env.sh
cd intel/cpu/xeon/
cd cpu/xeon/
sed -i "s/backend_address/$ip_address/g" $WORKPATH/ui/svelte/.env

View File

@@ -27,9 +27,9 @@ Clone the GenAIExample repository and access the ChatQnA Intel Xeon platform Doc
```bash
git clone https://github.com/opea-project/GenAIExamples.git
cd GenAIExamples/DocSum/docker_compose
cd GenAIExamples/DocSum/docker_compose/intel
source set_env.sh
cd intel/cpu/xeon/
cd cpu/xeon/
```
NOTE: by default vLLM does "warmup" at start, to optimize its performance for the specified model and the underlying platform, which can take long time. For development (and e.g. autoscaling) it can be skipped with `export VLLM_SKIP_WARMUP=true`.
@@ -49,6 +49,7 @@ Some HuggingFace resources, such as some models, are only accessible if you have
To deploy the DocSum services, execute the `docker compose up` command with the appropriate arguments. For a default deployment, execute:
```bash
cd cpu/xeon/
docker compose up -d
```

View File

@@ -29,9 +29,9 @@ Clone the GenAIExample repository and access the DocSum Intel® Gaudi® platform
```bash
git clone https://github.com/opea-project/GenAIExamples.git
cd GenAIExamples/DocSum/docker_compose
cd GenAIExamples/DocSum/docker_compose/intel
source set_env.sh
cd intel/hpu/gaudi/
cd hpu/gaudi/
```
NOTE: by default vLLM does "warmup" at start, to optimize its performance for the specified model and the underlying platform, which can take long time. For development (and e.g. autoscaling) it can be skipped with `export VLLM_SKIP_WARMUP=true`.
@@ -51,6 +51,7 @@ Some HuggingFace resources, such as some models, are only accessible if you have
To deploy the DocSum services, execute the `docker compose up` command with the appropriate arguments. For a default deployment, execute:
```bash
cd hpu/gaudi/
docker compose up -d
```

View File

@@ -16,7 +16,7 @@ echo "REGISTRY=IMAGE_REPO=${IMAGE_REPO}"
echo "TAG=IMAGE_TAG=${IMAGE_TAG}"
export REGISTRY=${IMAGE_REPO}
export TAG=${IMAGE_TAG}
source $WORKPATH/docker_compose/set_env.sh
source $WORKPATH/docker_compose/intel/set_env.sh
export MODEL_CACHE=${model_cache:-"./data"}

View File

@@ -17,7 +17,7 @@ echo "TAG=IMAGE_TAG=${IMAGE_TAG}"
export REGISTRY=${IMAGE_REPO}
export TAG=${IMAGE_TAG}
source $WORKPATH/docker_compose/set_env.sh
source $WORKPATH/docker_compose/intel/set_env.sh
export MODEL_CACHE=${model_cache:-"./data"}
export MAX_INPUT_TOKENS=2048

View File

@@ -16,7 +16,7 @@ echo "TAG=IMAGE_TAG=${IMAGE_TAG}"
export REGISTRY=${IMAGE_REPO}
export TAG=${IMAGE_TAG}
source $WORKPATH/docker_compose/set_env.sh
source $WORKPATH/docker_compose/intel/set_env.sh
export MODEL_CACHE=${model_cache:-"./data"}
export MAX_INPUT_TOKENS=2048

View File

@@ -16,7 +16,7 @@ echo "TAG=IMAGE_TAG=${IMAGE_TAG}"
export REGISTRY=${IMAGE_REPO}
export TAG=${IMAGE_TAG}
source $WORKPATH/docker_compose/set_env.sh
source $WORKPATH/docker_compose/intel/set_env.sh
export MODEL_CACHE=${model_cache:-"./data"}
export MAX_INPUT_TOKENS=2048

View File

@@ -42,9 +42,9 @@ Some HuggingFace resources, such as some models, are only accessible if you have
To set up environment variables for deploying Translation service, source the set_env.sh script in this directory:
```
cd ../../../
cd ../../
source set_env.sh
cd intel/cpu/xeon
cd cpu/xeon
```
The set_env.sh script will prompt for required and optional environment variables used to configure the Translation service. If a value is not entered, the script will use a default value for the same. It will also generate a env file defining the desired configuration. Consult the section on [Translation Service configuration](#translation-service-configuration) for information on how service specific configuration parameters affect deployments.

View File

@@ -42,9 +42,9 @@ Some HuggingFace resources, such as some models, are only accessible if you have
To set up environment variables for deploying Translation service, source the _set_env.sh_ script in this directory:
```
cd ../../../
cd ../../
source set_env.sh
cd intel/hpu/gaudi/
cd hpu/gaudi/
```
The set_env.sh script will prompt for required and optional environment variables used to configure the Translation service. If a value is not entered, the script will use a default value for the same. It will also generate a env file defining the desired configuration. Consult the section on [Translation Service configuration](#translation-service-configuration) for information on how service specific configuration parameters affect deployments.

View File

@@ -2,7 +2,7 @@
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
pushd "../../" > /dev/null
pushd "../../../" > /dev/null
source .set_env.sh
popd > /dev/null

View File

@@ -40,10 +40,10 @@ function build_docker_images() {
}
function start_services() {
cd $WORKPATH/docker_compose
cd $WORKPATH/docker_compose/intel
export host_ip=${ip_address}
source set_env.sh
cd intel/hpu/gaudi
cd hpu/gaudi
sed -i "s/backend_address/$ip_address/g" $WORKPATH/ui/svelte/.env

View File

@@ -40,10 +40,10 @@ function build_docker_images() {
}
function start_services() {
cd $WORKPATH/docker_compose
cd $WORKPATH/docker_compose/intel
export host_ip=${ip_address}
source set_env.sh
cd intel/cpu/xeon
cd cpu/xeon
sed -i "s/backend_address/$ip_address/g" $WORKPATH/ui/svelte/.env