The anatomy of an AI agent: model, loop, tools, memory
An AI agent is a language model wrapped in a loop that plans, calls tools and iterates toward a goal across many steps. Five components make one up. A model that picks the next action, a harness that runs the loop, tools that reach outside the model, memory that carries state, and a trajectory, the record of the whole run. Originally published at overmindlab.ai . An agent has a model, loop, tools…
An AI agent is composed of five key components: a model, a harness, tools, memory, and a trajectory. The model is the language model that selects the next action based on the current goal and state. The harness runs the loop of reason, act, observe, and repeat. Tools allow the agent to interact with external systems, such as databases, APIs, or code execution.
Memory enables the agent to persist and retrieve state across loop iterations. The trajectory is the record of the entire agent run, consisting of the goal, all LLM calls, tool invocations, observations, and the final outcome.
Originally, most AI products in 2024 were basic chatbots, relying on a single LLM inference call with a prompt and completion. However, in 2026, the default architecture is expected to be an AI agent, which plans, calls tools, and iterates toward a goal across multiple steps. In contrast to chatbots, AI agents can plan, act, observe, and repeat, leading to more complex and dynamic outcomes.
The five components of an AI agent can be assembled or fine-tuned independently, but the trajectory, produced by the other four components, represents the complete record of a single agent run. This trajectory provides a valuable analysis tool for evaluating the agent's success and guiding future improvements.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.