Perceive, Then Reason and Plan
Asha types: "Get me to Jaipur for Priya's wedding, cheapest option, I can't leave before Thursday evening." Before Tripmate can act, it has to take that sentence in, together with everything else it knows, and turn it into a next move. Those are the first two stages of every agent loop.
The rule
Perceive everything relevant, then decide the single next step.
Perception is how input reaches the model. In an agent it is more than the user's latest message. Each turn, the program assembles:
- the user input — text, and sometimes images, files or voice turned into text,
- the state so far — earlier turns, tool results, notes from memory,
- the environment — today's date, the user's time zone, what tools exist.
Anything the program leaves out, the model cannot perceive. "Thursday evening" means nothing unless the model also knows what today's date is. Perception also means leaving things out: pasting a whole 40-page timetable into every turn buries the few lines that matter, so good agents choose what to show.
Reasoning and planning is the model working out what to do with that picture. For Tripmate it might go:
Goal: arrive in Jaipur before the wedding, cheapest fare.
Known: can leave Thursday after 6 pm. Wedding date: unknown.
Plan: 1) ask or look up the wedding date 2) search trains Thu night–Fri
3) compare fares 4) propose the cheapest that arrives in time
Next step: look up the wedding date in Asha's calendar.A plan is useful, but it is a draft. The loop only commits to the next step; after seeing the result, the model can revise the rest.
The shortcut
At each turn, run a quick three-question check: "What is the goal? What is still unknown? Which one action shrinks the unknown most?" That action is the next step.
Name the goal
Reach Jaipur in time for the wedding, at the lowest fare, leaving Thursday evening or later.
A common mistake is planning too far ahead in detail. If the calendar shows the wedding is on Sunday, a rigid plan built for Friday is wasted. Plan roughly, act on the next step, and replan with new facts.
Drills
Answer fast — trust the rule.
Asha says "leave tomorrow", but Tripmate books the wrong day. What perception gap is most likely?
In the agent loop, what does the reason-and-plan stage produce?
Which is part of an agent's perception on a given turn?
The calendar shows the wedding moved to Sunday. What should Tripmate do with its plan?
Remember
- Perceive everything relevant — input, history, and context like the date — then decide one next step.
- Shortcut: goal, unknowns, the one action that shrinks the unknowns most.
- Trap: rigid, detailed plans that ignore what each step reveals.
