What is an AI Agent?
An agent is an LLM with the ability to plan actions, use tools, and remember context across steps. It solves complex tasks by breaking them into sub-tasks and choosing the right tool at each step.
Agent Core Loop
Loop continues until goal is reached or max steps exceeded
Key Agent Components
| Component | Role |
|---|---|
| Planner (LLM) | Reasons about which tool to use next given the goal and history |
| Tools | Python functions, APIs, databases, web browsers, code interpreters |
| Memory | Short-term (conversation), long-term (vector DB), episodic (past runs) |
| Executor | Runs the chosen tool and captures the output |
| Scratchpad | Stores intermediate reasoning and tool outputs |