-
Notifications
You must be signed in to change notification settings - Fork 0
Desktop Integration
Voice Input does not grab keys. Hyprland runs small client commands that connect to the daemon control socket.
The installed snippet is:
source = ~/.local/share/voice-input/omarchy-hyprland-snippet.confIts main binding is toggle mode:
bindd = SUPER CTRL, X, Voice input, exec, voice-input record toggleToggle is the robust choice when release events are unreliable. Each toggle client includes a request timestamp; the daemon ignores one that spent more than 750 ms queued behind finalization.
For push-to-talk, pair press and release:
bind = SUPER CTRL, X, exec, voice-input record start
bindr = SUPER CTRL, X, exec, voice-input record stopThe release must reach Hyprland. If a multi-modifier release is unreliable, return to toggle. hotkey.mode does not install a binding by itself; it affects generated output from:
voice-input setup hyprlandCancel without output:
voice-input record cancelThe primary HUD is a separate service:
systemctl --user status voice-input-hud.service
systemctl --user restart voice-input-hud.serviceThe unit runs:
/usr/bin/qs --no-duplicate --path ~/.local/share/voice-input/quickshell
It sets XDG_RUNTIME_DIR=%t, creates one PanelWindow variant per screen, displays only on the focused Hyprland monitor, uses the overlay layer, requests no keyboard focus, ignores exclusive-zone layout, and subtracts its complete input mask so it is click-through.
$XDG_RUNTIME_DIR/voice-input/state.json
$XDG_RUNTIME_DIR/voice-input/waveform.sock
StateStore.qml polls the atomic JSON state every 50 ms. A Quickshell local socket receives newline-delimited waveform frames independently and reconnects after 400 ms when disconnected. Long transcript display is clipped to roughly five lines and shifted upward so the newest text remains visible.
The daemon service sets VOICE_INPUT_EXTERNAL_HUD=1, preventing the daemon from spawning the legacy Python HUD. Consequently:
- restarting the daemon does not restart Quickshell;
- a HUD crash does not stop ASR/output;
-
[hud].enabled = falsedoes not disable the separately enabled HUD service—disable/stopvoice-input-hud.servicefor that; -
[hud].margin_bottomand[hud].heightcurrently configure the Python fallback, while the Quickshell implementation directly uses 72 and 56 respectively.
Quickshell watches:
~/.config/omarchy/current/theme/colors.toml
It maps accent, foreground, color3, color5, and color1 to phase colors and retains built-in colors if the file cannot be read or parsed. This theme file is optional.
The current position and offsets live in config and runtime state:
voice-input hud position bottom-left
voice-input hud move right
voice-input hud move up 12
voice-input hud center
voice-input hud reset-
moveuses[hud].nudge_stepunless an amount is given. - Positive X moves right; positive Y raises the HUD.
-
centerselects bottom-center and clears X only. -
resetselects bottom-center and clears both offsets.
Suggested optional bindings:
bind = SUPER CTRL ALT, left, exec, voice-input hud move left
bind = SUPER CTRL ALT, right, exec, voice-input hud move right
bind = SUPER CTRL ALT, up, exec, voice-input hud move up
bind = SUPER CTRL ALT, down, exec, voice-input hud move down
bind = SUPER CTRL ALT, c, exec, voice-input hud centerThe supplied JSONC fragment defines custom/voice-input:
voice-input setup waybarIts command is:
voice-input status --follow --format json --extended
status --follow checks state every 250 ms and prints only when the payload changes. The snippet maps phase classes to icons, opens Settings on right click, and opens the model setup wizard on left click.
Merge the object into your Waybar configuration and add custom/voice-input to the desired module list. The setup command prints a fragment; it does not edit an existing Waybar file or restart Waybar.
At recording start, the CLI asks Hyprland whether the active window is XWayland and passes a hint to the daemon. At output time the daemon queries again. If either the captured hint or current target says XWayland, it takes the XWayland route.
| Target | Direct type | Clipboard | Paste |
|---|---|---|---|
| Wayland | wtype |
wl-copy |
wl-copy + wtype chord |
| XWayland |
wtype if explicitly allowed |
xclip |
xclip + xdotool
|
The default prefer_paste_for_xwayland = true avoids direct typing in XWayland. Text over 120 characters also switches from type to paste on Wayland. Paste backs up and restores the target clipboard; clipboard mode copies only.
Hyprland discovery first tries the command socket and falls back to hyprctl. It can import HYPRLAND_INSTANCE_SIGNATURE, WAYLAND_DISPLAY, DISPLAY, and XDG_RUNTIME_DIR from the systemd user-manager environment. If a service cannot see the session, update that environment from your graphical-session startup and restart the service rather than hard-coding another user's runtime path.
When VOICE_INPUT_EXTERNAL_HUD is absent/false and [hud].enabled = true, the daemon may launch assets/hud.py on non-idle state. It needs Python GTK4, Gtk4LayerShell, and optionally the layer-shell preload library. This fallback reads the same state and waveform paths. The standard installed service intentionally disables it in favor of Quickshell.
See also: Troubleshooting · Configuration
English Home · 简体中文首页 · Source repository · MIT License
Voice Input is an independent community project. HUD and Settings require Quickshell 0.3+. Review Security and Privacy before enabling remote ASR, LLM refinement, pre-roll, agent context, or replacing credentials in Settings.
Voice Input 是独立的社区项目。HUD 和 Settings 需要 Quickshell 0.3 或更高版本。启用远程 ASR、LLM refinement、pre-roll、Agent 上下文,或者在 Settings 中替换 credential 前,请阅读安全与隐私。