An AI agent is a software system that combines a large language model (LLM) with tools and a decision loop. It perceives a situation, reasons about the best course of action, acts, and reassesses — often across multiple steps.
Unlike a chatbot that responds to single messages, an agent:
- Maintains memory across a session or longer
- Uses tools (APIs, databases, search, code execution)
- Makes multi-step decisions to reach a goal
- Can run autonomously or with human oversight
The defining trait is judgment: an agent handles ambiguous inputs that rule-based automation cannot parse — like a vague maintenance request at midnight where urgency is buried in uncertain language.
AI agent vs. automation
| Automation | AI Agent | |
|---|---|---|
| Logic | Predefined rules | Reasoning at runtime |
| Input | Structured, predictable | Messy, natural language |
| Scope | Single step | Multi-step sequences |
| Failure mode | Wrong branch | Can reassess and retry |
When to use an AI agent
Agents earn their place when the work involves interpretation, context, and judgment — not just routing. Common examples include customer support triage, research synthesis, code generation with execution, and operations workflows where every case looks slightly different.
Related reading
For a full walkthrough with a concrete example, see What Is an AI Agent? A Builder's Guide.