Back to Blog
Production AIPart 5 of 5AI AgentsAutomation

Automation Follows Rules. Agents Decide What Happens Next.

A helmet detector can tell you whether someone is wearing a helmet. An agentic workflow decides what to do about it.

PPratik Khanapurkar· Co-founderAugust 24, 20269 min read
Rules
automation follows fixed paths with predictable outcomes
Context
agents interpret, choose tools and verify results
Both
most real workflows need automation and agents together

A camera sees a motorcyclist. A computer-vision model detects a person, a motorcycle and no helmet. What happens next?

If the answer is always helmet=false → send alert, you have automation. Useful automation — but still automation.

Now suppose the system has to decide whether the detection is reliable, whether the person is actually riding the bike, whether enforcement rules apply, whether the plate is readable and whether a human should review the evidence.

That is starting to look like an agentic workflow.

Agents are not just chatbots with better branding

The word “agent” is attached to almost everything involving an LLM. A chatbot is called an agent. A classifier is called an agent. A prompt connected to an automation tool becomes an agent.

A more useful distinction is about control over the workflow. Automation executes a predefined path. An agent can choose which path to take based on the current state.

Traditional automation is still excellent

Suppose a lead submits a form:

Form submittedAdd lead to CRMSend emailNotify salesperson

Every step is known in advance. Perfect. Do not replace it with an AI agent.

Now change the input. A lead writes:

“We’re a chain of 17 dental clinics across three cities. We want automated appointment recovery, but our branches do not use the same booking process. Can you integrate?”

There is no single obvious branch. The system may need to extract requirements, identify missing information, inspect CRM documentation, decide which questions to ask and route the opportunity to the right solution.

Now reasoning has somewhere useful to operate.

Observation and inference must stay separate

Observation: detector confidence for a helmet is 0.34.

Inference: the rider is probably not wearing a helmet.

Further inference: a traffic violation may have occurred.

Action: issue a penalty.

Why the distinction matters
A statistical output can turn into a real-world consequence in only a few steps. Good agentic systems preserve what was observed, what was retrieved, what was inferred and what still needs confirmation.

The agent loop

ObserveInterpretDecideUse toolObserve resultRepeat or stop

That loop is the core pattern. The agent observes the current state, chooses an action, receives the result and decides what happens next until it reaches a goal, hits a limit or escalates to a human.

Return to the helmet camera

  1. The vision system flags a possible no-helmet event.
  2. The workflow checks confidence.
  3. If confidence is low, it sends the case for human review.
  4. If confidence is high, it checks an additional frame.
  5. It extracts the number plate.
  6. It validates whether the plate is readable.
  7. It checks whether the event already exists.
  8. It packages the evidence.
  9. Only an allowed downstream action is executed.

The model did not replace the detector. It orchestrated the workflow around it.

The best agent often contains very little AI

A production agent should not “think creatively” about every step. Deterministic software should handle deterministic things.

  • Validation should be code.
  • Authentication should be code.
  • Database constraints should be code.
  • Payment limits should be code.
  • Permission checks should be code.
  • AI should be used where interpretation, ambiguity or flexible decision-making is actually required.
The model should decide. The software should enforce.

When should you actually build an agent?

The strongest use cases tend to combine messy inputs with variable paths:

  • Customer support where requests arrive in natural language.
  • Operations where exceptions constantly break rigid workflows.
  • Research requiring information from multiple sources.
  • Sales qualification where different leads require different questions.
  • Document-heavy processes where context determines the next action.

Automation is not being replaced

Agents sit above automation. A good agent calls reliable automated tools: book appointment, search database, send WhatsApp message, create invoice, retrieve customer, generate report.

Each action should be boring and predictable. The intelligence belongs in deciding which action should happen, in what order, using what information and when to stop.

The future is deterministic software doing what deterministic software does best, with reasoning systems handling the messy spaces between the rules.

References & further reading

Build with DestinPQ

Production AI should survive the real world.

We design AI agents, integrations and full-stack products around real business constraints: reliability, observability, safety, cost and maintainability.

Talk to DestinPQ →
All posts