Update README

This commit is contained in:
Michael Hansen committed 2025-10-16 17:16:16 -05:00
1 parent 0f73f2e830
commit 2b04484f4c
4 files changed
+49 -4

No files matched your search

+3 -2
View File
@@ -15,5 +15,6 @@ venv/
.mypy_cache/
*.egg-info/
dist/
preferences.json
/dist/
/preferences.json
/local/
+46 -2
View File
@@ -31,18 +31,31 @@ See `--help` for more options.
### Microphone
Use `--audio-input-device` to change the microphone device. Use `python3 -m sounddevice` to see the available PortAudio devices.
Use `--audio-input-device` to change the microphone device. Use `--list-input-devices` to see the available microphones.
The microphone device **must** support 16Khz mono audio.
### Speaker
Use `--audio-output-device` to change the speaker device. Use `mpv --audio-device=help` to see the available MPV devices.
Use `--audio-output-device` to change the speaker device. Use `--list-output-devices` to see the available speakers.
## Wake Word
Change the default wake word with `--wake-model <id>` where `<id>` is the name of a model in the `wakewords` directory. For example, `--wake-model hey_jarvis` will load `wakewords/hey_jarvis.tflite` by default.
You can include more wakeword directories by adding `--wake-word-dir <DIR>` where `<DIR>` contains either [microWakeWord][] or [openWakeWord][] config files and `.tflite` models. For example, `--wake-word-dir wakewords/openWakeWord` will include the default wake words for openWakeWord.
If you want to add [other wakeword][wakewords-collection], make sure to create a small JSON config file to identify it as an openWakeWord model. For example, download the [GLaDOS][glados] model to `glados.tflite` and create `glados.json` with:
``` json
{
"type": "openWakeWord",
"wake_word": "GLaDOS",
"model": "glados.tflite"
}
```
Add `--wake-word-dir <DIR>` with the directory containing `glados.tflite` and `glados.json` to your command-line.
## Connecting to Home Assistant
@@ -52,6 +65,37 @@ Change the default wake word with `--wake-model <id>` where `<id>` is the name o
4. Enter the IP address of your voice satellite with port 6053
5. Click "Submit"
## Acoustic Echo Cancellation
Enable the echo cancel PulseAudio module:
``` sh
pactl load-module module-echo-cancel \
aec_method=webrtc \
aec_args="analog_gain_control=0 digital_gain_control=1 noise_suppression=1"
```
Verify that the `echo-cancel-source` and `echo-cancel-sink` devices are present:
``` sh
pactl list short sources
pactl list short sinks
```
Use the new devices:
``` sh
# The device names may be different on your system.
# Double check with --list-input-devices and --list-output-devices
python3 -m linux_voice_assistant ... \
--audio-input-device 'Echo-Cancel Source' \
--audio-output-device 'pipewire/echo-cancel-sink'
```
<!-- Links -->
[homeassistant]: https://www.home-assistant.io/
[esphome]: https://esphome.io/
[microWakeWord]: https://github.com/kahrendt/microWakeWord
[openWakeWord]: https://github.com/dscripka/openWakeWord
[wakewords-collection]: https://github.com/fwartner/home-assistant-wakewords-collection
[glados]: https://github.com/fwartner/home-assistant-wakewords-collection/blob/main/en/glados/glados.tflite
Binary file not shown.
Binary file not shown.