LocalVoiceAI has a single configuration point: the push-to-talk keycode. By default, the binary listens for F10 (CGKeyboard keycodeDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/npateriya/LocalVoiceAI/llms.txt
Use this file to discover all available pages before exploring further.
109). If F10 conflicts with another application or system shortcut, you can override it at startup by setting the WHISPER_KEYCODE environment variable to any decimal keycode before starting the service.
Setting a Custom Keycode
PassWHISPER_KEYCODE inline when calling make start:
localvoice binary. If the environment variable is absent, the binary silently falls back to the default of 109 (F10).
Keycode Reference
| Key | Keycode |
|---|---|
| F8 | 100 |
| F9 | 101 |
| F10 | 109 (default) |
| F11 | 103 |
| F12 | 111 |
Code value directly as the WHISPER_KEYCODE value.
How the Default Is Applied
Thelocalvoice binary initialises the push-to-talk keycode in two steps. First, the C-level event tap sets a module-level default:
main() startup, the binary reads the environment variable and validates it:
If you pass a value that cannot be parsed as a decimal integer (for example,
WHISPER_KEYCODE=F9 instead of WHISPER_KEYCODE=101), the binary logs [WARN] Invalid WHISPER_KEYCODE, using 109 (F10) and continues with the built-in default. Always use the numeric keycode, not the key name.Persisting the Keycode via the LaunchAgent Plist
UsingWHISPER_KEYCODE=<value> make start only applies to that single invocation — if the agent is restarted by macOS (for example after a reboot), the variable will not be set. To make the override permanent, add it to the EnvironmentVariables dictionary in the LaunchAgent plist.
The plist is located at:
EnvironmentVariables key. A PATH entry is already present from the install step; add WHISPER_KEYCODE alongside it:
make reload unloads and reloads the LaunchAgent from the updated plist without replacing the binary, so no permission re-grant is required.