Skip to main content

foreach

Apply ONE operation to EVERY item of a list — the **map** (N→N). The operation is a prompt; items come from a JSON list, a markdown checklist, or another run's output. Runs in parallel subagents or inline in the main thread, with persistent state and cross-turn auto-continue. USE on any "do the same thing to each of these" intent — formal OR casual: "for each X…", "per ogni…", "go through these one by one", "do every item in TODO.md", "review each of these files", "handle all of them", a glob, a folder. Trigger on the INTENT, then judge by count (the count gate, Step 2.5): - 1–2 items → just do it inline, no machinery; - a borderline handful (~3–10) → ask whether to use the durable/parallel mechanism or handle inline; - genuinely many, or heavy/independent items → use foreach. DON'T use when the list must first be generated from a spec (→ /agentflow:enumerate, then foreach), or you need one combined output (→ /agentflow:reduce). For the prebuilt "review every file → digest", use /agentflow:audit. Explicit

跳到安装

来源信息

仓库
AleSaiani/agentflow
最近来源活动
2026年5月27日 05:23
检测到的 SKILL.md 语言
英语
星标
5
分支
0

安装方式

默认使用会先检查来源的 Prompt;你也可以切换为直接命令,或下载本地副本。

检查来源文件

决定是否安装前,请先阅读 SKILL.md,以及 SkillsMP 当前展示的配套文件。