Artificial Intelligence Technology

Why Do We Need Agents? — Agentic AI Series Part 1/4

Why Do We Need Agents? 

The notion of “agents” or “agentic AI” is a recent development in artificial intelligence that significantly enhances the power and robustness of Large Language Models (LLMs) applications.

To understand why the need for Agents arose, we first need to understand the differences between traditional programming and AI-driven programming. This comparison will highlight the shortcomings of current AI processes and explain how agents are designed to address these issues.

Traditional Software Development

Traditional software development, which was the norm before the recent rise of generative AI, relies on humans providing explicit instructions to computers to dictate how tasks should be executed. These instructions are rigid, following a predefined sequence of steps, often referred to as algorithms. The flow of a traditional program can be structured as follows:

For instance, starting from point A, depending on various input values, the algorithm may move to point B, C, or D, as shown in the diagram. The algorithm follows a fixed set of paths, resulting in predictable and well-defined outcomes.

AI-Driven Software Development

AI-driven software development involves usage of generative AI models to perform tasks. Unlike traditional methods, these systems do not rely on explicit instructions or a fixed sequence of steps for every scenario. Instead, they operate based on a description of the task and leverage past data and patterns to transform inputs, make decisions, and generate predictions. An example of flow of an AI application is illustrated below:

As the diagram shows, AI-driven systems have no fixed paths. Within a certain boundary, they can produce any output from the possible options, such as A, B, C, or D.

Differences Between Traditional & AI-Driven Software Development

AI-driven software development differs from traditional software development primarily in that its aspects — inputs, transformations, and outputs — are fuzzy, meaning flexible and not well-defined. While traditional programming is deterministic, with predictable results, AI-driven approaches yield probabilistic results, allowing for variability and adaptation.

In traditional programming, inputs and outputs are precisely defined by their quantity, size, and data types (e.g., text, integer, float). In contrast, AI-based software can handle input in various formats such as plain text, markdown, and tabular data, and produce outputs in varying formats such as bullet-point lists, JSON, and markdown.

Similarly, transformations in traditional programs typically involve mathematical computations, string operations, conditional logic, and iterative processes. AI software, however, performs transformations such as keywords extraction, ideas generation, and summarisation.

Fuzzy inputs, transformations, outputs

Traditional Software DevelopmentAI Software Development
Inputs– text (string) with defined set (“happy”, “calm”)
– Numerics (int ,float)
Fuzzy inputs: Open-ended text
– Tabular data
– Markdown
– Text
– Math operation
Transformations– Maths calculations (+ – ➗ x)
f“Hello {first_name}, how are you?”
if, elif, else
for/while loops
Fuzzy transformations:
– Extract list of key words
– Rewrite as a paragraph
– Answer a question
– Brainstorm new ideas
– Perform logic/maths reasoning
Outputs– text (string) with defined set (“Positive”, “Neutral”)
– Numerics (int ,float)
Fuzzy outputs: text
– Paragraphs
– Number(s)
– JSON
– Markdown
Notes– Can be replicated– Probabilistic: can be different every time

Limitations Of Traditional Programming

Traditional programming faces some challenges that makes it less suitable for every scenario such as:

  • Need for Definitive Steps: Requires detailed and explicit instructions for every scenario.
  • Limited Adaptability: Struggles with varying types of inputs and scenarios.
  • Deep Problem Understanding: Necessitates a thorough understanding of the problem to define appropriate steps.

These problems call for a more flexible approach, which AI-driven software development provides, by not requiring explicit step-by-step definitions.Instead, AI software leverages patterns and data to adapt and perform tasks more flexibly and efficiently.

Limitations of AI Softwares

AI based software themselves are not without limitations. They often produce results that may not meet expectations or be in the desired format. Issues often arise with ambiguous inputs or contexts that differ from what the model was trained on.

While the probabilistic nature of AI allows for flexibility and adaptation — enabling a single LLM model to perform a range of tasks such as content summarisation, code writing, brainstorming, and teaching — this same variability can lead to unpredictable results.

To obtain the desired output from AI software like ChatGPT, iterative prompting is often required. For instance, if you ask the AI to “write briefly about the history of United States,” it may initially provide a detailed essay. You might then prompt it to summarise the information into bullet points, but the result could still be too lengthy for your liking. This iterative process continues until you achieve the desired result. This approach requires human intervention and presence, but ideally, we would want as little human involvement as possible in an AI-based system — here’s where agents come in.

Role Of AI Agents

To address the above challenges, AI agents are introduced. Simply put, AI agents replace the human in the iterative prompting cycle with an autonomous reasoning system. This system continuously works to refine the output until it meets the desired criteria. An AI agent takes an input, processes it through the LLM, evaluates the output, and if it’s not satisfactory, repeats the process until the output aligns with the requirements. This approach minimises the need for human intervention, making the AI-based system more efficient and effective.

Conclusion: Why do we need AI Agents?

AI agents enhance traditional AI-based software by addressing issues such as unpredictability, unreliability, fuzziness, and the need for iterative adjustments, while also reducing human involvement. They offer the following key advantages:

  • Predictability: Agents produce results that are more consistent and aligned with the desired outcomes.
  • Reflection: Agents can evaluate and adjust their results as needed to improve performance.
  • Collaboration: Agentic systems can involve multiple agents with distinct roles working together to achieve better results.

In the next part of our Agentic AI Series, we’ll dive into the practical aspects of creating these agents. Stay tuned as we explore the step-by-step process of designing and implementing AI agents to enhance your applications.