Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# Resolving End-of-Transcript Issues in Deepgram Streaming

When working with Deepgram's streaming services, one might encounter issues related to the end-of-transcript (EOT) threshold. This threshold determines when a transcription should be considered complete, which can be challenging to configure correctly.

## Understanding EOT Threshold

The EOT threshold is an optional parameter in Deepgram's API that attempts to decide when to mark a transcript as finished after recognizing a pause or end of speech. Depending on the use case, this can affect how quickly or accurately the system responds to silence or breaks in speech.

### Experimentation with EOT

If you encounter difficulties using the `eot_threshold`, try initially bypassing this parameter to observe how the system behaves without it. This can help determine if the threshold is contributing to any transcription issues and allow you to reconfigure it in smaller increments.

## Example Implementation

For those using JavaScript to stream audio data to Deepgram, a useful example is available in our [Flux streaming demo on GitHub](https://github.com/deepgram-devs/deepgram-demos-flux-streaming). This demo demonstrates a WebSocket connection to send audio data alongside handling potential challenges like EOT.

```javascript
// Example setup for streaming without eot_threshold.
const WebSocket = require('ws');

const ws = new WebSocket('wss://api.deepgram.com/v1/listen', {
headers: {
Authorization: 'Token YOUR_DEEPGRAM_API_KEY'
}
});

// Logic for handling the streaming connection and data.
```

## Conclusion

Configuring the `eot_threshold` might require some trial and error, and initial usage without this parameter can sometimes yield better results. Always ensure you have logged behaviors to later fine-tune the parameter setting.

If issues persist or the system behavior seems inconsistent, reach out to your Deepgram support representative (if you have one) or visit our [community for assistance](https://discord.gg/deepgram).

## References

- [Deepgram API Documentation - Streaming](https://developers.deepgram.com/docs/getting-started-with-live-streaming-audio)
- [Deepgram Demos on GitHub](https://github.com/deepgram-devs/deepgram-demos-flux-streaming)

Further examples and discussions can be found in our [GitHub Discussions](https://github.com/orgs/deepgram/discussions) and [Discord community](https://discord.gg/deepgram).