Please do not try to setup this API without referencing the Voice-Assistant-Boilerplate first to see if it meets your needs.
It is important to note this API requires a number of services to be registered and configured for before use.
- GitHub
- Make sure you have cloned this into a project that you can access, it's important!
- Snips
- Google API (OPTIONAL)
- Needed for WaveNet TTS. Google also requires a credit card for access to advanced APIs.)
- Heroku
Before using the API you will require a Snips account and project with some basic intents created.
You can use the guide below as reference to get started.
Login/Create a snips.ai Account
Simple enough...
EZ...
You can ignore the hotword option on the next page.
It is only necessary when using snips standalone.
We will be using artyom to detect our hotword instead.
Jarvis, what's a cool nickname?
Move/Copy the 'nlu_engine' folder into the root directory of the API
This step is only necessary if you would like to implement wavenet tts.
You will need to setup a new project and authorize that projects API access.
This process will yield your app specific credentials in a json format.
Replace the text in the 'auth.json' file with the json generated for you by Google.
You can use the guide below as reference to get started.
Login/Create a Google Cloud Platform Account
Next to the Google Cloud Platform text in the top left nav-bar, click the dropdown and select 'New Project' from the modal that follows.
Enter your details and after submitting wait for the notification to say complete.
Once it does, click the notification to open your new project.
Select 'APIs & Services' from the left slider menu and navigate to the dashboard.
On the top of this page, select the 'Enable APIs & Services' button to open the search page.
Enter 'speech' and look for 'Cloud Text to Speech API'. Select it to continue.
On the next page, simply select the 'Enable' button.
If you do not currently have payment authorized on your account you will be prompted here.
After enabling successfully, select 'Credentials' from the left slider menu to continue.
On the next page, select the 'Cloud Text to Speech API' from the dropdown and then click the 'What credentials do I need?' button.
Next, fill out the form like below (but with your own details), making sure to select JSON.
Click continue, and select 'Create without Role' (unless you want one).
A JSON file should download momentarily
Copy the contents into the 'auth.json' file in the root directory.
This should run pretty easily on Heroku if you follow the steps below:
Login/Create a Heroku Account
Once logged in, you will need to create a new Heroku application.
On the right side of your screen click the 'New' button and select 'Create new app'.
Enter the details of your choosing and click 'Create app' to continue.
On the next page, select GitHub under 'Deployment Method'.
If you have not linked your GitHub account with Heroku yet, now is the time do so.
Once you have, search for the name of THIS cloned repository on your GitHub account.
Click 'Connect' when you find it to continue.
Next, we need to enable automatic deployments.
This ensures any new push to 'master' will update our build on Heroku automatically.
Heroku will install the python modules in our 'requirements.txt' file when loading our app.
!! AFTER pushing to Heroku for the first time we need to modify our 'requirements.txt' and uncomment the remaining modules.
!! COMMIT those changes and push to your repo again, but ONLY after it has successfully built the first time which you can check under 'Activity'.
This is to resolve a dependency issue. If you know a better way for us to avoid this issue.
Please let us know here!
At this point, you should be registered for Snips, Google*, Heroku, and hopefully GitHub.
Please make sure you have both the 'voice-assistant-boilerplate' and 'voice-assistant-api' repositories installed before continuing.
Now that our API is in place. We can use our new API requests to serve to our website!
Continue by completing the Voice Assistant Boilerplate Prerequisites
- Connlaoi Smith - Ongoing Development - connlaoi
- Steve Bakos - Initial work on snips & python api - steve-bakos
- Neil Gaspar - Initial work on snips, artyom, & python api - neil-gaspar
See also the list of contributors who participated in this project.