Select multiple options from suggestion in dialogflow - dialogflow-es

I am building a chatbot using dialogflow and I want that a user will be able to select multiple responses from Suggestions.
Is there any way to get it done using dialogflow fulfillment or something else? Or is there some other alternative to implement this?

I had the same issue, and my finding is that we can't select multiple suggestion chips.
but if you want to select multiple items from user in single intent then you can use "IS LIST" option in actions and parameters.
suppose you have an entity "fruits" having values {apple, orange, mango etc}
bot: what would you like to eat
user: I would like to have apple and mango
for this add training phrase "I would like to have apple and orange"
and in actions and parameters select "IS LIST" against "fruits" entity

Suggestion Chips are meant to be hints or ways to pivot the conversation.
Depending on your use case you can guide your user through different options. For example, if they are selecting a shirt, you can first ask for the color and then the size -- separating the different options to smaller subsets. A different option/example is for selecting music style (where one can choose one or several options) can be ask them to tell you the style of music they like (while providing 5 suggestion chips) and then in your response you confirm the styles and allow them to add more (while providing 4 suggestion chips of music styles and another that says "All done") --- I think I would also use this design to implement ranking of their preferred music.

Related

How to setup a more complicated 'IsList' parameter in Dialogflow

I've asked this question previously:
How to setup a complicated 'IsList' parameter in Dialogflow
In there I had this example:
"I want 7 apples, 8 oranges and 12 bananas"
So by setting up a 'Developer Composite Entity' that looks like this:
#sys.cardinal:Amount #Fruits:Fruit
I was able to solve my problem.
In there I'm using the #sys.cardinal system entity and my own custom #Fruits entity, which has a bunch of fruits in it.
I'm now looking for a way to handle examples like this:
"I want green apples, small oranges and cavendish bananas"
I then tried to make a new 'Developer Composite Entity' as follows:
#sys.any:Description #Fruits:Fruit
Now I'm using the #sys.any system entity instead of #sys.cardinal, but then I get this error:
"Do not use #sys.any in entities."
Is there any other way I can achieve this?
Help / Advice appreciated.
Don't use "sys.any"
Create a custom entity named "fruit-description" and add values like "small,cavendish,green etc." as many as you expect and also tick the "Allow automated expansions" Checkbox ,so any unexpected property which you have not mentioned is likely to be detected as a property.
Also train agent after adding new utterances carrying this new entitiy "fruit-description".

How to add text responses to selected suggestion chips on Dialogflow

I added suggestion chips to the Dialogflow Chatbot, but I want them to continue with an existing flow based on the button selected. How can I achieve that?
For example: How else can I help you?
Locate store Choose an item About Us
I would like the user to go these flows which already exist.
How can I achieve that?
You would make each of these choices a new Intent, and take action based on that Intent being triggered. Intents represent a specific activity by the user - typically something said or entered, or a selection chip being selected. Suggestion chips are handled just like the person entered what was on the chip.
However, keep in mind that these are just suggestions. Users can enter whatever they want. You need to be prepared for them to take the conversation in a different direction or skip ahead in the conversation. For example, in response to your prompt above, they may try to send feedback, or they may enter something like "find a store near me" and ignore the suggestion chip. You need to account for this when designing your conversations and Intents.

Complex Statements Intent Classification

Consider following sentences:
1) I want to watch movies watched by Srikanth but not by tarun
2) I want to watch movies of Christoper Nolan but not having Christian Bayle
3) I want watch movies watched by Srikanth but not liked by Tarun
The problem I am facing is -
Even though I can successfully define entities such as "not watched", "watched" , "not liked" , "having" , "not having" etc; etc;
Hence I will know what kind of action user is referring to.
I will also get to know names like Srikanth, Tarun, Nolan, Bayle etc;
But How do I establish Relationship between name and action. How do i know which action was related to which name.
I am not able to achieve this in LUIS / DIALOGFLOW.
What I feel is only way is to break statement into 2 distinct statements, How can we do that and is that a right approahc
We cannot directly assign multiple intents to the same utterance through LUIS. You can use NLTK along with LUIS to fix this issue as discussed here.
Another workaround is to create 2 apps with each intent and assign the same utterances and add the code which would differentiate the intent based on the keyword in the sentence.

Open dialog, slot filling chatbot

Hi I am creating slot filling chatbot where I would like to ask as much open question as possible at the beginning to make my flow the most similar to the normal conversation.
How can I achieve such a thing in terms of intents. Should I create three separate intents for case 1,2 and 3 and adding context flows in terms of 2nd and 3rd? Please help
For a case like this, you can do them as a single simple Intent that has prompts for parameters/slots that aren't addressed by the user.
First, we'll need a simple vehicle Entity type. Something like this, perhaps:
Once we have that, we can create an Intent and give it a few sample phrases:
We then need to do a few additional things (which are illustrated in the picture by the two orange arrows):
We need to mark the parameters as Required.
We need to give some Prompts for each parameter
With these, the Intent won't be complete until the user has responded to each prompt to fill the parameters. Once the user has given all the required values, it will call your fulfillment.

How to find out when user has enter wrong input when chatting with bot?

i am developing one Bot Framework related application in that i am showing like near by places for that user enter like this way "show me nearby places" here i am pass the key value "places" to google API and its producing the exact results, But here my question is when user enter wrong input like "show nearby places" and show places nearby me" at this time i want to show message "please enter correct input" for this how to show the user friendly message. please give the proper suggestion for me.
Thanks in advance.
You will have to use a NLP tool such as wit.ai, luis.ai or api.ai. The jury is out on which is the best tool so my advice will be to try out all and see for yourself.
You will essentially define stories and tell the NLP engine what the components of a statement are. So if you pass a statement to the NLP engine, it will parse the intents and objects to you.
For example your statement is "show me places nearby". Set your intent as 'nearby' and your entity as 'wit/location'. The tool should recognize variants of the above statement.
You can check out the recipe wit.ai have created for it here.
Else if you want just a string matching mechanism, check if your user's message has the substring 'location' and then show nearby places. Check out gupshup.io which has a Bot Builder that allows you to do this easily. (disclosure: I work there)

Resources