You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat!: align engine front matter with gh-aw and hook up Engine enum (#286)
* feat!: align engine front matter with gh-aw and hook up Engine enum
BREAKING CHANGE: The engine front matter format changed from model names
(engine: claude-opus-4.5) to engine identifiers (engine: copilot). Model
is now a sub-field in the object form (engine: { id: copilot, model: ... }).
- Redefine EngineConfig to use engine identifiers aligned with gh-aw
- Add full gh-aw field set: id, version, model, agent, api-target, args,
env, command, timeout-minutes
- Replace Engine trait + dyn dispatch with Engine enum (Engine::Copilot)
- Add get_engine() factory that rejects non-copilot identifiers
- Supply resolved Engine in CompileContext
- Route generate_copilot_params through ctx.engine.args()
- Consolidate engine env vars (GITHUB_TOKEN, COPILOT_OTEL_*) into
Engine::env(), remove from pipeline templates
- Rename {{ copilot_ado_env }} to {{ engine_env }}
- Remove SYSTEM_ACCESSTOKEN injection from agent sandbox step
- Remove AZURE_DEVOPS_EXT_PAT from engine env (handled by MCPG)
- Remove cancel_previous_builds functionality (used System.AccessToken)
- Update examples to new engine format
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* chore: remove engine from example front matters
Default engine (copilot) and model (claude-opus-4.5) are applied
automatically when engine: is omitted.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* docs(engine): update AGENTS.md and engine.rs for new engine format
- Update AGENTS.md front matter example to use `engine: copilot` instead
of the old `engine: claude-opus-4.5` format (which now fails at compile)
- Update Engine Configuration section to document `id` field, object form
with `id: copilot`, and all new EngineOptions fields
- Add compile-time warnings for engine options that are parsed but not yet
wired into the pipeline (args, version, agent, api-target, command, env)
- Fix 8-space indent in copilot_args() body left over from impl extraction
- Add #[allow(dead_code)] and clarifying doc comment to Engine::command()
- Remove obsolete {{ cancel_previous_builds }} section from AGENTS.md
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix(prompts): update dispatcher prompts for new engine format, simplify generate_copilot_params
- Fix create-ado-agentic-workflow.md: Step 2 now teaches engine as an
engine identifier (not a model name), object form includes id: copilot,
complete example uses object form with model selection
- Fix debug-ado-agentic-workflow.md: Model/Engine Failures section now
shows correct format and explains the engine vs model distinction
- Remove redundant front_matter parameter from generate_copilot_params —
ctx.front_matter is the same value; updated all 25+ call sites
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* refactor(engine): remove generate_copilot_params wrapper, use Engine::args directly
The wrapper was a trivial one-liner delegating to ctx.engine.args().
All call sites (production + 25 tests) now call Engine::args() directly
via the CompileContext, removing an unnecessary layer of indirection.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copy file name to clipboardExpand all lines: AGENTS.md
+15-27Lines changed: 15 additions & 27 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -121,8 +121,9 @@ The compiler expects markdown files with YAML front matter similar to gh-aw:
121
121
name: "name for this agent"
122
122
description: "One line description for this agent"
123
123
target: standalone # Optional: "standalone" (default) or "1es". See Target Platforms section below.
124
-
engine: claude-opus-4.5 # AI engine to use. Defaults to claude-opus-4.5. Other options include claude-sonnet-4.5, gpt-5.2-codex, gemini-3-pro-preview, etc.
124
+
engine: copilot # Engine identifier. Defaults to copilot. Currently only 'copilot' (GitHub Copilot CLI) is supported.
125
125
# engine: # Alternative object format (with additional options)
126
+
# id: copilot
126
127
# model: claude-opus-4.5
127
128
# timeout-minutes: 30
128
129
schedule: daily around 14:00 # Fuzzy schedule syntax - see Schedule Syntax section below
@@ -314,14 +315,15 @@ schedule:
314
315
315
316
### Engine Configuration
316
317
317
-
The `engine` field specifies which AI model to use and optional execution parameters. It accepts both a simple string format (model name only) and an object format with additional options.
318
+
The `engine` field specifies which engine to use for the agentic task. The string form is an engine identifier (currently only `copilot` is supported). The object form uses `id` for the engine identifier plus additional options like model selection and timeout.
318
319
319
320
```yaml
320
-
# Simple string format (just a model name)
321
-
engine: claude-opus-4.5
321
+
# Simple string format (engine identifier, defaults to copilot)
322
+
engine: copilot
322
323
323
324
# Object format with additional options
324
325
engine:
326
+
id: copilot
325
327
model: claude-opus-4.5
326
328
timeout-minutes: 30
327
329
```
@@ -330,11 +332,20 @@ engine:
330
332
331
333
| Field | Type | Default | Description |
332
334
|-------|------|---------|-------------|
335
+
| `id` | string | `copilot` | Engine identifier. Currently only `copilot` (GitHub Copilot CLI) is supported. |
333
336
| `model` | string | `claude-opus-4.5` | AI model to use. Options include `claude-sonnet-4.5`, `gpt-5.2-codex`, `gemini-3-pro-preview`, etc. |
334
337
| `timeout-minutes` | integer | *(none)* | Maximum time in minutes the agent job is allowed to run. Sets `timeoutInMinutes` on the `Agent` job in the generated pipeline. |
338
+
| `version` | string | *(none)* | Engine CLI version to install (e.g., `"0.0.422"`, `"latest"`). **Not yet wired** — parsed but ignored with a warning. |
339
+
| `agent` | string | *(none)* | Custom agent file identifier (Copilot only). **Not yet wired** — parsed but ignored with a warning. |
340
+
| `api-target` | string | *(none)* | Custom API endpoint hostname for GHES/GHEC (e.g., `"api.acme.ghe.com"`). **Not yet wired** — parsed but ignored with a warning. |
341
+
| `args` | list | `[]` | Custom CLI arguments injected before the prompt. **Not yet wired** — parsed but ignored with a warning. |
342
+
| `env` | map | *(none)* | Engine-specific environment variables. **Not yet wired** — parsed but ignored with a warning. |
343
+
| `command` | string | *(none)* | Custom engine executable path (skips default installation). **Not yet wired** — parsed but ignored with a warning. |
335
344
336
345
> **Deprecated:** `max-turns` is still accepted in front matter for backwards compatibility but is ignored at compile time (a warning is emitted). It was specific to Claude Code and is not supported by Copilot CLI.
337
346
347
+
> **Note:** Fields marked "not yet wired" are accepted in the schema for forward compatibility with gh-aw but produce a compile-time warning. Pipeline wiring for these fields is incremental.
348
+
338
349
#### `timeout-minutes`
339
350
340
351
The `timeout-minutes` field sets a wall-clock limit (in minutes) for the entire agent job. It maps to the Azure DevOps `timeoutInMinutes` job property on `Agent`. This is useful for:
@@ -838,29 +849,6 @@ Tool names are validated at compile time:
838
849
- Names must contain only ASCII alphanumerics and hyphens (shell injection prevention)
839
850
- Unrecognized names (not in `ALL_KNOWN_SAFE_OUTPUTS`) emit a warning to catch typos
840
851
841
-
## {{ cancel_previous_builds }}
842
-
843
-
When `triggers.pipeline` is configured, this generates a bash step that cancels any previously queued or in-progress builds of the same pipeline definition. This prevents multiple builds from accumulating when the upstream pipeline triggers rapidly (e.g., multiple PRs merged in quick succession).
844
-
845
-
The step:
846
-
- Uses the Azure DevOps REST API to query builds for the current pipeline definition
847
-
- Filters to only `notStarted` and `inProgress` builds
Should be replaced with the embedded threat detection analysis prompt from `src/data/threat-analysis.md`. This prompt template includes markers for `{{ source_path }}`, `{{ agent_name }}`, `{{ agent_description }}`, and `{{ working_directory }}` which are replaced during compilation.
description: "Checks for outdated dependencies and opens PRs to update them"
63
63
```
64
64
65
-
### Step 2 — AI Model (engine)
65
+
### Step 2 — Engine
66
66
67
-
Default is `claude-opus-4.5`. Only include `engine:` if the user requests a different model.
67
+
Default engine is `copilot` (GitHub Copilot CLI). The `engine:` field is an engine identifier, not a model name. Only include `engine:` if you need to set a non-default model or timeout.
68
68
69
-
| Value | Use when |
69
+
The default model is `claude-opus-4.5`. To use a different model, use the object form:
70
+
71
+
| Model | Use when |
70
72
|---|---|
71
73
| `claude-opus-4.5` | Default. Best reasoning, complex tasks. |
Copy file name to clipboardExpand all lines: prompts/debug-ado-agentic-workflow.md
+11-1Lines changed: 11 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -133,10 +133,20 @@ network:
133
133
134
134
**Common causes**:
135
135
136
-
- **Invalid model name**: Check the `engine:` field matches a supported model (`claude-opus-4.5`, `claude-sonnet-4.5`, `gpt-5.2-codex`, `gemini-3-pro-preview`, etc.)
136
+
- **Invalid engine or model**: The `engine:` field is an engine identifier (e.g., `copilot`), not a model name. To specify a model, use the object form. Check that the engine identifier is valid and the model name is correct:
137
+
```yaml
138
+
# Wrong — model name as engine identifier
139
+
engine: claude-opus-4.5
140
+
141
+
# Correct — engine identifier with model
142
+
engine:
143
+
id: copilot
144
+
model: claude-opus-4.5
145
+
```
137
146
- **Timeout**: Agent hits the Azure DevOps job timeout (default 60 minutes). Set an explicit timeout:
0 commit comments