v1alpha1

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 29, 2023 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the arcadia v1alpha1 API group +kubebuilder:object:generate=true +groupName=arcadia.kubeagi.k8s.com.cn

Index

Constants

View Source
const (
	InputNode  = "Input"
	OutputNode = "Output"
)
View Source
const (
	ObjectTypeTag  = "object_type"
	ObjectCountTag = "object_count"
	ObjectTypeQA   = "QA"
)

Tags for file object

View Source
const (
	Group   = "arcadia.kubeagi.k8s.com.cn"
	Version = "v1alpha1"
)
View Source
const (
	// LabelModelEmbedding indicates this is a embedding model
	LabelModelEmbedding = Group + "/embedding"
	// LabelModelLLM indicates this is a llm model
	LabelModelLLM      = Group + "/llm"
	LabelModelFullPath = Group + "/full-path"
)
View Source
const (
	LabelWorkerType = Group + "/worker-type"

	// Labels for worker's Pod
	WorkerPodSelectorLabel = "app.kubernetes.io/name"
	WorkerPodLabel         = Group + "/worker"
)
View Source
const (
	// Finalizer is the key of the finalizer
	Finalizer = Group + "/finalizer"
)
View Source
const InheritedFromVersionName = "inheritfrom-"
View Source
const (
	LabelDatasourceType = Group + "/datasource-type"
)
View Source
const (
	LabelVectorStoreType = Group + "/vectorstore-type"
)

Variables

View Source
var (
	// LabelDatasetScene defines the content type of this dataset
	LabelDatasetContentType = Group + "/content-type"
	// LabelDatasetField defines the best field to use this dataset
	LabelDatasetField     = Group + "/field"
	LabelDatasetFinalizer = Group + "/finalizers"
)
View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: Group, Version: Version}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)
View Source
var (
	LabelVersionedDatasetVersion      = Group + "/version"
	LabelVersionedDatasetVersionOwner = Group + "/owner"
)

Functions

This section is empty.

Types

type Application

type Application struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   ApplicationSpec   `json:"spec,omitempty"`
	Status ApplicationStatus `json:"status,omitempty"`
}

Application is the Schema for the applications API

func (*Application) DeepCopy

func (in *Application) DeepCopy() *Application

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Application.

func (*Application) DeepCopyInto

func (in *Application) DeepCopyInto(out *Application)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Application) DeepCopyObject

func (in *Application) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApplicationList

type ApplicationList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Application `json:"items"`
}

ApplicationList contains a list of Application

func (*ApplicationList) DeepCopy

func (in *ApplicationList) DeepCopy() *ApplicationList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationList.

func (*ApplicationList) DeepCopyInto

func (in *ApplicationList) DeepCopyInto(out *ApplicationList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ApplicationList) DeepCopyObject

