Chatbase group by locale - chatbase

I'm currently developing a simple messenger bot, which supports multiple languages.
Is it possible in chatbase to group conversations by user locale? Can I somehow include the locale in message_received request?
Is it OK to append the locale to the chatbase_fields.version ?

We plan to add arbitrary key:value pairs to the api when we release our redesigned backend in the coming months. For now, there are a few solutions for separating your bot's messages.
You can create a separate bot for each locale, and send messages to each respective bot.
You can use the version field of the api to denote the locale and filter your metrics accordingly.

Related

Is it possible to add custom emojis?

If I wanted to use custom emoticons from https://slackmojis.com/
Does the getstream client (ios, android, web) allow adding these custom emojis?
I don't see any docs for emoticons https://getstream.io/chat/docs/message_input_view/?language=js&q=emo
StreamChat backend stores reactions as strings and allows users to create their own reaction types. Backend only sends these reaction types as strings and does not send/store any associated image/emoji for reactions (but you can achieve this via custom extra data if you need). Frontend SDKs parse these reactions and render them with default values (emojis).
You can definitely add your own reaction type, as outlined in here.
In iOS SDK, you can override defaultEmojiReactionTypes property in your ChatViewController subclass to provide an emoji for your reaction type. Currently, only default emojis as reactions are supported. It's in our roadmap to support any vector graphic as reactions.

Dialogflow Integration into Custom CRM

I am trying to wrap my head around using Dialogflow for developing and integrating an SMS chatbot with our custom CRM. The creation of an Intent is pretty powerful and straight forward. However, I am trying to understand best practices for something. If I have an intent used to return the price of a service at a certain location, I can model that very easily within dialog flow. However, when an SMS message comes in, it will be from a new customer or a known existing customer for a certain location. For existing customers, we already know the location and therefore don't want them to have to specify the location value in the intent. Prior to sending the inbound SMS message to the client API to match the intent, how can I pre-set the "location" parameter value in the intent so it does exists even if that inbound SMS message did not include it? For example a known customer in Dallas would just have to say "how much is a xxx" instead of "how much is a xxx in Dallas".
Can you use the API to set a parameter value prior to calling the API to try and match the intent? If so, how do you get do that without a session ID? The reason the "location" is needed is because when we get to the fulfillment, the prices for the same service are different based on the location so I will need to be known but we don't want to make existing customers say the location.
Maybe another option is to have a Location intent with an event that we can trigger through the API. this would have an output context on it called location and fulfillment that sets the parameter value. But even then I struggle with understanding how to pass in values like location, phone number, etc into dialogflow from the calling application so dialogflow has those parameter values to use in fulfillment.
Reading documentation, watching videos and starting to test client API v2
This is certainly possible. What you would want to do is use the Dialogflow API for this. Here you can find the languages for which Google has created client libraries: https://cloud.google.com/dialogflow/docs/reference/libraries/overview
As soon as you have any 'if' in your code you should use the fulfillment: https://dialogflow.com/docs/fulfillment
How I would handle this:
Client sends SMS
You check in your back-end if this user is known. If known -> don't ask location, else you ask the location
Match the user query against the Dialogflow client library
Dialogflow will return the intent if (any) is matched
You should define and implement any logic before calling the Dialogflow library.

Sending a message to user when user enters a geofence / area?

I'm making a dialogflow agent that will be integrated with various platforms (Facebook messenger, slack and maybe a few others) that will have the basic functions of a informational chatbot.
The agent will be for a specific store and I'm wondering if it's possible to trigger some sort of welcome message once the user enters the geofence (in this case, the store)?
Thanks for the help. I haven't found any documentation for this on dialogflow specifically or anywhere else so anything will be awesome.
Note: I'm am not by any means dead set of dialogflow, if AWS Lex offers something like this and it's better, I will take a look. I'm just a bit more used to dialogflow.
This cannot be achieved just by using either Lex or Dialogflow. Because at the end of the day, you are using them to integrate with Messenger/Slack/Whatsapp and these apps will (for obvious good reasons) not share the user's location information with the bot. You will need a helper app which takes the user's location permission as well and triggers the bots for you.
Keep in mind that channels like Messenger and Whatsapp have restrictions over sending messages willy-nilly to users. Messenger has a '24+1' policy Whatsapp also you can only send free form messages in the 24 hour window. But after that you can send chargeable pre-approved "hsm" message templates.

Track multiple context for the same Bot

We have a bot that will be used by different customers and depending on their database, sector of activity we're gonna have different answers from the bot and inputs from users. Intents etc will be the same for now we don't plan to make a custom bot for each customer.
What would be the best way to separate data per customer within Chatbase?
I'm not sure if we should use
A new API key for each customer (Do we have a limitation then?)
Differentiate them by the platform filter (seems to not be appropriated)
Differentiate them by the version filter (same it would feel a bit weird to me)
Using Custom Event, not sure how though
Example, in Dialogflow we pass the customer name/id as a context parameter.
Thank you for your question. You listed the two workarounds I would suggest, I will detail the pros/cons:
New API Key for each customer: Could become unwieldy to have to change bots everytime you want to look at a different users' metrics. You should also create a general api (bot) where you send all messages in order to get the aggregate metrics. This would mean making two api calls per message.
Differentiate by version filter: This would be the preferred method, however it could lengthen load times for your reports as your number of users grows. The advantage would be that all of your metrics are in one place, and they will be aggregated while only having to send one api call per message.

Can I install multiple bots on a single Facebook fanpage

We are having two teams building two bots for our Facebook fanpage. One is for customer service and the other one is for a quiz campaign. Can we have the two bots on the same fanpage? Will there be any conflicts such as the custom menu?
The short answer is YES!
However unless managed correctly there will be conflict.
I know it is possible to use one chatbot built on ManyChat and another on Flowxo.
I need to ensure that I LIMIT the "keywords" in ManyChat so that ManyChat does not respond and allows FLOWXO to respond.
In my situation, I am using the Pro version of MC to get users subscribed and to further broadcast to them or subscribe them to a sequence. I pass over the conversation to Flowxo for integrations to third party software and for the basic conversational aspect of the chatbot.
Passing the conversation over from one chatbot to the other takes some manipulation of the use of keywords and Flowxo's "unrecognised phrase" flow.
I will post the link to a blog post when I get around to writing about how I did it.
Another issue as you pointed out is the Greeting and Welcome text. I have not figured out a way to control this and as it turns out with my chatbot, users always appear to enter into the chatbot via ManyChat which fortunately for me is exactly what I need.

Resources