What if you’re creating a bot for a major online clothing retailer? For starters, the bot will require a greeting (“How can I help you?”) as well as a process for saying its goodbyes. In between, the bot needs to respond to inputs, which could range from shopping inquiries to questions about shipping rates or return policies, and the bot must possess a script for fielding questions it doesn’t understand.
No one wants to download another restaurant app and put in their credit-card information just to order. Livingston sees an opportunity in being able to come into a restaurant, scan a code, and have the restaurant bot appear in the chat. And instead of typing out all the food a person wants, the person should be able to, for example, easily order the same thing as last time and charge it to the same card.
It didn’t take long, however, for Turing’s headaches to begin. The BabyQ bot drew the ire of Chinese officials by speaking ill of the Communist Party. In the exchange seen in the screenshot above, one user commented, “Long Live the Communist Party!” In response, BabyQ asked the user, “Do you think that such a corrupt and incompetent political regime can live forever?”
There was a time when even some of the most prominent minds believed that a machine could not be as intelligent as humans but in 1991, the start of the Loebner Prize competitions began to prove otherwise. The competition awards the best performing chatbot that convinces the judges that it is some form of intelligence. But despite the tremendous development of chatbots and their ability to execute intelligent behavior not displayed by humans, chatbots still do not have the accuracy to understand the context of questions in every situation each time.
Several studies accomplished by analytics agencies such as Juniper or Gartner  report significant reduction of cost of customer services, leading to billions of dollars of economy in the next 10 years. Gartner predicts an integration by 2020 of chatbots in at least 85% of all client's applications to customer service. Juniper's study announces an impressive amount of $8 billion retained annually by 2022 due to the use of chatbots.
For each kind of question, a unique pattern must be available in the database to provide a suitable response. With lots of combination on patterns, it creates a hierarchical structure. We use algorithms to reduce the classifiers and generate the more manageable structure. Computer scientists call it a “Reductionist” approach- in order to give a simplified solution, it reduces the problem.
Another option is to integrate your own custom AI service. This approach is more complex, but gives you complete flexibility in terms of the machine learning algorithm, training, and model. For example, you could implement your own topic modeling and use algorithm such as LDA to find similar or relevant documents. A good approach is to expose your custom AI solution as a web service endpoint, and call the endpoint from the core bot logic. The web service could be hosted in App Service or in a cluster of VMs. Azure Machine Learning provides a number of services and libraries to assist you in training and deploying your models.
The bot itself is only part of a larger system that provides it with the latest data and ensures its proper operation. All of these other Azure resources — data orchestration services such as Data Factory, storage services such as Cosmos DB, and so forth — must be deployed. Azure Resource Manager provides a consistent management layer that you can access through the Azure portal, PowerShell, or the Azure CLI. For speed and consistency, it's best to automate your deployment using one of these approaches.
Previous generations of chatbots were present on company websites, e.g. Ask Jenn from Alaska Airlines which debuted in 2008 or Expedia's virtual customer service agent which launched in 2011.  The newer generation of chatbots includes IBM Watson-powered "Rocky", introduced in February 2017 by the New York City-based e-commerce company Rare Carat to provide information to prospective diamond buyers. 
Note that you can add more than one button under this card, so if the most common customer requests are your hours, location, phone number, or directions, create additional blocks with that information to return to the user. If you’re an online service-based business, you may want to include blocks in your buttons that give more information on a particular segment of your business.
With the help of equation, word matches are found for given some sample sentences for each class. Classification score identifies the class with the highest term matches but it also has some limitations. The score signifies which intent is most likely to the sentence but does not guarantee it is the perfect match. Highest score only provides the relativity base.
Back to our earlier example, if a bot doesn’t know the word trousers and a user corrects the input to pants, the bot will remember the connection between those two words in the future. The more words and connections that a bot is exposed to, the smarter it gets. This process is similar to that of human learning. Our capacity for memory and synthesis is part of what makes us unique, and we’re teaching our best tricks to bots.
When considering potential uses, first assess the impact on resources. There are two options here: replacement or empowerment. Replacement is clearly easier as you don’t need to consider integration with existing processes and you can build from scratch. Empowerment enhances an existing process by making it more flexible, accommodating, accessible and simple for users.
At a high level, a conversational bot can be divided into the bot functionality (the "brain") and a set of surrounding requirements (the "body"). The brain includes the domain-aware components, including the bot logic and ML capabilities. Other components are domain agnostic and address non-functional requirements such as CI/CD, quality assurance, and security.
Chatbots are a great way to answer customer questions. According to a case study, Amtrak uses chatbots to answer roughly 5,000,000 questions a year. Not only are the questions answered promptly, but Amtrak saved $1,000,000 in customer service expenses in the year the study was conducted. It also experienced a 25 percent increase in travel bookings.
“Bots go bust” — so went the first of the five AI startup predictions in 2017 by Bradford Cross, countering some recent excitement around conversational AI (see for example O’Reilly’s “Why 2016 is shaping up to be the Year of the Bot”). The main argument was that social intelligence, rather than artificial intelligence is lacking, rendering bots utilitarian and boring.
The chatbot is trained to translate the input data into a desired output value. When given this data, it analyzes and forms context to point to the relevant data to react to spoken or written prompts. Looking into deep learning within AI, the machine discovers new patterns in the data without any prior information or training, then extracts and stores the pattern.