func (in *ApplicationList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ApplicationSpec

type ApplicationSpec struct {
	CommonSpec `json:",inline"`
	// Icon base64 image icon
	Icon string `json:"icon,omitempty"`
	// IsPublic Set whether the current application provides services to the public
	IsPublic bool `json:"isPublic,omitempty"`
	// prologue, show in the chat top
	Prologue string `json:"prologue,omitempty"`
	// Nodes
	// +kubebuilder:validation:Required
	Nodes []Node `json:"nodes"`
}

ApplicationSpec defines the desired state of Application

func (*ApplicationSpec) DeepCopy

func (in *ApplicationSpec) DeepCopy() *ApplicationSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationSpec.

func (*ApplicationSpec) DeepCopyInto

func (in *ApplicationSpec) DeepCopyInto(out *ApplicationSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ApplicationStatus

type ApplicationStatus struct {
	// ObservedGeneration is the last observed generation.
	// +optional
	ObservedGeneration int64 `json:"observedGeneration,omitempty"`

	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`
}

ApplicationStatus defines the observed state of Application

func (*ApplicationStatus) DeepCopy

func (in *ApplicationStatus) DeepCopy() *ApplicationStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ApplicationStatus.

func (*ApplicationStatus) DeepCopyInto

func (in *ApplicationStatus) DeepCopyInto(out *ApplicationStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Chroma

type Chroma struct {
	DistanceFunction chromago.DistanceFunction `json:"distanceFunction,omitempty"`
}

Chroma defines the configuration of Chroma

func (*Chroma) DeepCopy

func (in *Chroma) DeepCopy() *Chroma

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Chroma.

func (*Chroma) DeepCopyInto

func (in *Chroma) DeepCopyInto(out *Chroma)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type CommonSpec

type CommonSpec struct {
	// Creator defines datasource creator (AUTO-FILLED by webhook)
	Creator string `json:"creator,omitempty"`

	// DisplayName defines datasource display name
	DisplayName string `json:"displayName,omitempty"`

	// Description defines datasource description
	Description string `json:"description,omitempty"`
}

func (*CommonSpec) DeepCopy

func (in *CommonSpec) DeepCopy() *CommonSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CommonSpec.

func (*CommonSpec) DeepCopyInto

func (in *CommonSpec) DeepCopyInto(out *CommonSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Condition

type Condition struct {
	// Type of this condition. At most one of each condition type may apply to
	// a resource at any point in time.
	Type ConditionType `json:"type"`

	// Status of this condition; is it currently True, False, or Unknown
	Status corev1.ConditionStatus `json:"status"`

	// LastTransitionTime is the last time this condition transitioned from one
	// status to another.
	LastTransitionTime metav1.Time `json:"lastTransitionTime"`

	// LastSuccessfulTime is repository Last Successful Update Time
	LastSuccessfulTime metav1.Time `json:"lastSuccessfulTime,omitempty"`

	// A Reason for this condition's last transition from one status to another.
	Reason ConditionReason `json:"reason"`

	// A Message containing details about this condition's last transition from
	// one status to another, if any.
	// +optional
	Message string `json:"message,omitempty"`
}

A Condition that may apply to a resource.

func (*Condition) DeepCopy

func (in *Condition) DeepCopy() *Condition

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Condition.

func (*Condition) DeepCopyInto

func (in *Condition) DeepCopyInto(out *Condition)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (Condition) Equal

func (c Condition) Equal(other Condition) bool

Equal returns true if the condition is identical to the supplied condition

func (Condition) WithMessage

func (c Condition) WithMessage(msg string) Condition

WithMessage returns a condition by adding the provided message to existing condition.

type ConditionReason

type ConditionReason string

A ConditionReason represents the reason a resource is in a condition. Should be only one word

const (
	ReasonAvailable        ConditionReason = "Available"
	ReasonUnavailable      ConditionReason = "Unavailable"
	ReasonReconcileSuccess ConditionReason = "ReconcileSuccess"
	ReasonReconcileError   ConditionReason = "ReconcileError"
	ReasonReconcilePaused  ConditionReason = "ReconcilePaused"

	ReasonFileSyncing     ConditionReason = "FileSyncing"
	ReasonFileSyncFailed  ConditionReason = "FileSyncFailed"
	ReasonFileSuncSuccess ConditionReason = "FileSyncSuccess"
)

Some common Condition reasons.

const (
	// Load data
	ReasonDataLoading     ConditionReason = "DataLoading"
	ReasonDataLoadError   ConditionReason = "DataLoadError"
	ReasonDataLoadSuccess ConditionReason = "DataLoadSuccess"
	// Process data
	ReasonDataProcessing     ConditionReason = "DataProcessing"
	ReasonDataProcessError   ConditionReason = "DataProcessError"
	ReasonDataProcessSuccess ConditionReason = "DataProcessSuccess"
	// Publish dataset
	ReasonDatasetUnpublished ConditionReason = "DatasetUnpublished"
	ReasonDatasetPublished   ConditionReason = "DatasetPublished"
)

Some Dataset related Condition reasons

type ConditionType

type ConditionType string

A ConditionType represents a condition a resource could be in.

const (
	// TypeReady resources are believed to be ready to handle work.
	TypeReady ConditionType = "Ready"
	// TypeUnknown resources are unknown to the system
	TypeUnknown ConditionType = "Unknown"
	// TypeDone resources are believed to be processed
	TypeDone           ConditionType = "Done"
	TypeDataProcessing ConditionType = "DataProcessing"
)

Some common Condition types.

const (
	// Dataset have 3 phases: load -> process -> publish
	// TypeLoaded resources are believed to be loaded
	TypeLoaded ConditionType = "Loaded"
	// TypeProcessed resources are believed to be processed
	TypeProcessed ConditionType = "Processed"
	// TypePublished resources are believed to be published
	TypePublished ConditionType = "Published"
)

Some Data related Condition Types

type ConditionedStatus

type ConditionedStatus struct {
	// Conditions of the resource.
	// +optional
	Conditions []Condition `json:"conditions,omitempty"`
}

A ConditionedStatus reflects the observed status of a resource. Only one condition of each type may exist.

func NewConditionedStatus

func NewConditionedStatus(c ...Condition) *ConditionedStatus

NewConditionedStatus returns a stat with the supplied conditions set.

func (*ConditionedStatus) DeepCopy

func (in *ConditionedStatus) DeepCopy() *ConditionedStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ConditionedStatus.

func (*ConditionedStatus) DeepCopyInto

func (in *ConditionedStatus) DeepCopyInto(out *ConditionedStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ConditionedStatus) Equal

func (s *ConditionedStatus) Equal(other *ConditionedStatus) bool

Equal returns true if the status is identical to the supplied status, ignoring the LastTransitionTimes and order of statuses.

func (*ConditionedStatus) ErrorCondition

func (s *ConditionedStatus) ErrorCondition(msg string) []Condition

func (*ConditionedStatus) GetCondition

func (s *ConditionedStatus) GetCondition(ct ConditionType) Condition

GetCondition returns the condition for the given ConditionType if exists, otherwise returns nil

func (*ConditionedStatus) IsOffline

func (s *ConditionedStatus) IsOffline() bool

func (*ConditionedStatus) IsReady

func (s *ConditionedStatus) IsReady() bool

func (*ConditionedStatus) ReadyCondition

func (s *ConditionedStatus) ReadyCondition() []Condition

func (*ConditionedStatus) SetConditions

func (s *ConditionedStatus) SetConditions(c ...Condition)

SetConditions sets the supplied conditions, replacing any existing conditions of the same type. This is a no-op if all supplied conditions are identical, ignoring the last transition time, to those already set.

func (*ConditionedStatus) WaitingCompleteCondition

func (s *ConditionedStatus) WaitingCompleteCondition() []Condition

type Dataset

type Dataset struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   DatasetSpec   `json:"spec,omitempty"`
	Status DatasetStatus `json:"status,omitempty"`
}

Dataset is the Schema for the datasets API

func (*Dataset) DeepCopy

func (in *Dataset) DeepCopy() *Dataset

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Dataset.

func (*Dataset) DeepCopyInto

func (in *Dataset) DeepCopyInto(out *Dataset)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Dataset) DeepCopyObject

func (in *Dataset) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type DatasetContentType

type DatasetContentType string
const (
	DatasetContentTypeText  DatasetContentType = "text"
	DatasetContentTypeImage DatasetContentType = "image"
	DatasetContentTypeVoice DatasetContentType = "voice"
	DatasetContentTypeVideo DatasetContentType = "video"
)

type DatasetList

type DatasetList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Dataset `json:"items"`
}

DatasetList contains a list of Dataset

func (*DatasetList) DeepCopy

func (in *DatasetList) DeepCopy() *DatasetList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DatasetList.

func (*DatasetList) DeepCopyInto

func (in *DatasetList) DeepCopyInto(out *DatasetList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*DatasetList) DeepCopyObject

func (in *DatasetList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type DatasetSpec

type DatasetSpec struct {
	CommonSpec `json:",inline"`

	// ContentType defines dataset
	ContentType string `json:"contentType"`

	// Model application fields
	Field string `json:"field,omitempty"`
}

DatasetSpec defines the desired state of Dataset

func (*DatasetSpec) DeepCopy

func (in *DatasetSpec) DeepCopy() *DatasetSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DatasetSpec.

func (*DatasetSpec) DeepCopyInto

func (in *DatasetSpec) DeepCopyInto(out *DatasetSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type DatasetStatus

type DatasetStatus struct {
	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`
}

DatasetStatus defines the observed state of Dataset

func (*DatasetStatus) DeepCopy

func (in *DatasetStatus) DeepCopy() *DatasetStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DatasetStatus.

func (*DatasetStatus) DeepCopyInto

func (in *DatasetStatus) DeepCopyInto(out *DatasetStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Datasource

type Datasource struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   DatasourceSpec   `json:"spec,omitempty"`
	Status DatasourceStatus `json:"status,omitempty"`
}

Datasource is the Schema for the datasources API

func (*Datasource) DeepCopy

func (in *Datasource) DeepCopy() *Datasource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Datasource.

func (*Datasource) DeepCopyInto

func (in *Datasource) DeepCopyInto(out *Datasource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Datasource) DeepCopyObject

func (in *Datasource) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type DatasourceList

type DatasourceList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Datasource `json:"items"`
}

DatasourceList contains a list of Datasource

func (*DatasourceList) DeepCopy

func (in *DatasourceList) DeepCopy() *DatasourceList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DatasourceList.

func (*DatasourceList) DeepCopyInto

func (in *DatasourceList) DeepCopyInto(out *DatasourceList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*DatasourceList) DeepCopyObject

func (in *DatasourceList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type DatasourceSpec

type DatasourceSpec struct {
	CommonSpec `json:",inline"`

	// Endpoint defines connection info
	Endpoint Endpoint `json:"endpoint"`

	// OSS defines info for object storage service
	OSS *OSS `json:"oss,omitempty"`

	// RDMA configure RDMA pulls the model file directly from the remote service to the host node.
	RDMA *RDMA `json:"rdma,omitempty"`
}

DatasourceSpec defines the desired state of Datasource

func (*DatasourceSpec) DeepCopy

func (in *DatasourceSpec) DeepCopy() *DatasourceSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DatasourceSpec.

func (*DatasourceSpec) DeepCopyInto

func (in *DatasourceSpec) DeepCopyInto(out *DatasourceSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (DatasourceSpec) Type

func (ds DatasourceSpec) Type() DatasourceType

type DatasourceStatus

type DatasourceStatus struct {
	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`
}

DatasourceStatus defines the observed state of Datasource

func (*DatasourceStatus) DeepCopy

func (in *DatasourceStatus) DeepCopy() *DatasourceStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new DatasourceStatus.

func (*DatasourceStatus) DeepCopyInto

func (in *DatasourceStatus) DeepCopyInto(out *DatasourceStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type DatasourceType

type DatasourceType string
const (
	DatasourceTypeOSS     DatasourceType = "oss"
	DatasourceTypeRDMA    DatasourceType = "RDMA"
	DatasourceTypeUnknown DatasourceType = "unknown"
)

type Embedder

type Embedder struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   EmbedderSpec   `json:"spec,omitempty"`
	Status EmbedderStatus `json:"status,omitempty"`
}

Embedder is the Schema for the embeddings API

func (Embedder) AuthAPIKey

func (e Embedder) AuthAPIKey(ctx context.Context, c client.Client, cli dynamic.Interface) (string, error)

func (*Embedder) DeepCopy

func (in *Embedder) DeepCopy() *Embedder

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Embedder.

func (*Embedder) DeepCopyInto

func (in *Embedder) DeepCopyInto(out *Embedder)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Embedder) DeepCopyObject

func (in *Embedder) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (Embedder) Get3rdPartyModels

func (e Embedder) Get3rdPartyModels() []string

Get3rdPartyModels returns a model list which provided by the 3rd party provider

func (Embedder) GetModelList

func (e Embedder) GetModelList() []string

GetModelList returns a model list provided by this LLM based on different provider

func (Embedder) GetWorkerModels

func (e Embedder) GetWorkerModels() []string

GetWorkerModels returns a model list which provided by this worker provider

type EmbedderList

type EmbedderList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Embedder `json:"items"`
}

EmbedderList contains a list of Embedder

func (*EmbedderList) DeepCopy

func (in *EmbedderList) DeepCopy() *EmbedderList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EmbedderList.

func (*EmbedderList) DeepCopyInto

func (in *EmbedderList) DeepCopyInto(out *EmbedderList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*EmbedderList) DeepCopyObject

func (in *EmbedderList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type EmbedderSpec

type EmbedderSpec struct {
	CommonSpec `json:",inline"`

	// ServiceType indicates the source type of embedding service
	Type embeddings.EmbeddingType `json:"type"`

	// Provider defines the provider info which provide this embedder service
	Provider `json:"provider,omitempty"`

	// Models provided by this LLM
	// If not set,we will use default model list based on LLMType
	Models []string `json:"models,omitempty"`
}

EmbedderSpec defines the desired state of Embedder

func (*EmbedderSpec) DeepCopy

func (in *EmbedderSpec) DeepCopy() *EmbedderSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EmbedderSpec.

func (*EmbedderSpec) DeepCopyInto

func (in *EmbedderSpec) DeepCopyInto(out *EmbedderSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type EmbedderStatus

type EmbedderStatus struct {
	// INSERT ADDITIONAL STATUS FIELD - define observed state of cluster
	// Important: Run "make" to regenerate code after modifying this file
	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`
}

EmbeddingsStatus defines the observed state of Embedder

func (*EmbedderStatus) DeepCopy

func (in *EmbedderStatus) DeepCopy() *EmbedderStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new EmbedderStatus.

func (*EmbedderStatus) DeepCopyInto

func (in *EmbedderStatus) DeepCopyInto(out *EmbedderStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Endpoint

type Endpoint struct {
	// URL for this endpoint
	// +kubebuilder:validation:Required
	URL string `json:"url,omitempty"`

	// InternalURL for this endpoint which is much faster but only can be used inside this cluster
	// +kubebuilder:validation:Required
	InternalURL string `json:"internalURL,omitempty"`

	// AuthSecret if the chart repository requires auth authentication,
	// set the username and password to secret, with the field user and password respectively.
	AuthSecret *TypedObjectReference `json:"authSecret,omitempty"`

	// Insecure if the endpoint needs a secure connection
	Insecure bool `json:"insecure,omitempty"`
}

Endpoint represents a reachable API endpoint.

func (Endpoint) AuthAPIKey

func (endpoint Endpoint) AuthAPIKey(ctx context.Context, ns string, c client.Client, cli dynamic.Interface) (string, error)

func (*Endpoint) DeepCopy

func (in *Endpoint) DeepCopy() *Endpoint

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Endpoint.

func (*Endpoint) DeepCopyInto

func (in *Endpoint) DeepCopyInto(out *Endpoint)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (Endpoint) SchemeInternalURL

func (endpoint Endpoint) SchemeInternalURL() string

SchemeInternalURL returns internal url with prefixed scheme

func (Endpoint) SchemeURL

func (endpoint Endpoint) SchemeURL() string

SchemeURL url with prefixed scheme

type FileDetails

type FileDetails struct {
	// Path defines the detail path to get objects from above datasource
	Path string `json:"path,omitempty"`

	// Type defines the file type which is extracted from object tag  `object_type`
	Type string `json:"type,omitempty"`

	// Count defines the total items in a file which is extracted from object tag  `object_count`
	Count string `json:"count,omitempty"`

	// Size defines the file size which is extracted from object tag  `object_size`
	Size string `json:"size,omitempty"`

	// Checksum defines the checksum of the file
	Checksum string `json:"checksum,omitempty"`

	// The last time this condition was updated.
	LastUpdateTime metav1.Time `json:"lastUpdateTime,omitempty"`

	// Phase defines the process phase
	Phase FileProcessPhase `json:"phase,omitempty"`

	// ErrMessage defines the error message
	ErrMessage string `json:"errMessage,omitempty"`
}

func (*FileDetails) DeepCopy

func (in *FileDetails) DeepCopy() *FileDetails

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FileDetails.

func (*FileDetails) DeepCopyInto

func (in *FileDetails) DeepCopyInto(out *FileDetails)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FileDetails) UpdateErr

func (f *FileDetails) UpdateErr(err error, phase FileProcessPhase)

type FileGroup

type FileGroup struct {
	// From defines the source which provides this `File`
	Source *TypedObjectReference `json:"source,omitempty"`
	// Paths defines the detail paths to get objects from above datasource
	Paths []string `json:"paths,omitempty"`
}

func (*FileGroup) DeepCopy

func (in *FileGroup) DeepCopy() *FileGroup

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FileGroup.

func (*FileGroup) DeepCopyInto

func (in *FileGroup) DeepCopyInto(out *FileGroup)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FileGroupDetail

type FileGroupDetail struct {
	// From defines the datasource which provides these files
	Source *TypedObjectReference `json:"source,omitempty"`

	// FileDetails is the detail files
	FileDetails []FileDetails `json:"fileDetails,omitempty"`
}

func (*FileGroupDetail) DeepCopy

func (in *FileGroupDetail) DeepCopy() *FileGroupDetail

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FileGroupDetail.

func (*FileGroupDetail) DeepCopyInto

func (in *FileGroupDetail) DeepCopyInto(out *FileGroupDetail)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FileGroupDetail) Init

func (f *FileGroupDetail) Init(group FileGroup)

type FileProcessPhase

type FileProcessPhase string
const (
	FileProcessPhasePending    FileProcessPhase = "Pending"
	FileProcessPhaseProcessing FileProcessPhase = "Processing"
	FileProcessPhaseSucceeded  FileProcessPhase = "Succeeded"
	FileProcessPhaseFailed     FileProcessPhase = "Failed"
	FileProcessPhaseSkipped    FileProcessPhase = "Skipped"
)

type FileStatus

type FileStatus struct {
	TypedObjectReference `json:",inline"`

	Status []FileDetails `json:"status,omitempty"`
}

func (*FileStatus) DeepCopy

func (in *FileStatus) DeepCopy() *FileStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FileStatus.

func (*FileStatus) DeepCopyInto

func (in *FileStatus) DeepCopyInto(out *FileStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type KnowledgeBase

type KnowledgeBase struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   KnowledgeBaseSpec   `json:"spec,omitempty"`
	Status KnowledgeBaseStatus `json:"status,omitempty"`
}

KnowledgeBase is the Schema for the knowledgebases API

func (*KnowledgeBase) DeepCopy

func (in *KnowledgeBase) DeepCopy() *KnowledgeBase

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KnowledgeBase.

func (*KnowledgeBase) DeepCopyInto

func (in *KnowledgeBase) DeepCopyInto(out *KnowledgeBase)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*KnowledgeBase) DeepCopyObject

func (in *KnowledgeBase) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*KnowledgeBase) ErrorCondition

