A Python-based voice-activated AI assistant inspired by JARVIS. Vasu can open websites, play music, and fetch news headlines using simple voice commands.
- 🎤 Voice Recognition: Responds to the wake word "activate"
- 🌐 Website Navigation: Opens popular websites with voice commands
- 🎵 Music Player: Plays songs from your custom music library
- 📰 News Updates: Fetches latest news headlines
- 🔊 Text-to-Speech: Provides voice feedback for all actions
- "Open Google"
- "Open YouTube"
- "Open Gmail"
- "Open Stack Overflow"
- "Open GitHub"
- "Open LinkedIn"
- "Open Facebook"
- "Open Instagram"
- "Open WhatsApp"
- "Open Amazon"
- "Open Flipkart"
- "Open Reddit"
- "Open Wikipedia"
- "Play [song name]" - Plays songs from your music library
- "News" - Opens latest news headlines
- Python 3.7 or higher
- Working microphone
- Internet connection
- Speaker/audio output device
-
Clone the repository
git clone https://github.com/yourusername/vasu-voice-assistant.git cd vasu-voice-assistant -
Install required dependencies
pip install -r requirements.txt
Or install manually:
pip install speechrecognition pip install pyttsx3 pip install pyaudio pip install requests
Note for PyAudio installation issues:
- Windows: Download the appropriate
.whlfile from here and install usingpip install filename.whl - Linux:
sudo apt-get install portaudio19-dev python3-pyaudio - macOS:
brew install portaudiothenpip install pyaudio
- Windows: Download the appropriate
-
Set up your music library
- Edit
musiclibrary.pyto add your favorite songs - Add song names and YouTube URLs in the dictionary format
- Edit
-
Run the assistant
python main.py
-
Activate the assistant
- Wait for "Listening...." to appear
- Say "activate" to wake up the assistant
- After hearing "Activated", give your command
- Example: Say "Open YouTube" or "Play judas"
-
Stop the assistant
- Press
Ctrl + Cin the terminal
- Press
vasu-voice-assistant/
│
├── main.py # Main application file
├── musiclibrary.py # Music library with song links
├── requirements.txt # Project dependencies
└── README.md # Project documentation
Edit musiclibrary.py and add songs in this format:
music = {
"song_name": "youtube_url",
"another_song": "youtube_url"
}In main.py, add new conditions in the processCommand() function:
elif "your command" in c.lower():
speak("Your response")
# Your action hereModify line 59 in main.py:
if (word.lower() == "your_wake_word"):- Check microphone permissions in your system settings
- Ensure your microphone is set as the default recording device
- Test microphone with other applications
- Speak clearly and at a moderate pace
- Reduce background noise
- Adjust the
timeoutandphrase_time_limitvalues inmain.py
- Check speaker/headphone connections
- Verify system volume settings
- Test pyttsx3 separately:
python -c "import pyttsx3; engine = pyttsx3.init(); engine.say('test'); engine.runAndWait()"
Create a requirements.txt file with:
SpeechRecognition==3.10.0
pyttsx3==2.90
PyAudio==0.2.13
requests==2.31.0
- Integration with OpenAI API for conversational AI
- Weather information lookup
- Calendar and reminder features
- Email sending capability
- System control (volume, brightness, etc.)
- Multi-language support
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the project
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Inspired by JARVIS from Iron Man
- Built with Python's speech recognition and text-to-speech libraries
- Thanks to the open-source community
Your Name - ARYAN GUPTA
Website Link: https://maybe-aryan.netlify.app/
⭐ If you found this project helpful, please give it a star!