docs(prds): fold review findings into execution-tree and harness PRDs

This commit is contained in:
sam committed 2026-09-26 01:45:10 +10:00
1 parent ca8d189f96
commit f74827795d
3 files changed
+15 -7

No files matched your search

+7 -1
View File
@@ -83,12 +83,17 @@ A StepExecution cannot reach `running` while its WorkflowExecution is not
- The table lives in `taskstate` (no dependencies), so the store, daemon and
gateway share one copy.
- Every store method that changes `tasks.status` checks the table and writes
the audit and event rows, not only `Transition`. That includes the claim,
`ParkTask`, `Requeue`, `RetryTask`, `BeginRemediation` and `RecoverStale`
paths, several of which change status without an audit row.
- The State Store rejects an illegal transition with a new sentinel,
`ErrIllegalTransition`, carried across the wire through `mapError` like
`ErrStaleTransition`. A stale `from` stays `ErrStaleTransition`.
- Each transition is one transaction: guarded row update, audit row, domain
event row. The events table is written by the store, not emitted beside it.
`KindStageStart` and `KindStageFinish` are produced by the step transition.
`KindStageStart` and `KindStageFinish` are produced by the step transition
and published to the bus after commit.
- `workflow.Run` stops discarding persistence errors. A failed step write
parks the execution; the step does not run unrecorded.
@@ -131,6 +136,7 @@ token.
One new table, `step_executions`: `id`, `execution_id`, `attempt`,
`parent_id`, `depth`, `kind`, `name`, `status`, `detail`, `tokens_used`,
`started_at`, `finished_at`. Indexed on `(execution_id, attempt, id)`.
Deleting an execution (archive, clearing terminal tasks) deletes its steps.
Existing rows gain no backfilled steps. Their history stays in `transitions`
and `events`.
+6 -4
View File
@@ -46,9 +46,10 @@ Order of precedence, first match wins:
2. the agent profile's `runner`;
3. `builtin`, the ai-sdk agent loop.
`runner` names a `[harnesses.<name>]` entry. An entry with no consumer
(named by no stage and no profile) is a validation warning, and an unknown
name is a validation error.
`runner` names a `[harnesses.<name>]` entry. `archie-agent` reads the entry
when it builds the stage's runner; that is the field's only consumer. An
unknown name and an entry named by no stage and no profile are both
validation errors.
```toml
[harnesses.claude-sub]
@@ -95,7 +96,8 @@ to the harness by `archie-agent mcp`, a stdio MCP server started inside the
container and registered through the adapter's invocation flags. It serves
the stage's `CaptureTools` and the central tools the agent profile allows.
It does not serve the `workspace` toolset, for the same reason the built-in
runner withholds it.
runner withholds it. The runner's `ToolLimits` bound the results it returns.
The harness's own built-in tools are outside archie's limits.
A harness that does not declare `mcp` can only run stages with no capture
tools.