func (kb *KnowledgeBase) ErrorCondition(msg string) Condition

func (*KnowledgeBase) InitCondition

func (kb *KnowledgeBase) InitCondition() Condition

func (*KnowledgeBase) PendingCondition

func (kb *KnowledgeBase) PendingCondition(msg string) Condition

func (*KnowledgeBase) ReadyCondition

func (kb *KnowledgeBase) ReadyCondition() Condition

func (*KnowledgeBase) VectorStoreCollectionName

func (kb *KnowledgeBase) VectorStoreCollectionName() string

type KnowledgeBaseList

type KnowledgeBaseList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []KnowledgeBase `json:"items"`
}

KnowledgeBaseList contains a list of KnowledgeBase

func (*KnowledgeBaseList) DeepCopy

func (in *KnowledgeBaseList) DeepCopy() *KnowledgeBaseList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KnowledgeBaseList.

func (*KnowledgeBaseList) DeepCopyInto

func (in *KnowledgeBaseList) DeepCopyInto(out *KnowledgeBaseList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*KnowledgeBaseList) DeepCopyObject

func (in *KnowledgeBaseList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type KnowledgeBaseSpec

type KnowledgeBaseSpec struct {
	CommonSpec `json:",inline"`

	// Embedder defines the embedder to embedding files
	Embedder *TypedObjectReference `json:"embedder,omitempty"`

	// VectorStore defines the vectorstore to store results
	VectorStore *TypedObjectReference `json:"vectorStore,omitempty"`

	// FileGroups included files Grouped by VersionedDataset
	FileGroups []FileGroup `json:"fileGroups,omitempty"`
}

KnowledgeBaseSpec defines the desired state of KnowledgeBase

func (*KnowledgeBaseSpec) DeepCopy

func (in *KnowledgeBaseSpec) DeepCopy() *KnowledgeBaseSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KnowledgeBaseSpec.

func (*KnowledgeBaseSpec) DeepCopyInto

func (in *KnowledgeBaseSpec) DeepCopyInto(out *KnowledgeBaseSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type KnowledgeBaseStatus

type KnowledgeBaseStatus struct {
	// ObservedGeneration is the last observed generation.
	// +optional
	ObservedGeneration int64 `json:"observedGeneration,omitempty"`

	// FileGroupDetail is the detail of these files
	FileGroupDetail []FileGroupDetail `json:"fileGroupDetail,omitempty"`

	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`
}

KnowledgeBaseStatus defines the observed state of KnowledgeBase

func (*KnowledgeBaseStatus) DeepCopy

func (in *KnowledgeBaseStatus) DeepCopy() *KnowledgeBaseStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KnowledgeBaseStatus.

func (*KnowledgeBaseStatus) DeepCopyInto

func (in *KnowledgeBaseStatus) DeepCopyInto(out *KnowledgeBaseStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type LLM

type LLM struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   LLMSpec   `json:"spec,omitempty"`
	Status LLMStatus `json:"status,omitempty"`
}

LLM is the Schema for the llms API

func (LLM) AuthAPIKey

func (llm LLM) AuthAPIKey(ctx context.Context, c client.Client, cli dynamic.Interface) (string, error)

func (*LLM) DeepCopy

func (in *LLM) DeepCopy() *LLM

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LLM.

func (*LLM) DeepCopyInto

func (in *LLM) DeepCopyInto(out *LLM)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*LLM) DeepCopyObject

func (in *LLM) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (LLM) Get3rdPartyModels

func (llm LLM) Get3rdPartyModels() []string

Get3rdPartyModels returns a model list which provided by the 3rd party provider

func (LLM) GetModelList

func (llm LLM) GetModelList() []string

GetModelList returns a model list provided by this LLM based on different provider

func (LLM) GetWorkerModels

func (llm LLM) GetWorkerModels() []string

GetWorkerModels returns a model list which provided by this worker provider

type LLMList

type LLMList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []LLM `json:"items"`
}

LLMList contains a list of LLM

func (*LLMList) DeepCopy

func (in *LLMList) DeepCopy() *LLMList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LLMList.

func (*LLMList) DeepCopyInto

func (in *LLMList) DeepCopyInto(out *LLMList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*LLMList) DeepCopyObject

func (in *LLMList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type LLMSpec

type LLMSpec struct {
	CommonSpec `json:",inline"`

	// Type defines the type of llm
	Type llms.LLMType `json:"type"`

	// Provider defines the provider info which provide this llm service
	Provider `json:"provider,omitempty"`

	// Models provided by this LLM
	// If not set,we will use default model list based on LLMType
	Models []string `json:"models,omitempty"`
}

LLMSpec defines the desired state of LLM

func (*LLMSpec) DeepCopy

func (in *LLMSpec) DeepCopy() *LLMSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LLMSpec.

func (*LLMSpec) DeepCopyInto

func (in *LLMSpec) DeepCopyInto(out *LLMSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type LLMStatus

type LLMStatus struct {
	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`
}

LLMStatus defines the observed state of LLM

func (*LLMStatus) DeepCopy

func (in *LLMStatus) DeepCopy() *LLMStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new LLMStatus.

func (*LLMStatus) DeepCopyInto

func (in *LLMStatus) DeepCopyInto(out *LLMStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (LLMStatus) LLMReady

func (llmStatus LLMStatus) LLMReady() (string, bool)

type Model

type Model struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   ModelSpec   `json:"spec,omitempty"`
	Status ModelStatus `json:"status,omitempty"`
}

Model is the Schema for the models API

func (*Model) DeepCopy

func (in *Model) DeepCopy() *Model

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Model.

func (*Model) DeepCopyInto

func (in *Model) DeepCopyInto(out *Model)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Model) DeepCopyObject

func (in *Model) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (Model) FullPath

func (model Model) FullPath() string

FullPath with bucket and object path

func (Model) IsEmbeddingModel

func (model Model) IsEmbeddingModel() bool

IsLLMModel checks whether this model is a embedding model

func (Model) IsLLMModel

func (model Model) IsLLMModel() bool

IsLLMModel checks whether this model is a llm model

func (Model) ObjectPath

func (model Model) ObjectPath() string

ObjectPath is the path where model stored at in a bucket

type ModelList

type ModelList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Model `json:"items"`
}

