DictionaryAgents
Agentic Loop
The repeat cycle of think, act, check the result, and think again that an AI agent runs until it finishes.
Definition
The cycle that drives an agent: the model receives the prompt, system prompt, tool definitions, and history; responds with text, tool calls, or both; the harness runs the tools and feeds the results back; and the cycle repeats until the model replies with no tool calls. In the Claude Agent SDK each round trip is a turn, and max_turns or max_budget_usd can cap the loop.
Example
Turn 1 runs npm test (3 failures), turn 2 reads auth.ts, turn 3 edits and reruns tests, then a text-only reply ends the loop.