Skip to content
Back to full roadmap
topicadvanced

Agentic Loop Architecture

while(!done) { think → act → observe → update_state } — backbone of modern agents.

5 hours1 resources1 prereqs

An agent ≠ single LLM call. There's a loop:

  1. Plan — break goal into steps
  2. Select tool — pick the right one
  3. Execute — run it
  4. Observe — interpret result
  5. Update — revise the plan
  6. Goal done? No → back to 1

Dangers:

  • Infinite loop → set max iterations
  • Complex tool chains → trace logging is mandatory
  • Bad tool output → retry + fallback

Prerequisites

Resources(1)