alexa-samples / alexa-smarthome

Resources for Alexa Smart Home developers.
https://alexa.design/smarthome
Other
686 stars 336 forks source link

Limitations of InputController #26

Closed rlbartle closed 7 months ago

rlbartle commented 6 years ago

There isn't much documentation on how to use the InputController interface. From what I gather it has support for a limited set of built-in names. However, the supported names are not documented anywhere.

Besides that, I think a more common case for modern devices is for user customizable input names. Instead of "HDMI 1", users almost certainly refer to it by the actual source device name. Any decent smart home system allows naming these inputs for user clarification. All user interfaces would show the device input source name so the user knows what they're doing. Controlling with Alexa should be the same.

Ideally InputController should be able to have a list of supported source names which can be used.

Here is a forum discussion on this: https://forums.developer.amazon.com/questions/79376/inputselect-slot-type.html

rlbartle commented 6 years ago

After playing around with this some, I have found that it does actually allow a range of custom names. However, the real issue is that Alexa really struggles to properly capture some names and is often confused which makes it return an error message before even passing the directive to the skill. It's particularly bad when trying to handle numbers. For example I spoke 'Digital 6', and I got a message with the payload 'DIGITAL SUCKS'. Because the returned payload is always approximate I had to integrate a fuzzy comparison with https://github.com/seatgeek/fuzzywuzzy.

It's obviously not how it is supposed to be - Alexa should handle the determination of speech, not me. Also when numeric suffixes of source names are used, it comes in with the english printed representation, so it makes comparison trickier. ie. "Media 1" is "MEDIA ONE". I normalize the speech strings and the actual source name strings that I want to match against, and then perform approximate matching.

With distinct names it usually works quite well, but almost always fails when trying to get it to differentiate between "Stream 1" and "Stream 2". Typically Alexa won't even understand the request if I ask "Stream 2", but "Stream 1" works fine.

Also I was wondering how to differentiate between devices when using this directive. The example syntax is “Alexa, change the input to \”, but it doesn't specify the device it applies to. When I try to say “Alexa, change the input of \ to \” or “Alexa, on \, change the input to \”, it doesn't understand.

aszk commented 10 months ago

Is this still happening? Supported input property values lists here

aszk commented 7 months ago

Closing due to inactivity.