I worked in the eClub Summer Camp this summer again. My task was to develop system allowing creation of chatbots and use it to make chatbot helping customers to choose their new smartphone. The result is Alquist. This is blog, which I wrote with my colleague Jakub Konrád and my boss Jan Šedivý:

Intelligent chat bots are hot and we have decided to design our own during the eClub Summer Camp 2016. Bots are streamlining the user’s interaction to a messenger type of applications creating the same UI for many apps. They relieve users from the maze of id/passwords and downloading app for each service. The users just log in to their preferred messaging app, load the bot’s profile and start talking to it. Bots can also be huge money savers for companies. They don’t have to build expensive apps for their business, they just integrate bot to a messaging service and communicate and offer their services that way.

Our goal is to simplify bots development. With our framework a developer does not have to write the whole bot each time from scratch. The Alquist dialogue manager (ADM) is our solution. The design does not provide an interactive UI. The Alquist framework relies on standards such as YAML, JSON leaving large space for customization. We also expect that the NLU models will be developed from larger data sets. For NLU text processing of larger set are the standards much more suitable. The initial assumption is also to run the Alquist DM on premise. I will explain, why is it special and why should you care.

The first important feature is versatility. The dialogue is defined by nodes in the YAML file. The ADM executes dialogue by walking through nodes and jumps between them as bot’s creator defines. In each dialog note the developer has a choice of procedures showing a text, NLU processing, saving data into a context (that is how we call bot’s memory), comparing data from context or showing predefined answers as buttons etc. You can mix all of these nodes or add some of your own, creating a unique bot.


Yaml file describing a dialogue

We also implemented a change of intent during the dialogue capability. What does it mean? If you have a bot talking about weather and news, you can change between these two topics anytime. During the news conversation, you can change the topic to weather by a single sentence with “weather” intent. Bot’s creator can define how intent triggers in which state will be processed to make step to the next node. This feature is great for more advanced projects.

In order for the bot to understand what you are saying, it uses natural language understanding (NLU). We currently use Alquist’s NLU implemented by Wit.ai. However, this is only a tempory solution we are developing our own tools. The main reason is to support other languages.

We are constantly developing, improving and adding new features into Alquist. Alquist is an open source project. You can view the whole Alquist’s code and documentation on Github https://github.com/AlquistManager. Don’t forget to try the actual demo at https://alquistmanager.github.io/alquist-client/?e=https://alquist.herokuapp.com.

Btw. Alquist is named after the character from R.U.R. by Karel Čapek.

Blog post was originally published on https://eclubprague.com/blog/alquist-dialogue-manager/.

2 responses

  1. Petr,

    I hope this helps your endeavours.
    I am probably singing to the choir here (yes this post will include many colloquialisms as a reminder they are as important any as teeth on a saw-check out Cockney rhyming slang)
    Since you all are the smartest of the smart yet you never know if my thoughts are unique until you read them.
    I am offering this to your team only since I’ve decided you are my champions.
    1) please make sure your chat bots smart people up and not dumb them down. Like Asimov please create global imperatives(rules) that each and every chat bot must “live by” from now and into the future. I believe that alone will help you advance in any competition.
    2) use data from audio books for machine learning. If mostly from redit I’m afraid you will be teaching it lazy shorthand speaking. This goes towards thought one, no laziness.
    And I am not saying to disallow teaching the chat bot lazy speak just do not let it use much of it.
    3) Give users of “chat” to choose an education level. The “hick” bot, “blue collar” bot and the “thoughtful” bot
    4)Use song lyrics and poem data for machine learning. I’m not suggesting to segregate these categories of 3) and 4) to be associated with your already defined cats, no, add that data to the main chat bot lexicon and language dbase.
    5) create a platform on a website for collecting data, like Amazon does with Alexa yet yours requests for people to add conversation data will go out to all of us that do not have Alexa yet want to support this adventure.
    6) Beowulf- this will support the future work when multilingual requirements come around.
    7) Watch Darmok – Star Trek TNG, episode w/ Picard and alien captain speak in medaphor. Machine language learn or custom code because this type of language choice could be a foundation for any language.

    That’s all for now.

    If any of these thoughts are helpful or not please tell me so I can adjust and keep thinking.
    Thank you. DJ Lock

    • Hi DJ Lock.
      Thank you for your tips. The fifth is very important. You need a lot of conversational data covering a broad range of topics with current techniques of machine learning and artificial intelligence. We have collected some amount thanks to Amazon and Alexa Prize.

      There are problems with Reddit for sure. But the audiobooks are not ideal too. Audiobooks (or books in general) contains a lot of parts, in which there are no dialogs (some descriptions of environment or feelings for example). These are the parts which we would have to filter. That would remove a big part of the book (which is a problem, we need as much data as possible). You may say, “just keep it there and let the AI learn from all of it”. The problem is, nobody knows how to do it yet. It is hard problem yet to be cracked.

      We tried to use subtitles from movies. This is a little bit better. The AI is able to communicate with you thanks to these data. But the conversation is strange. The conversations in the movies are dependent on the environment, characters and a story of the movie. AI sadly learns this dependency as a side product, so it references some characters in responses or refers to some things which are out of context of your current conversation. How to clean conversations from unwanted context? This is another hard problem waiting to be solved.

      I am happy when people are thinking about conversational AI, because more people will join the field, the faster we will create truly smart conversation AI.

Leave a Reply

Your email address will not be published. Required fields are marked *