The purpose of this demo is to showcase how you can build a NextJS + langchain + langgraph + Web Speech API SpeechSynthesis + Groq + Google Search speech to speech AI Assistant using Deepgram.
Capture streaming audio using Deepgram Streaming Speech to Text.
Convert text to speech Deepgram Streaming Text to Speech
Chat Pal: Enjoy fluid, voice-driven conversations with an AI companion. Ask questions, explore topics, and receive spoken answers in real-time, creating a dynamic and engaging conversational experience.
This speech-to-speech AI assistant offers a user-friendly way to interact with AI enhanced with the Langgraph MemorySaver, enabling it to recall details from previous interaction. It is also binded with the Google Search tool, allowing it to be able to access real-time information from the internet. In a nutshell, information and assistance is accessible through simple voice commands.
Follow these steps to get started with this starter application.
Go to GitHub and clone the repository.
Install the project dependencies.
npm install
Copy the code from sample.env.local
and create a new file called .env.local
.
DEEPGRAM_API_KEY=YOUR-DG-API-KEY
GROQ_API_KEY=YOUR-GROQ-API-KEY
For DEEPGRAM_API_KEY
paste in the key you generated in the Deepgram console.
For GROQ_API_KEY
paste in the key you generated in the Groq console.
Once running, you can access the application in your browser.
npm run dev
If you have found a bug or if you have a feature request, please report them at this repository issues section. Please do not report security vulnerabilities on the public GitHub issue tracker. The Security Policy details the procedure for contacting Deepgram.
I will love to hear from you so if you have questions, comments or find a bug in the project, let me know! You can:
Victor Oluwadare
This project is licensed under the MIT license. See the LICENSE file for more info.