The LLM matching task matches passages to your chatbot user's utterance using a knowledge base of your chatbot content. LLM Matching runs after keyword questions have been matched, but before NLP question matching:
| LLM matching disabled | LLM matching enabled |
|---|---|
|
|
If you have enabled the rewrite utterance task, the matching conditions you configure will affect whether LLM matching uses the chatbot user's original utterance or the rewritten utterance.
Keep your configuration up to date
LLM matching uses the chatbot content data source in your knowledge base. When you change your chatbot content, the data source appears as ready to publish in versions. Make sure you publish the data source change with your chatbot version to keep the live chatbot's data source up to date. Remember to check your LLM matching configuration periodically and exclude any conversations or passages that should never be matched.
The LLM matching task is in the TrueIntent usage. You need an administrator or publisher role in your team to create a usage.
By default, new usages you create are set as the primary usage (the usage the chatbot will use). You can create a usage without setting it as primary if you need to.
When you create the TrueIntent usage, the LLM matching task is disabled. Disabled tasks won't appear in your live chatbot, but you can still configure and test them using automated tests. When you're ready to use the LLM matching task in your live chatbot, enable the task and publish the change.
When editing tasks and usages, check the top of the usage page to see if it is the primary usage and whether your changes must be published to take effect. If there is no message indicating your changes must be published, then the changes are applied immediately and will not appear in versions.
LLM matching may match your chatbot user's questions to different passages than your NLP training phrases, so you should test your changes thoroughly before you publish. You can create an automated test to test your prompt against a variety of utterances and generate improvements.
You can also test the task by asking questions in the Test Bot once the task is enabled. Questions that have been matched by LLM matching are shown in the test bot logs as Detection type: LLM Matching under the passage that was matched. The LLM matching task is not used during regression tests.
To create a TrueIntent usage and configure an LLM matching task, you must have:
- Generative AI configurations enabled for your chatbot by inGenious AI support.
- A connector to power the task.
You can see the list of connectors that support the task when you create the usage. - A knowledge base containing a published chatbot content data source.
Use the same usage
Your chatbot can only use one usage of each type at a time, so make sure you configure LLM matching in the same TrueIntent usage as other TrueIntent tasks you're using.
To create a TrueIntent usage and configure the LLM matching task:
- Click Manage in the left navigation, then click LLM Usages.
- Click your primary TrueIntent usage.
If you don't have a TrueIntent usage, create one:- Click + LLM Usage.
- In the Type field, select TrueIntent.
- Optionally, edit the Name for the usage.
- If you don't want the chatbot to use this task yet, clear the Set As Primary checkbox.
- Select the Connector to use for the task or select Create compatible Connector to create a new connector.
Only compatible connectors will be available.
You must have an administrator role in your team to create connectors. - Click Create.
- Click the LLM Matching tab.
- Leave the Enable LLM Matching field unselected for now.
You can configure the task and test it in automated tests without enabling it.
You'll need to enable the task if you want to test it in TestBot.
The task won't run in your live chatbot until you've enabled it and published that change. - By default, the inGenious AI platform waits a maximum of 10 seconds for the model to generate a result. If it doesn't receive a result within that time, it starts the passage that was matched by your NLP questions.
If you want to change this period:- Expand the Timeout section.
- Update the number of seconds the inGenious AI platform will wait.
- If you want to edit the default prompt used to generate the summary, type any edits into the Prompt area.
Make sure you don't delete the prompt variables: ${userQuestion}, ${chatHistory}, and ${content}. - If you want to include the transcript of the chat for context, select Populate ${chatHistory}.
If this field is not selected, the ${chatHistory} prompt variable is blank. - Select the Knowledge Base that contains the chatbot content data source.
- Select the Maximum number of Potential Answers the model should retrieve as possible passages.
A higher number can give more accurate matches, but will take longer to respond to the user and may need a connector to a higher-tier LLM model. - Select whether to match passages using:
- Passage Content.
- Training Phrases in the passage questions.
- Annotations you have added to passages and conversations.
- If you want to limit the chatbot content that can be matched against passages:
- Select either:
- Include if you want to match passages against only the conversations and passages you specify.
- Exclude if you want to match passages against all chatbot content except the conversations and passages you specify.
- Select Specific Conversations and Passages.
- Expand the Conversations List and Passage List sections and click + Conversation or + Passage to add the conversations and passages.
If you add a conversation, all passages from that conversation are included. You don't need to add those passages separately.
Adding a conversation does not add the passages from any child conversations. Add child conversations separately.
To remove all the conversations or passages you've selected, click the menu at the top of the list, then click Delete All.
- Select either:
- Click Save.
Enable LLM matching
The LLM matching task is only available to your live chatbot once you've enabled the task and published the change. To enable the task:
- Click Manage in the left navigation, then click LLM Usages.
- Click the primary TrueIntent usage.
Only the task from the primary usage will be used. - Click the LLM Matching tab.
- Click Enable LLM Matching.
- Click Save.
You must publish the change for it to take effect.