Coder Social home page Coder Social logo

aumbriac / gpt-voice-assist Goto Github PK

View Code? Open in Web Editor NEW
3.0 2.0 0.0 299 KB

A full-stack application that utilizes the OpenAI API and continuously listens for voice input in the background, converts this input to text, processes the text with the GPT-4 model, and converts the model's response back into spoken voice.

HTML 13.54% CSS 16.99% JavaScript 69.47%
ai gpt-4 node react

gpt-voice-assist's Introduction

GPT Voice Assist

A full-stack application that utilizes the OpenAI API and continuously listens for voice input in the background, converts this input to text, processes the text with the GPT-4 model, and converts the model's response back into spoken voice.

Setup and Installation

Prerequisites

  • Node.js and npm installed on your local machine.
  • An OpenAI API key.

Installation

  1. Clone the repository to your local machine.

    git clone https://github.com/aumbriac/GPT-Voice-Assist.git
  2. Navigate to the /server directory.

    cd GPT-Voice-Assist/server
  3. Rename .env.example to .env.

    mv .env.example .env
  4. Open the .env file in a text editor and replace YOUR_OPENAI_KEY with your OpenAI API key.

  5. Install the dependencies.

    npm install
  6. Start the server.

    node server.js
  7. Open another terminal and navigate to the /client directory.

    cd ../client
  8. Install the dependencies.

    npm install
  9. Start the client application.

    npm start

You should now have the server running on http://localhost:3001/ and the client running on http://localhost:3000/.

Usage

  1. Click on the "Click to Speak to GPT" button to activate voice recognition.

  2. To activate GPT, say "GPT" into your device's microphone. A sound effect will play to indicate that GPT is ready to receive your command. You can say "cancel" or "nevermind" to deactivate GPT. GPT may be reactivated at any time by saying "GPT".

  3. Speak your command or question to the microphone. The GPT assistant will listen to your command, send it to the OpenAI API, and convert the response back to voice.

  4. Open the console to see the input and output logs. Note: logs will display only if true is passed as a second parameter to GPTVoiceAssist.

Contributing

Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

License

MIT

gpt-voice-assist's People

Contributors

aumbriac avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.