Guys from API.AI (NLP provider as a service) have recently made their Small Talk NLP module open and in this article I’m going to tell you why it’s a really big deal for all bot builders.
What is “Small Talk” Module at All?
Here at BotCube we’ve built a lot of bots during the last year using both api.ai and wit.ai as NLP providers. Most of time I’ve been choosing api.ai because of one reason — module called “Small Talk”. It allows you to easily import a lot of predefined answers for simple questions and phrases like “Hi!”, “How are you?”, “Are you robot?”, “What’s your hobby?”, “How old are you?” and many-many more (about one hundred actually).
Take a look at the screenshot — it was done without single line of code.
But what if I don’t like responses to the questions? You can easily change them.
To customize Small Talk responses you can easily rewrite default responses using api.ai UI.
Sounds like a perfect tool, right? 🤔
But of course this module is not perfect. At least it wasn’t a couple of weeks ago 🙂
What Problems we Faced With Small Talk on a Real Project
- You can’t customize every response.
During one of our projects at BotCube we were building a chatbot mostly for children use. So, we really needed it to act like a funny magical buddy and use its own distinctive phrases in order to engage children. But we couldn’t fully customize the responses from UI because of the existing limitations. Maximum percentage of responses you were able to customize from UI was about 60%. But it’s not enough to build a real image of a character.
Featured CBM: The Future of AI Is in the Hands of Storytellers
So we decided to change responses directly from the code. We built a mechanism to identify a question from JSON data and rewrite a response. But it was a shitty solution, because 60% of our texts were stored in api.ai UI and 40% were in the code. Just a mess to be honest.
2. You can’t train Small Talk.
Usually, when you are teaching the api.ai neural net to understand particular type of questions you are creating a thing called intent and add a lot of options there. Let’s say I wanna teach my character to tell when it will visit some town in USA. So, I’m creating a separate intent called WhenWillYouCome and add a couple of different options how can users ask me about this: “Please visit me here in Boston”, “Are you coming to Chicago at all?”, “When will you come to New York?”. Yep, that’s it, that’s training.
But you couldn’t actually train any Small Talk intent. You didn’t have access to it at all. In our case it was a super desired feature because children have their own kinda language to talk to a bot and we really needed some customization to be done but training was not available for a Small Talk too.
To say the truth Small Talk was more like a big black box with the cool features inside you can’t actually control.
How API.AI New Update Solved Our Problems
About a couple of days ago (it’s May 2017 now) api.ai rolled out their big update which included a lot of changes to Small Talk. So, right now you can split up the big Small Talk module into pieces and import it into your app as one hundred separate small intents.
And this update itself solves both of our problems: you can easily open any intent, change response and add more training data (take a look at the screenshot below). And that’s super awesome! 🚀
Good luck with new api.ai features and Happy Botting! 🤖 ❤
For More on API.AI:
Read original post here.