Skip to content

Commit 33fe3b4

Browse files
committed
merge conflict
Signed-off-by: Xinyao Wang <xinyao.wang@intel.com>
2 parents 3962f1b + 1b6342a commit 33fe3b4

File tree

8 files changed

+297
-582
lines changed

8 files changed

+297
-582
lines changed

.github/workflows/_example-workflow.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,9 @@ on:
5050
type: boolean
5151

5252
jobs:
53+
####################################################################################################
54+
# Image Build
55+
####################################################################################################
5356
pre-build-image-check:
5457
runs-on: ubuntu-latest
5558
outputs:
@@ -64,9 +67,6 @@ jobs:
6467
echo "should_skip=false" >> $GITHUB_OUTPUT
6568
fi
6669
67-
####################################################################################################
68-
# Image Build
69-
####################################################################################################
7070
build-images:
7171
needs: [pre-build-image-check]
7272
if: ${{ needs.pre-build-image-check.outputs.should_skip == 'false' }}
@@ -133,7 +133,7 @@ jobs:
133133
run: |
134134
set -x
135135
run_compose="false"
136-
if [[ ${{ inputs.test_compose }} ]]; then
136+
if [[ "${{ inputs.test_compose }}" == "true" ]]; then
137137
if [[ "${{ needs.pre-build-image-check.outputs.should_skip }}" == "false" && "${{ needs.build-images.result}}" == "success" || "${{ needs.pre-build-image-check.outputs.should_skip }}" == "true" ]]; then
138138
run_compose="true"
139139
fi

.github/workflows/daily_check_issue_and_pr.yml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,13 @@ jobs:
1616
steps:
1717
- uses: actions/stale@v9
1818
with:
19-
days-before-issue-stale: 60
20-
days-before-pr-stale: 60
19+
days-before-issue-stale: 30
20+
days-before-pr-stale: 30
2121
days-before-issue-close: 7
2222
days-before-pr-close: 7
23-
stale-issue-message: "This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days."
24-
stale-pr-message: "This PR is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days."
23+
stale-issue-message: "This issue is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days."
24+
stale-pr-message: "This PR is stale because it has been open 30 days with no activity. Remove stale label or comment or this will be closed in 7 days."
2525
close-issue-message: "This issue was closed because it has been stalled for 7 days with no activity."
2626
close-pr-message: "This PR was closed because it has been stalled for 7 days with no activity."
2727
repo-token: ${{ secrets.ACTION_TOKEN }}
28-
start-date: "2025-01-01T00:00:00Z"
29-
debug-only: true # will remove this line when ready to merge
28+
start-date: "2025-03-01T00:00:00Z"

.github/workflows/manual-example-workflow.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,12 +52,12 @@ on:
5252
type: string
5353
inject_commit:
5454
default: false
55-
description: "inject commit to docker images true or false"
55+
description: "inject commit to docker images"
5656
required: false
5757
type: boolean
5858
use_model_cache:
5959
default: false
60-
description: "use model cache true or false"
60+
description: "use model cache"
6161
required: false
6262
type: boolean
6363

.github/workflows/manual-image-build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,9 @@ on:
3232
type: string
3333
inject_commit:
3434
default: false
35-
description: "inject commit to docker images true or false"
35+
description: "inject commit to docker images"
3636
required: false
37-
type: string
37+
type: boolean
3838

3939
jobs:
4040
get-test-matrix:

ChatQnA/docker_compose/intel/hpu/gaudi/README.md

Lines changed: 198 additions & 535 deletions
Large diffs are not rendered by default.

ChatQnA/docker_compose/intel/hpu/gaudi/set_env.sh

100644100755
Lines changed: 86 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,94 @@
1-
#!/usr/bin/env bash
1+
#/usr/bin/env bash
22

33
# Copyright (C) 2024 Intel Corporation
44
# SPDX-License-Identifier: Apache-2.0
5+
6+
# Function to prompt for input and set environment variables
7+
prompt_for_env_var() {
8+
local var_name="$1"
9+
local prompt_message="$2"
10+
local default_value="$3"
11+
local mandatory="$4"
12+
13+
if [[ "$mandatory" == "true" ]]; then
14+
while [[ -z "$value" ]]; do
15+
read -p "$prompt_message [default: \"${default_value}\"]: " value
16+
if [[ -z "$value" ]]; then
17+
echo "Input cannot be empty. Please try again."
18+
fi
19+
done
20+
else
21+
read -p "$prompt_message [default: \"${default_value}\"]: " value
22+
fi
23+
24+
if [[ "$value" == "" ]]; then
25+
export "$var_name"="$default_value"
26+
else
27+
export "$var_name"="$value"
28+
fi
29+
}
30+
531
pushd "../../../../../" > /dev/null
632
source .set_env.sh
733
popd > /dev/null
834

35+
# Prompt the user for each required environment variable
36+
prompt_for_env_var "EMBEDDING_MODEL_ID" "Enter the EMBEDDING_MODEL_ID" "BAAI/bge-base-en-v1.5" false
37+
prompt_for_env_var "HUGGINGFACEHUB_API_TOKEN" "Enter the HUGGINGFACEHUB_API_TOKEN" "" true
38+
prompt_for_env_var "RERANK_MODEL_ID" "Enter the RERANK_MODEL_ID" "BAAI/bge-reranker-base" false
39+
prompt_for_env_var "LLM_MODEL_ID" "Enter the LLM_MODEL_ID" "meta-llama/Meta-Llama-3-8B-Instruct" false
40+
prompt_for_env_var "INDEX_NAME" "Enter the INDEX_NAME" "rag-redis" false
41+
prompt_for_env_var "NUM_CARDS" "Enter the number of Gaudi devices" "1" false
42+
prompt_for_env_var "host_ip" "Enter the host_ip" "$(curl ifconfig.me)" false
43+
44+
#Query for enabling http_proxy
45+
prompt_for_env_var "http_proxy" "Enter the http_proxy." "" false
46+
47+
#Query for enabling https_proxy
48+
prompt_for_env_var "https_proxy" "Enter the https_proxy." "" false
49+
50+
#Query for enabling no_proxy
51+
prompt_for_env_var "no_proxy" "Enter the no_proxy." "" false
52+
53+
# Query for enabling logging
54+
read -p "Enable logging? (yes/no): " logging && logging=$(echo "$logging" | tr '[:upper:]' '[:lower:]')
55+
if [[ "$logging" == "yes" || "$logging" == "y" ]]; then
56+
export LOGFLAG=true
57+
else
58+
export LOGFLAG=false
59+
fi
60+
61+
# Query for enabling OpenTelemetry Tracing Endpoint
62+
read -p "Enable OpenTelemetry Tracing Endpoint? (yes/no): " telemetry && telemetry=$(echo "$telemetry" | tr '[:upper:]' '[:lower:]')
63+
if [[ "$telemetry" == "yes" || "$telemetry" == "y" ]]; then
64+
export JAEGER_IP=$(ip route get 8.8.8.8 | grep -oP 'src \K[^ ]+')
65+
export OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=grpc://$JAEGER_IP:4317
66+
export TELEMETRY_ENDPOINT=http://$JAEGER_IP:4318/v1/traces
67+
telemetry_flag=true
68+
else
69+
telemetry_flag=false
70+
fi
71+
72+
# Generate the .env file
73+
cat <<EOF > .env
74+
#!/bin/bash
75+
# Set all required ENV values
76+
export TAG=${TAG}
77+
export EMBEDDING_MODEL_ID=${EMBEDDING_MODEL_ID}
78+
export HUGGINGFACEHUB_API_TOKEN=$HUGGINGFACEHUB_API_TOKEN
79+
export RERANK_MODEL_ID=${RERANK_MODEL_ID}
80+
export LLM_MODEL_ID=${LLM_MODEL_ID}
81+
export INDEX_NAME=${INDEX_NAME}
82+
export NUM_CARDS=${NUM_CARDS}
83+
export host_ip=${host_ip}
84+
export http_proxy=${http_proxy}
85+
export https_proxy=${https_proxy}
86+
export no_proxy=${no_proxy}
87+
export LOGFLAG=${LOGFLAG}
88+
export JAEGER_IP=${JAEGER_IP}
89+
export OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=${OTEL_EXPORTER_OTLP_TRACES_ENDPOINT}
90+
export TELEMETRY_ENDPOINT=${TELEMETRY_ENDPOINT}
91+
EOF
992

