ioBroker / ioBroker.sayit

Text to speech for ioBroker
MIT License
30 stars 25 forks source link
amazon iobroker smarthome speech-engine text2speech

Logo

ioBroker sayit adapter

Number of Installations Number of Installations NPM version

Test and Release Translation status Downloads

This adapter uses Sentry libraries to automatically report exceptions and code errors to the developers. For more details and for information how to disable the error reporting see Sentry-Plugin Documentation! Sentry reporting is used starting with js-controller 3.0.

SayIt Adapter can convert text to speech and play it on some device.

Configuration

Actually, the following outputs are supported:

To enable the text to speech on RaspberryPI or linux system call one time following command sudo apt-get -y install mpg321 to install mpg321.

The mp3/wav files can be played to by writing its name into the object. (e.g. /vis.0/main/img/door-bell.mp3)

The file must be first loaded.

TTS engines

Online:

Offline:

Cloud and Amazon Web Services Polly text formatting

You can format your text with Speech Synthesis Markup Language.

Most useful features:

More info.

System command

If you have some program, that can play audio files locally or somewhere else, you can write this command here. E.g.

myCustomPlayer --option

If System output is selected, the sayit adapter will execute the following command on a local system:

myCustomPlayer --option /opt/iobroker/node_modules/iobroker.sayit/say.mp3

If file name must stay somewhere in the middle, you can use %s to specify where the file name must be placed:

myCustomPlayer --option "%s" > /dev/null

sayIt will make myCustomPlayer --option "/opt/iobroker/node_modules/iobroker.sayit/say.mp3" > /dev/null from it.

Usage

SayIt adapter cannot be used alone. It must be controlled from javascript adapter or from "vis" with specific widget. After creation of adapter instance, you can find the following objects:

State tts.text supports extended syntax, so the language/engine and volume can be defined together with text. It is used to enable multi-language text2speech engines. E.g., if adapter has engine Google-english, it is possible with phrase de:Sag es to force using Google-Deutsch speech engine.

With ru;75;Погода хорошая we can force using russian language and volume 75%.

You can specify the volume of announcement in percent from current or given volume (not from maximal). E.g., if command is de;75;Gutes Wetterand "announce volume" is 50%, the announcement will be played with volume 38% from 100% possible.

The system command to play the mp3 file can be specified too. If you leave it blank, the default settings will be used: windows - cmdmp3.exe, OSX - /usr/bin/afplay, linux - mpg321 or omxplayer (recommended).

To install omxplayer write sudo apt-get install omxplayer or write sudo apt-get install mpg321 to install mpg321.

Note: The default announce selection will be possible only after the start of the instance.

Priorities

To immediately pronounce the text despite the queued texts, you have two possibilities:

Engines

The following values for engines are possible:

Google

Yandex

Amazon polly via cloud

Pico TTS

Coqui TTS

Amazon polly direct

Changelog

5.0.0 (2024-07-16)

4.0.5 (2024-07-12)

4.0.1 (2024-05-25)

4.0.0 (2023-10-31)

3.0.5 (2023-04-17)

3.0.0 (2023-04-03)

2.1.2 (2023-03-27)

2.1.1 (2023-03-24)

2.0.0 (2023-03-23)

1.13.0 (2023-03-22)

1.12.6 (2022-02-09)

1.12.5 (2022-02-09)

1.12.3 (2021-06-25)

1.12.2 (2020-11-07)

1.12.0 (2020-10-19)

1.11.5 (2020-09-24)

1.11.3 (2020-09-17)

1.11.2 (2020-08-08)

1.11.1 (2020-08-06)

1.11.0 (2020-08-02)

1.10.2 (2020-07-19)

1.10.1 (2020-07-16)

1.10.0 (2020-07-07)

1.9.8 (2020-06-11)

1.9.7 (2020-06-11)

1.9.6 (2020-05-24)

1.9.4 (2020-05-11)

1.9.3 (2020-04-24)

1.9.2 (2020-04-21)

Changed type of top-level object to "meta" in order to comply with js-controller v3

1.9.1 (2020-03-12)

1.9.0 (2019-11-06)

1.8.2 (2019-07-11)

1.8.1

1.8.0 (2018-12-04)

1.7.1 (2018-09-19)

1.7.0 (2018-06-08)

1.6.8 (2018-04-11)

1.6.7 (2018-02-05)

1.6.6 (2017-11-27)

1.6.5 (2017-11-04)

1.6.4 (2017-10-18)

1.6.3 (2017-10-04)

1.5.2 (2017-03-09)

1.5.1 (2017-02-15)

1.5.0 (2017-01-27)

1.4.0 (2017-01-16)

1.3.3 (2017-01-13)

1.3.2 (2017-01-10)

1.3.1 (2016-12-27)

1.3.0 (2016-12-20)

1.2.1 (2016-10-31)

1.2.0 (2016-10-28)

1.1.3 (2016-10-24)

1.1.2 (2016-10-20)

1.0.1 (2016-10-12)

1.0.0 (2016-05-14)

0.3.16 (2015-12-26)

0.3.16 (2015-12-26)

0.3.15 (2015-11-10)

0.3.14 (2015-11-01)

0.3.13 (2015-10-27)

0.3.12 (2015-10-06)

0.3.11 (2015-08-03)

0.3.10 (2015-07-26)

0.3.9 (2015-07-09)

0.3.8 (2015-06-09)

0.3.7 (2015-05-28)

0.3.6 (2015-03-24)

0.3.5 (2015-03-22)

0.3.4 (2015-03-20)

0.3.3 (2015-03-20)

0.3.2 (2015-03-16)

0.3.1 (2015-03-15)

0.3.0 (2015-03-08)

0.2.2 (2015-03-08)

0.2.1 (2015-03-07)

0.2.0 (2015-03-02)

0.1.0 (2015-03-02)

0.0.1 (2015-02-06)

License

The MIT License (MIT)

Copyright (c) 2014-2024, bluefox dogafox@gmail.com

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.