💡 Concept Anchor · Prompt Engineering
AI AGENT = Give it a GOAL and it PLANS, ACTS, OBSERVES, and LOOPS until done
AI agents — LLMs that take actions in the world
O
Observe — assessing the current state
The agent first observes the current state of its task or environment, establishing what's currently true before deciding what to do next.
Example: an agent checking the current status of a multi-step task it's working on, before deciding what action to take next.
P
Plan — deciding the next action
Based on its observation, the agent plans what it should do next to make progress toward its overall goal.
Example: an agent planning to search for specific information it's currently missing, based on its observation that this information gap is blocking further progress.
A
Act — calling a tool
The agent acts by actually calling a tool — this could be web search, code execution, file access, or an API call — to carry out its planned action.
Example: an agent calling a web search tool to actually retrieve the specific information it planned to look up.
R
Repeat — looping until the goal is achieved
The agent observes the results of its action, then repeats this observe-plan-act cycle as many times as needed until its overall goal is achieved. Unlike a simple chatbot that just responds once, an agent works autonomously across many steps toward a goal, using the ReAct (Reason + Act) framework as the standard approach.
Example: an agent repeating this full cycle multiple times — observing, planning, acting, observing again — to complete a multi-step task like booking a flight, writing and running code, or browsing the web for research.
1
A user gives an agent the goal of researching a topic, writing a summary, and saving it to a file.
2
The agent observes that it currently has no relevant information, plans to search the web for that information, and acts by calling a web search tool.
3
It observes the search results, plans its next step (perhaps writing the summary based on what it found), and acts by generating that summary text.
4
It continues this observe-plan-act cycle, eventually acting to save the file, repeating the loop until the entire multi-step goal is fully achieved — unlike a simple chatbot, which would have just produced a single response without this autonomous multi-step action sequence.

Exams test whether you understand the agent's core observe-plan-act-repeat loop and how this fundamentally differs from a simple chatbot's single-turn response behavior, and whether you know ReAct as the standard framework implementing this pattern.

The most common trap is confusing an agent with a simple chatbot. A chatbot just responds to a single message; an agent works autonomously across MULTIPLE steps toward a goal, actually taking real-world actions (via tools) and repeating an observe-plan-act cycle until that goal is achieved — a fundamentally different, more autonomous mode of operation.

1. What does an agent do during the "observe" step?
Assesses the current state of its task or environment.
Tap to reveal / hide
2. What does an agent do during the "plan" step?
Decides what action to take next, based on its observation.
Tap to reveal / hide
3. What does an agent do during the "act" step?
Actually calls a tool (web search, code execution, file access, API) to carry out its planned action.
Tap to reveal / hide
4. How does an agent differ fundamentally from a simple chatbot?
An agent works autonomously across multiple steps toward a goal, taking real-world actions, rather than just producing a single response.
Tap to reveal / hide
5. What is the standard framework implementing this agent loop?
ReAct (Reason + Act).
Tap to reveal / hide