intent#
- class besser.bot.core.intent.intent.Intent(name, training_sentences=None, parameters=None, description=None)[source]#
Bases:
object
The Intent core component of a bot.
Intents define a set of training sentences representing the different ways a user could express an intention (e.g. “Hi”, “Hello” for a Greetings intent).
Intents can also define parameters that are filled with information extracted from the user input using entities.
- Parameters:
- processed_training_sentences#
Processed training sentences are stored for intent prediction
- parameters#
The intent’s parameters
- Type:
- parameter(name, fragment, entity)[source]#
Add a parameter to the list of intent parameters.
This method creates an
IntentParameter
instance with the provided name, fragment, and entity, and appends it to the list of parameters associated with the intent.