Skip to content

DamienDeepgram/node-live-example

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Deepgram Live Transcriptions Example (Node.js)

ALPHA

This is a basic express server that shows the basic setup for live audio transcriptions using Deepgram.

The code can be found in the following places:

Client code

This code gets access to the users microphone which will be used as the audio input. Once data is available from the microphone, it gets sent to the server via websocket.

When data comes back from the server on the data event, it takes the text and adds it to the body.

Server code

The server code creates a new web socket called globalSocket that communicates with the client. When data comes in from the client it then sends that data to Deepgram via the SDK. (Note that the Deepgram SDK is just setting up a websocket connection with Deepgram).

Running the application locally

Create a .env file with your own Deepgram API Key.

Run the following commands to install the dependencies and run the application

npm i
npm run dev

Accessing the running application in your browser

Once the server is running, open the following url in the browser

http://localhost:3000/

Click on the button when you're ready to transcribe.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 64.1%
  • CSS 18.2%
  • HTML 17.7%