@@ -105,6 +105,7 @@ type AITaskDetailInfo struct { | |||
ID int64 `json:"id"` | |||
JobID string `json:"job_id"` | |||
Status string `json:"status"` | |||
DetailedStatus string `json:"detailed_status"` | |||
JobType string `json:"job_type"` | |||
Cluster string `json:"cluster"` | |||
DisplayJobName string `json:"display_job_name"` | |||
@@ -202,6 +203,7 @@ type AITaskBriefInfo struct { | |||
ID int64 `json:"id"` | |||
JobType string `json:"job_type"` | |||
Status string `json:"status"` | |||
DetailedStatus string `json:"detailed_status"` | |||
DisplayJobName string `json:"display_job_name"` | |||
CreatedUnix timeutil.TimeStamp `json:"created_unix"` | |||
StartTime timeutil.TimeStamp `json:"start_time"` | |||
@@ -239,6 +241,7 @@ func ConvertCloudbrainToAITaskBriefInfo(task *models.Cloudbrain) *AITaskBriefInf | |||
ID: task.ID, | |||
JobType: task.JobType, | |||
Status: task.Status, | |||
DetailedStatus: task.DetailedStatus, | |||
DisplayJobName: task.DisplayJobName, | |||
CreatedUnix: task.CreatedUnix, | |||
FormattedDuration: task.TrainJobDuration, | |||
@@ -63,19 +63,20 @@ type CreateTrainTaskRequest struct { | |||
} | |||
type QueryTaskResponse struct { | |||
StartedAt timeutil.TimeStamp `json:"started_at"` | |||
CompletedAt timeutil.TimeStamp `json:"completed_at"` | |||
JobId string `json:"job_id"` | |||
Status string `json:"status"` | |||
Url string `json:"url"` | |||
Token string `json:"token"` | |||
CenterId string `json:"center_id"` | |||
CenterName string `json:"center_name"` | |||
CodeUrl string `json:"code_url"` | |||
DataUrl string `json:"data_url"` | |||
ContainerIP string `json:"container_ip"` | |||
ContainerID string `json:"container_id"` | |||
VersionId int64 `json:"version_id"` | |||
StartedAt timeutil.TimeStamp `json:"started_at"` | |||
CompletedAt timeutil.TimeStamp `json:"completed_at"` | |||
JobId string `json:"job_id"` | |||
Status string `json:"status"` | |||
DetailedStatus string `json:"detailed_status"` | |||
Url string `json:"url"` | |||
Token string `json:"token"` | |||
CenterId string `json:"center_id"` | |||
CenterName string `json:"center_name"` | |||
CodeUrl string `json:"code_url"` | |||
DataUrl string `json:"data_url"` | |||
ContainerIP string `json:"container_ip"` | |||
ContainerID string `json:"container_id"` | |||
VersionId int64 `json:"version_id"` | |||
} | |||
func ConvertGrampusNotebookResponse(job models.GrampusNotebookInfo) *QueryTaskResponse { | |||
@@ -100,16 +101,17 @@ func ConvertGrampusNotebookResponse(job models.GrampusNotebookInfo) *QueryTaskRe | |||
dataUrl = t.DataUrl | |||
} | |||
return &QueryTaskResponse{ | |||
StartedAt: timeutil.TimeStamp(job.StartedAt), | |||
CompletedAt: timeutil.TimeStamp(job.CompletedAt), | |||
Status: job.Status, | |||
CenterId: centerId, | |||
CenterName: centerName, | |||
Url: url, | |||
Token: token, | |||
JobId: job.JobID, | |||
CodeUrl: codeUrl, | |||
DataUrl: dataUrl, | |||
StartedAt: timeutil.TimeStamp(job.StartedAt), | |||
CompletedAt: timeutil.TimeStamp(job.CompletedAt), | |||
Status: job.Status, | |||
DetailedStatus: job.DetailedStatus, | |||
CenterId: centerId, | |||
CenterName: centerName, | |||
Url: url, | |||
Token: token, | |||
JobId: job.JobID, | |||
CodeUrl: codeUrl, | |||
DataUrl: dataUrl, | |||
} | |||
} | |||
func ConvertGrampusTrainResponse(job models.GrampusJobInfo) *QueryTaskResponse { | |||
@@ -236,8 +236,9 @@ type Cloudbrain struct { | |||
JobName string | |||
DisplayJobName string | |||
Status string | |||
UserID int64 `xorm:"INDEX NOT NULL"` | |||
RepoID int64 `xorm:"INDEX NOT NULL"` | |||
DetailedStatus string `xorm:"DEFAULT '-'"` | |||
UserID int64 `xorm:"INDEX NOT NULL"` | |||
RepoID int64 `xorm:"INDEX NOT NULL"` | |||
SubTaskName string | |||
ContainerID string | |||
ContainerIp string | |||
@@ -1839,31 +1840,33 @@ type GrampusResult struct { | |||
} | |||
type GrampusJobInfo struct { | |||
StartedAt int64 `json:"startedAt"` | |||
RunSec int64 `json:"runSec"` | |||
CompletedAt int64 `json:"completedAt"` | |||
CreatedAt int64 `json:"createdAt"` | |||
UpdatedAt int64 `json:"updatedAt"` | |||
Desc string `json:"desc"` | |||
JobID string `json:"id"` | |||
Name string `json:"name"` | |||
Status string `json:"status"` | |||
UserID string `json:"userId"` | |||
Tasks []GrampusTasks `json:"tasks"` | |||
StartedAt int64 `json:"startedAt"` | |||
RunSec int64 `json:"runSec"` | |||
CompletedAt int64 `json:"completedAt"` | |||
CreatedAt int64 `json:"createdAt"` | |||
UpdatedAt int64 `json:"updatedAt"` | |||
Desc string `json:"desc"` | |||
JobID string `json:"id"` | |||
Name string `json:"name"` | |||
Status string `json:"status"` | |||
DetailedStatus string `json:"detailedStatus"` | |||
UserID string `json:"userId"` | |||
Tasks []GrampusTasks `json:"tasks"` | |||
} | |||
type GrampusNotebookInfo struct { | |||
StartedAt int64 `json:"startedAt"` | |||
RunSec int64 `json:"runSec"` | |||
CompletedAt int64 `json:"completedAt"` | |||
CreatedAt int64 `json:"createdAt"` | |||
UpdatedAt int64 `json:"updatedAt"` | |||
Desc string `json:"desc"` | |||
JobID string `json:"id"` | |||
Name string `json:"name"` | |||
Status string `json:"status"` | |||
UserID string `json:"userId"` | |||
Tasks []GrampusNotebookTask `json:"tasks"` | |||
StartedAt int64 `json:"startedAt"` | |||
RunSec int64 `json:"runSec"` | |||
CompletedAt int64 `json:"completedAt"` | |||
CreatedAt int64 `json:"createdAt"` | |||
UpdatedAt int64 `json:"updatedAt"` | |||
Desc string `json:"desc"` | |||
JobID string `json:"id"` | |||
Name string `json:"name"` | |||
Status string `json:"status"` | |||
DetailedStatus string `json:"detailedStatus"` | |||
UserID string `json:"userId"` | |||
Tasks []GrampusNotebookTask `json:"tasks"` | |||
} | |||
type Center struct { | |||
ID string `json:"id"` | |||
@@ -658,12 +658,13 @@ func convertGrampusTrainJobResponse(job models.GrampusJobInfo) *entity.QueryTask | |||
centerName = task.CenterName[0] | |||
} | |||
return &entity.QueryTaskResponse{ | |||
StartedAt: timeutil.TimeStamp(job.StartedAt), | |||
CompletedAt: timeutil.TimeStamp(job.CompletedAt), | |||
Status: job.Status, | |||
CenterId: centerId, | |||
CenterName: centerName, | |||
JobId: job.JobID, | |||
StartedAt: timeutil.TimeStamp(job.StartedAt), | |||
CompletedAt: timeutil.TimeStamp(job.CompletedAt), | |||
Status: job.Status, | |||
DetailedStatus: job.DetailedStatus, | |||
CenterId: centerId, | |||
CenterName: centerName, | |||
JobId: job.JobID, | |||
} | |||
} | |||
@@ -100,6 +100,7 @@ func buildAITaskInfo(task *models.Cloudbrain, creator *models.User, config *enti | |||
ID: task.ID, | |||
JobID: task.JobID, | |||
Status: task.Status, | |||
DetailedStatus: task.DetailedStatus, | |||
JobType: task.JobType, | |||
DisplayJobName: task.DisplayJobName, | |||
FormattedDuration: task.TrainJobDuration, | |||
@@ -240,6 +241,8 @@ func StopAITaskByJobNameFromRemote(task *models.Cloudbrain, queryFunc QueryListF | |||
return nil | |||
} | |||
const DEFAULT_DETAILED_STATUS = "-" | |||
func UpdateByQueryResponse(res *entity.QueryTaskResponse, task *models.Cloudbrain) error { | |||
if res.JobId == "" { | |||
return nil | |||
@@ -260,6 +263,10 @@ func UpdateByQueryResponse(res *entity.QueryTaskResponse, task *models.Cloudbrai | |||
newStatus := TransAITaskStatus(res.Status) | |||
task.Status = newStatus | |||
task.DetailedStatus = res.DetailedStatus | |||
if res.DetailedStatus == "" || res.DetailedStatus == res.Status { | |||
task.DetailedStatus = DEFAULT_DETAILED_STATUS | |||
} | |||
if res.StartedAt > 0 { | |||
task.StartTime = res.StartedAt | |||
} | |||
@@ -2,6 +2,7 @@ | |||
<link rel="stylesheet" href="{{StaticUrlPrefix}}/css/vp-cloudbrain-create.css?v={{MD5 AppVer}}" /> | |||
<div class="repository"> | |||
{{template "repo/header" .}} | |||
<i class="SUCCEEDED"></i> | |||
<div id="__vue-root"></div> | |||
</div> | |||
<script src="{{StaticUrlPrefix}}/js/vp-cloudbrain-create.js?v={{MD5 AppVer}}"></script> | |||
@@ -319,6 +319,23 @@ i.INFO { | |||
.i-bg-orange { | |||
background-position: -495px -51px; | |||
} | |||
.data-migrating{ | |||
display: inline-block; | |||
width: 18px; | |||
height: 18px; | |||
margin-left: 8px; | |||
background: url("/img/icons.svg"); | |||
background-position: -56px -52px; | |||
} | |||
.center-pending{ | |||
display: inline-block; | |||
width: 18px; | |||
height: 18px; | |||
margin-left: 8px; | |||
background: url("/img/icons.svg"); | |||
background-position: -511px -52px; | |||
} | |||
.FAILED, | |||
.START_FAILED, | |||
.DELETED, | |||
@@ -669,6 +669,9 @@ const en = { | |||
chartTime: 'Time(min)', | |||
scrollToTop: 'Scroll to top', | |||
scrollToBottom: 'Scroll to bottom', | |||
migratingData: 'Data migration in progress', | |||
centerPending: 'Queuing in sub centers', | |||
dialogTips: { | |||
tips1: "The platform does not directly provide external ports such as 7860 for external services, and can only use FastAPI to forward to the specified URL exposed to the outside world (environment variable can be obtained: os. getenv ('OPENI_GRADIO_URL ') to provide services.", | |||
tips2: 'We need to make a simple adjustment to the way the original Gradio code started the webui, only slightly modifying the original code at the beginning and end. The platform will use the FastAPI method to start the webui service.', | |||
@@ -685,6 +685,9 @@ const zh = { | |||
chartTime: '时间(min)', | |||
scrollToTop: '滚动到顶部', | |||
scrollToBottom: '滚动到底部', | |||
migratingData: '数据迁移中', | |||
centerPending: '分中心排队中', | |||
dialogTips: { | |||
tips1: "平台没有对外直接提供端口如:7860 对外提供服务,只能使用fastapi转发到对外暴露的指定的URL(环境变量可获取:os.getenv('OPENI_GRADIO_URL'))提供服务。", | |||
tips2: '需要简单的调整原先gradio代码启动webui的方式,仅在开头和结尾稍微修改下原始代码,平台会使用fastapi方式启动webui服务。', | |||
@@ -43,6 +43,8 @@ | |||
<div class="status-wrap"> | |||
<i :class="scope.row.task.status"></i> | |||
<span>{{ scope.row.task.status }}</span> | |||
<i v-if="scope.row.task.detailed_status==='dataMigrating'" class="data-migrating" :title="$t('cloudbrainObj.migratingData')"></i> | |||
<i v-if="scope.row.task.detailed_status==='centerPending'" class="center-pending" :title="$t('cloudbrainObj.centerPending')"></i> | |||
</div> | |||
</template> | |||
</el-table-column> | |||
Dear OpenI User
Thank you for your continuous support to the Openl Qizhi Community AI Collaboration Platform. In order to protect your usage rights and ensure network security, we updated the Openl Qizhi Community AI Collaboration Platform Usage Agreement in January 2024. The updated agreement specifies that users are prohibited from using intranet penetration tools. After you click "Agree and continue", you can continue to use our services. Thank you for your cooperation and understanding.
For more agreement content, please refer to the《Openl Qizhi Community AI Collaboration Platform Usage Agreement》