From 3cd7a619ad1d3bc0229abe54813ca4eaf9fee7c3 Mon Sep 17 00:00:00 2001 From: Dave Horton Date: Tue, 30 Apr 2024 08:21:27 -0400 Subject: [PATCH] ignore transcriptions from previous turns of conversation (#734) --- lib/tasks/gather.js | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/tasks/gather.js b/lib/tasks/gather.js index 85a9fc29..65b08da2 100644 --- a/lib/tasks/gather.js +++ b/lib/tasks/gather.js @@ -747,6 +747,7 @@ class TaskGather extends SttTask { const finished = fsEvent.getHeader('transcription-session-finished'); this.logger.debug({evt, bugname, finished, vendor: this.vendor}, 'Gather:_onTranscription raw transcript'); if (bugname && this.bugname !== bugname) return; + if (finished === 'true') return; if (this.vendor === 'ibm' && evt?.state === 'listening') return; if (this.vendor === 'deepgram' && evt.type === 'UtteranceEnd') {