Skip to content

Khadijah is a voice-controlled digital assistant designed to perform various tasks

Notifications You must be signed in to change notification settings

shahbajsingh/khadijah-ai

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Khadijah AI (in-progress)

Khadijah is a voice-controlled digital assistant designed to perform various tasks such as opening and closing applications, responding to greetings, and interacting with the user via voice commands. This project leverages Python libraries for text-to-speech, speech recognition, and keyboard shortcuts to deliver a dynamic and interactive experience.


Features

  • Voice-Controlled Commands:

    • Open or close common applications like Terminal, Safari, Notes, and more.
    • Respond to user greetings and basic queries.
  • Customizable Hotkeys:

    • j to start listening.
    • k to pause listening.
  • Dynamic Application Mapping:

    • Easily add or modify supported applications in the global APP_MAP.

Technologies Used

  • Python Libraries:

    • pyttsx3: For text-to-speech functionality.
    • SpeechRecognition: To recognize and process user voice commands.
    • keyboard: To add hotkey functionality for starting and pausing the assistant.
    • python-decouple: For managing user and bot configuration variables.
    • smtplib: For securely sending email messages over SMTP.
  • macOS-Specific Utilities:

    • osascript: Used to execute AppleScript for closing applications.
    • open: The native macOS command to launch applications.

Installation

Prerequisites

  • Python 3.7 or higher installed on your system.

Step 1: Clone the Repository

$ git clone https://github.com/shahbajsingh/khadijah-ai.git
$ cd khadijah-ai

Step 2:

(Option 1) Set up Dependencies

$ pip install -r requirements.txt

(Option 2) Use Setup Script

$ chmod +x setup.sh
$ ./setup.sh

Step 3: Configure User Information

Create a .env file in the project directory with the following content:

USER=YourName

Navigate to online.py and enter email and passkey credentials to send emails.

EMAIL=YourEmailAddress
PASSWORD=YourPasskey

Usage

1. Start Khadijah

Run the script

$ python khadijah-ai.py
2. Voice Commands
  • Say open [application] to open an application
  • Say quit [application] to close an application
  • Say search google, search wikipedia, or search youtube to browse web related content
  • Say send an email to send emails
  • Say read me the news to get the top headlines in US news
  • Say give me the forecast to get the weather forecast for a city
  • Example:
    • open terminal
    • quit safari
3. Exit Khadijah

Say stop or exit to gracefully shut down Khadijah

About

Khadijah is a voice-controlled digital assistant designed to perform various tasks

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published