diff --git a/adaptor/PCM-AI/PCM-AI-CORE/api/internal/types/types.go b/adaptor/PCM-AI/PCM-AI-CORE/api/internal/types/types.go index 0f5a116..7f9c49e 100644 --- a/adaptor/PCM-AI/PCM-AI-CORE/api/internal/types/types.go +++ b/adaptor/PCM-AI/PCM-AI-CORE/api/internal/types/types.go @@ -22,7 +22,7 @@ type DataSetReq struct { type DataSetResp struct { TotalNumber uint32 `json:"total_number" copier:"TotalNumber"` - DataSets []DataSets `json:"data_sets" copier:"DataSets"` + Datasets []DataSets `json:"data_sets" copier:"Datasets"` } type CreateDataSetReq struct { diff --git a/adaptor/PCM-AI/PCM-MODELARTS/rpc/modelarts/pcm-modelarts.pb.go b/adaptor/PCM-AI/PCM-MODELARTS/rpc/modelarts/pcm-modelarts.pb.go index 8116c27..c75b26f 100644 --- a/adaptor/PCM-AI/PCM-MODELARTS/rpc/modelarts/pcm-modelarts.pb.go +++ b/adaptor/PCM-AI/PCM-MODELARTS/rpc/modelarts/pcm-modelarts.pb.go @@ -568,7 +568,7 @@ type DataSetResp struct { unknownFields protoimpl.UnknownFields TotalNumber uint32 `protobuf:"varint,1,opt,name=total_number,json=totalNumber,proto3" json:"total_number,omitempty"` // @gotags: copier:"TotalNumber" - DataSets []*DataSets `protobuf:"bytes,2,rep,name=dataSets,proto3" json:"dataSets,omitempty"` // @gotags: copier:"DataSets" + Datasets []*DataSets `protobuf:"bytes,2,rep,name=datasets,proto3" json:"datasets,omitempty"` // @gotags: copier:"Datasets" } func (x *DataSetResp) Reset() { @@ -610,9 +610,9 @@ func (x *DataSetResp) GetTotalNumber() uint32 { return 0 } -func (x *DataSetResp) GetDataSets() []*DataSets { +func (x *DataSetResp) GetDatasets() []*DataSets { if x != nil { - return x.DataSets + return x.Datasets } return nil } @@ -10149,7 +10149,7 @@ type SearchLabel struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // @gotags: copier:"Name" Op string `protobuf:"bytes,2,opt,name=op,proto3" json:"op,omitempty"` // @gotags: copier:"Op" - // map property = 3; // @gotags: copier:"Property" + // map property = 3; // @gotags: copier:"Property" Type int64 `protobuf:"varint,4,opt,name=type,proto3" json:"type,omitempty"` // @gotags: copier:"Type" } @@ -19575,9 +19575,9 @@ var file_pcm_modelarts_proto_rawDesc = []byte{ 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0b, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x2f, 0x0a, 0x08, 0x64, 0x61, 0x74, 0x61, - 0x53, 0x65, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x13, 0x2e, 0x6d, 0x6f, 0x64, + 0x73, 0x65, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x13, 0x2e, 0x6d, 0x6f, 0x64, 0x65, 0x6c, 0x61, 0x72, 0x74, 0x73, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x53, 0x65, 0x74, 0x73, 0x52, - 0x08, 0x64, 0x61, 0x74, 0x61, 0x53, 0x65, 0x74, 0x73, 0x22, 0x93, 0x02, 0x0a, 0x08, 0x44, 0x61, + 0x08, 0x64, 0x61, 0x74, 0x61, 0x73, 0x65, 0x74, 0x73, 0x22, 0x93, 0x02, 0x0a, 0x08, 0x44, 0x61, 0x74, 0x61, 0x53, 0x65, 0x74, 0x73, 0x12, 0x1d, 0x0a, 0x0a, 0x64, 0x61, 0x74, 0x61, 0x73, 0x65, 0x74, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x64, 0x61, 0x74, 0x61, 0x73, 0x65, 0x74, 0x49, 0x64, 0x12, 0x1f, 0x0a, 0x0b, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x66, 0x6f, @@ -23031,7 +23031,7 @@ var file_pcm_modelarts_proto_depIdxs = []int32{ 6, // 5: modelarts.password.user:type_name -> modelarts.user 7, // 6: modelarts.user.domain:type_name -> modelarts.domain 0, // 7: modelarts.TokenReq.auth:type_name -> modelarts.auth - 12, // 8: modelarts.DataSetResp.dataSets:type_name -> modelarts.DataSets + 12, // 8: modelarts.DataSetResp.datasets:type_name -> modelarts.DataSets 13, // 9: modelarts.DataSets.data_sources:type_name -> modelarts.DataSources 15, // 10: modelarts.ImportTaskDataResp.resp200:type_name -> modelarts.ImportTaskDataResp200 16, // 11: modelarts.ImportTaskDataResp.resp400:type_name -> modelarts.ImportTaskDataResp400 diff --git a/adaptor/PCM-AI/PCM-MODELARTS/rpc/modelarts/pcm-modelarts_grpc.pb.go b/adaptor/PCM-AI/PCM-MODELARTS/rpc/modelarts/pcm-modelarts_grpc.pb.go index 277a0ff..edc8f98 100644 --- a/adaptor/PCM-AI/PCM-MODELARTS/rpc/modelarts/pcm-modelarts_grpc.pb.go +++ b/adaptor/PCM-AI/PCM-MODELARTS/rpc/modelarts/pcm-modelarts_grpc.pb.go @@ -22,64 +22,64 @@ const _ = grpc.SupportPackageIsVersion7 // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. type ModelArtsClient interface { - // get modelarts Token + //get modelarts Token GetToken(ctx context.Context, in *TokenReq, opts ...grpc.CallOption) (*TokenResp, error) - // get modelarts Token + //get modelarts Token GetDatasetList(ctx context.Context, in *DataSetReq, opts ...grpc.CallOption) (*DataSetResp, error) - // create DateSet + //create DateSet CreateDataSet(ctx context.Context, in *CreateDataSetReq, opts ...grpc.CallOption) (*CreateDataSetResq, error) - // create DateSet + //create DateSet DeleteDataSet(ctx context.Context, in *DeleteDataSetReq, opts ...grpc.CallOption) (*DeleteDataSetResq, error) - // creat task 创建导入任务 + //creat task 创建导入任务 CreateTask(ctx context.Context, in *ImportTaskDataReq, opts ...grpc.CallOption) (*ImportTaskDataResp, error) - // get taskList 查询数据集导入任务列表 + //get taskList 查询数据集导入任务列表 GetImportTaskList(ctx context.Context, in *ListImportTasksReq, opts ...grpc.CallOption) (*ListImportTasksResp, error) - // ListTrainingJobs 查询训练作业列表 + // ListTrainingJobs 查询训练作业列表 GetListTrainingJobs(ctx context.Context, in *ListTrainingJobsreq, opts ...grpc.CallOption) (*ListTrainingJobsresp, error) - // CreateTrainingJob 创建训练作业 + // CreateTrainingJob 创建训练作业 CreateTrainingJob(ctx context.Context, in *CreateTrainingJobReq, opts ...grpc.CallOption) (*CreateTrainingJobResp, error) - // DeleteTrainingJobConfig 删除训练作业 + // DeleteTrainingJobConfig 删除训练作业 DeleteTrainingJob(ctx context.Context, in *DeleteTrainingJobReq, opts ...grpc.CallOption) (*DeleteTrainingJobResp, error) - // CreateTrainingJobConfig 创建训练作业参数 + // CreateTrainingJobConfig 创建训练作业参数 CreateTrainingJobConfig(ctx context.Context, in *CreateTrainingJobConfigReq, opts ...grpc.CallOption) (*CreateTrainingJobConfigResp, error) - // DeleteTrainingJobConfig 删除训练作业参数 + // DeleteTrainingJobConfig 删除训练作业参数 DeleteTrainingJobConfig(ctx context.Context, in *DeleteTrainingJobConfigReq, opts ...grpc.CallOption) (*DeleteTrainingJobConfigResp, error) - // ListTrainingJobConfig 查询训练作业参数 + // ListTrainingJobConfig 查询训练作业参数 ListTrainingJobConfig(ctx context.Context, in *ListTrainingJobConfigReq, opts ...grpc.CallOption) (*ListTrainingJobConfigResp, error) - // CreateAlgorithm 创建算法 + // CreateAlgorithm 创建算法 CreateAlgorithm(ctx context.Context, in *CreateAlgorithmReq, opts ...grpc.CallOption) (*CreateAlgorithmResp, error) - // ListAlgorithms 查询算法 + // ListAlgorithms 查询算法 ListAlgorithms(ctx context.Context, in *ListAlgorithmsReq, opts ...grpc.CallOption) (*ListAlgorithmsResp, error) - // DeleteAlgorithms 删除算法 + // DeleteAlgorithms 删除算法 DeleteAlgorithms(ctx context.Context, in *DeleteAlgorithmsReq, opts ...grpc.CallOption) (*DeleteAlgorithmsResp, error) - // ShowAlgorithmByUuid 展示算法详情 + // ShowAlgorithmByUuid 展示算法详情 ShowAlgorithmByUuid(ctx context.Context, in *ShowAlgorithmByUuidReq, opts ...grpc.CallOption) (*ShowAlgorithmByUuidResp, error) //export task ExportTask(ctx context.Context, in *ExportTaskReq, opts ...grpc.CallOption) (*ExportTaskResp, error) GetExportTasksOfDataset(ctx context.Context, in *GetExportTasksOfDatasetReq, opts ...grpc.CallOption) (*GetExportTasksOfDatasetResp, error) GetExportTaskStatusOfDataset(ctx context.Context, in *GetExportTaskStatusOfDatasetReq, opts ...grpc.CallOption) (*GetExportTaskStatusOfDatasetResp, error) - // processor task + //processor task CreateProcessorTask(ctx context.Context, in *CreateProcessorTaskReq, opts ...grpc.CallOption) (*CreateProcessorTaskResp, error) DescribeProcessorTask(ctx context.Context, in *DescribeProcessorTaskReq, opts ...grpc.CallOption) (*DescribeProcessorTaskResp, error) - // model management + //model management CreateModel(ctx context.Context, in *CreateModelReq, opts ...grpc.CallOption) (*CreateModelResp, error) DeleteModel(ctx context.Context, in *DeleteModelReq, opts ...grpc.CallOption) (*DeleteModelResp, error) ListModels(ctx context.Context, in *ListModelReq, opts ...grpc.CallOption) (*ListModelResp, error) ShowModels(ctx context.Context, in *ShowModelReq, opts ...grpc.CallOption) (*ShowModelResp, error) - // service management + //service management CreateService(ctx context.Context, in *CreateServiceReq, opts ...grpc.CallOption) (*CreateServiceResp, error) ListServices(ctx context.Context, in *ListServicesReq, opts ...grpc.CallOption) (*ListServicesResp, error) ShowService(ctx context.Context, in *ShowServiceReq, opts ...grpc.CallOption) (*ShowServiceResp, error) DeleteService(ctx context.Context, in *DeleteServiceReq, opts ...grpc.CallOption) (*DeleteServiceResp, error) ListClusters(ctx context.Context, in *ListClustersReq, opts ...grpc.CallOption) (*ListClustersResp, error) - // notebook task + //notebook task ListNotebook(ctx context.Context, in *ListNotebookReq, opts ...grpc.CallOption) (*ListNotebookResp, error) CreateNotebook(ctx context.Context, in *CreateNotebookReq, opts ...grpc.CallOption) (*CreateNotebookResp, error) StartNotebook(ctx context.Context, in *StartNotebookReq, opts ...grpc.CallOption) (*StartNotebookResp, error) StopNotebook(ctx context.Context, in *StopNotebookReq, opts ...grpc.CallOption) (*StopNotebookResp, error) GetNotebookStorage(ctx context.Context, in *GetNotebookStorageReq, opts ...grpc.CallOption) (*GetNotebookStorageResp, error) MountNotebookStorage(ctx context.Context, in *MountNotebookStorageReq, opts ...grpc.CallOption) (*MountNotebookStorageResp, error) - // visualization-jobs + //visualization-jobs GetVisualizationJob(ctx context.Context, in *GetVisualizationJobReq, opts ...grpc.CallOption) (*GetVisualizationJobResp, error) CreateVisualizationJob(ctx context.Context, in *CreateVisualizationJobReq, opts ...grpc.CallOption) (*CreateVisualizationJobResp, error) } @@ -438,64 +438,64 @@ func (c *modelArtsClient) CreateVisualizationJob(ctx context.Context, in *Create // All implementations must embed UnimplementedModelArtsServer // for forward compatibility type ModelArtsServer interface { - // get modelarts Token + //get modelarts Token GetToken(context.Context, *TokenReq) (*TokenResp, error) - // get modelarts Token + //get modelarts Token GetDatasetList(context.Context, *DataSetReq) (*DataSetResp, error) - // create DateSet + //create DateSet CreateDataSet(context.Context, *CreateDataSetReq) (*CreateDataSetResq, error) - // create DateSet + //create DateSet DeleteDataSet(context.Context, *DeleteDataSetReq) (*DeleteDataSetResq, error) - // creat task 创建导入任务 + //creat task 创建导入任务 CreateTask(context.Context, *ImportTaskDataReq) (*ImportTaskDataResp, error) - // get taskList 查询数据集导入任务列表 + //get taskList 查询数据集导入任务列表 GetImportTaskList(context.Context, *ListImportTasksReq) (*ListImportTasksResp, error) - // ListTrainingJobs 查询训练作业列表 + // ListTrainingJobs 查询训练作业列表 GetListTrainingJobs(context.Context, *ListTrainingJobsreq) (*ListTrainingJobsresp, error) - // CreateTrainingJob 创建训练作业 + // CreateTrainingJob 创建训练作业 CreateTrainingJob(context.Context, *CreateTrainingJobReq) (*CreateTrainingJobResp, error) - // DeleteTrainingJobConfig 删除训练作业 + // DeleteTrainingJobConfig 删除训练作业 DeleteTrainingJob(context.Context, *DeleteTrainingJobReq) (*DeleteTrainingJobResp, error) - // CreateTrainingJobConfig 创建训练作业参数 + // CreateTrainingJobConfig 创建训练作业参数 CreateTrainingJobConfig(context.Context, *CreateTrainingJobConfigReq) (*CreateTrainingJobConfigResp, error) - // DeleteTrainingJobConfig 删除训练作业参数 + // DeleteTrainingJobConfig 删除训练作业参数 DeleteTrainingJobConfig(context.Context, *DeleteTrainingJobConfigReq) (*DeleteTrainingJobConfigResp, error) - // ListTrainingJobConfig 查询训练作业参数 + // ListTrainingJobConfig 查询训练作业参数 ListTrainingJobConfig(context.Context, *ListTrainingJobConfigReq) (*ListTrainingJobConfigResp, error) - // CreateAlgorithm 创建算法 + // CreateAlgorithm 创建算法 CreateAlgorithm(context.Context, *CreateAlgorithmReq) (*CreateAlgorithmResp, error) - // ListAlgorithms 查询算法 + // ListAlgorithms 查询算法 ListAlgorithms(context.Context, *ListAlgorithmsReq) (*ListAlgorithmsResp, error) - // DeleteAlgorithms 删除算法 + // DeleteAlgorithms 删除算法 DeleteAlgorithms(context.Context, *DeleteAlgorithmsReq) (*DeleteAlgorithmsResp, error) - // ShowAlgorithmByUuid 展示算法详情 + // ShowAlgorithmByUuid 展示算法详情 ShowAlgorithmByUuid(context.Context, *ShowAlgorithmByUuidReq) (*ShowAlgorithmByUuidResp, error) //export task ExportTask(context.Context, *ExportTaskReq) (*ExportTaskResp, error) GetExportTasksOfDataset(context.Context, *GetExportTasksOfDatasetReq) (*GetExportTasksOfDatasetResp, error) GetExportTaskStatusOfDataset(context.Context, *GetExportTaskStatusOfDatasetReq) (*GetExportTaskStatusOfDatasetResp, error) - // processor task + //processor task CreateProcessorTask(context.Context, *CreateProcessorTaskReq) (*CreateProcessorTaskResp, error) DescribeProcessorTask(context.Context, *DescribeProcessorTaskReq) (*DescribeProcessorTaskResp, error) - // model management + //model management CreateModel(context.Context, *CreateModelReq) (*CreateModelResp, error) DeleteModel(context.Context, *DeleteModelReq) (*DeleteModelResp, error) ListModels(context.Context, *ListModelReq) (*ListModelResp, error) ShowModels(context.Context, *ShowModelReq) (*ShowModelResp, error) - // service management + //service management CreateService(context.Context, *CreateServiceReq) (*CreateServiceResp, error) ListServices(context.Context, *ListServicesReq) (*ListServicesResp, error) ShowService(context.Context, *ShowServiceReq) (*ShowServiceResp, error) DeleteService(context.Context, *DeleteServiceReq) (*DeleteServiceResp, error) ListClusters(context.Context, *ListClustersReq) (*ListClustersResp, error) - // notebook task + //notebook task ListNotebook(context.Context, *ListNotebookReq) (*ListNotebookResp, error) CreateNotebook(context.Context, *CreateNotebookReq) (*CreateNotebookResp, error) StartNotebook(context.Context, *StartNotebookReq) (*StartNotebookResp, error) StopNotebook(context.Context, *StopNotebookReq) (*StopNotebookResp, error) GetNotebookStorage(context.Context, *GetNotebookStorageReq) (*GetNotebookStorageResp, error) MountNotebookStorage(context.Context, *MountNotebookStorageReq) (*MountNotebookStorageResp, error) - // visualization-jobs + //visualization-jobs GetVisualizationJob(context.Context, *GetVisualizationJobReq) (*GetVisualizationJobResp, error) CreateVisualizationJob(context.Context, *CreateVisualizationJobReq) (*CreateVisualizationJobResp, error) mustEmbedUnimplementedModelArtsServer() diff --git a/adaptor/PCM-CORE/api/desc/ai/pcm-ai.api b/adaptor/PCM-CORE/api/desc/ai/pcm-ai.api index 32938a9..037558d 100644 --- a/adaptor/PCM-CORE/api/desc/ai/pcm-ai.api +++ b/adaptor/PCM-CORE/api/desc/ai/pcm-ai.api @@ -1,9 +1,1509 @@ syntax = "v1" info( - title: "type title here" - desc: "type desc here" - author: "type author here" - email: "type email here" - version: "type version here" + title: "AI core" + desc: "AI core微服务" + author: "wanqgi" + email: "1364512070@qq.com" ) +/******************find datasetList start*************************/ + +type DataSets { + DatasetId string `json:"dataset_id" copier:"DatasetId"` + DataFormat string `json:"data_format" copier:"DataFormat"` + DataSources []DataSources `json:"data_sources" copier:"DataSources"` + DatasetFormat int32 `json:"dataset_format" copier:"DatasetFormat"` + DatasetName string `json:"dataset_name" copier:"DatasetName"` + DatasetType int32 `json:"dataset_type" copier:"DatasetType"` + ImportData bool `json:"import_data" copier:"ImportData"` +} + +type DataSources { + DataPath string `json:"data_path" copier:"DataPath"` + DataType int32 `json:"data_type" copier:"DataType"` +} + +type ( + DataSetReq { + ProjectId string `json:"projectId" copier:"ProjectId"` + } + DataSetResp { + TotalNumber uint32 `json:"total_number" copier:"TotalNumber"` + Datasets []DataSets `json:"data_sets" copier:"Datasets"` + } +) + +/******************find datasetList end*************************/ + +/******************Create dataset start*************************/ + +type CreateDataSetReq { + DatasetId string `json:"datasetId"` + DatasetType int32 `json:"datasetType"` + Description string `json:"description"` + WorkPath string `json:"workPath"` + DatasetName string `json:"datasetName"` + WorkPathType string `json:"workPathType"` + ProjectId string `json:"projectId"` + DataSources []DataSources `json:"DataSources"` +} + +type CreateDataSetResp { + Dataset_id string `json:"datasetId"` +} + +/******************Create dataset end*************************/ +/******************ImportTask start*************************/ +type ( + ImportTaskDataReq { + ProjectId string `json:"projectId"` + DatasetId string `json:"datasetId"` + ImportPath string `json:"importPath"` + } + ImportTaskDataResp200 { + TaskId string `json:"taskId,omitempty"` + } + ImportTaskDataResp400 { + ErrorMsg string `json:"errorMsg,omitempty"` + ErrorCode string `json:"errorCode,omitempty"` + ErrorSolution string `json:"errorSolution,omitempty"` + } + ImportTaskDataResp { + Resp200 ImportTaskDataResp200 `json:"resp200,omitempty"` + Resp400 ImportTaskDataResp400 `json:"resp400,omitempty"` + } +) +/******************ImportTask end*************************/ + +/******************ExportTask start*************************/ +type ( + CreateExportTaskReq { + ProjectId string `json:"projectId,optional" copier:"ProjectId"` + DatasetId string `json:"datasetId,optional" copier:"DatasetId"` + Path string `json:"path,optional" copier:"Path"` + AnnotationFormat string `json:"annotationFormat,optional" copier:"AnnotationFormat"` + ExportFormat int64 `json:"exportFormat,optional" copier:"ExportFormat"` + ExportParams ExportParams `json:"exportParams,optional" copier:"ExportParams"` + ExportType int32 `json:"exportType,optional" copier:"ExportType"` + SampleState string `json:"sampleState,optional" copier:"ExportState"` + SourceTypeHeader string `json:"sourceTypeHeader,optional" copier:"SourceTypeHeader"` + Status int32 `json:"status,optional" copier:"Status"` + VersionFormat string `json:"versionFormat,optional" copier:"VersionFormat"` + VersionId string `json:"versionId,optional" copier:"VersionId"` + WithColumnHeader bool `json:"withColumnHeader,optional" copier:"WithColumnHeader"` + } + CreateExportTaskResp { + Resp200 ExportTaskDataResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 ExportTaskDataResp400 `json:"resp400,omitempty" copier:"Resp400"` + } +) +type ExportTaskDataResp200 { + TaskId string `json:"task_id,optional" copier:"TaskId"` + CreateTime uint32 `json:"create_time,optional" copier:"CreateTime"` + ExportFormat int64 `json:"export_format,optional" copier:"ExportFormat"` + ExportParams ExportParams `json:"export_params,optional" copier:"ExportParams"` + FinishedSampleCount int32 `json:"finished_sample_count,optional" copier:"FinishedSampleCount"` + Path string `json:"path,optional" copier:"Path"` + Progress float64 `json:"progress,optional" copier:"Progress"` + Status string `json:"status,optional" copier:"Status"` + TotalSampleCount int64 `json:"total_sample_count,optional" copier:"TotalSampleCount"` + UpdateTime uint32 `json:"update_time,optional" copier:"UpdateTime"` + VersionFormat string `json:"version_format,optional" copier:"VersionFormat"` + VersionId string `json:"version_id,optional" copier:"VersionId"` +} +type ExportTaskDataResp400 { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} +type ExportParams { + ClearHardProperty bool `json:"clear_hard_property" copier:"ClearHardProperty"` + ExportDatasetVersionFormat string `json:"export_dataset_version_format,optional" copier:"ExportDatasetVersionFormat"` + ExportDatasetVersionName string `json:"export_dataset_version_name,optional" copier:"ExportDatasetVersionName"` + ExportDest string `json:"export_dest,optional" copier:"ExportDest"` + ExportNewDatasetWorkName string `json:"export_new_dataset_work_name,optional" copier:"ExportNewDatasetWorkName"` + ExportNewDatasetWorkPath string `json:"export_new_dataset_work_path,optional" copier:"ExportNewDatasetWorkPath"` + RatioSampleUsage bool `json:"ratio_sample_usage,optional" copier:"RatioSampleUsage"` + SampleState string `json:"sample_state,optional" copier:"SampleState"` + Sample []string `json:"sample,optional" copier:"Sample"` + SearchConditions []SearchCondition `json:"search_conditions,optional" copier:"SearchConditions"` + TrainSampleRatio string `json:"train_sample_ratio,optional" copier:"TrainSampleRatio"` +} + +type SearchCondition { + Coefficient string `json:"coefficient,optional" copier:"Coefficient"` + FrameInVideo int64 `json:"frame_in_video,optional" copier:"FrameInVideo"` + Hard string `json:"coefficient,optional" copier:"Hard"` + Kvp string `json:"kvp,optional" copier:"Kvp"` + ImportOrigin string `json:"import_origin,optional" copier:"ImportOrigin"` + LabelList SearchLabels `json:"label_list,optional" copier:"LabelList"` + Labeler string `json:"labeler,optional" copier:"Labeler"` + ParentSampleId string `json:"parent_sample_id,optional" copier:"ParentSampleId"` + Metadata SearchProp `json:"metadata,optional" copier:"Metadata"` + SampleDir string `json:"sample_dir,optional" copier:"SampleDir"` + SampleName string `json:"sample_name,optional" copier:"SampleName"` + SampleTime string `json:"sample_time,optional" copier:"SampleTime"` + Score string `json:"score,optional" copier:"Score"` + SliceThickness string `json:"slice_thickness,optional" copier:"SliceThickness"` + StudyDate string `json:"StudyDate,optional" copier:"StudyDate"` + TimeInVideo string `json:"time_in_video,optional" copier:"TimeInVideo"` +} +type SearchLabels { + Labels []SearchLabel `json:"labels,optional" copier:"Labels"` + Op string `json:"op,optional" copier:"Op"` +} +type SearchLabel { + Name string `json:"name,optional" copier:"Name"` + Op string `json:"op,optional" copier:"Op"` + // Property map `json:"property,optional" copier:"Property"` + Type int64 `json:"type,optional" copier:"Type"` +} +type SearchProp { + Op string `json:"op,optional" copier:"Op"` +} +/******************ExportTask end*************************/ + +/******************Get Export Tasks Of Dataset Start*************************/ +type ( + GetExportTasksOfDatasetReq { + ProjectId string `json:"project_id" copier:"ProjectId"` + DatasetId string `json:"dataset_id" copier:"DatasetId"` + ExportType int32 `json:"export_type,optional" copier:"ExportType"` + Limit int32 `json:"limit,optional" copier:"Limit"` + Offset int32 `json:"offset,optional" copier:"Offset"` + } + GetExportTasksOfDatasetResp { + Resp200 GetExportTasksOfDatasetResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 GetExportTasksOfDatasetResp400 `json:"resp400,omitempty" copier:"Resp400"` + } +) +type GetExportTasksOfDatasetResp200 { + TaskId string `json:"taskId,omitempty" copier:"TaskId"` + CreateTime uint32 `json:"create_time,omitempty" copier:"CreateTime"` + ExportFormat int64 `json:"export_format,omitempty" copier:"ExportFormat"` + ExportParams ExportParams `json:"export_params,omitempty" copier:"ExportParams"` + ExportTasks []ExportTaskStatus `json:"export_tasks,omitempty" copier:"ExportTasks"` + FinishedSampleCount int32 `json:"finished_sample_count,omitempty" copier:"FinishedSampleCount"` + Path string `json:"path,omitempty" copier:"Path"` + Progress float64 `json:"progress,omitempty" copier:"Progress"` + Status string `json:"status,omitempty" copier:"Status"` + TotalCount int64 `json:"total_count,omitempty" copier:"TotalCount"` + UpdateTime uint32 `json:"update_time,omitempty" copier:"UpdateTime"` + VersionFormat string `json:"version_format,omitempty" copier:"VersionFormat"` + VersionId string `json:"version_id,omitempty" copier:"VersionId"` + ExportType int32 `json:"export_type,omitempty" copier:"ExportType"` + TotalSample int64 `json:"total_sample,omitempty" copier:"TotalSample"` +} +type GetExportTasksOfDatasetResp400 { + ErrorCode string `json:"error_code,omitempty" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,omitempty" copier:"ErrorMsg"` +} +type ExportTaskStatus { + TaskId string `json:"taskId,omitempty" copier:"TaskId"` + CreateTime uint32 `json:"create_time,omitempty" copier:"CreateTime"` + ErrorCode string `json:"error_code,omitempty" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,omitempty" copier:"ErrorMsg"` + ExportFormat int64 `json:"export_format,omitempty" copier:"ExportFormat"` + ExportParams ExportParams `json:"export_params,omitempty" copier:"ExportParams"` + FinishedSampleCount int32 `json:"finished_sample_count,omitempty" copier:"FinishedSampleCount"` + Path string `json:"path,omitempty" copier:"Path"` + Progress float64 `json:"progress,omitempty" copier:"Progress"` + Status string `json:"status,omitempty" copier:"Status"` + TotalCount int64 `json:"total_count,omitempty" copier:"TotalCount"` + UpdateTime uint32 `json:"update_time,omitempty" copier:"UpdateTime"` + VersionFormat string `json:"version_format,omitempty" copier:"VersionFormat"` + VersionId string `json:"version_id,omitempty" copier:"VersionId"` + ExportType int32 `json:"export_type,omitempty" copier:"ExportType"` + TotalSample int64 `json:"total_sample,omitempty" copier:"TotalSample"` +} +/******************Get Export Tasks Of Dataset End*************************/ + +/******************Get Export Task Status Of Dataset Start*************************/ +type ( + GetExportTaskStatusOfDatasetReq { + ProjectId string `json:"project_id" copier:"ProjectId"` + ResourceId string `json:"resource_id" copier:"ResourceId"` + TaskId string `json:"task_id,optional" copier:"TaskId"` + } + GetExportTaskStatusOfDatasetResp { + Resp200 GetExportTaskStatusOfDatasetResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 GetExportTaskStatusOfDatasetResp400 `json:"resp400,omitempty" copier:"Resp400"` + } +) +type GetExportTaskStatusOfDatasetResp200 { + TaskId string `json:"taskId,optional" copier:"TaskId"` + CreateTime uint32 `json:"create_time,optional" copier:"CreateTime"` + ExportFormat int64 `json:"export_format,optional" copier:"ExportFormat"` + ExportParams ExportParams `json:"export_params,optional" copier:"ExportParams"` + ExportTasks []ExportTaskStatus `json:"export_tasks,optional" copier:"ExportTasks"` + FinishedSampleCount int32 `json:"finished_sample_count,optional" copier:"FinishedSampleCount"` + Path string `json:"path,optional" copier:"Path"` + Progress float64 `json:"progress,optional" copier:"Progress"` + Status string `json:"status,optional" copier:"Status"` + TotalCount int64 `json:"total_count,optional" copier:"TotalCount"` + UpdateTime uint32 `json:"update_time,optional" copier:"UpdateTime"` + VersionFormat string `json:"version_format,optional" copier:"VersionFormat"` + VersionId string `json:"version_id,optional" copier:"VersionId"` + ExportType int32 `json:"export_type,optional" copier:"ExportType"` + TotalSample int64 `json:"total_sample,optional" copier:"TotalSample"` +} +type GetExportTaskStatusOfDatasetResp400 { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} +/******************Get Export Task Status Of Dataset End*************************/ + +/******************Create Processor Task Start*************************/ +type ( + CreateProcessorTaskReq { + ProjectId string `json:"dataset_id" copier:"ProjectId"` + CreateVersion bool `json:"create_version,optional" copier:"CreateVersion"` + Description string `json:"description,optional" copier:"Description"` + DataSources ProcessorDataSource `json:"data_source,optional" copier:"DataSources"` + Inputs []ProcessorDataSource `json:"inputs,optional" copier:"Inputs"` + Name string `json:"name,optional" copier:"Nmae"` + Template TemplateParam `json:"template,optional" copier:"Template"` + VersionId string `json:"version_id,optional" copier:"VersionId"` + WorkPath WorkPath `json:"work_path,optional" copier:"WorkPath"` + WorkspaceId string `json:"workspace_id,optional" copier:"WorkspaceId"` + } + CreateProcessorTaskResp { + TaskId string `json:"taskId,optional" copier:"Code"` + Code int32 `json:"code,optional" copier:"Code"` + Msg string `json:"msg,optional" copier:"Msg"` + } +) +type ProcessorDataSource { + Name string `json:"name,optional" copier:"Name"` + Source string `json:"source,optional" copier:"Source"` + Type string `json:"type,optional" copier:"type"` + VersionId string `json:"version_id,optional" copier:"VersionId"` + VersionName string `json:"version_name,optional" copier:"VersionName"` +} +type TemplateParam { + Id string `json:"id,optional" copier:"Id"` + Name string `json:"name,optional" copier:"Name"` + OperatorParam []OperatorParam `json:"operator_params,optional" copier:"OperatorParam"` +} +type WorkPath { + Name string `json:"name,optional" copier:"name"` + OutputPath string `json:"output_path,optional" copier:"OutputPath"` + Path string `json:"path,optional" copier:"Path"` + Type string `json:"type,optional" copier:"type"` + VersionId string `json:"version_id,optional" copier:"VersionId"` + VersionName string `json:"version_name,optional" copier:"VersionName"` +} +type OperatorParam { + Id string `json:"id,optional" copier:"Id"` + Name string `json:"name,optional" copier:"Name"` + Params string `json:"params,optional" copier:"Params"` + AdvancedParamsSwitch bool `json:"advanced_params_switch,optional" copier:"AdvancedParamsSwitch"` +} +/******************Create Processor Task End*************************/ + +/******************taskList start*************************/ +type ( + ListImportTasksReq { + ProjectId string `json:"projectId"` + DatasetId string `json:"datasetId"` + Limit int32 `json:"limit,optional"` + Offset int32 `json:"offset,optional"` + } + ListImportTasksResp { + Resp200 *ListImportTasksResp200 `json:"resp200,omitempty"` + Resp400 *ListImportTasksResp400 `json:"resp400,omitempty"` + } + ListImportTasksResp200 { + TotalCount uint32 `json:"totalCount,omitempty"` + ImportTasks []ImportTasks `json:"importTasks,omitempty"` + } + ListImportTasksResp400 { + ErrorMsg string `json:"errorMsg,omitempty"` + ErrorCode string `json:"errorCode,omitempty"` + ErrorSolution string `json:"errorSolution,omitempty"` + } +) +type ImportTasks { + Status string `json:"status,omitempty"` + TaskId string `json:"task_id,omitempty"` + DatasetId string `json:"dataset_id,omitempty"` + ImportPath string `json:"import_path,omitempty"` + ImportType int32 `json:"import_type,omitempty"` + TotalSampleCount uint32 `json:"total_sample_count,omitempty"` + ImportedSampleCount uint32 `json:"imported_sample_count,omitempty"` + AnnotatedSampleCount uint32 `json:"annotated_sample_count,omitempty"` + TotalSubSampleCount uint32 `json:"total_sub_sample_count,omitempty"` + ImportedSubSampleCount uint32 `json:"imported_sub_sample_count,omitempty"` + TotalFileSize uint32 `json:"total_file_size,omitempty"` + FinishedFileCount uint32 `json:"finished_file_count,omitempty"` + FinishedFileSize uint32 `json:"finished_file_size,omitempty"` + TotalFileCount uint32 `json:"total_file_count,omitempty"` + CreateTime uint32 `json:"create_time,omitempty"` + ElapsedTime uint32 `json:"elapsed_time,omitempty"` + AnnotationFormatConfig []interface{} `json:"annotation_format_config"` +} +/******************taskList end*************************/ +/******************ListTrainingJobs start*************************/ +type Annotations { + JobTemplate string `json:"job_template"` + KeyTask string `json:"key_task"` +} +type TrainingExperimentReference { +} +type Metadata { + ID string `json:"id"` + Name string `json:"name"` + Description string `json:"description"` + CreateTime uint32 `json:"create_time"` + WorkspaceID string `json:"workspace_id"` + AiProject string `json:"ai_project"` + UserName string `json:"user_name"` + Annotations Annotations `json:"annotations"` + TrainingExperimentReference TrainingExperimentReference `json:"training_experiment_reference"` + Tags []interface{} `json:"tags"` +} +type CPUUsage { + Average int32 `json:"average"` + Max int32 `json:"max"` + Min int32 `json:"min"` +} +type MemUsage { + Average int32 `json:"average"` + Max int32 `json:"max"` + Min int32 `json:"min"` +} +type Util { + Average int32 `json:"average"` + Max int32 `json:"max"` + Min int32 `json:"min"` +} +type Gpu { + MemUsage MemUsage `json:"mem_usage"` + Util Util `json:"util"` + UnitNum int32 `json:"unit_num"` + ProductName string `json:"product_name"` + Memory string `json:"memory"` +} +type Status { + Phase string `json:"phase"` + SecondaryPhase string `json:"secondaryPhase"` + Duration int32 `json:"duration"` + Tasks []string `json:"tasks"` + StartTime uint64 `json:"startTime"` + TaskStatuses []*TaskStatuses `json:"taskStatuses,omitempty"` + // NodeCountMetrics []NodeCountMetrics[]interface{} `json:"node_count_metrics"` +} +type TaskStatuses { + Task string `json:"task,omitempty"` + ExitCode string `json:"exitCode,omitempty"` + Message string `json:"message,omitempty"` +} + +type Constraint { + Type string `json:"type"` + Editable bool `json:"editable"` + Required bool `json:"required"` + Sensitive bool `json:"sensitive"` + ValidType string `json:"valid_type"` + ValidRange interface{} `json:"valid_range,optional"` +} +type Parameters { + Name string `json:"name"` + Description string `json:"description"` + I18NDescription interface{} `json:"i18n_description"` + Value string `json:"value"` + Constraint Constraint `json:"constraint"` +} +type Obs { + ObsURL string `json:"obs_url"` +} +type Remote { + Obs Obs `json:"obs"` +} +type Attributes { + DataFormat []string `json:"data_format"` + DataSegmentation []string `json:"data_segmentation"` + DatasetType []string `json:"dataset_type"` + IsFree string `json:"is_free"` + MaxFreeJobCount string `json:"max_free_job_count"` +} +type RemoteConstraints { + DataType string `json:"dataType"` + Attributes Attributes `json:"attributes,omitempty"` +} +type Inputs { + Name string `json:"name"` + Description string `json:"description"` + LocalDir string `json:"local_dir"` + AccessMethod string `json:"access_method"` + Remote Remote `json:"remote"` + RemoteConstraints []RemoteConstraints `json:"remote_constraints"` +} +type Outputs { + Name string `json:"name"` + LocalDir string `json:"local_dir"` + AccessMethod string `json:"access_method"` + Remote Remote `json:"remote"` + Mode string `json:"mode"` + Period int32 `json:"period"` + PrefetchToLocal bool `json:"prefetch_to_local"` +} +type Engine { + EngineID string `json:"engine_id"` + EngineName string `json:"engine_name"` + EngineVersion string `json:"engine_version"` + V1Compatible bool `json:"v1_compatible"` + RunUser string `json:"run_user"` + ImageSource bool `json:"image_source"` +} +type Policies { +} +type Algorithm { + ID string `json:"id"` + Name string `json:"name"` + V1Algorithm bool `json:"v1_algorithm"` + SubscriptionID string `json:"subscription_id"` + ItemVersionID string `json:"item_version_id"` + ContentID string `json:"content_id"` + Parameters []Parameters `json:"parameters"` + ParametersCustomization bool `json:"parameters_customization"` + Inputs []Inputs `json:"inputs"` + Outputs []Outputs `json:"outputs"` + Engine Engine `json:"engine"` + Policies Policies `json:"policies"` +} +type Billing { + Code string `json:"code"` + UnitNum int32 `json:"unit_num"` +} +type CPU { + Arch string `json:"arch"` + CoreNum int32 `json:"core_num"` +} +type Memory { + Size int `json:"size"` + Unit string `json:"unit"` +} +type Disk { + Size int32 `json:"size"` + Unit string `json:"unit"` +} +type FlavorInfo { + CPU CPU `json:"cpu"` + Gpu Gpu `json:"gpu"` + Memory Memory `json:"memory"` + Disk Disk `json:"disk"` +} +type FlavorDetail { + FlavorType string `json:"flavor_type"` + Billing Billing `json:"billing"` + Attributes Attributes `json:"attributes"` + FlavorInfo FlavorInfo `json:"flavor_info"` +} +type Resource { + Policy string `json:"policy,optional"` + FlavorId string `json:"flavor_id,optional"` + FlavorName string `json:"flavor_name,optional"` + NodeCount int32 `json:"node_count,optional"` + FlavorDetail FlavorDetail `json:"flavor_detail,optional"` +} +type LogExportPathCreateTraining { +} +type Spec { + Resource Resource `json:"resource"` + LogExportPath LogExportPath `json:"log_export_path"` + IsHostedLog bool `json:"is_hosted_log"` +} +type Items { + Kind string `json:"kind"` + Metadata Metadata `json:"metadata"` + Status Status `json:"status"` + Algorithm Algorithm `json:"algorithm,omitempty"` + Spec Spec `json:"spec"` +} +type ( + ListTrainingJobsreq { + ProjectId string `json:"projectId"` + } + ListTrainingJobsresp { + Resp200 *ListTrainingJobsresp200 `json:"resp200,omitempty"` + Resp400 *ListTrainingJobsresp400 `json:"resp400,omitempty"` + } + ListTrainingJobsresp200 { + Total int32 `json:"total"` + Count int32 `json:"count"` + Limit int32 `json:"limit"` + Offset int32 `json:"offset"` + SortBy string `json:"sort_by"` + Order string `json:"order"` + GroupBy string `json:"group_by"` + WorkspaceID string `json:"workspace_id"` + AiProject string `json:"ai_project"` + Items []Items `json:"items"` + } + ListTrainingJobsresp400 { + ErrorMsg string `json:"errorMsg,omitempty"` + ErrorCode string `json:"errorCode,omitempty"` + ErrorSolution string `json:"errorSolution,omitempty"` + } +) +/******************ListTrainingJobs end*************************/ + +/******************DeleteTrainingJob start*************************/ +type ( + DeleteTrainingJobReq { + Project_id string `json:"projectId"` + Training_job_id string `json:"trainingJobId"` + } + DeleteTrainingJobResp { + Is_success bool `json:"isSuccess"` + Error_message string `json:"errorMessage"` + Error_code string `json:"errorCode"` + } +) +/******************DeleteTrainingJob end*************************/ + +/******************Create Service Start*************************/ +type ( + CreateServiceReq { + WorkspaceId string `json:"workspaceId,optional" copier:"WorkspaceId"` + Schedule Scheduler `json:"schedule,optional" copier:"Schedule"` + ClusterId string `json:"clusterId,optional" copier:"ClusterId"` + InferType string `json:"inferType,optional" copier:"InferType"` + VpcId string `json:"vpcId,optional" copier:"VpcId"` + ServiceName string `json:"serviceName,optional" copier:"ServiceName"` + Description string `json:"description,optional" copier:"Description"` + SecurityGroupId string `json:"securityGroupId,optional" copier:"SecurityGroupId"` + SubnetNetworkId string `json:"subnetNetworkId,optional" copier:"SubnetNetworkId"` + Config []ServiceConfig `json:"config,optional" copier:"Config"` + ProjectId string `json:"projectId,optional" copier:"ProjectId"` + } + CreateServiceResp { + Resp200 CreateServiceResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 CreateServiceResp400 `json:"resp400,omitempty" copier:"Resp400"` + } +) +type CreateServiceResp200 { + ServiceId string `json:"service_id,omitempty" copier:"ServiceId"` + ResourceIds []string `json:"resource_ids,omitempty" copier:"ResourceIds"` +} +type CreateServiceResp400 { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type Scheduler { + Duration int32 `json:"duration,optional" copier:"Duration"` + TimeUnit string `json:"timeUnit,optional" copier:"TimeUnit"` + Type string `json:"type,optional" copier:"Type"` +} + +type ServiceConfig { + CustomSpec CustomSpec `json:"customSpec,optional" copier:"CustomSpec"` + Envs map[string]string `json:"envs,optional" copier:"Envs"` + Specification string `json:"specification,optional" copier:"Specification"` + Weight int32 `json:"weight,optional" copier:"Weight"` + ModelId string `json:"modelId,optional" copier:"ModelId"` + SrcPath string `json:"srcPath,optional" copier:"SrcPath"` + ReqUri string `json:"reqUri,optional" copier:"ReqUri"` + MappingType string `json:"mappingType,optional" copier:"MappingType"` + ClusterId string `json:"clusterId,optional" copier:"ClusterId"` + Nodes []string `json:"nodes,optional" copier:"Nodes"` + SrcType string `json:"srcType,optional" copier:"SrcType"` + DestPath string `json:"destPath,optional" copier:"DestPath"` + InstanceCount int32 `json:"instanceCount,optional" copier:"InstanceCount"` +} + +type CustomSpec { + GpuP4 float64 `json:"gpuP4,optional" copier:"GpuP4"` + Memory int64 `json:"memory,optional" copier:"Memory"` + Cpu float64 `json:"cpu,optional" copier:"Cpu"` + AscendA310 int64 `json:"ascendA310,optional" copier:"AscendA310"` +} +/******************Create Service End*************************/ + +/******************Delete Service Start*************************/ +type ( + DeleteServiceReq { + ProjectId string `json:"projectId" copier:"ProjectId"` + ServiceId string `json:"serviceId" copier:"ServiceId"` + } + DeleteServiceResp { + Resp200 DeleteServiceResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 DeleteServiceResp400 `json:"resp400,omitempty" copier:"Resp400"` + } +) + +type DeleteServiceResp200 { +} +type DeleteServiceResp400 { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} +/******************Delete Service End*************************/ + +/******************List Services Start*************************/ +type ( + ListServicesReq { + ProjectId string `json:"projectId" copier:"ProjectId"` + // ServiceId string `json:"serviceId" copier:"ServiceId"` + } + ListServicesResp { + Resp200 ListServicesResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 ListServicesResp400 `json:"resp400,omitempty" copier:"Resp400"` + } +) +type ListServicesResp200 { + TotalCount int32 `json:"total_count,omitempty" copier:"TotalCount"` + Count int32 `json:"count,omitempty" copier:"Count"` + Services []ListServices `json:"services,omitempty" copier:"Services"` +} +type ListServicesResp400 { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type ListServices { + FailedTimes uint32 `json:"failed_times,omitempty" copier:"FailedTimes"` + Owner string `json:"owner,omitempty" copier:"Owner"` + DueTime int32 `json:"due_time,omitempty" copier:"DueTime"` + FinishedTime int32 `json:"finished_time,omitempty" copier:"FinishedTime"` + InferType string `json:"infer_type,omitempty" copier:"InferType"` + ServiceName string `json:"service_name,omitempty" copier:"ServiceName"` + Description string `json:"description,omitempty" copier:"Description"` + Project string `json:"project,omitempty" copier:"Project"` + InvocationTimes uint32 `json:"invocation_times,omitempty" copier:"InvocationTimes"` + PublishAt uint32 `json:"publish_at,omitempty" copier:"PublishAt"` + WorkspaceId string `json:"workspace_id,omitempty" copier:"WorkspaceId"` + Scheduler []*Scheduler `json:"scheduler,omitempty" copier:"Scheduler"` + StartTime int32 `json:"start_time,omitempty" copier:"StartTime"` + OperationTime string `json:"operation_time,omitempty" copier:"OperationTime"` + IsShared bool `json:"is_shared,omitempty" copier:"IsShared"` + ServiceId string `json:"service_id,omitempty" copier:"ServiceId"` + Progress int32 `json:"progress,omitempty" copier:"Progress"` + SharedCount int32 `json:"shared_count,omitempty" copier:"SharedCount"` + Tenant string `json:"tenant,omitempty" copier:"Tenant"` + Status string `json:"status,omitempty" copier:"Status"` + IsOpenedSampleCollection string `json:"is_opened_sample_collection,omitempty" copier:"IsOpenedSampleCollection"` + TransitionAt int32 `json:"transition_at,omitempty" copier:"TransitionAt"` + IsFree bool `json:"is_free,omitempty" copier:"IsFree"` + AdditionalProperties map[string]string `json:"additional_properties,omitempty" copier:"AdditionalProperties"` +} +/******************List Service End*************************/ + +/******************Show Service Start*************************/ +type ( + ShowServiceReq { + ProjectId string `json:"projectId" copier:"ProjectId"` + ServiceId string `json:"serviceId" copier:"ServiceId"` + } + ShowServiceResp { + Resp200 ShowServiceResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 ShowServiceResp400 `json:"resp400,omitempty" copier:"Resp400"` + } +) + +type ShowServiceResp200 { + FailedTimes uint32 `json:"failed_times,omitempty" copier:"FailedTimes"` + Owner string `json:"owner,omitempty" copier:"Owner"` + DueTime int32 `json:"due_time,omitempty" copier:"DueTime"` + FinishedTime int32 `json:"finished_time,omitempty" copier:"FinishedTime"` + InferType string `json:"infer_type,omitempty" copier:"InferType"` + ServiceName string `json:"service_name,omitempty" copier:"ServiceName"` + Description string `json:"description,omitempty" copier:"Description"` + Project string `json:"project,omitempty" copier:"Project"` + InvocationTimes uint32 `json:"invocation_times,omitempty" copier:"InvocationTimes"` + PublishAt uint32 `json:"publish_at,omitempty" copier:"PublishAt"` + WorkspaceId string `json:"workspace_id,omitempty" copier:"WorkspaceId"` + Scheduler []Scheduler `json:"scheduler,omitempty" copier:"Scheduler"` + StartTime int32 `json:"start_time,omitempty" copier:"StartTime"` + OperationTime string `json:"operation_time,omitempty" copier:"OperationTime"` + IsShared bool `json:"is_shared,omitempty" copier:"IsShared"` + ServiceId string `json:"service_id,omitempty" copier:"ServiceId"` + Progress int32 `json:"progress,omitempty" copier:"Progress"` + SharedCount int32 `json:"shared_count,omitempty" copier:"SharedCount"` + Tenant string `json:"tenant,omitempty" copier:"Tenant"` + Status string `json:"status,omitempty" copier:"Status"` + IsOpenedSampleCollection string `json:"is_opened_sample_collection,omitempty" copier:"IsOpenedSampleCollection"` + TransitionAt int32 `json:"transition_at,omitempty" copier:"TransitionAt"` + IsFree bool `json:"is_free,omitempty" copier:"IsFree"` + AdditionalProperties map[string]string `json:"additional_properties,omitempty" copier:"AdditionalProperties"` + ClusterId string `json:"cluster_id,omitempty" copier:"ClusterId"` + VpcId string `json:"vpc_id,omitempty" copier:"VpcId"` + SubnetNetworkId string `json:"subnet_network_id,omitempty" copier:"SubnetNetworkId"` + SecurityGroupId string `json:"security_group_id,omitempty" copier:"SecurityGroupId"` + Config []QueryServiceConfig `json:"config,omitempty" copier:"Config"` + AccessAddress string `json:"access_address,omitempty" copier:"AccessAddress"` + BindAccessAddress string `json:"bind_access_address,omitempty" copier:"BindAccessAddress"` + UpdateTime string `json:"update_time,omitempty" copier:"UpdateTime"` + DebugUrl string `json:"debug_url,omitempty" copier:"DebugUrl"` +} + +type ShowServiceResp400 { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type QueryServiceConfig { + ModelVersion string `json:"model_version,omitempty" copier:"ModelVersion"` + FinishedTime string `json:"finished_time,omitempty" copier:"FinishedTime"` + CustomSpec *CustomSpec `json:"CustomSpec,omitempty" copier:"CustomSpec"` + Envs map[string]string `json:"envs,omitempty" copier:"Envs"` + Specification string `json:"specification,omitempty" copier:"Specification"` + Weight int32 `json:"weight,omitempty" copier:"Weight"` + ModelId string `json:"model_id,omitempty" copier:"ModelId"` + SrcPath string `json:"src_path,omitempty" copier:"SrcPath"` + ReqUri string `json:"req_uri,omitempty" copier:"ReqUri"` + MappingType string `json:"mapping_type,omitempty" copier:"MappingType"` + StartTime string `json:"start_time,omitempty" copier:"StartTime"` + ClusterId string `json:"cluster_id,omitempty" copier:"ClusterId"` + Nodes []string `json:"nodes,omitempty" copier:"Nodes"` + MappingRule string `json:"mapping_rule,omitempty" copier:"MappingRule"` + ModelName string `json:"model_name,omitempty" copier:"ModelName"` + SrcType string `json:"src_type,omitempty" copier:"SrcType"` + DestPath string `json:"dest_path,omitempty" copier:"DestPath"` + InstanceCount int32 `json:"instance_count,omitempty" copier:"InstanceCount"` + Status string `json:"status,omitempty" copier:"Status"` + Scaling bool `json:"scaling,omitempty" copier:"Scaling"` + SupportDebug bool `json:"support_debug,omitempty" copier:"SupportDebug"` + AdditionalProperties map[string]string `json:"additional_properties,omitempty" copier:"AdditionalProperties"` +} +/******************Show Service End*************************/ + +/******************List Clusters Start*************************/ +type ( + ListClustersReq { + ProjectId string `json:"project_id" copier:"ProjectId"` + ClusterName string `json:"cluster_name,optional" copier:"ClusterName"` + Offset int64 `json:"offset,optional" copier:"Offset"` + Limit int64 `json:"limit,optional" copier:"Limit"` + SortBy string `json:"sort_by,optional" copier:"SortBy"` + Order string `json:"order,optional" copier:"Order"` + } + ListClustersResp { + Resp200 ListClustersResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 ListClustersResp400 `json:"resp400,omitempty" copier:"Resp400"` + } +) + +type ListClustersResp200 { + Count int32 `json:"count,omitempty" copier:"Count"` + Clusters []Cluster `json:"clusters,omitempty" copier:"Clusters"` +} +type ListClustersResp400 { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type ClusterNode { + Specification string `json:"specification,omitempty" copier:"Specification"` + Count int32 `json:"count,omitempty" copier:"Count"` + AvailableCount int32 `json:"available_count,omitempty" copier:"AvailableCount"` +} + +type Cluster { + ClusterId string `json:"cluster_id,omitempty" copier:"ClusterId"` + ClusterName string `json:"cluster_name,omitempty" copier:"ClusterName"` + Description string `json:"description,omitempty" copier:"Description"` + Tenant string `json:"tenant,omitempty" copier:"Tenant"` + Project string `json:"project,omitempty" copier:"Project"` + Owner string `json:"owner,omitempty" copier:"Owner"` + CreatedAt int32 `json:"created_at,omitempty" copier:"CreatedAt"` + Status string `json:"status,omitempty" copier:"Status"` + Nodes ClusterNode `json:"nodes,omitempty" copier:"Nodes"` + AllocatableCpuCores float64 `json:"allocatable_cpu_cores,omitempty" copier:"AllocatableCpuCores"` + AllocatableMemory int64 `json:"allocatable_memory,omitempty" copier:"AllocatableMemory"` + PeriodNum int32 `json:"period_num,omitempty" copier:"PeriodNum"` + PeriodType string `json:"period_type,omitempty" copier:"PeriodType"` + OrderId string `json:"order_id,omitempty" copier:"OrderId"` +} +/******************List Clusters End*************************/ + +/******************ListAlgorithms start*************************/ +type AlgorithmResponse { + MetadataAlRp MetadataAlRp `json:"metadata,optional"` + JobConfigAlRp JobConfigAlRp `json:"jobConfig,optional"` + ResourceRequirementsAlRp []ResourceRequirements `json:"resourceRequirements,optional"` + AdvancedConfigAlRp AdvancedConfigAl `json:"advancedConfig,optional"` +} + +type MetadataAlRp { + Id string `json:"id,optional"` + Name string `json:"name,optional"` + Description string `json:"description,optional"` + CreateTime uint64 `json:"createTime,optional"` + WorkspaceId string `json:"workspaceId,optional"` + AiProject string `json:"aiProject,optional"` + UserName string `json:"userName,optional"` + DomainId string `json:"domainId,optional"` + Source string `json:"source,optional"` + ApiVersion string `json:"apiVersion,optional"` + IsValid bool `json:"isValid,optional"` + State string `son:"state,optional"` + Size int32 `json:"size,optional"` + + Tags []*TagsAlRp `json:"tags,optional"` + AttrList []string `json:"attrList,optional"` + VersionNum int32 `json:"versionNum,optional"` + UpdateTime uint64 `json:"updateTime,optional"` +} + +type TagsAlRp { + Tags map[string]string `json:"tags,optional"` +} + +type JobConfigAlRp { + CodeDir string `json:"codeDir,optional"` + BootFile string `json:"bootFile,optional"` + Command string `json:"command,optional"` + ParametersAlRq []ParametersAlRq `json:"parameters,optional"` + ParametersCustomization bool `json:"parameters_customization,optional"` + InputsAlRq []InputsAlRq `json:"inputs,optional"` + OutputsAl []OutputsAl `json:"outputs,optional"` + EngineAlRq EngineAlRq `json:"engine,optional"` +} +type ParametersAlRq { + Name string `json:"name,optional"` + Description string `json:"description,optional"` + I18NDescription I18NDescription `json:"i18nDescription,optional"` + Value string `json:"value,optional"` + Constraint ConstraintAlRq `json:"constraint,optional"` +} + +type I18NDescription { + Language string `json:"language,optional"` + Description string `json:"description,optional"` +} +type ConstraintAlRq { + Type string `son:"type,optional"` + Editable bool `json:"editable,optional"` + Required bool `json:"required,optional"` + Sensitive bool `json:"sensitive,optional"` + ValidType string `json:"valid_type,optional"` + ValidRange []string `json:"valid_range,optional"` +} + +type EngineAlRq { + EngineId string `json:"engineId,optional"` + EngineName string `json:"engineName,optional"` + EngineVersion string `json:"engineVersion,optional"` + ImageUrl string `json:"imageUrl,optional"` +} + +type InputsAlRq { + Name string `json:"name,optional"` + Description string `json:"description,optional"` + RemoteConstraints []RemoteConstraints `json:"remoteConstraints,optional"` +} + +type OutputsAl { + Name string `json:"name,optional"` + Description string `json:"description,optional"` +} +type ResourceRequirements { + Key string `json:"key,optional"` + Value []string `json:"value,optional"` + Operator string `json:"operator,optional"` +} + +type AdvancedConfigAl { + AutoSearch AutoSearch `json:"autoSearch,optional"` +} + +type AutoSearch { + SkipSearchParams string `json:"skipSearch_params,optional"` + RewardAttrs []RewardAttrs `json:"rewardAttrs,optional"` + SearchParams []SearchParams `json:"searchParams,optional"` + AlgoConfigs []AlgoConfigs `json:"algoConfigs,optional"` +} + +type AlgoConfigs { + Name string `json:"name,optional"` + AutoSearchAlgoConfigParameterAlRp []AutoSearchAlgoConfigParameterAlRp `json:"params,optional"` +} + +type AutoSearchAlgoConfigParameterAlRp { + Key string `json:"key,optional"` + Value string `json:"value,optional"` + Type string `json:"type,optional"` +} + +type RewardAttrs { + Name string `json:"name,optional"` + Mode string `json:"mode,optional"` + Regex string `json:"regex,optional"` +} + +type SearchParams { + Name string `json:"name,optional"` + ParamType string `json:"param_type,optional"` + LowerBound string `json:"lower_bound,optional"` + UpperBound string `json:"upper_bound,optional"` + DiscretePointsNum string `json:"discrete_points_num,optional"` + DiscreteValues []string `json:"discrete_values,optional"` +} + +type ( + ListAlgorithmsReq { + ProjectId string `json:"projectId"` + Offset int32 `json:"offset,optional"` + Limit int32 `json:"limit"` + // SortBy string `json:"sort_by,optional"` + // Order string `json:"order,optional"` + // GroupBy string `json:"group_by,optional"` + // Searches string `json:"searches,optional"` + // WorkspaceId string `json:"workspace_id,optional"` + } + ListAlgorithmsResp { + Total int32 `json:"total,optional"` + Count int32 `json:"count,optional"` + Limit int32 `json:"limit,optional"` + SortBy string `json:"sortBy,optional"` + Order string `json:"order,optional"` + Items []AlgorithmResponse `json:"items,optional"` + } +) + +/******************ListAlgorithms End*************************/ + +/******************DeleteAlgorithm Start*************************/ +type ( + DeleteAlgorithmReq { + ProjectId string `json:"projectId" copier:"ProjectId"` + AlgorithmId string `json:"algorithmId" copier:"AlgorithmId"` + } + DeleteAlgorithmResp { + Msg string `json:"msg" copier:"Msg"` + Code int32 `json:"code" copier:"Code"` + } +) + +/******************DeleteAlgorithm End*************************/ + +/******************Show Algorithm By Uuid start*************************/ +type ( + ShowAlgorithmByUuidReq { + ProjectId string `json:"projectId" copier:"ProjectId"` + AlgorithmId string `json:"algorithmId" copier:"AlgorithmId"` + } + ShowAlgorithmByUuidResp { + Metadata MetadataAlRq `json:"metadata" copier:"Metadata"` + JobConfig JobConfigAl `json:"jobConfig" copier:"JobConfig"` + ResourceRequirements []ResourceRequirements `json:"resourceRequirements" copier:"ResourceRequirements"` + AdvancedConfig AdvancedConfigAl `json:"advancedConfig" copier:"AdvancedConfig"` + Msg string `json:"msg" copier:"Msg"` + Code int32 `json:"code" copier:"Code"` + } +) +/******************Show Algorithm By Uuid end*************************/ + +/******************CreateAlgorithm start*************************/ +type MetadataAlRq { + Id string `json:"id,optional"` + Name string `json:"name,optional"` + Description string `json:"description,optional"` + WorkspaceId string `json:"workspaceId,optional"` + AiProject string `json:"aiProject,optional"` +} +type JobConfigAl { + CodeDir string `json:"codeDir,optional"` + BootFile string `json:"bootFile,optional"` + Command string `json:"command,optional"` + Parameters []ParametersAlRq `json:"parameters,optional"` + ParametersCustomization bool `json:"parameters_customization,optional"` + Inputs []InputsAlRq `json:"inputs,optional"` + Outputs []OutputsAl `json:"outputs,optional"` + Engine EngineAlRq `json:"engine,optional"` +} +type ShareInfo { +} + +type ( + CreateAlgorithmReq { + MetadataCARq MetadataAlRq `json:"metadata,optional"` + JobConfigCARq JobConfigAl `json:"jobConfig,optional"` + ResourceRequirementsCARq []ResourceRequirements `json:"resourceRequirements,optional"` + AdvancedConfigCARq AdvancedConfigAl `json:"advancedConfig,optional"` + ProjectIdCARq string `json:"projectId"` + } + CreateAlgorithmResp { + Resp200 *CreateAlgorithmResp201 `json:"resp200,omitempty"` + Resp400 *CreateAlgorithmResp400 `json:"resp400,omitempty"` + } + CreateAlgorithmResp400 { + ErrorMsg string `json:"errorMsg,omitempty"` + ErrorCode string `json:"errorCode,omitempty"` + ErrorSolution string `json:"errorSolution,omitempty"` + } + CreateAlgorithmResp201 { + MetadataCARp MetadataAlRp `json:"metadata,optional"` + Share_infoCARp ShareInfo `json:"shareInfo,optional"` + JobConfigCARp JobConfigAl `json:"jobConfig,optional"` + ResourceRequirementsCARp []ResourceRequirements `json:"resourceRequirements,optional"` + AdvancedConfigCARp AdvancedConfigAl `json:"advancedConfig,optional"` + } +) +/******************CreateTrainingJob end*************************/ + +/******************Delete dataset start*************************/ + +type DeleteDataSetReq { + DatasetId string `json:"datasetId"` + ProjectId string `json:"projectId"` +} + +type DeleteDataSetResp { +} + +/******************Delete dataset end*************************/ + +/******************Notebook Type start*************************/ +type ( + ListNotebookReq { + Project_id string `json:"project_id"` + Param ListNotebookParam `json:"param"` + } + ListNotebookResp { + Current int32 `json:"current"` + Data []NotebookResp `json:"data"` + Pages int32 `json:"pages"` + Size int32 `json:"size"` + Total int64 `json:"total"` + } + ListNotebookParam { + Feature string `json:"feature"` + Limit int32 `json:"limit"` + Name string `json:"name"` + Pool_id string `json:"pool_id"` + Offset int32 `json:"offset"` + Owner string `json:"owner"` + Sort_dir string `json:"sort_dir"` + Sort_key string `json:"sort_key"` + Status string `json:"status"` + WorkspaceId string `json:"workspaceId"` + } + CreateNotebookReq { + Project_id string `json:"project_id"` + Param CreateNotebookParam `json:"param"` + } + CreateNotebookResp { + NotebookResp NotebookResp `json:"notebookResp"` + } + CreateNotebookParam { + Description string `json:"description"` + Duration int64 `json:"duration"` + Endpoints []EndpointsReq `json:"endpoints"` + Feature string `json:"feature"` + Flavor string `json:"flavor"` + Image_id string `json:"image_id"` + Name string `json:"name"` + Pool_id string `json:"pool_id"` + Volume VolumeReq `json:"volume"` + Workspace_id string `json:"workspace_id"` + Hooks CustomHooks `json:"hooks"` + Lease LeaseReq `json:"lease"` + } + + StartNotebookReq { + Id string `json:"id"` + Project_id string `json:"project_id"` + Param StartNotebookParam `json:"param"` + } + StartNotebookResp { + NotebookResp NotebookResp `json:"notebookResp"` + } + StartNotebookParam { + Duration int64 `json:"duration"` + Type_start_notebook string `json:"type"` + } + + StopNotebookReq { + Id string `json:"id"` + Project_id string `json:"project_id"` + } + StopNotebookResp { + NotebookResp NotebookResp `json:"notebookResp"` + } + + GetNotebookStorageReq { + Instance_id string `json:"instance_id"` + Project_id string `json:"project_id"` + } + GetNotebookStorageResp { + Current int32 `json:"current"` + Data []DataVolumesRes `json:"data"` + Pages int32 `json:"pages"` + Size int32 `json:"size"` + Total int64 `json:"total"` + } + MountNotebookStorageReq { + Instance_id string `json:"instance_id"` + Project_id string `json:"project_id"` + Param MountNotebookStorageParam `json:"param"` + } + MountNotebookStorageResp { + Category string `json:"category"` + Id string `json:"id"` + Mount_path string `json:"mount_path"` + Status string `json:"status"` + Uri string `json:"uri"` + } + + MountNotebookStorageParam { + Category string `json:"category"` + Mount_path string `json:"mount_path"` + Uri string `json:"uri"` + } + + DataVolumesRes { + Category string `json:"category"` + Id string `json:"id"` + Mount_path string `json:"mount_path"` + Status string `json:"status"` + Uri string `json:"uri"` + } + NotebookResp { + Action_progress []JobProgress `json:"action_progress"` + Description string `json:"description"` + Endpoints []EndpointsRes `json:"endpoints"` + Fail_reason string `json:"fail_reason"` + Flavor string `json:"flavor"` + Id string `json:"id"` + Image Image `json:"image"` + Lease Lease `json:"lease"` + Name string `json:"name"` + Pool Pool `json:"pool"` + Status string `json:"status"` + Token string `json:"token"` + Url string `json:"url"` + Volume VolumeRes `json:"volume"` + Workspace_id string `json:"workspace_id"` + Feature string `json:"feature"` + } + JobProgress { + Notebook_id string `json:"notebook_id"` + Status string `json:"status"` + Step int32 `json:"step"` + Step_description string `json:"step_description"` + } + EndpointsRes { + Allowed_access_ips []string `json:"allowed_access_ips"` + Dev_service string `json:"dev_service"` + Ssh_keys []string `json:"ssh_keys"` + } + Image { + Arch string `json:"arch"` + Create_at int64 `json:"create_at"` + Description string `json:"description"` + Dev_services []string `json:"dev_services"` + Id string `json:"id"` + Name string `json:"name"` + Namespace string `json:"namespace"` + Origin string `json:"origin"` + Resource_categories []string `json:"resource_categories"` + Service_type string `json:"service_type"` + Size int64 `json:"size"` + Status string `json:"status"` + Status_message string `json:"status_message"` + Support_res_categories []string `json:"support_res_categories"` + Swr_path string `json:"swr_path"` + Tag string `json:"tag"` + Type_image string `json:"type"` + Update_at int64 `json:"update_at"` + Visibility string `json:"visibility"` + Workspace_id string `json:"workspace_id"` + } + Lease { + Create_at int64 `json:"create_at"` + Duration int64 `json:"duration"` + Enable bool `json:"enable"` + Type_lease string `json:"type"` + Update_at int64 `json:"update_at"` + } + Pool { + Id string `json:"id"` + Name string `json:"name"` + } + VolumeRes { + Capacity int64 `json:"capacity"` + Category string `json:"category"` + Mount_path string `json:"mount_path"` + Ownership string `json:"ownership"` + Status string `json:"status"` + } + EndpointsReq { + Allowed_access_ips []string `json:"allowed_access_ips"` + Dev_service string `json:"dev_service"` + Ssh_keys []string `json:"ssh_keys"` + } + VolumeReq { + Capacity int64 `json:"capacity"` + Category string `json:"category"` + Ownership string `json:"ownership"` + Uri string `json:"uri"` + } + CustomHooks { + Container_hooks ContainerHooks `json:"container_hooks"` + } + ContainerHooks { + Post_start Config `json:"post_start"` + Pre_start Config `json:"pre_start"` + } + Config { + Script string `json:"script"` + Type_config string `json:"type"` + } + LeaseReq { + Duration int64 `json:"duration"` + Type_lease_req string `json:"type"` + } +) +/******************Notebook Type end*************************/ + +/******************Visualization Job Start*************************/ +type ( + GetVisualizationJobReq { + Project_id string `json:"project_id"` + Param GetVisualizationJobParam `json:"param"` + } + GetVisualizationJobResp { + Is_success bool `json:"is_success"` + Error_code string `json:"error_code"` + Error_message string `json:"error_message"` + Job_total_count int32 `json:"job_total_count"` + Job_count_limit int32 `json:"job_count_limit"` + Jobs []Jobs `json:"jobs"` + Quotas int32 `json:"quotas"` + } + Jobs { + Job_name string `json:"job_name"` + Status int32 `json:"status"` + Create_time int64 `json:"create_time"` + Duration int64 `json:"duration"` + Job_desc string `json:"job_desc"` + Service_url string `json:"service_url"` + Train_url string `json:"train_url"` + Job_id string `json:"job_id"` + Resource_id string `json:"resource_id"` + } + GetVisualizationJobParam { + Status string `json:"status"` + Per_page int32 `json:"per_page"` + Page int32 `json:"page"` + SortBy string `json:"sortBy"` + Order string `json:"order"` + Search_content string `json:"search_content"` + Workspace_id string `json:"workspace_id"` + } + CreateVisualizationJobReq { + Project_id string `json:"project_id"` + Param CreateVisualizationJobParam `json:"param"` + } + CreateVisualizationJobResp { + Error_message string `json:"error_message"` + Error_code string `json:"error_code"` + Job_id int64 `json:"job_id"` + Job_name string `json:"job_name"` + Status int32 `json:"status"` + Create_time int64 `json:"create_time"` + Service_url string `json:"service_url"` + } + CreateVisualizationJobParam { + Job_name string `json:"job_name"` + Job_desc string `json:"job_desc"` + Train_url string `json:"train_url"` + Job_type string `json:"job_type"` + Flavor Flavor `json:"flavor"` + Schedule Schedule `json:"schedule"` + } + Flavor { + Code string `json:"code"` + } + Schedule { + Type_schedule string `json:"type"` + Time_unit string `json:"time_unit"` + Duration int32 `json:"duration"` + } +) +/******************Visualization Job End*************************/ + +/******************create TrainIngJob start*************************/ + +type ( + CreateTrainingJobReq { //创建训练任务入参 + Kind string `json:"kind,optional"` + Metadatas MetadataS `json:"metadata,optional"` + AlgorithmsCtRq AlgorithmsCtRq `json:"algorithm,optional"` + SpecsCtRq SpecsCtRq `json:"spec,optional"` + ProjectId string `json:"projectId,optional"` + } + CreateTrainingJobResp201 { + Kind string `json:"kind"` + Metadatas MetadataS `json:"metadata"` + Status Status `json:"status"` + SpecCtRp SpecCtRp `json:"spec"` + Algorithms AlgorithmsCtRq `json:"algorithm"` + } + CreateTrainingJobResp400 { + ErrorMsg string `json:"errorMsg,omitempty"` + ErrorCode string `json:"errorCode,omitempty"` + ErrorSolution string `json:"errorSolution,omitempty"` + } + CreateTrainingJobResp { //创建训练任务出参 + Resp201 CreateTrainingJobResp201 `json:"resp201,omitempty"` + Resp400 CreateTrainingJobResp400 `json:"resp400,omitempty"` + } + MetadataS { + Id string `json:"id,optional"` + Name string `json:"name,optional"` + Description string `json:"description,optional"` + WorkspaceId string `json:"workspaceId,optional"` + } + + EngineCreateTraining { + EngineId string `json:"engineId,optional"` + EngineName string `json:"engineName,optional"` + EngineVersion string `json:"engineVersion,optional"` + ImageUrl string `json:"imageUrl,optional"` + } + + ConstraintCreateTraining { + Type string `json:"type,optional"` + Editable bool `json:"editable,optional"` + Required bool `json:"required,optional"` + Sensitive bool `json:"sensitive,optional"` + ValidType string `json:"validType,optional"` + } + + ParametersTrainJob { + Name string `json:"name,optional"` + Description string `json:"description,optional"` + Value string `json:"value,optional"` + ConstraintCreateTraining ConstraintCreateTraining `json:"constraint,optional"` + } + + PoliciesCreateTraining { + } + + AlgorithmsCtRq { + Id string `json:"id,optional"` + Name string `json:"name,optional"` + CodeDir string `json:"codeDir,optional"` + BootFile string `json:"bootFile,optional"` + EngineCreateTraining EngineCreateTraining `json:"engine,optional"` + ParametersTrainJob []ParametersTrainJob `json:"parameters,optional"` + PoliciesCreateTraining PoliciesCreateTraining `json:"policies,optional"` + Command string `json:"command,optional"` + } + + ResourceCreateTraining { + FlavorId string `json:"flavorId,optional"` + NodeCount int32 `json:"nodeCount,optional"` + } + + LogExportPathCreateTrainingJob { + ObsUrl string `json:"obs_url,optional"` + } + + SpecsCtRq { + Resource ResourceCreateTraining `json:"resource,optional"` + Volumes []Volumes `json:"volumes,optional"` + LogExportPath LogExportPath `json:"logExportPath,optional"` + } + SpecCtRp { + Resource ResourceCreateTraining `json:"resource,optional"` + Volumes []Volumes `json:"volumes,optional"` + LogExportPath LogExportPath `json:"logExportPath,optional"` + } + LogExportPath { + ObsUrl string `json:"obsUrl,optional"` + HostPath string `json:"hostPath,optional"` + } + Volumes { + Nfs *Nfs `json:"nfs,optional"` + } + Nfs { + NfsServerPath string `json:"nfsServer_path,optional"` + LocalPath string `json:"localPath,optional"` + ReadOnly bool `json:"readOnly,optional"` + } +) + +/******************create TrainIngJob end*************************/ + +/* +service AICore-api { + @handler listDataSetHandler + get /listDataSet (DataSetReq) returns (DataSetResp) + @handler CreateDataSetHandler + post /createDataSet (CreateDataSetReq) returns (CreateDataSetResp) + @handler DeleteDataSetHandler + delete /deleteDataSet (DeleteDataSetReq) returns (DeleteDataSetResp) + // creat task 创建导入任务 + @handler CreateTaskHandler + post /CreateTask (ImportTaskDataReq) returns (ImportTaskDataResp) + // get taskList 查询数据集导入任务列表 + @handler ListImportHandler + get /ListImport (ListImportTasksReq) returns (ListImportTasksResp) + // ListTrainingJobs 查询训练作业列表 + @handler GetListTrainingJobsHandler + get /GetListTrainingJobs (ListTrainingJobsreq) returns (ListTrainingJobsresp) + // DeleteTrainingJob 删除训练作业 + @handler DeleteTrainingJobHandler + delete /DeleteTrainingJob (DeleteTrainingJobReq) returns (DeleteTrainingJobResp) + // CreateAlgorithm 创建算法 + @handler CreateAlgorithmHandler + post /CreateAlgorithm (CreateAlgorithmReq) returns (CreateAlgorithmResp) + // ListAlgorithms 查询创建算法列表 + @handler ListAlgorithms + get /ListAlgorithms (ListAlgorithmsReq) returns (ListAlgorithmsResp) + // DeleteAlgorithm 删除算法 + @handler DeleteAlgorithm + delete /DeleteAlgorithm (DeleteAlgorithmReq) returns (DeleteAlgorithmResp) + // CreateTrainingJob 创建训练作业 + @handler CreateTrainingJobHandler + post /CreateTrainingJob (CreateTrainingJobReq) returns (CreateTrainingJobResp) + // ShowAlgorithmByUuid 展示算法详情 + @handler ShowAlgorithmByUuid + get /ShowAlgorithmByUuid (ShowAlgorithmByUuidReq) returns (ShowAlgorithmByUuidResp) + // creat export task 创建导出任务 + @handler CreateExportTaskHandler + post /CreateExportTask (CreateExportTaskReq) returns (CreateExportTaskResp) + @handler GetExportTasksOfDatasetHandler + get /GetExportTasksOfDataset (GetExportTasksOfDatasetReq) returns (GetExportTasksOfDatasetResp) + @handler GetExportTaskStatusOfDatasetHandler + get /GetExportTaskStatusOfDataset (GetExportTaskStatusOfDatasetReq) returns (GetExportTaskStatusOfDatasetResp) + // create processor task 创建处理任务 + @handler CreateProcessorTaskHandler + post /CreateProcessorTask (CreateProcessorTaskReq) returns (CreateProcessorTaskResp) + // create service 创建服务 + @handler CreateServiceHandler + post /CreateService (CreateServiceReq) returns (CreateServiceResp) + // list services 展示服务 + @handler ListServicesHandler + get /ListServices (ListServicesReq) returns (ListServicesResp) + // Show service 展示服务详情 + @handler ShowServiceHandler + get /ShowService (ShowServiceReq) returns (ShowServiceResp) + // Delete service 删除服务 + @handler DeleteServiceHandler + delete /DeleteService (DeleteServiceReq) returns (DeleteServiceResp) + // ListClusters查询专属资源池列表 + @handler ListClustersHandler + get /ListClusters (ListClustersReq) returns (ListClustersResp) + @handler listNotebookHandler + get /listNotebook (ListNotebookReq) returns (ListNotebookResp) + @handler createNotebookHandler + post /createNotebook (CreateNotebookReq) returns (CreateNotebookResp) + @handler startNotebookHandler + post /startNotebook (StartNotebookReq) returns (StartNotebookResp) + @handler stopNotebookHandler + post /stopNotebook (StopNotebookReq) returns (StopNotebookResp) + @handler getNotebookStorageHandler + get /getNotebookStorage (GetNotebookStorageReq) returns (GetNotebookStorageResp) + @handler mountNotebookStorageHandler + post /mountNotebookStorage (MountNotebookStorageReq) returns (MountNotebookStorageResp) + @handler getVisualizationJobHandler + get /getVisualizationJob (GetVisualizationJobReq) returns (GetVisualizationJobResp) + @handler createVisualizationJobHandler + post /CreateVisualizationJob (CreateVisualizationJobReq) returns (CreateVisualizationJobResp) +}*/ \ No newline at end of file diff --git a/adaptor/PCM-CORE/api/desc/pcm.api b/adaptor/PCM-CORE/api/desc/pcm.api index 1a64764..3c1e88f 100644 --- a/adaptor/PCM-CORE/api/desc/pcm.api +++ b/adaptor/PCM-CORE/api/desc/pcm.api @@ -3,6 +3,7 @@ syntax = "v1" import ( "core/pcm-core.api" "hpc/pcm-hpc.api" + "ai/pcm-ai.api" ) info( @@ -49,4 +50,97 @@ service pcm { @handler listHistoryJobHandler get /hpc/listHistoryJob (listHistoryJobReq) returns (listHistoryJobResp) +} + +//hpc二级接口 +@server( + prefix: pcm/v1 + group : ai +) +service pcm { + @handler listDataSetHandler + get /ai/listDataSet (DataSetReq) returns (DataSetResp) + + @handler CreateDataSetHandler + post /ai/createDataSet (CreateDataSetReq) returns (CreateDataSetResp) + + @handler DeleteDataSetHandler + delete /ai/deleteDataSet (DeleteDataSetReq) returns (DeleteDataSetResp) + // creat task 创建导入任务 + @handler CreateTaskHandler + post /ai/CreateTask (ImportTaskDataReq) returns (ImportTaskDataResp) + // get taskList 查询数据集导入任务列表 + @handler ListImportHandler + get /ai/ListImport (ListImportTasksReq) returns (ListImportTasksResp) + // ListTrainingJobs 查询训练作业列表 + @handler GetListTrainingJobsHandler + get /ai/GetListTrainingJobs (ListTrainingJobsreq) returns (ListTrainingJobsresp) + // DeleteTrainingJob 删除训练作业 + @handler DeleteTrainingJobHandler + delete /ai/DeleteTrainingJob (DeleteTrainingJobReq) returns (DeleteTrainingJobResp) + // CreateAlgorithm 创建算法 + @handler CreateAlgorithmHandler + post /ai/CreateAlgorithm (CreateAlgorithmReq) returns (CreateAlgorithmResp) + // ListAlgorithms 查询创建算法列表 + @handler ListAlgorithms + get /ai/ListAlgorithms (ListAlgorithmsReq) returns (ListAlgorithmsResp) + // DeleteAlgorithm 删除算法 + @handler DeleteAlgorithm + delete /ai/DeleteAlgorithm (DeleteAlgorithmReq) returns (DeleteAlgorithmResp) + // CreateTrainingJob 创建训练作业 + @handler CreateTrainingJobHandler + post /ai/CreateTrainingJob (CreateTrainingJobReq) returns (CreateTrainingJobResp) + // ShowAlgorithmByUuid 展示算法详情 + @handler ShowAlgorithmByUuid + get /ai/ShowAlgorithmByUuid (ShowAlgorithmByUuidReq) returns (ShowAlgorithmByUuidResp) + + // creat export task 创建导出任务 + @handler CreateExportTaskHandler + post /ai/CreateExportTask (CreateExportTaskReq) returns (CreateExportTaskResp) + @handler GetExportTasksOfDatasetHandler + get /ai/GetExportTasksOfDataset (GetExportTasksOfDatasetReq) returns (GetExportTasksOfDatasetResp) + @handler GetExportTaskStatusOfDatasetHandler + get /ai/GetExportTaskStatusOfDataset (GetExportTaskStatusOfDatasetReq) returns (GetExportTaskStatusOfDatasetResp) + + // create processor task 创建处理任务 + @handler CreateProcessorTaskHandler + post /ai/CreateProcessorTask (CreateProcessorTaskReq) returns (CreateProcessorTaskResp) + + // create service 创建服务 + @handler CreateServiceHandler + post /ai/CreateService (CreateServiceReq) returns (CreateServiceResp) + // list services 展示服务 + @handler ListServicesHandler + get /ai/ListServices (ListServicesReq) returns (ListServicesResp) + // Show service 展示服务详情 + @handler ShowServiceHandler + get /ai/ShowService (ShowServiceReq) returns (ShowServiceResp) + // Delete service 删除服务 + @handler DeleteServiceHandler + delete /ai/DeleteService (DeleteServiceReq) returns (DeleteServiceResp) + // ListClusters查询专属资源池列表 + @handler ListClustersHandler + get /ai/ListClusters (ListClustersReq) returns (ListClustersResp) + + /******************Notebook Method start*************************/ + @handler listNotebookHandler + get /ai/listNotebook (ListNotebookReq) returns (ListNotebookResp) + @handler createNotebookHandler + post /ai/createNotebook (CreateNotebookReq) returns (CreateNotebookResp) + @handler startNotebookHandler + post /ai/startNotebook (StartNotebookReq) returns (StartNotebookResp) + @handler stopNotebookHandler + post /ai/stopNotebook (StopNotebookReq) returns (StopNotebookResp) + @handler getNotebookStorageHandler + get /ai/getNotebookStorage (GetNotebookStorageReq) returns (GetNotebookStorageResp) + @handler mountNotebookStorageHandler + post /ai/mountNotebookStorage (MountNotebookStorageReq) returns (MountNotebookStorageResp) + /******************Notebook Method end*************************/ + + /******************Visualization Job Method start*************************/ + @handler getVisualizationJobHandler + get /ai/getVisualizationJob (GetVisualizationJobReq) returns (GetVisualizationJobResp) + @handler createVisualizationJobHandler + post /ai/CreateVisualizationJob (CreateVisualizationJobReq) returns (CreateVisualizationJobResp) + /******************Visualization Job Method start*************************/ } \ No newline at end of file diff --git a/adaptor/PCM-CORE/api/internal/handler/routes.go b/adaptor/PCM-CORE/api/internal/handler/routes.go index 2ffc67c..2587248 100644 --- a/adaptor/PCM-CORE/api/internal/handler/routes.go +++ b/adaptor/PCM-CORE/api/internal/handler/routes.go @@ -4,6 +4,7 @@ package handler import ( "net/http" + ai "PCM/adaptor/PCM-CORE/api/internal/handler/ai" core "PCM/adaptor/PCM-CORE/api/internal/handler/core" hpc "PCM/adaptor/PCM-CORE/api/internal/handler/hpc" "PCM/adaptor/PCM-CORE/api/internal/svc" @@ -63,4 +64,155 @@ func RegisterHandlers(server *rest.Server, serverCtx *svc.ServiceContext) { }, rest.WithPrefix("/pcm/v1"), ) + + server.AddRoutes( + []rest.Route{ + { + Method: http.MethodGet, + Path: "/ai/listDataSet", + Handler: ai.ListDataSetHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/createDataSet", + Handler: ai.CreateDataSetHandler(serverCtx), + }, + { + Method: http.MethodDelete, + Path: "/ai/deleteDataSet", + Handler: ai.DeleteDataSetHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/CreateTask", + Handler: ai.CreateTaskHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/ListImport", + Handler: ai.ListImportHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/GetListTrainingJobs", + Handler: ai.GetListTrainingJobsHandler(serverCtx), + }, + { + Method: http.MethodDelete, + Path: "/ai/DeleteTrainingJob", + Handler: ai.DeleteTrainingJobHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/CreateAlgorithm", + Handler: ai.CreateAlgorithmHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/ListAlgorithms", + Handler: ai.ListAlgorithmsHandler(serverCtx), + }, + { + Method: http.MethodDelete, + Path: "/ai/DeleteAlgorithm", + Handler: ai.DeleteAlgorithmHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/CreateTrainingJob", + Handler: ai.CreateTrainingJobHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/ShowAlgorithmByUuid", + Handler: ai.ShowAlgorithmByUuidHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/CreateExportTask", + Handler: ai.CreateExportTaskHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/GetExportTasksOfDataset", + Handler: ai.GetExportTasksOfDatasetHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/GetExportTaskStatusOfDataset", + Handler: ai.GetExportTaskStatusOfDatasetHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/CreateProcessorTask", + Handler: ai.CreateProcessorTaskHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/CreateService", + Handler: ai.CreateServiceHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/ListServices", + Handler: ai.ListServicesHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/ShowService", + Handler: ai.ShowServiceHandler(serverCtx), + }, + { + Method: http.MethodDelete, + Path: "/ai/DeleteService", + Handler: ai.DeleteServiceHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/ListClusters", + Handler: ai.ListClustersHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/listNotebook", + Handler: ai.ListNotebookHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/createNotebook", + Handler: ai.CreateNotebookHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/startNotebook", + Handler: ai.StartNotebookHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/stopNotebook", + Handler: ai.StopNotebookHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/getNotebookStorage", + Handler: ai.GetNotebookStorageHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/mountNotebookStorage", + Handler: ai.MountNotebookStorageHandler(serverCtx), + }, + { + Method: http.MethodGet, + Path: "/ai/getVisualizationJob", + Handler: ai.GetVisualizationJobHandler(serverCtx), + }, + { + Method: http.MethodPost, + Path: "/ai/CreateVisualizationJob", + Handler: ai.CreateVisualizationJobHandler(serverCtx), + }, + }, + rest.WithPrefix("/pcm/v1"), + ) } diff --git a/adaptor/PCM-CORE/api/internal/types/types.go b/adaptor/PCM-CORE/api/internal/types/types.go index 31fafe8..40cfe08 100644 --- a/adaptor/PCM-CORE/api/internal/types/types.go +++ b/adaptor/PCM-CORE/api/internal/types/types.go @@ -403,3 +403,1444 @@ type ListHistoryJobResp struct { RecordCount int32 `json:"recordCount"` HistoryJobs []HistoryJob `json:"historyJobs"` } + +type DataSets struct { + DatasetId string `json:"dataset_id" copier:"DatasetId"` + DataFormat string `json:"data_format" copier:"DataFormat"` + DataSources []DataSources `json:"data_sources" copier:"DataSources"` + DatasetFormat int32 `json:"dataset_format" copier:"DatasetFormat"` + DatasetName string `json:"dataset_name" copier:"DatasetName"` + DatasetType int32 `json:"dataset_type" copier:"DatasetType"` + ImportData bool `json:"import_data" copier:"ImportData"` +} + +type DataSources struct { + DataPath string `json:"data_path" copier:"DataPath"` + DataType int32 `json:"data_type" copier:"DataType"` +} + +type DataSetReq struct { + ProjectId string `json:"projectId" copier:"ProjectId"` +} + +type DataSetResp struct { + TotalNumber uint32 `json:"total_number" copier:"TotalNumber"` + Datasets []DataSets `json:"data_sets" copier:"Datasets"` +} + +type CreateDataSetReq struct { + DatasetId string `json:"datasetId"` + DatasetType int32 `json:"datasetType"` + Description string `json:"description"` + WorkPath string `json:"workPath"` + DatasetName string `json:"datasetName"` + WorkPathType string `json:"workPathType"` + ProjectId string `json:"projectId"` + DataSources []DataSources `json:"DataSources"` +} + +type CreateDataSetResp struct { + Dataset_id string `json:"datasetId"` +} + +type ImportTaskDataReq struct { + ProjectId string `json:"projectId"` + DatasetId string `json:"datasetId"` + ImportPath string `json:"importPath"` +} + +type ImportTaskDataResp200 struct { + TaskId string `json:"taskId,omitempty"` +} + +type ImportTaskDataResp400 struct { + ErrorMsg string `json:"errorMsg,omitempty"` + ErrorCode string `json:"errorCode,omitempty"` + ErrorSolution string `json:"errorSolution,omitempty"` +} + +type ImportTaskDataResp struct { + Resp200 ImportTaskDataResp200 `json:"resp200,omitempty"` + Resp400 ImportTaskDataResp400 `json:"resp400,omitempty"` +} + +type CreateExportTaskReq struct { + ProjectId string `json:"projectId,optional" copier:"ProjectId"` + DatasetId string `json:"datasetId,optional" copier:"DatasetId"` + Path string `json:"path,optional" copier:"Path"` + AnnotationFormat string `json:"annotationFormat,optional" copier:"AnnotationFormat"` + ExportFormat int64 `json:"exportFormat,optional" copier:"ExportFormat"` + ExportParams ExportParams `json:"exportParams,optional" copier:"ExportParams"` + ExportType int32 `json:"exportType,optional" copier:"ExportType"` + SampleState string `json:"sampleState,optional" copier:"ExportState"` + SourceTypeHeader string `json:"sourceTypeHeader,optional" copier:"SourceTypeHeader"` + Status int32 `json:"status,optional" copier:"Status"` + VersionFormat string `json:"versionFormat,optional" copier:"VersionFormat"` + VersionId string `json:"versionId,optional" copier:"VersionId"` + WithColumnHeader bool `json:"withColumnHeader,optional" copier:"WithColumnHeader"` +} + +type CreateExportTaskResp struct { + Resp200 ExportTaskDataResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 ExportTaskDataResp400 `json:"resp400,omitempty" copier:"Resp400"` +} + +type ExportTaskDataResp200 struct { + TaskId string `json:"task_id,optional" copier:"TaskId"` + CreateTime uint32 `json:"create_time,optional" copier:"CreateTime"` + ExportFormat int64 `json:"export_format,optional" copier:"ExportFormat"` + ExportParams ExportParams `json:"export_params,optional" copier:"ExportParams"` + FinishedSampleCount int32 `json:"finished_sample_count,optional" copier:"FinishedSampleCount"` + Path string `json:"path,optional" copier:"Path"` + Progress float64 `json:"progress,optional" copier:"Progress"` + Status string `json:"status,optional" copier:"Status"` + TotalSampleCount int64 `json:"total_sample_count,optional" copier:"TotalSampleCount"` + UpdateTime uint32 `json:"update_time,optional" copier:"UpdateTime"` + VersionFormat string `json:"version_format,optional" copier:"VersionFormat"` + VersionId string `json:"version_id,optional" copier:"VersionId"` +} + +type ExportTaskDataResp400 struct { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type ExportParams struct { + ClearHardProperty bool `json:"clear_hard_property" copier:"ClearHardProperty"` + ExportDatasetVersionFormat string `json:"export_dataset_version_format,optional" copier:"ExportDatasetVersionFormat"` + ExportDatasetVersionName string `json:"export_dataset_version_name,optional" copier:"ExportDatasetVersionName"` + ExportDest string `json:"export_dest,optional" copier:"ExportDest"` + ExportNewDatasetWorkName string `json:"export_new_dataset_work_name,optional" copier:"ExportNewDatasetWorkName"` + ExportNewDatasetWorkPath string `json:"export_new_dataset_work_path,optional" copier:"ExportNewDatasetWorkPath"` + RatioSampleUsage bool `json:"ratio_sample_usage,optional" copier:"RatioSampleUsage"` + SampleState string `json:"sample_state,optional" copier:"SampleState"` + Sample []string `json:"sample,optional" copier:"Sample"` + SearchConditions []SearchCondition `json:"search_conditions,optional" copier:"SearchConditions"` + TrainSampleRatio string `json:"train_sample_ratio,optional" copier:"TrainSampleRatio"` +} + +type SearchCondition struct { + Coefficient string `json:"coefficient,optional" copier:"Coefficient"` + FrameInVideo int64 `json:"frame_in_video,optional" copier:"FrameInVideo"` + Hard string `json:"coefficient,optional" copier:"Hard"` + Kvp string `json:"kvp,optional" copier:"Kvp"` + ImportOrigin string `json:"import_origin,optional" copier:"ImportOrigin"` + LabelList SearchLabels `json:"label_list,optional" copier:"LabelList"` + Labeler string `json:"labeler,optional" copier:"Labeler"` + ParentSampleId string `json:"parent_sample_id,optional" copier:"ParentSampleId"` + Metadata SearchProp `json:"metadata,optional" copier:"Metadata"` + SampleDir string `json:"sample_dir,optional" copier:"SampleDir"` + SampleName string `json:"sample_name,optional" copier:"SampleName"` + SampleTime string `json:"sample_time,optional" copier:"SampleTime"` + Score string `json:"score,optional" copier:"Score"` + SliceThickness string `json:"slice_thickness,optional" copier:"SliceThickness"` + StudyDate string `json:"StudyDate,optional" copier:"StudyDate"` + TimeInVideo string `json:"time_in_video,optional" copier:"TimeInVideo"` +} + +type SearchLabels struct { + Labels []SearchLabel `json:"labels,optional" copier:"Labels"` + Op string `json:"op,optional" copier:"Op"` +} + +type SearchLabel struct { + Name string `json:"name,optional" copier:"Name"` + Op string `json:"op,optional" copier:"Op"` + Type int64 `json:"type,optional" copier:"Type"` +} + +type SearchProp struct { + Op string `json:"op,optional" copier:"Op"` +} + +type GetExportTasksOfDatasetReq struct { + ProjectId string `json:"project_id" copier:"ProjectId"` + DatasetId string `json:"dataset_id" copier:"DatasetId"` + ExportType int32 `json:"export_type,optional" copier:"ExportType"` + Limit int32 `json:"limit,optional" copier:"Limit"` + Offset int32 `json:"offset,optional" copier:"Offset"` +} + +type GetExportTasksOfDatasetResp struct { + Resp200 GetExportTasksOfDatasetResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 GetExportTasksOfDatasetResp400 `json:"resp400,omitempty" copier:"Resp400"` +} + +type GetExportTasksOfDatasetResp200 struct { + TaskId string `json:"taskId,omitempty" copier:"TaskId"` + CreateTime uint32 `json:"create_time,omitempty" copier:"CreateTime"` + ExportFormat int64 `json:"export_format,omitempty" copier:"ExportFormat"` + ExportParams ExportParams `json:"export_params,omitempty" copier:"ExportParams"` + ExportTasks []ExportTaskStatus `json:"export_tasks,omitempty" copier:"ExportTasks"` + FinishedSampleCount int32 `json:"finished_sample_count,omitempty" copier:"FinishedSampleCount"` + Path string `json:"path,omitempty" copier:"Path"` + Progress float64 `json:"progress,omitempty" copier:"Progress"` + Status string `json:"status,omitempty" copier:"Status"` + TotalCount int64 `json:"total_count,omitempty" copier:"TotalCount"` + UpdateTime uint32 `json:"update_time,omitempty" copier:"UpdateTime"` + VersionFormat string `json:"version_format,omitempty" copier:"VersionFormat"` + VersionId string `json:"version_id,omitempty" copier:"VersionId"` + ExportType int32 `json:"export_type,omitempty" copier:"ExportType"` + TotalSample int64 `json:"total_sample,omitempty" copier:"TotalSample"` +} + +type GetExportTasksOfDatasetResp400 struct { + ErrorCode string `json:"error_code,omitempty" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,omitempty" copier:"ErrorMsg"` +} + +type ExportTaskStatus struct { + TaskId string `json:"taskId,omitempty" copier:"TaskId"` + CreateTime uint32 `json:"create_time,omitempty" copier:"CreateTime"` + ErrorCode string `json:"error_code,omitempty" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,omitempty" copier:"ErrorMsg"` + ExportFormat int64 `json:"export_format,omitempty" copier:"ExportFormat"` + ExportParams ExportParams `json:"export_params,omitempty" copier:"ExportParams"` + FinishedSampleCount int32 `json:"finished_sample_count,omitempty" copier:"FinishedSampleCount"` + Path string `json:"path,omitempty" copier:"Path"` + Progress float64 `json:"progress,omitempty" copier:"Progress"` + Status string `json:"status,omitempty" copier:"Status"` + TotalCount int64 `json:"total_count,omitempty" copier:"TotalCount"` + UpdateTime uint32 `json:"update_time,omitempty" copier:"UpdateTime"` + VersionFormat string `json:"version_format,omitempty" copier:"VersionFormat"` + VersionId string `json:"version_id,omitempty" copier:"VersionId"` + ExportType int32 `json:"export_type,omitempty" copier:"ExportType"` + TotalSample int64 `json:"total_sample,omitempty" copier:"TotalSample"` +} + +type GetExportTaskStatusOfDatasetReq struct { + ProjectId string `json:"project_id" copier:"ProjectId"` + ResourceId string `json:"resource_id" copier:"ResourceId"` + TaskId string `json:"task_id,optional" copier:"TaskId"` +} + +type GetExportTaskStatusOfDatasetResp struct { + Resp200 GetExportTaskStatusOfDatasetResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 GetExportTaskStatusOfDatasetResp400 `json:"resp400,omitempty" copier:"Resp400"` +} + +type GetExportTaskStatusOfDatasetResp200 struct { + TaskId string `json:"taskId,optional" copier:"TaskId"` + CreateTime uint32 `json:"create_time,optional" copier:"CreateTime"` + ExportFormat int64 `json:"export_format,optional" copier:"ExportFormat"` + ExportParams ExportParams `json:"export_params,optional" copier:"ExportParams"` + ExportTasks []ExportTaskStatus `json:"export_tasks,optional" copier:"ExportTasks"` + FinishedSampleCount int32 `json:"finished_sample_count,optional" copier:"FinishedSampleCount"` + Path string `json:"path,optional" copier:"Path"` + Progress float64 `json:"progress,optional" copier:"Progress"` + Status string `json:"status,optional" copier:"Status"` + TotalCount int64 `json:"total_count,optional" copier:"TotalCount"` + UpdateTime uint32 `json:"update_time,optional" copier:"UpdateTime"` + VersionFormat string `json:"version_format,optional" copier:"VersionFormat"` + VersionId string `json:"version_id,optional" copier:"VersionId"` + ExportType int32 `json:"export_type,optional" copier:"ExportType"` + TotalSample int64 `json:"total_sample,optional" copier:"TotalSample"` +} + +type GetExportTaskStatusOfDatasetResp400 struct { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type CreateProcessorTaskReq struct { + ProjectId string `json:"dataset_id" copier:"ProjectId"` + CreateVersion bool `json:"create_version,optional" copier:"CreateVersion"` + Description string `json:"description,optional" copier:"Description"` + DataSources ProcessorDataSource `json:"data_source,optional" copier:"DataSources"` + Inputs []ProcessorDataSource `json:"inputs,optional" copier:"Inputs"` + Name string `json:"name,optional" copier:"Nmae"` + Template TemplateParam `json:"template,optional" copier:"Template"` + VersionId string `json:"version_id,optional" copier:"VersionId"` + WorkPath WorkPath `json:"work_path,optional" copier:"WorkPath"` + WorkspaceId string `json:"workspace_id,optional" copier:"WorkspaceId"` +} + +type CreateProcessorTaskResp struct { + TaskId string `json:"taskId,optional" copier:"Code"` + Code int32 `json:"code,optional" copier:"Code"` + Msg string `json:"msg,optional" copier:"Msg"` +} + +type ProcessorDataSource struct { + Name string `json:"name,optional" copier:"Name"` + Source string `json:"source,optional" copier:"Source"` + Type string `json:"type,optional" copier:"type"` + VersionId string `json:"version_id,optional" copier:"VersionId"` + VersionName string `json:"version_name,optional" copier:"VersionName"` +} + +type TemplateParam struct { + Id string `json:"id,optional" copier:"Id"` + Name string `json:"name,optional" copier:"Name"` + OperatorParam []OperatorParam `json:"operator_params,optional" copier:"OperatorParam"` +} + +type WorkPath struct { + Name string `json:"name,optional" copier:"name"` + OutputPath string `json:"output_path,optional" copier:"OutputPath"` + Path string `json:"path,optional" copier:"Path"` + Type string `json:"type,optional" copier:"type"` + VersionId string `json:"version_id,optional" copier:"VersionId"` + VersionName string `json:"version_name,optional" copier:"VersionName"` +} + +type OperatorParam struct { + Id string `json:"id,optional" copier:"Id"` + Name string `json:"name,optional" copier:"Name"` + Params string `json:"params,optional" copier:"Params"` + AdvancedParamsSwitch bool `json:"advanced_params_switch,optional" copier:"AdvancedParamsSwitch"` +} + +type ListImportTasksReq struct { + ProjectId string `json:"projectId"` + DatasetId string `json:"datasetId"` + Limit int32 `json:"limit,optional"` + Offset int32 `json:"offset,optional"` +} + +type ListImportTasksResp struct { + Resp200 *ListImportTasksResp200 `json:"resp200,omitempty"` + Resp400 *ListImportTasksResp400 `json:"resp400,omitempty"` +} + +type ListImportTasksResp200 struct { + TotalCount uint32 `json:"totalCount,omitempty"` + ImportTasks []ImportTasks `json:"importTasks,omitempty"` +} + +type ListImportTasksResp400 struct { + ErrorMsg string `json:"errorMsg,omitempty"` + ErrorCode string `json:"errorCode,omitempty"` + ErrorSolution string `json:"errorSolution,omitempty"` +} + +type ImportTasks struct { + Status string `json:"status,omitempty"` + TaskId string `json:"task_id,omitempty"` + DatasetId string `json:"dataset_id,omitempty"` + ImportPath string `json:"import_path,omitempty"` + ImportType int32 `json:"import_type,omitempty"` + TotalSampleCount uint32 `json:"total_sample_count,omitempty"` + ImportedSampleCount uint32 `json:"imported_sample_count,omitempty"` + AnnotatedSampleCount uint32 `json:"annotated_sample_count,omitempty"` + TotalSubSampleCount uint32 `json:"total_sub_sample_count,omitempty"` + ImportedSubSampleCount uint32 `json:"imported_sub_sample_count,omitempty"` + TotalFileSize uint32 `json:"total_file_size,omitempty"` + FinishedFileCount uint32 `json:"finished_file_count,omitempty"` + FinishedFileSize uint32 `json:"finished_file_size,omitempty"` + TotalFileCount uint32 `json:"total_file_count,omitempty"` + CreateTime uint32 `json:"create_time,omitempty"` + ElapsedTime uint32 `json:"elapsed_time,omitempty"` + AnnotationFormatConfig []interface{} `json:"annotation_format_config"` +} + +type Annotations struct { + JobTemplate string `json:"job_template"` + KeyTask string `json:"key_task"` +} + +type TrainingExperimentReference struct { +} + +type Metadata struct { + ID string `json:"id"` + Name string `json:"name"` + Description string `json:"description"` + CreateTime uint32 `json:"create_time"` + WorkspaceID string `json:"workspace_id"` + AiProject string `json:"ai_project"` + UserName string `json:"user_name"` + Annotations Annotations `json:"annotations"` + TrainingExperimentReference TrainingExperimentReference `json:"training_experiment_reference"` + Tags []interface{} `json:"tags"` +} + +type CPUUsage struct { + Average int32 `json:"average"` + Max int32 `json:"max"` + Min int32 `json:"min"` +} + +type MemUsage struct { + Average int32 `json:"average"` + Max int32 `json:"max"` + Min int32 `json:"min"` +} + +type Util struct { + Average int32 `json:"average"` + Max int32 `json:"max"` + Min int32 `json:"min"` +} + +type Gpu struct { + MemUsage MemUsage `json:"mem_usage"` + Util Util `json:"util"` + UnitNum int32 `json:"unit_num"` + ProductName string `json:"product_name"` + Memory string `json:"memory"` +} + +type Status struct { + Phase string `json:"phase"` + SecondaryPhase string `json:"secondaryPhase"` + Duration int32 `json:"duration"` + Tasks []string `json:"tasks"` + StartTime uint64 `json:"startTime"` + TaskStatuses []*TaskStatuses `json:"taskStatuses,omitempty"` +} + +type TaskStatuses struct { + Task string `json:"task,omitempty"` + ExitCode string `json:"exitCode,omitempty"` + Message string `json:"message,omitempty"` +} + +type Constraint struct { + Type string `json:"type"` + Editable bool `json:"editable"` + Required bool `json:"required"` + Sensitive bool `json:"sensitive"` + ValidType string `json:"valid_type"` + ValidRange interface{} `json:"valid_range,optional"` +} + +type Parameters struct { + Name string `json:"name"` + Description string `json:"description"` + I18NDescription interface{} `json:"i18n_description"` + Value string `json:"value"` + Constraint Constraint `json:"constraint"` +} + +type Obs struct { + ObsURL string `json:"obs_url"` +} + +type Remote struct { + Obs Obs `json:"obs"` +} + +type Attributes struct { + DataFormat []string `json:"data_format"` + DataSegmentation []string `json:"data_segmentation"` + DatasetType []string `json:"dataset_type"` + IsFree string `json:"is_free"` + MaxFreeJobCount string `json:"max_free_job_count"` +} + +type RemoteConstraints struct { + DataType string `json:"dataType"` + Attributes Attributes `json:"attributes,omitempty"` +} + +type Inputs struct { + Name string `json:"name"` + Description string `json:"description"` + LocalDir string `json:"local_dir"` + AccessMethod string `json:"access_method"` + Remote Remote `json:"remote"` + RemoteConstraints []RemoteConstraints `json:"remote_constraints"` +} + +type Outputs struct { + Name string `json:"name"` + LocalDir string `json:"local_dir"` + AccessMethod string `json:"access_method"` + Remote Remote `json:"remote"` + Mode string `json:"mode"` + Period int32 `json:"period"` + PrefetchToLocal bool `json:"prefetch_to_local"` +} + +type Engine struct { + EngineID string `json:"engine_id"` + EngineName string `json:"engine_name"` + EngineVersion string `json:"engine_version"` + V1Compatible bool `json:"v1_compatible"` + RunUser string `json:"run_user"` + ImageSource bool `json:"image_source"` +} + +type Policies struct { +} + +type Algorithm struct { + ID string `json:"id"` + Name string `json:"name"` + V1Algorithm bool `json:"v1_algorithm"` + SubscriptionID string `json:"subscription_id"` + ItemVersionID string `json:"item_version_id"` + ContentID string `json:"content_id"` + Parameters []Parameters `json:"parameters"` + ParametersCustomization bool `json:"parameters_customization"` + Inputs []Inputs `json:"inputs"` + Outputs []Outputs `json:"outputs"` + Engine Engine `json:"engine"` + Policies Policies `json:"policies"` +} + +type Billing struct { + Code string `json:"code"` + UnitNum int32 `json:"unit_num"` +} + +type CPU struct { + Arch string `json:"arch"` + CoreNum int32 `json:"core_num"` +} + +type Memory struct { + Size int `json:"size"` + Unit string `json:"unit"` +} + +type Disk struct { + Size int32 `json:"size"` + Unit string `json:"unit"` +} + +type FlavorInfo struct { + CPU CPU `json:"cpu"` + Gpu Gpu `json:"gpu"` + Memory Memory `json:"memory"` + Disk Disk `json:"disk"` +} + +type FlavorDetail struct { + FlavorType string `json:"flavor_type"` + Billing Billing `json:"billing"` + Attributes Attributes `json:"attributes"` + FlavorInfo FlavorInfo `json:"flavor_info"` +} + +type Resource struct { + Policy string `json:"policy,optional"` + FlavorId string `json:"flavor_id,optional"` + FlavorName string `json:"flavor_name,optional"` + NodeCount int32 `json:"node_count,optional"` + FlavorDetail FlavorDetail `json:"flavor_detail,optional"` +} + +type LogExportPathCreateTraining struct { +} + +type Spec struct { + Resource Resource `json:"resource"` + LogExportPath LogExportPath `json:"log_export_path"` + IsHostedLog bool `json:"is_hosted_log"` +} + +type Items struct { + Kind string `json:"kind"` + Metadata Metadata `json:"metadata"` + Status Status `json:"status"` + Algorithm Algorithm `json:"algorithm,omitempty"` + Spec Spec `json:"spec"` +} + +type ListTrainingJobsreq struct { + ProjectId string `json:"projectId"` +} + +type ListTrainingJobsresp struct { + Resp200 *ListTrainingJobsresp200 `json:"resp200,omitempty"` + Resp400 *ListTrainingJobsresp400 `json:"resp400,omitempty"` +} + +type ListTrainingJobsresp200 struct { + Total int32 `json:"total"` + Count int32 `json:"count"` + Limit int32 `json:"limit"` + Offset int32 `json:"offset"` + SortBy string `json:"sort_by"` + Order string `json:"order"` + GroupBy string `json:"group_by"` + WorkspaceID string `json:"workspace_id"` + AiProject string `json:"ai_project"` + Items []Items `json:"items"` +} + +type ListTrainingJobsresp400 struct { + ErrorMsg string `json:"errorMsg,omitempty"` + ErrorCode string `json:"errorCode,omitempty"` + ErrorSolution string `json:"errorSolution,omitempty"` +} + +type DeleteTrainingJobReq struct { + Project_id string `json:"projectId"` + Training_job_id string `json:"trainingJobId"` +} + +type DeleteTrainingJobResp struct { + Is_success bool `json:"isSuccess"` + Error_message string `json:"errorMessage"` + Error_code string `json:"errorCode"` +} + +type CreateServiceReq struct { + WorkspaceId string `json:"workspaceId,optional" copier:"WorkspaceId"` + Schedule Scheduler `json:"schedule,optional" copier:"Schedule"` + ClusterId string `json:"clusterId,optional" copier:"ClusterId"` + InferType string `json:"inferType,optional" copier:"InferType"` + VpcId string `json:"vpcId,optional" copier:"VpcId"` + ServiceName string `json:"serviceName,optional" copier:"ServiceName"` + Description string `json:"description,optional" copier:"Description"` + SecurityGroupId string `json:"securityGroupId,optional" copier:"SecurityGroupId"` + SubnetNetworkId string `json:"subnetNetworkId,optional" copier:"SubnetNetworkId"` + Config []ServiceConfig `json:"config,optional" copier:"Config"` + ProjectId string `json:"projectId,optional" copier:"ProjectId"` +} + +type CreateServiceResp struct { + Resp200 CreateServiceResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 CreateServiceResp400 `json:"resp400,omitempty" copier:"Resp400"` +} + +type CreateServiceResp200 struct { + ServiceId string `json:"service_id,omitempty" copier:"ServiceId"` + ResourceIds []string `json:"resource_ids,omitempty" copier:"ResourceIds"` +} + +type CreateServiceResp400 struct { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type Scheduler struct { + Duration int32 `json:"duration,optional" copier:"Duration"` + TimeUnit string `json:"timeUnit,optional" copier:"TimeUnit"` + Type string `json:"type,optional" copier:"Type"` +} + +type ServiceConfig struct { + CustomSpec CustomSpec `json:"customSpec,optional" copier:"CustomSpec"` + Envs map[string]string `json:"envs,optional" copier:"Envs"` + Specification string `json:"specification,optional" copier:"Specification"` + Weight int32 `json:"weight,optional" copier:"Weight"` + ModelId string `json:"modelId,optional" copier:"ModelId"` + SrcPath string `json:"srcPath,optional" copier:"SrcPath"` + ReqUri string `json:"reqUri,optional" copier:"ReqUri"` + MappingType string `json:"mappingType,optional" copier:"MappingType"` + ClusterId string `json:"clusterId,optional" copier:"ClusterId"` + Nodes []string `json:"nodes,optional" copier:"Nodes"` + SrcType string `json:"srcType,optional" copier:"SrcType"` + DestPath string `json:"destPath,optional" copier:"DestPath"` + InstanceCount int32 `json:"instanceCount,optional" copier:"InstanceCount"` +} + +type CustomSpec struct { + GpuP4 float64 `json:"gpuP4,optional" copier:"GpuP4"` + Memory int64 `json:"memory,optional" copier:"Memory"` + Cpu float64 `json:"cpu,optional" copier:"Cpu"` + AscendA310 int64 `json:"ascendA310,optional" copier:"AscendA310"` +} + +type DeleteServiceReq struct { + ProjectId string `json:"projectId" copier:"ProjectId"` + ServiceId string `json:"serviceId" copier:"ServiceId"` +} + +type DeleteServiceResp struct { + Resp200 DeleteServiceResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 DeleteServiceResp400 `json:"resp400,omitempty" copier:"Resp400"` +} + +type DeleteServiceResp200 struct { +} + +type DeleteServiceResp400 struct { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type ListServicesReq struct { + ProjectId string `json:"projectId" copier:"ProjectId"` +} + +type ListServicesResp struct { + Resp200 ListServicesResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 ListServicesResp400 `json:"resp400,omitempty" copier:"Resp400"` +} + +type ListServicesResp200 struct { + TotalCount int32 `json:"total_count,omitempty" copier:"TotalCount"` + Count int32 `json:"count,omitempty" copier:"Count"` + Services []ListServices `json:"services,omitempty" copier:"Services"` +} + +type ListServicesResp400 struct { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type ListServices struct { + FailedTimes uint32 `json:"failed_times,omitempty" copier:"FailedTimes"` + Owner string `json:"owner,omitempty" copier:"Owner"` + DueTime int32 `json:"due_time,omitempty" copier:"DueTime"` + FinishedTime int32 `json:"finished_time,omitempty" copier:"FinishedTime"` + InferType string `json:"infer_type,omitempty" copier:"InferType"` + ServiceName string `json:"service_name,omitempty" copier:"ServiceName"` + Description string `json:"description,omitempty" copier:"Description"` + Project string `json:"project,omitempty" copier:"Project"` + InvocationTimes uint32 `json:"invocation_times,omitempty" copier:"InvocationTimes"` + PublishAt uint32 `json:"publish_at,omitempty" copier:"PublishAt"` + WorkspaceId string `json:"workspace_id,omitempty" copier:"WorkspaceId"` + Scheduler []*Scheduler `json:"scheduler,omitempty" copier:"Scheduler"` + StartTime int32 `json:"start_time,omitempty" copier:"StartTime"` + OperationTime string `json:"operation_time,omitempty" copier:"OperationTime"` + IsShared bool `json:"is_shared,omitempty" copier:"IsShared"` + ServiceId string `json:"service_id,omitempty" copier:"ServiceId"` + Progress int32 `json:"progress,omitempty" copier:"Progress"` + SharedCount int32 `json:"shared_count,omitempty" copier:"SharedCount"` + Tenant string `json:"tenant,omitempty" copier:"Tenant"` + Status string `json:"status,omitempty" copier:"Status"` + IsOpenedSampleCollection string `json:"is_opened_sample_collection,omitempty" copier:"IsOpenedSampleCollection"` + TransitionAt int32 `json:"transition_at,omitempty" copier:"TransitionAt"` + IsFree bool `json:"is_free,omitempty" copier:"IsFree"` + AdditionalProperties map[string]string `json:"additional_properties,omitempty" copier:"AdditionalProperties"` +} + +type ShowServiceReq struct { + ProjectId string `json:"projectId" copier:"ProjectId"` + ServiceId string `json:"serviceId" copier:"ServiceId"` +} + +type ShowServiceResp struct { + Resp200 ShowServiceResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 ShowServiceResp400 `json:"resp400,omitempty" copier:"Resp400"` +} + +type ShowServiceResp200 struct { + FailedTimes uint32 `json:"failed_times,omitempty" copier:"FailedTimes"` + Owner string `json:"owner,omitempty" copier:"Owner"` + DueTime int32 `json:"due_time,omitempty" copier:"DueTime"` + FinishedTime int32 `json:"finished_time,omitempty" copier:"FinishedTime"` + InferType string `json:"infer_type,omitempty" copier:"InferType"` + ServiceName string `json:"service_name,omitempty" copier:"ServiceName"` + Description string `json:"description,omitempty" copier:"Description"` + Project string `json:"project,omitempty" copier:"Project"` + InvocationTimes uint32 `json:"invocation_times,omitempty" copier:"InvocationTimes"` + PublishAt uint32 `json:"publish_at,omitempty" copier:"PublishAt"` + WorkspaceId string `json:"workspace_id,omitempty" copier:"WorkspaceId"` + Scheduler []Scheduler `json:"scheduler,omitempty" copier:"Scheduler"` + StartTime int32 `json:"start_time,omitempty" copier:"StartTime"` + OperationTime string `json:"operation_time,omitempty" copier:"OperationTime"` + IsShared bool `json:"is_shared,omitempty" copier:"IsShared"` + ServiceId string `json:"service_id,omitempty" copier:"ServiceId"` + Progress int32 `json:"progress,omitempty" copier:"Progress"` + SharedCount int32 `json:"shared_count,omitempty" copier:"SharedCount"` + Tenant string `json:"tenant,omitempty" copier:"Tenant"` + Status string `json:"status,omitempty" copier:"Status"` + IsOpenedSampleCollection string `json:"is_opened_sample_collection,omitempty" copier:"IsOpenedSampleCollection"` + TransitionAt int32 `json:"transition_at,omitempty" copier:"TransitionAt"` + IsFree bool `json:"is_free,omitempty" copier:"IsFree"` + AdditionalProperties map[string]string `json:"additional_properties,omitempty" copier:"AdditionalProperties"` + ClusterId string `json:"cluster_id,omitempty" copier:"ClusterId"` + VpcId string `json:"vpc_id,omitempty" copier:"VpcId"` + SubnetNetworkId string `json:"subnet_network_id,omitempty" copier:"SubnetNetworkId"` + SecurityGroupId string `json:"security_group_id,omitempty" copier:"SecurityGroupId"` + Config []QueryServiceConfig `json:"config,omitempty" copier:"Config"` + AccessAddress string `json:"access_address,omitempty" copier:"AccessAddress"` + BindAccessAddress string `json:"bind_access_address,omitempty" copier:"BindAccessAddress"` + UpdateTime string `json:"update_time,omitempty" copier:"UpdateTime"` + DebugUrl string `json:"debug_url,omitempty" copier:"DebugUrl"` +} + +type ShowServiceResp400 struct { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type QueryServiceConfig struct { + ModelVersion string `json:"model_version,omitempty" copier:"ModelVersion"` + FinishedTime string `json:"finished_time,omitempty" copier:"FinishedTime"` + CustomSpec *CustomSpec `json:"CustomSpec,omitempty" copier:"CustomSpec"` + Envs map[string]string `json:"envs,omitempty" copier:"Envs"` + Specification string `json:"specification,omitempty" copier:"Specification"` + Weight int32 `json:"weight,omitempty" copier:"Weight"` + ModelId string `json:"model_id,omitempty" copier:"ModelId"` + SrcPath string `json:"src_path,omitempty" copier:"SrcPath"` + ReqUri string `json:"req_uri,omitempty" copier:"ReqUri"` + MappingType string `json:"mapping_type,omitempty" copier:"MappingType"` + StartTime string `json:"start_time,omitempty" copier:"StartTime"` + ClusterId string `json:"cluster_id,omitempty" copier:"ClusterId"` + Nodes []string `json:"nodes,omitempty" copier:"Nodes"` + MappingRule string `json:"mapping_rule,omitempty" copier:"MappingRule"` + ModelName string `json:"model_name,omitempty" copier:"ModelName"` + SrcType string `json:"src_type,omitempty" copier:"SrcType"` + DestPath string `json:"dest_path,omitempty" copier:"DestPath"` + InstanceCount int32 `json:"instance_count,omitempty" copier:"InstanceCount"` + Status string `json:"status,omitempty" copier:"Status"` + Scaling bool `json:"scaling,omitempty" copier:"Scaling"` + SupportDebug bool `json:"support_debug,omitempty" copier:"SupportDebug"` + AdditionalProperties map[string]string `json:"additional_properties,omitempty" copier:"AdditionalProperties"` +} + +type ListClustersReq struct { + ProjectId string `json:"project_id" copier:"ProjectId"` + ClusterName string `json:"cluster_name,optional" copier:"ClusterName"` + Offset int64 `json:"offset,optional" copier:"Offset"` + Limit int64 `json:"limit,optional" copier:"Limit"` + SortBy string `json:"sort_by,optional" copier:"SortBy"` + Order string `json:"order,optional" copier:"Order"` +} + +type ListClustersResp struct { + Resp200 ListClustersResp200 `json:"resp200,omitempty" copier:"Resp200"` + Resp400 ListClustersResp400 `json:"resp400,omitempty" copier:"Resp400"` +} + +type ListClustersResp200 struct { + Count int32 `json:"count,omitempty" copier:"Count"` + Clusters []Cluster `json:"clusters,omitempty" copier:"Clusters"` +} + +type ListClustersResp400 struct { + ErrorCode string `json:"error_code,optional" copier:"ErrorCode"` + ErrorMsg string `json:"error_msg,optional" copier:"ErrorMsg"` +} + +type ClusterNode struct { + Specification string `json:"specification,omitempty" copier:"Specification"` + Count int32 `json:"count,omitempty" copier:"Count"` + AvailableCount int32 `json:"available_count,omitempty" copier:"AvailableCount"` +} + +type Cluster struct { + ClusterId string `json:"cluster_id,omitempty" copier:"ClusterId"` + ClusterName string `json:"cluster_name,omitempty" copier:"ClusterName"` + Description string `json:"description,omitempty" copier:"Description"` + Tenant string `json:"tenant,omitempty" copier:"Tenant"` + Project string `json:"project,omitempty" copier:"Project"` + Owner string `json:"owner,omitempty" copier:"Owner"` + CreatedAt int32 `json:"created_at,omitempty" copier:"CreatedAt"` + Status string `json:"status,omitempty" copier:"Status"` + Nodes ClusterNode `json:"nodes,omitempty" copier:"Nodes"` + AllocatableCpuCores float64 `json:"allocatable_cpu_cores,omitempty" copier:"AllocatableCpuCores"` + AllocatableMemory int64 `json:"allocatable_memory,omitempty" copier:"AllocatableMemory"` + PeriodNum int32 `json:"period_num,omitempty" copier:"PeriodNum"` + PeriodType string `json:"period_type,omitempty" copier:"PeriodType"` + OrderId string `json:"order_id,omitempty" copier:"OrderId"` +} + +type AlgorithmResponse struct { + MetadataAlRp MetadataAlRp `json:"metadata,optional"` + JobConfigAlRp JobConfigAlRp `json:"jobConfig,optional"` + ResourceRequirementsAlRp []ResourceRequirements `json:"resourceRequirements,optional"` + AdvancedConfigAlRp AdvancedConfigAl `json:"advancedConfig,optional"` +} + +type MetadataAlRp struct { + Id string `json:"id,optional"` + Name string `json:"name,optional"` + Description string `json:"description,optional"` + CreateTime uint64 `json:"createTime,optional"` + WorkspaceId string `json:"workspaceId,optional"` + AiProject string `json:"aiProject,optional"` + UserName string `json:"userName,optional"` + DomainId string `json:"domainId,optional"` + Source string `json:"source,optional"` + ApiVersion string `json:"apiVersion,optional"` + IsValid bool `json:"isValid,optional"` + State string `son:"state,optional"` + Size int32 `json:"size,optional"` + Tags []*TagsAlRp `json:"tags,optional"` + AttrList []string `json:"attrList,optional"` + VersionNum int32 `json:"versionNum,optional"` + UpdateTime uint64 `json:"updateTime,optional"` +} + +type TagsAlRp struct { + Tags map[string]string `json:"tags,optional"` +} + +type JobConfigAlRp struct { + CodeDir string `json:"codeDir,optional"` + BootFile string `json:"bootFile,optional"` + Command string `json:"command,optional"` + ParametersAlRq []ParametersAlRq `json:"parameters,optional"` + ParametersCustomization bool `json:"parameters_customization,optional"` + InputsAlRq []InputsAlRq `json:"inputs,optional"` + OutputsAl []OutputsAl `json:"outputs,optional"` + EngineAlRq EngineAlRq `json:"engine,optional"` +} + +type ParametersAlRq struct { + Name string `json:"name,optional"` + Description string `json:"description,optional"` + I18NDescription I18NDescription `json:"i18nDescription,optional"` + Value string `json:"value,optional"` + Constraint ConstraintAlRq `json:"constraint,optional"` +} + +type I18NDescription struct { + Language string `json:"language,optional"` + Description string `json:"description,optional"` +} + +type ConstraintAlRq struct { + Type string `son:"type,optional"` + Editable bool `json:"editable,optional"` + Required bool `json:"required,optional"` + Sensitive bool `json:"sensitive,optional"` + ValidType string `json:"valid_type,optional"` + ValidRange []string `json:"valid_range,optional"` +} + +type EngineAlRq struct { + EngineId string `json:"engineId,optional"` + EngineName string `json:"engineName,optional"` + EngineVersion string `json:"engineVersion,optional"` + ImageUrl string `json:"imageUrl,optional"` +} + +type InputsAlRq struct { + Name string `json:"name,optional"` + Description string `json:"description,optional"` + RemoteConstraints []RemoteConstraints `json:"remoteConstraints,optional"` +} + +type OutputsAl struct { + Name string `json:"name,optional"` + Description string `json:"description,optional"` +} + +type ResourceRequirements struct { + Key string `json:"key,optional"` + Value []string `json:"value,optional"` + Operator string `json:"operator,optional"` +} + +type AdvancedConfigAl struct { + AutoSearch AutoSearch `json:"autoSearch,optional"` +} + +type AutoSearch struct { + SkipSearchParams string `json:"skipSearch_params,optional"` + RewardAttrs []RewardAttrs `json:"rewardAttrs,optional"` + SearchParams []SearchParams `json:"searchParams,optional"` + AlgoConfigs []AlgoConfigs `json:"algoConfigs,optional"` +} + +type AlgoConfigs struct { + Name string `json:"name,optional"` + AutoSearchAlgoConfigParameterAlRp []AutoSearchAlgoConfigParameterAlRp `json:"params,optional"` +} + +type AutoSearchAlgoConfigParameterAlRp struct { + Key string `json:"key,optional"` + Value string `json:"value,optional"` + Type string `json:"type,optional"` +} + +type RewardAttrs struct { + Name string `json:"name,optional"` + Mode string `json:"mode,optional"` + Regex string `json:"regex,optional"` +} + +type SearchParams struct { + Name string `json:"name,optional"` + ParamType string `json:"param_type,optional"` + LowerBound string `json:"lower_bound,optional"` + UpperBound string `json:"upper_bound,optional"` + DiscretePointsNum string `json:"discrete_points_num,optional"` + DiscreteValues []string `json:"discrete_values,optional"` +} + +type ListAlgorithmsReq struct { + ProjectId string `json:"projectId"` + Offset int32 `json:"offset,optional"` + Limit int32 `json:"limit"` +} + +type ListAlgorithmsResp struct { + Total int32 `json:"total,optional"` + Count int32 `json:"count,optional"` + Limit int32 `json:"limit,optional"` + SortBy string `json:"sortBy,optional"` + Order string `json:"order,optional"` + Items []AlgorithmResponse `json:"items,optional"` +} + +type DeleteAlgorithmReq struct { + ProjectId string `json:"projectId" copier:"ProjectId"` + AlgorithmId string `json:"algorithmId" copier:"AlgorithmId"` +} + +type DeleteAlgorithmResp struct { + Msg string `json:"msg" copier:"Msg"` + Code int32 `json:"code" copier:"Code"` +} + +type ShowAlgorithmByUuidReq struct { + ProjectId string `json:"projectId" copier:"ProjectId"` + AlgorithmId string `json:"algorithmId" copier:"AlgorithmId"` +} + +type ShowAlgorithmByUuidResp struct { + Metadata MetadataAlRq `json:"metadata" copier:"Metadata"` + JobConfig JobConfigAl `json:"jobConfig" copier:"JobConfig"` + ResourceRequirements []ResourceRequirements `json:"resourceRequirements" copier:"ResourceRequirements"` + AdvancedConfig AdvancedConfigAl `json:"advancedConfig" copier:"AdvancedConfig"` + Msg string `json:"msg" copier:"Msg"` + Code int32 `json:"code" copier:"Code"` +} + +type MetadataAlRq struct { + Id string `json:"id,optional"` + Name string `json:"name,optional"` + Description string `json:"description,optional"` + WorkspaceId string `json:"workspaceId,optional"` + AiProject string `json:"aiProject,optional"` +} + +type JobConfigAl struct { + CodeDir string `json:"codeDir,optional"` + BootFile string `json:"bootFile,optional"` + Command string `json:"command,optional"` + Parameters []ParametersAlRq `json:"parameters,optional"` + ParametersCustomization bool `json:"parameters_customization,optional"` + Inputs []InputsAlRq `json:"inputs,optional"` + Outputs []OutputsAl `json:"outputs,optional"` + Engine EngineAlRq `json:"engine,optional"` +} + +type ShareInfo struct { +} + +type CreateAlgorithmReq struct { + MetadataCARq MetadataAlRq `json:"metadata,optional"` + JobConfigCARq JobConfigAl `json:"jobConfig,optional"` + ResourceRequirementsCARq []ResourceRequirements `json:"resourceRequirements,optional"` + AdvancedConfigCARq AdvancedConfigAl `json:"advancedConfig,optional"` + ProjectIdCARq string `json:"projectId"` +} + +type CreateAlgorithmResp struct { + Resp200 *CreateAlgorithmResp201 `json:"resp200,omitempty"` + Resp400 *CreateAlgorithmResp400 `json:"resp400,omitempty"` +} + +type CreateAlgorithmResp400 struct { + ErrorMsg string `json:"errorMsg,omitempty"` + ErrorCode string `json:"errorCode,omitempty"` + ErrorSolution string `json:"errorSolution,omitempty"` +} + +type CreateAlgorithmResp201 struct { + MetadataCARp MetadataAlRp `json:"metadata,optional"` + Share_infoCARp ShareInfo `json:"shareInfo,optional"` + JobConfigCARp JobConfigAl `json:"jobConfig,optional"` + ResourceRequirementsCARp []ResourceRequirements `json:"resourceRequirements,optional"` + AdvancedConfigCARp AdvancedConfigAl `json:"advancedConfig,optional"` +} + +type DeleteDataSetReq struct { + DatasetId string `json:"datasetId"` + ProjectId string `json:"projectId"` +} + +type DeleteDataSetResp struct { +} + +type ListNotebookReq struct { + Project_id string `json:"project_id"` + Param ListNotebookParam `json:"param"` +} + +type ListNotebookResp struct { + Current int32 `json:"current"` + Data []NotebookResp `json:"data"` + Pages int32 `json:"pages"` + Size int32 `json:"size"` + Total int64 `json:"total"` +} + +type ListNotebookParam struct { + Feature string `json:"feature"` + Limit int32 `json:"limit"` + Name string `json:"name"` + Pool_id string `json:"pool_id"` + Offset int32 `json:"offset"` + Owner string `json:"owner"` + Sort_dir string `json:"sort_dir"` + Sort_key string `json:"sort_key"` + Status string `json:"status"` + WorkspaceId string `json:"workspaceId"` +} + +type CreateNotebookReq struct { + Project_id string `json:"project_id"` + Param CreateNotebookParam `json:"param"` +} + +type CreateNotebookResp struct { + NotebookResp NotebookResp `json:"notebookResp"` +} + +type CreateNotebookParam struct { + Description string `json:"description"` + Duration int64 `json:"duration"` + Endpoints []EndpointsReq `json:"endpoints"` + Feature string `json:"feature"` + Flavor string `json:"flavor"` + Image_id string `json:"image_id"` + Name string `json:"name"` + Pool_id string `json:"pool_id"` + Volume VolumeReq `json:"volume"` + Workspace_id string `json:"workspace_id"` + Hooks CustomHooks `json:"hooks"` + Lease LeaseReq `json:"lease"` +} + +type StartNotebookReq struct { + Id string `json:"id"` + Project_id string `json:"project_id"` + Param StartNotebookParam `json:"param"` +} + +type StartNotebookResp struct { + NotebookResp NotebookResp `json:"notebookResp"` +} + +type StartNotebookParam struct { + Duration int64 `json:"duration"` + Type_start_notebook string `json:"type"` +} + +type StopNotebookReq struct { + Id string `json:"id"` + Project_id string `json:"project_id"` +} + +type StopNotebookResp struct { + NotebookResp NotebookResp `json:"notebookResp"` +} + +type GetNotebookStorageReq struct { + Instance_id string `json:"instance_id"` + Project_id string `json:"project_id"` +} + +type GetNotebookStorageResp struct { + Current int32 `json:"current"` + Data []DataVolumesRes `json:"data"` + Pages int32 `json:"pages"` + Size int32 `json:"size"` + Total int64 `json:"total"` +} + +type MountNotebookStorageReq struct { + Instance_id string `json:"instance_id"` + Project_id string `json:"project_id"` + Param MountNotebookStorageParam `json:"param"` +} + +type MountNotebookStorageResp struct { + Category string `json:"category"` + Id string `json:"id"` + Mount_path string `json:"mount_path"` + Status string `json:"status"` + Uri string `json:"uri"` +} + +type MountNotebookStorageParam struct { + Category string `json:"category"` + Mount_path string `json:"mount_path"` + Uri string `json:"uri"` +} + +type DataVolumesRes struct { + Category string `json:"category"` + Id string `json:"id"` + Mount_path string `json:"mount_path"` + Status string `json:"status"` + Uri string `json:"uri"` +} + +type NotebookResp struct { + Action_progress []JobProgress `json:"action_progress"` + Description string `json:"description"` + Endpoints []EndpointsRes `json:"endpoints"` + Fail_reason string `json:"fail_reason"` + Flavor string `json:"flavor"` + Id string `json:"id"` + Image Image `json:"image"` + Lease Lease `json:"lease"` + Name string `json:"name"` + Pool Pool `json:"pool"` + Status string `json:"status"` + Token string `json:"token"` + Url string `json:"url"` + Volume VolumeRes `json:"volume"` + Workspace_id string `json:"workspace_id"` + Feature string `json:"feature"` +} + +type JobProgress struct { + Notebook_id string `json:"notebook_id"` + Status string `json:"status"` + Step int32 `json:"step"` + Step_description string `json:"step_description"` +} + +type EndpointsRes struct { + Allowed_access_ips []string `json:"allowed_access_ips"` + Dev_service string `json:"dev_service"` + Ssh_keys []string `json:"ssh_keys"` +} + +type Image struct { + Arch string `json:"arch"` + Create_at int64 `json:"create_at"` + Description string `json:"description"` + Dev_services []string `json:"dev_services"` + Id string `json:"id"` + Name string `json:"name"` + Namespace string `json:"namespace"` + Origin string `json:"origin"` + Resource_categories []string `json:"resource_categories"` + Service_type string `json:"service_type"` + Size int64 `json:"size"` + Status string `json:"status"` + Status_message string `json:"status_message"` + Support_res_categories []string `json:"support_res_categories"` + Swr_path string `json:"swr_path"` + Tag string `json:"tag"` + Type_image string `json:"type"` + Update_at int64 `json:"update_at"` + Visibility string `json:"visibility"` + Workspace_id string `json:"workspace_id"` +} + +type Lease struct { + Create_at int64 `json:"create_at"` + Duration int64 `json:"duration"` + Enable bool `json:"enable"` + Type_lease string `json:"type"` + Update_at int64 `json:"update_at"` +} + +type Pool struct { + Id string `json:"id"` + Name string `json:"name"` +} + +type VolumeRes struct { + Capacity int64 `json:"capacity"` + Category string `json:"category"` + Mount_path string `json:"mount_path"` + Ownership string `json:"ownership"` + Status string `json:"status"` +} + +type EndpointsReq struct { + Allowed_access_ips []string `json:"allowed_access_ips"` + Dev_service string `json:"dev_service"` + Ssh_keys []string `json:"ssh_keys"` +} + +type VolumeReq struct { + Capacity int64 `json:"capacity"` + Category string `json:"category"` + Ownership string `json:"ownership"` + Uri string `json:"uri"` +} + +type CustomHooks struct { + Container_hooks ContainerHooks `json:"container_hooks"` +} + +type ContainerHooks struct { + Post_start Config `json:"post_start"` + Pre_start Config `json:"pre_start"` +} + +type Config struct { + Script string `json:"script"` + Type_config string `json:"type"` +} + +type LeaseReq struct { + Duration int64 `json:"duration"` + Type_lease_req string `json:"type"` +} + +type GetVisualizationJobReq struct { + Project_id string `json:"project_id"` + Param GetVisualizationJobParam `json:"param"` +} + +type GetVisualizationJobResp struct { + Is_success bool `json:"is_success"` + Error_code string `json:"error_code"` + Error_message string `json:"error_message"` + Job_total_count int32 `json:"job_total_count"` + Job_count_limit int32 `json:"job_count_limit"` + Jobs []Jobs `json:"jobs"` + Quotas int32 `json:"quotas"` +} + +type Jobs struct { + Job_name string `json:"job_name"` + Status int32 `json:"status"` + Create_time int64 `json:"create_time"` + Duration int64 `json:"duration"` + Job_desc string `json:"job_desc"` + Service_url string `json:"service_url"` + Train_url string `json:"train_url"` + Job_id string `json:"job_id"` + Resource_id string `json:"resource_id"` +} + +type GetVisualizationJobParam struct { + Status string `json:"status"` + Per_page int32 `json:"per_page"` + Page int32 `json:"page"` + SortBy string `json:"sortBy"` + Order string `json:"order"` + Search_content string `json:"search_content"` + Workspace_id string `json:"workspace_id"` +} + +type CreateVisualizationJobReq struct { + Project_id string `json:"project_id"` + Param CreateVisualizationJobParam `json:"param"` +} + +type CreateVisualizationJobResp struct { + Error_message string `json:"error_message"` + Error_code string `json:"error_code"` + Job_id int64 `json:"job_id"` + Job_name string `json:"job_name"` + Status int32 `json:"status"` + Create_time int64 `json:"create_time"` + Service_url string `json:"service_url"` +} + +type CreateVisualizationJobParam struct { + Job_name string `json:"job_name"` + Job_desc string `json:"job_desc"` + Train_url string `json:"train_url"` + Job_type string `json:"job_type"` + Flavor Flavor `json:"flavor"` + Schedule Schedule `json:"schedule"` +} + +type Flavor struct { + Code string `json:"code"` +} + +type Schedule struct { + Type_schedule string `json:"type"` + Time_unit string `json:"time_unit"` + Duration int32 `json:"duration"` +} + +type CreateTrainingJobReq struct { + Kind string `json:"kind,optional"` + Metadatas MetadataS `json:"metadata,optional"` + AlgorithmsCtRq AlgorithmsCtRq `json:"algorithm,optional"` + SpecsCtRq SpecsCtRq `json:"spec,optional"` + ProjectId string `json:"projectId,optional"` +} + +type CreateTrainingJobResp201 struct { + Kind string `json:"kind"` + Metadatas MetadataS `json:"metadata"` + Status Status `json:"status"` + SpecCtRp SpecCtRp `json:"spec"` + Algorithms AlgorithmsCtRq `json:"algorithm"` +} + +type CreateTrainingJobResp400 struct { + ErrorMsg string `json:"errorMsg,omitempty"` + ErrorCode string `json:"errorCode,omitempty"` + ErrorSolution string `json:"errorSolution,omitempty"` +} + +type CreateTrainingJobResp struct { + Resp201 CreateTrainingJobResp201 `json:"resp201,omitempty"` + Resp400 CreateTrainingJobResp400 `json:"resp400,omitempty"` +} + +type MetadataS struct { + Id string `json:"id,optional"` + Name string `json:"name,optional"` + Description string `json:"description,optional"` + WorkspaceId string `json:"workspaceId,optional"` +} + +type EngineCreateTraining struct { + EngineId string `json:"engineId,optional"` + EngineName string `json:"engineName,optional"` + EngineVersion string `json:"engineVersion,optional"` + ImageUrl string `json:"imageUrl,optional"` +} + +type ConstraintCreateTraining struct { + Type string `json:"type,optional"` + Editable bool `json:"editable,optional"` + Required bool `json:"required,optional"` + Sensitive bool `json:"sensitive,optional"` + ValidType string `json:"validType,optional"` +} + +type ParametersTrainJob struct { + Name string `json:"name,optional"` + Description string `json:"description,optional"` + Value string `json:"value,optional"` + ConstraintCreateTraining ConstraintCreateTraining `json:"constraint,optional"` +} + +type PoliciesCreateTraining struct { +} + +type AlgorithmsCtRq struct { + Id string `json:"id,optional"` + Name string `json:"name,optional"` + CodeDir string `json:"codeDir,optional"` + BootFile string `json:"bootFile,optional"` + EngineCreateTraining EngineCreateTraining `json:"engine,optional"` + ParametersTrainJob []ParametersTrainJob `json:"parameters,optional"` + PoliciesCreateTraining PoliciesCreateTraining `json:"policies,optional"` + Command string `json:"command,optional"` +} + +type ResourceCreateTraining struct { + FlavorId string `json:"flavorId,optional"` + NodeCount int32 `json:"nodeCount,optional"` +} + +type LogExportPathCreateTrainingJob struct { + ObsUrl string `json:"obs_url,optional"` +} + +type SpecsCtRq struct { + Resource ResourceCreateTraining `json:"resource,optional"` + Volumes []Volumes `json:"volumes,optional"` + LogExportPath LogExportPath `json:"logExportPath,optional"` +} + +type SpecCtRp struct { + Resource ResourceCreateTraining `json:"resource,optional"` + Volumes []Volumes `json:"volumes,optional"` + LogExportPath LogExportPath `json:"logExportPath,optional"` +} + +type LogExportPath struct { + ObsUrl string `json:"obsUrl,optional"` + HostPath string `json:"hostPath,optional"` +} + +type Volumes struct { + Nfs *Nfs `json:"nfs,optional"` +} + +type Nfs struct { + NfsServerPath string `json:"nfsServer_path,optional"` + LocalPath string `json:"localPath,optional"` + ReadOnly bool `json:"readOnly,optional"` +}