Tools vs Agents: Choosing the Right Abstraction
Understand when to use a simple tool, a single agent, or a multi-agent system.
The Three Levels of AI Interaction
Prompt — a single LLM call. Fast, cheap, stateless. Right for: classification, extraction, generation, summarization.
Tool-augmented prompt — an LLM call that can invoke external functions. Right for: tasks requiring real-time data, computation, or external API calls.
Agent — a persistent, goal-directed system with memory, planning, and multiple tool calls. Right for: multi-step tasks, tasks requiring adaptation, long-running work.
The Cost of Choosing Wrong
Choosing an agent when a prompt suffices: unnecessary complexity, higher latency, higher cost, harder debugging.
Choosing a prompt when an agent is needed: brittle single-shot solutions that break on edge cases, require constant human intervention.
Decision Framework
Ask these questions:
- Can this be done in one LLM call? → Use a prompt
- Does it need real-time data or computation? → Add tools
- Does it require multiple steps with dependencies? → Use a single agent
- Do the steps benefit from parallel execution or specialization? → Use multi-agent
The Minimal Agent
The smallest useful agent has: a system prompt (role + behavior), one or two tools (file read, web search), and a loop (observe → reason → act → repeat).
Start minimal. Add capabilities only when the minimal version fails.
Anti-Pattern: Over-Engineering
The most common agent mistake is building a complex multi-agent system before proving a single agent can solve the core problem. Build the simplest thing that could work, then scale up based on real failure modes.