[OBSOLETE] Ask Alexa 2.3.9 (2018)

Version 2.3.9 of Ask Alexa

I am pleased to announce the 2.3.9 version of Ask Alexa! In this version I continue (along with help from the community) to evolve the application to allow more conversational syntax, along with adding more functionality for existing and new devices.

This app is used for those who are not happy with simply with simply saying “Alexa, turn on the living room”. If you are curious about the STATUS of a light, or run a very complex set of instructions (or even use a little bit of logic to choose what runs), then this program is for you. While the thread is long, I recommend you start with the first paragraph here ([NO LONGER SUPPORTED] Ask Alexa).

This will be a complex upgrade (Scenario 1, 2 and 3 http://thingsthataresmart.wiki/index.php?title=Ask_Alexa#Frequently_Asked_Questions_.28FAQs.29). Ask Alexa is part of the Community Installer written by @tonesto7. You can also upgrade your IDE code that way. However, you will need to upgrade your Lambda and Developer area as well.

PLEASE NOTE: Now that this app is rather stable (It is now 2 years old!) now I will be updating it less frequently except for bugs and new features. I am waiting for Amazon to release their ‘push’ notifications where some amazing stuff will happen with this app. Until then, if you do have a great feature idea for this app, just let me know.

Other additions to this new version include:

  • Echo Speaker Identification Ask Alexa is now aware (and ability to identify) the Echo device in each room, which opens up a plethora of new options! Please read how this changes the way you could potentially use Ask Alea Rooms/Groups: http://thingsthataresmart.wiki/index.php?title=Ask_Alexa_Rooms/Groups#Room_.22IN_HERE.22_Commanding
  • Various fixes As I went through every area of my code I came across a few items that I would classify as bugs that I squashed
  • Updated About Screen Not only can you see the associated speakers in the Rooms/Groups Extension, you can also see all of them in the About Screen.
  • New Setup Section To prep for some major changes in how you install Ask Alexa I have moved some components around. Many of the setup items (invocation name, setup variables, security) are now under Settings>>Setup Ask Alexa. In addition, I moved (and updated the cheat sheet) to this area as well and improved the look of this area.Too much HTTP underlining before.
  • PIN restrictions Speaking of the security, I was reading through some of the Echosistant posts to see what users really liked so I could bring it over Ask Alexa and came across this: [DEPRECATED] EchoSistant Evolved ~ Amazon Echo's Only Assistant with Robust Scheduling and Flexible Reporting - #663 by coreylista
    Since I added restrictions to the personality playback I also added restrictions to PIN usage as well. Now you can choose What (lock, doors, modes etc) and other restrictions like what echo is being used, or who is at home, to control WHEN a PIN is implemented. Thanks to the Echosistant team for the idea (It was in their product over a year ago…so it is good to have it in Ask Alexa now).
  • Better Setup Webpage The Setup Variables page now uses ‘iframes’ to take up less space on the screen for those long developer slots lists. This allow you to select all within a group instead of using the mouse to select each list. This also allows for easier ‘copy/paste’ from the setup page to the developer slots
  • Missing Routine Fix After a note from @sechen43 I was motivated to fix a long standing issue. Basically if you delete a routine or mode from SmartThings that was used in Ask Alexa you basically orphaned it, and it was difficult to remove. Now Ask Alexa recognizes this, and give you the option to remove the item from the list. Thanks for the motivation to finally fix this!!!

Partner Announcements
Nothing this time. For new developers…if you want to have your applications notify through Alexa, please reach out to me so we can work together on integrating your app with this feature.

Installation
For those with IDE integration with GitHub, simply update the repository and you will have the latest code for the SmartApp itself. It is recommended up update the utterances as there are some new ones available.

You can also now use the Community Installer (Free Marketplace) to install the IDE portion of this app. See more information here: http://thingsthataresmart.wiki/index.php?title=Community_Installer_(Free_Marketplace)

Support
All of you have been great in asking very relevant questions and making suggestions that I end up using. Here are some helpful tips on usage and support:

  • Sometimes it works best if I can work real time with you. To facilitate this, I have created a Slack channel: https://askalexa.slack.com. Using this tool is easy and will allow for real-time collaboration to solve the problems faster. To use this feature, I must invite you to the Slack channel. This will not be for normal questions; please use this forum for that function.
  • The Echo, as it is designed currently, cannot react to switches opening or other actions within SmartThings. She will do things for you, but only at your direction and at the time of the request. The delay timer mentioned in the control macro happens at the SmartThings hub, not within the Amazon Alexa control. See the new Message Queue functions for similar functionality with Big Talker!
  • When evaluating new features I will typically ask for a valid use case. If it can be used by others to bring them value I will put it on my list of future revisions. Not all suggestions will be used and many times I add aspects of the request.
  • There are no dumb questions, but many of the questions you may have were probably answered in the year since the initial release. Please take some time to go through the forum and the wiki if you have issues. And don’t be offended if I give you the specific area of the manual that answers your question. I have spent almost as much time on the documentation as I have on the app. Finally, there are some big fans of Ask Alexa that know almost as much as I do. They can also help.
  • Feel free to send me forks of utterances or even code revisions. As mentioned above, if it adds value to the overall program I will try to include it. This also goes for the wiki documentation…while I have spent over a year and a half creating this document, I am open to it being improved; I know there are probably still grammatical errors or syntax issues…If you find them, fix them…I will include your name (if I can) in any fixes submitted.
  • If you find a bug or a consistent crash please help me track it down by giving me repeatable steps to reproduce it. A non-reproducible bug, many times, indicates other areas that may be at fault besides the app. If you watch the live logging and see a red error with a line number, that is very helpful to me! However, I will need a full screenshot and not a copy/paste of the text. But be careful about revealing your OAuth and AppToken in your public posts. People can control you house with that information. You may want to blur that out.

As mentioned above, revisions will be less and less now. And with the code base now unified, I expect less and less additions…especially as I partner with other application developers to ensure their strengths can be brought into the notification model of Ask Alexa . Any and all suggestions are still on the table for addition.

As always, I appreciate any public accolades or even donations to my PayPal account: PayPal.Me . And, if you are so inclined, I also will accept bitcoins (or fractions thereof) if you have any laying around. My wallet ID is: 1CMgaiKgBfojTBCLpHLfa9KvcrW3cNxVpm
Enjoy.

6 Likes

Since version 2.3.9 is a ‘big’ upgrade I want to ensure everyone is able to do it successfully. Please follow these directions to get Ask Alexa completely updated to the new version. After you complete this process if you find Ask Alexa does NOT operate as you expect, I recommend going through the complete installation process again (do not delete anything, but just go through the steps) to see where your issues may be.

  • BACK UP your working Lambda code before you begin.
  • Use the Community installer, or your IDE, to update the SmartThings IDE code. ALL of the pieces of Ask Alexa have been updated, This includes:
    • Ask Alexa Main code
    • All extensions (Message Queue, Voice Reports, Weather Reports, Schedules and Rooms/Groups)
  • Save and Publish ALL items as you update them
  • Once you verify you can open Ask Alexa within your SmartThings App (DO NOT issues any commands to Alexa yet), go the Settings>>Setup Ask Alexa (this is a new area in Settings). Go down to Setup Variables. With your IDE Live Logging on your computer, tap Setup Variables. Grab the URL from the Live Logging (filter on Ask Alexa at the top), and open that page within a desktop browser.
  • Click the button labeled Display Lambda Code. Copy the entire code base and OVERWRITE your Lambda code at aws.amazon.com
  • Finally, also on the Setup Variables page, click Display Developer JSON Code. Paste this code to developer.amazon.com. This code specifically should go to the Interaction Model>>Skill Builder>>Code Editor.
  • Save and then Build the model at the top left of the screen.
    • Optionally, you can update your intent, developer slots, and utterances manually by following the directions here: http://thingsthataresmart.wiki/index.php?title=Ask_Alexa#Developer_Account
    • If you DO manually update your Developer’s area, be sure to update in the items in the correct order. First Intents, then slots, then utterances. Be sure to Save at the bottom of the page to build the skill
  • When everything is built and saved, Say “Alexa, ask {invocation name} for help”. You should get a long answer from Alexa about the app and its version. You should be ready to go at that point!
1 Like

I have a problem. Live Logging shows this.

For whatever reason SmartThings truncates the data in live logging sometimes. This does not happen to everyone(including me). Refresh the page and try again, maybe changing browsers. If that doesn’t work, I would recommend texting yourself the address of the setup page (which is on your mobile when you tap Setup Variables).

Here is mine…

1 Like

No Luck the same. Can I copy the URL from lower down LambaDA CODE VARIABLES

The URL is at the bottom of the Setup Variables page produced on your phone. Try copying it and emailing it to yourself. I also recommend opening a ticket with support at SmartThings to find out what causes the truncation.

1 Like

I am not sure what you mean. is it the item that says “URL of this setup page?”

1 Like

Yes. Copy that on your phone and email it some how to you desktop. Again I recommend you get with SmartThings and figure out WHY this is happening. PM me if you can’t get it and I can give you code to put into you IDE to get the URL in another way.

If it is the URL of the setup page I already emailed it to my self. I i contact ST what should I tell them?

Were you able to open the Setup Variables page on a desktop browser? If so then you can continue to follow directions for the upgrade.

As for the ticket, tell them your live logging is truncating data.

I finished, but do I have to rebuild my slots again? The AWS page doesn’t look like it did the other day. Could I be in the wrong URL? How do I copy and paste the device list etc?

While in the instructions, it is not clear so I will update it. Amazon (once again) updated their web site. At the top of the main page (where you choose your skills) you will see the “View Alexa Consoles”. Choose Skills (Not Skills (new console).

image

You should be brought back to the interface you are accustom to.

To answer your other question, however…YES you DO need to update your slots as there is NEW information I put in there to allow for better room control.

Am I correct to say my device list and Macros are

OK I thought I screwed up. Will update now. Thanks.

Not sure what you are asking, but the List of Macros will definitely be changed. I recommend going though each one or using the one-step method to simply update your JSON file in the developer area. That updates everything.

Also, I just updated the documentation:

http://thingsthataresmart.wiki/index.php?title=Ask_Alexa#Developer_Account

Didn’t they get the memo that any web site updates need to be cleared by you? :grin:

1 Like

Unfortunately no…While joking, Amazon pretty much does what they want. The site, empirically, is an improvement; however, it changes the process in which you install Ask Alexa. Fortunately, it is on the roadmap to get the skill to auto-install without having to go to the developer site, so we can FINALLY bypass all of this copy/paste mess :slight_smile:

Enjoy!

1 Like

One thing is confusing me. I understand we can associate one Alexa device to a room. I get that and no duplicates allowed. But I tried my normal command “Alexa tell the house to tune on Living room and family room” and I am now in my office, on the office Echo. Alexa tells me to associate this device to a group. I don’t want to do that, as I can be in another room with another echo. I have echos in every room. Now I have to say turn on one device wait for her to respond then the next and so on. Is this correct?

1 Like

I see truncation in my live logging but only when I use compound commands. The url for setup worked just fine for me.

Let me know if you contact support and if they give you an answer.

1 Like

There is not a requirement to associate a speaker with a room. I just tried a similiar compound command and it worked fine:

Are “living room” and “family room” rooms or individual devices? Either way they should be explicitly in your list of devices or macros list. Also, check your Amazon app for what she heard. I am betting she missed one of the key words. Compound commands, while ‘fun’ run into a limit with Alexa being able to parse multiple words properly in long sentences. As such, there is a higher ‘misunderstanding’ rate in compound commands.

1 Like

These rooms always worked, I use them every day. Each is a group of switches. Alexa heard exacrly what I said. look below. What now. nothing changed since yesterday. Below are screenshots showing the setup and config.



46%20AM

1 Like