Hey everyone!
I’m excited to share with you a shortcut that combines voice dictation, API responses, Ollama if you’re using an LLM (any conversation agent really!) and Text-to-Speech (TTS) playback using Piper and Siri. This solution can be used on HomePods, making it a great alternative to building or buying another open-source smart speaker.
How it Works
- Say “Hey Siri” followed by the shortcut name.
- Siri will prompt you, and you’ll say what you want to your Home Assistant (HA) assistant or issue commands.
- The shortcut will play back your HA voice assistant reply with your TTS settings (piper).
Pre-Requisites and Configurations
Before testing this shortcut, make sure to update the variable input values at the top:
- HAURL: Enter your full URL for your Home Assistant server, including the port (e.g.,
http(s)://homeassistant_IP:port
). - PiperVoice: Get the voice you want to use for TTS from the Piper Addon page on your HA instance. Look for something like
en_US-arctic-medium.onnx.json
and remove the.onnx.json
part. - Token: Create a long-lived access token to access the API by going to your account name > Security > scrolling all the way to the bottom.
- ConvAgent: Find the agent you need (e.g., Basic Home Assistant Agent or Ollama for LLM) and copy whatever is after “conversation.” from your entities.
- URLPort: Important! Set this variable to whatever value (anything) if your Home Assistant is behind a reverse proxy/uses SSL AND the default port is blocked on your LAN.
Get the Shortcut
Head over to this link: Shortcuts
Once you add it, edit it, and update these variables to test this shortcut!
Conclusion
I hope this becomes something useful and is built upon by our community. With this shortcut, we can still use our HomeKit devices and HomePods with the HA voice assistant integration.
Thanks for giving me so much to be thankful for!