Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

helm: fix tei/tgi/docsum #289

Merged
merged 3 commits into from
Aug 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 4 additions & 5 deletions helm-charts/chatqna/gaudi-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ tei:
resources:
limits:
habana.ai/gaudi: 1
securityContext:
readOnlyRootFilesystem: false
Comment on lines +11 to +12
Copy link
Contributor

@eero-t eero-t Aug 28, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

IMHO Instead of allowing rootfs writes, this should have been fixed by adding separate volume for writes.


# To override values in subchart tgi
tgi:
Expand All @@ -17,8 +19,5 @@ tgi:
resources:
limits:
habana.ai/gaudi: 1
extraArgs:
- "--max-input-length"
- "1024"
- "--max-total-tokens"
- "2048"
MAX_INPUT_LENGTH: "1024"
MAX_TOTAL_TOKENS: "2048"
7 changes: 2 additions & 5 deletions helm-charts/codegen/gaudi-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,5 @@ tgi:
resources:
limits:
habana.ai/gaudi: 1
extraArgs:
- "--max-input-length"
- "1024"
- "--max-total-tokens"
- "2048"
MAX_INPUT_LENGTH: "1024"
MAX_TOTAL_TOKENS: "2048"
7 changes: 2 additions & 5 deletions helm-charts/codetrans/gaudi-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,5 @@ tgi:
resources:
limits:
habana.ai/gaudi: 1
extraArgs:
- "--max-input-length"
- "1024"
- "--max-total-tokens"
- "2048"
MAX_INPUT_LENGTH: "1024"
MAX_TOTAL_TOKENS: "2048"
3 changes: 3 additions & 0 deletions helm-charts/common/tei/gaudi-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@ image:
repository: ghcr.io/huggingface/tei-gaudi
tag: synapse_1.16

securityContext:
readOnlyRootFilesystem: false

resources:
limits:
habana.ai/gaudi: 1
7 changes: 2 additions & 5 deletions helm-charts/common/tgi/gaudi-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,8 @@ image:
repository: ghcr.io/huggingface/tgi-gaudi
tag: "2.0.1"

extraArgs:
- "--max-input-length"
- "1024"
- "--max-total-tokens"
- "2048"
MAX_INPUT_LENGTH: "1024"
MAX_TOTAL_TOKENS: "2048"

resources:
limits:
Expand Down
6 changes: 6 additions & 0 deletions helm-charts/common/tgi/templates/configmap.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,9 @@ data:
NUMBA_CACHE_DIR: "/tmp"
TRANSFORMERS_CACHE: "/tmp/transformers_cache"
HF_HOME: "/tmp/.cache/huggingface"
{{- if .Values.MAX_INPUT_LENGTH }}
MAX_INPUT_LENGTH: {{ .Values.MAX_INPUT_LENGTH | quote }}
{{- end }}
{{- if .Values.MAX_TOTAL_TOKENS }}
MAX_TOTAL_TOKENS: {{ .Values.MAX_TOTAL_TOKENS | quote }}
{{- end }}
4 changes: 0 additions & 4 deletions helm-charts/common/tgi/templates/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,6 @@ spec:
{{- end }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
{{- if .Values.extraArgs }}
args:
{{- toYaml .Values.extraArgs | nindent 12}}
{{- end }}
volumeMounts:
- mountPath: /data
name: model-volume
Expand Down
3 changes: 3 additions & 0 deletions helm-charts/common/tgi/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,9 @@ affinity: {}

LLM_MODEL_ID: Intel/neural-chat-7b-v3-3

MAX_INPUT_LENGTH: ""
MAX_TOTAL_TOKENS: ""

global:
http_proxy: ""
https_proxy: ""
Expand Down
7 changes: 2 additions & 5 deletions helm-charts/docsum/gaudi-values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,5 @@ tgi:
resources:
limits:
habana.ai/gaudi: 1
extraArgs:
- "--max-input-length"
- "1024"
- "--max-total-tokens"
- "2048"
MAX_INPUT_LENGTH: "1024"
MAX_TOTAL_TOKENS: "2048"
5 changes: 5 additions & 0 deletions helm-charts/docsum/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ tolerations: []

affinity: {}

# To override values in subchart llm-uservice
llm-uservice:
image:
repository: opea/llm-docsum-tgi

# To override values in subchart tgi
tgi:
LLM_MODEL_ID: Intel/neural-chat-7b-v3-3
Expand Down
7 changes: 2 additions & 5 deletions microservices-connector/config/manifests/tgi_gaudi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,8 @@ data:
NUMBA_CACHE_DIR: "/tmp"
TRANSFORMERS_CACHE: "/tmp/transformers_cache"
HF_HOME: "/tmp/.cache/huggingface"
MAX_INPUT_LENGTH: "1024"
MAX_TOTAL_TOKENS: "2048"
---
# Source: tgi/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
Expand Down Expand Up @@ -90,11 +92,6 @@ spec:
{}
image: "ghcr.io/huggingface/tgi-gaudi:2.0.1"
imagePullPolicy: IfNotPresent
args:
- --max-input-length
- "1024"
- --max-total-tokens
- "2048"
volumeMounts:
- mountPath: /data
name: model-volume
Expand Down
Loading