dream
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
Chinesedream — Overnight Batch Execution
dream — 夜间批量执行
Runtime syntax: invoke the plugin copy through the active runtime's owner-qualified skill selector; use a bare selector only when intentionally selecting a user-tier copy (a separately installed personal copy; Genie no longer seeds this tier). Cross-skill prose below uses bare names as portable semantic routes; the orchestrator resolves the selector for the active runtime.
Pick SHIP-ready wishes, build a dependency-ordered plan, dispatch one worker subagent per wish, review PRs, merge to dev, run the QA loop, and write a wake-up report. The dream orchestrator dispatches — it never executes wish work directly.
This is a high-impact, explicit-only workflow. The user must approve the selected wishes, the generated plan, PR creation, and merge-to- authority. Never merge to or , deploy, send external messages, or expand scope without separate authority.
devmainmaster运行时语法: 通过活跃运行时的所有者限定skill选择器调用插件副本;仅当有意选择用户层级副本(单独安装的个人副本;Genie不再默认生成该层级)时,才使用裸选择器。以下跨skill说明使用裸名称作为可移植语义路径;编排器会为活跃运行时解析选择器。
筛选已就绪(SHIP-ready)的wish,构建按依赖排序的计划,为每个wish调度一个工作子Agent(worker subagent),审核PR,合并至dev分支,运行QA循环,并生成一份醒后报告。dream编排器仅负责调度——从不直接执行wish相关工作。
这是一个高影响力、需明确授权的工作流。用户必须批准所选wish、生成的计划、PR创建以及合并至分支的权限。未经单独授权,绝不能合并至或分支、部署、发送外部消息或扩大范围。
devmainmasterWhen to Use
适用场景
- Human wants to queue multiple wishes for autonomous overnight execution
- Multiple WISH.md files have persisted status
APPROVED
- 人类希望将多个wish排入队列,由系统自主在夜间执行
- 多个WISH.md文件的状态持续为
APPROVED
Flow
流程
- Pick wishes (Picker below); human confirms the selection.
- Generate — dependency-ordered plan; human may edit before the run.
.genie/DREAM.md - Phase 1 — Execute: dispatch workers layer by layer, collect outcomes.
- Phase 2 — Review + PR: review every PR, fix valid gaps, CI green.
- Phase 3 — Merge + QA: merge to dev in order, QA loop until criteria proven.
- Phase 4 — Report: write , the wake-up artifact.
.genie/DREAM-REPORT.md
- 筛选wish(下方为筛选器逻辑);人工确认所选内容。
- 生成—— 按依赖排序的计划;执行前人工可编辑。
.genie/DREAM.md - 阶段1 — 执行: 逐层调度工作Agent,收集执行结果。
- 阶段2 — 审核 + PR: 审核每一个PR,修复有效问题,确保CI通过。
- 阶段3 — 合并 + QA: 按顺序合并至dev分支,运行QA循环直至满足验证标准。
- 阶段4 — 生成报告: 写入,作为醒后查看的成果文件。
.genie/DREAM-REPORT.md
Picker
筛选器
- Read and select only wishes whose Status field is exactly
.genie/wishes/*/WISH.md. The brainstorm jar is historical/discovery context, never readiness authority. A Poured entry without an existing approved WISH.md is skipped and reported as drift. No matches → printAPPROVEDand stop.No APPROVED wishes found under .genie/wishes/ - List matches numbered by slug: .
1. <slug> — <one-line description> - Human picks by number () or
1 3 5.all
- 读取,仅选择Status字段恰好为
.genie/wishes/*/WISH.md的wish。头脑风暴记录仅作为历史/探索上下文,不能作为就绪依据。若存在已记录但未生成已批准WISH.md的条目,将跳过并报告为偏差。若无匹配项 → 输出APPROVED并终止流程。No APPROVED wishes found under .genie/wishes/ - 按slug编号列出匹配项:。
1. <slug> — <单行描述> - 人工通过编号()或
1 3 5选择wish。all
DREAM.md
DREAM.md
- Read the wish-level value from each selected WISH.md's
**depends-on:**section (## Dependenciesmeans no edge).none - Topologically sort into layers
merge_order— layer 1 has no selected dependencies; same-layer wishes are parallel.1..N - Per-wish entry: ,
slug,branch: feat/<slug>,wish-path: .genie/wishes/<slug>/WISH.md,depends-on. Keep the canonical hyphenated keys so the plan can be checked directly against each wish.merge-order - Write in the shared worktree; present for human confirmation before executing.
.genie/DREAM.md
- 从每个选中的WISH.md的部分读取wish级别的
## Dependencies值(**depends-on:**表示无依赖)。none - 进行拓扑排序,生成层级
merge_order—— 层级1的wish无选中的依赖项;同层级wish可并行执行。1..N - 每个wish的条目包含:、
slug、branch: feat/<slug>、wish-path: .genie/wishes/<slug>/WISH.md、depends-on。保留标准连字符键,以便直接对照每个wish验证计划。merge-order - 在共享工作区写入;执行前需提交人工确认。
.genie/DREAM.md
Phase 1: Execute
阶段1:执行
For each layer, in order:
merge_order- Spawn one worker subagent per wish via the native delegation surface — all of the layer's spawns in ONE message so they run in parallel (background; each notifies you with its final message).
- Every brief carries the Worker Contract below plus curated wish context (goal, groups, acceptance criteria, validation commands — see § Context Curation).
work - Follow-ups to a running worker go through native follow-up messaging; completion is push (the final-message notification), never a sleep-poll.
- Inspect state on demand: /
genie board --wish <slug>. If a wish has no task rows, drive it off WISH.md directly — task tracking is an enhancement, never a blocker.genie task list --wish <slug> - The layer is done when every worker has reported; then dispatch the next layer.
按层级依次处理:
merge_order- 通过原生委托接口为每个wish生成一个工作子Agent —— 同一层级的所有Agent通过一条消息生成,以实现并行运行(后台执行;每个Agent完成后会发送最终消息通知)。
- 每个任务包含下方的工作Agent协议以及整理后的wish上下文(目标、分组、验收标准、验证命令 —— 详见§ Context Curation)。
work - 对运行中Agent的跟进需通过原生跟进消息机制;完成状态通过推送(最终消息通知)确认,绝不采用睡眠轮询方式。
- 按需检查状态:/
genie board --wish <slug>。若某个wish无任务记录,则直接依据WISH.md推进 —— 任务追踪是增强功能,绝不能成为阻塞点。genie task list --wish <slug> - 当该层级所有Agent均已报告完成后,调度下一层级。
Worker Contract
工作Agent协议
Each worker, independently:
- Work in a dedicated branch and worktree for , using runtime-managed or ordinary Git worktrees according to the active environment. The contract governing parallel writers and repo-level git state is stated once in AGENTS.md and the
feat/<slug>skill's Dispatch section — follow it there.work - Execute the wish per (its dispatch, review-gate, and task-state rules govern): dispatched engineers claim via
work; the worker leaves task stategenie task checkoutand reports evidence. Only the dream PM/orchestrator runsin_progressafter clean review and passing validation.genie task done - Run per group against acceptance criteria.
review - Run CI; on failure fix and retry (max 3 attempts; poll CI status, never sleep-loop). After 3 failures → blocked.
- Only after CI green and authorized PR creation: create a PR targeting , preferring the GitHub connector.
dev - Final message is the completion signal, every claim audited against tool output:
done — PR <url>, CI green, groups N/Nblocked — <reason>, groups N/N
每个工作Agent独立执行以下操作:
- 在专用分支和工作区中工作,根据活跃环境使用运行时管理或普通Git工作区。并行写入和仓库级Git状态的管理协议已在AGENTS.md和
feat/<slug>skill的Dispatch部分统一说明 —— 需遵循该协议。work - 按照的规则执行wish(其调度、审核门限和任务状态规则适用):被指派的工程师通过
work认领任务;工作Agent将任务状态标记为genie task checkout并提交执行证据。只有dream PM/编排器在完成审核且验证通过后,才能执行in_progress。genie task done - 按分组对照验收标准运行。
review - 运行CI;若失败则修复并重试(最多3次尝试;轮询CI状态,绝不采用睡眠循环)。3次失败后 → 标记为阻塞。
- 仅在CI通过且获得PR创建授权后:创建目标为分支的PR,优先使用GitHub连接器。
dev - 最终消息为完成信号,所有声明均需对照工具输出审核:
done — PR <url>, CI green, groups N/Nblocked — <reason>, groups N/N
Phase 2: Review + PR
阶段2:审核 + PR
Trigger: all workers in the layer reported done or blocked.
- Dispatch one reviewer subagent per PR via the native delegation surface (reviewer ≠ worker) to run against the wish's acceptance criteria.
review - Read bot comments critically — never blindly accept automated findings.
- On FIX-FIRST: diagnose first; return an overdesigned plan to wish/design review, otherwise dispatch for valid gaps (max 2 loops per PR). On another architectural issue: escalate in the report, no fix attempt.
fix - CI must be green before proceeding — poll status, do not sleep.
- On SHIP: mark the PR review-complete.
触发条件: 该层级所有工作Agent均已报告完成或阻塞。
- 通过原生委托接口为每个PR调度一个审核子Agent(审核Agent ≠ 工作Agent),对照wish的验收标准运行。
review - 审慎读取机器人评论 —— 绝不盲目接受自动化结果。
- 若需优先修复:先诊断问题;若涉及架构问题,将完善后的计划提交至wish/设计审核,否则针对有效问题调度(每个PR最多循环2次)。若存在其他架构问题:在报告中升级处理,不尝试修复。
fix - 继续推进前必须确保CI通过 —— 轮询状态,不采用睡眠等待。
- 若符合SHIP标准:标记该PR审核完成。
Phase 3: Merge + QA
阶段3:合并 + QA
Trigger: all PRs marked SHIP.
- After explicit merge authorization, merge PRs to in
dev; never merge tomerge_orderormain.master - Dispatch a qa subagent on dev to test against each wish's QA criteria.
- Each failure: →
report→trace→ retest. Every fix is a new PR through review and merge.fix - Continue until all criteria are proven or blocked.
触发条件: 所有PR均标记为SHIP。
- 获得明确的合并授权后,按顺序将PR合并至
merge_order分支;绝不能合并至dev或main分支。master - 在dev分支调度一个QA子Agent,对照每个wish的QA标准进行测试。
- 每出现一次失败:→
report→trace→ 重新测试。每一次修复都需创建新PR,经过审核和合并流程。fix - 持续执行直至所有标准均通过验证或任务被阻塞。
Phase 4: Report
阶段4:生成报告
Write — always, even if every wish blocked:
.genie/DREAM-REPORT.mdmarkdown
undefined写入 —— 无论所有wish是否被阻塞,均需生成:
.genie/DREAM-REPORT.mdmarkdown
undefinedDream Report — <date>
Dream Report — <date>
Per-Wish Status
各Wish状态
| merge_order | slug | PR | CI | Review | Merged | QA |
|---|
| merge_order | slug | PR | CI | Review | Merged | QA |
|---|
Blocked Wishes
阻塞的Wish
- : <blocking reason>
<slug>
- : <阻塞原因>
<slug>
QA Findings
QA发现
- : <criterion failed — root cause, fix PR>
<slug>
- : <未通过的标准 — 根本原因,修复PR>
<slug>
Follow-ups
后续事项
- <items requiring human intervention>
undefined- <需人工干预的事项>
undefinedGrounded Progress
可追溯进度
The report is an audit, not a recollection. Every cell traces to tool output from the run: PR URLs, CI results, review verdicts, state, worker final messages. State per wish exactly what is verified, what failed, and what was skipped. Never report a wish shipped until its merge and QA evidence is in hand — dispatched is not done.
genie task list --wish <slug>报告是一份审计记录,而非回忆总结。每个单元格均需追溯至本次运行的工具输出:PR链接、CI结果、审核结论、状态、工作Agent最终消息。每个wish的状态需准确记录已验证内容、失败内容和跳过内容。在拿到合并和QA证据前,绝不能报告wish已完成 —— 调度完成不等于执行完成。
genie task list --wish <slug>Rules
规则
- Never early-stop: a blocked wish is recorded and the remaining wishes continue.
- Never skip Phase 2 or Phase 3 — every PR is reviewed, every merge is QA-tested against wish criteria.
- The orchestrator never executes wish work — always dispatch worker subagents.
- No scope beyond what each WISH.md defines.
- Poll CI status — never in retry loops.
sleep
- 绝不提前终止:若某个wish被阻塞,需记录该状态并继续执行剩余wish。
- 绝不跳过阶段2或阶段3 —— 每个PR都需审核,每次合并都需对照wish标准进行QA测试。
- 编排器绝不直接执行wish工作 —— 始终调度工作子Agent。
- 范围不得超出每个WISH.md的定义。
- 轮询CI状态 —— 重试循环中绝不使用。
sleep