Gen Z
Chapter 6 • 9 min read • Last reviewed: June 2026

Agentic AI & Reasoning

For the first few years of the LLM boom, AI models were treated as passive chatbots: you write a prompt, and the model instantly outputs a response. Today, the frontier has shifted toward Agentic AI. Instead of answering statically, agentic systems act as autonomous software entities that can plan, use external tools, inspect their own output, and run in loops to solve multi-step problems.

Tool Use & Function Calling

LLMs are notoriously bad at precise math (like multiplying two 8-digit numbers) and cannot fetch live data or interact with the physical world because they are just word-prediction engines.

Tool Use (or Function Calling) overcomes this limitation by letting the host application expose specific capabilities. The model is provided with a list of available tools, described in plain text. For example:

Available Tool: calculate_weather(location, date)
- Returns the temperature forecast for a location.

If the user asks: "Should I wear a coat in Chicago tomorrow?", the LLM recognizes it cannot answer from memory. Instead of guessing, it outputs a structured instruction:

{
  "call": "calculate_weather",
  "arguments": { "location": "Chicago", "date": "tomorrow" }
}

The host application intercepts this JSON, runs the actual weather API, receives the result (e.g., "Chicago: 41°F, Rain"), and appends it to the model's chat history. The LLM reads the result and finishes its response: "Yes, you should wear a coat. Chicago will be 41°F and raining tomorrow."

Reasoning Loops: ReAct and Reflection

To solve complex tasks, agents use structured loops rather than generating answers in a single pass.

1. The ReAct (Reason + Act) Loop

ReAct forces the model to document its thinking before taking actions. The loop proceeds as follows:

2. Reflection and Self-Correction

If a model writes a block of code, it may contain a bug. A reflection agent doesn't send the code to the user immediately. Instead, it runs the code in an isolated environment, catches any error logs, feeds those errors back to itself, and rewrites the code to fix the bug. This cyclic feedback loop dramatically boosts task success rates.

What Makes an Agent Safe Enough to Ship

An agent is more than a prompt with tools. The product around it needs boundaries:

The model can decide which tool to request, but the application must decide whether that request is allowed. Instructions are not access control.

System 1 vs. System 2 Thinking in AI

System 1 Prompt Ans one forward pass System 2 agent loop Plan Act Observe repeat until the task is done

Cognitive psychologist Daniel Kahneman famously split human thinking into two modes:

  • System 1 (Fast): Fast, intuitive, automatic actions (e.g., answering "2+2=?", reading a familiar road sign).
  • System 2 (Slow): Slow, deliberate, logical reasoning (e.g., solving "17 × 24", filling out a tax form).

Standard LLMs operate mostly like System 1. They output the next token immediately without much opportunity to plan, test, or revise. If they start a sentence poorly, they cannot truly rewind the generation path.

Modern System 2 Reasoning Models spend extra inference-time compute before producing a final answer. Current reasoning systems point toward the same design shift: models are being trained and served to plan, use tools, check intermediate work, and keep going across longer workflows. Some expose controllable reasoning effort; others keep the reasoning internal while returning a concise answer.

Sources