OmniVoice Voice Preset:
OmniVoiceVoicePreset loads a saved reference voice and its associated transcript for use with OmniVoice Generate. It lets you choose from available built-in presets or add your own audio files, so you can reuse a reference recording without locating and loading it separately each time. When a preset is selected, the node reads its audio and prepares it in ComfyUI’s audio format while keeping the recording’s sample rate. It also retrieves the text associated with that recording, giving you a convenient way to pass the reference voice and its words together to the next node.
OmniVoice Voice Preset Input Parameters:
preset
Selects the reference voice to load. The choices come from the available built-in presets and audio files found in the preset cache directory; added files appear with (local) after their filename stem. Your choice determines both the recording and its associated transcript. A local preset uses the contents of a same-stem .txt file as its transcript when that file exists; otherwise, its transcript is empty. The available options depend on the presets and files present in your installation, so the source does not specify a fixed list. No minimum, maximum, or explicit default value is defined.
OmniVoice Voice Preset Output Parameters:
ref_audio
The selected reference recording as an AUDIO value. It contains the loaded waveform and the recording’s sample rate, allowing a connected node to interpret its timing correctly. Connect this output to OmniVoice Generate’s ref_audio input when using the preset as its voice reference. The audio is loaded from the preset’s source; this node does not alter the sample rate.
ref_text
The STRING transcript associated with the selected recording. Connect it to OmniVoice Generate’s ref_text input alongside ref_audio so the reference text and recording stay paired. For a local preset, this is the trimmed text from a same-stem .txt file. If that file is absent, the output is an empty string rather than a transcript generated from the audio.
OmniVoice Voice Preset Usage Tips:
- Connect
ref_audioto OmniVoice Generate’sref_audioinput andref_textto itsref_textinput; both outputs come from the same selected preset. - To add a local voice, place a supported audio file in the cache directory shown in the
presettooltip. Place a matching.txtfile beside it, with the same filename stem, when you have a transcript. - Restart ComfyUI after adding preset files so they appear in the selection list. Choose the entry ending in
(local)to use your added recording. - Check the transcript file before using a local preset when the downstream workflow needs reference text. A missing
.txtfile does not prevent this node from loading the audio, but it produces an emptyref_textvalue. - For presets sourced from a URL, the node downloads the audio only when its cache file is absent. Keeping that cached file available avoids another download on subsequent loads.
OmniVoice Voice Preset Common Errors and Solutions:
KeyError: '<preset name>'
- Explanation: The selected preset name was not found when the node ran. This can happen if a local audio file was moved or renamed after it appeared in the selection list.
- Solution: Check that the file is still in the cache directory, restart ComfyUI, and select a preset that appears in the refreshed list.
FileNotFoundError: [Errno 2] No such file or directory: '<path>'
- Explanation: The node could not find the selected audio file at the path it attempted to read.
- Solution: Restore the file or place it back in the cache directory, then restart ComfyUI and select the preset again.
urllib.error.HTTPError: HTTP Error 404: Not Found
- Explanation: A preset sourced from a URL could not be downloaded because the remote file was not found. Other HTTP status codes may appear for different server problems.
- Solution: Check that the preset’s source is available. If you manage the preset definition, correct its URL; otherwise, try a different available preset.
urllib.error.URLError: <reason>
- Explanation: The node could not reach a remote audio source, for example because of a network or connection problem.
- Solution: Check your internet connection and access to the source, then try again. A local preset does not require downloading its audio.
soundfile.LibsndfileError: Error opening '<path>'
- Explanation: The audio reader could not open or decode the selected file. The file may be damaged or may use an audio format the reader cannot handle.
- Solution: Confirm that the file plays correctly, then replace it with a valid, readable audio file if needed. Restart ComfyUI if you changed the preset file.
UnicodeDecodeError: '<encoding>' codec can't decode byte <value>
- Explanation: A local preset’s same-stem
.txtfile could not be read as UTF-8 text. - Solution: Re-save the transcript as a UTF-8
.txtfile and run the node again.
ref_text is empty
- Explanation: This is not necessarily an error. For a local preset, the node returns an empty string when its matching
.txtfile is missing or contains no text after surrounding whitespace is removed. - Solution: Add a nonempty UTF-8
.txtfile beside the audio file using the same filename stem, then run the node again.
