In IFTTT you can create an applet that connects to your Google account and gets invoked when you say certain phrases directly to the Assistant. I’ve worked on dialogflow chat bots with some complex interactions and fulfilment services but it was always for in house projects so I never really go to a point where my bots where being used in a B2C manner. So for these bots you’d have to say something like “Talk to xyz” to invoke your agent and then you could continue talking and interacting with the agent.
I’d like to recreate what IFTTT does with Google assistant now, so that I can have users sign up once and then use my chat bot directly from their Assistant device, without the need to explicitly trigger the agent. Can someone please tell me how this works or point me towards where I need to research on this?
Artificial Intelligence is rapidly getting into the workflow of many businesses across various industries. Due to the advancements in Natural Language Processing (NLP), Natural Language Understanding (NLU), and Deep Learning (DL), we are now able to develop technologies capable of imitating human-like interactions which include recognizing speech, as well as text.
In this article, we are going to build a Conversational Chatbot app using Transformer (microsoft/DialoGPT-medium model), streamlit.
Transformer Model
A State-of-the-Art Large-scale Pretrained Response generation model (DialoGPT)
DialoGPT is a SOTA large-scale pretrained dialogue response generation model for multiturn conversations. The human evaluation results indicate that the response generated from DialoGPT is comparable to human response quality under a single-turn conversation Turing test. The model is trained on 147M multi-turn dialogue from Reddit discussion thread.
Streamlit
Streamlit is an open-source Python library
Streamlit makes it easy to create and share beautiful, custom web apps for machine learning and data science. In just a few minutes we can build and deploy powerful data apps.
Importing the libraries that are required to perform operations on the dataset.
import streamlit as st import torch import transformers from transformers import AutoModelForCausalLM, AutoTokenizer
Load the tokenizer and model
Streamlit cache, caches the tokenizer and the model. This avoids reloading of the tokenizer and the model and thus improving the performance.
@st.cache(hash_funcs={transformers.models.gpt2.tokenization_gpt2_fast.GPT2TokenizerFast: hash}, suppress_st_warning=True) def load_data(): tokenizer = AutoTokenizer.from_pretrained("microsoft/DialoGPT-medium") model = AutoModelForCausalLM.from_pretrained("microsoft/DialoGPT-medium") return tokenizer, model
tokenizer, model = load_data()
Set up the streamlit
In the session state of streamlit, we are storing the below items:
chat_history_ids: Stores the conversations made by the user in that session.
count: Count of conversations. It was observed that the model was not giving good results after 5 sequential conversations. So we use this counter to clear the chat history.
old_response: Stores the previous response by the model. Sometimes the model generates the same response as the previous, using this variable we can track such duplicate responses and we can regenerate the model response.
st.write("Welcome to the Chatbot. I am still learning, please be patient")
input = st.text_input('User:')
if 'count' not in st.session_state or st.session_state.count == 6: st.session_state.count = 0 st.session_state.chat_history_ids = None st.session_state.old_response = '' else: st.session_state.count += 1
Tokenizing the user input and returning the tensor output
Digital era has always amused us with its new innovative ideas and inventions. Digital India is a dream of every Indian and that dream has almost come true. It was only successful by applying artificial intelligence and one of them is AI virtual agents as contact center solutions that are being introduced in every field.
Virtual assistant call center service has played an essential role in customer servicing by assisting clients through interacting across various channels including emails, webchats, social media, etc., and has led intelligent virtual assistance to a new level.
Having said that, contact centers have always been run by human beings and there are unforeseen mistakes and risks which any company cannot afford to have. In this competitive world, we expect every work or job to be done perfectly and with less cost consumption.
This has been possible only through one medium is Virtual agents. Are you wondering how it works, what are its benefits? Then let us not wait any further. Let’s get started.
Firstly, what is a supercharging contact center?
As said earlier, supercharging contact centers which are also called e-contact centers are one-point contact areas where all customer interaction channels are managed with the help of CRM (Customer Relationship Manager). Basically, it includes one or more call centers integrated with CRM.
As the business grows, contact center solutions become quite important to achieve utmost customer satisfaction. To help the users with their queries and other issues related to the product, a contact center solution is very essential for a company’s growth. It allows us to maintain retention in the company for a longer time period.
What are virtual agents?
Virtual agents are a set of programs that have certain rules and support of Conversation AI in order to assist with customer service through various mediums. These virtual agents can help us through chatbots, emails, voice bots, or even interactive voice response systems.
In simple words, virtual agents can also be called digital assistants which is mainly helpful for huge organizations dealing with enormous amounts of customers or internal employees. Unlike other agents such as chatbots, virtual agents can communicate through any medium available.
Basically, virtual agents or virtual assistant call center services are pre-programmed or scripted products in specific ways to understand human language at ease. Upon request of human virtual agents receive the language and convert it to machine language with the help of ASR. Virtual agents will identify keywords and search for solutions.
Later the extracted solution will be converted into human-understandable language with the help of Dialog conversation. Thus, virtual agents can be effective and efficient.
How will supercharging contact centers with virtual agents be beneficial?
Virtual agents can provide numerous benefits to contact centers AI. Below are the following benefits where one can focus on
1. Improves customer experience
Digital India has made us more comfortable with technology than before. Hence, no one wants to wait in the queue to be answered and can resolve on their own with little help available. Virtual agents, with their unique way of approach, help the customers to reach for needed solutions in a short span of time.
Even though virtual agents provide minimal and only needed solutions, they are much more effective and useful solutions for our problems compared to other methods.
2. Available round the clock
We may not expect human beings to work 24/7 as there is a physical and mental limit, but with virtual agents, this is possible seven days a week. In this busy world, users do not have time to check in to companies’ websites to search for solutions. Through AI virtual agents nothing is stopping us by assisting our customers and getting utmost satisfaction.
3. Efficient data gathering
Every time a customer interacts with virtual data, the information shared is different from others. Virtual agent saves information in the backend of the system which is later used for fetching users’ data indeed, to upgrade or update the user system, better decision-making, etc.
From all the questions or the issues faced by virtual agents, managers or superiors can check the pattern or frequently asked questions so that solutions can be found out easily. It also helps us find out where exactly an issue is and at which level customers are facing this difficulty and at which location very easily.
4. Benefits to human agents
During festive seasons or any offers, occasions there will be high volumes of calls or inquiries and at this high rate of calls, there is a lot of pressure which results in not answering every customer efficiently. Thus, virtual agents are used to interact effectively. Here, we have to note that virtual agents are not here to replace contact centers but to assist.
Hence, while a virtual AI assistant for contact center agents can answer commonly asked questions that are still difficult for customers to figure out, contact centers can face challenging tasks which together result in inefficient customer service virtual assistants.
5. Advanced AI
Contact center virtual agents are a real boon to contact centers as AI is built with the capability to upgrade or to correct itself on its own. With every interaction with customers, virtual agent service learns more and more every day. This takes the weight of the developer to update virtual agents frequently.
With every interaction with users, virtual agents assure us that they have the potentiality to satisfy customers with their needs at ease.
6. Enhanced lead generation
As these intelligent virtual agents can gather any amount of information in a fraction of seconds and store it, they are very suitable for interacting with clients. Intelligent Virtual assistance understands the customer’s needs and can assist them at multiple levels and in a wider area compared to contact centers.
Conclusion
Considering all the above points, every contact center virtual agent can perform better with utmost user satisfaction and maintain 100% retention. This is the most effective and easiest way to resolve customer issues with very little cost consumption.
How to Collect User Data in Messenger and Export It to Google Sheets with the ManyChat Bot — EmpathyBots
Are you planning to generate leads for your business with Messenger?
Or, just growing a subscriber list of your newsletter?
Whatever it be, you just want to collect user data like name, email, contact number, etc.
And you know what, it is very easy to collect user data in Messenger with the ManyChat bot.
Not just that, In this tutorial, I’m going to show you how to collect user data in Messenger and export it to google sheets with the ManyChat bot so that you can easily access it later.
Before starting out, If you are not familiar with technical terms in chatbot development then please refer to my guide on technical chatbot terminology, because in this tutorial you need to be aware of that technical jargon.
Ok, I’m going to divide this tutorial into 2 parts, first we’ll see how to collect user data and then how to export it to google sheets.
So, let’s dive in!
How to Collect User Data in Messenger with ManyChat Bot
Before starting, I hope you have a ManyChat account, if not, then go create one.
Ok!, for this tutorial, we will collect 4 types of user data such as first name, last name, email address, gender, and user ID.
If you are wondering what is the user ID, then it is nothing but a unique ID given to each user by Facebook. I will tell you why we need a user ID in a while.
You just follow the following steps to collect user data in messenger with ManyChat.
I have already created one, so I will just select that.
If you scroll down a little, you will see an option to add the Skip button, I’m not going to add it, you can if you want.
Woohoo! You have just created your first user data field.
What it does is send a message and show a user’s email address as a quick reply button so that they can quickly enter an email address or type an alternative one if they want.
You need not ask users for their user ID, first name, and last name because you can extract it from their profile directly. I will show you how in the google sheets section.
Step 5:
Repeat the same process to collect the gender of a user.
Add the following text into a textbox,
“Please select your gender”
This time select the reply type as Multiple Choice because we’re going to give users the ability to select from the options.
Then, check the box asking to allow free text input as well, select your custom field, and add the options to select beneath a textbox.
Click on it, then on an action block > Actions > Google Sheets Action.
Then, click on Select Action under Google Sheets Action > Insert Row > and select your sheet.
Now as I told you before, you can extract the user Id, first name, and last name directly from the user’s profile, just insert the following system fields in ManyChat data in front of respective column titles,
User Id
First Name
Last Name
And then, insert a custom field you have created to collect email addresses in front of the Email Address column title,
The Global Chatbots Market is projected to witness around 24.10% CAGR during the forecast period, i.e., 2021-26. The growth of the market is driven primarily by the mounting adoption of Chatbots and the integration of Artificial Intelligence (AI) in them to enhance interaction with the customers & solve their queries instantly, without the need for human intervention in noncritical situations.
I created a chatbot at https://boredhumans.com/chat.php . Let me know what you think of it. It is programmed in AIML, which is not AI, but I used an extensive amount of custom programming to make it sound intelligent.