ModelList contains a list of Model

func (*ModelList) DeepCopy

func (in *ModelList) DeepCopy() *ModelList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ModelList.

func (*ModelList) DeepCopyInto

func (in *ModelList) DeepCopyInto(out *ModelList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*ModelList) DeepCopyObject

func (in *ModelList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type ModelSpec

type ModelSpec struct {
	CommonSpec `json:",inline"`

	// Type defines what kind of model this is
	// Comma separated field which can be wrapped by {llm,embedding}
	Types string `json:"types,omitempty"`

	// Source define the source of the model file
	Source *TypedObjectReference `json:"source,omitempty"`
}

ModelSpec defines the desired state of Model

func (*ModelSpec) DeepCopy

func (in *ModelSpec) DeepCopy() *ModelSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ModelSpec.

func (*ModelSpec) DeepCopyInto

func (in *ModelSpec) DeepCopyInto(out *ModelSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type ModelStatus

type ModelStatus struct {
	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`
}

ModelStatus defines the observed state of Model

func (*ModelStatus) DeepCopy

func (in *ModelStatus) DeepCopy() *ModelStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ModelStatus.

func (*ModelStatus) DeepCopyInto

func (in *ModelStatus) DeepCopyInto(out *ModelStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Node

type Node struct {
	NodeConfig   `json:",inline"`
	NextNodeName []string `json:"nextNodeName,omitempty"`
}

func (*Node) DeepCopy

func (in *Node) DeepCopy() *Node

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Node.

func (*Node) DeepCopyInto

func (in *Node) DeepCopyInto(out *Node)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type NodeConfig

type NodeConfig struct {
	// +kubebuilder:validation:Required
	Name        string                `json:"name,omitempty"`
	DisplayName string                `json:"displayName,omitempty"`
	Description string                `json:"description,omitempty"`
	Ref         *TypedObjectReference `json:"ref,omitempty"`
}

func (*NodeConfig) DeepCopy

func (in *NodeConfig) DeepCopy() *NodeConfig

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NodeConfig.

func (*NodeConfig) DeepCopyInto

func (in *NodeConfig) DeepCopyInto(out *NodeConfig)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type OSS

type OSS struct {
	Bucket string `json:"bucket,omitempty"`
	// Object must end with a slash "/" if it is a directory
	Object string `json:"object,omitempty"`
}

OSS defines info for object storage service as datasource

func (*OSS) DeepCopy

func (in *OSS) DeepCopy() *OSS

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new OSS.

func (*OSS) DeepCopyInto

func (in *OSS) DeepCopyInto(out *OSS)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Prompt

type Prompt struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   PromptSpec   `json:"spec,omitempty"`
	Status PromptStatus `json:"status,omitempty"`
}

Prompt is the Schema for the prompts API

func (*Prompt) DeepCopy

func (in *Prompt) DeepCopy() *Prompt

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Prompt.

func (*Prompt) DeepCopyInto

func (in *Prompt) DeepCopyInto(out *Prompt)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Prompt) DeepCopyObject

func (in *Prompt) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*Prompt) Default

func (p *Prompt) Default(ctx context.Context, obj runtime.Object) error

func (*Prompt) SetupWebhookWithManager

func (p *Prompt) SetupWebhookWithManager(mgr ctrl.Manager) error

func (*Prompt) ValidateCreate

func (p *Prompt) ValidateCreate(ctx context.Context, obj runtime.Object) error

ValidateCreate implements webhook.Validator so a webhook will be registered for the type

func (*Prompt) ValidateDelete

func (p *Prompt) ValidateDelete(ctx context.Context, obj runtime.Object) error

ValidateDelete implements webhook.Validator so a webhook will be registered for the type

func (*Prompt) ValidateUpdate

func (p *Prompt) ValidateUpdate(ctx context.Context, oldObj runtime.Object, newObj runtime.Object) error

ValidateUpdate implements webhook.Validator so a webhook will be registered for the type

type PromptList

type PromptList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Prompt `json:"items"`
}

PromptList contains a list of Prompt

func (*PromptList) DeepCopy

func (in *PromptList) DeepCopy() *PromptList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PromptList.

func (*PromptList) DeepCopyInto

func (in *PromptList) DeepCopyInto(out *PromptList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*PromptList) DeepCopyObject

func (in *PromptList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type PromptSpec

type PromptSpec struct {
	// LLM serivice name(CRD LLM)
	LLM string `json:"llm"`
	// ZhiPuAIParams defines the params of ZhiPuAI
	ZhiPuAIParams *llmzhipuai.ModelParams `json:"zhiPuAIParams,omitempty"`
}

PromptSpec defines the desired state of Prompt

func (*PromptSpec) DeepCopy

func (in *PromptSpec) DeepCopy() *PromptSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PromptSpec.

func (*PromptSpec) DeepCopyInto

func (in *PromptSpec) DeepCopyInto(out *PromptSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type PromptStatus

type PromptStatus struct {
	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`

	// Data retrieved after LLM Call
	Data []byte `json:"data"`
}

PromptStatus defines the observed state of Prompt

func (*PromptStatus) DeepCopy

func (in *PromptStatus) DeepCopy() *PromptStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new PromptStatus.

func (*PromptStatus) DeepCopyInto

func (in *PromptStatus) DeepCopyInto(out *PromptStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Provider

type Provider struct {
	// Endpoint defines connection info
	Endpoint *Endpoint `json:"endpoint,omitempty"`

	// Worker defines the worker info
	// Means this LLM is provided by a arcadia worker
	Worker *TypedObjectReference `json:"worker,omitempty"`
}

Provider defines how to prvoide the service

func (*Provider) DeepCopy

func (in *Provider) DeepCopy() *Provider

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Provider.

func (*Provider) DeepCopyInto

func (in *Provider) DeepCopyInto(out *Provider)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (Provider) GetType

func (p Provider) GetType() ProviderType

GetType returns the type of this provider

type ProviderType

type ProviderType string
const (
	ProviderTypeUnknown  ProviderType = "unknown"
	ProviderType3rdParty ProviderType = "3rd_party"
	ProviderTypeWorker   ProviderType = "worker"
)

type RDMA

type RDMA struct {
	// We consider the model storage path on the sender's side and the save path on the receiver's side to be the same,
	// so a single Path is uniformly configured here.
	// example: /opt/kubeagi/, /opt/, /
	// +kubebuilder:validation:Pattern=(^\/$)|(^\/[a-zA-Z0-9\_.@-]+(\/[a-zA-Z0-9\_.@-]+)*\/$)
	Path string `json:"path"`

	NodePaths map[string]string `json:"nodePaths,omitempty"`
}

func (*RDMA) DeepCopy

func (in *RDMA) DeepCopy() *RDMA

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RDMA.

func (*RDMA) DeepCopyInto

func (in *RDMA) DeepCopyInto(out *RDMA)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type TypedObjectReference

type TypedObjectReference struct {
	// APIGroup is the group for the resource being referenced.
	// If APIGroup is not specified, the specified Kind must be in the core API group.
	// For any other third-party types, APIGroup is required.
	// +optional
	APIGroup *string `json:"apiGroup" protobuf:"bytes,1,opt,name=apiGroup"`
	// Kind is the type of resource being referenced
	Kind string `json:"kind" protobuf:"bytes,2,opt,name=kind"`
	// Name is the name of resource being referenced
	Name string `json:"name" protobuf:"bytes,3,opt,name=name"`
	// Namespace is the namespace of resource being referenced
	// +optional
	Namespace *string `json:"namespace,omitempty" protobuf:"bytes,4,opt,name=namespace"`
}

func (*TypedObjectReference) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new TypedObjectReference.

func (*TypedObjectReference) DeepCopyInto

func (in *TypedObjectReference) DeepCopyInto(out *TypedObjectReference)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*TypedObjectReference) GetNamespace

func (in *TypedObjectReference) GetNamespace(defaultNamespace string) string

GetNamespace returns the namespace: 1. if TypedObjectReference.namespace is not nil, return it 2. if defaultNamespace is not empty, return it 3. return env: POD_NAMESPACE value, usually operator's namespace

func (*TypedObjectReference) WithAPIGroup

func (in *TypedObjectReference) WithAPIGroup(apiGroup string)

func (*TypedObjectReference) WithKind

func (in *TypedObjectReference) WithKind(kind string)

func (*TypedObjectReference) WithName

func (in *TypedObjectReference) WithName(name string)

func (*TypedObjectReference) WithNameSpace

func (in *TypedObjectReference) WithNameSpace(namespace string)

type VectorStore

type VectorStore struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   VectorStoreSpec   `json:"spec,omitempty"`
	Status VectorStoreStatus `json:"status,omitempty"`
}

VectorStore is the Schema for the vectorstores API

func (*VectorStore) DeepCopy

func (in *VectorStore) DeepCopy() *VectorStore

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VectorStore.

func (*VectorStore) DeepCopyInto

func (in *VectorStore) DeepCopyInto(out *VectorStore)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*VectorStore) DeepCopyObject

