My question is: how can I implement this decision-making within the flow? I tried using `Session.ActiveIntent` but the value is always empty
I'm sorry if this is a repeated question, but I'm having trouble piecing the flow together.
Original Message:
Sent: 09-22-2025 08:06
From: Lars Richter
Subject: Agent Escalation Phrases
Hello Ramsha,
the last input from "Ask for..." actions can be retrieved using the built-in variable Session.LastCollectionUtterance (Source: https://help.mypurecloud.com/articles/architect-default-variables/#tab11).
Best regards
------------------------------
Lars Richter
Solution Consultant
Original Message:
Sent: 09-22-2025 07:43
From: Ramsha Shaikh
Subject: Agent Escalation Phrases
Thank you for the explanation.
So, if I'm using intents, I need to call the Wait for Input action in order to match the user query against the intents.
However, with the Wait for Input task, all downstream processes are disabled because the end of the task is End Task.
Right now, we have a slot that accepts builtin:any for the user query and then performs subsequent operations. With Wait for Input, the task just ends, how can I store this query in a variable, since the query (which may not match an agent intent) still needs to be passed to our AI bot?
We are already using the Genesys built-in agent escalation intent, but it doesn't cover all variations of user's queries for escalation.
------------------------------
Ramsha Shaikh
Engineer, AI
Original Message:
Sent: 09-22-2025 04:57
From: Lars Richter
Subject: Agent Escalation Phrases
Hello Ramsha,
in Digital Bot Flows, each intent is linked to a specific task. For example, the AgentEscalation intent triggers the corresponding AgentEscalation task. When creating an intent, you can either associate it with a new task or connect it to an existing one.
Instead of the "Ask for intent" action, which is available in regular bot flows, Digital Bot Flows have the "Wait for input" action. The provided input is matched against the defined intents, and if a suitable intent is found, the associated task is called.
You could also use Genesys built-in agent escalation intent, which you can find in your (Digital) Bot Flow > Settings > Event Handling > Agent Escalation.
Here is the related resource article: https://help.mypurecloud.com/articles/agent-escalation-in-voice-and-digital-bot-flows/
------------------------------
Lars Richter
Solution Consultant
Original Message:
Sent: 09-22-2025 02:30
From: Ramsha Shaikh
Subject: Agent Escalation Phrases
Hi everyone,
As a continuation from my previous thread, we decided to give Genesys NLU another try for handling user requests to speak with a human.
Quick Context:
I'm working on a Genesys Digital Bot Flow where I need to skip the AI bot and route to an Agent Escalation Task whenever a user expresses a desire to speak with a human (e.g., "I need a live agent," "Talk to support").
Here's the setup and challenge:
I have an open-ended slot (builtin:any) in my task where the user types their query.
I've created a AgentEscalation intent in Genesys NLU with relevant utterances.
The goal is:
The problem:
In Digital Bot Flows, I don't see any option to directly connect a builtin:any slot to an intent.
I also don't see an "Ask for Intent" action or similar mechanism inside the Digital Bot Flow UI.
I'm finding it difficult to understand how to set up and attach my intent so that the bot can use it for routing.
------------------------------
Ramsha Shaikh
Engineer, AI
Original Message:
Sent: 09-11-2025 13:23
From: Cameron Tomlin
Subject: Agent Escalation Phrases
Hello Ramsha,
I want to address both your questions.
- You can use regex in architect by creating a custom regex slot type and here are the steps
- Go to NLU > Slots
- Click "Add Slot"
- Provide the name for the first slot
- Under the slot type, select "New ReGex"
- Create your regex pattern.
An example that you might want to consider is something like the below:
.*(agent|human|person|representative|support|help desk|speak|talk).*(agent|human|person|representative|support|help desk).*
This should match variations like "speak to agent", "talk to human", etc.
For your second question on how to better handle escalations I have a couple of ideas.
A. Built-in Escalation handler, I know we offer built in agent escalation detections systems that you can configure from the bot flow Settings>Event handling menu. This system can use pre-maintained escalation phrases, can be configured to either confirm escalation or bypass confirmations and sets the exit reason to "AgentRequestedByUser" when triggered.
B. Hybrid Approach, this uses regex and point A right above. This uses the built in escalation handler for common patterns, you will need to create a regex slot for custom patterns specific to your needs, and this maintains a small lost of high priority exact matches using Contains() for critical phrases.
Some best practices notes:
- Early Detection: Place the escalation check early in your flow to minimize unnecessary AI processing
- Maintenance Strategy:
- Keep a log of missed escalation attempts
- Regularly review and update your patterns based on actual user interactions
- Document all patterns and their purpose
- Testing:
- Create a comprehensive test set of various escalation phrases
- include negative test cases to ensure your not over-triggering
Hope this helps!
------------------------------
Cameron
Online Community Manager/Moderator
Original Message:
Sent: 09-11-2025 00:47
From: Ramsha Shaikh
Subject: Agent Escalation Phrases
Hi everyone,
We have an AI bot integrated in one of our Genesys flows and have already enabled agent escalation path handling. However, it doesn't cover all the queries that users type in, especially when phrasing varies.
The idea is that whenever a user explicitly asks for an agent (e.g., "talk to a real person"), we want that query to bypass the AI model completely and go down a different path straight to an agent.
Right now, we're handling this in Architect with a long chain of Contains() checks, like:
This approach works for exact strings but:
It's hard to maintain as the list grows.
It misses variations in phrasing (e.g., "speak to human" vs. "connect me to an agent").
We've tried using NLU intents for escalation before but didn't have a great experience (accuracy issues and false matches created poor user experience). Because of that, we decided to use string matching.
1. How can I use regex or pattern-based matching directly in Architect instead of "contains"? I tried exploring expressions but didn't find what I was looking for.
2. Is there a better way to handle escalation phrases so they reliably go to a different path without going through the AI model?
Any guidance, best practices, or examples would be greatly appreciated!
Thanks!
#ArchitectureandDesign
------------------------------
Ramsha Shaikh
Engineer, AI
------------------------------