Code Monkey home page Code Monkey logo

voice_assistant_openai's Introduction

Python AI Voice Assistant using OpenAI and Speech Recognition

This project is a Python AI Voice Assistant that uses OpenAI's GPT-3 to generate responses to user input and text-to-speech technology to respond to user input with spoken responses. Speech recognition is used to transcribe the user's voice input to text, which is then used as input for the OpenAI model.

Installation

Before running the program, you must first install the required libraries:

openai pyttsx3 speech_recognition To install these libraries, run the following command:

pip install openai pyttsx3 SpeechRecognition

Usage

To use the AI Voice Assistant, simply run the jarvis_voice.py script. The program will listen for the user to say "Jarvis" to initiate a voice command. Once initiated, the program will record the user's voice input, transcribe it to text, generate a response using OpenAI's GPT-3, and then speak the response back to the user.

The program uses a female English voice by default, but this can be changed by modifying the setProperty method of the pyttsx3 engine. To change the voice to a male English voice, change the voices[1].id argument to voices[0].id in the following line:

engine.setProperty('voice', voices[1].id) 0 is for the male voice. To change the language of the voice, modify the setProperty method argument to the desired language code. For example, to change the language to French, change the argument to 'fr'.

Credits

This project was created by Felipe Oliveira with the help of OpenAI's GPT-3, pyttsx3, and speech_recognition libraries.

voice_assistant_openai's People

Contributors

felipeoliveira-1 avatar erickbessa avatar

Watchers

James Cloos 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.