forked from JointCloud/pcm-coordinator
1837 lines
82 KiB
Plaintext
1837 lines
82 KiB
Plaintext
syntax = "v1"
|
|
|
|
info(
|
|
title: "AI core"
|
|
desc: "AI core微服务"
|
|
author: "wanqgi"
|
|
email: "1364512070@qq.com"
|
|
)
|
|
/******************find datasetList start*************************/
|
|
|
|
type DataSets {
|
|
DatasetId string `json:"datasetId" copier:"DatasetId"`
|
|
DataFormat string `json:"dataFormat" copier:"DataFormat"`
|
|
DataSources []DataSources `json:"dataSources" copier:"DataSources"`
|
|
DatasetFormat int32 `json:"datasetFormat" copier:"DatasetFormat"`
|
|
DatasetName string `json:"datasetName" copier:"DatasetName"`
|
|
DatasetType int32 `json:"datasetType" copier:"DatasetType"`
|
|
ImportData bool `json:"importData" copier:"ImportData"`
|
|
TotalSampleCount int32 `json:"totalSampleCount" copier:"TotalSampleCount"`
|
|
CreateTime int64 `json:"createTime" copier:"CreateTime"`
|
|
description string `json:"description" copier:"Description"`
|
|
}
|
|
|
|
type DataSources {
|
|
DataPath string `json:"dataPath" copier:"DataPath"`
|
|
DataType int32 `json:"dataType" copier:"DataType"`
|
|
}
|
|
|
|
type (
|
|
DataSetReq {
|
|
ProjectId string `path:"projectId"`
|
|
Limit int32 `form:"limit,optional"`
|
|
OffSet int32 `form:"offSet,optional"`
|
|
/****************parmas from modelArtsType ********************/
|
|
modelArtsType string `form:"modelArtsType,optional"`
|
|
}
|
|
DataSetResp {
|
|
TotalNumber uint32 `json:"totalNumber" copier:"TotalNumber"`
|
|
Datasets []DataSets `json:"dataSets" copier:"Datasets"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"errorMsg,omitempty"`
|
|
}
|
|
)
|
|
|
|
/******************find datasetList end*************************/
|
|
|
|
/******************Create dataset start*************************/
|
|
|
|
type CreateDataSetReq {
|
|
DatasetName string `json:"datasetName" copier:"DatasetName"`
|
|
DatasetType int32 `json:"datasetType" copier:"DatasetType"`
|
|
Description string `json:"description" copier:"Description"`
|
|
WorkPath string `json:"workPath" copier:"WorkPath"`
|
|
WorkPathType int32 `json:"workPathType" copier:"WorkPathType"`
|
|
ProjectId string `path:"projectId" copier:"ProjectId"`
|
|
DataSources []DataSources `json:"dataSources" copier:"DataSources"`
|
|
/****************parmas from modelArtsType ********************/
|
|
modelArtsType string `json:"modelArtsType,optional"`
|
|
}
|
|
|
|
type CreateDataSetResp {
|
|
DatasetId string `json:"datasetId" copier:"DatasetId"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
|
|
/******************Create dataset end*************************/
|
|
/******************ImportTask start*************************/
|
|
type (
|
|
ImportTaskDataReq {
|
|
ProjectId string `path:"projectId"`
|
|
DatasetId string `path:"datasetId"`
|
|
ImportPath string `json:"importPath"`
|
|
/****************parmas from modelArtsType ********************/
|
|
modelArtsType string `json:"modelArtsType,optional"`
|
|
}
|
|
ImportTaskDataResp{
|
|
TaskId string `json:"taskId,omitempty"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
|
|
)
|
|
/******************ImportTask end*************************/
|
|
|
|
/******************ExportTask start*************************/
|
|
type (
|
|
CreateExportTaskReq {
|
|
ProjectId string `path:"projectId" copier:"ProjectId"`
|
|
DatasetId string `path:"datasetId" 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"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelartsType,optional"`
|
|
}
|
|
)
|
|
type ExportTaskDataResp {
|
|
TaskId string `json:"taskId,omitempty" copier:"TaskId"`
|
|
CreateTime uint32 `json:"createTime,omitempty" copier:"CreateTime"`
|
|
ExportFormat int64 `json:"exportFormat,omitempty" copier:"ExportFormat"`
|
|
ExportParams ExportParams `json:"exportParams,omitempty" copier:"ExportParams"`
|
|
FinishedSampleCount int32 `json:"finishedSampleCount,omitempty" copier:"FinishedSampleCount"`
|
|
Path string `json:"path,omitempty" copier:"Path"`
|
|
Progress float64 `json:"progress,omitempty" copier:"Progress"`
|
|
Status string `json:"status,omitempty" copier:"Status"`
|
|
TotalSampleCount int64 `json:"totalSampleCount,omitempty" copier:"TotalSampleCount"`
|
|
UpdateTime uint32 `json:"updateTime,omitempty" copier:"UpdateTime"`
|
|
VersionFormat string `json:"versionFormat,omitempty" copier:"VersionFormat"`
|
|
VersionId string `json:"versionId,omitempty" copier:"VersionId"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
|
|
type ExportParams {
|
|
ClearHardProperty bool `json:"clearHardProperty" copier:"ClearHardProperty"`
|
|
ExportDatasetVersionFormat string `json:"exportDatasetVersionFormat,optional" copier:"ExportDatasetVersionFormat"`
|
|
ExportDatasetVersionName string `json:"exportDatasetVersionName,optional" copier:"ExportDatasetVersionName"`
|
|
ExportDest string `json:"exportDest,optional" copier:"ExportDest"`
|
|
ExportNewDatasetWorkName string `json:"exportNewDatasetWorkName,optional" copier:"ExportNewDatasetWorkName"`
|
|
ExportNewDatasetWorkPath string `json:"exportNewDatasetWorkPath,optional" copier:"ExportNewDatasetWorkPath"`
|
|
RatioSampleUsage bool `json:"ratioSampleUsage,optional" copier:"RatioSampleUsage"`
|
|
SampleState string `json:"sampleState,optional" copier:"SampleState"`
|
|
Sample []string `json:"sample,optional" copier:"Sample"`
|
|
SearchConditions []SearchCondition `json:"searchConditions,optional" copier:"SearchConditions"`
|
|
TrainSampleRatio string `json:"trainSampleRatio,optional" copier:"TrainSampleRatio"`
|
|
}
|
|
|
|
type SearchCondition {
|
|
Coefficient string `json:"coefficient,optional" copier:"Coefficient"`
|
|
FrameInVideo int64 `json:"frameInVideo,optional" copier:"FrameInVideo"`
|
|
Hard string `json:"hard,optional" copier:"Hard"`
|
|
Kvp string `json:"kvp,optional" copier:"Kvp"`
|
|
ImportOrigin string `json:"importOrigin,optional" copier:"ImportOrigin"`
|
|
LabelList SearchLabels `json:"labelList,optional" copier:"LabelList"`
|
|
Labeler string `json:"labeler,optional" copier:"Labeler"`
|
|
ParentSampleId string `json:"parentSampleId,optional" copier:"ParentSampleId"`
|
|
Metadata SearchProp `json:"metadata,optional" copier:"Metadata"`
|
|
SampleDir string `json:"sampleDir,optional" copier:"SampleDir"`
|
|
SampleName string `json:"sampleName,optional" copier:"SampleName"`
|
|
SampleTime string `json:"sampleTime,optional" copier:"SampleTime"`
|
|
Score string `json:"score,optional" copier:"Score"`
|
|
SliceThickness string `json:"sliceThickness,optional" copier:"SliceThickness"`
|
|
StudyDate string `json:"StudyDate,optional" copier:"StudyDate"`
|
|
TimeInVideo string `json:"timeInVideo,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<string,weigou> `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 `path:"projectId" copier:"ProjectId"`
|
|
DatasetId string `path:"datasetId" copier:"DatasetId"`
|
|
ExportType int32 `json:"exportType,optional" copier:"ExportType"`
|
|
Limit int32 `form:"limit,optional"`
|
|
Offset int32 `form:"offset,optional"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelartsType,optional"`
|
|
}
|
|
)
|
|
type GetExportTasksOfDatasetResp {
|
|
TaskId string `json:"taskId,omitempty" copier:"TaskId"`
|
|
CreateTime uint32 `json:"createTime,omitempty" copier:"CreateTime"`
|
|
ExportFormat int64 `json:"exportFormat,omitempty" copier:"ExportFormat"`
|
|
ExportParams ExportParams `json:"exportParams,omitempty" copier:"ExportParams"`
|
|
ExportTasks []ExportTaskStatus `json:"exportTasks,omitempty" copier:"ExportTasks"`
|
|
FinishedSampleCount int32 `json:"finishedSampleCount,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:"totalCount,omitempty" copier:"TotalCount"`
|
|
UpdateTime uint32 `json:"updateTime,omitempty" copier:"UpdateTime"`
|
|
VersionFormat string `json:"versionFormat,omitempty" copier:"VersionFormat"`
|
|
VersionId string `json:"versionId,omitempty" copier:"VersionId"`
|
|
ExportType int32 `json:"exportType,omitempty" copier:"ExportType"`
|
|
TotalSample int64 `json:"totalSample,omitempty" copier:"TotalSample"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
type ExportTaskStatus {
|
|
TaskId string `json:"taskId,omitempty" copier:"TaskId"`
|
|
CreateTime uint32 `json:"createTime,omitempty" copier:"CreateTime"`
|
|
ErrorCode string `json:"errorCode,omitempty" copier:"ErrorCode"`
|
|
ErrorMsg string `json:"errorMsg,omitempty" copier:"ErrorMsg"`
|
|
ExportFormat int64 `json:"exportFormat,omitempty" copier:"ExportFormat"`
|
|
ExportParams ExportParams `json:"exportParams,omitempty" copier:"ExportParams"`
|
|
FinishedSampleCount int32 `json:"finishedSampleCount,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:"totalCount,omitempty" copier:"TotalCount"`
|
|
UpdateTime uint32 `json:"updateTime,omitempty" copier:"UpdateTime"`
|
|
VersionFormat string `json:"versionFormat,omitempty" copier:"VersionFormat"`
|
|
VersionId string `json:"versionId,omitempty" copier:"VersionId"`
|
|
ExportType int32 `json:"exportType,omitempty" copier:"ExportType"`
|
|
TotalSample int64 `json:"totalSample,omitempty" copier:"TotalSample"`
|
|
}
|
|
/******************Get Export Tasks Of Dataset End*************************/
|
|
|
|
/******************Get Export Task Status Of Dataset Start*************************/
|
|
type (
|
|
GetExportTaskStatusOfDatasetReq {
|
|
ProjectId string `path:"projectId"`
|
|
ResourceId string `path:"resourceId"`
|
|
TaskId string `path:"taskId"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelartsType,optional"`
|
|
}
|
|
)
|
|
type GetExportTaskStatusOfDatasetResp {
|
|
TaskId string `json:"taskId,optional" copier:"TaskId"`
|
|
CreateTime uint32 `json:"createTime,optional" copier:"CreateTime"`
|
|
ExportFormat int64 `json:"exportFormat,optional" copier:"ExportFormat"`
|
|
ExportParams ExportParams `json:"exportParams,optional" copier:"ExportParams"`
|
|
ExportTasks []ExportTaskStatus `json:"exportTasks,optional" copier:"ExportTasks"`
|
|
FinishedSampleCount int32 `json:"finishedSampleCount,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:"totalCount,optional" copier:"TotalCount"`
|
|
UpdateTime uint32 `json:"updateTime,optional" copier:"UpdateTime"`
|
|
VersionFormat string `json:"versionFormat,optional" copier:"VersionFormat"`
|
|
VersionId string `json:"versionId,optional" copier:"VersionId"`
|
|
ExportType int32 `json:"exportType,optional" copier:"ExportType"`
|
|
TotalSample int64 `json:"totalSample,optional" copier:"TotalSample"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
|
|
/******************Get Export Task Status Of Dataset End*************************/
|
|
|
|
/******************Create Processor Task Start*************************/
|
|
type (
|
|
CreateProcessorTaskReq {
|
|
ProjectId string `json:"datasetId" copier:"ProjectId"`
|
|
CreateVersion bool `json:"createVersion,optional" copier:"CreateVersion"`
|
|
Description string `json:"description,optional" copier:"Description"`
|
|
DataSources ProcessorDataSource `json:"dataSource,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:"versionId,optional" copier:"VersionId"`
|
|
WorkPath WorkPath `json:"workPath,optional" copier:"WorkPath"`
|
|
WorkspaceId string `json:"workspaceId,optional" copier:"WorkspaceId"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelartsType,optional"`
|
|
}
|
|
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:"versionId,optional" copier:"VersionId"`
|
|
VersionName string `json:"versionName,optional" copier:"VersionName"`
|
|
}
|
|
type TemplateParam {
|
|
Id string `json:"id,optional" copier:"Id"`
|
|
Name string `json:"name,optional" copier:"Name"`
|
|
OperatorParam []OperatorParam `json:"operatorParams,optional" copier:"OperatorParam"`
|
|
}
|
|
type WorkPath {
|
|
Name string `json:"name,optional" copier:"name"`
|
|
OutputPath string `json:"outputPath,optional" copier:"OutputPath"`
|
|
Path string `json:"path,optional" copier:"Path"`
|
|
Type string `json:"type,optional" copier:"type"`
|
|
VersionId string `json:"versionId,optional" copier:"VersionId"`
|
|
VersionName string `json:"versionName,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:"advancedParamsSwitch,optional" copier:"AdvancedParamsSwitch"`
|
|
}
|
|
/******************Create Processor Task End*************************/
|
|
|
|
/******************taskList start*************************/
|
|
type (
|
|
ListImportTasksReq {
|
|
ProjectId string `path:"projectId"`
|
|
DatasetId string `path:"datasetId"`
|
|
Limit int32 `form:"limit,optional"`
|
|
Offset int32 `form:"offSet,optional"`
|
|
/****************parmas from modelArtsType ********************/
|
|
modelArtsType string `form:"modelArtsType,optional"`
|
|
}
|
|
ListImportTasksResp {
|
|
TotalCount uint32 `json:"totalCount,omitempty"`
|
|
ImportTasks []*ImportTasks `json:"importTasks,omitempty"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
)
|
|
type ImportTasks {
|
|
Status string `json:"status,omitempty"`
|
|
TaskId string `json:"taskId,omitempty"`
|
|
DatasetId string `json:"datasetId,omitempty"`
|
|
ImportPath string `json:"importPath,omitempty"`
|
|
ImportType int32 `json:"importType,omitempty"`
|
|
TotalSampleCount uint32 `json:"totalSampleCount,omitempty"`
|
|
ImportedSampleCount uint32 `json:"importedSampleCount,omitempty"`
|
|
AnnotatedSampleCount uint32 `json:"annotatedSampleCount,omitempty"`
|
|
TotalSubSampleCount uint32 `json:"totalSubSampleCount,omitempty"`
|
|
ImportedSubSampleCount uint32 `json:"importedSubSampleCount,omitempty"`
|
|
TotalFileSize uint32 `json:"totalFileSize,omitempty"`
|
|
FinishedFileCount uint32 `json:"finishedFileCount,omitempty"`
|
|
FinishedFileSize uint32 `json:"finishedFileSize,omitempty"`
|
|
TotalFileCount uint32 `json:"totalFileCount,omitempty"`
|
|
CreateTime uint32 `json:"createTime,omitempty"`
|
|
ElapsedTime uint32 `json:"elapsedTime,omitempty"`
|
|
AnnotationFormatConfig []interface{} `json:"annotationFormatConfig,omitempty"`
|
|
}
|
|
/******************taskList end*************************/
|
|
/******************ListTrainingJobs start*************************/
|
|
type Annotations {
|
|
JobTemplate string `json:"jobTemplate"`
|
|
KeyTask string `json:"keyTask"`
|
|
}
|
|
type TrainingExperimentReference {
|
|
}
|
|
type Metadata {
|
|
ID string `json:"id"`
|
|
Name string `json:"name"`
|
|
Description string `json:"description"`
|
|
CreateTime uint64 `json:"createTime"`
|
|
WorkspaceID string `json:"workspaceId"`
|
|
AiProject string `json:"aiProject"`
|
|
UserName string `json:"userName"`
|
|
Annotations Annotations `json:"annotations"`
|
|
TrainingExperimentReference TrainingExperimentReference `json:"trainingExperimentReference"`
|
|
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:"memUsage"`
|
|
Util Util `json:"util"`
|
|
UnitNum int32 `json:"unitNum"`
|
|
ProductName string `json:"productName"`
|
|
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:"validType"`
|
|
ValidRange interface{} `json:"validRange,optional"`
|
|
}
|
|
type Parameters {
|
|
Name string `json:"name"`
|
|
Description string `json:"description"`
|
|
I18NDescription interface{} `json:"i18nDescription"`
|
|
Value string `json:"value"`
|
|
Constraint Constraint `json:"constraint"`
|
|
}
|
|
type Obs {
|
|
ObsURL string `json:"obsUrl"`
|
|
}
|
|
type Remote {
|
|
Obs Obs `json:"obs"`
|
|
}
|
|
type Attributes {
|
|
DataFormat []string `json:"dataFormat"`
|
|
DataSegmentation []string `json:"dataSegmentation"`
|
|
DatasetType []string `json:"datasetType"`
|
|
IsFree string `json:"isFree"`
|
|
MaxFreeJobCount string `json:"maxFreeJobCount"`
|
|
}
|
|
type RemoteConstraints {
|
|
DataType string `json:"dataType"`
|
|
Attributes Attributes `json:"attributes,omitempty"`
|
|
}
|
|
type Inputs {
|
|
Name string `json:"name"`
|
|
Description string `json:"description"`
|
|
LocalDir string `json:"localDir"`
|
|
AccessMethod string `json:"accessMethod"`
|
|
Remote Remote `json:"remote"`
|
|
RemoteConstraints []RemoteConstraints `json:"remoteConstraints"`
|
|
}
|
|
type Outputs {
|
|
Name string `json:"name"`
|
|
LocalDir string `json:"localDir"`
|
|
AccessMethod string `json:"accessMethod"`
|
|
Remote Remote `json:"remote"`
|
|
Mode string `json:"mode"`
|
|
Period int32 `json:"period"`
|
|
PrefetchToLocal bool `json:"prefetchToLocal"`
|
|
}
|
|
type Engine {
|
|
EngineID string `json:"engineId"`
|
|
EngineName string `json:"engineName"`
|
|
EngineVersion string `json:"engineVersion"`
|
|
V1Compatible bool `json:"v1Compatible"`
|
|
RunUser string `json:"runUser"`
|
|
ImageSource bool `json:"imageSource"`
|
|
}
|
|
type Policies {
|
|
}
|
|
type Algorithm {
|
|
ID string `json:"id"`
|
|
Name string `json:"name"`
|
|
V1Algorithm bool `json:"v1Algorithm"`
|
|
SubscriptionID string `json:"subscriptionId"`
|
|
ItemVersionID string `json:"itemVersionId"`
|
|
ContentID string `json:"contentId"`
|
|
Parameters []Parameters `json:"parameters"`
|
|
ParametersCustomization bool `json:"parametersCustomization"`
|
|
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:"unitNum"`
|
|
}
|
|
type CPU {
|
|
Arch string `json:"arch"`
|
|
CoreNum int32 `json:"coreNum"`
|
|
}
|
|
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:"flavorType"`
|
|
Billing Billing `json:"billing"`
|
|
Attributes Attributes `json:"attributes"`
|
|
FlavorInfo FlavorInfo `json:"flavorInfo"`
|
|
}
|
|
type Resource {
|
|
Policy string `json:"policy,optional"`
|
|
FlavorId string `json:"flavorId,optional"`
|
|
FlavorName string `json:"flavorName,optional"`
|
|
NodeCount int32 `json:"nodeCount,optional"`
|
|
FlavorDetail FlavorDetail `json:"flavorDetail,optional"`
|
|
}
|
|
type LogExportPathCreateTraining {
|
|
}
|
|
type Spec {
|
|
Resource Resource `json:"resource"`
|
|
LogExportPath LogExportPath `json:"logExportPath"`
|
|
IsHostedLog bool `json:"isHostedLog"`
|
|
}
|
|
type Items {
|
|
Kind string `json:"kind"`
|
|
Metadata Metadata `json:"metadata"`
|
|
Status Status `json:"status"`
|
|
Algorithm JobAlgorithmResponse `json:"algorithm,omitempty"`
|
|
Spec Spec `json:"spec"`
|
|
projectId string `json:"projectId"`
|
|
}
|
|
type JobAlgorithmResponse{
|
|
ID string `json:"id"`
|
|
Name string `json:"name"`
|
|
SubscriptionID string `json:"subscriptionId"`
|
|
ItemVersionID string `json:"itemVersionId"`
|
|
CodeDir string `json:"codeDir"`
|
|
BootFile string `json:"bootFile"`
|
|
AutosearchConfigPath string `json:"autosearchConfigPath"`
|
|
AutosearchFrameworkPath string `json:"autosearchFrameworkPath"`
|
|
Command string `json:"command"`
|
|
Parameters []Parameters `json:"parameters"`
|
|
Policies Policies `json:"policies"`
|
|
Inputs []Inputs `json:"inputs"`
|
|
Outputs []Outputs `json:"outputs"`
|
|
Engine Engine `json:"engine"`
|
|
LocalCodeDir string `json:"localCodeDir"`
|
|
WorkingDir string `json:"workingDir"`
|
|
Environments []map[string]string `json:"environments"`
|
|
}
|
|
type (
|
|
ListTrainingJobsreq {
|
|
ProjectId string `path:"projectId"`
|
|
Limit int32 `form:"limit,optional"`
|
|
Offset int32 `form:"offSet,optional"`
|
|
/****************parmas from octpus
|
|
platform string `json:"platform,optional"`
|
|
pageIndex int32 `json:"pageIndex,optional"`
|
|
pageSize int32 `json:"pageSize,optional"`********************/
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `form:"modelArtsType,optional"`
|
|
}
|
|
ListTrainingJobsresp {
|
|
Total int32 `json:"total"`
|
|
Count int32 `json:"count,omitempty"`
|
|
Limit int32 `json:"limit,omitempty"`
|
|
Offset int32 `json:"offset,omitempty"`
|
|
SortBy string `json:"sortBy,omitempty"`
|
|
Order string `json:"order,omitempty"`
|
|
GroupBy string `json:"groupBy,omitempty"`
|
|
WorkspaceID string `json:"workspaceId,omitempty"`
|
|
AiProject string `json:"aiProject,omitempty"`
|
|
Items []*Items `json:"items,omitempty"`
|
|
Code int32 `json:"code,omitempty,omitempty"`
|
|
Msg string `json:"msg,omitempty,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
/****************parmas from octpus
|
|
success bool `json:"success"`
|
|
payload PayloadGetTrainJobList `json:"payload"`
|
|
error Error `json:"error"`********************/
|
|
}
|
|
/****************parmas from octpus
|
|
PayloadGetTrainJobList {
|
|
totalSize int32 `json:"totalSize"`
|
|
trainJobs []*TrainJob `json:"trainJobs,optional,omitempty"`
|
|
}
|
|
TrainJob {
|
|
algorithmId string `json:"algorithmId,optional" copier:"algorithmId"`
|
|
algorithmName string `json:"algorithmId,optional" copier:"algorithmId"`
|
|
algorithmVersion string `json:"algorithmVersion,optional" copier:"algorithmVersion"`
|
|
completedAt int64 `json:"completedAt,optional" copier:"completedAt"`
|
|
config []*Config `json:"config,optional" copier:"config"`
|
|
createdAt int64 `json:"createdAt,optional" copier:"createdAt"`
|
|
dataSetId string `json:"dataSetId,optional" copier:"dataSetId"`
|
|
dataSetName string `json:"dataSetName,optional" copier:"dataSetName"`
|
|
dataSetVersion string `json:"dataSetVersion,optional" copier:"dataSetVersion"`
|
|
desc string `json:"desc,optional" copier:"desc"`
|
|
id string `json:"id,optional" copier:"id"`
|
|
imageId string `json:"imageId,optional" copier:"imageId"`
|
|
imageName string `json:"imageName,optional" copier:"imageName"`
|
|
imageUrl string `json:"imageUrl,optional" copier:"imageUrl"`
|
|
imageVersion string `json:"imageVersion,optional" copier:"imageVersion"`
|
|
isDistributed string `json:"isDistributed,optional" copier:"isDistributed"`
|
|
name string `json:"name,optional" copier:"name"`
|
|
resourcePool int64 `json:"resourcePool,optional" copier:"resourcePool"`
|
|
runSec int64 `json:"runSec,optional" copier:"runSec"`
|
|
startedAt int64 `json:"startedAt,optional" copier:"startedAt"`
|
|
status string `json:"status,optional" copier:"status"`
|
|
updatedAt int64 `json:"updatedAt,optional" copier:"updatedAt"`
|
|
userId string `json:"userId,optional" copier:"userId"`
|
|
workspaceId string `json:"workspaceId,optional" copier:"workspaceId"`
|
|
}********************/
|
|
)
|
|
/******************ListTrainingJobs end*************************/
|
|
|
|
/******************DeleteTrainingJob start*************************/
|
|
type (
|
|
DeleteTrainingJobReq {
|
|
Project_id string `path:"projectId"`
|
|
Training_job_id string `path:"trainingJobId"`
|
|
/****************parmas from modelArtsType ********************/
|
|
modelArtsType string `form:"modelArtsType,optional"`
|
|
/****************parmas from octpus
|
|
platform string `path:"platform"`
|
|
jobIds []*string `path:"jobIds"`
|
|
********************/
|
|
}
|
|
DeleteTrainingJobResp {
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
/****************parmas from octpus
|
|
success bool `json:"success,optional"`
|
|
payload PayloadDeleteTrainJob `json:"payload,optional"`
|
|
error Error `json:"error,optional"`
|
|
********************/
|
|
}
|
|
/****************parmas from octpus
|
|
PayloadDeleteTrainJob {
|
|
deletedAt int64 `json:"deletedAt,optional"`
|
|
}********************/
|
|
|
|
)
|
|
/******************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 `path:"projectId"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelartsType,optional"`
|
|
}
|
|
)
|
|
type CreateServiceResp {
|
|
ServiceId string `json:"serviceId,omitempty" copier:"ServiceId"`
|
|
ResourceIds []string `json:"resourceIds,omitempty" copier:"ResourceIds"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
|
|
|
|
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 `path:"projectId"`
|
|
ServiceId string `path:"serviceId"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `form:"modelArtsType,optional"`
|
|
}
|
|
)
|
|
|
|
type DeleteServiceResp {
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
|
|
/******************Delete Service End*************************/
|
|
|
|
/******************ClientList Services Start*************************/
|
|
type (
|
|
ListServicesReq {
|
|
ProjectId string `path:"projectId"`
|
|
Limit int32 `form:"limit,optional"`
|
|
Offset int32 `form:"offSet,optional"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `form:"modelArtsType,optional"`
|
|
Platform string `form:"platform,optional"`
|
|
}
|
|
)
|
|
type ListServicesResp {
|
|
TotalCount int32 `json:"total,omitempty" copier:"TotalCount"`
|
|
Count int32 `json:"count,omitempty" copier:"Count"`
|
|
Services []ListServices `json:"services,omitempty" copier:"Services"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
|
|
type ListServices {
|
|
FailedTimes uint32 `json:"failedTimes,omitempty" copier:"FailedTimes"`
|
|
Owner string `json:"owner,omitempty" copier:"Owner"`
|
|
DueTime int32 `json:"dueTime,omitempty" copier:"DueTime"`
|
|
FinishedTime int32 `json:"finishedTime,omitempty" copier:"FinishedTime"`
|
|
InferType string `json:"inferType,omitempty" copier:"InferType"`
|
|
ServiceName string `json:"serviceName,omitempty" copier:"ServiceName"`
|
|
Description string `json:"description,omitempty" copier:"Description"`
|
|
Project string `json:"project,omitempty" copier:"Project"`
|
|
InvocationTimes uint32 `json:"invocationTimes,omitempty" copier:"InvocationTimes"`
|
|
PublishAt uint32 `json:"publishAt,omitempty" copier:"PublishAt"`
|
|
WorkspaceId string `json:"workspaceId,omitempty" copier:"WorkspaceId"`
|
|
Scheduler []*Scheduler `json:"scheduler,omitempty" copier:"Scheduler"`
|
|
StartTime int32 `json:"startTime,omitempty" copier:"StartTime"`
|
|
OperationTime string `json:"operationTime,omitempty" copier:"OperationTime"`
|
|
IsShared bool `json:"isShared,omitempty" copier:"IsShared"`
|
|
ServiceId string `json:"serviceId,omitempty" copier:"ServiceId"`
|
|
Progress int32 `json:"progress,omitempty" copier:"Progress"`
|
|
SharedCount int32 `json:"sharedCount,omitempty" copier:"SharedCount"`
|
|
Tenant string `json:"tenant,omitempty" copier:"Tenant"`
|
|
Status string `json:"status,omitempty" copier:"Status"`
|
|
IsOpenedSampleCollection string `json:"isOpenedSampleCollection,omitempty" copier:"IsOpenedSampleCollection"`
|
|
TransitionAt int32 `json:"transitionAt,omitempty" copier:"TransitionAt"`
|
|
IsFree bool `json:"isFree,omitempty" copier:"IsFree"`
|
|
AdditionalProperties map[string]string `json:"additionalProperties,omitempty" copier:"AdditionalProperties"`
|
|
}
|
|
/******************ClientList Service End*************************/
|
|
|
|
/******************Show Service Start*************************/
|
|
type (
|
|
ShowServiceReq {
|
|
ProjectId string `path:"projectId"`
|
|
ServiceId string `path:"serviceId"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelartsType,optional"`
|
|
}
|
|
)
|
|
|
|
type ShowServiceResp {
|
|
FailedTimes uint32 `json:"failedTimes,omitempty" copier:"FailedTimes"`
|
|
Owner string `json:"owner,omitempty" copier:"Owner"`
|
|
DueTime int32 `json:"dueTime,omitempty" copier:"DueTime"`
|
|
FinishedTime int32 `json:"finishedTime,omitempty" copier:"FinishedTime"`
|
|
InferType string `json:"inferType,omitempty" copier:"InferType"`
|
|
ServiceName string `json:"serviceName,omitempty" copier:"ServiceName"`
|
|
Description string `json:"description,omitempty" copier:"Description"`
|
|
Project string `json:"project,omitempty" copier:"Project"`
|
|
InvocationTimes uint32 `json:"invocationTimes,omitempty" copier:"InvocationTimes"`
|
|
PublishAt uint32 `json:"publishAt,omitempty" copier:"PublishAt"`
|
|
WorkspaceId string `json:"workspaceId,omitempty" copier:"WorkspaceId"`
|
|
Scheduler []Scheduler `json:"scheduler,omitempty" copier:"Scheduler"`
|
|
StartTime int32 `json:"startTime,omitempty" copier:"StartTime"`
|
|
OperationTime string `json:"operationTime,omitempty" copier:"OperationTime"`
|
|
IsShared bool `json:"isShared,omitempty" copier:"IsShared"`
|
|
ServiceId string `json:"serviceId,omitempty" copier:"ServiceId"`
|
|
Progress int32 `json:"progress,omitempty" copier:"Progress"`
|
|
SharedCount int32 `json:"sharedCount,omitempty" copier:"SharedCount"`
|
|
Tenant string `json:"tenant,omitempty" copier:"Tenant"`
|
|
Status string `json:"status,omitempty" copier:"Status"`
|
|
IsOpenedSampleCollection string `json:"isOpenedSampleCollection,omitempty" copier:"IsOpenedSampleCollection"`
|
|
TransitionAt int32 `json:"transitionAt,omitempty" copier:"TransitionAt"`
|
|
IsFree bool `json:"isFree,omitempty" copier:"IsFree"`
|
|
AdditionalProperties map[string]string `json:"additionalProperties,omitempty" copier:"AdditionalProperties"`
|
|
ClusterId string `json:"clusterId,omitempty" copier:"ClusterId"`
|
|
VpcId string `json:"vpcId,omitempty" copier:"VpcId"`
|
|
SubnetNetworkId string `json:"subnetNetworkId,omitempty" copier:"SubnetNetworkId"`
|
|
SecurityGroupId string `json:"securityGroupId,omitempty" copier:"SecurityGroupId"`
|
|
Config []QueryServiceConfig `json:"config,omitempty" copier:"Config"`
|
|
AccessAddress string `json:"accessAddress,omitempty" copier:"AccessAddress"`
|
|
BindAccessAddress string `json:"bindAccessAddress,omitempty" copier:"BindAccessAddress"`
|
|
UpdateTime string `json:"updateTime,omitempty" copier:"UpdateTime"`
|
|
DebugUrl string `json:"debugUrl,omitempty" copier:"DebugUrl"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
|
|
|
|
type QueryServiceConfig {
|
|
ModelVersion string `json:"modelVersion,omitempty" copier:"ModelVersion"`
|
|
FinishedTime string `json:"finishedTime,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:"modelId,omitempty" copier:"ModelId"`
|
|
SrcPath string `json:"srcPath,omitempty" copier:"SrcPath"`
|
|
ReqUri string `json:"reqUri,omitempty" copier:"ReqUri"`
|
|
MappingType string `json:"mappingType,omitempty" copier:"MappingType"`
|
|
StartTime string `json:"startTime,omitempty" copier:"StartTime"`
|
|
ClusterId string `json:"clusterId,omitempty" copier:"ClusterId"`
|
|
Nodes []string `json:"nodes,omitempty" copier:"Nodes"`
|
|
MappingRule string `json:"mappingRule,omitempty" copier:"MappingRule"`
|
|
ModelName string `json:"modelName,omitempty" copier:"ModelName"`
|
|
SrcType string `json:"srcType,omitempty" copier:"SrcType"`
|
|
DestPath string `json:"destPath,omitempty" copier:"DestPath"`
|
|
InstanceCount int32 `json:"instanceCount,omitempty" copier:"InstanceCount"`
|
|
Status string `json:"status,omitempty" copier:"Status"`
|
|
Scaling bool `json:"scaling,omitempty" copier:"Scaling"`
|
|
SupportDebug bool `json:"supportDebug,omitempty" copier:"SupportDebug"`
|
|
AdditionalProperties map[string]string `json:"additionalProperties,omitempty" copier:"AdditionalProperties"`
|
|
}
|
|
/******************Show Service End*************************/
|
|
|
|
/******************ClientList Clusters Start*************************/
|
|
type (
|
|
ListClustersReq {
|
|
ProjectId string `json:"projectId" copier:"ProjectId"`
|
|
ClusterName string `json:"clusterName,optional" copier:"ClusterName"`
|
|
Offset int64 `form:"offset,optional"`
|
|
Limit int64 `form:"limit,optional"`
|
|
SortBy string `json:"sortBy,optional" copier:"SortBy"`
|
|
Order string `json:"order,optional" copier:"Order"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelartsType,optional"`
|
|
}
|
|
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:"errorCode,optional" copier:"ErrorCode"`
|
|
ErrorMsg string `json:"errorMsg,optional" copier:"ErrorMsg"`
|
|
}
|
|
|
|
type ClusterNode {
|
|
Specification string `json:"specification,omitempty" copier:"Specification"`
|
|
Count int32 `json:"count,omitempty" copier:"Count"`
|
|
AvailableCount int32 `json:"availableCount,omitempty" copier:"AvailableCount"`
|
|
}
|
|
|
|
type Cluster {
|
|
ClusterId string `json:"clusterId,omitempty" copier:"ClusterId"`
|
|
ClusterName string `json:"clusterName,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:"createdAt,omitempty" copier:"CreatedAt"`
|
|
Status string `json:"status,omitempty" copier:"Status"`
|
|
Nodes ClusterNode `json:"nodes,omitempty" copier:"Nodes"`
|
|
AllocatableCpuCores float64 `json:"allocatableCpuCores,omitempty" copier:"AllocatableCpuCores"`
|
|
AllocatableMemory int64 `json:"allocatableMemory,omitempty" copier:"AllocatableMemory"`
|
|
PeriodNum int32 `json:"periodNum,omitempty" copier:"PeriodNum"`
|
|
PeriodType string `json:"periodType,omitempty" copier:"PeriodType"`
|
|
OrderId string `json:"orderId,omitempty" copier:"OrderId"`
|
|
}
|
|
/******************ClientList 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:"parametersCustomization,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:"validType,optional"`
|
|
ValidRange []string `json:"validRange,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:"skipSearchParams,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:"paramType,optional"`
|
|
LowerBound string `json:"lowerBound,optional"`
|
|
UpperBound string `json:"upperBound,optional"`
|
|
DiscretePointsNum string `json:"discretePointsNum,optional"`
|
|
DiscreteValues []string `json:"discreteValues,optional"`
|
|
}
|
|
|
|
type (
|
|
ListAlgorithmsReq {
|
|
//ProjectId string `path:"projectId"`
|
|
ProjectId string `path:"projectId,optional"`
|
|
Offset int32 `form:"offset,optional"`
|
|
Limit int32 `form:"limit,optional"`
|
|
/****************parmas from modelArtsType ********************/
|
|
modelArtsType string `form:"modelArtsType,optional"`
|
|
// 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"`
|
|
/****************parmas from octpus
|
|
platform string `path:"platform"`
|
|
pageIndex int32 `form:"pageIndex,optional"`
|
|
pageSize int32 `form:"pageSize,optional"`
|
|
********************/
|
|
}
|
|
ListAlgorithmsResp {
|
|
Total int32 `json:"total,omitempty"`
|
|
Count int32 `json:"count,omitempty"`
|
|
Limit int32 `json:"limit,omitempty"`
|
|
SortBy string `json:"sortBy,omitempty"`
|
|
Order string `json:"order,omitempty"`
|
|
Items []*AlgorithmResponse `json:"items,omitempty"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
/****************parmas from octpus********************/
|
|
}
|
|
)
|
|
|
|
/******************ListAlgorithms End*************************/
|
|
|
|
/******************DeleteAlgorithm Start*************************/
|
|
type (
|
|
DeleteAlgorithmReq {
|
|
ProjectId string `path:"projectId" copier:"ProjectId"`
|
|
AlgorithmId string `path:"algorithmId" jcopier:"AlgorithmId"`
|
|
/****************parmas from modelArtsType ********************/
|
|
modelArtsType string `form:"modelArtsType,optional"`
|
|
}
|
|
DeleteAlgorithmResp {
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
)
|
|
|
|
/******************DeleteAlgorithm End*************************/
|
|
|
|
/******************Show Algorithm By Uuid start*************************/
|
|
type (
|
|
ShowAlgorithmByUuidReq {
|
|
ProjectId string `path:"projectId" copier:"ProjectId"`
|
|
AlgorithmId string `path:"algorithmId" copier:"AlgorithmId"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `form:"modelartsType,optional"`
|
|
}
|
|
ShowAlgorithmByUuidResp {
|
|
Metadata *MetadataAlRq `json:"metadata,omitempty" copier:"Metadata"`
|
|
JobConfig *JobConfigAl `json:"jobConfig,omitempty" copier:"JobConfig"`
|
|
ResourceRequirements []*ResourceRequirements `json:"resourceRequirements,omitempty" copier:"ResourceRequirements"`
|
|
AdvancedConfig *AdvancedConfigAl `json:"advancedConfig,omitempty" copier:"AdvancedConfig"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
)
|
|
/******************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:"parametersCustomization,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 `path:"projectId"`
|
|
/****************parmas from modelArtsType ********************/
|
|
modelArtsType string `json:"modelArtsType,optional"`
|
|
}
|
|
CreateAlgorithmResp {
|
|
MetadataCARp *MetadataAlRp `json:"metadata,omitempty"`
|
|
Share_infoCARp *ShareInfo `json:"shareInfo,omitempty"`
|
|
JobConfigCARp *JobConfigAl `json:"jobConfig,omitempty"`
|
|
ResourceRequirementsCARp []*ResourceRequirements `json:"resourceRequirements,omitempty"`
|
|
AdvancedConfigCARp *AdvancedConfigAl `json:"advancedConfig,omitempty"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
)
|
|
/******************CreateTrainingJob end*************************/
|
|
|
|
/******************Delete dataset start*************************/
|
|
|
|
type DeleteDataSetReq {
|
|
DatasetId string `path:"datasetId"`
|
|
ProjectId string `path:"projectId"`
|
|
/****************parmas from modelArtsType ********************/
|
|
modelArtsType string `form:"modelArtsType,optional"`
|
|
}
|
|
|
|
type DeleteDataSetResp {
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
}
|
|
|
|
/******************Delete dataset end*************************/
|
|
|
|
/******************Notebook Type start*************************/
|
|
type (
|
|
ListNotebookReq {
|
|
ProjectId string `json:"projectId" copier:"ProjectId"`
|
|
Param ListNotebookParam `json:"param,optional" copier:"Param"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
Platform string `json:"platform,optional"`
|
|
}
|
|
ListNotebookResp {
|
|
Current int32 `json:"current,omitempty" copier:"Current"`
|
|
Data []NotebookResp `json:"data" copier:"Data"`
|
|
Pages int32 `json:"pages,omitempty" copier:"Pages"`
|
|
Size int32 `json:"size,omitempty" copier:"Size"`
|
|
Total int64 `json:"total" copier:"Total"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"errorMsg,omitempty"`
|
|
}
|
|
ListNotebookParam {
|
|
Feature string `json:"feature,optional" copier:"Feature"`
|
|
Limit int32 `json:"limit,optional" copier:"Limit"`
|
|
Name string `json:"name,optional" copier:"Name"`
|
|
PoolId string `json:"poolId,optional" copier:"PoolId"`
|
|
Offset int32 `json:"offset,optional" copier:"Offset"`
|
|
Owner string `json:"owner,optional" copier:"Owner"`
|
|
SortDir string `json:"sortDir,optional" copier:"SortDir"`
|
|
SortKey string `json:"sortKey,optional" copier:"SortKey"`
|
|
Status string `json:"status,optional" copier:"Status"`
|
|
WorkspaceId string `json:"workspaceId,optional" copier:"WorkspaceId"`
|
|
}
|
|
CreateNotebookReq {
|
|
ProjectId string `json:"projectId" copier:"ProjectId"`
|
|
Param CreateNotebookParam `json:"param" copier:"Param"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelArtsType,optional"`
|
|
}
|
|
CreateNotebookResp {
|
|
NotebookResp *NotebookResp `json:"notebookResp,omitempty" copier:"NotebookResp"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"errorMsg,omitempty"`
|
|
}
|
|
CreateNotebookParam {
|
|
Description string `json:"description,optional" copier:"Description"`
|
|
Duration int64 `json:"duration,optional" copier:"Duration"`
|
|
Endpoints []EndpointsReq `json:"endpoints,optional" copier:"Endpoints"`
|
|
Feature string `json:"feature,optional" copier:"Feature"`
|
|
Flavor string `json:"flavor" copier:"Flavor"`
|
|
ImageId string `json:"imageId" copier:"ImageId"`
|
|
Name string `json:"name" copier:"Name"`
|
|
PoolId string `json:"poolId,optional" copier:"PoolId"`
|
|
Volume VolumeReq `json:"volume" copier:"Volume"`
|
|
WorkspaceId string `json:"workspaceId,optional" copier:"WorkspaceId"`
|
|
Hooks CustomHooks `json:"hooks" copier:"Hooks"`
|
|
Lease LeaseReq `json:"lease,optional" copier:"Lease"`
|
|
}
|
|
|
|
StartNotebookReq {
|
|
Id string `json:"id" copier:"Id"`
|
|
ProjectId string `json:"projectId" copier:"ProjectId"`
|
|
Param StartNotebookParam `json:"param" copier:"Param"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
Platform string `json:"platform,optional"`
|
|
}
|
|
StartNotebookResp {
|
|
NotebookResp NotebookResp `json:"notebookResp" copier:"NotebookResp"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"errorMsg,omitempty"`
|
|
}
|
|
StartNotebookParam {
|
|
Duration int64 `json:"duration" copier:"Duration"`
|
|
TypeStartNotebook string `json:"type" copier:"TypeStartNotebook"`
|
|
}
|
|
|
|
StopNotebookReq {
|
|
Id string `json:"id" copier:"Id"`
|
|
ProjectId string `json:"projectId" copier:"ProjectId"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelArtsType,optional"`
|
|
}
|
|
StopNotebookResp {
|
|
NotebookResp NotebookResp `json:"notebookResp" copier:"NotebookResp"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"errorMsg,omitempty"`
|
|
}
|
|
|
|
GetNotebookStorageReq {
|
|
InstanceId string `json:"instanceId" copier:"InstanceId"`
|
|
ProjectId string `json:"projectId" copier:"ProjectId"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelArtsType,optional"`
|
|
}
|
|
GetNotebookStorageResp {
|
|
Current int32 `json:"current" copier:"Current"`
|
|
Data []DataVolumesRes `json:"data" copier:"Data"`
|
|
Pages int32 `json:"pages" copier:"Pages"`
|
|
Size int32 `json:"size" copier:"Size"`
|
|
Total int64 `json:"total" copier:"Total"`
|
|
}
|
|
MountNotebookStorageReq {
|
|
InstanceId string `json:"instanceId" copier:"InstanceId"`
|
|
ProjectId string `json:"projectId" copier:"ProjectId"`
|
|
Param MountNotebookStorageParam `json:"param" copier:"Param"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelArtsType,optional"`
|
|
}
|
|
MountNotebookStorageResp {
|
|
Category string `json:"category" copier:"Category"`
|
|
Id string `json:"id" copier:"Id"`
|
|
MountPath string `json:"mountPath" copier:"MountPath"`
|
|
Status string `json:"status" copier:"Status"`
|
|
Uri string `json:"uri" copier:"Uri"`
|
|
}
|
|
|
|
MountNotebookStorageParam {
|
|
Category string `json:"category" copier:"Category"`
|
|
MountPath string `json:"mountPath" copier:"MountPath"`
|
|
Uri string `json:"uri" copier:"Uri"`
|
|
}
|
|
|
|
DataVolumesRes {
|
|
Category string `json:"category" copier:"Category"`
|
|
Id string `json:"id" copier:"Id"`
|
|
MountPath string `json:"mountPath" copier:"MountPath"`
|
|
Status string `json:"status" copier:"Status"`
|
|
Uri string `json:"uri" copier:"Uri"`
|
|
}
|
|
NotebookResp {
|
|
ActionProgress []ActionProgress `json:"actionProgress,omitempty" copier:"ActionProgress"`
|
|
Description string `json:"description,omitempty" copier:"Description"`
|
|
Endpoints []EndpointsRes `json:"endpoints,omitempty" copier:"Endpoints"`
|
|
FailReason string `json:"failReason,omitempty" copier:"FailReason"`
|
|
Flavor string `json:"flavor,omitempty" copier:"Flavor"`
|
|
Id string `json:"id,omitempty" copier:"Id"`
|
|
Image Image `json:"image,omitempty" copier:"Image"`
|
|
Lease Lease `json:"lease,omitempty" copier:"Lease"`
|
|
Name string `json:"name,omitempty" copier:"Name"`
|
|
Pool Pool `json:"pool,omitempty" copier:"Pool"`
|
|
Status string `json:"status,omitempty" copier:"Status"`
|
|
Token string `json:"token,omitempty" copier:"Token"`
|
|
Url string `json:"url,omitempty" copier:"Url"`
|
|
Volume VolumeRes `json:"volume,omitempty" copier:"Volume"`
|
|
WorkspaceId string `json:"workspaceId,omitempty" copier:"WorkspaceId"`
|
|
Feature string `json:"feature,omitempty" copier:"Feature"`
|
|
CreateAt int64 `json:"createAt,omitempty" copier:"CreateAt"` // *
|
|
Hooks Hooks `json:"hooks,omitempty" copier:"Hooks"` // *
|
|
Tags []string `json:"tags,omitempty" copier:"Tags"` // *
|
|
UpdateAt int64 `json:"updateAt,omitempty" copier:"UpdateAt"` // *
|
|
UserNotebookResp UserNotebookResp `json:"user,omitempty" copier:"UserNotebookResp"` // *
|
|
UserId string `json:"userId,omitempty" copier:"UserId"` // *
|
|
BillingItems []string `json:"billingItems,omitempty" copier:"BillingItems"` // *
|
|
}
|
|
|
|
UserNotebookResp{
|
|
UserNotebookDomain UserNotebookDomain `json:"domain,omitempty" copier:"UserNotebookDomain"` // *
|
|
Id string `json:"id,omitempty" copier:"Id"` // *
|
|
Name string `json:"name,omitempty" copier:"Name"` // *
|
|
}
|
|
|
|
UserNotebookDomain{
|
|
Id string `json:"id,omitempty" copier:"Id"` // *
|
|
Name string `json:"name,omitempty" copier:"Name"` // *
|
|
}
|
|
|
|
Hooks{
|
|
ContainerHooksResp ContainerHooksResp `json:"containerHooks,omitempty" copier:"ContainerHooksResp"` // *
|
|
}
|
|
|
|
ContainerHooksResp{
|
|
PostStart PostStart `json:"postStart,omitempty" copier:"PostStart"` // *
|
|
PreStart PreStart `json:"preStart,omitempty" copier:"PreStart"` // *
|
|
}
|
|
|
|
PostStart{
|
|
Mode string `json:"mode,omitempty" copier:"Mode"` // *
|
|
Script string `json:"script,omitempty" copier:"Script"` // *
|
|
Type string `json:"type,omitempty" copier:"Type"` // *
|
|
}
|
|
|
|
PreStart{
|
|
Mode string `json:"mode,omitempty" copier:"Mode"` // *
|
|
Script string `json:"script,omitempty" copier:"Script"` // *
|
|
Type string `json:"type,omitempty" copier:"Type"` // *
|
|
}
|
|
|
|
ActionProgress{
|
|
Step int32 `json:"step,omitempty" copier:"Step"` // *
|
|
Status string `json:"status,omitempty" copier:"Status"` // *
|
|
Description string `json:"description,omitempty" copier:"Description"` // *
|
|
}
|
|
JobProgress {
|
|
NotebookId string `json:"notebookId" copier:"NotebookId"`
|
|
Status string `json:"status,omitempty" copier:"Status"`
|
|
Step int32 `json:"step,omitempty" copier:"Step"`
|
|
StepDescription string `json:"stepDescription,omitempty" copier:"StepDescription"`
|
|
}
|
|
EndpointsRes {
|
|
AllowedAccessIps []string `json:"allowedAccessIps,omitempty" copier:"AllowedAccessIps"`
|
|
DevService string `json:"devService,omitempty" copier:"DevService"`
|
|
SshKeys []string `json:"sshKeys,omitempty" copier:"SshKeys"`
|
|
}
|
|
Image {
|
|
Arch string `json:"arch,omitempty" copier:"Arch"`
|
|
CreateAt int64 `json:"createAt,omitempty" copier:"CreateAt"`
|
|
Description string `json:"description,omitempty" copier:"Description"`
|
|
DevServices []string `json:"devServices,omitempty" copier:"DevServices"`
|
|
Id string `json:"id,omitempty" copier:"Id"`
|
|
Name string `json:"name,omitempty" copier:"Name"`
|
|
Namespace string `json:"namespace,omitempty" copier:"Namespace"`
|
|
Origin string `json:"origin,omitempty" copier:"Origin"`
|
|
ResourceCategories []string `json:"resourceCategories,omitempty" copier:"ResourceCategories"`
|
|
ServiceType string `json:"serviceType,omitempty" copier:"ServiceType"`
|
|
Size int64 `json:"size,omitempty" copier:"Size"`
|
|
Status string `json:"status,omitempty" copier:"Status"`
|
|
StatusMessage string `json:"statusMessage,omitempty" copier:"StatusMessage"`
|
|
SupportResCategories []string `json:"supportResCategories,omitempty" copier:"SupportResCategories"`
|
|
SwrPath string `json:"swrPath,omitempty" copier:"SwrPath"`
|
|
Tag string `json:"tag,omitempty" copier:"Tag"`
|
|
TypeImage string `json:"type,omitempty" copier:"TypeImage"`
|
|
UpdateAt int64 `json:"updateAt,omitempty" copier:"UpdateAt"`
|
|
Visibility string `json:"visibility,omitempty" copier:"Visibility"`
|
|
WorkspaceId string `json:"workspaceId,omitempty" copier:"WorkspaceId"`
|
|
}
|
|
Lease {
|
|
CreateAt int64 `json:"createAt,omitempty" copier:"CreateAt"`
|
|
Duration int64 `json:"duration,omitempty" copier:"Duration"`
|
|
Enable bool `json:"enable,omitempty" copier:"Enable"`
|
|
TypeLease string `json:"type,omitempty" copier:"TypeLease"`
|
|
UpdateAt int64 `json:"updateAt,omitempty" copier:"UpdateAt"`
|
|
}
|
|
Pool {
|
|
Id string `json:"id,omitempty" copier:"Id"`
|
|
Name string `json:"name,omitempty" copier:"Name"`
|
|
}
|
|
VolumeRes {
|
|
Capacity int64 `json:"capacity,omitempty" copier:"Capacity"`
|
|
Category string `json:"category,omitempty" copier:"Category"`
|
|
MountPath string `json:"mountPath,omitempty" copier:"MountPath"`
|
|
Ownership string `json:"ownership,omitempty" copier:"Ownership"`
|
|
Status string `json:"status,omitempty" copier:"Status"`
|
|
}
|
|
EndpointsReq {
|
|
AllowedAccessIps []string `json:"allowedAccessIps" copier:"AllowedAccessIps"`
|
|
DevService string `json:"devService" copier:"DevService"`
|
|
SshKeys []string `json:"sshKeys" copier:"SshKeys"`
|
|
}
|
|
VolumeReq {
|
|
Capacity int64 `json:"capacity,optional" copier:"Capacity"`
|
|
Category string `json:"category" copier:"Category"`
|
|
Ownership string `json:"ownership" copier:"Ownership"`
|
|
Uri string `json:"uri,optional" copier:"Uri"`
|
|
}
|
|
CustomHooks {
|
|
ContainerHooks ContainerHooks `json:"containerHooks" copier:"ContainerHooks"`
|
|
}
|
|
ContainerHooks {
|
|
PostStart Config `json:"postStart" copier:"PostStart"`
|
|
PreStart Config `json:"preStart" copier:"PreStart"`
|
|
}
|
|
Config {
|
|
/****************parmas from modelarts********************/
|
|
Script string `json:"script" copier:"Script"`
|
|
TypeConfig string `json:"type" copier:"TypeConfig"`
|
|
/****************parmas from octopus
|
|
command string `json:"command" copier:"command"`
|
|
envs Envs `json:"envs" copier:"envs"`
|
|
isMainRole bool `json:"isMainRole" copier:"isMainRole"`
|
|
minFailedTaskCount int32 `json:"minFailedTaskCount" copier:"minFailedTaskCount"`
|
|
minSucceededTaskCount int32 `json:"minSucceededTaskCount" copier:"minSucceededTaskCount"`
|
|
name string `json:"name" copier:"name"`
|
|
parameters Parameters `json:"parameters" copier:"parameters"`
|
|
replicaStates ReplicaStates `json:"replicaStates" copier:"replicaStates"`
|
|
resourceSpecId string `json:"resourceSpecId" copier:"resourceSpecId"`
|
|
resourceSpecPrice int32 `json:"resourceSpecPrice" copier:"resourceSpecPrice"`
|
|
subTaskState string `json:"subTaskState" copier:"subTaskState"`
|
|
taskNumber int32 `json:"taskNumber" copier:"taskNumber"`
|
|
********************/
|
|
}
|
|
LeaseReq {
|
|
Duration int64 `json:"duration,omitempty" copier:"Duration"`
|
|
TypeLeaseReq string `json:"type,omitempty" copier:"TypeLeaseReq"`
|
|
}
|
|
)
|
|
/******************Notebook Type end*************************/
|
|
|
|
/******************Visualization Job Start*************************/
|
|
type (
|
|
GetVisualizationJobReq {
|
|
Project_id string `json:"projectId"`
|
|
Param GetVisualizationJobParam `json:"param"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelArtsType,optional"`
|
|
}
|
|
GetVisualizationJobResp {
|
|
Is_success bool `json:"isSuccess"`
|
|
Error_code string `json:"errorCode"`
|
|
Error_message string `json:"errorMessage"`
|
|
Job_total_count int32 `json:"jobTotalCount"`
|
|
Job_count_limit int32 `json:"jobCountLimit"`
|
|
Jobs []Jobs `json:"jobs"`
|
|
Quotas int32 `json:"quotas"`
|
|
}
|
|
Jobs {
|
|
Job_name string `json:"jobName"`
|
|
Status int32 `json:"status"`
|
|
Create_time int64 `json:"createTime"`
|
|
Duration int64 `json:"duration"`
|
|
Job_desc string `json:"jobDesc"`
|
|
Service_url string `json:"serviceUrl"`
|
|
Train_url string `json:"trainUrl"`
|
|
Job_id string `json:"jobId"`
|
|
Resource_id string `json:"resourceId"`
|
|
}
|
|
GetVisualizationJobParam {
|
|
Status string `json:"status"`
|
|
Per_page int32 `json:"perPage"`
|
|
Page int32 `json:"page"`
|
|
SortBy string `json:"sortBy"`
|
|
Order string `json:"order"`
|
|
Search_content string `json:"searchContent"`
|
|
Workspace_id string `json:"workspaceId"`
|
|
}
|
|
CreateVisualizationJobReq {
|
|
Project_id string `json:"projectId"`
|
|
Param CreateVisualizationJobParam `json:"param"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelArtsType,optional"`
|
|
}
|
|
CreateVisualizationJobResp {
|
|
Error_message string `json:"errorMessage"`
|
|
Error_code string `json:"errorCode"`
|
|
Job_id int64 `json:"jobId"`
|
|
Job_name string `json:"jobName"`
|
|
Status int32 `json:"status"`
|
|
Create_time int64 `json:"createTime"`
|
|
Service_url string `json:"serviceUrl"`
|
|
}
|
|
CreateVisualizationJobParam {
|
|
Job_name string `json:"jobName"`
|
|
Job_desc string `json:"jobDesc"`
|
|
Train_url string `json:"trainUrl"`
|
|
Job_type string `json:"jobType"`
|
|
Flavor Flavor `json:"flavor"`
|
|
Schedule Schedule `json:"schedule"`
|
|
}
|
|
Flavor {
|
|
Code string `json:"code"`
|
|
}
|
|
Schedule {
|
|
Type_schedule string `json:"type"`
|
|
Time_unit string `json:"timeUnit"`
|
|
Duration int32 `json:"duration"`
|
|
}
|
|
)
|
|
/******************Visualization Job End*************************/
|
|
|
|
/******************create TrainIngJob start*************************/
|
|
|
|
type (
|
|
CreateTrainingJobReq { //创建训练任务入参
|
|
/****************parmas from modelarts********************/
|
|
Kind string `json:"kind,optional"`
|
|
Metadatas MetadataS `json:"metadata,optional"`
|
|
AlgorithmsCtRq AlgorithmsCtRq `json:"algorithm,optional"`
|
|
SpecsCtRq SpecsCtRq `json:"spec,optional"`
|
|
ProjectId string `path:"projectId"`
|
|
/****************智算类型 ModelartsType parmas ********************/
|
|
ModelArtsType string `json:"modelArtsType,optional"`
|
|
/****************parmas from octpus
|
|
platform string `json:"platform,optional"`
|
|
params CreateTrainJobParam `json:"params,optional"`
|
|
********************/
|
|
}
|
|
|
|
CreateTrainingJobResp { //创建训练任务出参
|
|
Kind string `json:"kind,omitempty"`
|
|
Metadatas *MetadataS `json:"metadata,omitempty"`
|
|
Status *Status `json:"status,omitempty"`
|
|
SpecCtRp *SpecCtRp `json:"spec,omitempty"`
|
|
Algorithms *AlgorithmsCtRq `json:"algorithm,omitempty"`
|
|
Code int32 `json:"code,omitempty"`
|
|
Msg string `json:"msg,omitempty"`
|
|
ErrorMsg string `json:"ErrorMsg,omitempty"`
|
|
/****************parmas from octpus
|
|
success bool `json:"success,omitempty"`
|
|
error Error `json:"error,omitempty"`
|
|
payload PayloadCreateTrainJob `json:"error,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"`
|
|
SubscriptionId string `json:"subscriptionId,optional"`
|
|
ItemVersionId string `json:"itemVersionId,optional"`
|
|
InputTra []InputTra `json:"inputs,optional"`
|
|
OutputTra []OutputTra `json:"outputs,optional"`
|
|
Environments Environments `json:"environments,optional"`
|
|
}
|
|
Environments{
|
|
|
|
}
|
|
InputTra{
|
|
Name string `json:"name,optional"`
|
|
AccessMethod string `json:"accessMethod,optional"`
|
|
RemoteIn RemoteTra `json:"remoteIn,optional"`
|
|
}
|
|
RemoteTra{
|
|
DatasetIn DatasetTra `json:"dataSet,optional"`
|
|
}
|
|
DatasetTra{
|
|
Id string `json:"id,optional"`
|
|
Name string `json:"name,optional"`
|
|
VersionName string `json:"versionName,optional"`
|
|
VersionId string `json:"versionId,optional"`
|
|
}
|
|
OutputTra{
|
|
Name string `json:"name,optional"`
|
|
AccessMethod string `json:"accessMethod,optional"`
|
|
PrefetchToLocal string `json:"prefetchToLocal,optional"`
|
|
RemoteOut RemoteOut `json:"remoteOut,optional"`
|
|
}
|
|
RemoteOut{
|
|
Obs ObsTra `json:"obs,optional"`
|
|
}
|
|
ObsTra{
|
|
ObsUrl string `json:"obsUrl,optional"`
|
|
}
|
|
|
|
ResourceCreateTraining {
|
|
FlavorId string `json:"flavorId,optional"`
|
|
NodeCount int32 `json:"nodeCount,optional"`
|
|
Policy string `json:"policy,optional"`
|
|
FlavorLabel string `json:"flavorLabel,optional"`
|
|
}
|
|
|
|
LogExportPathCreateTrainingJob {
|
|
ObsUrl string `json:"obsUrl,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:"nfsServerPath,optional"`
|
|
LocalPath string `json:"localPath,optional"`
|
|
ReadOnly bool `json:"readOnly,optional"`
|
|
/****************parmas from octpus
|
|
path string `json:"path,optional"`
|
|
server string `json:"server,optional"`
|
|
********************/
|
|
}
|
|
/****************parmas from octpus
|
|
CreateTrainJobParam {
|
|
algorithmId string `json:"algorithmId,optional"`
|
|
algorithmVersion string `json:"algorithmVersion,optional"`
|
|
config Config `json:"config,optional"`
|
|
dataSetId string `json:"dataSetId,optional"`
|
|
dataSetVersion string `json:"dataSetVersion,optional"`
|
|
desc string `json:"desc,optional"`
|
|
imageId string `json:"imageId,optional"`
|
|
imageUrl string `json:"imageUrl,optional"`
|
|
isDistributed bool `json:"isDistributed,optional"`
|
|
mounts Mounts `json:"mounts,optional"`
|
|
name string `json:"name,optional"`
|
|
resourcePool string `json:"resourcePool,optional"`
|
|
}
|
|
|
|
Envs{
|
|
additionalProp1 string `json:"algorithmId,optional"`
|
|
additionalProp2 string `json:"algorithmId,optional"`
|
|
additionalProp3 string `json:"algorithmId,optional"`
|
|
}
|
|
|
|
ReplicaStates{
|
|
key string `json:"key,optional"`
|
|
state string `json:"state,optional"`
|
|
}
|
|
|
|
Mounts{
|
|
containerPath string `json:"containerPath,optional"`
|
|
nfs Nfs `json:"nfs,optional"`
|
|
octopus TrainJobOctopus `json:"octopus,optional"`
|
|
readOnly bool `json:"readOnly,optional"`
|
|
}
|
|
|
|
TrainJobOctopus{
|
|
bucket string `json:"bucket,optional"`
|
|
object string `json:"object,optional"`
|
|
}
|
|
|
|
Error{
|
|
code int32 `json:"code,optional"`
|
|
subcode int32 `json:"subcode,optional"`
|
|
message string `json:"message,optional"`
|
|
subMessage string `json:"subMessage,optional"`
|
|
}
|
|
PayloadCreateTrainJob{
|
|
jobId string `json:"jobId,optional"`
|
|
}
|
|
********************/
|
|
|
|
/******************Ai Center overview*************************/
|
|
CenterOverviewResp {
|
|
CenterNum int32 `json:"totalCenters,optional"`
|
|
TaskNum int32 `json:"totalTasks,optional"`
|
|
CardNum int32 `json:"totalCards,optional"`
|
|
PowerInTops float64 `json:"totalPower,optional"`
|
|
}
|
|
|
|
CenterQueueingResp {
|
|
Current []*CenterQueue `json:"current,optional"`
|
|
History []*CenterQueue `json:"history,optional"`
|
|
}
|
|
|
|
CenterQueue {
|
|
Name string `json:"name,optional"`
|
|
QueueingNum int32 `json:"num,optional"`
|
|
}
|
|
|
|
CenterListResp {
|
|
List []*AiCenter `json:"centerList,optional"`
|
|
}
|
|
|
|
AiCenter {
|
|
Name string `json:"name,optional"`
|
|
StackName string `json:"stack,optional"`
|
|
Version string `json:"version,optional"`
|
|
}
|
|
|
|
CenterTaskListResp {
|
|
List []*AiTask `json:"taskList,optional"`
|
|
}
|
|
|
|
AiTask {
|
|
Name string `json:"name,optional"`
|
|
status string `json:"status,optional"`
|
|
Cluster string `json:"cluster,optional"`
|
|
Card string `json:"card,optional"`
|
|
TimeElapsed int32 `json:"elapsed,optional"`
|
|
}
|
|
|
|
TrainingTaskStatResp {
|
|
Running int32 `json:"running"`
|
|
Total int32 `json:"total"`
|
|
}
|
|
)
|
|
|
|
/******************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)
|
|
}*/
|
|
|
|
type (
|
|
ChatReq{
|
|
id uint `json:"id,string"`
|
|
Method string `json:"method,optional"`
|
|
ReqData map[string]interface{} `json:"reqData"`
|
|
}
|
|
ChatResult{
|
|
Resuluts string `json:"results,optional"`
|
|
}
|
|
) |