mirror of
https://github.com/jambonz/jambonz-feature-server.git
synced 2025-12-20 08:40:38 +00:00
clear gather timeout if imterim result received (#800)
* clear gather timeout if imterim result received * fix to reset timeout timer if receive interrim result * fix to reset timeout timer if receive interrim result
This commit is contained in:
@@ -882,13 +882,15 @@ class TaskGather extends SttTask {
|
||||
this.cs.callInfo, httpHeaders));
|
||||
}
|
||||
if (this.vendor === 'soniox') {
|
||||
this._clearTimer();
|
||||
if (evt.vendor.finalWords.length) {
|
||||
this.logger.debug({evt}, 'TaskGather:_onTranscription - buffering soniox transcript');
|
||||
this._sonioxTranscripts.push(evt.vendor.finalWords);
|
||||
}
|
||||
}
|
||||
|
||||
// If transcription received, reset timeout timer.
|
||||
if (this._timeoutTimer) {
|
||||
this._startTimer();
|
||||
}
|
||||
/* restart asr timer if we get a partial transcript */
|
||||
if (this.isContinuousAsr) this._startAsrTimer();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user