Memuat
Memuat
Want to go deeper?
Join one of our courses or ask us directly on WhatsApp.
Picked from the software, topic, and level of “Agentic AI Without Coding Class #37: Designing an Auto-Reply Flow with Escalation to a Human”.
Other ways we can help with Agentic AI.
Learn with a mentor
Scheduled AI & Machine Learning courses with live guidance and a certificate.

MATLAB Agentic AI Course: Building Autonomous AI Agents with MATLAB & Simulink

Midjourney Course: Create Stunning AI Images from Text
★ 4.9

DALL-E Course: Creating Professional AI Images from Text
★ 4.9
Have it built for you
No time to learn Agentic AI? Our team can do the project for you.

MATLAB & Simulink Development — Agentic AI for Simulation Automation and Data Analysis

AI Image Creation with Stable Diffusion — Unlimited Custom Visual Production
★ 4.9

AI Image & Video Creation with Leonardo AI — All-in-One Visuals for Business
★ 4.9
Get notified about new Agentic AI classes
At most one email a week. Unfollow anytime with one click.
The full narration of this video. The current sentence is highlighted while the video plays; click any sentence to jump there.
Hi, and welcome back to Agentic AI Without Coding. In the last episode we chose our doors: learn on Telegram, then serve through official WhatsApp. Before that door opens to customers, let's design the ground rules first. When the bot answers on its own, when it has to hand the customer over to Dimas, and how Dimas gets notified.
A good design starts from real data, not guesses. Dimas copies the past week's chats into Google Sheets. Notice that only the day, the first name, and the message are written down, with no phone numbers or addresses. On Monday, Rina asks about the stock of the liter-size iced coffee, and Budi orders two cold brews. The stock question goes into the product info category. Budi's order goes into the order category. On Tuesday, Sari asks about a sugar-free hamper, product info again. Then Andi complains that the coffee spilled on the way and wants a replacement. That's a complaint. On Wednesday, Putri has transferred money, but the payment hasn't been confirmed. On Thursday, Joko wants to order forty cups for the office and asks about a discount. That's a special request. Then there's a question about Sunday opening hours, and Budi asking to talk directly to the admin. Now look at the handling column. Some are answered by the bot, some are answered by the bot and then logged, and some must be handed to Dimas. From just eight examples, the pattern is already starting to show. If Dimas counted a hundred chats in a week, about sixty of them would be product info: prices, stock, and opening hours. The answers are always in the data. About twenty are standard orders, which the agent can log as in Session 7. About twelve are complaints and payment matters. There aren't many, but the stakes are high. And about eight are special requests or customers who want to talk to a human. These are illustrative numbers, but the pattern in most businesses is similar: most questions repeat, and a small share needs a human touch. From there we set up five categories. First, product info like prices, stock, opening hours, and delivery fees. Handling: the bot answers directly from the data in Google Sheets. Second, standard orders, where the product and quantity are clear and the address is within the city. The bot answers and logs the order at the same time. Third, complaints: a damaged product, the wrong item, or a late delivery. The bot shows empathy, then hands over to Dimas. Fourth, payments: a transfer that hasn't been confirmed or a refund request. These go straight to Dimas, because they involve money. Fifth, special requests and customers who ask to talk to a human, for example large orders, discount requests, or the sentence I want to talk to the admin. These also go to Dimas.
So the agent can decide on its own, we give it four conditions. The first condition: the answer is in the business data, meaning the sheets for products, prices, stock, opening hours, and delivery fees. Second, the question doesn't involve money or special promises. Refunds, discounts, and exceptions to the rules aren't the bot's call. Third, a mistake would have small consequences. Getting the opening hours wrong is easy to correct. Wrongly promising compensation is not. Fourth, the customer hasn't asked for a human. If a customer says they want to talk to the admin, that request is always respected. And if any condition isn't met, or the bot is unsure, the rule is clear: don't guess, hand over to Dimas. Let's look at an example. Sari asks two things at once: is there a sugar-free hamper, and how much is delivery to Antapani. Both answers are in the data. The bot gives the hamper price, checks the stock, then explains the city delivery fee according to the policy, which is ten thousand rupiah. Sari goes on to order one hamper for delivery tomorrow. This is a standard order. Notice this good habit: before logging, the bot repeats the order details and the total, one hundred sixty thousand rupiah, then asks whether it's correct. That gives the customer a chance to make corrections. Only after Sari confirms does the agent log the order to the sheet. Every step here meets all four conditions, so there's no need to involve Dimas at all.
Now the other side. There are five escalation triggers, meaning conditions where the bot must hand the customer over to a human. The first trigger is a complaint: a damaged product, the wrong item, a late delivery, or a customer who sounds disappointed. Second, payment problems: a transfer that hasn't arrived, a customer who paid twice, or a refund request. The bot never decides money matters. Third, special requests, like an order of forty cups for the office, a discount request, or an exception to the rules. Fourth, the customer asks to talk to a human. The words can vary: I want the admin, is this a bot, or please connect me to a person. They all mean the same thing. Fifth, the answer isn't in the data, or the bot isn't sure. It's better to hand over to Dimas than to make up an answer. What does a good escalation look like to the customer? Andi writes that half of the coffee had spilled when it arrived, and that this is really disappointing. The bot doesn't reply with a flat sentence. It apologizes, acknowledges that this is disappointing, and then is honest: I'm an automated assistant, so I'm passing this case to Dimas, our admin. The bot gives an estimated time, within thirty minutes at the latest, and asks for a photo so Dimas can check right away. Notice what the bot doesn't do: it doesn't promise a replacement coffee or money back. That decision belongs to Dimas. The bot only makes sure the customer knows a human is handling the case. The next example. Joko asks: is this a bot? I'd rather talk to a person. The bot honestly says it's an automated assistant, then hands over to Dimas right away, without persuading Joko to stay with the bot. A summary of Joko's question is passed along too, so Joko doesn't have to start over. A few minutes later, Dimas replies personally and greets Joko by name. The switch from bot to human feels smooth.
Before we look at n8n, let's put in order what happens during an escalation. First, the agent recognizes that this message matches one of the five triggers. Second, the agent replies to the customer with empathy, honestly says that the admin will follow up, and gives an estimated time. A customer must never be left waiting without news. Third, the agent notifies Dimas with a notification that includes the category and a summary of the problem. Fourth, Dimas handles the case and replies from the same chat, so the customer doesn't need to switch numbers or apps. Fifth, the status in the log is updated to done by Dimas. These five steps make sure no customer falls through the gap between the bot and a human. Escalation is only useful if Dimas knows about it. Let's look at the design in n8n. The trigger is an incoming message from Telegram or WhatsApp, which we set up in Episodes 39 and 40. The AI Agent node is still the admin agent from Session 7, now with escalation rules added to its instructions. We already know the first tool: Google Sheets for products and orders. The second tool is the new one: Escalate to Dimas. Look at the panel on the right. The most important part is the tool description, because this sentence is how the agent knows when to use the tool: complaints, payments, special requests, or customers asking for a human. The message content is filled in by the agent itself. The category and summary fields have a special color because their values come from the agent's conclusions, not fixed text. The third tool, write log, records every escalation to the Conversation Log sheet. So no case is kept only in someone's memory. This is what Dimas receives. The notification is sent through a dedicated Telegram bot that only Dimas uses. It could also go to Dimas's personal WhatsApp, as long as Dimas reads it quickly. The first line states the category right away with a color marker: red for a complaint. Then the customer's name, the source channel, and a summary of the problem, including the time promise the bot already made. For Joko, the marker is yellow: a special request. Dimas knows right away which one to handle first. Dimas doesn't have to open the whole chat history. The summary is enough to act on right away. Every important conversation is also recorded in the Conversation Log sheet. The columns are: time, customer name, channel, category, summary, and status. Sari's order was handled fully by the bot. Andi's complaint is recorded with the status escalated. After sending a replacement, Dimas adds a note and changes the status to done by Dimas. Joko's request still has the status escalated, meaning it isn't resolved yet. And look at the last row: Putri reported a transfer problem at ten thirty at night, outside opening hours. The status is waiting for tomorrow. That brings us to the next topic, operating hours.
The bot can work twenty-four hours a day, but Dimas can't. For product info and prices, it makes no difference. During opening hours or at midnight, the bot still answers. Standard orders are logged at any time. The difference is that orders outside opening hours are only processed the next day at eight in the morning, and the bot has to say so. For cases that need a human, during opening hours Dimas gets a notification right away and replies within thirty minutes at the latest. Outside opening hours, the case is logged with the status waiting for tomorrow. And the most important thing is what the bot says. The time promise must be honest. Don't say the admin will reply right away at eleven at night if the reality is tomorrow morning. From that table, Sunset Coffee sets three time promises. First, the bot replies within seconds, in less than a minute, whenever a message comes in. Second, during opening hours, Dimas handles escalations within thirty minutes at the latest. Third, escalations that come in at night are answered the next day from eight in the morning. Write promises you can definitely keep, then measure in the log whether they're really met. Promises that often slip damage trust more than simple promises do. Now the opening message. Putri says hello at ten twenty-eight at night. The bot's first sentence is honest right away: I'm Sunset Coffee's automated assistant. Then it says what it can help with, and how to ask for the admin: type ADMIN at any time. The customer doesn't feel tricked, and knows the way out. Putri then raises a payment problem: a transfer of eighty-five thousand rupiah that hasn't been confirmed. This is about money, so escalation is required. Since it's already outside opening hours, the bot is honest that Dimas will only reply tomorrow from eight. The case is logged as waiting for tomorrow, exactly as we saw in the log earlier. We write all of those rules as extra instructions for the agent, using the block pattern you've known since Session 2. The role block: you are Sunset Coffee's automated customer service assistant, and always introduce yourself as an automated assistant. The context block holds the opening hours, the current time, and the admin's name. Notice the current time variable. In n8n its value is filled in automatically, so the agent knows whether the shop is open. The task block: answer product info and log standard orders from the Sheets data, and repeat the order details before logging. The limits block is the heart of escalation: for complaints, payments, special requests, asking for a human, or being unsure, use the Escalation tool. And never promise refunds, discounts, or replacements. Finally, the format block: at most three sentences, polite, greeting by name, and outside opening hours, saying that Dimas will reply tomorrow from eight.
Let's put it all together into one flow map. The first step: a message comes in from WhatsApp or Telegram. Second, on the first message, the bot greets honestly as an automated assistant and explains how to ask for the admin. Third, the bot recognizes the message category: product info, order, complaint, payment, or special request. Fourth, the bot decides: answer on its own if the four conditions are met, or escalate to Dimas, with a time promise that fits the opening hours. Fifth, important conversations are written to the log with their status and summary. This is the design we set up on Telegram in Episode 39, and then on official WhatsApp in Episode 40. Before setting it up, test the design on paper with hard messages. The first example: the coffee went bad, I want my money back now. The correct response: escalate it as a complaint, in a calm and empathetic tone. Second: can you deliver to Jakarta? Sunset Coffee's delivery data only covers the city. So the bot doesn't guess; it passes the question to Dimas. Third: are you a human or a robot? The answer is always honest: an automated assistant. Fourth: order two cups at eleven at night. The order is logged, and the bot says it will be processed tomorrow at eight. Now two wrong examples, marked with a red cross. The bot promises a ten percent discount so the customer won't be angry. This breaks the limits, because discounts are Dimas's decision. And a bot that stays silent when it doesn't know the answer. A customer who gets no reply is just as badly served as a customer who gets a made-up answer. If your design is still unclear on any of these examples, fix the rules before moving on. Before moving on, do these four tasks. First, take twenty real chats from your business and sort them into the five categories. Remember, first names and messages only. Second, decide who receives escalations in your business, and which app they read notifications on fastest. Third, write an honest opening message: say it's an automated assistant, what it can help with, and how to ask to talk to the admin. Fourth, write escalation instructions for your agent with the role, context, task, limits, and format block pattern. We use these instructions right away in Episode 39.
Let's recap. Map the message categories from real chats. The bot answers when the answer is in the data and the risk is small. Complaints, payments, special requests, and requests to talk to a human are handed to Dimas through an escalation notification and recorded in the log, with honest time promises that match the opening hours. In the next episode we discuss the ethics of agent communication with customers: being honest about the bot, not sending spam, protecting privacy, and not promising anything outside policy. See you in Episode 38.
Try these on your own after watching to lock in what you learned.
Type a question or keyword; we find the part of this episode that explains it and jump the video there.
Notes are saved with the current video time and are only visible to you.
Stuck on a step? Ask here; the instructor and other learners can answer.
No questions yet.

Cerdas Inovasi Digital Team
Software developers, BIM & 3D engineers, and AI practitioners
We build software, BIM models, games and AI automations for clients every day, and turn that hands-on work into step-by-step classes: every step is shown on screen and comes with a PDF guide you can keep.
See our clients →