From b80ae5041957af7afe68522991eeda66ee49d347 Mon Sep 17 00:00:00 2001 From: bjzhjing Date: Wed, 4 Sep 2024 17:08:24 +0800 Subject: [PATCH] helm-chart/common: Add logging config for service components (#375) Logging is added in GenAIComps to print input/output, add it here for components debugging. Signed-off-by: Cathy Zhang --- helm-charts/common/asr/templates/configmap.yaml | 1 + helm-charts/common/asr/values.yaml | 4 ++++ helm-charts/common/data-prep/templates/configmap.yaml | 1 + helm-charts/common/data-prep/values.yaml | 4 ++++ helm-charts/common/embedding-usvc/templates/configmap.yaml | 1 + helm-charts/common/embedding-usvc/values.yaml | 4 ++++ helm-charts/common/llm-uservice/templates/configmap.yaml | 1 + helm-charts/common/llm-uservice/values.yaml | 4 ++++ helm-charts/common/reranking-usvc/templates/configmap.yaml | 1 + helm-charts/common/reranking-usvc/values.yaml | 4 ++++ helm-charts/common/retriever-usvc/templates/configmap.yaml | 1 + helm-charts/common/retriever-usvc/values.yaml | 4 ++++ helm-charts/common/tts/templates/configmap.yaml | 1 + helm-charts/common/tts/values.yaml | 4 ++++ helm-charts/common/web-retriever/templates/configmap.yaml | 1 + helm-charts/common/web-retriever/values.yaml | 4 ++++ microservices-connector/config/manifests/asr.yaml | 1 + microservices-connector/config/manifests/data-prep.yaml | 1 + .../config/manifests/docsum-llm-uservice.yaml | 1 + microservices-connector/config/manifests/embedding-usvc.yaml | 1 + microservices-connector/config/manifests/llm-uservice.yaml | 1 + microservices-connector/config/manifests/reranking-usvc.yaml | 1 + microservices-connector/config/manifests/retriever-usvc.yaml | 1 + microservices-connector/config/manifests/tts.yaml | 1 + microservices-connector/config/manifests/web-retriever.yaml | 1 + 25 files changed, 49 insertions(+) diff --git a/helm-charts/common/asr/templates/configmap.yaml b/helm-charts/common/asr/templates/configmap.yaml index 19eb0cf7..965e98fc 100644 --- a/helm-charts/common/asr/templates/configmap.yaml +++ b/helm-charts/common/asr/templates/configmap.yaml @@ -20,3 +20,4 @@ data: {{- else }} no_proxy: {{ .Values.global.no_proxy | quote }} {{- end }} + LOGFLAG: {{ .Values.LOGFLAG | quote }} diff --git a/helm-charts/common/asr/values.yaml b/helm-charts/common/asr/values.yaml index d1167ff3..02f7ceea 100644 --- a/helm-charts/common/asr/values.yaml +++ b/helm-charts/common/asr/values.yaml @@ -10,6 +10,10 @@ autodependency: replicaCount: 1 +# Set it as a non-null string, such as true, if you want to enable logging facility, +# otherwise, keep it as "" to disable it. +LOGFLAG: "" + ASR_ENDPOINT: "" image: diff --git a/helm-charts/common/data-prep/templates/configmap.yaml b/helm-charts/common/data-prep/templates/configmap.yaml index 44b1559e..63622762 100644 --- a/helm-charts/common/data-prep/templates/configmap.yaml +++ b/helm-charts/common/data-prep/templates/configmap.yaml @@ -37,3 +37,4 @@ data: LANGCHAIN_TRACING_V2: {{ .Values.global.LANGCHAIN_TRACING_V2 | quote }} LANGCHAIN_API_KEY: {{ .Values.global.LANGCHAIN_API_KEY | quote }} LANGCHAIN_PROJECT: "opea-dataprep-service" + LOGFLAG: {{ .Values.LOGFLAG | quote }} diff --git a/helm-charts/common/data-prep/values.yaml b/helm-charts/common/data-prep/values.yaml index 62f98b4d..6a1fc082 100644 --- a/helm-charts/common/data-prep/values.yaml +++ b/helm-charts/common/data-prep/values.yaml @@ -79,6 +79,10 @@ tolerations: [] affinity: {} +# Set it as a non-null string, such as true, if you want to enable logging facility, +# otherwise, keep it as "" to disable it. +LOGFLAG: "" + # text embedding inference service URL, e.g. http://: TEI_EMBEDDING_ENDPOINT: "" diff --git a/helm-charts/common/embedding-usvc/templates/configmap.yaml b/helm-charts/common/embedding-usvc/templates/configmap.yaml index a7566b7b..28da012e 100644 --- a/helm-charts/common/embedding-usvc/templates/configmap.yaml +++ b/helm-charts/common/embedding-usvc/templates/configmap.yaml @@ -23,3 +23,4 @@ data: LANGCHAIN_TRACING_V2: {{ .Values.global.LANGCHAIN_TRACING_V2 | quote }} LANGCHAIN_API_KEY: {{ .Values.global.LANGCHAIN_API_KEY }} LANGCHAIN_PROJECT: "opea-embedding-service" + LOGFLAG: {{ .Values.LOGFLAG | quote }} diff --git a/helm-charts/common/embedding-usvc/values.yaml b/helm-charts/common/embedding-usvc/values.yaml index f12df1af..b57f08e0 100644 --- a/helm-charts/common/embedding-usvc/values.yaml +++ b/helm-charts/common/embedding-usvc/values.yaml @@ -10,6 +10,10 @@ autodependency: replicaCount: 1 +# Set it as a non-null string, such as true, if you want to enable logging facility, +# otherwise, keep it as "" to disable it. +LOGFLAG: "" + TEI_EMBEDDING_ENDPOINT: "" image: repository: opea/embedding-tei diff --git a/helm-charts/common/llm-uservice/templates/configmap.yaml b/helm-charts/common/llm-uservice/templates/configmap.yaml index 4feeb857..8e734b65 100644 --- a/helm-charts/common/llm-uservice/templates/configmap.yaml +++ b/helm-charts/common/llm-uservice/templates/configmap.yaml @@ -28,3 +28,4 @@ data: LANGCHAIN_TRACING_V2: {{ .Values.global.LANGCHAIN_TRACING_V2 | quote }} LANGCHAIN_API_KEY: {{ .Values.global.LANGCHAIN_API_KEY }} LANGCHAIN_PROJECT: "opea-llm-uservice" + LOGFLAG: {{ .Values.LOGFLAG | quote }} diff --git a/helm-charts/common/llm-uservice/values.yaml b/helm-charts/common/llm-uservice/values.yaml index dd55dc93..0b7b2642 100644 --- a/helm-charts/common/llm-uservice/values.yaml +++ b/helm-charts/common/llm-uservice/values.yaml @@ -11,6 +11,10 @@ autodependency: replicaCount: 1 TGI_LLM_ENDPOINT: "" +# Set it as a non-null string, such as true, if you want to enable logging facility, +# otherwise, keep it as "" to disable it. +LOGFLAG: "" + image: repository: opea/llm-tgi pullPolicy: IfNotPresent diff --git a/helm-charts/common/reranking-usvc/templates/configmap.yaml b/helm-charts/common/reranking-usvc/templates/configmap.yaml index c805ba09..d63c53ee 100644 --- a/helm-charts/common/reranking-usvc/templates/configmap.yaml +++ b/helm-charts/common/reranking-usvc/templates/configmap.yaml @@ -23,3 +23,4 @@ data: LANGCHAIN_TRACING_V2: {{ .Values.global.LANGCHAIN_TRACING_V2 | quote }} LANGCHAIN_API_KEY: {{ .Values.global.LANGCHAIN_API_KEY | quote }} LANGCHAIN_PROJECT: "opea-reranking-service" + LOGFLAG: {{ .Values.LOGFLAG | quote }} diff --git a/helm-charts/common/reranking-usvc/values.yaml b/helm-charts/common/reranking-usvc/values.yaml index 7fee759f..3bac2ccc 100644 --- a/helm-charts/common/reranking-usvc/values.yaml +++ b/helm-charts/common/reranking-usvc/values.yaml @@ -10,6 +10,10 @@ autodependency: replicaCount: 1 +# Set it as a non-null string, such as true, if you want to enable logging facility, +# otherwise, keep it as "" to disable it. +LOGFLAG: "" + TEI_RERANKING_ENDPOINT: "" image: repository: opea/reranking-tei diff --git a/helm-charts/common/retriever-usvc/templates/configmap.yaml b/helm-charts/common/retriever-usvc/templates/configmap.yaml index 8b06ab9d..b2be3834 100644 --- a/helm-charts/common/retriever-usvc/templates/configmap.yaml +++ b/helm-charts/common/retriever-usvc/templates/configmap.yaml @@ -33,3 +33,4 @@ data: LANGCHAIN_PROJECT: "opea-retriever-service" HF_HOME: "/tmp/.cache/huggingface" HUGGINGFACEHUB_API_TOKEN: {{ .Values.global.HUGGINGFACEHUB_API_TOKEN | quote}} + LOGFLAG: {{ .Values.LOGFLAG | quote }} diff --git a/helm-charts/common/retriever-usvc/values.yaml b/helm-charts/common/retriever-usvc/values.yaml index 3128287e..fe8f36e0 100644 --- a/helm-charts/common/retriever-usvc/values.yaml +++ b/helm-charts/common/retriever-usvc/values.yaml @@ -10,6 +10,10 @@ autodependency: replicaCount: 1 +# Set it as a non-null string, such as true, if you want to enable logging facility, +# otherwise, keep it as "" to disable it. +LOGFLAG: "" + TEI_EMBEDDING_ENDPOINT: "" EMBED_MODEL: "" diff --git a/helm-charts/common/tts/templates/configmap.yaml b/helm-charts/common/tts/templates/configmap.yaml index 5afcee74..96fd677e 100644 --- a/helm-charts/common/tts/templates/configmap.yaml +++ b/helm-charts/common/tts/templates/configmap.yaml @@ -20,3 +20,4 @@ data: {{- else }} no_proxy: {{ .Values.global.no_proxy | quote }} {{- end }} + LOGFLAG: {{ .Values.LOGFLAG | quote }} diff --git a/helm-charts/common/tts/values.yaml b/helm-charts/common/tts/values.yaml index 6de99219..a37c42a9 100644 --- a/helm-charts/common/tts/values.yaml +++ b/helm-charts/common/tts/values.yaml @@ -10,6 +10,10 @@ autodependency: replicaCount: 1 +# Set it as a non-null string, such as true, if you want to enable logging facility, +# otherwise, keep it as "" to disable it. +LOGFLAG: "" + TTS_ENDPOINT: "" image: diff --git a/helm-charts/common/web-retriever/templates/configmap.yaml b/helm-charts/common/web-retriever/templates/configmap.yaml index 4b2d94d8..a3ac0f9a 100644 --- a/helm-charts/common/web-retriever/templates/configmap.yaml +++ b/helm-charts/common/web-retriever/templates/configmap.yaml @@ -24,3 +24,4 @@ data: no_proxy: {{ .Values.global.no_proxy | quote }} {{- end }} HF_HOME: "/tmp/.cache/huggingface" + LOGFLAG: {{ .Values.LOGFLAG | quote }} diff --git a/helm-charts/common/web-retriever/values.yaml b/helm-charts/common/web-retriever/values.yaml index 99d4272a..5311b316 100644 --- a/helm-charts/common/web-retriever/values.yaml +++ b/helm-charts/common/web-retriever/values.yaml @@ -10,6 +10,10 @@ autodependency: replicaCount: 1 +# Set it as a non-null string, such as true, if you want to enable logging facility, +# otherwise, keep it as "" to disable it. +LOGFLAG: "" + TEI_EMBEDDING_ENDPOINT: "" GOOGLE_API_KEY: "" GOOGLE_CSE_ID: "" diff --git a/microservices-connector/config/manifests/asr.yaml b/microservices-connector/config/manifests/asr.yaml index 606c8d95..5c9d45c3 100644 --- a/microservices-connector/config/manifests/asr.yaml +++ b/microservices-connector/config/manifests/asr.yaml @@ -18,6 +18,7 @@ data: http_proxy: "" https_proxy: "" no_proxy: "" + LOGFLAG: "" --- # Source: asr/templates/service.yaml # Copyright (C) 2024 Intel Corporation diff --git a/microservices-connector/config/manifests/data-prep.yaml b/microservices-connector/config/manifests/data-prep.yaml index ea3da484..a958941c 100644 --- a/microservices-connector/config/manifests/data-prep.yaml +++ b/microservices-connector/config/manifests/data-prep.yaml @@ -28,6 +28,7 @@ data: LANGCHAIN_TRACING_V2: "false" LANGCHAIN_API_KEY: "insert-your-langchain-key-here" LANGCHAIN_PROJECT: "opea-dataprep-service" + LOGFLAG: "" --- # Source: data-prep/templates/service.yaml # Copyright (C) 2024 Intel Corporation diff --git a/microservices-connector/config/manifests/docsum-llm-uservice.yaml b/microservices-connector/config/manifests/docsum-llm-uservice.yaml index e69d8a06..2f0adc1f 100644 --- a/microservices-connector/config/manifests/docsum-llm-uservice.yaml +++ b/microservices-connector/config/manifests/docsum-llm-uservice.yaml @@ -23,6 +23,7 @@ data: LANGCHAIN_TRACING_V2: "false" LANGCHAIN_API_KEY: insert-your-langchain-key-here LANGCHAIN_PROJECT: "opea-llm-uservice" + LOGFLAG: "" --- # Source: llm-uservice/templates/service.yaml # Copyright (C) 2024 Intel Corporation diff --git a/microservices-connector/config/manifests/embedding-usvc.yaml b/microservices-connector/config/manifests/embedding-usvc.yaml index f0cf5c97..45e9b2e8 100644 --- a/microservices-connector/config/manifests/embedding-usvc.yaml +++ b/microservices-connector/config/manifests/embedding-usvc.yaml @@ -21,6 +21,7 @@ data: LANGCHAIN_TRACING_V2: "false" LANGCHAIN_API_KEY: insert-your-langchain-key-here LANGCHAIN_PROJECT: "opea-embedding-service" + LOGFLAG: "" --- # Source: embedding-usvc/templates/service.yaml # Copyright (C) 2024 Intel Corporation diff --git a/microservices-connector/config/manifests/llm-uservice.yaml b/microservices-connector/config/manifests/llm-uservice.yaml index 905185b4..a65b03dd 100644 --- a/microservices-connector/config/manifests/llm-uservice.yaml +++ b/microservices-connector/config/manifests/llm-uservice.yaml @@ -23,6 +23,7 @@ data: LANGCHAIN_TRACING_V2: "false" LANGCHAIN_API_KEY: insert-your-langchain-key-here LANGCHAIN_PROJECT: "opea-llm-uservice" + LOGFLAG: "" --- # Source: llm-uservice/templates/service.yaml # Copyright (C) 2024 Intel Corporation diff --git a/microservices-connector/config/manifests/reranking-usvc.yaml b/microservices-connector/config/manifests/reranking-usvc.yaml index 0ffc1bb8..954a8c19 100644 --- a/microservices-connector/config/manifests/reranking-usvc.yaml +++ b/microservices-connector/config/manifests/reranking-usvc.yaml @@ -21,6 +21,7 @@ data: LANGCHAIN_TRACING_V2: "false" LANGCHAIN_API_KEY: "insert-your-langchain-key-here" LANGCHAIN_PROJECT: "opea-reranking-service" + LOGFLAG: "" --- # Source: reranking-usvc/templates/service.yaml # Copyright (C) 2024 Intel Corporation diff --git a/microservices-connector/config/manifests/retriever-usvc.yaml b/microservices-connector/config/manifests/retriever-usvc.yaml index 91e18c8e..79824a96 100644 --- a/microservices-connector/config/manifests/retriever-usvc.yaml +++ b/microservices-connector/config/manifests/retriever-usvc.yaml @@ -27,6 +27,7 @@ data: LANGCHAIN_PROJECT: "opea-retriever-service" HF_HOME: "/tmp/.cache/huggingface" HUGGINGFACEHUB_API_TOKEN: "insert-your-huggingface-token-here" + LOGFLAG: "" --- # Source: retriever-usvc/templates/service.yaml # Copyright (C) 2024 Intel Corporation diff --git a/microservices-connector/config/manifests/tts.yaml b/microservices-connector/config/manifests/tts.yaml index afba1c38..6e09d977 100644 --- a/microservices-connector/config/manifests/tts.yaml +++ b/microservices-connector/config/manifests/tts.yaml @@ -18,6 +18,7 @@ data: http_proxy: "" https_proxy: "" no_proxy: "" + LOGFLAG: "" --- # Source: tts/templates/service.yaml # Copyright (C) 2024 Intel Corporation diff --git a/microservices-connector/config/manifests/web-retriever.yaml b/microservices-connector/config/manifests/web-retriever.yaml index 14000831..5a4b8b9d 100644 --- a/microservices-connector/config/manifests/web-retriever.yaml +++ b/microservices-connector/config/manifests/web-retriever.yaml @@ -22,6 +22,7 @@ data: https_proxy: "" no_proxy: "" HF_HOME: "/tmp/.cache/huggingface" + LOGFLAG: "" --- # Source: web-retriever/templates/service.yaml # Copyright (C) 2024 Intel Corporation