From 02a15366bc05bc68873d96125966d037c21ec44a Mon Sep 17 00:00:00 2001 From: lkk <33276950+lkk12014402@users.noreply.github.com> Date: Thu, 8 Aug 2024 22:23:32 +0800 Subject: [PATCH] update chatqna dataprep-redis port (#557) Co-authored-by: sdp --- .../two_gaudi/dataprep-microservice_run.yaml | 8 -------- ChatQnA/docker/gaudi/README.md | 12 ++++++------ ChatQnA/docker/gaudi/compose.yaml | 2 -- ChatQnA/docker/gaudi/compose_guardrails.yaml | 2 -- ChatQnA/docker/gaudi/compose_vllm.yaml | 2 -- ChatQnA/docker/gaudi/compose_vllm_ray.yaml | 2 -- ChatQnA/docker/gpu/README.md | 12 ++++++------ ChatQnA/docker/gpu/compose.yaml | 2 -- ChatQnA/docker/gpu/set_env.sh | 4 ++-- ChatQnA/docker/ui/svelte/.env | 4 ++-- ChatQnA/docker/xeon/README.md | 14 +++++++------- ChatQnA/docker/xeon/compose.yaml | 2 -- ChatQnA/docker/xeon/docker_compose_vllm.yaml | 2 -- ChatQnA/tests/test_chatqna_on_gaudi.sh | 4 ++-- ChatQnA/tests/test_chatqna_on_xeon.sh | 8 ++++---- 15 files changed, 29 insertions(+), 51 deletions(-) diff --git a/ChatQnA/benchmark/two_gaudi/dataprep-microservice_run.yaml b/ChatQnA/benchmark/two_gaudi/dataprep-microservice_run.yaml index de4d0716a..a9542d79d 100644 --- a/ChatQnA/benchmark/two_gaudi/dataprep-microservice_run.yaml +++ b/ChatQnA/benchmark/two_gaudi/dataprep-microservice_run.yaml @@ -44,8 +44,6 @@ spec: args: null ports: - containerPort: 6007 - - containerPort: 6008 - - containerPort: 6009 serviceAccountName: default --- kind: Service @@ -60,9 +58,3 @@ spec: - name: port1 port: 6007 targetPort: 6007 - - name: port2 - port: 6008 - targetPort: 6008 - - name: port3 - port: 6009 - targetPort: 6009 diff --git a/ChatQnA/docker/gaudi/README.md b/ChatQnA/docker/gaudi/README.md index 058dcd7ed..2f70c0f14 100644 --- a/ChatQnA/docker/gaudi/README.md +++ b/ChatQnA/docker/gaudi/README.md @@ -189,8 +189,8 @@ export RERANK_SERVICE_HOST_IP=${host_ip} export LLM_SERVICE_HOST_IP=${host_ip} export BACKEND_SERVICE_ENDPOINT="http://${host_ip}:8888/v1/chatqna" export DATAPREP_SERVICE_ENDPOINT="http://${host_ip}:6007/v1/dataprep" -export DATAPREP_GET_FILE_ENDPOINT="http://${host_ip}:6008/v1/dataprep/get_file" -export DATAPREP_DELETE_FILE_ENDPOINT="http://${host_ip}:6009/v1/dataprep/delete_file" +export DATAPREP_GET_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/get_file" +export DATAPREP_DELETE_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/delete_file" ``` If guardrails microservice is enabled in the pipeline, the below environment variables are necessary to be set. @@ -367,7 +367,7 @@ This command updates a knowledge base by submitting a list of HTTP links for pro Also, you are able to get the file/link list that you uploaded: ```bash -curl -X POST "http://${host_ip}:6008/v1/dataprep/get_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/get_file" \ -H "Content-Type: application/json" ``` @@ -375,17 +375,17 @@ To delete the file/link you uploaded: ```bash # delete link -curl -X POST "http://${host_ip}:6009/v1/dataprep/delete_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/delete_file" \ -d '{"file_path": "https://opea.dev"}' \ -H "Content-Type: application/json" # delete file -curl -X POST "http://${host_ip}:6009/v1/dataprep/delete_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/delete_file" \ -d '{"file_path": "nke-10k-2023.pdf"}' \ -H "Content-Type: application/json" # delete all uploaded files and links -curl -X POST "http://${host_ip}:6009/v1/dataprep/delete_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/delete_file" \ -d '{"file_path": "all"}' \ -H "Content-Type: application/json" ``` diff --git a/ChatQnA/docker/gaudi/compose.yaml b/ChatQnA/docker/gaudi/compose.yaml index ead0b7db3..362ce1824 100644 --- a/ChatQnA/docker/gaudi/compose.yaml +++ b/ChatQnA/docker/gaudi/compose.yaml @@ -19,8 +19,6 @@ services: - tei-embedding-service ports: - "6007:6007" - - "6008:6008" - - "6009:6009" environment: no_proxy: ${no_proxy} http_proxy: ${http_proxy} diff --git a/ChatQnA/docker/gaudi/compose_guardrails.yaml b/ChatQnA/docker/gaudi/compose_guardrails.yaml index b3c759064..0454bb161 100644 --- a/ChatQnA/docker/gaudi/compose_guardrails.yaml +++ b/ChatQnA/docker/gaudi/compose_guardrails.yaml @@ -19,8 +19,6 @@ services: - tei-embedding-service ports: - "6007:6007" - - "6008:6008" - - "6009:6009" environment: no_proxy: ${no_proxy} http_proxy: ${http_proxy} diff --git a/ChatQnA/docker/gaudi/compose_vllm.yaml b/ChatQnA/docker/gaudi/compose_vllm.yaml index 2f29a932f..69be293f3 100644 --- a/ChatQnA/docker/gaudi/compose_vllm.yaml +++ b/ChatQnA/docker/gaudi/compose_vllm.yaml @@ -19,8 +19,6 @@ services: - tei-embedding-service ports: - "6007:6007" - - "6008:6008" - - "6009:6009" environment: no_proxy: ${no_proxy} http_proxy: ${http_proxy} diff --git a/ChatQnA/docker/gaudi/compose_vllm_ray.yaml b/ChatQnA/docker/gaudi/compose_vllm_ray.yaml index 9d954a0b9..7bce9463a 100644 --- a/ChatQnA/docker/gaudi/compose_vllm_ray.yaml +++ b/ChatQnA/docker/gaudi/compose_vllm_ray.yaml @@ -19,8 +19,6 @@ services: - tei-embedding-service ports: - "6007:6007" - - "6008:6008" - - "6009:6009" environment: no_proxy: ${no_proxy} http_proxy: ${http_proxy} diff --git a/ChatQnA/docker/gpu/README.md b/ChatQnA/docker/gpu/README.md index eff77ee17..a5130b5e5 100644 --- a/ChatQnA/docker/gpu/README.md +++ b/ChatQnA/docker/gpu/README.md @@ -100,8 +100,8 @@ export RERANK_SERVICE_HOST_IP=${host_ip} export LLM_SERVICE_HOST_IP=${host_ip} export BACKEND_SERVICE_ENDPOINT="http://${host_ip}:8888/v1/chatqna" export DATAPREP_SERVICE_ENDPOINT="http://${host_ip}:6007/v1/dataprep" -export DATAPREP_GET_FILE_ENDPOINT="http://${host_ip}:6008/v1/dataprep/get_file" -export DATAPREP_DELETE_FILE_ENDPOINT="http://${host_ip}:6009/v1/dataprep/delete_file" +export DATAPREP_GET_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/get_file" +export DATAPREP_DELETE_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/delete_file" ``` Note: Please replace with `host_ip` with you external IP address, do **NOT** use localhost. @@ -220,7 +220,7 @@ This command updates a knowledge base by submitting a list of HTTP links for pro Also, you are able to get the file list that you uploaded: ```bash -curl -X POST "http://${host_ip}:6008/v1/dataprep/get_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/get_file" \ -H "Content-Type: application/json" ``` @@ -228,17 +228,17 @@ To delete the file/link you uploaded: ```bash # delete link -curl -X POST "http://${host_ip}:6009/v1/dataprep/delete_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/delete_file" \ -d '{"file_path": "https://opea.dev"}' \ -H "Content-Type: application/json" # delete file -curl -X POST "http://${host_ip}:6009/v1/dataprep/delete_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/delete_file" \ -d '{"file_path": "nke-10k-2023.pdf"}' \ -H "Content-Type: application/json" # delete all uploaded files and links -curl -X POST "http://${host_ip}:6009/v1/dataprep/delete_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/delete_file" \ -d '{"file_path": "all"}' \ -H "Content-Type: application/json" ``` diff --git a/ChatQnA/docker/gpu/compose.yaml b/ChatQnA/docker/gpu/compose.yaml index 65682d384..13f0a3fbc 100644 --- a/ChatQnA/docker/gpu/compose.yaml +++ b/ChatQnA/docker/gpu/compose.yaml @@ -19,8 +19,6 @@ services: - tei-embedding-service ports: - "6007:6007" - - "6008:6008" - - "6009:6009" environment: no_proxy: ${no_proxy} http_proxy: ${http_proxy} diff --git a/ChatQnA/docker/gpu/set_env.sh b/ChatQnA/docker/gpu/set_env.sh index e024bd8a6..3b3d43336 100644 --- a/ChatQnA/docker/gpu/set_env.sh +++ b/ChatQnA/docker/gpu/set_env.sh @@ -19,5 +19,5 @@ export RERANK_SERVICE_HOST_IP=${host_ip} export LLM_SERVICE_HOST_IP=${host_ip} export BACKEND_SERVICE_ENDPOINT="http://${host_ip}:8888/v1/chatqna" export DATAPREP_SERVICE_ENDPOINT="http://${host_ip}:6007/v1/dataprep" -export DATAPREP_GET_FILE_ENDPOINT="http://${host_ip}:6008/v1/dataprep/get_file" -export DATAPREP_DELETE_FILE_ENDPOINT="http://${host_ip}:6009/v1/dataprep/delete_file" +export DATAPREP_GET_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/get_file" +export DATAPREP_DELETE_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/delete_file" diff --git a/ChatQnA/docker/ui/svelte/.env b/ChatQnA/docker/ui/svelte/.env index 1f1eb0acc..fad2468c0 100644 --- a/ChatQnA/docker/ui/svelte/.env +++ b/ChatQnA/docker/ui/svelte/.env @@ -2,6 +2,6 @@ CHAT_BASE_URL = 'http://backend_address:8888/v1/chatqna' UPLOAD_FILE_BASE_URL = 'http://backend_address:6007/v1/dataprep' -GET_FILE = 'http://backend_address:6008/v1/dataprep/get_file' +GET_FILE = 'http://backend_address:6007/v1/dataprep/get_file' -DELETE_FILE = 'http://backend_address:6009/v1/dataprep/delete_file' +DELETE_FILE = 'http://backend_address:6007/v1/dataprep/delete_file' diff --git a/ChatQnA/docker/xeon/README.md b/ChatQnA/docker/xeon/README.md index b6c1fe3a4..a8a815d4f 100644 --- a/ChatQnA/docker/xeon/README.md +++ b/ChatQnA/docker/xeon/README.md @@ -146,7 +146,7 @@ Build frontend Docker image that enables Conversational experience with ChatQnA cd GenAIExamples/ChatQnA/docker/ui/ export BACKEND_SERVICE_ENDPOINT="http://${host_ip}:8888/v1/chatqna" export DATAPREP_SERVICE_ENDPOINT="http://${host_ip}:6007/v1/dataprep" -export DATAPREP_GET_FILE_ENDPOINT="http://${host_ip}:6008/v1/dataprep/get_file" +export DATAPREP_GET_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/get_file" docker build --no-cache -t opea/chatqna-conversation-ui:latest --build-arg https_proxy=$https_proxy --build-arg http_proxy=$http_proxy --build-arg BACKEND_SERVICE_ENDPOINT=$BACKEND_SERVICE_ENDPOINT --build-arg DATAPREP_SERVICE_ENDPOINT=$DATAPREP_SERVICE_ENDPOINT --build-arg DATAPREP_GET_FILE_ENDPOINT=$DATAPREP_GET_FILE_ENDPOINT -f ./docker/Dockerfile.react . cd ../../../.. ``` @@ -211,8 +211,8 @@ export RERANK_SERVICE_HOST_IP=${host_ip} export LLM_SERVICE_HOST_IP=${host_ip} export BACKEND_SERVICE_ENDPOINT="http://${host_ip}:8888/v1/chatqna" export DATAPREP_SERVICE_ENDPOINT="http://${host_ip}:6007/v1/dataprep" -export DATAPREP_GET_FILE_ENDPOINT="http://${host_ip}:6008/v1/dataprep/get_file" -export DATAPREP_DELETE_FILE_ENDPOINT="http://${host_ip}:6009/v1/dataprep/delete_file" +export DATAPREP_GET_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/get_file" +export DATAPREP_DELETE_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/delete_file" ``` Note: Please replace with `host_ip` with you external IP address, do not use localhost. @@ -352,7 +352,7 @@ This command updates a knowledge base by submitting a list of HTTP links for pro Also, you are able to get the file list that you uploaded: ```bash -curl -X POST "http://${host_ip}:6008/v1/dataprep/get_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/get_file" \ -H "Content-Type: application/json" ``` @@ -360,17 +360,17 @@ To delete the file/link you uploaded: ```bash # delete link -curl -X POST "http://${host_ip}:6009/v1/dataprep/delete_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/delete_file" \ -d '{"file_path": "https://opea.dev"}' \ -H "Content-Type: application/json" # delete file -curl -X POST "http://${host_ip}:6009/v1/dataprep/delete_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/delete_file" \ -d '{"file_path": "nke-10k-2023.pdf"}' \ -H "Content-Type: application/json" # delete all uploaded files and links -curl -X POST "http://${host_ip}:6009/v1/dataprep/delete_file" \ +curl -X POST "http://${host_ip}:6007/v1/dataprep/delete_file" \ -d '{"file_path": "all"}' \ -H "Content-Type: application/json" ``` diff --git a/ChatQnA/docker/xeon/compose.yaml b/ChatQnA/docker/xeon/compose.yaml index b865ab38e..6c996a735 100644 --- a/ChatQnA/docker/xeon/compose.yaml +++ b/ChatQnA/docker/xeon/compose.yaml @@ -19,8 +19,6 @@ services: - tei-embedding-service ports: - "6007:6007" - - "6008:6008" - - "6009:6009" environment: no_proxy: ${no_proxy} http_proxy: ${http_proxy} diff --git a/ChatQnA/docker/xeon/docker_compose_vllm.yaml b/ChatQnA/docker/xeon/docker_compose_vllm.yaml index 4791b530f..2ff0faa1a 100644 --- a/ChatQnA/docker/xeon/docker_compose_vllm.yaml +++ b/ChatQnA/docker/xeon/docker_compose_vllm.yaml @@ -19,8 +19,6 @@ services: - tei-embedding-service ports: - "6007:6007" - - "6008:6008" - - "6009:6009" environment: no_proxy: ${no_proxy} http_proxy: ${http_proxy} diff --git a/ChatQnA/tests/test_chatqna_on_gaudi.sh b/ChatQnA/tests/test_chatqna_on_gaudi.sh index 4ac991b78..957a02685 100644 --- a/ChatQnA/tests/test_chatqna_on_gaudi.sh +++ b/ChatQnA/tests/test_chatqna_on_gaudi.sh @@ -176,14 +176,14 @@ function validate_microservices() { # test /v1/dataprep/get_file validate_service \ - "http://${ip_address}:6008/v1/dataprep/get_file" \ + "http://${ip_address}:6007/v1/dataprep/get_file" \ '{"name":' \ "dataprep_get" \ "dataprep-redis-server" # test /v1/dataprep/delete_file validate_service \ - "http://${ip_address}:6009/v1/dataprep/delete_file" \ + "http://${ip_address}:6007/v1/dataprep/delete_file" \ '{"status":true}' \ "dataprep_del" \ "dataprep-redis-server" diff --git a/ChatQnA/tests/test_chatqna_on_xeon.sh b/ChatQnA/tests/test_chatqna_on_xeon.sh index 6c4aa1fb5..bff1c5527 100644 --- a/ChatQnA/tests/test_chatqna_on_xeon.sh +++ b/ChatQnA/tests/test_chatqna_on_xeon.sh @@ -49,8 +49,8 @@ function start_services() { export LLM_SERVICE_HOST_IP=${ip_address} export BACKEND_SERVICE_ENDPOINT="http://${ip_address}:8888/v1/chatqna" export DATAPREP_SERVICE_ENDPOINT="http://${ip_address}:6007/v1/dataprep" - export DATAPREP_GET_FILE_ENDPOINT="http://${ip_address}:6008/v1/dataprep/get_file" - export DATAPREP_DELETE_FILE_ENDPOINT="http://${ip_address}:6009/v1/dataprep/delete_file" + export DATAPREP_GET_FILE_ENDPOINT="http://${ip_address}:6007/v1/dataprep/get_file" + export DATAPREP_DELETE_FILE_ENDPOINT="http://${ip_address}:6007/v1/dataprep/delete_file" sed -i "s/backend_address/$ip_address/g" $WORKPATH/docker/ui/svelte/.env @@ -162,14 +162,14 @@ function validate_microservices() { # test /v1/dataprep/get_file validate_service \ - "http://${ip_address}:6008/v1/dataprep/get_file" \ + "http://${ip_address}:6007/v1/dataprep/get_file" \ '{"name":' \ "dataprep_get" \ "dataprep-redis-server" # test /v1/dataprep/delete_file validate_service \ - "http://${ip_address}:6009/v1/dataprep/delete_file" \ + "http://${ip_address}:6007/v1/dataprep/delete_file" \ '{"status":true}' \ "dataprep_del" \ "dataprep-redis-server"