Say "Hola Jarvis" → voice response → your song plays.
Runs in the background from the moment you turn on your laptop.
- macOS (uses
sayfor voice andlaunchctlfor auto-start) - Python 3.9+
- Microphone
1. Clone the repo
git clone https://github.com/creativoma/jarvis.git
cd jarvis2. Create a virtual environment and install dependencies
python3 -m venv venv
source venv/bin/activate
pip install sounddevice numpy vosk3. Download the Spanish voice model
curl -LO https://alphacephei.com/vosk/models/vosk-model-small-es-0.42.zip
unzip vosk-model-small-es-0.42.zip
rm vosk-model-small-es-0.42.zip4. Grant microphone permission (required)
Run the script once from Terminal so macOS can show the microphone permission dialog:
venv/bin/python3 index.pyWhen the dialog appears asking "Python wants to access the microphone", click OK.
You can stop the script with Ctrl+C after granting permission.
Why is this step required? macOS blocks microphone access for background processes (launchd agents) because they can't show permission dialogs. You need to grant the permission at least once from a terminal session. The permission is tied to the Python binary, so the background service will reuse it automatically.
5. Say "Hola Jarvis" and you're good to go.
Edit com.jarvis.welcome.plist and replace /path/to/jarvis with the absolute path to your cloned repo (e.g. /Users/yourname/projects/jarvis). Then copy and load it:
cp com.jarvis.welcome.plist ~/Library/LaunchAgents/
launchctl load ~/Library/LaunchAgents/com.jarvis.welcome.plistTo stop it:
launchctl unload ~/Library/LaunchAgents/com.jarvis.welcome.plistTo reload after changes:
launchctl unload ~/Library/LaunchAgents/com.jarvis.welcome.plist
launchctl load ~/Library/LaunchAgents/com.jarvis.welcome.plistCheck logs in real time:
tail -f /tmp/jarvis-welcome.log
tail -f /tmp/jarvis-welcome-error.log"Hola Jarvis" is not being detected
- Make sure you ran
venv/bin/python3 index.pyfrom Terminal at least once and accepted the microphone permission dialog. - Check the service is running:
launchctl list | grep jarvis— the PID column should show a number. - Check the logs:
cat /tmp/jarvis-welcome.log— you should seeListening… say «Hola Jarvis». - If you revoked or reset microphone permissions (e.g. via System Settings → Privacy), repeat step 4 of Getting started.
Service is running but logs are empty
The plist includes -u (unbuffered) and PYTHONUNBUFFERED=1. If you have an older copy of the plist, reload it:
cp com.jarvis.welcome.plist ~/Library/LaunchAgents/
launchctl unload ~/Library/LaunchAgents/com.jarvis.welcome.plist
launchctl load ~/Library/LaunchAgents/com.jarvis.welcome.plistIn index.py:
| Variable | Description |
|---|---|
WAKE_WORD |
Word that triggers Jarvis (default: "jarvis") |
YOUTUBE_URL |
Song to open |
MENSAJE |
What Jarvis says when activated |
Inspired by RafaTatay's Jarvis project — saw it on his social media and had to build my own version.
MIT © Mariano Alvarez