CaMa development view on the survival tab; governance trains any scenario in the background
This commit is contained in:
@@ -10,6 +10,8 @@ import {
|
||||
ModelVersion,
|
||||
PromotionCheck,
|
||||
ReportField,
|
||||
TrainableScenario,
|
||||
TrainingJob,
|
||||
OcrJob,
|
||||
OcrRowStatus,
|
||||
OcrRowsResponse,
|
||||
@@ -39,6 +41,20 @@ export class GovernanceApi {
|
||||
return this.http.post<{ output: string }>(`/governance/model-versions/${domain}/${scenario}/train`, {});
|
||||
}
|
||||
|
||||
/** The scenarios that can be trained from here. */
|
||||
trainableScenarios(): Observable<{ scenarios: TrainableScenario[] }> {
|
||||
return this.http.get<{ scenarios: TrainableScenario[] }>('/governance/scenarios');
|
||||
}
|
||||
|
||||
/** Starts the training in the background: 202 with the job, 409 with the running one, 503 with no dbt manifest. */
|
||||
startTrainingJob(domain: string, scenario: string): Observable<{ job: TrainingJob }> {
|
||||
return this.http.post<{ job: TrainingJob }>(`/governance/model-versions/${domain}/${scenario}/train-jobs`, {});
|
||||
}
|
||||
|
||||
trainingJobs(): Observable<{ jobs: TrainingJob[] }> {
|
||||
return this.http.get<{ jobs: TrainingJob[] }>('/governance/training-jobs');
|
||||
}
|
||||
|
||||
retireModelVersion(domain: string, scenario: string, version: string): Observable<ModelVersion> {
|
||||
return this.http.post<ModelVersion>(`/governance/model-versions/${domain}/${scenario}/${version}/retire`, {});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user