10-
export EMBEDDING_MODEL_ID="BAAI/bge-base-en-v1.5"
11-
export RERANK_MODEL_ID="BAAI/bge-reranker-base"
12-
export LLM_MODEL_ID="meta-llama/Meta-Llama-3-8B-Instruct"
13-
export INDEX_NAME="rag-redis"
14-
export NUM_CARDS=1
15-
# Set it as a non-null string, such as true, if you want to enable logging facility,
16-
# otherwise, keep it as "" to disable it.
17-
export LOGFLAG=""
18-
# Set OpenTelemetry Tracing Endpoint
19-
export JAEGER_IP=$(ip route get 8.8.8.8 | grep -oP 'src \K[^ ]+')
20-
export OTEL_EXPORTER_OTLP_TRACES_ENDPOINT=grpc://$JAEGER_IP:4317
21-
export TELEMETRY_ENDPOINT=http://$JAEGER_IP:4318/v1/traces
22-
export no_proxy="$no_proxy,chatqna-gaudi-ui-server,chatqna-gaudi-backend-server,dataprep-redis-service,tei-embedding-service,retriever,tei-reranking-service,tgi-gaudi-server,vllm-gaudi-server,guardrails,jaeger,prometheus,grafana,node-exporter,gaudi-exporter,$JAEGER_IP"
23-
24-
export LLM_ENDPOINT_PORT=8010
25-
export LLM_SERVER_PORT=9001
26-
export CHATQNA_BACKEND_PORT=8888
27-
export CHATQNA_REDIS_VECTOR_PORT=6379
28-
export CHATQNA_REDIS_VECTOR_INSIGHT_PORT=8001
29-
export CHATQNA_FRONTEND_SERVICE_PORT=5173
30-
export NGINX_PORT=80
31-
export FAQGen_COMPONENT_NAME="OpeaFaqGenvLLM"
32-
export LLM_ENDPOINT="http://${host_ip}:${LLM_ENDPOINT_PORT}"
93+
echo ".env file has been created with the following content:"
94+
cat .env

