| Developers Guide

| Developers Guide

  • Docs
  • API
  • Help
  • Blog

›Tutorials

Notes on Versions Released

  • Migrating & Updating
  • Updating to New Releases

Getting Started

  • Introduction
  • Installation
  • Quick Start

Main Concepts

  • Overview
  • Glossary
  • CMS
  • Dialog Engine
  • Actions & Hooks
  • Memory
  • Modules
  • NLU
  • Emulator

Advanced Guides

  • Debug
  • Configuration
  • Authentication Methods
  • Custom Module
  • Performances
  • Hosting
  • Version Control
  • Development Pipelines
  • Clustering

Channels

  • Website Embedding
  • Facebook Messenger
  • Telegram
  • Microsoft Teams
  • Converse API
  • Slack
  • Smooch (Sunshine Conversations)
  • FAQ

Tutorials

  • Deploying a cluster on Digital Ocean
  • How to act on an intent
  • Acting Proactively
  • Using Carousel Postback
  • How to use Slot Skill
  • How to use Call API Skill
  • Calling an API in a Custom Action
  • Shortlinks
  • Connecting your bot with your existing backend
  • Supported databases
  • Timeouts
  • Human in the loop
  • Jump To
  • Inter-bot Communication / Delegation
  • Contextual FAQ
  • Authenticate a user against a 3rd Party OAuth
  • Listening for file changes
  • Using a 3rd party NLU
  • Using the UiPath integration for Botpress

Pro Edition

  • About
  • Licensing
  • Configuring RBAC
  • Monitoring & Alerting
  • Bot Pipelines
  • Internationalization

How to use Slot Skill

Overview

The Slot skill is used to help with something that we refer as slot filling. It handles input validation and bot reply when the input is invalid.

Define your slots

Let's say that we have an intent to book a flight. We need the following information:

  • From where is the user departing (from)
  • Where he is going (to)
  • When he is departing (departure)

For the purpose of this tutorial, both from and to slots are of type @system.any. departure is of type @system.time.

Skill Slot Intents

Create your skill

  1. From the Flow Editor view, click on Insert skill > Slot.
  2. Choose an intent to use for the slot filling.
  3. Choose a slot to fill.
  4. Choose the content that your bot will ask. It should be a question about the information you seek e.g. "From where are you departing?", "Where do you want to go?", etc.
  5. Choose the content for your bot reply when the input is invalid. It should guide the user towards a valid answer.

Skill Slot Overview

Validation Types

There are two types of validations:

  1. Input validation: The first validation is based on entity extraction. If the provided information doesn't match the entity of the slot, the bot will notify the user. This will not apply when the slot has type @system.any.
  2. Custom Input Validation: An action can be used to add custom validation e.g. regex, type validation (number, string). The action should set the variable temp.valid to either true or false based on validation result.

Max retry attempts

How many times the bot should try to get the right answer. On not found outcome will be triggered when the maximum is reached.

Outcomes

Three outcome are possible:

  1. On extracted - The slot has been successfuly extracted. It will be stored in session.slots.<slot_name>
  2. On not found - The slot has not been extracted. This will also happen when the maximum number of retries is reached or when custom validation fail.
  3. On already extracted - The slot has previously been extracted. One use-case for that would be to ask for the user if the previous information is still relevant and if he would like to overwrite it.

Slot skill outcomes

Chaining Multiple Slots

You can chain multiple skills to fill all the slots for a given intent:

Skill Slot Flow

This flow will result in something like this:

Skill Slot Convo

Notice that in the first phrase "I want to book a flight to NYC", the intent "book-flight" is matched and NYC has been extracted as the to slot. Then, the bot tries to fill the remaining slots from and when.

← Using Carousel PostbackHow to use Call API Skill →
  • Overview
  • Define your slots
  • Create your skill
    • Validation Types
    • Max retry attempts
  • Outcomes
  • Chaining Multiple Slots
| Developers Guide
Docs
Getting Started (or other categories)Guides (or other categories)API Reference (or other categories)
Community
User ShowcaseStack OverflowProject ChatTwitter
More
BlogGitHubStar
Facebook Open Source
Copyright © 2021 Botpress Inc.