← ClaudeAtlas

task-tree-chain-runlisted

Run one Agent step along GraphState.Chain in Codex or Cursor. Use chain-step for focus; execute Next node's NextIdea (下一步思路); may read full task-tree.md when needed. Stop loop when shouldStopLoop=true.
guess-guess-who-i-am/llm-task-tree · ★ 1 · AI & Automation · score 72
Install: claude install-skill guess-guess-who-i-am/llm-task-tree
# Task Tree Chain Run 让 **Codex / Cursor Agent** 按执行链**一次只跑一个节点**。 ## 关键限制(必读) | 问题 | 现状 | |------|------| | 能否看完整树? | **可以**。Codex 在项目里能读 `task-tree.md`;链式 loop 仍建议先用 `chain-step` 拿本步 `Next`/`NextIdea`,需要全局上下文时再读整树 | | 正确读法 | 先 `GET /api/graph-state/chain-step` 的 `stepMarkdown`(或 `.chain-run/step-context.md`),再按需读完整 `task-tree.md` | | loop 执行依据 | **Next 节点的 `NextIdea`(页面「下一步思路」)** — **不是** `GraphState.NextPlan`(「下一步」) | | loop 会不会自己停? | **不会自动停**。`shouldStopLoop=true` 时必须运行 **`chain-loop-stop.ps1 -SoftOnly`**(默认不关闭 IDE) | | 怎么知道本轮结束? | 一轮 = Agent 从 tick 醒来到本 turn 结束;结束时更新节点 + 可选 `chain-advance` | | 链跑完后? | `Next` 空、`ChainRunStatus=done`、`shouldStopLoop=true` → **stop loop,不再执行** | 链式模式下 **§10 补充 AGENTS §1**:每轮先用 chain-step 确定本步;**执行内容以 Next 节点的 NextIdea 为准**;可读整树、改树、跑命令,但**一轮只完成当前 Next 的 NextIdea**。**推进 Next 只能用 `POST /api/graph-state/chain-advance`**,不要手改 markdown 里的 `GraphState.Next`(非链式时 Next 由用户在 UI 点 ◆ 决定)。 ## 每轮 loop 固定流程 ### 0. 第一件事 — 门禁(必须) ```bash curl -s http://127.0.0.1:<port>/api/graph-state/chain-step ``` 解析 JSON: - **`shouldStopLoop: true`** → 运行停止脚本(**最后一动作**,默认 SoftOnly 不关 IDE): ```powershell powershell -ExecutionPolicy Bypass -File llm-task-tree-kit/scripts/chain-loop-stop.ps1 -SoftOnly -Reason "<stopReason>" ``` 只回复 `链已停止:<stopReason>`;**不要**读 task-tree、**不要**继续 loop - **`shouldStopLoop: false`** → 继续 也可用项目脚本(若存在):`powershell -File llm-task-tree-kit/scripts/chain-loop-gate.ps1` ### 1. 读上下文 优先使用响应里的 **`stepMarkdown`**(或磁盘上的 `.chain-run/step-con