You know what OpenClaw is. But how does it actually work? How does it go from "find me the cheapest flight to Tokyo" to actually searching airlines and comparing prices?
Today you'll learn the agent loop — the four-step cycle that runs every time your agent takes action.
Quick Recall
What does OpenClaw do differently than a chatbot?
A
It connects to real tools and takes action — not just generates text
B
It generates longer, more detailed responses with better formatting
C
It remembers previous conversations without needing to be reminded
OpenClaw connects to your real tools — email, calendar, code, files — and takes action. That's the fundamental difference from a chatbot.
The agent loop
Every time you give OpenClaw a task, it runs through a cycle with four steps:
1. Observe — Read the request. Gather context. What does the user want?
2. Think — Plan the approach. What tools do I need? What order? What could go wrong?
3. Act — Execute the plan. Call the tools. Do the work.
4. Report — Tell the user what happened. Show the results. Ask if anything else is needed.
This loop runs continuously. If the first action reveals new information, the agent loops back to Think and adjusts its plan. It's not a one-shot process — it's iterative.
How an AI agent processes every request — a continuous loop that adapts as new information appears.
Knowledge Check
What are the four steps of the agent loop?
A
Listen, Plan, Delegate, Summarize
B
Receive, Analyze, Execute, Confirm
C
Input, Process, Output, Repeat
D
Observe, Think, Act, Report
Observe → Think → Act → Report. The agent reads the request, plans its approach, executes, and reports back. If something changes, it loops again.
Let's see the loop in action. You ask OpenClaw: "Find me the cheapest direct flight to Tokyo next month."
Here's what happens inside the agent's head:
🦞
OpenClaw 🦞
online
Find me the cheapest direct flight to Tokyo next month.
🔍 Searching flights...
Found your best options:
✈️ **Best price: $487** — United, Mar 15, departs 11:20am
✈️ $512 — ANA, Mar 18, departs 1:45pm
✈️ $539 — JAL, Mar 12, departs 10:00am
All direct from SFO (your home airport from memory). Prices are round-trip.
Want me to book the $487 United flight?
↻ Replay conversation
What happened behind the scenes
That simple exchange triggered the full agent loop:
Observe: "User wants cheapest direct flight to Tokyo, next month. I know from memory their home airport is SFO."
Think: "I need the flight search tool. Parameters: origin SFO, destination TYO, dates March 1-31, direct only, sort by price."
Act: Calls the flight search tool. Gets back 14 results. Filters to direct flights only. Sorts by price. Picks the top 3.
Report: Presents the options clearly. Offers to take the next action (booking).
The whole thing took seconds. And the agent was ready to loop again — if you said "book it," it would Observe that new instruction, Think about how to book, Act by calling the booking tool, and Report the confirmation.
Knowledge Check
In the flight example, when did the agent use your home airport without you mentioning it?
A
During the Act step — the flight search tool auto-detected your location via IP address
B
During the Think step — it inferred the most likely airport from your timezone
C
During the Observe step — it pulled the home airport from memory without being told
During the Observe step, the agent gathered context — including your preferences stored in memory. You never mentioned SFO. The agent remembered it from a previous conversation.
Why the loop matters
This loop is what separates a real agent from a fancy chatbot with plugins.
A chatbot with a plugin can call one tool and return the result. But it can't adapt. If the first result isn't right, or if new information changes the plan, the chatbot is stuck.
An agent loops. It adjusts. It tries a different approach. If the flight search tool returns an error, the agent doesn't just say "sorry, I couldn't find flights." It thinks: "That tool failed. Let me try a different search provider." And it does.
Knowledge Check
What happens if a tool fails during the Act step?
A
The agent loops back to Think and adjusts its plan based on the new information
B
The agent retries the same tool up to three times before reporting failure
C
The agent logs the error and skips to the Report step with a partial result
D
The agent pauses and asks you which alternative tool to try next
The loop is iterative. When something fails, the agent doesn't give up — it goes back to the Think step, considers alternatives, and tries again. That's the power of the agent loop.
Final Check
Why is the agent loop "iterative" rather than "one-shot"?
A
Because it processes each tool call separately, running the full cycle once per tool
B
Because the agent breaks complex tasks into smaller subtasks, each with their own loop
C
Because each step generates multiple options that need to be evaluated before proceeding
D
Because the agent can loop back to earlier steps when new information changes the plan
The agent continuously loops through Observe → Think → Act → Report. If new information appears (a tool fails, results are unexpected, the user adds context), it adapts its plan. It's not a rigid pipeline — it's a flexible cycle.
★
Your opinion matters!
How would you rate this lesson?
Not my thingLoved it!
What could be better?
✨
Thanks for your feedback!
It helps us make better lessons.
🧠
Day 3 Complete
"Observe, Think, Act, Report — then loop again. That's how your agent reasons through any task."
Tomorrow — Day 4
Tools — The Agent's Hands
Discover what "tools" are and why they're the secret ingredient that makes agents useful.