Bot-creator can configure many options of the bot in Settings, including basic information, chat-client integration, confidence etc.
- Settings > Bot Information
- Name: name of the bot
- Language: language which bot supports (NLP)
- Description: purpose of the bot
- Bot code: used for API calling (see API guide for more detail)
- Bot token: used for API calling (see API guide for more detail) + Last success train: last training time of NLP (see NLP guide for more detail)
- Switch bot/admin:
- On: bot would answer automatically any question from user.
- Off: bot would not answer anything.
- On/Off for each integrated channel (ex: Facebook, Livechat)
- Import/Export data: of whole bot via Json file.
- Migrate from V2: this is used in case that bot-creator has a bot in FPT.AI Version 2, and want to migrate to V3 (current version).
Bot Intent Confidence
- Suggestion: to turn on/off suggestion feature.
- Confidence: to configure Max-Confidence and Min-Confidence.
The detail usage of these configurations is described below.
Answer Generation Logic:
- NLP results: check the MAX ‘confidence’, if it is:
- max-confidence (ex: 0.6) => reply intent’s answer
- < min-confidence (ex: 0.3) => reply default answer
- min < the result < max => check suggestions
- Use elastic search: suggest 3 samples which cover > 40% the input sentence (words)
- Note: if suggestion is
- Sample of QnA: suggestion’s content = the Question itself
- Sample of Intent (not QnA): suggestion’s content = the Intent’s Description (but not sample)
- Ex: intent=’ask_price’, sample=’how much is iPhone X’, then user ask=’price of Galaxy Note 9?’ => suggestion is bad with the sample, but should be the general description of ‘ask_price’ intent
- Delete Data: delete only data (scenarios, NLP…) but not the bot.
- Delete Bot: delete the bot.
Integrations (Chat Channels)
Bot-creator can integrate the bot with multiple communication channels such as Facebook, Viber, Zalo, Livechat (website) or Webhook for any other channels such as mobile apps, customized chat client.
The bot creator presses the button, logs into Facebook, then selects the page in the Facebook Page list to connect the bot.
Facebook at Work
Bot-creator can integrate the bot with Facebook at Work (F@W) by following below steps:
Bot-creator must have Administrator role of the F@W to setup required information
- Step1: Click “Integrations” on the left table page.
- Step 2: Then click “Create custom integration” and the system display the popup. User input name and description of integration, then click “Create”
Step 3: The system displays the popup to edit integration.
- In Grant Permissions (1), User select permission for integration.
- In Configure Webhooks (2):
- Copy Callback URL in Facebook at work channel of bot and paste in Callback URL of integration.
- Copy Verification token in Facebook at work channel of bot and paste in Verify Token of integration.
- In Access Token (3): Click “Create Access Token”, then the popup “New Token Created” displayed. Next, copy Access Token and paste in Page access token of bot.
- Click Done and Save.
- Reload page, search integration and chat with bot.
Bot-creator can integrate the bot with Viber by following the guide here to get the authentication token and paste it in this configuration.
Bot-creator can integrate the bot with Zalo by configuring the required information.
- Login Zalo to create OA account: http://oa.zalo.me
- Go link to select the OA account and configure information between Zalo and FPT.AI as below:
- Bot-creator can embed a livechat window into an existing website.
- The usage is: copying the provided script into the website source code, in scope of tag.
- Bot-creator can integrate the bot with other types of chat clients (ex: mobile app, internal chat system…) via webhook.
- The usage of webhook is described in detail at API Reference.