Documentation ¶
Overview ¶
+k8s:deepcopy-gen=package +groupName=ml.llmos.ai
+k8s:deepcopy-gen=package +groupName=ml.llmos.ai
+k8s:deepcopy-gen=package +groupName=ml.llmos.ai
Index ¶
- Variables
- func Kind(kind string) schema.GroupKind
- func Resource(resource string) schema.GroupResource
- type ModelService
- type ModelServiceList
- type ModelServiceSpec
- type ModelServiceStatus
- type ModelServiceTemplateSpec
- type Notebook
- type NotebookList
- type NotebookSpec
- type NotebookStatus
- type NotebookTemplateSpec
- type Volume
Constants ¶
This section is empty.
Variables ¶
var ( ModelServiceResourceName = "modelservices" NotebookResourceName = "notebooks" )
var ( SchemeBuilder = runtime.NewSchemeBuilder(addKnownTypes) AddToScheme = SchemeBuilder.AddToScheme )
var SchemeGroupVersion = schema.GroupVersion{Group: ml.GroupName, Version: "v1"}
SchemeGroupVersion is group version used to register these objects
Functions ¶
func Resource ¶
func Resource(resource string) schema.GroupResource
Resource takes an unqualified resource and returns a Group qualified GroupResource
Types ¶
type ModelService ¶
type ModelService struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec ModelServiceSpec `json:"spec,omitempty"` Status ModelServiceStatus `json:"status,omitempty"` }
ModelService is a deployment for the LLM Model
func NewModelService ¶
func NewModelService(namespace, name string, obj ModelService) *ModelService
func (*ModelService) DeepCopy ¶
func (in *ModelService) DeepCopy() *ModelService
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ModelService.
func (*ModelService) DeepCopyInto ¶
func (in *ModelService) DeepCopyInto(out *ModelService)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ModelService) DeepCopyObject ¶
func (in *ModelService) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ModelServiceList ¶
type ModelServiceList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata"` Items []ModelService `json:"items"` }
ModelServiceList is a list of ModelService resources
func (*ModelServiceList) DeepCopy ¶
func (in *ModelServiceList) DeepCopy() *ModelServiceList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ModelServiceList.
func (*ModelServiceList) DeepCopyInto ¶
func (in *ModelServiceList) DeepCopyInto(out *ModelServiceList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*ModelServiceList) DeepCopyObject ¶
func (in *ModelServiceList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type ModelServiceSpec ¶
type ModelServiceSpec struct { // +kubebuilder:validation:Enum:={"huggingface","modelscope","local"} // +kubebuilder:validation:Required ModelRegistry string `json:"modelRegistry"` // +kubebuilder:validation:Required ModelName string `json:"model"` // +optional, name of the model to serve in API ServedModelName string `json:"servedModelName,omitempty"` // +kubebuilder:validation:Required Replicas int32 `json:"replicas"` // selector is a label query over pods that should match the replica count. // It must match the pod template's labels. // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors Selector *metav1.LabelSelector `json:"selector,omitempty"` // +kubebuilder:default:=ClusterIP ServiceType corev1.ServiceType `json:"serviceType,omitempty"` // +optional, list of persistent volume claims VolumeClaimTemplates []corev1.PersistentVolumeClaim `json:"volumeClaimTemplates,omitempty"` // +optional, modelService's statefulset update strategy UpdateStrategy v1.StatefulSetUpdateStrategy `json:"updateStrategy,omitempty"` // +optional, pod template spec of the model Template ModelServiceTemplateSpec `json:"template,omitempty"` // +optional, map of accelerator name to number of accelerators // e.g., 4090:2 means only schedule to a node with 2 4090 GPUs // TODO: support accelerators by node selection Accelerators map[string]uint8 `json:"accelerators,omitempty"` // +optional, enable gradio GUI of the model EnableGUI bool `json:"enableGUI,omitempty"` }
ModelServiceSpec defines the desired state of ModelService
func (*ModelServiceSpec) DeepCopy ¶
func (in *ModelServiceSpec) DeepCopy() *ModelServiceSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ModelServiceSpec.
func (*ModelServiceSpec) DeepCopyInto ¶
func (in *ModelServiceSpec) DeepCopyInto(out *ModelServiceSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ModelServiceStatus ¶
type ModelServiceStatus struct { Conditions []common.Condition `json:"conditions,omitempty"` // ReadyReplicas is the number of Pods created by the controller that have a Ready Condition ReadyReplicas int32 `json:"readyReplicas,omitempty"` // ContainerState is the mirror state of underlying container ContainerState corev1.ContainerState `json:"containerState,omitempty"` // State is the state of the model service State string `json:"state,omitempty"` }
ModelServiceStatus defines the observed state of ModelService
func (*ModelServiceStatus) DeepCopy ¶
func (in *ModelServiceStatus) DeepCopy() *ModelServiceStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ModelServiceStatus.
func (*ModelServiceStatus) DeepCopyInto ¶
func (in *ModelServiceStatus) DeepCopyInto(out *ModelServiceStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type ModelServiceTemplateSpec ¶
func (*ModelServiceTemplateSpec) DeepCopy ¶
func (in *ModelServiceTemplateSpec) DeepCopy() *ModelServiceTemplateSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new ModelServiceTemplateSpec.
func (*ModelServiceTemplateSpec) DeepCopyInto ¶
func (in *ModelServiceTemplateSpec) DeepCopyInto(out *ModelServiceTemplateSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Notebook ¶
type Notebook struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` Spec NotebookSpec `json:"spec,omitempty"` Status NotebookStatus `json:"status,omitempty"` }
Notebook is the Schema for the notebooks API
func NewNotebook ¶
func (*Notebook) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Notebook.
func (*Notebook) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Notebook) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type NotebookList ¶
type NotebookList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata"` Items []Notebook `json:"items"` }
NotebookList is a list of Notebook resources
func (*NotebookList) DeepCopy ¶
func (in *NotebookList) DeepCopy() *NotebookList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NotebookList.
func (*NotebookList) DeepCopyInto ¶
func (in *NotebookList) DeepCopyInto(out *NotebookList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*NotebookList) DeepCopyObject ¶
func (in *NotebookList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type NotebookSpec ¶
type NotebookSpec struct { // +optional, template describes the notebooks that will be created. Template NotebookTemplateSpec `json:"template,omitempty"` // +kubebuilder:validation:Required Replicas int32 `json:"replicas"` // selector is a label query over pods that should match the replica count. // It must match the pod template's labels. // More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/#label-selectors Selector *metav1.LabelSelector `json:"selector,omitempty"` // +optional, serviceType is the type of service that will be created. // +kubebuilder:default:=ClusterIP ServiceType corev1.ServiceType `json:"serviceType,omitempty"` // +optional, list of PersistentVolumeClaims that will be created. VolumeClaimTemplates []corev1.PersistentVolumeClaim `json:"volumeClaimTemplates,omitempty"` }
NotebookSpec defines the desired state of Dataset
func (*NotebookSpec) DeepCopy ¶
func (in *NotebookSpec) DeepCopy() *NotebookSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NotebookSpec.
func (*NotebookSpec) DeepCopyInto ¶
func (in *NotebookSpec) DeepCopyInto(out *NotebookSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type NotebookStatus ¶
type NotebookStatus struct { // Conditions is an array of current conditions Conditions []common.Condition `json:"conditions"` // ReadyReplicas is the number of Pods created by the StatefulSet controller that have a Ready Condition. ReadyReplicas int32 `json:"readyReplicas"` // ContainerState is the mirror state of underlying container ContainerState corev1.ContainerState `json:"containerState,omitempty"` // State is the state of the notebook State string `json:"state,omitempty"` }
NotebookStatus defines the observed state of Dataset
func (*NotebookStatus) DeepCopy ¶
func (in *NotebookStatus) DeepCopy() *NotebookStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NotebookStatus.
func (*NotebookStatus) DeepCopyInto ¶
func (in *NotebookStatus) DeepCopyInto(out *NotebookStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type NotebookTemplateSpec ¶
func (*NotebookTemplateSpec) DeepCopy ¶
func (in *NotebookTemplateSpec) DeepCopy() *NotebookTemplateSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NotebookTemplateSpec.
func (*NotebookTemplateSpec) DeepCopyInto ¶
func (in *NotebookTemplateSpec) DeepCopyInto(out *NotebookTemplateSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type Volume ¶
type Volume struct { Name string `json:"name"` Spec corev1.PersistentVolumeClaimSpec `json:"spec"` }
func (*Volume) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Volume.
func (*Volume) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.