diff --git a/frontend/pages/projects/_id/intent-detection-and-slot-filling/index.vue b/frontend/pages/projects/_id/intent-detection-and-slot-filling/index.vue index 326e4886..fb2de8af 100644 --- a/frontend/pages/projects/_id/intent-detection-and-slot-filling/index.vue +++ b/frontend/pages/projects/_id/intent-detection-and-slot-filling/index.vue @@ -95,6 +95,9 @@ export default { this.$route.query.ordering ) const doc = this.docs.items[0] + if (this.enableAutoLabeling && !doc.isConfirmed) { + await this.autoLabel(doc.id) + } await this.listSpan(doc.id) await this.listCategory(doc.id) }, @@ -178,6 +181,14 @@ export default { await this.listSpan(this.doc.id) }, + async autoLabel(docId) { + try { + await this.$services.sequenceLabeling.autoLabel(this.projectId, docId) + } catch (e) { + console.log(e.response.data.detail) + } + }, + async updateProgress() { this.progress = await this.$services.metrics.fetchMyProgress(this.projectId) },