Refactor DocSum example (#1286)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
Sihan Chen
2024-12-26 14:45:17 +08:00
committed by GitHub
parent 6b6a08df78
commit a01729a5c2
16 changed files with 145 additions and 1143 deletions

View File

@@ -135,67 +135,6 @@ data:
HUGGINGFACEHUB_API_TOKEN: "insert-your-huggingface-token-here"
HF_HOME: "/tmp/.cache/huggingface"
---
# Source: docsum/charts/tgi/templates/configmap.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: ConfigMap
metadata:
name: docsum-audio2text-config
labels:
helm.sh/chart: audio2text-1.0.0
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
data:
http_proxy: ""
https_proxy: ""
no_proxy: ""
A2T_ENDPOINT: "http://docsum-whisper"
---
# Source: docsum/charts/tgi/templates/configmap.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: ConfigMap
metadata:
name: docsum-video2audio-config
labels:
helm.sh/chart: video2audio-1.0.0
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
data:
http_proxy: ""
https_proxy: ""
no_proxy: ""
V2A_ENDPOINT: "http://docsum-video2audio"
---
# Source: docsum/charts/tgi/templates/configmap.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: ConfigMap
metadata:
name: docsum-multimedia2text-config
labels:
helm.sh/chart: multimedia2text-1.0.0
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
data:
http_proxy: ""
https_proxy: ""
no_proxy: ""
V2A_ENDPOINT: "http://docsum-video2audio"
A2T_ENDPOINT: "http://docsum-whisper"
---
# Source: docsum/charts/tgi/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
@@ -221,81 +160,6 @@ spec:
app.kubernetes.io/name: whisper
app.kubernetes.io/instance: docsum
---
# Source: docsum/charts/tgi/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: Service
metadata:
name: docsum-audio2text
labels:
helm.sh/chart: audio2text-1.0.0
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
spec:
type: ClusterIP
ports:
- port: 9099
targetPort: 9199
protocol: TCP
name: audio2text
selector:
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
---
# Source: docsum/charts/tgi/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: Service
metadata:
name: docsum-video2audio
labels:
helm.sh/chart: video2audio-1.0.0
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
spec:
type: ClusterIP
ports:
- port: 7078
targetPort: 7078
protocol: TCP
name: video2audio
selector:
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
---
# Source: docsum/charts/tgi/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: Service
metadata:
name: docsum-multimedia2text
labels:
helm.sh/chart: multimedia2text-1.0.0
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
spec:
type: ClusterIP
ports:
- port: 7079
targetPort: 7079
protocol: TCP
name: multimedia2text
selector:
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
---
# Source: docsum/charts/docsum-ui/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
@@ -801,214 +665,3 @@ spec:
volumes:
- name: tmp
emptyDir: {}
---
# Source: docsum/charts/audio2text/templates/deployment.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: apps/v1
kind: Deployment
metadata:
name: docsum-audio2text
labels:
helm.sh/chart: audio2text-1.0.0
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "v1.0"
app.kubernetes.io/managed-by: Helm
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
template:
metadata:
labels:
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
spec:
securityContext:
{}
containers:
- name: docsum
envFrom:
- configMapRef:
name: docsum-audio2text-config
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: false
runAsNonRoot: true
runAsUser: 1000
seccompProfile:
type: RuntimeDefault
image: "opea/dataprep-audio2text:latest"
imagePullPolicy: IfNotPresent
ports:
- name: audio2text
containerPort: 9199
protocol: TCP
volumeMounts:
- mountPath: /tmp
name: tmp
resources:
{}
volumes:
- name: tmp
emptyDir: {}
---
# Source: docsum/charts/video2audio/templates/deployment.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: apps/v1
kind: Deployment
metadata:
name: docsum-video2audio
labels:
helm.sh/chart: video2audio-1.0.0
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "v1.0"
app.kubernetes.io/managed-by: Helm
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
template:
metadata:
labels:
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
spec:
securityContext:
{}
containers:
- name: docsum
envFrom:
- configMapRef:
name: docsum-video2audio-config
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: false
runAsNonRoot: true
runAsUser: 1000
seccompProfile:
type: RuntimeDefault
image: "opea/dataprep-video2audio:latest"
imagePullPolicy: IfNotPresent
ports:
- name: video2audio
containerPort: 7078
protocol: TCP
volumeMounts:
- mountPath: /tmp
name: tmp
livenessProbe:
failureThreshold: 24
httpGet:
path: v1/health_check
port: video2audio
initialDelaySeconds: 5
periodSeconds: 5
readinessProbe:
httpGet:
path: v1/health_check
port: video2audio
initialDelaySeconds: 5
periodSeconds: 5
startupProbe:
failureThreshold: 120
httpGet:
path: v1/health_check
port: video2audio
initialDelaySeconds: 5
periodSeconds: 5
resources:
{}
volumes:
- name: tmp
emptyDir: {}
---
# Source: docsum/charts/multimedia2text/templates/deployment.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: apps/v1
kind: Deployment
metadata:
name: docsum-multimedia2text
labels:
helm.sh/chart: multimedia2text-1.0.0
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "v1.0"
app.kubernetes.io/managed-by: Helm
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
template:
metadata:
labels:
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
spec:
securityContext:
{}
containers:
- name: docsum
envFrom:
- configMapRef:
name: docsum-multimedia2text-config
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: false
runAsNonRoot: true
runAsUser: 1000
seccompProfile:
type: RuntimeDefault
image: "opea/dataprep-multimedia2text:latest"
imagePullPolicy: IfNotPresent
ports:
- name: multimedia2text
containerPort: 7079
protocol: TCP
volumeMounts:
- mountPath: /tmp
name: tmp
livenessProbe:
failureThreshold: 24
httpGet:
path: v1/health_check
port: multimedia2text
initialDelaySeconds: 5
periodSeconds: 5
readinessProbe:
httpGet:
path: v1/health_check
port: multimedia2text
initialDelaySeconds: 5
periodSeconds: 5
startupProbe:
failureThreshold: 120
httpGet:
path: v1/health_check
port: multimedia2text
initialDelaySeconds: 5
periodSeconds: 5
resources:
{}
volumes:
- name: tmp
emptyDir: {}

View File

@@ -136,66 +136,30 @@ data:
HUGGINGFACEHUB_API_TOKEN: "insert-your-huggingface-token-here"
HF_HOME: "/tmp/.cache/huggingface"
---
# Source: docsum/charts/tgi/templates/configmap.yaml
# Source: docsum/charts/tgi/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: ConfigMap
kind: Service
metadata:
name: docsum-audio2text-config
name: docsum-whisper
labels:
helm.sh/chart: audio2text-1.0.0
app.kubernetes.io/name: audio2text
helm.sh/chart: whisper-1.0.0
app.kubernetes.io/name: whisper
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
data:
http_proxy: ""
https_proxy: ""
no_proxy: ""
A2T_ENDPOINT: "http://docsum-whisper"
---
# Source: docsum/charts/tgi/templates/configmap.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: ConfigMap
metadata:
name: docsum-video2audio-config
labels:
helm.sh/chart: video2audio-1.0.0
app.kubernetes.io/name: video2audio
spec:
type: ClusterIP
ports:
- port: 7066
targetPort: 7066
protocol: TCP
name: whisper
selector:
app.kubernetes.io/name: whisper
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
data:
http_proxy: ""
https_proxy: ""
no_proxy: ""
V2A_ENDPOINT: "http://docsum-video2audio"
---
# Source: docsum/charts/tgi/templates/configmap.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: ConfigMap
metadata:
name: docsum-multimedia2text-config
labels:
helm.sh/chart: multimedia2text-1.0.0
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
data:
http_proxy: ""
https_proxy: ""
no_proxy: ""
V2A_ENDPOINT: "http://docsum-video2audio"
A2T_ENDPOINT: "http://docsum-whisper"
---
# Source: docsum/charts/docsum-ui/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
@@ -288,106 +252,6 @@ spec:
app: docsum-nginx
type: NodePort
---
# Source: docsum/charts/tgi/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: Service
metadata:
name: docsum-whisper
labels:
helm.sh/chart: whisper-1.0.0
app.kubernetes.io/name: whisper
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
spec:
type: ClusterIP
ports:
- port: 7066
targetPort: 7066
protocol: TCP
name: whisper
selector:
app.kubernetes.io/name: whisper
app.kubernetes.io/instance: docsum
---
# Source: docsum/charts/tgi/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: Service
metadata:
name: docsum-audio2text
labels:
helm.sh/chart: audio2text-1.0.0
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
spec:
type: ClusterIP
ports:
- port: 9099
targetPort: 9199
protocol: TCP
name: audio2text
selector:
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
---
# Source: docsum/charts/tgi/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: Service
metadata:
name: docsum-video2audio
labels:
helm.sh/chart: video2audio-1.0.0
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
spec:
type: ClusterIP
ports:
- port: 7078
targetPort: 7078
protocol: TCP
name: video2audio
selector:
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
---
# Source: docsum/charts/tgi/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: v1
kind: Service
metadata:
name: docsum-multimedia2text
labels:
helm.sh/chart: multimedia2text-1.0.0
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "2.1.0"
app.kubernetes.io/managed-by: Helm
spec:
type: ClusterIP
ports:
- port: 7079
targetPort: 7079
protocol: TCP
name: multimedia2text
selector:
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
---
# Source: docsum/templates/service.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
@@ -805,214 +669,3 @@ spec:
volumes:
- name: tmp
emptyDir: {}
---
# Source: docsum/charts/audio2text/templates/deployment.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: apps/v1
kind: Deployment
metadata:
name: docsum-audio2text
labels:
helm.sh/chart: audio2text-1.0.0
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "v1.0"
app.kubernetes.io/managed-by: Helm
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
template:
metadata:
labels:
app.kubernetes.io/name: audio2text
app.kubernetes.io/instance: docsum
spec:
securityContext:
{}
containers:
- name: docsum
envFrom:
- configMapRef:
name: docsum-audio2text-config
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: false
runAsNonRoot: true
runAsUser: 1000
seccompProfile:
type: RuntimeDefault
image: "opea/dataprep-audio2text:latest"
imagePullPolicy: IfNotPresent
ports:
- name: audio2text
containerPort: 9199
protocol: TCP
volumeMounts:
- mountPath: /tmp
name: tmp
resources:
{}
volumes:
- name: tmp
emptyDir: {}
---
# Source: docsum/charts/video2audio/templates/deployment.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: apps/v1
kind: Deployment
metadata:
name: docsum-video2audio
labels:
helm.sh/chart: video2audio-1.0.0
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "v1.0"
app.kubernetes.io/managed-by: Helm
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
template:
metadata:
labels:
app.kubernetes.io/name: video2audio
app.kubernetes.io/instance: docsum
spec:
securityContext:
{}
containers:
- name: docsum
envFrom:
- configMapRef:
name: docsum-video2audio-config
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: false
runAsNonRoot: true
runAsUser: 1000
seccompProfile:
type: RuntimeDefault
image: "opea/dataprep-video2audio:latest"
imagePullPolicy: IfNotPresent
ports:
- name: video2audio
containerPort: 7078
protocol: TCP
volumeMounts:
- mountPath: /tmp
name: tmp
livenessProbe:
failureThreshold: 24
httpGet:
path: v1/health_check
port: video2audio
initialDelaySeconds: 5
periodSeconds: 5
readinessProbe:
httpGet:
path: v1/health_check
port: video2audio
initialDelaySeconds: 5
periodSeconds: 5
startupProbe:
failureThreshold: 120
httpGet:
path: v1/health_check
port: video2audio
initialDelaySeconds: 5
periodSeconds: 5
resources:
{}
volumes:
- name: tmp
emptyDir: {}
---
# Source: docsum/charts/multimedia2text/templates/deployment.yaml
# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
apiVersion: apps/v1
kind: Deployment
metadata:
name: docsum-multimedia2text
labels:
helm.sh/chart: multimedia2text-1.0.0
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
app.kubernetes.io/version: "v1.0"
app.kubernetes.io/managed-by: Helm
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
template:
metadata:
labels:
app.kubernetes.io/name: multimedia2text
app.kubernetes.io/instance: docsum
spec:
securityContext:
{}
containers:
- name: docsum
envFrom:
- configMapRef:
name: docsum-multimedia2text-config
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: false
runAsNonRoot: true
runAsUser: 1000
seccompProfile:
type: RuntimeDefault
image: "opea/dataprep-multimedia2text:latest"
imagePullPolicy: IfNotPresent
ports:
- name: multimedia2text
containerPort: 7079
protocol: TCP
volumeMounts:
- mountPath: /tmp
name: tmp
livenessProbe:
failureThreshold: 24
httpGet:
path: v1/health_check
port: multimedia2text
initialDelaySeconds: 5
periodSeconds: 5
readinessProbe:
httpGet:
path: v1/health_check
port: multimedia2text
initialDelaySeconds: 5
periodSeconds: 5
startupProbe:
failureThreshold: 120
httpGet:
path: v1/health_check
port: multimedia2text
initialDelaySeconds: 5
periodSeconds: 5
resources:
{}
volumes:
- name: tmp
emptyDir: {}