CORE GUIDE

MENTAL_MODELINTERMEDIATE7 min read

Loop versus graph

Use an agent loop when one controller can own iteration and state; introduce a graph only when explicit branches, joins, specialized responsibilities or independent recovery boundaries create measurable value.

Mental model

A loop repeats decision and action inside one control boundary. A graph makes multiple control boundaries explicit and defines how state, ownership and evidence move between nodes. Graph structure should follow dependency structure, not architectural fashion.

Why it matters

Multi-agent and workflow frameworks make graphs easy to draw, but every node and edge adds coordination, state and recovery cost. The loop-versus-graph decision is therefore upstream of delegation. Choosing the simpler structure when dependencies do not require a graph improves reliability and makes later failures easier to attribute.

01

Choose structure from dependency and control needs

Start with a single bounded loop. Move to a graph only when the task contains work that must branch, run independently, join with verification, use different state scopes or recover separately. For every added node, define owner, input/output contract, retry scope and completion evidence, then compare the result with the simpler loop baseline.

02

Example: one research task becomes five agents too early

A team splits a linear research workflow into planner, searcher, summarizer, critic and coordinator agents. Each stage waits for the previous one, so the graph adds handoffs without parallelism or independent recovery. Returning to a single loop with explicit phases is cheaper and easier to debug; graph nodes are added later only for truly parallel evidence collection.

Common failure modes

  • Using multiple nodes to represent labels rather than independent control boundaries.
  • Adding a coordinator when the workflow is still strictly sequential.
  • Comparing graphs only with other graphs instead of a simpler loop baseline.

Engineering heuristics

  • Start with a bounded loop and require evidence before adding graph structure.
  • Add nodes where state, recovery or parallel dependencies genuinely differ.
  • Define contracts and retry scope for every graph boundary.

Takeaways

  1. 01A graph is justified by control boundaries, not by role count.
  2. 02Loop is the simpler default for tightly coupled iterative work.
  3. 03Topology should earn its coordination cost against a baseline.

Reading evidence

UnseenPractice not completed

This records actions you actually took; it does not claim mastery, proficiency, or certification.

Used in

This Concept is reused across these canonical learning paths.

Related concepts from the Knowledge Graph

These relationships come from the canonical graph, not a separate Guide taxonomy.