diff --git a/ChatQnA/docker_compose/intel/cpu/aipc/README.md b/ChatQnA/docker_compose/intel/cpu/aipc/README.md index d075b9843..d8541c89b 100644 --- a/ChatQnA/docker_compose/intel/cpu/aipc/README.md +++ b/ChatQnA/docker_compose/intel/cpu/aipc/README.md @@ -158,6 +158,13 @@ export RERANK_SERVER_HOST_IP=${host_ip} export LLM_SERVER_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}:6007/v1/dataprep/get_file" +export DATAPREP_DELETE_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/delete_file" +export FRONTEND_SERVICE_IP=${host_ip} +export FRONTEND_SERVICE_PORT=5173 +export BACKEND_SERVICE_NAME=chatqna +export BACKEND_SERVICE_IP=${host_ip} +export BACKEND_SERVICE_PORT=8888 export OLLAMA_ENDPOINT=http://${host_ip}:11434 export OLLAMA_MODEL="llama3" @@ -179,6 +186,13 @@ set RERANK_SERVER_HOST_IP=%host_ip% set LLM_SERVER_HOST_IP=%host_ip% set BACKEND_SERVICE_ENDPOINT=http://%host_ip%:8888/v1/chatqna set DATAPREP_SERVICE_ENDPOINT=http://%host_ip%:6007/v1/dataprep +set DATAPREP_GET_FILE_ENDPOINT="http://%host_ip%:6007/v1/dataprep/get_file" +set DATAPREP_DELETE_FILE_ENDPOINT="http://%host_ip%:6007/v1/dataprep/delete_file" +set FRONTEND_SERVICE_IP=%host_ip% +set FRONTEND_SERVICE_PORT=5173 +set BACKEND_SERVICE_NAME=chatqna +set BACKEND_SERVICE_IP=%host_ip% +set BACKEND_SERVICE_PORT=8888 set OLLAMA_ENDPOINT=http://host.docker.internal:11434 set OLLAMA_MODEL="llama3" diff --git a/ChatQnA/docker_compose/intel/cpu/aipc/compose.yaml b/ChatQnA/docker_compose/intel/cpu/aipc/compose.yaml index 3d70480e6..664b6281f 100644 --- a/ChatQnA/docker_compose/intel/cpu/aipc/compose.yaml +++ b/ChatQnA/docker_compose/intel/cpu/aipc/compose.yaml @@ -51,6 +51,7 @@ services: REDIS_URL: ${REDIS_URL} INDEX_NAME: ${INDEX_NAME} TEI_EMBEDDING_ENDPOINT: ${TEI_EMBEDDING_ENDPOINT} + HUGGINGFACEHUB_API_TOKEN: ${HUGGINGFACEHUB_API_TOKEN} restart: unless-stopped tei-reranking-service: image: ghcr.io/huggingface/text-embeddings-inference:cpu-1.5 @@ -123,6 +124,8 @@ services: - http_proxy=${http_proxy} - CHAT_BASE_URL=${BACKEND_SERVICE_ENDPOINT} - UPLOAD_FILE_BASE_URL=${DATAPREP_SERVICE_ENDPOINT} + - GET_FILE=${DATAPREP_GET_FILE_ENDPOINT} + - DELETE_FILE=${DATAPREP_DELETE_FILE_ENDPOINT} ipc: host restart: always diff --git a/ChatQnA/docker_compose/intel/cpu/aipc/set_env.sh b/ChatQnA/docker_compose/intel/cpu/aipc/set_env.sh new file mode 100644 index 000000000..2cb996874 --- /dev/null +++ b/ChatQnA/docker_compose/intel/cpu/aipc/set_env.sh @@ -0,0 +1,39 @@ +#!/usr/bin/env bash + +# Copyright (C) 2024 Intel Corporation +# SPDX-License-Identifier: Apache-2.0 + + +if [ -z "${your_hf_api_token}" ]; then + echo "Error: HUGGINGFACEHUB_API_TOKEN is not set. Please set your_hf_api_token." +fi + +if [ -z "${host_ip}" ]; then + echo "Error: host_ip is not set. Please set host_ip first." +fi + +export HUGGINGFACEHUB_API_TOKEN=${your_hf_api_token} +export EMBEDDING_MODEL_ID="BAAI/bge-base-en-v1.5" +export RERANK_MODEL_ID="BAAI/bge-reranker-base" +export TEI_EMBEDDING_ENDPOINT="http://${host_ip}:6006" +export TEI_RERANKING_ENDPOINT="http://${host_ip}:8808" +export REDIS_URL="redis://${host_ip}:6379" +export INDEX_NAME="rag-redis" +export REDIS_HOST=${host_ip} +export MEGA_SERVICE_HOST_IP=${host_ip} +export EMBEDDING_SERVICE_HOST_IP=${host_ip} +export RETRIEVER_SERVICE_HOST_IP=${host_ip} +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}:6007/v1/dataprep/get_file" +export DATAPREP_DELETE_FILE_ENDPOINT="http://${host_ip}:6007/v1/dataprep/delete_file" +export FRONTEND_SERVICE_IP=${host_ip} +export FRONTEND_SERVICE_PORT=5173 +export BACKEND_SERVICE_NAME=chatqna +export BACKEND_SERVICE_IP=${host_ip} +export BACKEND_SERVICE_PORT=8888 + +export OLLAMA_ENDPOINT=http://${host_ip}:11434 +export OLLAMA_MODEL="llama3"