Skip to content

Detecting a pause of 2 Seconds or more in Speech. #11

@catosaurusrex2003

Description

@catosaurusrex2003

is there any reliable and consistent method to detect a pause of more than 2 seconds in realtime transcript.

currently my implementation is this.

if(currentFinalTranscript.audio_start - previousFinalTranscript.audio_end  >= 2000){
    console.log("pause greater than 2 seconds detected");
}

this works well when the pause duration is 5000 instead of 2000.
but the more near i go to 2000 it starts getting unreliable.

i am assuming that the audio_start and audio_end in the realtimeTranscript response excludes the milliseconds where the person was silent.
as this seems to be the case when the pause is longer.

currentFinalTranscript is the finalTranscript recieved in the new socket.onMessage callback

previousFinalTranscript is the finalTranscript recieved in the preceeding socket.onMessage callback

other logical approaches or flaws in the current logic are welcomed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions