- skills
- audio
- speech client
- messagebus service
- enclosure
The main functions now accepts the arguments ready_hook and error_hook
allowing a service or runner script to catch these states and perform
actions accordingly.
This is useful for things like systemd or a desktop launcher.
Fix audio service startup
_record_phrase now uses a helper class to track the noise in a sentence
to determine when the user has stopped speaking.
The logic should be the same but the same but allow for easier testing
and manipulation.
Some dependencies aren't actually required but can be optionally
installed for extra functionality.
The Chromecast is an optional audio backend
VLC is an optional audio backend
pyalsaaudio is only used by the mark1 enclosure
google-api-python-client is an optional STT backend, by default Mycroft
uses the Mycroft servers
If the stream is restarted while muted this would cause an Exception
leading to an unresponsive voice client due to the read_lock being
called before creation.
The DEBUG, has been filtered by default. This will disregard the DEBUG
filter completely since the same effect can be achieved by setting the
debug level using ":log level debug".
At some point during refactoring the ability to hit Ctrl+C to exit the basic CLI was lost.
The signal.SIGINT handler is needed by the graphical GUI, but it
interfered with the use of sys.stdin.readline() in the simple CLI.
Rearrange the installation of the handler for only the GUI.
To test, run:
mycroft-cli-client --simple
Then hit Ctrl+C. Before this change nothing happens (you just see the "^C" printed out). After the change it exits as expected.
Account ID will now be refetched if invalid the first time.
This also adds some general exception handling to avoid client crashing due
to the servers invalid 204 response.
The pairing trigger should only be triggered by the 401 status for the
Mycroft hosted STT backends. Doing it for other STT's is only confusing.
This creates the decorator 'requires_pairing' that can be applied to the STT modules where it's relevant.
This adds the decorator to the MycroftSTT and the MycroftDeepSpeechSTT
Major refactoring of the skills startup sequence
- Restructure to a less nested structure
- Remove usage of globals by wrapping a lot of state variables into a class this allows for things like caching a negative pairing status throughout the startup process
Message bus config loading is now shared by service and client.
messagebus.client.ws file is still available in case skills are using it. It is a backport that inherits from the new MessageBusClient class. Adds depreciation warning.
A backwards compatibility piece of code creates a hotword from the
listener settings if the listener referes to a non-existing hotword.
This makes sure the generated config doesn't affect the loaded
configuration to avoid extra reloads of precise.
The reload check is now using a more reliable method and only a subset
of the configuration. Currently set to "listener", "hotwords", "opt_in"
and "stt".
The initial framework for live streaming Speech to Text. STT derived
classes now can report that they support live streaming via their
"can_stream" property. If True, the following member functions will be
called on the object:
stream_start() - Called when a stream is starting. Should setup any
persistent state required to process speech to text.
stream_data(chunk) - Called when a chunk of audio data has been
captured.
stream_stop() - Called when a stream should be stopped. Should tear down
any state setup with stream_start(). Note that this may be called at
anytime (even if stream_start() has not been called).
Note that the execute() API is still used to get the text utterance from
the class.
A typical sequence of calls would be:
stream_start()
stream_data(...)
stream_data(...)
stream_data(...)
stream_data(...)
...
execute(...)
stream_stop()
When opt in is set and local saving of the file no mtd would be generated and the cause a undefined variable exception. This generates metadata if it's missing
* Restored ability to store wakewords locally
The code that handles the local save of wake words configuration -
"record_wake_words" - was removed some time ago. This restores that
capability.
Add the following to mycroft.conf
{
"listener": {
"record_wake_words": true
}
}
Then restart Mycroft. It should begin saving .wav files under the
/tmp/mycroft_wake_words directory.
The filename, will be filename structure is:
<accountId>_<engine>_<model>_<name>_<sessionId>_<time>.wav
* Add documentation for 'record_wake_words' and improve the doc for
'save_utterances'.
* Catch the new system.gui.user.interaction
This will in turn trigger the gui.page_interaction similar to the page flip but page_number will be None
* Fix issue when adding pages
Seems like appending would fail at times
* Add lock around namespace modifications
* Improve argument description for override_idle