scripod.com

How to design AI agent loops: schedules, goals, and subagents in Claude Code and Codex

How I AI

Jun 17
How I AI

How I AI

Jun 17

Shownote

I break down every loop type from scratch—what a heartbeat, cron, hook, and goal loop actually are, when each one fits, and the five things any effective loop needs before it touches production. Then I build two live loops: a daily aging-PR reviewer in Cla...

Highlights

This episode explores the shift from manual prompting to automated AI agent loops, breaking down how to design and implement them for recurring tasks. The host explains the core concepts and then demonstrates two live builds, showing how these loops can autonomously manage workflows like code review and skills identification.
00:00
Prompts are outdated, loops are the new trend
02:30
A loop is a way to prompt an AI agent.
03:03
These loops automate prompting so agents can work autonomously.
06:04
Five components for effective AI agent loops
09:26
Designing AI loops is like onboarding an employee.
14:54
The loop runs at 10:15 AM, checks for PRs open over 12 hours
17:08
Autonomous subagents babysit PRs until merge checks pass
19:00
Loop-based prompting can schedule teams to work iteratively until completion.
22:57
A weekly loop spawns sub-agents to validate new skills.
27:00
Goal-based loops require very precise prompting.
27:31
Use agents with schedules or goals and leave them to work autonomously

Chapters

Prompts are out and loops are in
00:00
Defining a loop
02:30
The four ways to automate a prompt: heartbeat, cron, hooks, and goals
03:03
Five things every effective loop needs
06:03
The “onboarding an employee” framework for designing loops
09:26
Live build #1: Daily aging PR loop in Claude Code
11:58
Subagents inside loops
17:08
Live build #2: Weekly skills identification loop in Codex
19:00
Watching subagents spin up in real time
22:57
Warning signals around loops
25:28
What listeners are doing with loops
27:31

Transcript

Claire Vo: prompts are out and loops are in. If your agent isn't able to prompt itself through an automation, what are you even doing? In today's episode, I'm going to teach you what a prompt is in normal person speak, how to write one, when it's useful, a...