12/9/2023 0 Comments Rasa pythonIf required, it also offers a high degree of flexibility to make extensions and configurations to meet the needs of individual target groups. Rasa offers an easy way to create conversation assistants. If training data already exists in a certain data format, it is possible to create your own importers to avoid having to convert this data into the format described in the article. An application scenario for this are for example assistants that simplify reservation systems. In addition, you can create assistants using Rasa that fill out forms in the dialog. Rasa also offers the possibility to execute Python code with so-called actions, for example to create dynamic answers. In this example we have shown how to create a simple chatbot in Rasa that answers simple questions with fixed answers. How to build a chatbot using Rasa - Prospects Here we can test the conversation defined at the beginning and see if our chatbot gives the right answers. Therefore, we have to replace the value en with de. In our example, however, we want to set the language to German. We can make this setting in the config.yml file.īy default, English is the preconfigured language. Besides creating the training data for the NLU, we must specify the language of the chatbot to enable a correct recognition of the users' intentions. Setting the languageīefore we can start training the bot, we have to do some configuration. In this article we do not want to go into slots any further. Slots are key-value stores that the user can fill during the conversation. In this configuration, the session is terminated after 60 minutes without interaction by the user and slots are taken over into new sessions. The conversation is a dialog between the user and the chatbot. Furthermore, we configure the so-called conversation session here. In this file we list the individual intents and define the texts for the responses, i.e. text: “My developers were staff of Steadforce” text: “Yes, I am a bot and developed with Rasa ” The following example shows this using the intent is_bot. For a meaningful training we need at least four example data per intent. The training data need to be provided as a list. The individual intents must be specified in the format When the user interacts with the chatbot, the intent is recognized based on the input using so-called Natural Language Understanding. Creating Natural Language Understanding (NLU) dataĪfter creating sample dialogs based on the stories, we generate possible versions of the intents. We can also save these in Markdown format and use them for training. Rasa also offers the option of creating stories in an interactive mode. In this pattern it is possible to create different stories, which serve as a basis for the Dialog Management of the chatbot. Next follows another intent of the user, to which we answer with utter_created_by_steadforce. We see the definition of the response text right away in creating the domain. This is also just the name of this action. The chatbot reacts by replying with the action utter_i_am_a_bot. We will go into the various forms of this question in the description of Natural Language Understanding (NLU). This intent also has a name, in this example is_bot. An intent is an intention of the user, for example, the question whether the user’s conversation partner is a bot. It begins with a so-called intent, which is indicated by the * character followed by its identifier. In the next line the dialog between the chatbot and the user starts. With this the name of the story is defined and and therefore the beginning of such. The story is called "Bot challenge and ask for creator", as marked from the "-story"-key. story: Bot-Challenge and ask for creator
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |