Skip to content

docs: lead model-choice guidance with default routing and model: router #76983

Done

Description

@SivaKesava1

Problem

A few documentation and authoring-guide passages still teach model choice as though workflows must pin a model and model: router does not exist. Update the four pages below to lead with routing when a task has no specific model requirement, while preserving explicit model selection.

Verified against main at 3e1d95c.

Background and factual corrections

  • Default implicit model routing to cost/auto instead of cost/balanced #76602 (merged November 10, 2026) changed existing implicit routing from goal: cost, mode: balanced to goal: cost, mode: auto; it did not first introduce default routing.
  • Choose model routing with model: router and router/economy|balanced|robust #76617 (merged November 11, 2026; fixes Choose model routing with model: router #76599) added model: router, router/economy, router/balanced, and router/robust as the preferred explicit routing syntax. engine.model-routing remains supported.
  • Default routing is conditional, not universal: it applies to eligible main-agent workflows on GitHub Copilot inference. Claude and Codex require model-provider: github; their native providers are not routed implicitly. Model overrides, including applicable repository/organization model variables, can bypass the implicit default. Link to the existing eligibility rules rather than duplicating them.
  • An alias such as small selects a model without per-task routing, but resolves against available models and can change over time. Do not promise that small guarantees the same concrete model on every run. Use an exact model ID when a particular concrete model is required.
  • The docs build command is make build-docs, not make build: the root build target builds the Go CLI. There is no docs/Makefile. The docs target runs npm run build in docs.

The routing reference, frontmatter references, shared engines reference, four engine references, glossary, model tables, and .github/aw/syntax-engine.md already received related updates across the earlier work. Do not broadly rewrite them; the Codex clarification and short routing-reference note below are the intended exceptions.

Required changes

1. docs/src/content/docs/reference/cost-management.md

Source reviewed.

  • Choose a Cheaper Model: replace the routing-blind opening and examples pinning gpt-4.1-mini and claude-haiku-4-5. Lead with omitting model for eligible workflows, which already use goal: cost, mode: auto, or explicitly setting model: router/economy for routine, low-risk triage, labeling, and summaries. Explain that routing right-sizes the model and effort; economy sets the lowest success target, not a guaranteed spend cap or universally available model. Link [Model Routing](/gh-aw/reference/model-routing/), including the default-routing eligibility section where helpful.
  • Keep non-routed model selection as the alternative for tasks requiring a particular model or its capabilities. An alias such as small avoids per-task routing, while an exact model ID expresses a concrete-model requirement; do not describe an alias as an immutable pin.
  • Batch Instead of Reacting to Events: the nightly-triage example currently sets engine.model: gpt-4.1-mini. Replace it with model: router/economy (prefer the top-level field), or omit the model line to use eligible default routing. Preserve the rest of the example.
  • AI Credits with Dynamic Model Selectors: retain the model: auto example and accounting explanation. Add a sentence that auto is the engine/provider's selector (Copilot's server-side selector in this example), not gh-aw's per-task router; point readers to model: router and Model Routing.
  • Roll Out Shared Defaults: this page also contains default_model_claude: "claude-haiku-4-5", beyond the two cheaper-model examples. Replace that stale example value with an alias such as small so acceptance case A covers all examples. These variables are explicit model overrides, not a way to enable routing: do not put router or router/* in default_model_* variables, which cannot supply router values at runtime.

2. docs/src/content/docs/reference/engines/codex.md

Source reviewed.

Under Selection and authentication, qualify "Codex has no default model. Set model explicitly..." as applying to the native OpenAI provider. Link to default routing for workflows without a model, and make it consistent with the existing GitHub Copilot inference section: eligible Codex workflows with model-provider: github and no model are routed by default. Do not imply that explicitly configured native OpenAI routing is unsupported.

3. .github/aw/syntax-agentic.md

Source reviewed.

The top-level model: entry currently lists only model IDs and aliases. Add all four router values: router, router/economy, router/balanced, and router/robust, with a relative link to syntax-engine.md for requirements and details.

Tell the authoring agent: unless the task needs a specific model, omit model to retain eligible default routing, or use a supported router value rather than pinning a model. Preserve the existing engine.model precedence rule and support for IDs and aliases. Keep eligibility qualified; omission alone does not enable routing for unsupported providers or configurations.

4. docs/src/content/docs/reference/model-routing.md

Source reviewed.

Add a short note near Get started distinguishing the two different "auto" concepts:

model: auto retains the engine/provider's own model-selection behavior and does not enable gh-aw routing. model: router uses gh-aw's per-task router with goal: cost and mode: auto; that routing mode selects economy, balanced, or robust for each task.

Keep the existing documented balanced fallback when classification is unavailable or unknown. Do not rewrite the rest of the page.

Acceptance cases

  • A - Cost Management: no example in cost-management.md pins gpt-4.1-mini or claude-haiku-4-5, including the shared-defaults sample. The cheaper-model section presents eligible default routing and model: router/economy before explicit model selection, links Model Routing, and does not promise that aliases fix one concrete model forever. The nightly-triage example routes explicitly or omits its model; the dynamic-selector section distinguishes auto from router.
  • B - Codex: the "no default model" statement is limited to native OpenAI inference, links the default-routing section, and no longer contradicts the page's GitHub Copilot inference guidance.
  • C - Authoring guide: the top-level model: entry in .github/aw/syntax-agentic.md lists all four router values, links syntax-engine.md, and instructs the authoring agent to omit model or use a router value unless the task needs a specific model.
  • D - Model Routing: a short note near Get started explicitly distinguishes model: router, engine/provider model: auto, and routing mode: auto.
  • E - Validation: make build-docs succeeds with no new broken links. Existing affected documentation/content-contract tests still pass, including assertions on .github/aw/*.md text; run make test-guidance and any other existing tests that cover the changed passages. Adjust directly affected text assertions only when required by this documentation change. Report baseline failures under the Scope rules below rather than expanding this fix.

Scope

  • Keep the PR to this one fix. Do not change files or behavior unrelated to it. Limit edits to these four pages and directly affected existing documentation/content-test assertions, if necessary.
  • Before fixing a failing check, compare it with the same check on main. If it also fails on main, do not fix it in this PR; merge main once main is fixed, and note in the PR which checks are known failures on main.
  • This applies even if a bot comment asks to fix a failing check: fix only failures caused by this PR's changes.

Non-goals

  • No compiler, schema, runtime, routing-policy, or model-alias behavior changes.
  • No migration of gh-aw's own workflows to model: router; that is a separate decision. Do not edit workflow source or generated lock files.
  • Do not change sub-agent examples using model: small (sub-agents are not routed), evals or enclaves examples, blog posts, or ADRs.
  • No broad cleanup of other pages already updated by the preceding work. Outside the specific Codex clarification and routing-reference note above, leave those pages unchanged.
  • No workflow dispatches or live inference runs are needed for this documentation-only fix.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

documentationmodel-routing

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions