Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[snips-tts][picotts] TTS input is not uttered when the hyphen '-' is the first character of the input string. #54

Closed
TMaddox opened this issue Sep 7, 2018 · 2 comments

Comments

Projects
None yet
4 participants
@TMaddox
Copy link

commented Sep 7, 2018

When the first character of the string provided to snips-tts is an hyphen, snips-tts does not produce the expected sound.

Version
All

Platform
Raspbian (using pico tts)

How to reproduce
result_sentence = "{} times {} is {}".format(first, second, calc)

If first has a negative value (f.e. -3) the TTS engine does not output the text.

Workaround
result_sentence = " {} times {} is {}".format(first, second, calc)
Mention the space next to the "

@cpoisson

This comment has been minimized.

Copy link
Collaborator

commented Mar 8, 2019

Issue confirmed on Snips Flow 1.1.0 (0.61.1)

Protocol
on a Pi, snips-audio-server and snips-tts are started

mosquitto_pub -t hermes/tts/say -m '{"siteId":"default", "lang":"en", "text": "-6 ", "id": "fakeid", "sessionId": "fakesession"}'

does not produce a sound output

mosquitto_pub -t hermes/tts/say -m '{"siteId":"default", "lang":"en", "text": " -6 ", "id": "fakeid", "sessionId": "fakesession"}'

does produce a sound output (add a space)

The issue comes from pico2wave integration

pico2wave -w test.wav "-something"

produces the following output as the text input is interpreted as a command option

Invalid option -something: unknown option
Usage: pico2wave <words>
  -w, --wave=filename.wav     Write output to this WAV file (extension SHOULD be .wav)
  -l, --lang=lang             Language (default: "en-US")

Help options:
  -?, --help                  Show this help message
      --usage                 Display brief usage message

The following commands do work (hyphen only, or a space before the hyphen)

pico2wave -w test.wav "- something"
pico2wave -w test.wav " -something"
pico2wave -w test.wav "-"
pico2wave -w test.wav " -6"

@cpoisson cpoisson changed the title TTS bug with '-' in the beginning [snips-tts][picotts] TTS input is not uttered when the hyphen '-' is the first character of text string. Mar 8, 2019

@cpoisson cpoisson changed the title [snips-tts][picotts] TTS input is not uttered when the hyphen '-' is the first character of text string. [snips-tts][picotts] TTS input is not uttered when the hyphen '-' is the first character of the input string. Mar 8, 2019

@cpoisson cpoisson modified the milestones: Snips Flow - Release 1.1.3, Snips Flow - Release 1.1.2 Mar 11, 2019

@cpoisson

This comment has been minimized.

Copy link
Collaborator

commented Mar 20, 2019

Fixed on version 1.1.2 (0.62.2)

@cpoisson cpoisson closed this Mar 20, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.