CxPerium uses three different methods to understand user messages and route them to the appropriate dialogue. The operation of these methods and their configuration settings are detailed below:
1. Matching with Regex
When a user sends a message, CxPerium first checks if it matches any Regex expressions defined in the Dialogue screen.
- Matching: If the message conforms to a Regex expression, it is directed to the relevant dialogue. This allows the dialogue to progress based on predefined rules and templates.
- Definition: It is recommended to define Regex rules that match the most frequently sent user messages.
2. Google Dialogflow Integration
If the message does not match any Regex expressions, CxPerium checks the DialogFlowConfig setting in the Assistant > Configuration screen.
- Activation Condition: If
IsEnabled:true
is set in the configuration screen, the message is sent to Google Dialogflow. - Purpose: Google Dialogflow analyzes the meaning of the message and either generates an appropriate response or returns a suggested action to CxPerium.
- Configuration: To work with Dialogflow, CxPerium must be configured with DialogFlow API keys and project details.
3. ChatGPT Integration
If the message neither matches any Regex expressions nor receives an appropriate response from Google Dialogflow, CxPerium checks the ChatGPTConfig setting in the Assistant > Configuration screen.
- Activation Condition: If
IsEnabled:true
is set in the configuration screen, the message is sent to ChatGPT. - Purpose: ChatGPT directly analyzes the message using an AI-powered natural language processing model and generates a unique response for the user.
- Configuration: To integrate with ChatGPT, API keys, model selection, and other parameters must be correctly defined.
Summary Flow
- Regex Matching: If the message matches Regex rules, it is directed to the relevant dialogue.
- Google Dialogflow: If there is no Regex match and
DialogFlowConfig IsEnabled:true
, the message is sent to Dialogflow. - ChatGPT: If no appropriate response is received from Dialogflow and
ChatGPTConfig IsEnabled:true
, the message is sent to ChatGPT.
This structure ensures that messages are processed through multiple control mechanisms and handled using the most appropriate method.