From 6e0d9c74772710459c99164e038c9dcbb5f4171c Mon Sep 17 00:00:00 2001 From: Vaibhav Malik <34866732+VaibhavMalik4187@users.noreply.github.com> Date: Mon, 15 Apr 2024 18:14:31 +0530 Subject: [PATCH] [feature]: add gemini to supported AI backends (#406) This commit adds `google` to the list of supported AI backends. Fixes: https://github.com/k8sgpt-ai/k8sgpt-operator/issues/347 Signed-off-by: VaibhavMalik4187 --- api/v1alpha1/k8sgpt_types.go | 4 +++- chart/operator/templates/k8sgpt-crd.yaml | 4 +++- config/crd/bases/core.k8sgpt.ai_k8sgpts.yaml | 2 ++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/api/v1alpha1/k8sgpt_types.go b/api/v1alpha1/k8sgpt_types.go index ef0021bb..3fc6bd8c 100644 --- a/api/v1alpha1/k8sgpt_types.go +++ b/api/v1alpha1/k8sgpt_types.go @@ -82,7 +82,7 @@ type BackOff struct { type AISpec struct { // +kubebuilder:default:=openai - // +kubebuilder:validation:Enum=openai;localai;azureopenai;amazonbedrock;cohere;amazonsagemaker + // +kubebuilder:validation:Enum=openai;localai;azureopenai;amazonbedrock;cohere;amazonsagemaker;google;googlevertexai Backend string `json:"backend"` BackOff *BackOff `json:"backOff,omitempty"` BaseUrl string `json:"baseUrl,omitempty"` @@ -138,6 +138,8 @@ const ( AmazonBedrock = "amazonbedrock" AmazonSageMaker = "AmazonSageMaker" Cohere = "cohere" + Google = "google" + GoogleVertexAI = "googlevertexai" ) // K8sGPTStatus defines the observed state of K8sGPT diff --git a/chart/operator/templates/k8sgpt-crd.yaml b/chart/operator/templates/k8sgpt-crd.yaml index 5258b61c..7c811493 100644 --- a/chart/operator/templates/k8sgpt-crd.yaml +++ b/chart/operator/templates/k8sgpt-crd.yaml @@ -62,6 +62,8 @@ spec: - amazonbedrock - cohere - amazonsagemaker + - google + - googlevertexai type: string baseUrl: type: string @@ -209,4 +211,4 @@ status: kind: "" plural: "" conditions: [] - storedVersions: [] \ No newline at end of file + storedVersions: [] diff --git a/config/crd/bases/core.k8sgpt.ai_k8sgpts.yaml b/config/crd/bases/core.k8sgpt.ai_k8sgpts.yaml index cf6310c6..755bd390 100644 --- a/config/crd/bases/core.k8sgpt.ai_k8sgpts.yaml +++ b/config/crd/bases/core.k8sgpt.ai_k8sgpts.yaml @@ -61,6 +61,8 @@ spec: - amazonbedrock - cohere - amazonsagemaker + - google + - googlevertexai type: string baseUrl: type: string