Voice Assistant with Python A basic voice assistant built using Python that demonstrates speech recognition and text-to-speech capabilities. This project utilizes the speech_recognition and pyttsx3 libraries to create an interactive assistant that listens to user commands and responds with a synthesized voice.
Features Speech Recognition: Converts spoken words into text using Google's speech recognition service. Text-to-Speech: Provides spoken responses with a configurable voice using pyttsx3. Real-time Preview: Displays recognized spoken words in the terminal for immediate feedback. Custom Voice Settings: Configurable voice properties including a deeper tone and support for Indian accent (if available). Installation To get started with the voice assistant, you'll need to install the necessary Python libraries. Run the following command:
bash Copy code pip install speechrecognition pyttsx3 pyaudio Usage Clone the repository:
bash Copy code git clone https://github.com/yourusername/voice-assistant.git cd voice-assistant Run the Python script:
bash Copy code python voice_assistant.py The assistant will greet you and listen for commands. Speak your commands and see the responses in the terminal.
Customization Voice Properties: Modify the set_voice_properties function to adjust the voice rate, volume, and accent as needed. Commands: Update the main function to handle additional commands and responses according to your needs. Dependencies speech_recognition: For converting speech to text. pyttsx3: For converting text to speech. pyaudio: For microphone access. License This project is licensed under the MIT License - see the LICENSE file for details.