mirror of
https://github.com/jambonz/jambonz-feature-server.git
synced 2025-12-21 00:58:34 +00:00
deepgram sends transcripts with empty alternatives array
This commit is contained in:
@@ -338,7 +338,7 @@ class TaskTranscribe extends SttTask {
|
|||||||
|
|
||||||
let emptyTranscript = false;
|
let emptyTranscript = false;
|
||||||
if (evt.is_final) {
|
if (evt.is_final) {
|
||||||
if (evt.alternatives[0].transcript === '' && !cs.callGone && !this.killed) {
|
if (evt.alternatives.length === 0 || evt.alternatives[0].transcript === '' && !cs.callGone && !this.killed) {
|
||||||
emptyTranscript = true;
|
emptyTranscript = true;
|
||||||
if (finished === 'true' &&
|
if (finished === 'true' &&
|
||||||
['microsoft', 'deepgram'].includes(this.vendor) &&
|
['microsoft', 'deepgram'].includes(this.vendor) &&
|
||||||
|
|||||||
Reference in New Issue
Block a user