Updated on 2023-10-12 GMT+08:00

Intention Variable (TOC)

The system directly recognizes intention slot variables as those of the character string type. Therefore, use the same type of flow variables when associating the slot variables with flow variables.

Parameter

Description

TOC.ChatBotIntentCode

Code of a matched intention in semantic recognition. The value is a character string.

The following ChatBotIntentCodes are preset in the system and can be directly used:

  • systemQA:

Generally, you can obtain the value of this parameter to determine whether the correct intention is matched.

ChatBotRespContent

Reply for the intention matched in semantic recognition, including the reply configured in the slot and response.

TOC.ChatBotScenarioName

Name of the intention template that is matched after the semantic recognition is executed. The value is a character string.

For example, you can set TOC.ChatBotScenarioName to Seat Type in the following scenario.

TOC.ChatBotSlot name

This parameter is the slot parameter set in the intention. The value is a character string. You can use the intention template to view the slot parameters of the intention.

Choose TUC Management > Template Management > Intention Management, select a domain from the first drop-down list, click the link, and then click the Slot and Name columns to view the slot variable names.

For example, to obtain the slot value in the following intention, you can set it as follows:

TOC.ChatBotsitType = "Suite"

TOC.ChatBotResponse

This parameter returns all the content in the recognition interface. An example structure is as follows: {"intents":[{"simQuestions":[],"scenarioType":"normal","scenarioStatus":"finish","confidence":1.0,"responses":["Balance"] ,"priority":0,"params":{},"scenarioName": "Call fee query 2","commands":["21312","TEXT"]}],"statusCode":200}

To obtain similar questions, use TOC.ChatBotResponse.intents[0].simQuestions.