This project demonstrates how to create a conversational AI agent.
- Python 3.7+
- An Eleven Labs account with an API Key and an Agent ID.
It is recommended to use a virtual environment to manage the project's dependencies.
python -m venv venv
source venv/bin/activate # On Windows use `venv\Scripts\activate`
Install the required Python packages using pip:
pip install -r requirements.txt
Copy the example environment file .env.example
to a new file named .env
:
cp .env.example .env
Open the .env
file and add your Eleven Labs API Key and Agent ID:
ELEVENLABS_API_KEY="YOUR_API_KEY_HERE"
ELEVENLABS_AGENT_ID="YOUR_AGENT_ID_HERE"
Once the setup is complete, you can run the conversational agent:
python main.py
The script will start an interactive session with your Eleven Labs agent. Speak into your microphone when prompted, and the agent will respond. The conversation will be transcribed in your terminal.