Commit Graph

1636 Commits (101e841554820fc23d9bc9c305fad130a5c8c560)

Author SHA1 Message Date
00tiagopolicarpo00 101e841554 Create pt-pt 2017-09-15 00:07:00 -05:00
Åke Forslund 4d0fb1b739 Add test cases for version module 2017-09-15 00:04:24 -05:00
Åke Forslund c8d86ff98d Add check_version method to mycroft.version
==== Fixed Issues ====
NONE - replace with associated issue numbers, e.g. #123, #304

====  Tech Notes ====
Adds a function to check if the core version is newer than a given
version string.
2017-09-15 00:04:24 -05:00
Matthew D. Scholefield af8826a1c7 Learning option for sharing wake word recordings (#1039)
* Add automatic uploading of wake words and learning option in enclosure client

* Spawn new thread and remove ping
Spawning a new thread eliminates the need to ping and eliminates additional latency. In addition, the return code of scp is now used to determine whether to delete the wake word

* Increment enclosure version number
2017-09-14 23:58:32 -05:00
Jarbas e39d013282 Hotword factory (#1062)
* Create hotword_factory.py

* hotword factory

* hotword factory

* hotword factory

* pass language

* HotwordEngine base class

* standup_word config

* missing ,

* hotword factory

* missing ,

* HotWordEngine template

* hotword factory

* pep8

* hotword factory

* hotword factory

* hotword factory

* hotword factory

* hotword factory

* hotword factory

* hotword factory

* hotword factory

* hotword factory

* fix unittest

* fix conflicts

* recognizer dir fix

* fix path

* fix path

* correct path

* fix path for realz

* fix path for real realz

* path fixed, end of brain fart

* fix phoneme lenght

* compatibility

* num phonemes for non pocketsphinx modules

* pep8

* bug fix

* bug hunt
2017-09-14 23:34:16 -05:00
Matthew D. Scholefield 15d5295bb4 Fix dev_setup installing non-existent package 2017-09-14 18:14:46 -05:00
Matthew D. Scholefield b5cc7b91a7 Update README to no longer point to build_host_setup and fix dev_setup 2017-09-14 17:10:15 -05:00
Steve Penrod db72dde378 Fix another Codacy warning 2017-09-14 16:51:16 -05:00
Steve Penrod a268b2e0ee Fix Codacy warnings
Fixes a few minor things triggering Codacy warnings.
2017-09-14 16:51:16 -05:00
Steve Penrod 92b8b59cde CLI: Add find command and chat history sizing
This extends the Command Line Interpreter with two new features:
* Add command
    :find 'string'
  Only show log lines that match the given string, including
  newly incoming log lines.  Hit Ctrl+X to end the search.
  Ctrl+F works as a shortcut.
* Add command
    :history #
  Change the change history height to # lines.  This setting
  stays across sessions.
2017-09-14 16:51:16 -05:00
Åke Forslund 326939df35 Make muted mic stay muted when stt is restarted
====  Tech Notes ====
- Number of callers is now handled in the recognizer loop to make sure
status isn't lost when new settings is applied.
- Adds a force_unmute method to make sure the device is completely
unmuted when the user presses the top button.
2017-09-14 16:50:43 -05:00
Matthew D. Scholefield aa8606501e Move contents of build_host_setup scripts into dev_setup.sh 2017-09-14 16:48:28 -05:00
Åke Forslund cf9aafa765 Add data to the information of running skill
==== Tech Notes ====
The handler name (including class if available) is sent along in the
data field. If an exception is raised an exception field in the data is
added with minor information of the problem.
2017-09-14 16:38:54 -05:00
Åke Forslund 1d6da7d37d Add messages for skill handler's starting/stopping
====  Tech Notes ====
Add message bus messages when a skill handler is starting to execute and
a separate message for when skill handler completes. Usable if grouping
speech in certain clients for example. Can also be of use for audio
ducking and similar processes.

==== Protocol Notes ====
Adds the following messages:
mycroft.skill.handler.start
mycroft.skill.handler.complete
2017-09-14 16:38:54 -05:00
Michael Nguyen 592882d125 fixed codacity again 2017-09-14 14:23:39 -05:00
Michael Nguyen 8c88c0f2ae fixed codacity 2017-09-14 14:23:39 -05:00
Michael Nguyen 00f9bac927 Commit headline -- not longer than this line (50)
This is the template for commits to mycroft-core and also an example of
a commit message. To use this template, change the first line (think of
it as a "headline" for the commit) and then edit this message with a
longer description of the change.  To be nice, keep lines to 72
characters or less (The first two lines of this template are exactly
that length).  Also use imperative writing, e.g. "Fix broken code" or
"Implement my new feature", not "Fixes the broken code" or
"Implemented my new feature".

Sections below can then be filled out and edited as appropriate.
Unused sections can optionally be removed.

Please fill this out carefully.  This moment is when the code is
clearest in the mind of you, the foremost expert in this change.
Please pause to think of side effects and impacts.

====  Documentation Notes ====
mycroft-use script is used to switch from stable and unstbale builds for the mycroft core. It also points the unstable build to use the home-test.mycroft.ai cluster instead of production cluster.

mycroft-packaging repo needs to be merged to master for the packaging to take place.
2017-09-14 14:23:39 -05:00
Åke Forslund 1e74dd3ebe Restore reconnect timer on ws on connect
====  Tech Notes ====
The retry timer doubles on each failed connect attempt but was never
restored to the original time causing an unncessary long wait time. This
restores the timer on each sucessful connection.
2017-09-14 14:22:06 -05:00
Michael Nguyen 1068eb6324 Merge pull request #1077 from MycroftAI/bugfix/README
Update README.md
2017-09-14 13:29:47 -05:00
Michael Nguyen 54109a0785 Update README.md 2017-09-14 10:07:43 -05:00
Åke Forslund cc3a33aa77 Remove debug prints 2017-09-14 14:29:40 +02:00
Åke 40215bf69e Merge pull request #1076 from forslund/test/fix-api-test
==== Tech Notes ====

- Restore ConfigurationManager after mocking it
- Enforce value of cached pairing status
2017-09-14 11:28:47 +02:00
Åke Forslund 0d4a841d4e Make test_api slightly more robust 2017-09-14 11:01:32 +02:00
Åke beb384d28b Merge pull request #1075 from MycroftAI/feature/issue-1074
Add "audio" service to start.sh help.
2017-09-14 10:29:49 +02:00
aatchison d8489a312e Commit headline -- not longer than this line (50)
==== Fixed Issues ====

====  Documentation Notes ====
2017-09-14 12:39:23 +09:00
Åke Forslund d750935fe3 Allow any bitrate of audio to the MycroftSTT
====  Tech Notes ====
Setting the convert_rate enforces the output bitrate of the FLAC audio.

This requires update of speechrecognition (3.7.1) and PyAudio (0.2.11)

==== Environment Notes ====
PyAudio => 0.2.11
speechrecognition => 3.7.1
2017-09-13 14:31:36 -05:00
Åke Forslund a33c07621b Reduce configuration loading in module scope
====  Tech Notes ====
Autoloading configuration in submodules is bad for testing purposes and
should be reduced. It takes time and adds the possibility of altering
the base conditions for the tests

- mycroft/skills/core: global configuration moved to main.py
- mycroft/messagebus/client/ws.py global config moved to __init__ of
Websocket
- client/speech/mic.py global config moved to ResponsiveRecognizer
__init__() method
- client/enclosure/display_manager.py
 - get_ipc_directory() called in methods where used
2017-09-13 12:51:48 -05:00
Åke Forslund 14f931e046 Fix send pairing utterance before loading skills
====  Tech Notes ====
Add a wait until skills have been loaded once before checking for
internet connection. If not an "I'm sorry I didn't catch that" may be
emitted since the pairing skill isn't loaded.
2017-09-13 12:49:31 -05:00
Åke Forslund 31701fc05d Add more safety around the context manager
====  Tech Notes ====
- Sanity check Message in handle_add_context(), 'word' needs to be a
string before calling into the context manager.
- Sanity check Message in handle_remove_context(), make sure a context
keyword was received before trying to remove.
- Docstrings
- Suppress exceptions while injecting context
2017-09-13 12:44:35 -05:00
Åke Forslund 64baa7d420 Enclosure mutes the mic and should unmute it
====  Tech Notes ====
Listens for 'mycroft.paired' and will unmute the mic when this occurs.
This was handled by the pairing skill but for clarity it should be
unmuted at the same place.
2017-09-13 12:02:27 -05:00
Åke Forslund e9f8d85040 Make mic mute counting instead of boolean
====  Tech Notes ====
Mute was previously a simple boolean meaning that if two parts of the
code wanted to mute it it would unmute the mic as soon as the first of
the two pieces of code wanted to unmute.

For example tts output will mute the mic and unmute it when the audio
output is complete. During first start up of a mark-1 the enclosure
mutes the mic and expects it to be muted until the pairing is complete.
This doesn't work. The mic get's unmuted as soon as the first sentence
has been spoken.

This counts the number of times mute is called and will not unmute until
as many unmute calls has been made.
2017-09-13 12:02:27 -05:00
Åke Forslund 65fa735a3a Fix isSpeaking
====  Tech Notes  ====
isSpeaking was lowered as soon a the tts had synthesized the audio and
not when the output finished. This commit moves the signal
raising/lowering to the tts instead of the 'mycroft.speak' handler.
2017-09-13 12:02:27 -05:00
esoleyman c8c5afdeaf Change instance of ConfigurationManager().get to ConfigurationManager.get 2017-09-13 10:41:02 -05:00
Åke Forslund 5ddf1250ab Fix issues discovered by codacity. 2017-09-12 15:07:20 -05:00
Åke Forslund df8fe650c8 Update docstrings after PR feedback 2017-09-12 15:07:20 -05:00
Åke Forslund f1c6912d43 Add event scheduler
====  Tech Notes ====
A single thread handling scheduled events. The skills interact with this
using the self.schedule_event() self.schedule_repeating_event
self.update_event() and self.remove_event().

This is an improvement over scheduledSkill since each skill creates
their own Thread and has to handle storing/restoring scheduled events
between starts.

All pending events are stored in a json file at shutdown for future
sessions.

====  Documentation Notes ====
Needs to be documented

==== Protocol Notes ====
new messagebus event handlers:
- mycroft.scheduler.schedule_event
- mycroft.scheduler.remove_event
- mycroft.scheduler.update_event
2017-09-12 15:07:20 -05:00
Michael Nguyen 162b37ffbd Merge pull request #1063 from forslund/test/api-stt
Test api/stt
2017-09-12 10:14:16 -05:00
Matthew D. Scholefield 5b31047ccd Add check to see if on master branch in msm 2017-09-11 20:12:29 -05:00
Åke Forslund 72a318cd92 make skill id hash of skill directory
====  Tech Notes ====
To ensure that the skills have the same id when loading the id was
replaced with a hash of the skill directory. (as long the skill isn't
 renamed). This is useful for things like the event_scheduler where
skills are referenced using the skill id and has info being persistent
over restarts
2017-09-11 19:43:02 -05:00
Michael Nguyen c814c8e326 Merge pull request #1066 from MycroftAI/bugfix/Readme
Fix links on README
2017-09-11 15:58:12 -05:00
Michael Nguyen 8d9b291ec0 Update README.md 2017-09-11 15:21:39 -05:00
Michael Nguyen 80c855c38d Update README.md 2017-09-11 15:17:23 -05:00
Michael Nguyen 5fcf0158aa Update README.md 2017-09-11 15:16:49 -05:00
Åke Forslund fd75b05e82 Add tests for api module 2017-09-11 20:31:23 +02:00
Michael Nguyen eb6340265b Merge pull request #1060 from forslund/feature/ignore-enclosure-mouth-update-messages
Ignore enclosure.mouth.display message by default
2017-09-08 10:38:40 -05:00
Åke dd49219438 Merge pull request #1058 from MycroftAI/feature/notify-update
====  Tech Notes  
-Notification on dependency changes by comparing hashes of current requirements.txt and dev_setup script and last time the dev_setup.sh was run
- Update padatious to v0.2.2
2017-09-07 23:24:44 +02:00
Åke Forslund 0c8aaa2664 Ignore enclosure.mouth.display message by default
====  Tech Notes ====
Add 'enclosure.mouth.display' to ignore_logs default configuration since
it will get called alot and spam the skills log.
2017-09-07 15:59:34 +02:00
Åke Forslund 4386fe1f04 Add tests for stt module 2017-09-07 15:21:58 +02:00
Matthew D. Scholefield 9efcc01ce0 Update padatious 2017-09-06 19:22:33 -05:00
Matthew D. Scholefield 92cf04aad4 Add update notification 2017-09-05 15:46:24 -05:00