Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ChatGPT + Whisper API Voice Discord Bot

The Discord bot is designed to interact with users in a voice channel. Upon joining a voice channel, the bot is capable of listening to users' spoken words and processing them as text. The bot utilizes voice recognition software to transcribe the speech into text, and then passes the text to ChatGPT for generating a response.

Table of Contents
  1. Built With
  2. Getting Started
  3. Usage
  4. Roadmap
  5. License
  6. Contact

Built With

Built By

Getting Started

Prerequisites

  1. Get a Discord Bot Token Discord Bot Token Guide
  2. Get an OpenAI API Key at OpenAI API

Installation

  1. Clone the repo
    git clone https://github.com/moo-gn/VoiceBot.git
  2. Install requirements using Pip
    pip install -r requirements.txt
  3. Enter your API keys in credentials.py
    DISCORD_BOT_TOKEN = "ENTER DISCORD TOKEN HERE"
    OPENAI_API_TOKEN = "ENTER OPENAPI KEY HERE"
  4. Run the main driver
    python3 voice_bot.py

Usage

  1. Command the bot to join the voice channel using
    /join
  2. Click the 🔴 button to start recording your prompt
  3. Click the ⬜ button to stop recording
  4. Find your response in the text channel you asked the bot to join from
  5. Command the bot to leave the voice channel using
    /leave

Here is an example where I asked the the voice bot for a pasta recipe! Screenshot 2023-05-12 at 3 27 36 PM

Roadmap

  • Have the option to convert the ChatGPT text response back to speech using text-to-speech synthesis and play the response in the voice channel.
  • Add voice commands.
  • Make interface more user friendly. For example, remove record button and only stop recording when we are in the recording phase
  • Improve the messages displayed to the user. Add the option to view the prompt recorded
  • Make the user have the ability to change the join/leave commands to words of their choosing

License

Distributed under the MIT License. See LICENSE.txt for more information.

Contact

Ghaith Khoja - gkhoja@umich.edu

Project Link: https://github.com/moo-gn/VoiceBot.git

About

Discord voice bot using OpenAI Whisper API

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages