Agent Step Metadata
Pattern agent steps gained stage declarations, role selection overrides, and generated task card text.
2 milestones 0 tasks
42 execute
2h 3m total
This run corrected a false record: pattern agent steps were all treated as execute work even when they planned, reviewed, repaired, or supplied display metadata. The build first made stage and selection metadata part of the pattern contract, then used the about-card sidecar as the source for task titles and execute-card blurbs.
How this walkthrough is structured
Feature
What did the run build and ship?
The tree now carries agent-step stage keys through parsing, reference data, runtime events, and generated task metadata fallbacks.
Build
How did Gantry structure the work?
The cut put the format and runtime contract before display reuse, so task card text could depend on resolved stages instead of adding another display-only exception.
Stage-Aware Agent Steps
The current pattern spec documents `stage`, `model`, `effort`, and `harness` on `agent` steps, with `stage` defaulting to `execute` and a closed stage vocabulary. `src/engine/pattern_language.rs` still parses those fields into `ResolvedAgentStep`, and `src/engine/reference_dataset.rs` still exports the agent selection keys, agent stages, agent efforts, agent harnesses, and bundled prompt stage evidence. The runtime tests added by the run remain in `src/engine/run/tests/pattern.rs`, where they cover stage declarations and role selection. This sprint's contribution is still identifiable in the tree.
This piece carried the foundation: the pattern format, the runtime resolution path, bundled pattern annotations, and reference data all had to agree on what stage an agent step performs. That was a large but coherent unit because every acceptance point was about the same contract: an agent step declares stage and optional selection overrides, and the engine believes that declaration. Its own sprint ledger stayed green, and the run-level history records no attributed retry for it. The later merge resolve failed after both top-level pieces, so the recorded stress sits at integration rather than inside this sprint's task boundary.
About-Card Task Metadata
`src/engine/run/generic_pattern.rs` still reads generated task cards by task id, prefers the generated title for `TaskMeta`, and uses the generated blurb only for execute-stage `StageStarted` events. `src/domain/mod.rs` still carries `headline` and `blurb` on stage events, so the TUI, attach stream, headless output, statistics, and window title paths consume the same event data rather than reading run directories. The old `title-plan` prompt no longer appears in the shipped prompt tree, and current docs treat its local copies as retired defaults. The fallback tests for absent about-card metadata remain in the runtime test module.
This piece was smaller and depended on the first piece's stage truth: display metadata could be joined only after execute work was no longer the default name for every agent step. Its boundary was the about-card sidecar and the event stream, with fallbacks required when the sidecar was absent or failed. The sprint ledger stayed green with no attributed retry. The only recorded trouble for the run came later, when merge resolve failed after the top-level work had already landed in its disposable branch.