Chatbot how to escalate an event at a qualified moment in a chatbot conversation?

Hey team

Working with the latest self hosted docker n8n with the template below

Chat with OpenAI Assistant (by adding a memory)

Work case:
we have it currently setup as a basic lead generation flow for a plumber, qualify with progressive information capture in a conversation flow.

Conversation journey configured from Google assistant

  1. Problem, 2) contact details, 3) detail confirmation and 4) confirmation. 5) direct CTA for immediate contact via twilio phone number if required

Question:
How can you setup a trigger in the workflow to monitor critical moments in the conversation to discard unqualified, escalate to live chat or complete the conversation to push to another workflow to submit to the CRM/lead alert etc.

Looking for a more complete example of best practices

Dwayne

It looks like your topic is missing some important information. Could you provide the following if applicable.

  • n8n version:
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app):
  • Operating system:

Approached it like this, using an IF statement and having the openai assistant instructed to use a very specific phrase when summarising the enquiry and closing out the conversation.

I feel there should be better way of approaching this