-
Notifications
You must be signed in to change notification settings - Fork 39
Quick Start
This tutorial shows how it's easy to create your first JAICF bot with JAICP and CAILA NLU.
JAICP (Just AI Conversational Platform) provides a lot of features for conversational applications developers, like CAILA NLU service, multiple integrations including telephony, text messengers, voice assistants and live operators, cloud hosting and dialogue analytics.
Log in to JAICP Application Panel and then create new JAICF project in the list of your projects.
This channel is great for testing and it also can be customised and installed to any website. Go to the Channels from the left menu bar and create new Chat Widget channel in the Incoming channels section.
You can config the look and feel of the widget as you wish. We recommend to check "Send /start" and "Show close controls".
This is a time to create some logic of your chatbot. To create a new Kotlin project, you have to have some appropriate IDE installed. We recommend to use IntelliJ IDEA due its native support of Kotlin language.
Create a new project using File > New > Project from version Control from the menu. Paste this template's URL jaicf-jaicp-caila-template and click Clone.
Template project contains a ready to use model for CAILA NLU. It's placed in the file named caila_import.json in the root directory.
Click on the cog in the top right corner, select Project properties -> Classifier -> Import CAILA project. Select caila_import.json file from your disk and click on Save button.
This appends one more intent named Smalltalk to your NLU model.
- Copy your API token from Project Settings in JAICP Application Panel
- Paste it into
src/main/resources/jaicp.properties
of your source code - Run
PollingConnection.kt
- Go to the Channels and click on Test of the Web widget channel
- Try it in action!
You've created your very first JAICF project. By fact this project utilises JAICP features like CAILA NLU (to recognise user inputs) and channels (web widget in our example).
Running locally on your PC, JAICF application connects to the JAICP project via JaicpPollingConnector
and retrieves all messages from the users who wrote something in web widget. Once received the message, JAICF sends it to the CAILA NLU to recognise an intent and then processes this intent through the MainScenario
activating an appropriate state and its action.
Now you may change your JAICF code and re-run it to see how responses are changed. For example, you can change reactions of your states, or add more intents to the CAILA model in the JAICP project and learn how to catch up these intents in your code.
Learn how JAICP transparently logs every interaction between the user and your chat bot, storing it to the Analytics -> Dialogs section in JAICP Application Panel
In this quick start guide you've learned how to create a new JAICF project with JAICP integration and simple dialogue scenario, there are so many things to learn about framework itself, like:
- cross-platform support
- managing a dialogue state
- automatic testing
- and much more
You may also would like to learn another version of this Quick start if you're familiar with Google Dialogflow tool. It covers the same steps but with Dialogflow usage.
To dive into the JAICF, we recommend to go next through the Introduction section, FAQ and check for some JAICF project examples.