Scripts, RPA, AI agents: three tiers of automation, three different uses
Your company already automates — with scripts, Excel macros or RPA bots. But when faced with tasks that require judgment (sorting an ambiguous email, qualifying a prospect, analyzing an unstructured document), these tools reach their limits. AI agents add a third tier: they understand context, reason, and choose the right action. The trap would be to bet everything on a single tool. The right approach combines all three according to the complexity of each process.
The problem
SMBs and mid-market companies have been investing in automation for years, but keep running into three recurring walls:
Scripts break silently
A Python script or a VBA macro does the job — until a file format changes, a column is renamed or an edge case appears. The script fails without warning, the data goes into the wrong pipeline, and nobody notices until a customer complains. In a mid-market company of 200 people, we observe on average 12 incidents per month related to unsupervised automation scripts.
RPA is fragile and costly to maintain
RPA bots (UiPath, Automation Anywhere) automate clicks on graphical interfaces. But as soon as a screen changes — an ERP update, a new web portal design — the bot stops. On average, 30% of the RPA budget goes to maintaining existing bots, not creating new ones. The ROI promises melt away once you include this hidden cost.
Judgment-based tasks stay manual
Neither scripts nor RPA handle cases that require interpretation: classifying an ambiguous complaint email, extracting an amount from a free-form invoice, deciding whether a prospect is qualified. These "in-between" tasks tie up skilled employees for repetitive, low-value work. This is where the productivity reservoir is largest.
The AI solution
The winning approach is a three-tier model where each type of tool covers its zone of strength. Here is how to distribute your processes:
Tier 1 — Scripts for the deterministic
Keep your scripts for everything that is predictable and high-throughput: data transformations, calculations, database synchronization, ETL. Add monitoring (alerts on errors) and automated tests. Cost: near zero. Reliability: 99.9% if well tested. You do not need AI to move a column from a CSV to a SQL database.
Tier 2 — RPA for systems without an API
Use RPA only when there is no API and the process is stable: data entry into a legacy ERP, extraction from a supplier portal with a fixed interface, copying between two applications that do not talk to each other. Limit the scope to limit maintenance. A well-targeted RPA bot remains a useful and cost-effective tool.
Tier 3 — AI agent for judgment
Deploy an AI agent for tasks that require understanding, reasoning or adaptation: sorting and replying to emails, qualifying prospects, extracting data from varied documents, summarizing reports. The agent understands the intent, chooses its tools (API, database, web search) and adapts to format variations without human intervention.
Implementation
To move from traditional automation to a three-tier model, follow this gradual roadmap:
Map and classify your processes (weeks 1-2)
List all automated processes or candidates for automation. For each, assess three criteria: variability (does the input format change often?), judgment (does it require interpreting, classifying, deciding?) and volume (how many executions per day?). Place each process in one of the three tiers. In practice, 60% stay in scripts, 15% in RPA and 25% benefit from moving to an AI agent.
Pilot a first AI agent on a high-impact process (weeks 3-6)
Choose a tier-3 process with sufficient volume and visible business impact: email sorting, lead qualification, invoice extraction. Develop an AI agent with an agentic framework (LangChain, CrewAI, or a custom architecture). Start in copilot mode: the agent proposes, the human validates. Measure the time saved and the accuracy rate over 100 executions.
Industrialize and extend (weeks 7-12)
Once the pilot is validated (accuracy > 90%, time saved > 50%), move to autonomous mode with supervision: the agent runs on its own, a dashboard flags uncertain cases. Extend to the other tier-3 processes. Connect the agent to existing RPA bots for data entry actions in legacy systems. Put in place unified monitoring that covers all three tiers.
Results
Frequently asked questions
What is the difference between an AI agent and an RPA bot?
An RPA bot executes a predefined sequence of actions on graphical interfaces — clicking, copy-pasting, data entry. It does not understand what it is doing and breaks as soon as a button moves. An AI agent understands an intent expressed in natural language, reasons over the data, chooses its tools and adapts to variations. RPA is ideal for stable, repetitive processes; the AI agent for tasks that require judgment or flexibility.
Can RPA and AI agents be combined?
Yes, and it is often the best approach. The AI agent handles the decision part (understanding an email, qualifying a request, choosing the right processing) and triggers an RPA bot for data entry into a legacy system without an API. This combines the flexibility of AI with the reliability of RPA for mechanical actions.
Can an AI agent replace all my automation scripts?
No. Scripts remain the best choice for deterministic, high-throughput processing: calculations, data transformations, ETL. An AI agent is oversized and too costly for these tasks. Reserve AI agents for processes that require understanding, reasoning or adaptation to context.
What is the cost of an AI agent compared to an RPA bot?
An RPA bot costs on average EUR 5,000 to 15,000 per year in licensing, plus maintenance. An AI agent based on an LLM API costs between EUR 50 and 500 per month in tokens depending on volume, with no licensing cost. The real differentiator is maintenance: an RPA bot breaks regularly (30% of total cost in maintenance), whereas an AI agent automatically adapts to minor changes.
For technical profiles
Detailed comparison table: Scripts vs RPA vs AI agents
| Criterion | Scripts (Python, SQL) | RPA (UiPath, AA) | AI agent (LLM) |
|---|---|---|---|
| Structured data | Excellent | Good | Good |
| Unstructured data | No | No | Excellent |
| Resilience to UI changes | N/A (no UI) | Fragile | Robust |
| Judgment / interpretation | None | None | Yes |
| Cost per execution | ~EUR 0 | EUR 0.05-0.20 | EUR 0.01-0.50 |
| Annual maintenance cost | Low | 30% of budget | Low |
| Throughput (executions/h) | 10,000+ | 50-200 | 100-1,000 |
| Development time | Variable | 2-4 weeks | 1-3 weeks |