Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

Dialogflox cx conflict: "intents matching" and "parameters form" at the same page.

Hello everyone,

I found an unexpected behavior with the following page-level configuration.

  • Parameters:
    - Only 1 required parameter - intent_param
    - Custom entity type: Map entity - @intent
    Initial prompt fulfillment: " What do you want? 

  • @intent Entity type:
    - Disabled "Entities only"
    - Disabled "Regexp entities"
    - One entity: "Entity1" - Synonyms: "Value1"

  • Routes:
    - Various Intent routes that if matching with the input will transfer to other page.

  • Event handler:
    - sys.no-match-1 
    This event handler should show a Fulfillment message and Route to another page when none of the intents is matched.

CONFLICT: After the question "What do you want? ", if the user input is not clear there will not be any intent matching, but if the user include in the sentence the word "Value1" which is synonym of "Entity1", then the parameter "intent_param" (entity type "@intent") will be collected with value "Entity1". When this happens I was expecting "sys.no-match-1" to be activated, but this did not occurred and the page state status is "PROCESSING_FORM" (FormFilled: false).

Does anyone knows why this happens and if is there a way to avoid this behavior? In this situation I would like to continue the workflow with the  parameter collected and no intents matched.

Thank you,
Miguel.

0 3 965
3 REPLIES 3

Can you provide an example of Value1? It would also help if you provide the whole response for investigation purposes.

Hello, this would be an example for the previous explanation:

Entity type:
Entity1: Tarjetas
Synonyms: "Tarjetas", "Cartón", "Plástico"

Page (not start page):
- Agent Fulfillment: "What do you want?"
- Required/Not required Parameter: "intent_param" (I said required in the previous explanation, in both cases I can't achieve what I was expecting)
- Some intent Routes
- Event handler ("sys.no-match-1")

User input: "Plástico"

The behavior which I was expecting is that Agent tried to match any of the intents and:
1. If match, activates the corresponding intent route
2. If no-match, activates the "sys.no-match-1" event handler

And I also expected that simultaneously, if the input matches with the Entity/Synonym, the parameter was also collected and mapped with the corresponding entity.

Summarizing, is it possible to collect a parameter (map entity type) and try to match intents, with one unique user input at the same time?

Response for Required parameter (Parameter is collected but event handler is not activated):

{
  "advancedSettings": {
    "audioExportGcsDestination": {},
    "loggingSettings": {
      "enableInteractionLogging": true
    },
    "speechSettings": {
      "endpointerSensitivity": 90,
      "noSpeechTimeout": "5s"
    }
  },
  "currentPage": {
    "displayName": "Prueba params",
    "name": "projects/dev-bbva-dialogflow-poc/locations/us-central1/agents/57dc60ad-5e59-4913-9c5a-dcef53842159/flows/9aecdd7b-3a57-4342-aaf9-caf3f2c6a9f8/pages/5409aed3-7c85-47a8-aa87-2a84947d8b5d"
  },
  "diagnosticInfo": {
    "Alternative Matched Intents": [
      {
        "Score": 1,
        "Active": true,
        "Parameters": {
          "intent_param": {
            "resolved": "REDACTED",
            "original": "REDACTED",
            "type": "@resolve_intent"
          }
        },
        "Type": "NLU_SLOT"
      }
    ],
    "Transition Targets Chain": [],
    "Session Id": "19db1e-467-50c-8d4-69fdb3e1a",
    "Triggered Transition Names": [],
    "Execution Sequence": [
      {
        "Step 1": {
          "InitialState": {
            "SessionParameters": {
              "intent_param": "REDACTED"
            },
            "MatchedIntent": {
              "Active": true,
              "Parameters": {
                "intent_param": {
                  "resolved": "REDACTED",
                  "type": "@resolve_intent",
                  "original": "REDACTED"
                }
              },
              "Type": "NLU_SLOT",
              "Score": 1
            },
            "FlowState": {
              "Name": "Prueba params",
              "FlowId": "9aecdd7b-3a57-4342-aaf9-caf3f2c6a9f8",
              "Version": 0,
              "PageState": {
                "Name": "Prueba params",
                "ActiveParameter": "intent_param",
                "PageId": "5409aed3-7c85-47a8-aa87-2a84947d8b5d",
                "FormFilled": false,
                "Status": "PROCESSING_FORM"
              }
            }
          },
          "Type": "INITIAL_STATE"
        }
      },
      {
        "Step 2": {
          "StateMachine": {
            "FlowState": {
              "Name": "Prueba params",
              "Version": 0,
              "PageState": {
                "PageId": "5409aed3-7c85-47a8-aa87-2a84947d8b5d",
                "FormFilled": true,
                "Name": "Prueba params",
                "Status": "TRANSITION_ROUTING"
              },
              "FlowId": "9aecdd7b-3a57-4342-aaf9-caf3f2c6a9f8"
            }
          },
          "Type": "STATE_MACHINE"
        }
      }
    ]
  },
  "intentDetectionConfidence": 1,
  "languageCode": "es",
  "match": {
    "confidence": 1,
    "matchType": "PARAMETER_FILLING",
    "parameters": {
      "intent_param": "Tarjetas"
    },
    "parametersOriginalValues": {
      "intent_param": "Plástico"
    },
    "resolvedInput": "Plástico"
  },
  "parameters": {
    "intent_param": "Tarjetas"
  },
  "redactedParameters": [
    "intent_param"
  ],
  "responseMessages": [
    {
      "interactiveVoiceResponseSettings": {
        "audioExportGcsDestination": {},
        "speechSettings": {
          "endpointerSensitivity": 90,
          "noSpeechTimeout": "5s"
        }
      }
    }
  ],
  "text": "Plástico"
}

 Response for no roquired parameter (Event handler is activated, but no parameter is collected):

{
  "advancedSettings": {
    "audioExportGcsDestination": {},
    "loggingSettings": {
      "enableInteractionLogging": true
    },
    "speechSettings": {
      "endpointerSensitivity": 90,
      "noSpeechTimeout": "5s"
    }
  },
  "currentPage": {
    "displayName": "End Session",
    "name": "projects/dev-bbva-dialogflow-poc/locations/us-central1/agents/57dc60ad-5e59-4913-9c5a-dcef53842159/flows/9aecdd7b-3a57-4342-aaf9-caf3f2c6a9f8/pages/END_SESSION"
  },
  "diagnosticInfo": {
    "Execution Sequence": [
      {
        "Step 1": {
          "InitialState": {
            "Event": "sys.no-match-1",
            "FlowState": {
              "PageState": {
                "Name": "Prueba params",
                "Status": "TRANSITION_ROUTING",
                "PageId": "5409aed3-7c85-47a8-aa87-2a84947d8b5d",
                "FormFilled": true
              },
              "FlowId": "9aecdd7b-3a57-4342-aaf9-caf3f2c6a9f8",
              "Name": "Prueba params",
              "Version": 0
            }
          },
          "Type": "INITIAL_STATE"
        }
      },
      {
        "Step 2": {
          "Type": "STATE_MACHINE",
          "FunctionExecution": {
            "Responses": [
              {
                "responseType": "HANDLER_PROMPT",
                "text": {
                  "redactedText": [
                    "No se a qué te refieres exáctamente, pero tiene que ver con $session.params.intent_param"
                  ],
                  "text": [
                    "No se a qué te refieres exáctamente, pero tiene que ver con $session.params.intent_param"
                  ]
                },
                "source": "VIRTUAL_AGENT"
              }
            ]
          },
          "StateMachine": {
            "FlowState": {
              "Name": "Prueba params",
              "PageState": {
                "PageId": "5409aed3-7c85-47a8-aa87-2a84947d8b5d",
                "Name": "Prueba params",
                "FormFilled": true,
                "Status": "TRANSITION_ROUTING"
              },
              "Version": 0,
              "FlowId": "9aecdd7b-3a57-4342-aaf9-caf3f2c6a9f8"
            },
            "TriggeredEvent": "sys.no-match-1",
            "TriggeredEventHandlerId": "f6760455-fb9b-49fb-acae-69142ec33188"
          }
        }
      },
      {
        "Step 3": {
          "StateMachine": {
            "FlowState": {
              "FlowId": "9aecdd7b-3a57-4342-aaf9-caf3f2c6a9f8",
              "PageState": {
                "Name": "End Session",
                "PageId": "END_SESSION",
                "Status": "ENTERING_PAGE"
              },
              "Name": "Prueba params",
              "Version": 0
            }
          },
          "Type": "STATE_MACHINE"
        }
      }
    ],
    "Alternative Matched Intents": [],
    "Session Id": "946ef0-346-0ee-be7-ec290fb95",
    "Unfulfilled Parameters": [
      "$session.params.intent_param"
    ],
    "Transition Targets Chain": [
      {
        "TargetPage": "END_SESSION"
      }
    ],
    "Triggered Transition Names": [
      "f6760455-fb9b-49fb-acae-69142ec33188"
    ]
  },
  "intentDetectionConfidence": 0.3,
  "languageCode": "es",
  "match": {
    "confidence": 0.3,
    "event": "sys.no-match-1",
    "matchType": "NO_MATCH"
  },
  "responseMessages": [
    {
      "responseType": "HANDLER_PROMPT",
      "source": "VIRTUAL_AGENT",
      "text": {
        "redactedText": [
          "No se a qué te refieres exáctamente, pero tiene que ver con $session.params.intent_param"
        ],
        "text": [
          "No se a qué te refieres exáctamente, pero tiene que ver con $session.params.intent_param"
        ]
      }
    },
    {
      "interactiveVoiceResponseSettings": {
        "audioExportGcsDestination": {},
        "speechSettings": {
          "endpointerSensitivity": 90,
          "noSpeechTimeout": "5s"
        }
      }
    },
    {
      "endInteraction": {}
    }
  ],
  "text": "Plástico"
}

This seems to be not reproducible on my end. If you have premium support, you can check with GCP Support to further check your issue since this is specific to your project.