Training a Knowledge Base model
This document teaches IBM RPA developers, knowledge base managers, and data specialists how to use the Knowledge Base Training tool to train machine learning models that use Knowledge Base algorithms.
Contents
Training a Knowledge Base model
The Knowledge Base Training tool is an interface used to train Knowledge Base models. The user can test, improve existing data, and create new data for the model.
Follow these steps to start the Knowledge Base Training tool:
- Log in to IBM RPA Studio, selecting the desired tenant.
- In the options menu bar, select the Tools tab.
- Click the Knowledge Base Training button. The Knowledge Bases window loads all Knowledge Base models from the Tenant.
- Click on the Knowledge Base model name for training.
- Select the model version. A new tab containing the model name opens.
The tab that opens containing the Knowledge Base model name is the Knowledge Base Training tool. The tool has four tabs located in the lower-left corner.
The Knowledge Base model tests and training happen in the Trainer panel.
Follow these steps to train a Knowledge Base model:
- In the menu bar of the Knowledge Base Training tool, click on the Trainer tab.
- In the Minimum Score field, select the minimum certainty score for the best answer. The value varies between 0 and 1000, where 1000 is the certainty that the return is the correct answer.
- Optional: In the Options field, select Use synonyms so the model evaluation uses the synonyms database for words and expressions.
- In the Type a message field, type in a user message you wish the model to evaluate.
After typing the user message, the message evaluation by the model returns these data:
- The best answer, if it exists. The best answer is visible under the user message.
- In the Selected Answer section, there is the Score, Tags, and Context related to the best answer.
- The Other Answer section displays all the answers considered by the evaluation but with a minor score compared to the best answer.
- The Related Questions section displays all the existing questions in the knowledge base that returns the same best answer.
The Knowledge Base model training occurs by analyzing the answer to the user's message.
- If the answer is satisfactory: Try new messages or finish the training.
- If one of the answers in the Other Answer section is satisfactory: Click in select to use the answer as the new best answer.
- If no answer is satisfactory: In the Add New Answer field, type in the new best answer.
Notes:
- If the user's message is equivalent to an existing question in the Knowledge Base model, the score will be 1000.
- Selecting or creating a new best answer updates the matching question and answer set or creates a new set entry in the KB spreadsheet of the knowledge base.
- In the Other Answer section, click on edit at the desired answer to edit the answer's details.
- If there is no answer to a question, the tool prompts the user for a new answer, if needed.
After completing the training, see the Publishing changes section for details on publishing a new Knowledge Base model.
Changing terms
The Knowledge Base Training tool provides an interface for the user to modify words from the Words knowledge base file spreadsheet. The user can remove or add words.
Follow these steps to change words, considering that the Knowledge Base Training tool is running:
- In the menu bar of the Knowledge Base Training tool, click on the Terms tab.
- Act accordingly:
- To remove terms: Select the term removal icon next to the word in the displayed list.
- To add words: In the Add New Term field, type in the word.
After completing the training, see the Publishing changes section for details on publishing a new Knowledge Base model.
Changing synonyms
The Knowledge Base Training tool provides an interface for the user to modify synonyms from the Synonym knowledge base file spreadsheet. The user can remove, add, or change words and synonyms.
Follow these steps to open the synonym modification interface, considering that the Knowledge Base Training tool is running:
- In the menu bar of the Knowledge Base Training tool, click on the Synonyms tab.
To edit synonyms of a word:
- In the Word section, click on the word.
- In the Synonyms section:
- To remove synonyms: Click on the removal icon next to the synonym in the displayed list.
- To add synonyms: In the Add New Synonym field, type in the synonym.
To remove a word and its synonyms:
- In the Word section, click on the removal icon next to the word in the displayed list.
To add a new word and its synonyms:
- In the Add New Word field, type in the word.
- In the Word section, click on the added word.
- In the Add New Synonym field, type in the word's synonyms.
After completing the training, see the Publishing changes section for details on publishing a new Knowledge Base model.
Publishing changes
The Knowledge Base Training tool provides an interface for the user to review changes in the KB knowledge base file spreadsheet. The user can remove or publish changes.
Follow these steps to review and publish changes to the Knowledge Base model, considering that the Knowledge Base Training tool is running:
- In the menu bar of the Knowledge Base Training tool, click in the Changes tab.
- Act accordingly:
- To remove changes: Click the removal icon next to the selected row in the changes table.
- To publish changes: Click the Publish button.
Important: Select Production Version next to the Publish button, so the newly published version becomes the production version.
See the Using a Knowledge Base model for details on using a Knowledge Base model in your bots.
See also
- The Answer question (
answerQuestion
) command - The Bot Ask and Answer (
botAnswerQuestion
) command