Empty message read as intent affirm

When the user sends empty message the bot read it as intent affirm with confidence 0.93

Received user message ‘’ with intent ‘{‘name’: ‘affirm’, ‘confidence’: 0.934365451335907}’ and entities ‘[]’

any solution for this issue ? can i let the bot ask him to re-phrase ? or ignore it ?

Why not just prevent your front-end application from sending an empty message in the first place? :slight_smile:

That’s good answer, however i cant make it from frontend, so there is anyway i can prevent it from the backend ?

You can write a Custom Connector

i am not sure how thats going to solve the issue. can you elaborate more ?

Hi @xsamerx3,

Have you tried creating an intent with examples like the below?

- intent: blank_input
  examples: |
    - ' '
    - " "
    - """ """

You could afterwards create a custom action linked with this intent to check whether the user input is blank or contain only spaces.

When I faced a similar issue I was able to prevent the front-end application from sending an empty message, so I’m not quite sure that this will work…

Hello @v_kostis
i have tried this method however it doesn’t recognize empty quotes in yaml file in the example section.