shricodev / siri-voice-llama3

Voice AI assistant with Groq, FastWhisper and llama3 πŸ¦™
MIT License
16 stars 4 forks source link

Siri Voice LLAMA-3 πŸ§™β€β™‚οΈπŸͺ„

Version License: MIT Twitter: shricodev

GitHub repo size GitHub language count GitHub top language GitHub last commit

πŸ‘€ Check Out My Blog Post on this Project!

I have a complete blog post explaining the project here.

πŸ“š Overview

The AI Assistant Automation is a Python application that uses Llama3, gTTS, OpenAI, Groq, and Faster-Whisper to create an intelligent assistant similar to Siri, with integrated image recognition support. This project allows users to interact with the assistant through voice commands and receive responses in audio format.

😎 Features

⚠️ Limitations

This application may have limitations based on the performance of the underlying AI models and available computing resources. Ensure that the necessary libraries are properly installed and the system is configured to handle audio and image processing efficiently.

🌳 Project Structure

siri-voice-llama3/
β”œβ”€β”€ .git/
β”œβ”€β”€ (gitignored) .venv/
β”œβ”€β”€ logs/
β”œβ”€β”€ data/
β”‚   β”œβ”€β”€ ai_response/
β”‚   β”‚   └── .gitkeep
β”‚   β”‚   └── (gitignored) ai_response_audio.mp3
β”‚   β”œβ”€β”€ chat_history/
β”‚   β”‚   └── 2024/
β”‚   β”‚      └── 10/
β”‚   β”‚         β”œβ”€β”€ (gitignored) 04.log
β”‚   β”‚         └── (gitignored) 05.log
β”‚   └── .gitkeep
β”‚   └── (gitignored) user_audio_prompt.wav
β”œβ”€β”€ main.py
β”œβ”€β”€ README.md
β”œβ”€β”€ requirements.txt
└── src/
    β”œβ”€β”€ __pycache__/
    β”œβ”€β”€ setup.py
    β”œβ”€β”€ siri.py
    β”œβ”€β”€ utils.py
    └── webcam.py

πŸ› οΈ Installation

πŸ’¬ If you are using HTTPS protocol instead of SSH, change the git clone command accordingly.

git clone git@github.com:shricodev/siri-voice-llama3.git
cd siri-voice-llama3
GROQ_API_KEY=
GOOGLE_GENERATIVE_AI_API_KEY=

# Optional
OPENAI_API_KEY=

You can use the .env.example file as a template.

{shell} src/scripts/start_siri_llama3.{sh/fish} main.py

Change the placeholder {shell} to the shell you are using. It can either be bash or fish.

python3 -m venv .venv
source .venv/bin/activate.fish # or .venv/bin/activate if you are not using the fish shell

Install Dependencies

pip3 install -r requirements.txt

πŸ’» Usage

To start the assistant, execute the following command:

python main.py

This command initializes the assistant, allowing you to interact via voice commands.

OR

{shell} src/scripts/start_siri_llama3.{sh/fish} main.py

Change the placeholder {shell} to the shell you are using. It can either be bash or fish.

πŸ’¬ Logging

The application logs all interactions in the data/chat_history/ directory. You can review past interactions in the log files to understand the context of your conversations.

Any ERRORS when running with the shell script will be logged in the logs/ directory.

Show your support

Give a ⭐️ if this project helped you!