Build your own chatbot using Python and open source tools. This book begins with an introduction to chatbots where you will gain vital information on their architecture. You will then dive straight into natural language processing with the natural language toolkit (NLTK) for building a custom langua
Building chatbots with Python: using natural language processing and machine learning
ā Scribed by Raj, Sumit
- Publisher
- Apress
- Year
- 2018;2019
- Tongue
- English
- Leaves
- 205
- Category
- Library
No coin nor oath required. For personal study only.
⦠Synopsis
Build your own chatbot using Python and open source tools. This book begins with an introduction to chatbots where you will gain vital information on their architecture. You will then dive straight into natural language processing with the natural language toolkit (NLTK) for building a custom language processing platform for your chatbot. With this foundation, you will take a look at different natural language processing techniques so that you can choose the right one for you.
The next stage is to learn to build a chatbot using the API.ai platform and define its intents and entities. During this example, you will learn to enable communication with your bot and also take a look at key points of its integration and deployment.
The final chapter ofBuilding Chatbots with Pythonteaches you how to build, train, and deploy your very own chatbot. Using open source libraries and machine learning techniques you will learn to predict conditions for your bot and develop a conversational agent as a web application. Finally you will deploy your chatbot on your own server with AWS.
What You Will Learn
Gain the basics of natural language processing using Python
Collect data and train your data for the chatbot
Build your chatbot from scratch as a web app
Integrate your chatbots with Facebook, Slack, and Telegram
Deploy chatbots on your own server
Who This Book Is For
Intermediate Python developers who have no idea about chatbots. Developers with basic Python programming knowledge can also take advantage of the book.
⦠Table of Contents
Table of Contents......Page 5
About the Author......Page 10
About the Technical Reviewer......Page 11
Acknowledgments......Page 12
Introduction......Page 13
Chapter 1: The Beloved Chatbots......Page 16
Popularity ofĀ Chatbots Usage......Page 17
The Zen ofĀ Python andĀ Why It Applies toĀ Chatbots?......Page 18
The Business Perspective......Page 20
Chatbots Bring Revenue......Page 21
A Glimpse ofĀ Chatbot Usage......Page 23
Customers Prefer Chatbots......Page 24
The Developerās Perspective......Page 25
Market Demand......Page 26
Industries Impacted by Chatbots......Page 27
1950......Page 28
1995......Page 29
2014......Page 30
What Kind ofĀ Problems Can IĀ Solve Using Chatbots?......Page 31
Does It Have Highly Repetitive Issues That Require Either Analyzing or Fetching ofĀ Data?......Page 32
A QnA Bot......Page 33
Decision Trees inĀ Chatbots......Page 35
How Does aĀ Decision Tree Help?......Page 36
The Best Chatbots/Bot Frameworks......Page 40
Components ofĀ aĀ Chatbot andĀ Terminologies Used......Page 41
Utterances......Page 42
Confidence Score......Page 43
Why Do IĀ Need toĀ Know Natural Language Processing toĀ Build aĀ Chatbot?......Page 44
Benchmarks Results ofĀ spaCy......Page 46
Features ofĀ spaCy......Page 47
Installation andĀ Prerequisites......Page 48
What Are SpaCy Models?......Page 50
POS Tagging......Page 52
Stemming andĀ Lemmatization......Page 57
Named-Entity Recognition......Page 59
Stop Words......Page 62
Dependency Parsing......Page 64
What Are Ancestors inĀ Dependency Parsing?......Page 65
Interactive Visualization forĀ Dependency Parsing......Page 66
What Is theĀ Use ofĀ Dependency Parsing inĀ Chatbots?......Page 68
Noun Chunks......Page 69
Finding Similarity......Page 70
Good toĀ Know Things inĀ NLP forĀ Chatbots......Page 73
Tokenization......Page 74
Regular Expressions......Page 75
Summary......Page 76
Introduction toĀ Dialogflow......Page 77
Deciding theĀ Scope......Page 79
Building aĀ Food Ordering Chatbot......Page 80
Getting Started WithĀ Dialogflow......Page 81
Points toĀ Remember When Creating Intents......Page 85
Adding Default Response toĀ theĀ Intent......Page 86
Item Description Intent andĀ Belonging Entities......Page 87
Understanding andĀ Replying Back toĀ theĀ User......Page 91
Order Status Intent......Page 92
User_Order_ID Intent......Page 93
User_Thanks Intent......Page 95
Deploying Dialogflow Chatbot onĀ theĀ Web......Page 96
Setting UpĀ Facebook......Page 100
Creating aĀ Facebook App......Page 101
Setting UpĀ theĀ Dialogflow Console......Page 102
Access Tokens......Page 103
Configuring Webhooks......Page 104
Testing theĀ Messenger Bot......Page 105
Fulfillment......Page 110
Enabling Webhook......Page 112
Checking theĀ Response......Page 115
Summary......Page 117
Chapter 4: Building Chatbots theĀ Hard Way......Page 118
Why Should IĀ Use Rasa NLU?......Page 119
Installing Rasa......Page 120
Deciding aĀ Pipeline inĀ Rasa......Page 121
Building aĀ Horoscope Bot......Page 122
Conversation Script BetweenĀ theĀ Horoscope Bot andĀ theĀ User......Page 123
Preparing Data forĀ Chatbot......Page 124
Creating Data forĀ Model inĀ JSON Format......Page 125
Visualizing andĀ Modifying Rasaās JSON Data Format......Page 127
Training theĀ Chatbot Model......Page 129
Creating aĀ Configuration File......Page 130
Writing Python Code toĀ Train theĀ Model andĀ Predict......Page 131
Predicting FromĀ theĀ Model......Page 132
Dialog Management Using Rasa Core......Page 134
Understanding More onĀ Rasa Core andĀ Dialog System......Page 135
Action......Page 138
Slots......Page 139
Creating Domain File forĀ theĀ Chatbot......Page 140
Writing Custom Actions ofĀ theĀ Chatbot......Page 143
Data Preparation forĀ Training theĀ Bot......Page 146
Creating Story Data......Page 147
Training theĀ Chatbot Agent Model......Page 149
Real-Time Training by Reinforcement......Page 153
rasa-nlu-sdk......Page 155
Exporting Conversations AsĀ Stories......Page 163
Test Case 1......Page 165
Summary......Page 166
Rasaās Credential Management......Page 168
Creating anĀ App onĀ Heroku......Page 170
Creating andĀ Setting UpĀ anĀ App at Facebook......Page 171
Creating andĀ Deploying Rasa Actions Server App onĀ Heroku......Page 174
Creating Rasa Chatbot API App......Page 176
Creating aĀ Standalone Script forĀ Facebook Messenger Chatbot......Page 177
Integrating Webhook WithĀ Facebook......Page 180
Post-Deployment Verification: Facebook Chatbot......Page 182
Creating aĀ Standalone Script forĀ Slack Chatbot......Page 184
Subscribe toĀ Slack Events......Page 188
Subscribe toĀ Bot Events......Page 189
Post-Deployment Verification: Slack Bot......Page 190
Deploying theĀ Chatbot onĀ Your Own......Page 191
Writing aĀ Script forĀ Your Own Chatbot Channel......Page 192
Verifying Your Chatbot APIs......Page 194
Creating theĀ Chatbot UI......Page 196
Summary......Page 200
Index......Page 202
⦠Subjects
Computer Science;Programming
š SIMILAR VOLUMES
<div><p>Build your own chatbot using Python and open source tools. This book begins with an introduction to chatbots where you will gain vital information on their architecture. You will then dive straight into natural language processing with the natural language toolkit (NLTK) for building a custo
<div><div><div>Focus on implementing end-to-end projects using Python and leverage state-of-the-art algorithms. This book teaches you to efficiently use a wide range of natural language processing (NLP) packages to: implement text classification, identify parts of speech, utilize topic modeling, tex
<div><div><div>Focus on implementing end-to-end projects using Python and leverage state-of-the-art algorithms. This book teaches you to efficiently use a wide range of natural language processing (NLP) packages to: implement text classification, identify parts of speech, utilize topic modeling, tex
<div><div><div>Focus on implementing end-to-end projects using Python and leverage state-of-the-art algorithms. This book teaches you to efficiently use a wide range of natural language processing (NLP) packages to: implement text classification, identify parts of speech, utilize topic modeling, tex