Skip to content

umarlhepk/Jarvis-Virtual-Assistant

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Jarvis - Virtual Assistant

Jarvis is a Python-based virtual assistant capable of handling voice commands to perform tasks like opening websites, playing music, fetching news, and interacting with OpenAI for general queries.

Features

  • Voice Activation: Activate Jarvis with the wake word "Jarvis."
  • Web Browsing: Open popular websites like Google, YouTube, and Facebook via voice commands.
  • Music Playback: Search and play songs from a predefined library.
  • News Updates: Fetch and read the latest news headlines using NewsAPI.
  • AI Integration: Responds to general queries using OpenAI's GPT-4.
  • Text-to-Speech: Uses Google Text-to-Speech (gTTS) for audio responses.

How It Works

  • Speech Recognition: Uses speech_recognition library to convert voice to text.
  • Task Execution: Maps commands to actions via Python functions.
  • Text-to-Speech: Generates audio responses dynamically using gTTS and plays them with pygame.
  • News Fetching: Retrieves top news headlines using NewsAPI.

Installation

  1. Clone the repository:
    git clone https://github.com/umarlhepk/Jarvis-Virtual-Assistant.git
    
    

Add your API keys:

Replace YOUR_NEWS_API_KEY and YOUR_OPENAI_API_KEY in the code.

Usage

Run the script:

python jarvis.py

Speak the wake word "Jarvis" to activate, then give your commands.

How to Use requirements.txt

Save the content to a file named requirements.txt. Install the dependencies by running the following

pip install -r requirements.txt

Future Enhancements

Add more websites to the command list. Enable dynamic song search from online libraries. Support for multiple languages.

Technologies Used

Python gTTS Pygame SpeechRecognition NewsAPI OpenAI GPT-4o

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages