Agentic Loops: Self-Prompting AI Workflows and How They Work

2 min read
agent-looporchestrationmulti-agentclaude-code
View as Markdown
Originally from youtube.com
View source

My notes

Summary

“Loops” (loop engineering) is an agentic workflow where, instead of prompting a chatbot back and forth, you set one goal once and let agents self-prompt through discovery, plan, parallel execution, verification, and iterate, with memory kept in files outside the conversation. The video demos a 3-agent loop (builder, scout, growth) plus an orchestrator running on a weekly cadence to grow an e-commerce store automatically.

Key Insight

The loop architecture (the actual pattern)

  • Goal set once by human, then discovery, planning, parallel execution, then a verification agent checks “did we hit the goal?”, then ship or iterate, then an optional “what next?” step.
  • Memory lives in files outside the conversation (e.g. /outputs/next_steps) so agents know what’s done and can resume across cycles. This is the load-bearing piece - without it, loops can’t iterate coherently.
  • An orchestrator agent owns the goal, spawns sub-agents (each runs its own discovery loop), then synthesizes their outputs into one unified action plan.

Open vs closed loops (the cost trade-off)

  • Open loop: broad mandate (“find what we should do, then do it”). Discovers things you wouldn’t think of, but burns massive tokens - it keeps going in any direction and never naturally stops. Only sane if budget is unlimited.
  • Closed loop (recommended): bounded goal, visible path, explicit evaluation at each step, which keeps spend constrained. Use this by default.

Loop conditions are explicit, not vibes

  • Each agent gets a concrete stop/continue rule, e.g. a scout that loops until 3+ fresh ideas are found that haven’t been acted on, or a study loop that asks “are there 2+ genuinely new developments this week? if not, dig deeper.”
  • Anti-repetition is built in: agents read the last N cycles (e.g. past 3 weeks of briefings, prior social captions) and flag diminishing returns in a notes file.

Concrete worked example - pickleball store (3 agents)

  • Agent 1 builder: one-shot a self-contained HTML personality quiz (Harry Potter x pickleball, email capture before result reveal) as a BuzzFeed-style shareable lead magnet.
  • Agent 2 scout: research Reddit, forums, competitor sites, YouTube, and search trends; score each opportunity on audience size, purchase intent, content gap, and quiz/lead-magnet potential; output a ranked top-8 with angle, source, and format.
  • Agent 3 growth: site link-placement audit (exact location, exact copy, and why), launch email, 3 platform-native social captions, next-lead-magnet recommendation; logs repetition warnings.

Honest limitation called out

  • Agents are weak at judgment-heavy calls (e.g. which YouTube topic will actually perform). Treat output as a strong second opinion or shortlist, then apply your own critical thinking - don’t outsource taste.

Practical notes

  • Requires a Claude Pro (or higher) or Codex subscription to use Claude Code.
  • On Claude Code desktop, an orchestrator spawns sub-agents inside the one chat (works fine but invisible); running each agent in its own tab is just for visibility and learning.