func (in *VectorStore) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*VectorStore) ErrorCondition

func (vs *VectorStore) ErrorCondition(msg string) Condition

func (*VectorStore) InitCondition

func (vs *VectorStore) InitCondition() Condition

func (*VectorStore) PendingCondition

func (vs *VectorStore) PendingCondition(msg string) Condition

func (*VectorStore) ReadyCondition

func (vs *VectorStore) ReadyCondition() Condition

type VectorStoreList

type VectorStoreList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []VectorStore `json:"items"`
}

VectorStoreList contains a list of VectorStore

func (*VectorStoreList) DeepCopy

func (in *VectorStoreList) DeepCopy() *VectorStoreList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VectorStoreList.

func (*VectorStoreList) DeepCopyInto

func (in *VectorStoreList) DeepCopyInto(out *VectorStoreList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*VectorStoreList) DeepCopyObject

func (in *VectorStoreList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type VectorStoreSpec

type VectorStoreSpec struct {
	CommonSpec `json:",inline"`

	// Endpoint defines connection info
	Endpoint *Endpoint `json:"endpoint,omitempty"`

	Chroma *Chroma `json:"chroma,omitempty"`
}

VectorStoreSpec defines the desired state of VectorStore

func (*VectorStoreSpec) DeepCopy

func (in *VectorStoreSpec) DeepCopy() *VectorStoreSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VectorStoreSpec.

func (*VectorStoreSpec) DeepCopyInto

func (in *VectorStoreSpec) DeepCopyInto(out *VectorStoreSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (VectorStoreSpec) Type

func (vs VectorStoreSpec) Type() VectorStoreType

type VectorStoreStatus

type VectorStoreStatus struct {
	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`
}

VectorStoreStatus defines the observed state of VectorStore

func (*VectorStoreStatus) DeepCopy

func (in *VectorStoreStatus) DeepCopy() *VectorStoreStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VectorStoreStatus.

func (*VectorStoreStatus) DeepCopyInto

func (in *VectorStoreStatus) DeepCopyInto(out *VectorStoreStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VectorStoreType

type VectorStoreType string
const (
	VectorStoreTypeChroma  VectorStoreType = "chroma"
	VectorStoreTypeUnknown VectorStoreType = "unknown"
)

type VersionedDataset

type VersionedDataset struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   VersionedDatasetSpec   `json:"spec,omitempty"`
	Status VersionedDatasetStatus `json:"status,omitempty"`
}

VersionedDataset is the Schema for the versioneddatasets API

func (*VersionedDataset) DeepCopy

func (in *VersionedDataset) DeepCopy() *VersionedDataset

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VersionedDataset.

func (*VersionedDataset) DeepCopyInto

func (in *VersionedDataset) DeepCopyInto(out *VersionedDataset)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*VersionedDataset) DeepCopyObject

func (in *VersionedDataset) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type VersionedDatasetList

type VersionedDatasetList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []VersionedDataset `json:"items"`
}

VersionedDatasetList contains a list of VersionedDataset

func (*VersionedDatasetList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VersionedDatasetList.

func (*VersionedDatasetList) DeepCopyInto

func (in *VersionedDatasetList) DeepCopyInto(out *VersionedDatasetList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*VersionedDatasetList) DeepCopyObject

func (in *VersionedDatasetList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type VersionedDatasetSpec

type VersionedDatasetSpec struct {
	// Dataset which this `VersionedDataset` belongs to
	Dataset *TypedObjectReference `json:"dataset"`

	// Version
	// +kubebuilder:validation:Pattern=^v\d+$
	Version string `json:"version"`

	// FileGroups included in this `VersionedDataset`
	// Grouped by Datasource
	FileGroups []FileGroup `json:"fileGroups,omitempty"`

	// +kubebuilder:validation:Enum=0;1
	// +kubebuilder:default=0
	Released uint8 `json:"released"`

	// Which version of the dataset it inherits from
	InheritedFrom string `json:"inheritedFrom,omitempty"`

	// DisplayName
	CommonSpec `json:",inline"`
}

VersionedDatasetSpec defines the desired state of VersionedDataset

func (*VersionedDatasetSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VersionedDatasetSpec.

func (*VersionedDatasetSpec) DeepCopyInto

func (in *VersionedDatasetSpec) DeepCopyInto(out *VersionedDatasetSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type VersionedDatasetStatus

type VersionedDatasetStatus struct {
	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`

	// Files record the process and results of file processing for each data source
	Files []FileStatus `json:"files,omitempty"`
}

VersionedDatasetStatus defines the observed state of VersionedDataset

func (*VersionedDatasetStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new VersionedDatasetStatus.

func (*VersionedDatasetStatus) DeepCopyInto

func (in *VersionedDatasetStatus) DeepCopyInto(out *VersionedDatasetStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Worker

type Worker struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   WorkerSpec   `json:"spec,omitempty"`
	Status WorkerStatus `json:"status,omitempty"`
}

Worker is the Schema for the workers API

func (Worker) BuildEmbedder

func (worker Worker) BuildEmbedder() *Embedder

func (Worker) BuildLLM

func (worker Worker) BuildLLM() *LLM

func (*Worker) DeepCopy

func (in *Worker) DeepCopy() *Worker

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Worker.

func (*Worker) DeepCopyInto

func (in *Worker) DeepCopyInto(out *Worker)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*Worker) DeepCopyObject

func (in *Worker) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (Worker) ErrorCondition

func (worker Worker) ErrorCondition(msg string) Condition

func (Worker) MakeRegistrationModelName

func (worker Worker) MakeRegistrationModelName() string

MakeRegistrationModelName generates a model name used to register itself into fastchat controller

func (Worker) Model

func (worker Worker) Model() TypedObjectReference

func (Worker) OfflineCondition

func (worker Worker) OfflineCondition() Condition

func (Worker) PendingCondition

func (worker Worker) PendingCondition() Condition

func (Worker) ReadyCondition

func (worker Worker) ReadyCondition() Condition

func (Worker) Type

func (worker Worker) Type() WorkerType

type WorkerList

type WorkerList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Worker `json:"items"`
}

WorkerList contains a list of Worker

func (*WorkerList) DeepCopy

func (in *WorkerList) DeepCopy() *WorkerList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerList.

func (*WorkerList) DeepCopyInto

func (in *WorkerList) DeepCopyInto(out *WorkerList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*WorkerList) DeepCopyObject

func (in *WorkerList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type WorkerSpec

type WorkerSpec struct {
	CommonSpec `json:",inline"`

	// Type for this worker
	Type WorkerType `json:"type,omitempty"`

	// Model this worker wants to use
	Model *TypedObjectReference `json:"model"`

	// Replicas of this worker instance(1 by default)
	// +kubebuilder:default=1
	// +kubebuilder:validation:Maximum=1
	Replicas *int32 `json:"replicas,omitempty"`

	// Resource request&limits including
	// - CPU or GPU
	// - Memory
	Resources corev1.ResourceRequirements `json:"resources,omitempty"`

	// Storage claimed to store model files
	Storage *corev1.PersistentVolumeClaimSpec `json:"storage,omitempty"`
}

WorkerSpec defines the desired state of Worker

func (*WorkerSpec) DeepCopy

func (in *WorkerSpec) DeepCopy() *WorkerSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerSpec.

func (*WorkerSpec) DeepCopyInto

func (in *WorkerSpec) DeepCopyInto(out *WorkerSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type WorkerStatus

type WorkerStatus struct {
	// PodStatus is the observed stated of Worker pod
	// +optional
	PodStatus corev1.PodStatus `json:"podStatus,omitempty"`

	// ConditionedStatus is the current status
	ConditionedStatus `json:",inline"`
}

WorkerStatus defines the observed state of Worker

func (*WorkerStatus) DeepCopy

func (in *WorkerStatus) DeepCopy() *WorkerStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new WorkerStatus.

func (*WorkerStatus) DeepCopyInto

func (in *WorkerStatus) DeepCopyInto(out *WorkerStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type WorkerType

type WorkerType string
const (
	WorkerTypeFastchatNormal WorkerType = "fastchat"
	WorkerTypeFastchatVLLM   WorkerType = "fastchat-vllm"
	WorkerTypeUnknown        WorkerType = "unknown"
)

func DefaultWorkerType

func DefaultWorkerType() WorkerType

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL