there are four types of agent loops. most people only know one.
loop engineering is a choice between four structures, each handing off one more job than the last.
every one answers two questions: what starts a run, and what ends it.
hand-run, you answer both yourself, every time.
1) turn-based
→ you prompt, it acts, you review, you prompt again. both jobs stay with you.
use when requirements are still forming.
2) goal-based
→ "/goal hit Lighthouse 90, stop after 5 tries." an evaluator checks, a no sends it back.
use when the outcome is measurable but the path isn't.
3) time-based
→ a clock fires, it runs "check the PR, fix CI," then waits. /loop local, /schedule survives a closed laptop.
use for recurring work.
4) proactive
→ no human present. it watches a channel, spawns triage, fix, and a reviewer, closes the task itself.
use for standing duties you can't predict.
not which one is most advanced.
whether your task is exploratory, measurable, recurring, or standing.
the more you hand off, the less you babysit.
full breakdown in the article below.智能体循环(agent loops)共有四种类型,但大多数人只知道一种。
循环工程是在四种结构之间做选择,每一种结构比上一种能分担更多的工作。
每种循环都要回答两个问题:什么触发运行,什么结束运行。
手动运行:每次都由你自己回答这两个问题。
1) 基于轮次(turn-based)
→ 你提示,它执行,你审查,然后再提示。这两项工作都由你承担。
适用于需求尚在形成阶段的场景。
2) 基于目标(goal-based)
→ “/goal 达到 Lighthouse 90 分,尝试 5 次后停止。”由评估器进行检查,若不合格则重新尝试。
适用于结果可衡量但路径不明确的场景。
3) 基于时间(time-based)
→ 时钟触发,运行“检查 PR,修复 CI”,然后等待。/loop local 和 /schedule 指令即使在电脑合盖后依然有效。
适用于周期性工作。
4) 主动式(proactive)
→ 无需人工干预。它监控频道,自动分流、修复、审查,并自行关闭任务。
适用于无法预测的常态化职责。
关键不在于哪种最先进。
而在于你的任务是探索性、可衡量、周期性还是常态化的。
你分担出去的工作越多,需要亲自照看的时间就越少。
完整解析请见下文。
引用
Hanako
@hanakoxbt
How to Build the Loops That Just Replaced Entire Prompt Engineering 如何构建那些刚刚取代了整个提示词工程的循环
For two years, getting more out of an AI agent meant writing a better prompt.
That era is quietly ending. The best engineers in the world stopped writing prompts a while ago and started writing loops...两年来,想要从 AI 智能体中获得更多产出,意味着要写出更好的提示词。
那个时代正在悄然终结。世界上最顶尖的工程师们早就停止了单纯编写提示词,转而开始编写循环……








