orch: require explicit dispatch execution mode
This commit is contained in:
@@ -174,14 +174,14 @@ Each case file should use this structure:
|
||||
| --- | --- | --- |
|
||||
| `leader-run-dispatch-reconcile-through-bundled-cli` | [leader-run-dispatch-reconcile-through-bundled-cli.md](./leader-run-dispatch-reconcile-through-bundled-cli.md) | validates that a leader can drive a complete `run -> task -> dispatch -> reconcile -> status` happy path through the packaged orch skill |
|
||||
| `leader-blocked-answer-resume-through-bundled-cli` | [leader-blocked-answer-resume-through-bundled-cli.md](./leader-blocked-answer-resume-through-bundled-cli.md) | validates that a leader can observe a blocked task, answer it through `orch`, and reach final completion with a real worker |
|
||||
| `strict-worktree-dispatch-to-cleanup-through-bundled-cli` | [strict-worktree-dispatch-to-cleanup-through-bundled-cli.md](./strict-worktree-dispatch-to-cleanup-through-bundled-cli.md) | validates that the skill can drive strict worktree allocation, reconcile completion, and cleanup through the bundled orch CLI |
|
||||
| `strict-worktree-dispatch-to-cleanup-through-bundled-cli` | [strict-worktree-dispatch-to-cleanup-through-bundled-cli.md](./strict-worktree-dispatch-to-cleanup-through-bundled-cli.md) | validates that the skill can drive `execution-mode code` worktree allocation, reconcile completion, and cleanup through the bundled orch CLI |
|
||||
| `leader-dispatches-dependent-task-after-prerequisite-through-bundled-cli` | [leader-dispatches-dependent-task-after-prerequisite-through-bundled-cli.md](./leader-dispatches-dependent-task-after-prerequisite-through-bundled-cli.md) | validates that a leader can use `dep add` and `ready` to hold back dependent work until a prerequisite completes, then dispatch the newly ready task |
|
||||
| `leader-cancels-active-task-through-bundled-cli` | [leader-cancels-active-task-through-bundled-cli.md](./leader-cancels-active-task-through-bundled-cli.md) | validates that a leader can cancel an already active task through the packaged orch skill without cancelling unrelated ready work |
|
||||
| `leader-answers-blocked-task-with-payload-json-through-bundled-cli` | [leader-answers-blocked-task-with-payload-json-through-bundled-cli.md](./leader-answers-blocked-task-with-payload-json-through-bundled-cli.md) | validates that a leader can answer a blocked task with structured payload data only and still drive the run to completion |
|
||||
| `leader-retries-failed-task-through-bundled-cli` | [leader-retries-failed-task-through-bundled-cli.md](./leader-retries-failed-task-through-bundled-cli.md) | validates that a leader can reconcile a failed attempt and create a successful retry through the packaged orch skill |
|
||||
| `leader-reassigns-blocked-task-through-bundled-cli` | [leader-reassigns-blocked-task-through-bundled-cli.md](./leader-reassigns-blocked-task-through-bundled-cli.md) | validates that a leader can reassign a blocked task from one worker to another and close the run through the packaged orch skill |
|
||||
| `leader-dispatches-and-launches-worker-through-codex-bridge` | [leader-dispatches-and-launches-worker-through-codex-bridge.md](./leader-dispatches-and-launches-worker-through-codex-bridge.md) | validates that a leader can dispatch a task, render a standardized worker brief, and launch a worker subagent from the same Codex thread |
|
||||
| `strict-worktree-dispatch-launches-worker-through-codex-bridge` | [strict-worktree-dispatch-launches-worker-through-codex-bridge.md](./strict-worktree-dispatch-launches-worker-through-codex-bridge.md) | validates that a leader can launch a code-writing worker subagent from saved dispatch metadata while preserving the assigned worktree contract |
|
||||
| `strict-worktree-dispatch-launches-worker-through-codex-bridge` | [strict-worktree-dispatch-launches-worker-through-codex-bridge.md](./strict-worktree-dispatch-launches-worker-through-codex-bridge.md) | validates that a leader can launch a code-writing worker subagent from saved `execution-mode code` dispatch metadata while preserving the assigned worktree contract |
|
||||
|
||||
## Scope
|
||||
|
||||
|
||||
+1
-1
@@ -34,7 +34,7 @@ Validate that all of the following can be true at the same time:
|
||||
### Leader Prompt
|
||||
|
||||
```text
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_payload_answer_001, 2) add and dispatch one task T1 to worker-a, 3) wait until the task becomes blocked, 4) inspect blocked tasks, 5) answer the blocked question using payload-json only with decision=stdout, source=leader, and format=structured, 6) wait until the task completes, 7) reconcile and inspect final status, 8) stop after reporting RUN_ID and THREAD_ID. Do not use ordinary chat to coordinate with the worker.
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_payload_answer_001, 2) add and dispatch one task T1 to worker-a with --execution-mode analysis, 3) wait until the task becomes blocked, 4) inspect blocked tasks, 5) answer the blocked question using payload-json only with decision=stdout, source=leader, and format=structured, 6) wait until the task completes, 7) reconcile and inspect final status, 8) stop after reporting RUN_ID and THREAD_ID. Do not use ordinary chat to coordinate with the worker.
|
||||
```
|
||||
|
||||
### Worker Prompt
|
||||
|
||||
@@ -34,7 +34,7 @@ Validate that all of the following can be true at the same time:
|
||||
### Leader Prompt
|
||||
|
||||
```text
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_002, 2) add and dispatch one task T1 to worker-a, 3) wait until the task becomes blocked, 4) inspect blocked tasks, 5) answer the blocked question with the decision "Use stdout for MVP.", 6) wait until the task completes, 7) reconcile and inspect final status, 8) stop after reporting RUN_ID and THREAD_ID. Do not use ordinary chat to coordinate with the worker.
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_002, 2) add and dispatch one task T1 to worker-a with --execution-mode analysis, 3) wait until the task becomes blocked, 4) inspect blocked tasks, 5) answer the blocked question with the decision "Use stdout for MVP.", 6) wait until the task completes, 7) reconcile and inspect final status, 8) stop after reporting RUN_ID and THREAD_ID. Do not use ordinary chat to coordinate with the worker.
|
||||
```
|
||||
|
||||
### Worker Prompt
|
||||
|
||||
@@ -34,7 +34,7 @@ Validate that all of the following can be true at the same time:
|
||||
### Leader Prompt
|
||||
|
||||
```text
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_cancel_001, 2) add task T1 for worker-a and a second task T2 that should remain untouched, 3) dispatch T1, 4) wait until worker-a has claimed it or marked it in progress, 5) cancel T1 with a clear reason through orch, 6) inspect ready work and final run status, 7) stop after reporting THREAD_ID_1. Do not use ordinary chat to coordinate with the worker.
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_cancel_001, 2) add task T1 for worker-a and a second task T2 that should remain untouched, 3) dispatch T1 with --execution-mode analysis, 4) wait until worker-a has claimed it or marked it in progress, 5) cancel T1 with a clear reason through orch, 6) inspect ready work and final run status, 7) stop after reporting THREAD_ID_1. Do not use ordinary chat to coordinate with the worker.
|
||||
```
|
||||
|
||||
### Worker Prompt
|
||||
|
||||
@@ -36,7 +36,7 @@ The leader is responsible for spawning the worker subagent after dispatch.
|
||||
### Leader Prompt
|
||||
|
||||
```text
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_launch_001, 2) add exactly one task T1 assigned to worker-a, 3) dispatch it with --json saved to TMPDIR/dispatch.json, 4) render a worker brief with ORCH_SKILL_PATH/assets/orch-worker-brief into TMPDIR/worker-brief.txt, 5) spawn one worker subagent that uses INBOX_SKILL_PATH and the generated worker brief, 6) wait or poll until the worker reports completion, 7) inspect final status, 8) stop after reporting RUN_ID and THREAD_ID. Do not use ordinary chat to coordinate with the worker; the launched worker must use inbox only.
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_launch_001, 2) add exactly one task T1 assigned to worker-a, 3) dispatch it with --execution-mode analysis and save --json to TMPDIR/dispatch.json, 4) render a worker brief with ORCH_SKILL_PATH/assets/orch-worker-brief into TMPDIR/worker-brief.txt, 5) spawn one worker subagent that uses INBOX_SKILL_PATH and the generated worker brief, 6) wait or poll until the worker reports completion, 7) inspect final status, 8) stop after reporting RUN_ID and THREAD_ID. Do not use ordinary chat to coordinate with the worker; the launched worker must use inbox only.
|
||||
```
|
||||
|
||||
## Execution Parameters
|
||||
|
||||
+1
-1
@@ -35,7 +35,7 @@ Validate that all of the following can be true at the same time:
|
||||
### Leader Prompt
|
||||
|
||||
```text
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_deps_001, 2) add prerequisite task T1 for worker-a and dependent task T2 for worker-b, 3) make T2 depend on T1, 4) inspect ready work and confirm only T1 is dispatchable at first, 5) dispatch T1, 6) wait until T1 completes, 7) reconcile and inspect ready work again, 8) dispatch T2 only after it becomes ready, 9) wait until T2 completes, 10) reconcile and inspect final status, 11) stop after reporting THREAD_ID_1 and THREAD_ID_2. Do not use ordinary chat to coordinate with the workers.
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_deps_001, 2) add prerequisite task T1 for worker-a and dependent task T2 for worker-b, 3) make T2 depend on T1, 4) inspect ready work and confirm only T1 is dispatchable at first, 5) dispatch T1 with --execution-mode analysis, 6) wait until T1 completes, 7) reconcile and inspect ready work again, 8) dispatch T2 only after it becomes ready with --execution-mode analysis, 9) wait until T2 completes, 10) reconcile and inspect final status, 11) stop after reporting THREAD_ID_1 and THREAD_ID_2. Do not use ordinary chat to coordinate with the workers.
|
||||
```
|
||||
|
||||
### Worker A Prompt
|
||||
|
||||
@@ -35,7 +35,7 @@ Validate that all of the following can be true at the same time:
|
||||
### Leader Prompt
|
||||
|
||||
```text
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_reassign_001, 2) add and dispatch one task T1 to worker-a, 3) wait until worker-a blocks, 4) inspect blocked tasks, 5) reassign T1 to worker-b with a short reason, 6) wait until worker-b completes the new attempt, 7) reconcile and inspect final status, 8) stop after reporting THREAD_ID_1 and THREAD_ID_2. Do not use ordinary chat to coordinate with the workers.
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_reassign_001, 2) add and dispatch one task T1 to worker-a with --execution-mode analysis, 3) wait until worker-a blocks, 4) inspect blocked tasks, 5) reassign T1 to worker-b with a short reason, 6) wait until worker-b completes the new attempt, 7) reconcile and inspect final status, 8) stop after reporting THREAD_ID_1 and THREAD_ID_2. Do not use ordinary chat to coordinate with the workers.
|
||||
```
|
||||
|
||||
### Worker A Prompt
|
||||
|
||||
@@ -34,7 +34,7 @@ Validate that all of the following can be true at the same time:
|
||||
### Leader Prompt
|
||||
|
||||
```text
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_retry_001, 2) add and dispatch one task T1 to worker-a, 3) wait until the first attempt fails, 4) reconcile, 5) retry T1 with a short retry note, 6) wait until the retried attempt completes, 7) reconcile again and inspect final status, 8) stop after reporting RUN_ID, THREAD_ID_1, and THREAD_ID_2. Do not use ordinary chat to coordinate with the worker.
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_retry_001, 2) add and dispatch one task T1 to worker-a with --execution-mode analysis, 3) wait until the first attempt fails, 4) reconcile, 5) retry T1 with a short retry note, 6) wait until the retried attempt completes, 7) reconcile again and inspect final status, 8) stop after reporting RUN_ID, THREAD_ID_1, and THREAD_ID_2. Do not use ordinary chat to coordinate with the worker.
|
||||
```
|
||||
|
||||
### Worker Prompt
|
||||
|
||||
@@ -33,7 +33,7 @@ Validate that all of the following can be true at the same time:
|
||||
### Leader Prompt
|
||||
|
||||
```text
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_001, 2) add exactly one task T1 assigned to worker-a, 3) dispatch it, 4) wait or poll until the worker reports completion, 5) reconcile the run, 6) inspect final status, 7) stop after reporting RUN_ID and THREAD_ID. Do not use ordinary chat to coordinate with the worker.
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_001, 2) add exactly one task T1 assigned to worker-a, 3) dispatch it with --execution-mode analysis, 4) wait or poll until the worker reports completion, 5) reconcile the run, 6) inspect final status, 7) stop after reporting RUN_ID and THREAD_ID. Do not use ordinary chat to coordinate with the worker.
|
||||
```
|
||||
|
||||
### Worker Prompt
|
||||
|
||||
+2
-2
@@ -10,7 +10,7 @@ The goal is to verify that a leader using the packaged `orch` skill can dispatch
|
||||
|
||||
Validate that all of the following can be true at the same time:
|
||||
|
||||
- the leader can dispatch a code task with `--strict-worktree` through the bundled orch skill
|
||||
- the leader can dispatch a code task with `--execution-mode code` through the bundled orch skill
|
||||
- the leader can turn that dispatch JSON into a stable worker brief through `./assets/orch-worker-brief`
|
||||
- the launched worker subagent uses `skills/inbox/` and reports through inbox
|
||||
- the launched worker observes the assigned `worktree_path` and completes the attempt
|
||||
@@ -37,7 +37,7 @@ The leader is responsible for spawning the code-writing worker subagent after di
|
||||
### Leader Prompt
|
||||
|
||||
```text
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_launch_worktree_001, 2) add one code task T1 for worker-a, 3) dispatch it with --repo-path TMPDIR/repo --workspace-root .orch/worktrees --strict-worktree while saving --json to TMPDIR/dispatch.json, 4) render a worker brief with ORCH_SKILL_PATH/assets/orch-worker-brief into TMPDIR/worker-brief.txt, 5) spawn one worker subagent that uses INBOX_SKILL_PATH and the generated worker brief, 6) wait until the worker completes, 7) inspect final status, 8) clean up attempt 1, 9) stop after reporting RUN_ID, THREAD_ID, and WORKTREE_PATH. Do not use ordinary chat to coordinate with the worker; the launched worker must use inbox only and should respect the assigned worktree.
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_launch_worktree_001, 2) add one code task T1 for worker-a, 3) dispatch it with --execution-mode code --repo-path TMPDIR/repo --workspace-root .orch/worktrees while saving --json to TMPDIR/dispatch.json, 4) render a worker brief with ORCH_SKILL_PATH/assets/orch-worker-brief into TMPDIR/worker-brief.txt, 5) spawn one worker subagent that uses INBOX_SKILL_PATH and the generated worker brief, 6) wait until the worker completes, 7) inspect final status, 8) clean up attempt 1, 9) stop after reporting RUN_ID, THREAD_ID, and WORKTREE_PATH. Do not use ordinary chat to coordinate with the worker; the launched worker must use inbox only and should respect the assigned worktree.
|
||||
```
|
||||
|
||||
## Execution Parameters
|
||||
|
||||
@@ -4,13 +4,13 @@
|
||||
|
||||
This is a `forward-test` and a worktree-lifecycle skill validation.
|
||||
|
||||
The goal is to verify that a leader using the packaged `orch` skill can allocate a strict worktree, reconcile completion, and clean that worktree up through the bundled CLI while a worker completes the task through inbox.
|
||||
The goal is to verify that a leader using the packaged `orch` skill can allocate a code-mode worktree, reconcile completion, and clean that worktree up through the bundled CLI while a worker completes the task through inbox.
|
||||
|
||||
## Purpose
|
||||
|
||||
Validate that all of the following can be true at the same time:
|
||||
|
||||
- the leader can dispatch a code task with `--strict-worktree` through the bundled orch skill
|
||||
- the leader can dispatch a code task with `--execution-mode code` through the bundled orch skill
|
||||
- the worker can complete the resulting attempt thread through inbox
|
||||
- the leader can reconcile the finished task and clean the attempt worktree
|
||||
- the final filesystem state matches the cleanup contract
|
||||
@@ -34,7 +34,7 @@ Validate that all of the following can be true at the same time:
|
||||
### Leader Prompt
|
||||
|
||||
```text
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_worktree_001, 2) add one code task T1 for worker-a, 3) dispatch it with --repo-path TMPDIR/repo --workspace-root .orch/worktrees --strict-worktree, 4) record the returned THREAD_ID and WORKTREE_PATH, 5) wait until the worker completes, 6) reconcile, 7) clean up attempt 1, 8) stop after reporting RUN_ID, THREAD_ID, and WORKTREE_PATH. Do not use ordinary chat to coordinate with the worker.
|
||||
Use $orch at ORCH_SKILL_PATH to act as leader on the already initialized SQLite DB TMPDIR/coord.db. Only coordinate through the bundled orch CLI from the skill. Workflow: 1) create run run_blog_skill_worktree_001, 2) add one code task T1 for worker-a, 3) dispatch it with --execution-mode code --repo-path TMPDIR/repo --workspace-root .orch/worktrees, 4) record the returned THREAD_ID and WORKTREE_PATH, 5) wait until the worker completes, 6) reconcile, 7) clean up attempt 1, 8) stop after reporting RUN_ID, THREAD_ID, and WORKTREE_PATH. Do not use ordinary chat to coordinate with the worker.
|
||||
```
|
||||
|
||||
### Worker Prompt
|
||||
@@ -98,7 +98,7 @@ test ! -d WORKTREE_PATH
|
||||
- observed thread id: `thr_5743259fdccb41f9bb33dce0040b27a5`
|
||||
- observed worktree suffix: `.orch/worktrees/run-blog-skill-worktree-001/T1/attempt-1`
|
||||
- evidence summary:
|
||||
- `orch dispatch --strict-worktree` returned `base_ref == "HEAD"`, a concrete `base_commit`, branch `orch/run-blog-skill-worktree-001/T1/attempt-1`, and a non-empty `worktree_path`
|
||||
- `orch dispatch --execution-mode code` returned `base_ref == "HEAD"`, a concrete `base_commit`, branch `orch/run-blog-skill-worktree-001/T1/attempt-1`, and a non-empty `worktree_path`
|
||||
- the task payload stored on the worker thread exposed the same `worktree_path`
|
||||
- final `orch status --run run_blog_skill_worktree_001 --json` returned `run.status == "done"` and `tasks[0].status == "done"`
|
||||
- final `orch cleanup --run run_blog_skill_worktree_001 --task T1 --json` returned one cleaned attempt and the worktree directory no longer existed afterward
|
||||
@@ -114,6 +114,6 @@ test ! -d WORKTREE_PATH
|
||||
- observed thread id: `thr_089527cd07f74b52a524ba07ed74c2e4`
|
||||
- observed worktree path: `/private/tmp/orch-skill-subagents.J1XWgs/strict-worktree-dispatch-to-cleanup-through-bundled-cli/repo/.orch/worktrees/run-blog-skill-worktree-001/T1/attempt-1`
|
||||
- evidence summary:
|
||||
- a real leader agent using `skills/orch/` completed strict `dispatch`, `wait`, `reconcile`, `cleanup`, and `status`
|
||||
- a real leader agent using `skills/orch/` completed code-mode `dispatch`, `wait`, `reconcile`, `cleanup`, and `status`
|
||||
- a real worker agent using `skills/inbox/` claimed the thread and finished it with `done`
|
||||
- main-thread validation confirmed that the task payload did include the same `worktree_path` even though the worker agent summary failed to notice it, and also confirmed the worktree directory no longer existed after cleanup
|
||||
|
||||
@@ -22,7 +22,7 @@ Snapshot date:
|
||||
|
||||
Current state:
|
||||
|
||||
- `orch` CLI is implemented for the current scheduler, strict worktree, wait, and council review surfaces
|
||||
- `orch` CLI is implemented for the current scheduler, explicit execution-mode dispatch, wait, and council review surfaces
|
||||
- automated Go tests now cover every currently documented `orch` command case and workflow case, combining the original integration suite with focused contract tests for run/task/ready/dispatch/blocked/answer/cleanup/status/reconcile/workflow/council-report edges
|
||||
- `status` coverage now also documents the richer leader view: auto-reconcile plus latest attempt, latest message, and blocked-question context
|
||||
- this roadmap now exists under `docs/tests/orch/ROADMAP.md`
|
||||
@@ -244,8 +244,8 @@ docs/tests/orch/
|
||||
| `docs/tests/orch/dispatch/dispatch-creates-strict-worktree.md` | `dispatch` command case | 1 | 1 | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-rejects-dirty-repo-without-base-ref.md` | `dispatch` command case | 1 | 1 | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-allows-explicit-base-ref-on-dirty-repo.md` | `dispatch` command case | 1 | 1 | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-auto-enables-worktree-for-code-like-task.md` | `dispatch` command case | 1 | 1 | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-skips-auto-worktree-for-non-code-task.md` | `dispatch` command case | 1 | 1 | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-requires-explicit-execution-mode.md` | `dispatch` command case | 1 | 1 | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-analysis-mode-skips-worktree.md` | `dispatch` command case | 1 | 1 | done |
|
||||
| `docs/tests/orch/reconcile/README.md` | `reconcile` command case index | 0 | 0 | done |
|
||||
| `docs/tests/orch/reconcile/reconcile-maps-claimed-or-in-progress-thread-to-running.md` | `reconcile` command case | 1 | 1 | done |
|
||||
| `docs/tests/orch/reconcile/reconcile-maps-done-or-failed-thread-to-terminal-task-state.md` | `reconcile` command case | 1 | 1 | done |
|
||||
@@ -303,7 +303,7 @@ docs/tests/orch/
|
||||
| --- | --- | --- | --- |
|
||||
| `docs/tests/orch/workflows/README.md` | `run-dispatch-reconcile-status-happy-path` | end-to-end happy path from run creation through final status | done |
|
||||
| `docs/tests/orch/workflows/README.md` | `dependency-blocked-answer-resume-flow` | dependency gating plus blocked question and answer recovery | done |
|
||||
| `docs/tests/orch/workflows/README.md` | `strict-worktree-dispatch-to-cleanup` | worktree-backed code task flows from dispatch through cleanup | done |
|
||||
| `docs/tests/orch/workflows/README.md` | `code-mode-dispatch-to-cleanup` | worktree-backed code task flows from dispatch through cleanup | done |
|
||||
| `docs/tests/orch/workflows/README.md` | `council-review-end-to-end` | council workflow runs from reviewer dispatch through final report | done |
|
||||
| `docs/tests/orch/run-init/run-init-creates-new-run.md` | `run-init-creates-new-run` | creates a run with goal and optional summary | done |
|
||||
| `docs/tests/orch/run-show/run-show-returns-run-summary-and-task-counts.md` | `run-show-returns-run-summary-and-task-counts` | shows aggregate run metadata after activity | done |
|
||||
@@ -315,11 +315,11 @@ docs/tests/orch/
|
||||
| `docs/tests/orch/ready/ready-orders-by-priority-and-respects-limit.md` | `ready-orders-by-priority-and-respects-limit` | ready output orders by priority and applies explicit limit truncation | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-creates-attempt-and-thread-for-ready-task.md` | `dispatch-creates-attempt-and-thread-for-ready-task` | ready task dispatch creates attempt, thread, and task message | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-rejects-non-ready-task.md` | `dispatch-rejects-non-ready-task` | dispatch on gated task returns invalid_state | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-creates-strict-worktree.md` | `dispatch-creates-strict-worktree` | explicit strict worktree dispatch provisions isolated workspace metadata | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-rejects-dirty-repo-without-base-ref.md` | `dispatch-rejects-dirty-repo-without-base-ref` | dirty repository without explicit base ref is rejected in strict mode | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-allows-explicit-base-ref-on-dirty-repo.md` | `dispatch-allows-explicit-base-ref-on-dirty-repo` | explicit base ref allows dispatch from a dirty repository | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-auto-enables-worktree-for-code-like-task.md` | `dispatch-auto-enables-worktree-for-code-like-task` | code-like task metadata auto-enables worktree mode | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-skips-auto-worktree-for-non-code-task.md` | `dispatch-skips-auto-worktree-for-non-code-task` | clearly non-code tasks stay on normal dispatch path | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-creates-strict-worktree.md` | `dispatch-creates-strict-worktree` | explicit `execution-mode code` dispatch provisions isolated workspace metadata | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-rejects-dirty-repo-without-base-ref.md` | `dispatch-rejects-dirty-repo-without-base-ref` | dirty repository without explicit base ref is rejected in `execution-mode code` | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-allows-explicit-base-ref-on-dirty-repo.md` | `dispatch-allows-explicit-base-ref-on-dirty-repo` | explicit base ref allows `execution-mode code` dispatch from a dirty repository | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-requires-explicit-execution-mode.md` | `dispatch-requires-explicit-execution-mode` | dispatch rejects calls that omit `--execution-mode analysis|code` | done |
|
||||
| `docs/tests/orch/dispatch/dispatch-analysis-mode-skips-worktree.md` | `dispatch-analysis-mode-skips-worktree` | analysis mode stays on the normal non-worktree path | done |
|
||||
| `docs/tests/orch/reconcile/reconcile-maps-claimed-or-in-progress-thread-to-running.md` | `reconcile-maps-claimed-or-in-progress-thread-to-running` | reconcile maps active inbox execution to running task state | done |
|
||||
| `docs/tests/orch/reconcile/reconcile-maps-done-or-failed-thread-to-terminal-task-state.md` | `reconcile-maps-done-or-failed-thread-to-terminal-task-state` | reconcile maps terminal inbox states to terminal task states | done |
|
||||
| `docs/tests/orch/wait/wait-wakes-on-matching-run-event.md` | `wait-wakes-on-matching-run-event` | wait wakes on a later matching run-scoped event | done |
|
||||
|
||||
@@ -104,7 +104,7 @@ Relevant commands:
|
||||
Cases covering worktree behavior should state:
|
||||
|
||||
- whether the source repository is clean or dirty
|
||||
- whether `--strict-worktree` is enabled explicitly or inferred automatically
|
||||
- whether `--execution-mode code` is selected explicitly
|
||||
- whether `--base-ref` is omitted or explicitly provided
|
||||
- where the expected worktree path should be created
|
||||
|
||||
|
||||
@@ -6,8 +6,8 @@
|
||||
| --- | --- | --- |
|
||||
| `dispatch-creates-attempt-and-thread-for-ready-task` | [dispatch-creates-attempt-and-thread-for-ready-task.md](./dispatch-creates-attempt-and-thread-for-ready-task.md) | dispatches a ready task into a new attempt, inbox thread, and initial task message |
|
||||
| `dispatch-rejects-non-ready-task` | [dispatch-rejects-non-ready-task.md](./dispatch-rejects-non-ready-task.md) | rejects dispatch when the task is still gated by dependencies |
|
||||
| `dispatch-creates-strict-worktree` | [dispatch-creates-strict-worktree.md](./dispatch-creates-strict-worktree.md) | provisions a strict worktree and writes workspace metadata into the attempt and payload |
|
||||
| `dispatch-rejects-dirty-repo-without-base-ref` | [dispatch-rejects-dirty-repo-without-base-ref.md](./dispatch-rejects-dirty-repo-without-base-ref.md) | blocks strict worktree dispatch from a dirty repository without an explicit base ref |
|
||||
| `dispatch-creates-strict-worktree` | [dispatch-creates-strict-worktree.md](./dispatch-creates-strict-worktree.md) | provisions a code-mode worktree and writes workspace metadata into the attempt and payload |
|
||||
| `dispatch-rejects-dirty-repo-without-base-ref` | [dispatch-rejects-dirty-repo-without-base-ref.md](./dispatch-rejects-dirty-repo-without-base-ref.md) | blocks code-mode worktree dispatch from a dirty repository without an explicit base ref |
|
||||
| `dispatch-allows-explicit-base-ref-on-dirty-repo` | [dispatch-allows-explicit-base-ref-on-dirty-repo.md](./dispatch-allows-explicit-base-ref-on-dirty-repo.md) | accepts dirty repository state when `--base-ref` resolves to a concrete commit |
|
||||
| `dispatch-auto-enables-worktree-for-code-like-task` | [dispatch-auto-enables-worktree-for-code-like-task.md](./dispatch-auto-enables-worktree-for-code-like-task.md) | auto-enables worktree mode for code-like tasks when no explicit worktree flags are supplied |
|
||||
| `dispatch-skips-auto-worktree-for-non-code-task` | [dispatch-skips-auto-worktree-for-non-code-task.md](./dispatch-skips-auto-worktree-for-non-code-task.md) | keeps clearly non-code tasks on the normal non-worktree dispatch path |
|
||||
| `dispatch-requires-explicit-execution-mode` | [dispatch-requires-explicit-execution-mode.md](./dispatch-requires-explicit-execution-mode.md) | rejects dispatch when the caller does not declare `--execution-mode analysis|code` |
|
||||
| `dispatch-analysis-mode-skips-worktree` | [dispatch-analysis-mode-skips-worktree.md](./dispatch-analysis-mode-skips-worktree.md) | keeps analysis-mode tasks on the normal non-worktree dispatch path |
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_worktree_003 --goal "Validate explicit base ref on dirty repo"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_worktree_003 --task T1 --title "Implement backend" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_worktree_003 --task T1 --repo-path TMPDIR/repo --workspace-root .orch/worktrees --strict-worktree --base-ref HEAD
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_worktree_003 --task T1 --execution-mode code --repo-path TMPDIR/repo --workspace-root .orch/worktrees --base-ref HEAD
|
||||
```
|
||||
|
||||
## 预期输出
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
# Case: `dispatch-analysis-mode-skips-worktree`
|
||||
|
||||
## 用例意义
|
||||
|
||||
验证 `dispatch --execution-mode analysis` 会保持 thread-only,不会创建 worktree。
|
||||
|
||||
## 前置条件
|
||||
|
||||
- 已存在 run `run_blog_auto_worktree_002`
|
||||
- 已存在任务 `T1`
|
||||
|
||||
## 输入
|
||||
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_auto_worktree_002 --goal "Validate analysis-mode dispatch fallback"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_auto_worktree_002 --task T1 --title "Review QA findings" --summary "Summarize test failures and next steps" --default-to qa-worker
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_auto_worktree_002 --task T1 --execution-mode analysis
|
||||
```
|
||||
|
||||
## 预期输出
|
||||
|
||||
- `dispatch` 退出码为 `0`
|
||||
- `data.attempt.worktree_path == ""`
|
||||
- `data.attempt.workspace_status == ""`
|
||||
- `data.message.payload_json.execution_mode == "analysis"`
|
||||
- 仍会正常返回 `thread_id` 与首条任务消息
|
||||
|
||||
## 断言结论
|
||||
|
||||
- analysis mode 始终走标准 dispatch 路径,不会平白引入分支和工作目录
|
||||
- worker brief 和桥接层可以从 payload 中读取显式的 `execution_mode`
|
||||
@@ -1,34 +0,0 @@
|
||||
# Case: `dispatch-auto-enables-worktree-for-code-like-task`
|
||||
|
||||
## 用例意义
|
||||
|
||||
验证 `dispatch` 在未显式传 worktree flags 时,会对 code-like 任务自动启用 worktree 流程。
|
||||
|
||||
## 前置条件
|
||||
|
||||
- `TMPDIR/repo` 是一个干净的 Git 仓库
|
||||
- 已存在 code-like 任务 `T1`
|
||||
|
||||
## 输入
|
||||
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_auto_worktree_001 --goal "Validate auto worktree detection"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_auto_worktree_001 --task T1 --title "Implement backend API" --default-to backend-worker
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_auto_worktree_001 --task T1 --repo-path TMPDIR/repo
|
||||
```
|
||||
|
||||
## 预期输出
|
||||
|
||||
- `dispatch` 退出码为 `0`
|
||||
- `data.attempt.worktree_path` 为非空
|
||||
- `data.attempt.workspace_status == "created"`
|
||||
- 返回的 worktree 路径在磁盘上存在
|
||||
|
||||
## 断言结论
|
||||
|
||||
- `dispatch` 存在自动 worktree 推断逻辑,不要求 leader 每次显式写 `--strict-worktree`
|
||||
|
||||
## 补充约束
|
||||
|
||||
- 当前推断主要依赖任务角色与 acceptance JSON 的 code-like 标记
|
||||
- 未指定 `--workspace-root` 时,自动 worktree 模式默认写到仓库下的 `.orch/worktrees`
|
||||
@@ -14,7 +14,7 @@
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_001 --goal "Build blog MVP" --summary "Public blog plus admin CRUD"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_001 --task T1 --title "Implement retry policy" --summary "Add retry policy to HTTP client" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --body "Implement retry handling for the HTTP client."
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --execution-mode analysis --body "Implement retry handling for the HTTP client."
|
||||
```
|
||||
|
||||
## 预期输出
|
||||
@@ -26,6 +26,7 @@ orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --body "I
|
||||
- `data.attempt.assigned_to == "worker-a"`
|
||||
- `data.thread.thread_id` 与 `data.attempt.thread_id` 一致
|
||||
- `data.message.kind == "task"`
|
||||
- `data.message.payload_json.execution_mode == "analysis"`
|
||||
|
||||
## 断言结论
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
## 用例意义
|
||||
|
||||
验证显式 `--strict-worktree` dispatch 会创建隔离 worktree,并把 workspace 元数据持久化到 attempt 与任务 payload 中。
|
||||
验证显式 `--execution-mode code` dispatch 会创建隔离 worktree,并把 workspace 元数据持久化到 attempt 与任务 payload 中。
|
||||
|
||||
## 前置条件
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_worktree_001 --goal "Validate strict worktree dispatch"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_worktree_001 --task T1 --title "Implement backend" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_worktree_001 --task T1 --repo-path TMPDIR/repo --workspace-root .orch/worktrees --strict-worktree --body "Implement inside isolated worktree."
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_worktree_001 --task T1 --execution-mode code --repo-path TMPDIR/repo --workspace-root .orch/worktrees --body "Implement inside isolated worktree."
|
||||
```
|
||||
|
||||
## 预期输出
|
||||
@@ -26,11 +26,12 @@ orch --db TMPDIR/coord.db --json dispatch --run run_blog_worktree_001 --task T1
|
||||
- `data.attempt.branch_name == "orch/run-blog-worktree-001/T1/attempt-1"`
|
||||
- 返回非空 `data.attempt.worktree_path`
|
||||
- `data.attempt.workspace_status == "created"`
|
||||
- `data.message.payload_json.execution_mode == "code"`
|
||||
- `data.message.payload_json.worktree_path` 与 attempt 中的路径一致
|
||||
|
||||
## 断言结论
|
||||
|
||||
- strict worktree dispatch 会创建真正的隔离工作目录,而不是只记录一组字符串元数据
|
||||
- code-mode dispatch 会创建真正的隔离工作目录,而不是只记录一组字符串元数据
|
||||
- worker 读取任务 payload 时可以拿到同一份 worktree 路径
|
||||
|
||||
## 补充约束
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_worktree_002 --goal "Validate dirty repo rejection"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_worktree_002 --task T1 --title "Implement backend" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_worktree_002 --task T1 --repo-path TMPDIR/repo --workspace-root .orch/worktrees --strict-worktree
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_worktree_002 --task T1 --execution-mode code --repo-path TMPDIR/repo --workspace-root .orch/worktrees
|
||||
```
|
||||
|
||||
## 预期输出
|
||||
|
||||
@@ -17,7 +17,7 @@ orch --db TMPDIR/coord.db --json run init --run run_blog_003 --goal "Validate re
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_003 --task T1 --title "Backend"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_003 --task T2 --title "Frontend"
|
||||
orch --db TMPDIR/coord.db --json dep add --run run_blog_003 --task T2 --depends-on T1
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_003 --task T2
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_003 --task T2 --execution-mode analysis
|
||||
```
|
||||
|
||||
## 预期输出
|
||||
|
||||
@@ -0,0 +1,29 @@
|
||||
# Case: `dispatch-requires-explicit-execution-mode`
|
||||
|
||||
## 用例意义
|
||||
|
||||
验证 `dispatch` 不再做 worktree heuristics,而是要求 caller 显式声明 `--execution-mode analysis|code`。
|
||||
|
||||
## 前置条件
|
||||
|
||||
- 已存在 run `run_blog_auto_worktree_001`
|
||||
- 已存在任务 `T1`
|
||||
|
||||
## 输入
|
||||
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_auto_worktree_001 --goal "Validate explicit execution mode"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_auto_worktree_001 --task T1 --title "Implement backend API" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_auto_worktree_001 --task T1
|
||||
```
|
||||
|
||||
## 预期输出
|
||||
|
||||
- `dispatch` 退出码为 `30`
|
||||
- JSON 错误码为 `invalid_input`
|
||||
- 错误消息指出必须提供 `--execution-mode`
|
||||
|
||||
## 断言结论
|
||||
|
||||
- dispatch 的执行模式是显式契约,而不是由 runtime 根据任务元数据自行猜测
|
||||
- leader 必须对 thread-only 与 worktree-backed 执行路径负责
|
||||
@@ -1,35 +0,0 @@
|
||||
# Case: `dispatch-skips-auto-worktree-for-non-code-task`
|
||||
|
||||
## 用例意义
|
||||
|
||||
验证 `dispatch` 在未显式传 worktree flags 时,不会把明显非代码任务错误地推进到 worktree 执行路径。
|
||||
|
||||
## 前置条件
|
||||
|
||||
- `TMPDIR/repo` 是一个干净的 Git 仓库
|
||||
- 已存在 run `run_blog_auto_worktree_002`
|
||||
- 已存在非 code-like 任务 `T1`
|
||||
|
||||
## 输入
|
||||
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_auto_worktree_002 --goal "Validate non-code dispatch fallback"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_auto_worktree_002 --task T1 --title "Review QA findings" --summary "Summarize test failures and next steps" --default-to qa-worker
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_auto_worktree_002 --task T1 --repo-path TMPDIR/repo
|
||||
```
|
||||
|
||||
## 预期输出
|
||||
|
||||
- `dispatch` 退出码为 `0`
|
||||
- `data.attempt.worktree_path == ""`
|
||||
- `data.attempt.workspace_status == ""`
|
||||
- 仍会正常返回 `thread_id` 与首条任务消息
|
||||
|
||||
## 断言结论
|
||||
|
||||
- 自动 worktree 推断不是“见仓库就建 worktree”
|
||||
- 非代码任务仍走标准 dispatch 路径,不会平白引入分支和工作目录
|
||||
|
||||
## 补充约束
|
||||
|
||||
- 当前非代码判断通常来自任务标题、摘要、角色和 acceptance 信息都缺少 code-like 信号
|
||||
+1
-1
@@ -15,7 +15,7 @@
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_001 --goal "Build blog MVP"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_001 --task T1 --title "Implement retry policy" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --body "Implement retry handling for the HTTP client."
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --execution-mode analysis --body "Implement retry handling for the HTTP client."
|
||||
inbox --db TMPDIR/coord.db --json claim --agent worker-a --thread THREAD_ID
|
||||
inbox --db TMPDIR/coord.db --json update --agent worker-a --thread THREAD_ID --status in_progress --summary "Implementation started"
|
||||
orch --db TMPDIR/coord.db --json reconcile --run run_blog_001
|
||||
|
||||
+1
-1
@@ -14,7 +14,7 @@
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_001 --goal "Build blog MVP"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_001 --task T1 --title "Implement retry policy" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --body "Implement retry handling for the HTTP client."
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --execution-mode analysis --body "Implement retry handling for the HTTP client."
|
||||
inbox --db TMPDIR/coord.db --json claim --agent worker-a --thread THREAD_ID
|
||||
inbox --db TMPDIR/coord.db --json done --agent worker-a --thread THREAD_ID --summary "Retry policy implemented" --body "The HTTP client now retries transient failures."
|
||||
orch --db TMPDIR/coord.db --json reconcile --run run_blog_001
|
||||
|
||||
@@ -16,7 +16,7 @@
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_002 --goal "Build blog MVP"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_002 --task T1 --title "Implement retry policy" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_002 --task T1 --body "Implement retry handling for the HTTP client."
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_002 --task T1 --execution-mode analysis --body "Implement retry handling for the HTTP client."
|
||||
inbox --db TMPDIR/coord.db --json claim --agent worker-a --thread THREAD_ID
|
||||
inbox --db TMPDIR/coord.db --json update --agent worker-a --thread THREAD_ID --status blocked --summary "Need logging decision" --payload-json '{"question":"Should retry attempts be logged?"}'
|
||||
orch --db TMPDIR/coord.db --json status --run run_blog_002
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_001 --goal "Build blog MVP"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_001 --task T1 --title "Implement retry policy" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --body "Implement retry handling for the HTTP client."
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --execution-mode analysis --body "Implement retry handling for the HTTP client."
|
||||
inbox --db TMPDIR/coord.db --json claim --agent worker-a --thread THREAD_ID
|
||||
inbox --db TMPDIR/coord.db --json done --agent worker-a --thread THREAD_ID --summary "Retry policy implemented" --body "The HTTP client now retries transient failures."
|
||||
orch --db TMPDIR/coord.db --json reconcile --run run_blog_001
|
||||
|
||||
@@ -27,7 +27,7 @@ All examples assume:
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_001 --goal "Build blog MVP" --summary "Public blog plus admin CRUD"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_001 --task T1 --title "Implement retry policy" --summary "Add retry policy to HTTP client" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json ready --run run_blog_001
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --body "Implement retry handling for the HTTP client."
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_001 --task T1 --execution-mode analysis --body "Implement retry handling for the HTTP client."
|
||||
inbox --db TMPDIR/coord.db --json claim --agent worker-a --thread THREAD_ID
|
||||
inbox --db TMPDIR/coord.db --json update --agent worker-a --thread THREAD_ID --status in_progress --summary "Implementation started"
|
||||
orch --db TMPDIR/coord.db --json reconcile --run run_blog_001
|
||||
@@ -71,12 +71,12 @@ orch --db TMPDIR/coord.db --json task add --run run_blog_002 --task T1 --title "
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_002 --task T2 --title "Build frontend" --summary "Implement frontend flows" --default-to worker-b
|
||||
orch --db TMPDIR/coord.db --json dep add --run run_blog_002 --task T2 --depends-on T1
|
||||
orch --db TMPDIR/coord.db --json ready --run run_blog_002
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_002 --task T1
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_002 --task T1 --execution-mode analysis
|
||||
inbox --db TMPDIR/coord.db --json claim --agent worker-a --thread THREAD_BACKEND
|
||||
inbox --db TMPDIR/coord.db --json done --agent worker-a --thread THREAD_BACKEND --summary "Backend complete"
|
||||
orch --db TMPDIR/coord.db --json reconcile --run run_blog_002
|
||||
orch --db TMPDIR/coord.db --json ready --run run_blog_002
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_002 --task T2
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_002 --task T2 --execution-mode analysis
|
||||
inbox --db TMPDIR/coord.db --json claim --agent worker-b --thread THREAD_FRONTEND
|
||||
inbox --db TMPDIR/coord.db --json update --agent worker-b --thread THREAD_FRONTEND --status blocked --summary "Need logging decision" --payload-json '{"question":"stdout or stderr?"}'
|
||||
orch --db TMPDIR/coord.db --json reconcile --run run_blog_002
|
||||
@@ -101,11 +101,11 @@ orch --db TMPDIR/coord.db --json status --run run_blog_002
|
||||
- 依赖门控和 blocked-answer 机制在同一个 run 中可以顺序衔接
|
||||
- `answer` 不直接改 task 状态;真正的状态恢复仍依赖 worker 继续推进线程并由 `reconcile` 采集
|
||||
|
||||
## case: strict-worktree-dispatch-to-cleanup
|
||||
## case: code-mode-dispatch-to-cleanup
|
||||
|
||||
### 用例意义
|
||||
|
||||
验证代码任务的 strict worktree 路径能从 dispatch 一直走到 cleanup,确保隔离工作区既会被创建,也能在完成后被移除。
|
||||
验证代码任务的 `execution-mode code` worktree 路径能从 dispatch 一直走到 cleanup,确保隔离工作区既会被创建,也能在完成后被移除。
|
||||
|
||||
### 前置条件
|
||||
|
||||
@@ -115,9 +115,9 @@ orch --db TMPDIR/coord.db --json status --run run_blog_002
|
||||
### 输入
|
||||
|
||||
```bash
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_worktree_001 --goal "Validate strict worktree dispatch"
|
||||
orch --db TMPDIR/coord.db --json run init --run run_blog_worktree_001 --goal "Validate code-mode worktree dispatch"
|
||||
orch --db TMPDIR/coord.db --json task add --run run_blog_worktree_001 --task T1 --title "Implement backend" --default-to worker-a
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_worktree_001 --task T1 --repo-path TMPDIR/repo --workspace-root .orch/worktrees --strict-worktree --body "Implement inside isolated worktree."
|
||||
orch --db TMPDIR/coord.db --json dispatch --run run_blog_worktree_001 --task T1 --execution-mode code --repo-path TMPDIR/repo --workspace-root .orch/worktrees --body "Implement inside isolated worktree."
|
||||
inbox --db TMPDIR/coord.db --json claim --agent worker-a --thread THREAD_ID
|
||||
inbox --db TMPDIR/coord.db --json done --agent worker-a --thread THREAD_ID --summary "Backend complete"
|
||||
orch --db TMPDIR/coord.db --json reconcile --run run_blog_worktree_001
|
||||
@@ -133,7 +133,7 @@ orch --db TMPDIR/coord.db --json cleanup --run run_blog_worktree_001 --task T1 -
|
||||
|
||||
### 断言结论
|
||||
|
||||
- strict worktree 不是单次 dispatch 细节,而是完整 attempt 生命周期的一部分
|
||||
- `execution-mode code` 的 worktree 不是单次 dispatch 细节,而是完整 attempt 生命周期的一部分
|
||||
- `cleanup` 的目标是已完成或废弃的工作区,不应误删仍在活动中的执行目录
|
||||
|
||||
## case: council-review-end-to-end
|
||||
|
||||
Reference in New Issue
Block a user