Zenaique

Flashcard: what is an AI agent?

Flashcard·Easy·4.0 · 0·~30s·Asked atBytedanceCoinbaseMercor·Relevant atLangChain
Attempt it
TL;DR

An agent is an LLM in a loop with tools: it observes, reasons, acts, reads results, and repeats until it produces a final answer or a stopping condition fires.

Memory aid
Sign in to see the mnemonic that makes this stick.
Easy to grasp

Imagine giving a very fast intern a goal, a phone, a calculator, and a notepad. The intern reads the goal, decides one next step, picks up a tool to do that step, writes down what they learned, and then looks at the notepad again to decide what to do next. They keep going until they have an answer or they run out of time. An AI agent works the same way. The language model is the intern doing the thinking. The runtime is the office around the intern: it actually picks up the phone, runs the calculator, writes things down on the notepad, and watches the clock. The two together, taking turns over and over, are what people mean when they say agent.

Concept explanation~2 min read

Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.

The word agent has been stretched so far in 2025 and 2026 marketing that it can mean almost anything. The technical core, though, is small and worth pinning down precisely. An AI agent is an LLM running inside a loop with tools, where the model itself decides what to do next on every turn.

This deep dive takes the one-sentence definition apart, names the parts that have to be present, and contrasts an agent against the two things people most often confuse it with: a one-shot chatbot completion and a hard-coded chain. By the end, the line between agent and not-agent should be crisp enough that you can apply it to any real system someone hands you.

The one-sentence definition, unpacked

An agent is an LLM-driven loop that observes the current state, reasons about the next step, takes an action by calling a tool or returning a final answer, reads the action's result back as a new observation, and repeats until a stopping condition fires.

Three ideas have to be present at the same time for the word agent to apply. First, there is a language model doing the deciding. The model is the part that picks the next move based on whatever has been accumulated so far. Second, there is a tool layer the model can reach. Tools let the agent act on the world beyond text generation: search the web, query a database, run code, send a message, click a button. Without tools, the model can think but cannot do anything outside its own response.

Third, there is a runtime that drives the loop. The runtime sits between the model and the tools. It receives the model's output, decides whether the model asked for a tool, executes that tool if so, packages the result as an observation, and feeds the observation back into the next model call. It also owns the stopping conditions and the budgets.

The whole point of the loop is that each turn is shaped by what happened on the previous turn. The agent is not following a fixed script. It is reacting to live information that did not exist when the task started.

The brain and body split
Agent versus one-shot completion versus fixed chain
Why the loop needs a stopping condition
Where agents fit in the 2026 stack
Sign in to unlock the full deep dive.

Situations where this technique stops working.

Sign in to see when this approach fails.

2–4 min · Everything important, quickly.

Sign in to see the quick scan of the deep dive.

Real products, models, and research that use this idea.

  • Anthropic's computer use feature: Claude Opus 4.7 decides the next click or keystroke, the harness takes the screenshot and executes the action, then loops the new screen back in.
  • Cursor and Cline coding agents: the model proposes an edit, the editor runtime applies the diff and runs tests, and the test output becomes the next observation.
Sign in to see more production examples.

What an interviewer would ask next. Try answering before peeking at the approach.

QIf the model only emits text, what actually invokes a tool and how does that result get back into the prompt?
A

Walk through the runtime parsing a structured tool-use block, executing the matching function with the given arguments, capturing the return value as an observation, and appending it to the conversation state before the next model call.

2 more follow-ups an interviewer would ask next. Sign in to reveal them.

Red flags & common mistakes

The phrases that signal junior thinking. Click to expand.

Most common mistake

Calling a single LLM completion an agent. A chatbot answer is not an agent; an agent requires a loop, tools, and a runtime that drives the loop until a stopping condition fires.

Sign in to see all red flags and common mistakes.

60 second bullets to scan on the way to the call.

  • Define an agent in one sentence using the observe, reason, act, repeat shape.

  • Name the three required pieces: model, tools, runtime.

Sign in to unlock the revision sheet.

Primary sources. Browse if you want the original framing.

Similar questions

Same topic, related formats. Practice these next.

4 curated
Next question
What is the Model Context Protocol (MCP) and what problem does it solve?
MCQ·Easy