# Alexa connector for RASA

**URL:** <https://forum.rasa.com/t/alexa-connector-for-rasa/10146>\
**Category:** Rasa Open Source\
**Created:** [May 22, 2019, 9:30am UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146 "2019-05-22T09:30:36Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![yashwanths112](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/yashwanths112/32/4150_2.png) [@yashwanths112](https://forum.rasa.com/u/yashwanths112)\
**Post date:** [May 22, 2019, 9:30am UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/1 "2019-05-22T09:30:36Z")

</div>

Hi, I am trying to use RASA NLU to develop alexa skill, but i found out there is no way of getting complete user utterance from alexa, in this forum there is a topic on google and alexa connector, there also I asked this question but I didn’t get any reply so creating this topic and also there is a tutorial about connecting google assistant with RASA and I did that, but I am not finding a way to do that with alexa.

Can anyone help me with this?

Thank you.

---

<div class="post-metadata">

**Author:** ![Juste](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/juste/32/15_2.png) [@Juste](https://forum.rasa.com/u/Juste)\
**Post date:** [May 24, 2019, 3:10pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/2 "2019-05-24T15:10:23Z")

</div>

HI @yashwanths112. I have experimented with Alex a little bit and had the same experience as you had, that it’s not that easy to pass user inputs to Alexa. I got it working in the end, I will try to find some time to write it all up and post it on the forum 🙂

---

<div class="post-metadata">

**Author:** ![yashwanths112](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/yashwanths112/32/4150_2.png) [@yashwanths112](https://forum.rasa.com/u/yashwanths112)\
**Post date:** [May 24, 2019, 3:36pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/3 "2019-05-24T15:36:22Z")

</div>

Thank you for the reply @Juste, that will be really helpful.

---

<div class="post-metadata">

**Author:** ![yashwanths112](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/yashwanths112/32/4150_2.png) [@yashwanths112](https://forum.rasa.com/u/yashwanths112)\
**Post date:** [May 28, 2019, 6:54am UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/4 "2019-05-28T06:54:31Z")

</div>

hi @Juste, can you please tell us when we can expect the tutorials about alexa connector?

---

<div class="post-metadata">

**Author:** ![mepc36](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/mepc36/32/4076_2.png) [@mepc36](https://forum.rasa.com/u/mepc36)\
**Post date:** [July 19, 2019, 6:30pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/5 "2019-07-19T18:30:57Z")

</div>

Hey Juste! Was this tutorial about creating a custom connector to Amazon’s Alexa that you mention in your August 2018 reply to a user named yashwanths112 (linked below) ever released?

> [@Alexa connector for RASA](http://forum.rasa.com/t/alexa-connector-for-rasa/10146/2):
>
> HI @yashwanths112. I have experimented with Alex a little bit and had the same experience as you had, that it’s not that easy to pass user inputs to Alexa. I got it working in the end, I will try to find some time to write it all up and post it on the forum slight_smile

I would love to know, thanks so much! Please have a good day.

---

<div class="post-metadata">

**Author:** ![Juste](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/juste/32/15_2.png) [@Juste](https://forum.rasa.com/u/Juste)\
**Post date:** [July 23, 2019, 9:23am UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/6 "2019-07-23T09:23:44Z")

</div>

Hi @mepc36. Not yet sorry, but I’ll try posting it by the end of this week. Will update you once it’s here.

---

<div class="post-metadata">

**Author:** ![mepc36](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/mepc36/32/4076_2.png) [@mepc36](https://forum.rasa.com/u/mepc36)\
**Post date:** [July 23, 2019, 12:46pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/7 "2019-07-23T12:46:52Z")

</div>

Great, thanks so much @Juste! I appreciate you letting me know when that Alexa connector tutorial gets posted. Thanks again!

---

<div class="post-metadata">

**Author:** ![HeiooDo](https://avatars.discourse-cdn.com/v4/letter/h/8baadc/32.png) [@HeiooDo](https://forum.rasa.com/u/HeiooDo)\
**Post date:** [August 1, 2019, 1:40pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/8 "2019-08-01T13:40:44Z")

</div>

I’ve done a poc to connect Alexa with Rasa Core. The NLU part is however performed by Alexa. You may have a look at this:

> **[GitHub - BadaBoomi/echo2rasa: This repository contains the complete code of...](https://github.com/BadaBoomi/echo2rasa)**
>
> This repository contains the complete code of the "echo2rasa" example project which gives a working example of an Amazon Alexa Skill implementd with the Rasa framework. - GitHub - BadaBoo...

---

<div class="post-metadata">

**Author:** ![Serge](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/serge/32/10491_2.png) [@Serge](https://forum.rasa.com/u/Serge)\
**Post date:** [September 9, 2019, 6:57pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/9 "2019-09-09T18:57:55Z")

</div>

@Juste Hey! I assume you’re crazy busy with the conference coming up, but what about writing about it after? Maybe by end of sept? Thank you.

---

<div class="post-metadata">

**Author:** ![mmm3bbb](https://avatars.discourse-cdn.com/v4/letter/m/3bc359/32.png) [@mmm3bbb](https://forum.rasa.com/u/mmm3bbb)\
**Post date:** [September 30, 2019, 3:16am UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/10 "2019-09-30T03:16:16Z")

</div>

Has anyone figured out if there’s a way to get the complete utterance from Alexa? I did a little test and the alexa skill intent handler lambda \<\> rasa interface is super-easy. But it seems like the alexa training data for that requires at least one fixed word. e.g.,

‘ok {full\_sentence}’ works so that I can say “ok hello there rasa” and this will invoke the alexa handler with the slot full\_sentence = “hello there rasa” … I can send that down to rasa and get the response back and say it.

But this:

‘{full\_sentence}’

is not a legal training example. So I’m stuck. Maybe there’s some trick with the fallback intent?

---

<div class="post-metadata">

**Author:** ![svshubham01](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/svshubham01/32/7321_2.png) [@svshubham01](https://forum.rasa.com/u/svshubham01)\
**Post date:** [February 6, 2020, 9:39am UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/11 "2020-02-06T09:39:38Z")

</div>

hey @Juste is there any update regarding this? please share the alexaConnector.py.

Thanks

---

<div class="post-metadata">

**Author:** ![Juste](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/juste/32/15_2.png) [@Juste](https://forum.rasa.com/u/Juste)\
**Post date:** [February 6, 2020, 9:45am UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/12 "2020-02-06T09:45:22Z")

</div>

Hi @svshubham01. We are working on this and will soon share a tutorial on it. Apologies it is taking quite some time 🙂

---

<div class="post-metadata">

**Author:** ![svshubham01](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/svshubham01/32/7321_2.png) [@svshubham01](https://forum.rasa.com/u/svshubham01)\
**Post date:** [February 10, 2020, 11:09am UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/14 "2020-02-10T11:09:07Z")

</div>

Hi @Juste It will be appreciated if you letting me know when we can expect that Alexa connector tutorial gets posted. Thanks again!

---

<div class="post-metadata">

**Author:** ![rctatman](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/rctatman/32/6734_2.png) [@rctatman](https://forum.rasa.com/u/rctatman)\
**Post date:** [March 2, 2020, 10:31pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/16 "2020-03-02T22:31:47Z")

</div>

The Alexa tutorial is live!

- Blog post: [Connect Your Rasa AI Assistant to Amazon Alexa](https://blog.rasa.com/connect-your-rasa-ai-assistant-to-amazon-alexa/)
- Video tutorials: [YouTube](https://www.youtube.com/playlist?list=PL75e0qA87dlGBbO8rWacgq9ejr5stsGnh)
- Code: [GitHub - RasaHQ/tutorial-rasa-alexa: Sample code for a Rasa virtual assistant with an Alexa connector.](https://github.com/RasaHQ/tutorial-rasa-alexa)

(Edited to fix line breaks.)

---

<div class="post-metadata">

**Author:** ![markdesign](https://avatars.discourse-cdn.com/v4/letter/m/85f322/32.png) [@markdesign](https://forum.rasa.com/u/markdesign)\
**Post date:** [March 6, 2020, 7:34pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/17 "2020-03-06T19:34:06Z")

</div>

Hi @rctatman, to my knowledge, the method of using single intent with a single slot to get the complete user utterance will not pass Alexa Certification.

I believe the Alexa docs says that this is not allowed.

Can you confirm that this will work now and any examples in production that have passed certification using this method?

Thank you!

---

<div class="post-metadata">

**Author:** ![rctatman](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/rctatman/32/6734_2.png) [@rctatman](https://forum.rasa.com/u/rctatman)\
**Post date:** [March 6, 2020, 8:47pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/18 "2020-03-06T20:47:49Z")

</div>

Hi Mark! I’ve heard mixed results from folks about using this approach in the certification process. I’ve been scouring the Alexa docs this week looking for a relevant policy and haven’t found one yet, but [someone from the Alexa team on Twitter](https://twitter.com/germanviscuso/status/1235219515283312640?s=20) suggested it would go against the certification policy. (If you’ve got a lead on more info I’d really appreciate it! 🙏) The Amazon team [recommended using custom slots as a replace after the Amazon.LITERAL intent–which did the same thing–was deprecated](https://developer.amazon.com/blogs/post/Tx3IHSFQSUF3RQP/why-a-custom-slot-is-the-literal-solution) so it does still seem like the best solution to me. I’m continuing to do more research & will post updates as I find out more.

In the meantime, if you have an [Alexa for Business](https://aws.amazon.com/alexaforbusiness/) account you can publish a private skill without having to go through the certification process. It will only work on your business devices, though, so not a very general solution.

---

<div class="post-metadata">

**Author:** ![Anand\_Menon](https://avatars.discourse-cdn.com/v4/letter/a/46a35a/32.png) [@Anand\_Menon](https://forum.rasa.com/u/Anand_Menon)\
**Post date:** [March 9, 2020, 5:37am UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/19 "2020-03-09T05:37:36Z")

</div>

My Favourite kaggler is in the house @rctatman 🤩

Now RASA tutorials are in great hands and thanks for the Alexa sessions

cheers

---

<div class="post-metadata">

**Author:** ![xiabai84](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/xiabai84/32/7712_2.png) [@xiabai84](https://forum.rasa.com/u/xiabai84)\
**Post date:** [May 16, 2020, 2:23pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/20 "2020-05-16T14:23:48Z")

</div>

Hi Rachael,

somehow Alexa can only return one utterance each time. Is there any way to configure it to give me all of my predefined utterances?

---

<div class="post-metadata">

**Author:** ![rctatman](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/rctatman/32/6734_2.png) [@rctatman](https://forum.rasa.com/u/rctatman)\
**Post date:** [May 18, 2020, 4:25pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/21 "2020-05-18T16:25:13Z")

</div>

Not that I know of unfortunately. You can store the conversation history on the Rasa side but I couldn’t find a way to get more than one utterance at a time passed from Alexa.

---

<div class="post-metadata">

**Author:** ![xiabai84](https://dub1.discourse-cdn.com/flex013/user_avatar/forum.rasa.com/xiabai84/32/7712_2.png) [@xiabai84](https://forum.rasa.com/u/xiabai84)\
**Post date:** [May 18, 2020, 11:01pm UTC](https://forum.rasa.com/t/alexa-connector-for-rasa/10146/22 "2020-05-18T23:01:24Z")

</div>

I found this in your Alexa connector code… responses = [m[“text”] for m in out.messages] message = responses[0]

If you change the second line to: message = " ".join(responses)

Alexa will get all utterances.

[Next page](https://forum.rasa.com/t/alexa-connector-for-rasa/10146.md?page=2)
