File tree 2 files changed +3
-2
lines changed
2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -22,8 +22,9 @@ const synthesizeStream = textToSpeech.synthesizeUsingWebSocket(params);
22
22
// the output of the stream can be piped to any writable stream, like an audio file
23
23
synthesizeStream . pipe ( fs . createWriteStream ( './speech.ogg' ) ) ;
24
24
25
+ // !!!!! IMPORTANT !!!!!
25
26
// if the stream is not being piped anywhere and is only being listened to, the stream needs
26
- // to be explicitly set to flowing mode:
27
+ // to be explicitly set to flowing mode by uncommenting the following line :
27
28
28
29
// synthesizeStream.resume();
29
30
Original file line number Diff line number Diff line change @@ -99,7 +99,7 @@ class SynthesizeStream extends Readable {
99
99
const url =
100
100
( options . url || 'wss://stream.watsonplatform.net/text-to-speech/api' )
101
101
. replace ( / ^ h t t p / , 'ws' ) +
102
- '/v1/synthesize' +
102
+ '/v1/synthesize? ' +
103
103
queryString ;
104
104
105
105
const socket = ( this . socket = new w3cWebSocket (
You can’t perform that action at this time.
0 commit comments