From 5d80f3479ac7354bae759184270a360c49916df1 Mon Sep 17 00:00:00 2001 From: DeepFlow-pengbin <84362246+1473371932@users.noreply.github.com> Date: Sat, 8 Feb 2025 18:38:30 +0800 Subject: [PATCH] Update 09-ai-agent.md MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 将详细的 AI 组件配置放入官网文档,默认部署时并不启用该功能,如需使用时,直接将配置粘贴至 value 文件即可 --- docs/zh/02-ce-install/09-ai-agent.md | 111 ++++++++++++++++++++++++++- 1 file changed, 110 insertions(+), 1 deletion(-) diff --git a/docs/zh/02-ce-install/09-ai-agent.md b/docs/zh/02-ce-install/09-ai-agent.md index aa208821..cfb04c3a 100644 --- a/docs/zh/02-ce-install/09-ai-agent.md +++ b/docs/zh/02-ce-install/09-ai-agent.md @@ -5,7 +5,116 @@ permalink: /ce-install/ai-agent # 前提条件 -已经在 K8s 中部署了社区版 DeepFlow。 +DeepFlow 部署时,默认不会启用 AI 组件,需手动在 `values-custom.yaml` 文件中添加 AI 组件配置: + +```yaml +stella-agent-ce: + enabled: true + replicas: 1 + hostNetwork: "false" + dnsPolicy: ClusterFirst + imagePullSecrets: [] + nameOverride: "" + fullnameOverride: "" + podAnnotations: {} + + image: + repository: "{{ .Values.global.image.repository }}/deepflowio-stella-agent-ce" + pullPolicy: Always + # Overrides the image tag whose default is the chart appVersion. + tag: latest + + podSecurityContext: {} + # fsGroup: 2000 + + securityContext: + # privileged: true + # capabilities: + # drop: + # - ALL + # readOnlyRootFilesystem: false + # runAsNonRoot: false + # runAsUser: 0 + + service: + ## Configuration for ClickHouse service + annotations: {} + labels: {} + clusterIP: "" + + ## Port for ClickHouse Service to listen on + ports: + - name: tcp + port: 20831 + targetPort: 20831 + nodePort: + protocol: TCP + # Additional ports to open for server service + additionalPorts: [] + externalIPs: [] + loadBalancerIP: "" + loadBalancerSourceRanges: [] + + ## Denotes if this Service desires to route external traffic to node-local or cluster-wide endpoints + externalTrafficPolicy: Cluster + type: ClusterIP + + readinessProbe: + httpGet: + path: /v1/health/ + port: http + failureThreshold: 10 + initialDelaySeconds: 15 + periodSeconds: 10 + successThreshold: 1 + livenessProbe: + failureThreshold: 6 + initialDelaySeconds: 15 + periodSeconds: 20 + successThreshold: 1 + httpGet: + path: /v1/health/ + port: http + timeoutSeconds: 1 + + configmap: + df-llm-agent.yaml: + daemon: true + api_timeout: 500 + sql_show: "false" + log_file: "/var/log/df-llm-agent.log" + log_level: "info" + instance_path: "/root/df-llm-agent" + mysql: + host: "{{ if $.Values.global.externalMySQL.enabled }}{{$.Values.global.externalMySQL.ip}}{{ else }}{{ $.Release.Name }}-mysql{{end}}" + port: "{{ if $.Values.global.externalMySQL.enabled }}{{$.Values.global.externalMySQL.port}}{{ else }}30130{{end}}" + user_name: "{{ if $.Values.global.externalMySQL.enabled }}{{$.Values.global.externalMySQL.username}}{{ else }}root{{end}}" + user_password: "{{ if $.Values.global.externalMySQL.enabled }}{{$.Values.global.externalMySQL.password}}{{ else }}{{ .Values.global.password.mysql }}{{end}}" + database: "deepflow_llm" + + resources: {} + # limits: + # cpu: 100m + # memory: 128Mi + # requests: + # cpu: 100m + # memory: 128Mi + + nodeSelector: {} + + tolerations: [] + + podAntiAffinityLabelSelector: [] + podAntiAffinityTermLabelSelector: [] + podAffinityLabelSelector: [] + podAffinityTermLabelSelector: [] + nodeAffinityLabelSelector: [] + # - matchExpressions: + # - key: kubernetes.io/hostname + # operator: In + # values: controller + nodeAffinityTermLabelSelector: [] +``` # 配置会话模型