DEV Community

Cover image for Built a Conversational AI Chatbot Using Amazon Lex
Subashkumar
Subashkumar

Posted on

Built a Conversational AI Chatbot Using Amazon Lex

First, What is Amazon Lex?

Amazon Lex is a aws service that used to build conversational AI chatbot application using speech or text interface powered by the same technology that powers Amazon Alexa.

What you will learn here?

Learn step by step to build AI chatbot using amazon lex.

Prerequisites:

  • Basic knowledge of amazon web service and aws free tier account.
  • Fundamentals of AI and AWS concepts.

Amazon lex underlying topics:

Amazon Lex Topics

Intent: An Intent is an action that the user wants to perform.
Utterance: Utterance are textual representation of what a user has to type or says on order to trigger an intent.
Slots: Slots are input data requirement to fulfil the inputs.
Fulfilment: Fulfilment is to complete the users intent.

Let's start step by step to build conversational AI chatbot for order pizza:

Step 1: Go to aws lex page and Create Chatbot for OrderPizza.
Create chatbot

Step 2: Fill the Intent details as OrderPizza(Heading) and Utterance as Hello,Hii (start).

Image description

Step 3: Add a slot types
- First name (BuiltIn)
- PizzaType
- Pizza crust
- Appetizers
- Time for pizza delivery(BuildIn)
Add more slot types as we needed.
Slot types

Image description

Step 4: Fill the slot type value as Thin and Thick.

Step 5: Active the confirmation and type "Confirmation {Pizzatype} pizza with {Pizzacrust}. Appetizers {Appetizers}"

Step 6: Active the closing response and type "Thank you {Name}. Your order was confirmed and will be delivered by {DeliveryTime}."

Image description

Step 7: Go to slot prompt to add a buttons in advance options.
Advance Option-->slot prompts-->more prompt option-->Add card group

Image description

Step 8: That's it. We have created a AI chatbot for OrderPizza. Click Build and Test the chatbot.

Here is the link for Orderpizza conversational AI chatbot demo video : LINK
We can integrate this chatbot AI with the web and mobile applications.

** Thank you for reading and If this is more informative. Share with your friend and follow me **

Top comments (2)

Collapse
 
manifest45 profile image
manifest45

This is really nice, thanks for sharing.
I have a small question, I found this AI Chatbot randomly, it is an AI powered GPT enabled chatbot which is an AI shopping assistant for ecommerce brands.

Do you know about this, if yes how it is different from your chatbot?

Collapse
 
subashkumar profile image
Subashkumar • Edited

Thank you, both actually use for same purpose. But this amazon lex chatbot AI enable you to query from endless use cases. If you are using aws for your application go for amazon lex and aws lambda.
Just see aws lex customer success story for better understanding.