adhearsion / ruby_speech

A ruby library for TTS & ASR document preparation
MIT License
101 stars 41 forks source link

Concatenated documents should have at least one space separating the strings #21

Closed bklang closed 10 years ago

bklang commented 10 years ago

Example:

s1 = RubySpeech::SSML.draw { 'thing 1' }
p s1

s2 = RubySpeech::SSML.draw { 'thing 2' }
p s2

# Concatenate
p s1 + s2

yields:

<speak xmlns="http://www.w3.org/2001/10/synthesis" version="1.0" xml:lang="en-US">thing 1</speak>
<speak xmlns="http://www.w3.org/2001/10/synthesis" version="1.0" xml:lang="en-US">thing 2</speak>
<speak xmlns="http://www.w3.org/2001/10/synthesis" version="1.0" xml:lang="en-US">thing 1thing 2</speak>

This would throw off most speech engines. I think the default should be more like:

<speak xmlns="http://www.w3.org/2001/10/synthesis" version="1.0" xml:lang="en-US">thing 1 thing 2</speak>
benlangfeld commented 10 years ago

v2.3.1 is out with this fixed