Commit Graph

53 Commits (da0f8ec9cdd93daab789738528c9d6e173dc26c8)

Author SHA1 Message Date
Åke Forslund 6a977ac96b Update Speech recognition module to 3.8.1
As suggested by @turboproc this restores GoogleCloudSTT. For details on the change see https://github.com/Uberi/speech_recognition/releases

==== Fixed Issues ====
#1329

==== Environment Notes ====
SpeechRecognition updated to 3.8.1
2018-01-08 17:39:04 -06:00
Åke 742558046d Python 2/3 compatibility (#1259)
Add Python 2/3 compatibility

====  Tech Notes ====
This allows the main bus, skills and cli to be run in both python 2.7 and
3.5+.

Mainly trivial changes
- syntax for exceptions
- logic for importing correct Queue module
- .iteritems -> future.utils.iteritems when accessing dicts key value
pairs

* Allow audio service to be run in python 3
* Make speech client work with python 3
* Importing of Queue version dependent
* Exception syntax corrected
* Creating sound buffer is version dependant
- Adapt context use range from builtins
- Use compatible next() instead of .next() when walking the skill
directory

* Make CLI Python 3 Compatible
- Use compatible BytesIO instead of StringsIO
- Open files as text instead of binary
- Make sure integer divisions are used

* Make messagebus send compatible
* Fix failing travis

Re-add future 0.16.0

* Make string checks compatible
* basestring doesn't exist in python 3 so it's imported from the "past"
* Fix latest compatibility issues in speech client
- handle urllib
- handle encoding before calling md5

* Make Api.build_json() python 2/3 compatible
2017-12-18 17:24:21 -06:00
Matthew D. Scholefield 2c48610650
Fix FANN dependency by locking to version 2017-12-08 16:50:18 -06:00
Åke 421c37f572
Merge pull request #1226 from ahayworth/feature-replace-google-tts-with-cloud-speech
Add Google Cloud Speech API STT
2017-11-20 09:53:00 +01:00
Matthew D. Scholefield b4226ff27b Remove pystache
On certain platforms it escapes quotes which causes problems. Since we only use it for something as simple as key value replacements, it doesn't make sense to include it as a dependency
2017-11-17 01:36:40 -06:00
Andrew Hayworth 6325c7ae7b Add replacment for Google TTS via Google Cloud Speech API
As noted on the Chromium Dev How-to [1] and on the
SpeechRecognition library docs [2], the Google TTS API
is really not the right API to call. While it's simple,
and allows you to authenticate via a simple token, it is
also limited to a max of *50* requests per day.

That's not a lot. I don't think many people will find that
useful, outside of quick testing (if they can even get an
API key - I couldn't figure out how to generate one that
worked correctly).

This commit introduces a new STT backend, google_cloud, so that
the Google STT backend can be deprecated eventually. To do so, we
needed to:
- Install the Google API Client Library
- Create a new STT class which knows how to turn a provided Google
  JSON credentials file into a string (the SpeechRecognition library
  expects you to pass in the JSON string, not a file path, nor an object).

Any person wishing to use this will need to:
- Enable the Cloud Speech API on the Google Cloud Platform console
- Create a new Service Account Key, and download the credentials to
  a secure location
- Configure that location in mycroft.conf, like so:

  "stt": {
    "google_cloud": {
      "credential" {
        "json": { contents of downloaded credentials }
      }
    }
  }

It's worth noting that the Cloud Speech API has a free quota of
60 minutes per month, which would probably stretch further than 50
individual requests. So for hobbyists, it should be nothing but
a net benefit.

[1] http://www.chromium.org/developers/how-tos/api-keys
[2] https://github.com/Uberi/speech_recognition/blob/master/reference/library-reference.rst#recognizer_instancerecognize_googleaudio_data-key--none-language--en-us-show_all--false
2017-11-15 22:10:00 -06:00
Arron Atchison 9a00ee258a
padatious==0.3.7 2017-11-02 17:07:06 -05:00
aatchison 4d2235692c removed default skills pip requirements from the requirements.txt 2017-11-02 17:03:27 -05:00
Matthew D. Scholefield 9d9d615904 Increment Padatious version to 0.3.7 2017-11-02 15:21:47 -05:00
Matthew D. Scholefield 8dc1dd5ab4 Increment Padatious to 0.3.6
Fixes issue registering entities
2017-10-26 18:59:17 -04:00
Matthew D. Scholefield ef1a6e24c3 Upgrade padatious to fix travis build 2017-10-06 00:06:08 -05:00
Matthew D. Scholefield b6bc4ee482 Increment padatious version number to 0.3.3
This adds a bugfix for empty containers
2017-10-04 21:50:54 -05:00
Matthew D. Scholefield 403aeb9360 Upgrade Padatious to 0.3.2 which brings in entity support 2017-10-03 12:17:02 -05:00
Matthew D. Scholefield a6709033d4 Remove wifi setup 2017-09-29 15:12:47 +09:00
Ethan Ward 1d67b17f00 Update requirements.txt (#1097) 2017-09-18 16:50:24 -05:00
Åke Forslund e182abedea Fix requirements installation 2017-09-18 09:49:17 -05: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
Matthew D. Scholefield 9efcc01ce0 Update padatious 2017-09-06 19:22:33 -05:00
Åke Forslund 0bd6c40694 Add fallback-aiml to defaults
====  Tech Notes ====
fallback-aiml was added to list of default skills in msm and the
requirement aiml==0.8.6 was added to requirements

====  Documentation Notes ====
NONE - description of a new feature or notes on behavior changes

==== Localization Notes ====
NONE - point to new strings, language specific functions, etc.

==== Environment Notes ====
NONE - new package requirements, new files being written to disk, etc.

==== Protocol Notes ====
NONE - message types added or changed, new signals, APIs, etc.
2017-08-18 02:13:01 -05:00
Matthew D. Scholefield dfa6fa2301 Update dependencies for Padatious and allow continuing if pip install fails
This is so that if fann is not installed locally, the user can still continue without padatious and only use adapt
2017-08-17 16:01:11 -05:00
Matthew D. Scholefield 69d17a373b Create PadatiousService and add padatious to requirements.txt 2017-08-17 16:01:11 -05:00
Åke Forslund 0c9f4ec786 Move testing requirements to test-requirements.txt 2017-08-17 02:05:02 -05:00
aatchison 9887009240 Upgrage netifaces in requirements.txt to netifaces==0.10.6 2017-08-02 11:57:57 -05:00
aatchison 80d152a95f restricted mock==2.0.0 2017-08-02 11:42:21 -05:00
Åke Forslund 0e2029d9fe Add support for muting pulse audio streams
when the audio configuration option "pulseaudio" is set to mute running
audio streams will be muted while mycroft is speaking and while mycroft
is listening.
2017-07-31 13:37:18 +02:00
Åke Forslund 581aafc3b6 Add pychromecast and python-vlc to requirements.txt 2017-07-31 13:37:17 +02:00
Steve Penrod e8e0853825 Merge pull request #838 from MycroftAI/feature/display_state_manager
Feature/display state manager
2017-07-21 19:58:07 -05:00
Connor Penrod 41698d4dbe Adds the ExtractDateTime parse function from Christopher (plus relevant tests) (#866)
Adds the ExtractDateTime parse function from Christopher.  When imported from mycroft/util/parse.py, it'll take a sentence like "What's the weather like 5 weeks from next Wednesday?" and will extract a python datetime object for that date.

* Added requirements.txt change for importing dateutil
2017-07-10 15:33:21 -05:00
Michael Nguyen f62a771e28 merge changes 2017-07-06 16:59:26 -05:00
Ethan Ward de4adb955b Remove uuid dependency; has been pulled into python standard library 2017-07-06 12:14:48 -05:00
Ethan Ward 738c181140 Removed unused dependencies from requirements.txt 2017-07-06 12:13:18 -05:00
Åke Forslund 728391427e Add test for PID locks
Catch IOError in delete method if pid-file doesn't exist
2017-06-16 14:17:43 +02:00
Michael Nguyen 7df83897ba added function in api.py to encode png images and display to Mark I faceplate 2017-06-07 17:19:26 -05:00
Åke Forslund 65d0943d4d Update pyOpenSSL version to 16.2.0
16.0.0 seem to have problems with newer versions of system installed
openSSL stack. Discussion in issue #705

Thanks to BoBeR182 for providing this solution.
2017-05-18 16:53:10 -03:00
penrods eff7b1bc6f Fix for issue #665. Synching requirements.txt versions with various skills- repos as a stopgap. 2017-04-14 18:18:13 -07:00
Arron Atchison e9ef6441a2 #496 update adapt-parser to 0.3.0 2017-02-15 15:37:52 -06:00
Arron Atchison cd1a36b94a Updating requests package in requirements.txt #464 (#465) 2017-01-20 15:31:13 -06:00
Åke 2a9bc7bda2 gTTS version bump (#454)
* upgrading gTTS

	- using play_mp3 to play mp3 files

Conflicts:
	mycroft/tts/google_tts.py

* Update gTTS version

* default to 'us-en' if lang is omitted

* Fix multiple sentence speech.

Wait until audio has been played before exiting `GoogleTTS.execute()`
2017-01-20 15:21:03 -06:00
Jonathan D'Orleans 416191e598 Issues 350 - Synchronizing local and remote configuration 2016-12-17 10:27:01 -05:00
Arron Atchison c52f92f949 Feature/issues 356 (#362)
* working on a client for wi-fi setup

* added refactored code, ready to integrate

* client is running, now to handle the rest

* Staring touble in the face

* saved

* added config settings for wifi setup

* add an entry point for wifisetup to mycroft-base-setup.py

* moved SSID sorting into LinkUtils

* I'm now using the new SanAp class throughout

* Cleaning up code. All bash executions use bashThreadHandling class, mycroft's LOGGER

* removed legacy configuration parser

* funneling effort into cleanup

* fixed pep8, see if she builds

*  changed entry point for init script

*  changed import path to full path

* changed import path to full path for all files

* change ws port to 8080 for now

*  pep8 in wifi.py fixed

* fixed a few more pep8 errors

* strange import stuff goign on

* strange import stuff goign on

* renamed wifi.py to prevent import conflict

* freeze pip requirement versions

* changed import path in LinkUtils

* changed import path again

* trying to fix wifi import.. something is wrong

* consumer and producer queues now working

* Consumer & producer API's are coming alogn

* Refactor: developing an API

* add ap up/down procedure to api

*  looking googd

*  removed some older code, api is nearly written

* success

* Sending conection status to browser is now working

* Fixed pep8 errors again

* removed blank line from file

* fixed entrypoint name

* added shutdown and save upon connect; reducing verbosity

* now disabling and flushing network on connection fail

*  fix start.sh

* Corrected amount of arguments passed to wpa_cli_disable_network

* added iface to disable network

* added shutdown on success; restart wpa_supplicant upon ap up

* turning powersave mode off for wlan0

* removed wpa_cli flush

*  fix some file restore and exit issues

* re enabled flush networks on fail

* powersave mode was logged but not executed

* stop and start dhcpcd withh ap up

* changed hostapd channel; bring links up and down after successful pair

*  removed double quotes from the wpa_supplicant template

* Multiple files combined into util.py

* clean up some comments, added license headers

* what is up

* Ap mode event fires on enclosure event

* added logic for open network

* Changed empty passphrase from bool to empty string

* enclosure version bump

* changed ap down method in WiFiConsumer

* I'm now pulling all configuration from mycroft.ini and grabbing the mac address for ap ssid

* REFACTOR: removed util.py, as it was a bit messy

* REFACTOR: remove pep8 errors again, you would think that I would do this each time

* chagned some logic for open net

* open networks now function properly

* Reboot on success

* changed network save method

* Issues 356 - Setup wifi connection
- Removing tornado dependency
- Merging WS reader with Wifi process

* Issues 356 - Refactoring
- Using PyRIC and WIFI libs

* Issues 356 - Refactoring bash command

* Issues 356 - Refactoring FileUtils

* Issues 356 - WebClient refactoring

* Issues 356 - create password and loading pages

* Issues 356 - connecting

* Issues 356 - parsing data on ws

* Issues 356 - removing fake function on wifisetup

* Issues 356 - connecting on public network

* Issues 356 - show loading page on backbutton

* Issues 356 - sort networks by quality

* Issues 356 - Fixing message type variable

* Issues 356 - Adding more logs to wifi setup

* Issues 356 - network sort by quality

* Issues 356 - Fixing cell ssid param and using correct interface for scheme

* Issues 356 - Ensuring to save scheme before activating

* Issues 356 - Logging bash command

* Issues 356 - Refactoring wifi to P2P

* Issues 356 - Simplifying cli usage and getting results from wpa_cli

* Issues 356 - Parsing ssid and pass

* Issues 356 - Saving wpa configuration

* Issues 356 - Removing postfix in favor of wpa_supplicant config

* Issues 356 - Setting host to 0.0.0.0

* Issues 356 - Fixing parsing for wpa_cli output

* Issues 356 - Ensuring to save wpa config after connected

* Issues 356 - Setting interface for save config

* Issues 356 - Ensuring interfaces in all wpa cli

* Issues 356 - Creating, staring and stopping wifi web server

* Issues 356 - Adding logs to web server

* Issues 356 - create succes page and merge connect page on list page

* Issues 356 - Config.js server addr

* Issues 356 - Adding wifi status and connected control

* Issues 356 - lock margin top wifisetup

* Issues 356 - waiting connection

* Issues 356 - Moving dnsmasq backup logic to main.py

* Issues 356 - Cleaning imports

* Changed the base manifest to reflect new file locations

* fixed indent for pep8

* changed the mycroft-base-setup.py to reference the proper entry point for wifisetup

*  Enclosure version bump

* Added the wifi index.html to the base manifest, as it doesn't seem to catch it recursively

* Issues 356 - Updating first setup flag after running the first time

* Issues 356 - Ensure to stop server only if it exists

* Issues 356 - Ensuring to set first setup to false when connected

* Issues 356 - Closing web server after shutdown

* Issues 356 - Running web server as daemon

* Issues 356 - Creating server connection only once at initialization

* Issues 356 - Disconnecting network before connecting and fixing get status

* Issues 356 - Starting web server only once after AP is up

* Issues 356 - Returning empty status if not able to parse

* Issues 356 - Creating web server loop control

* Issues 356 - Performing final request call in order to unblock server

* Issues 356 - Adding GET method to server request

* Issues 356 - Requesting web server to stop on main thread
2016-09-19 12:28:58 -05:00
Arron Atchison 736144028a fixed requirements.txt typo 2016-07-29 13:53:21 -05:00
Arron Atchison ae5882edfe added pocketsphinx to pip requirements once again 2016-07-29 13:47:40 -05:00
Ethan Ward b7965564e1 Replace outdated mustache library (#307)
* Change mustache library to Pystache

* Remove unneeded import
2016-07-28 10:15:43 -05:00
isaacnward a7fb9d2fe5 Issues/234: Weather display on faceplate (#255)
* i really need to fork

* Added weather functionality

* pep8

* uncommented line

* removed variable default values

* changed enclosure version

* edited metadata syntax
2016-07-12 10:26:18 -05:00
aatchison b57d6cc6f2 adapt bump to 2.7 2016-06-24 09:45:15 -05:00
aatchison c1ae384c2e edited postrm to unclude prvious if statement, adapt version bump 2016-06-23 10:16:35 -05:00
aatchison 06f75b3fa5 adapt version bump 2016-06-17 14:45:23 -05:00
aatchison 54a9ee4fa9 update pypi version 2016-06-14 09:12:21 -05:00
aatchison b5b3687b99 changes adapt-parser verson to 0.2.2 2016-06-13 12:17:25 -05:00
aatchison dff2573584 now pulling adapt-parser-0.2.2 from pypi.python.org 2016-06-13 12:14:33 -05:00