README.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ Below are some highlighted GenAI use cases across various application scenarios:
2121
| <b>Question Answering<b/> | [ChatQnA](ChatQnA) ✨: Chatbot with Retrieval Augmented Generation (RAG). <br/> [VisualQnA](VisualQnA) ✨: Visual Question-answering. |
2222
| <b>Image Generation<b/> | [Text2Image](Text2Image) ✨: Text-to-image generation. |
2323
| <b>Content Summarization<b/> | [DocSum](DocSum): Document Summarization Application. |
24-
| <b>FAQ Generation<b/> | [FaqGen](FaqGen): Frequently asked questions (FAQs) generation from your documents, legal texts, customer queries etc. |
2524
| <b>Code Generation<b/> | [CodeGen](CodeGen): Gen-AI Powered Code Generator. |
2625
| <b>Information Retrieval<b/> | [DocIndexRetriever](DocIndexRetriever): Document Retrieval with Retrieval Augmented Generation (RAG). |
2726
| <b>Fine-tuning<b/> | [InstructionTuning](InstructionTuning): Application of Instruction Tuning. |
@@ -72,7 +71,6 @@ Deployment is based on released docker images by default - check [docker image l
7271
| CodeTrans | [Xeon Instructions](CodeTrans/docker_compose/intel/cpu/xeon/README.md) | [Gaudi Instructions](CodeTrans/docker_compose/intel/hpu/gaudi/README.md) | [ROCm Instructions](CodeTrans/docker_compose/amd/gpu/rocm/README.md) | [CodeTrans with Helm Charts](CodeTrans/kubernetes/helm/README.md) | [CodeTrans with GMC](CodeTrans/kubernetes/gmc/README.md) |
7372
| DocSum | [Xeon Instructions](DocSum/docker_compose/intel/cpu/xeon/README.md) | [Gaudi Instructions](DocSum/docker_compose/intel/hpu/gaudi/README.md) | [ROCm Instructions](DocSum/docker_compose/amd/gpu/rocm/README.md) | [DocSum with Helm Charts](DocSum/kubernetes/helm/README.md) | [DocSum with GMC](DocSum/kubernetes/gmc/README.md) |
7473
| SearchQnA | [Xeon Instructions](SearchQnA/docker_compose/intel/cpu/xeon/README.md) | [Gaudi Instructions](SearchQnA/docker_compose/intel/hpu/gaudi/README.md) | Not Supported | [SearchQnA with Helm Charts](SearchQnA/kubernetes/helm/README.md) | [SearchQnA with GMC](SearchQnA/kubernetes/gmc/README.md) |
75-
| FaqGen | [Xeon Instructions](FaqGen/docker_compose/intel/cpu/xeon/README.md) | [Gaudi Instructions](FaqGen/docker_compose/intel/hpu/gaudi/README.md) | [ROCm Instructions](FaqGen/docker_compose/amd/gpu/rocm/README.md) | [FaqGen with Helm Charts](FaqGen/kubernetes/helm/README.md) | Not supported |
7674
| Translation | [Xeon Instructions](Translation/docker_compose/intel/cpu/xeon/README.md) | [Gaudi Instructions](Translation/docker_compose/intel/hpu/gaudi/README.md) | [ROCm Instructions](Translation/docker_compose/amd/gpu/rocm/README.md) | Not Supported | [Translation with GMC](Translation/kubernetes/gmc/README.md) |
7775
| AudioQnA | [Xeon Instructions](AudioQnA/docker_compose/intel/cpu/xeon/README.md) | [Gaudi Instructions](AudioQnA/docker_compose/intel/hpu/gaudi/README.md) | [ROCm Instructions](AudioQnA/docker_compose/amd/gpu/rocm/README.md) | [AudioQnA with Helm Charts](AudioQnA/kubernetes/helm/README.md) | [AudioQnA with GMC](AudioQnA/kubernetes/gmc/README.md) |
7876
| VisualQnA | [Xeon Instructions](VisualQnA/docker_compose/intel/cpu/xeon/README.md) | [Gaudi Instructions](VisualQnA/docker_compose/intel/hpu/gaudi/README.md) | [ROCm Instructions](VisualQnA/docker_compose/amd/gpu/rocm/README.md) | [VisualQnA with Helm Charts](VisualQnA/kubernetes/helm/README.md) | [VisualQnA with GMC](VisualQnA/kubernetes/gmc/README.md) |

supported_examples.md

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -177,13 +177,6 @@ The [AudioQnA](./AudioQnA/README.md) example demonstrates the integration of Gen
177177
</tr>
178178
</table>
179179

180-
### FaqGen
181-
182-
[FAQ Generation](./FaqGen/README.md) application leverages the power of large language models (LLMs) to revolutionize the way you interact with and comprehend complex textual data. By harnessing cutting-edge natural language processing techniques, our application can automatically generate comprehensive and natural-sounding frequently asked questions (FAQs) from your documents, legal texts, customer queries, and other sources. In this example use case, we utilize LangChain to implement FAQ Generation and facilitate LLM inference using Text Generation Inference on Intel Xeon and Gaudi2 processors.
183-
| Framework | LLM | Serving | HW | Description |
184-
| ------------------------------------------------------------------------------ | ----------------------------------------------------------------- | --------------------------------------------------------------- | ----------- | ----------- |
185-
| [LangChain](https://www.langchain.com)/[LlamaIndex](https://www.llamaindex.ai) | [Meta-Llama-3-8B-Instruct](https://huggingface.co/meta-llama/Meta-Llama-3-8B-Instruct) | [TGI](https://github.com/huggingface/text-generation-inference) | Xeon/Gaudi2 | Chatbot |
186-
187180
### MultimodalQnA
188181

189182
[MultimodalQnA](./MultimodalQnA/README.md) addresses your questions by dynamically fetching the most pertinent multimodal information (frames, transcripts, and/or captions) from your collection of videos, images, or audio files. MultimodalQnA utilizes BridgeTower model, a multimodal encoding transformer model which merges visual and textual data into a unified semantic space. During the ingestion phase, the BridgeTower model embeds both visual cues and auditory facts as texts, and those embeddings are then stored in a vector database. When it comes to answering a question, the MultimodalQnA will fetch its most relevant multimodal content from the vector store and feed it into a downstream Large Vision-Language Model (LVM) as input context to generate a response for the user.

0 commit comments

Comments
 (0)