Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .github/aw/syntax-agentic.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ description: Agentic workflow specific frontmatter fields for GitHub Agentic Wor
- **`max-turns:`** - AWF turn cap applied consistently across all agentic engines (integer or expression, e.g. `${{ inputs.max-turns }}`). The engine-level `engine.max-turns` is a deprecated alias kept for backward compatibility — prefer this top-level field. Not supported by the `gemini` engine.
- **`max-runs:`** - Deprecated legacy alias for the AWF invocation cap (`apiProxy.maxRuns`, defaults to `500` when omitted). Use `max-turns` instead; run `gh aw fix` to migrate.
- **`max-ai-credits:`** - Per-run AI Credits (AIC) budget enforced by the AWF firewall (integer or `K`/`M` short-form string like `100M`; default `1000`). Set a negative value to disable enforcement and token steering. See [token-optimization.md](token-optimization.md).
- **`max-turn-cache-misses:`** - Maximum consecutive AWF cache misses allowed before the API proxy blocks further requests (integer, default `5`). Maps to `apiProxy.maxCacheMisses`; precedence is frontmatter → `GH_AW_DEFAULT_MAX_TURN_CACHE_MISSES` env override → built-in default.
- **`max-daily-ai-credits:`** - Per-user 24-hour AI Credits (AIC) guardrail: activation blocks execution once the triggering user's aggregated AI Credits for this workflow over the last 24h exceed the threshold (integer or `K`/`M` short-form string, or `-1`). Enabled by default with a system default threshold; set `-1` to disable or an explicit value to override. See [token-optimization.md](token-optimization.md).
- **`user-rate-limit:`** - Rate limiting configuration to prevent users from triggering the workflow too frequently (object)
- **`max-runs-per-window:`** - Maximum runs allowed per user per time window (required, integer 1-10)
Expand Down Expand Up @@ -276,6 +277,7 @@ description: Agentic workflow specific frontmatter fields for GitHub Agentic Wor
id: copilot # Required: coding agent identifier (copilot, claude, codex, gemini; experimental: opencode, crush, pi)
version: beta # Optional: version of the action (has sensible default); also accepts GitHub Actions expressions: ${{ inputs.engine-version }}
model: gpt-5 # Optional: LLM model to use (has sensible default)
permission-mode: acceptEdits # Optional (claude only): auto | acceptEdits | plan | bypassPermissions. Default: acceptEdits (auto when tools.edit is false)
agent: technical-doc-writer # Optional: custom agent file (Copilot only, references .github/agents/{agent}.agent.md)
max-turns: 5 # Deprecated alias for the top-level `max-turns`; prefer the top-level field
max-continuations: 3 # Optional: max autopilot continuations (copilot only; >1 enables --autopilot mode, default: 1)
Expand Down
8 changes: 2 additions & 6 deletions .github/aw/syntax-tools-imports.md
Original file line number Diff line number Diff line change
Expand Up @@ -233,22 +233,18 @@ imports:
---
```

**Object form with inputs** — Use `path:`/`uses:` + `with:`/`inputs:` to pass values to shared workflows that define an `import-schema:`. Optional `checkout:` and `env:` fields customize the import:
**Object form with inputs** — Use `path:`/`uses:` + `with:`/`inputs:` to pass values to shared workflows that define an `import-schema:`:

```yaml
imports:
- path: shared/tool-setup.md
with:
environment: staging
max-issues: 3
env:
MY_VAR: "value" # Optional: pass env vars into the imported workflow
checkout: main # Optional: ref to check out when this import is processed
- uses: shared/security-notice.md # 'uses' is an alias for 'path'
```

- `env:` - Environment variables passed into the imported workflow context (object). Use when a shared workflow relies on environment variables that must be supplied by the importing workflow.
- `checkout:` - Ref (branch, tag, or SHA) to check out when processing this import (string). Overrides the default checkout for this specific import entry.
`path`/`uses` and `with`/`inputs` are the only valid keys on an import entry. To supply environment variables or a checkout ref, set top-level `env:`/`checkout:` frontmatter inside the imported file itself — those are merged into the importing workflow (see the merge list below), not configured per import entry.

Conditional `imports:` entries are not supported. For experiment-specific prompt variants, keep the import unconditional and gate a `{{#runtime-import? ...}}` block (optional form) in the workflow body instead. The optional form is not promoted to unconditional lock-file macros, so the content is only injected when the condition is true at runtime.

Expand Down
Loading