Any Alexa Lovers???... Then this project is for you, create your own alexa by using Python.. by using 3 simple packages we can create own voice assistant, Packages are... 1. pip speech recognition 2. pip text to speech recognition 3. pip PyAudio IMPORTANT: IN SOME SYSTEMS PYAUDUIO, INSTALLATION PROBLEM OCCURS, IN THAT CASE, CHECK YOUR PYTHON VERSION, USE PYTHON 3.6 OR ABOVE. You can search the things, playmusic, and you can ask the funny question to alexa using below code.. import speech_recognition as sr import pyttsx3 import pywhatkit import datetime import wikipedia import pyjokes listener = sr.Recognizer() engine = pyttsx3.init() voices = engine.getProperty('voices') engine.setProperty('voice', voices[1].id) def talk(text): engine.say(text) engine.runAndWait() def take_command(): try: with sr.Microphone() as source: ...
Comments
Post a Comment