tts: add --stream-by-line, one utterance and one WAV header per line
With -o '-', stdin is read line by line and every line synthesises immediately as its own utterance, model and speaker staying resident across lines. Each utterance after the first opens with a fresh RIFF header, armed at end of line and consumed lazily at the next audio, so a client can split the stream into standalone WAV clips on the RIFF magic. Port of the feature contributed to omnivoice.cpp in ServeurpersoCom/omnivoice.cpp#11. Co-authored-by: Jeffrey van Binsbergen <comgenie@comgenie.com>
This commit is contained in:
co-authored by
Jeffrey van Binsbergen
parent
ed8052eeb3
commit
df66c67706
@@ -494,7 +494,8 @@ Required:
|
||||
-o <path> Output WAV (24 kHz mono). '-' streams to stdout (pipe friendly).
|
||||
|
||||
Input:
|
||||
stdin Target text to synthesise. Read fully then synthesised in one shot.
|
||||
stdin Target text to synthesise. Read fully then synthesised in one
|
||||
shot, or line by line with --stream-by-line.
|
||||
|
||||
Optional:
|
||||
--format <fmt> WAV output format: wav16, wav24, wav32 (default: wav16)
|
||||
@@ -507,6 +508,7 @@ Optional:
|
||||
--max-new <n> Max new audio frames (default: 2048)
|
||||
--codec-chunk-dur <f> Codec decode chunk duration in seconds (default: 24.0)
|
||||
--codec-left-dur <f> Codec decode left context duration in seconds (default: 2.0)
|
||||
--stream-by-line Flush synthesis at each newline, one WAV header per line (-o '-')
|
||||
|
||||
Sampling:
|
||||
--seed <int> Sampling seed (default: -1 for random)
|
||||
|
||||
Reference in New Issue
Block a user