Voice-Assistant is an intelligent AI application designed for voice interactions through commands. It features a Python backend with a frontend crafted using JavaScript, HTML, and CSS.
main.py
: The entry point of the application that initializes and runs the Python Eel module.requirements.txt
: Lists the dependencies required for the application.
wake_word_detect.py
: Manages wake word detection for the initial screen.listener_thread.py
: Listens for the designated wake word ("Hey Jarvis").speech_to_text.py
: Handles speech-to-text conversion for the chat window..env
: Stores environment variables such as API keys securely.
main.html
: Provides the HTML structure for both the wake word detection and chat screens.wake_word_detect.css
: Styles the wake word detection screen.speech_to_text_chat.css
: Styles the chat window screen.wake_word_detect.js
: JavaScript code for integrating the frontend with backend wake word detection.speech_to_text_chat.js
: JavaScript code for connecting the chat window with backend functionalities.
- Install Python: Ensure Python is installed on your machine.
- Clone Repository: Clone the project repository or download the ZIP file.
- Open Project: Open the project folder in your preferred code editor or IDE.
- Create Virtual Environment: Run
python -m venv <name_of_virtual_environment>
. - Activate Environment: Activate the virtual environment with:
- Windows:
.\<name_of_virtual_environment>\Scripts\activate
- macOS/Linux:
source <name_of_virtual_environment>/bin/activate
- Windows:
- Install Dependencies: Run
pip install -r requirements.txt
to install project dependencies. - Obtain API Key: Sign up on Cohere and get your personal API key.
- Configure API Key: Replace
"your Cohere API key"
in the.env
file with your API key and save the changes. - Run Application: Execute
python main.py
in your terminal to start the application. - Interact: Enjoy using the Voice-Assistant application.
- Loading Time: The application may take 0.5-1 minute to load depending on your machine’s specifications.
- Wake Word Detection: On launch, click the microphone button 🎤. Wait for the text "Listening" to appear.
- Activate Assistant: When "Listening" is visible, say the wake word ("Hey Jarvis"). The text will change to "Jarvis Active," and you’ll hear "Jarvis Activated!" 🔊
- Chat Window: You’ll be directed to the chat window with a welcome message: "Welcome! How can I help you?" 💬
- Voice Conversation: Click the microphone button at the bottom of the chat window to start a voice conversation. Speak your query when prompted with "Ask..." 🗨️
- Pause/Resume Conversation: To pause, say "Thank you and goodbye." The system will respond with "Goodbye!" and pause the conversation. Resume by clicking the microphone button again. 🔄
- Text Conversation: Alternatively, type your query in the message input and press the send button or hit Enter. Text responses are faster. 📝
- Polite Responses: The bot is programmed to respond politely, only interacting when spoken to or texted. 😊