Full transcript of “[EXPLAINED🍄] AI Agents vs. Workflows”. Click a timestamp to open the video at that moment. Need another video? Use the YouTube transcript generator.
0:00 Why are AI agents so much more powerful than workflow automations? In this video, I'm going to explain the difference with a reallive example that I use for customer support in my business, Blot. You're going to visually see the difference between building workflow automations to handle the same set of use cases versus building an AI agent that can handle multiple flexible use cases. You're going to learn the power of AI agents, why everybody's super excited about them, and then I'm going to close the video with a discussion of the challenges to broader adoption of AI agents. For decades, the norm has been creating multi-step workflows to stitch together APIs and automate tasks like this in make.com. In enterprise, this is called robotic process automation or RPA. In SMB, this
0:45 is called workflow automation with popular tools like Zapier, Make, Naden, and Pipere. But building and maintaining hard-coded workflows, it's slow, brittle, and involves a lot of repetitive code and logic to handle dozens of possibilities and edge cases. In this example here, I'm going to walk through in more detail. You can already see three different branches of logic depending on the use case. AI agents, in contrast, let me show you in N8N. This is my Stripe AI agent we're going to be diving to in a bit. AI agents let you hook up tools once and then simply tell your agent what you wanted to do in plain English. And then the agent dynamically plans which actions to take in what order and even recovers from
1:31 errors without manually hard- coding every single edge case. So understanding that leap from the old way of doing things over here with hardcoded branches for every single scenario to the new way of doing things with AI agents is really important if you want faster, more flexible, more powerful AI automation. So let's dive into a real example. For my AI app, Blot, I use a support tool called Intercom, which also has a workflow builder, which I hate, by the way. It's very clunky and ends up looking like a mess like this. So this is a workflow to handle questions related to billing. So the flow I'm going to talk about today is the refund workflow here in orange. So what happens though is a customer is like oh I have questions with billing. Okay. Then they
2:16 see these options. Let's say they select I accidentally upgraded during my free trial. So now this will go to this path over here. This explains what's included in the free trial. people like don't read sometimes and they don't realize there's explanations like certain features are just not included in the free trial which is totally normal um but they'll click things anyway there's a confirmation popup they'll click it anyway and then they'll email me like oh why was I charged okay so I want an automated way to handle that so here the customer sees this message just explaining like what's included not included and then they have the option I still want a refund I want to stay but it's expensive which will actually just apply a promo code to their account. They have the option to message me, the founder, and they have the option to
3:02 say, "Oh, okay, cool. All good. Thanks." So, now let's talk about the refund flow. So, let's say they choose, "I still want a refund." Then it goes up here to this refund request. And this looks complicated, but most of it is just like messages. So, first the AI agent says, "Okay, give me a moment. I'm processing your request." And then we call my Stripe AI agent in N8N. And the neat thing about this, if you open it up here, is all I have to do is type what I want in natural language and the AI agent will figure out how to use its set of tools to accomplish this task. The key takeaway here when I open my Stripe AI agent node is that to cancel a subscription in Stripe and refund a last charge, all it took was this one step, one call to my N8N Stripe AI agent. But
3:48 in the old way of doing things, just this piece of logic, cancelling a subscription and refunding the last charge would involve multiple steps in your workflow automation. So here's how it would really look. For example, if you were building this out in make or some other workflow builder. So to cancel a customer subscription, that's this middle row over here. First, we get information about the customer. Our support tool intercom would call this web hook and pass the customer ID. Then for all possible branches, we likely need to retrieve that customer's information. So this calls the get customer endpoint in Stripe. And then depending on what you want to do next, you'll have like different filters and rules depending on which path to take. So to cancel the subscription and refund the charge, that would be this flow here
4:34 in the middle. First, you'd grab the customer subscription ID, which you get from this step. Then you would make a custom HTTP call to the Stripe API to cancel the subscription because it's not a pre-built action. Then to refund the last charge, you would get a list of the customers charges. Then you would call the refund endpoint. Then you would call chatgpt to summarize the changes made. And then you would send that summary back to the web hook in my support tool. And that's just one possible workflow. Now let's say you want to handle the case where a user wants to apply a promotion code. you need to build another workflow automation or add branching logic to this current workflow. So this top row over here is to apply promotion code. We take the stripe subscription ID from the get customer step. Then we apply promotion
5:20 code to their subscription. Then chatbt again summarizes the changes and sends the summary back to the web hook. And then a third use case is to cancel a customer's expired or incomplete subscription in Stripe, then restart their free trial. This happens sometimes when like somebody cancelled but then they restart later and Stripe treats it as incomplete or expired. So the first thing to do is to find that incomplete or expired subscription. Here I'd just have a code step to do it otherwise it's it's kind of painful to do it in make.com. And then I'd cancel the subscription. I'd recreate their new subscription and then again an AI summary and send the summary back to the web hook. And again, you could build these three distinct workflows within one mega workflow like I'm showing here with branching logic or keep each item
6:07 in a separate workflow. But the Stripe API is extensive. These are just three things you can do with it. But there are so many more combinations of actions you can take. What if you want to cancel a subscription, refund them, put them on a higher tier subscription, and apply a promo code? So, one of the weaknesses of traditional workflow automations is that you or your developer team, they have to hardcode each workflow path and handle edge cases manually. Now, here's how it looks in my AI agent that handles all three of these use cases. Okay, this is my Stripe AI agent. It has a web hook just like my previous one. And the cool thing here is you build this AI agent has the prompt here for what it's supposed to do. Your helpful AI agent, you have access to the following tools.
6:52 Here are some sample stripe object IDs just so it knows like the formats and then its task is to analyze the request. So it can be any request that uses any combination of these tools and then the AI agent formulates a plan to complete the request and then here is the request that I'm passing in. It follows the plan and summarizes its actions and final changes in second person voice. All you have to do to set this up is attach the tools that you want the AI agent to have access to. So here I'm going to give it access to 04 mini because I want a reasoning model for important use cases like this. This is the API call to get a customer. This is the API call to get customers last stripe charges. This is the API call to cancel a subscription.
7:38 API call to get a subscription. API call to refund the charge. And API call to apply the promo. Once your AI agent has access to these tools, it can perform any combination of actions that use these tools. So instead of having to like hardcode each path like this, apply promo, cancel and refund, find the incomplete subscription, cancel it, and then recreate the subscription. In contrast, the AI agent, you just hook up the tools once, and it can handle all three of those use cases, plus additional use cases that can be done with this set of tools. So now if you go back to our workflow builder in intercom, what that looks like is this. So for cancelling the subscription and refund, all I have to tell my AI agent is cancel subscription and refund last charge. Like that's it. That's the only
8:25 instruction that we're giving the AI agent. Now let's say we want to apply discount. So here this is the message sent to the customer and then this is a call to our AI agent. So let's open it up. And this is the only instruction I give it. apply this particular promotion code to their active subscription. So in natural language, it's able to just understand what that means and perform the action. And here in N8, if you open up executions, you can actually see previous runs of your AI agent. So I opened up one from yesterday, May 9th, and then I'm going to zoom into the Stripe AI agent over here. Click go ahead and click on that to open it up. Click logs on the right hand side and you can see the exact steps that the AI agent took to handle this request. You can see over here the requested action
9:11 was to cancel the subscription and refund the last charge. So first the AI agent retrieved that customer subscription. Then you know it thought about it. This is the AI and tool log so you can debug things. Then it decided to cancel the subscription by calling this endpoint. Then it got the charges for the customer and then it refunded the charge. But basically after hooking up the tools for the AI agent, each distinct API call is now a tool and the AI agent can dynamically analyze the task at hand, plan what to do next, decide which tools to use, for example, which API calls to make and how to orchestrate everything together in a reasonable sequence to accomplish the task. Once it's done planning, it goes ahead and executes each action and then reflects on the result of each action.
9:58 Like, did something fail? Should I try again with the same thing or try something different? And then it moves on to the next action until it completes the task. For example, if you give the AI agent instruction to apply the promo code, it's going to use only the tools that are relevant for that task. It won't call the API to refund the charge since it's irrelevant to that task. And the key point here is that I did not have to hardcode all of these steps, right? If you look at our make scenario corresponds to this middle row like each step is pretty much laid out for that path. But in NAN the AI agent just figured out what to do like it decided these are the steps that makes the most sense to take. And that's the key point. The AI agent dynamically decides what to
10:44 do given a task and a set of tools. I didn't have to manually stitch together all those multi-step workflows and branching paths and edge cases. Now, here's what the last step looks like to the customer. Output a summary of what it's done. Here's the summary. It's returned to my support tool intercom, which then forwards it to the customer. This is the actual message that is seen by the customer after the AI agent is done processing their request. And again, this is not hard-coded at all. Like the AI agent just using chat wrote this summary based on reflecting on the actions it took. So if we go back to our AI agent, let's open up the prompt again. You can see the third task assigned is simply to summarize the actions. And you can easily imagine that
11:29 that summary will look a little bit different depending on what the request is. Whether it's applying a promotion code an incomplete subscription or cancelling and refunding an active subscription. In terms of best practices for building AI agents, you'll hear the term guard rails often in relation to LLMs. This is due to the probabilistic nature of LLMs, which means that running the same prompt or agentic flow a 100 times can yield different results. And the purpose of guard rails is to tell your AI agent like only do these actions or always ask a human before proceeding with a high-risisk decision. That way, your agent won't run wild or make very expensive mistakes. One way I kind of have guard rails is that I'm still
12:14 controlling what message is passed to the AI agent. It's not like the customer can just type anything and then it's passed to the AI agent. I just type it here. Cancel, expired, or incomplete subscription. And that's because this is a really highsensitive use case that deals with billing and subscription. You can imagine a less sensitive use case where the customer just interacts with the AI agent and can say whatever they want, make any requests they want. your guardrails will look a little bit different there. To wrap up, I'm going to talk about the challenges in production. So, overall, I believe it's still very early days for AI agents in production. There really aren't many companies outside of Fang and big tech and the top startups that have deployed AI agents successfully in production at scale. Some of the key challenges slowing down broader adoption of AI
13:01 agents is number one, the probabilistic nature of LLMs is very different from the software we've been writing for decades and decades. All of our systems are built around deterministic software, meaning software that produces the same result every time. Whereas with LLMs, you can have wildly different results when you run the same prompt or a gentic flow 100 times. And so guard rails are really important. test cases and what's called LLM operations is really important and an emerging field. Another issue in production is cost and performance. So every single API call adds latency. So it slows down the time until the customer, for example, gets an answer and it increases the cost. So traditional workflows can be much more
13:46 predictable from a cost perspective at scale. probably the biggest issue. We're talking about an AI agent that has access to critical tools in your business. And so, how do you ensure that the AI agent doesn't do something it's not supposed to do? Make sure your AI agent has secure credentials. Enforce the concept of least privilege. If it doesn't need access to certain endpoints, for example, writing or updating data, then make sure it doesn't have it. And the last challenge is around interoperability. And this is where MCP or model context protocol comes in. You can think of MCP like a universal interface that enables AI agents to connect securely and efficiently to many many many different services without writing custom connectors for each service. Overall, I'm quite bullish on AI agents, but
14:33 there are very real world challenges that are kind of slowing down its broader adoption. But I hope with the example we walk through today, it's much clearer now the power of AI agents. And you hook up tools once and then simply tell your agent what to do in natural language. And then the AI agent dynamically decides what actions to take in what sequence and can even handle edge cases and recover from errors. In the Stripe example we talked about, we only hooked up tools related to Stripe, but imagine you have other systems, other business systems. You need the AI agent to interact with, for example, Stripe and HubSpot and some other marketing platform and your newsletter platform. You can imagine an AI agent equipped with a variety of tools from
15:21 different service and then deciding, okay, I'm going to update HubSpot right now. I'm going to update Stripe over here instead of having to build like all of those paths manually. The more services you have, the more API endpoints there are, the higher the number of combinations of actions there. Hope this video is helpful. Hit like, hit subscribe, and drop a comment below. would love to hear from you.