Skip to content

Investigate Copilot small model-alias failure in smoke workflow#44442

Closed
pelikhan with Copilot wants to merge 9 commits into
mainfrom
copilot/investigate-copilot-failure-aliases
Closed

Investigate Copilot small model-alias failure in smoke workflow#44442
pelikhan with Copilot wants to merge 9 commits into
mainfrom
copilot/investigate-copilot-failure-aliases

Conversation

Copilot AI commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

The Smoke Copilot Small run fails in the Copilot execution step with model 'small' is unsupported or unrecognized by this AWF version, despite the workflow intentionally using a model alias. This change adds a focused investigation artifact to capture evidence, scope, and next validation paths.

  • What was added

    • New troubleshooting doc: docs/troubleshooting/copilot-model-alias-failure-investigation.md
    • Anchors the analysis to the exact failing run/job/step URL.
    • Records the observed failure signature, runtime env evidence, and emitted model alias map context.
  • Findings captured

    • engine.model is set to small in workflow source.
    • Runtime passes COPILOT_MODEL=small.
    • AWF config includes alias mapping for small ("small": ["mini"]), but execution still rejects small before successful run.
  • Follow-up paths documented

    • Compare behavior across alias (small, mini) vs concrete model (gpt-5-mini) to isolate where alias resolution diverges.
    • Use results to decide between AWF-path upgrade vs smoke workflow model selection adjustment.
engine:
  id: copilot
  model: small
[ERROR] Error: model 'small' is unsupported or unrecognized by this AWF version. Did you mean 'gpt-4'?

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title Investigate Copilot model alias failure in smoke-copilot-small Investigate Copilot small model-alias failure in smoke workflow Jul 9, 2026
Copilot AI requested a review from pelikhan July 9, 2026 01:54
@pelikhan

pelikhan commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

@copilot investigate what code generates this error message

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>

Copilot AI commented Jul 9, 2026

Copy link
Copy Markdown
Contributor Author

@copilot investigate what code generates this error message

Tracked this down in commit 0b3f244.

The message is not generated by code in github/gh-aw itself. In this repo, we generate and run the AWF invocation (pkg/workflow/awf_helpers.go) and set COPILOT_MODEL (pkg/workflow/copilot_engine_execution.go). The exact error string (model 'small' is unsupported or unrecognized by this AWF version...) comes from the external awf runtime (gh-aw-firewall) during that invocation.

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
@pelikhan

pelikhan commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

@copilot find the root cause in the gitilhub/gh-aw-firewall sources

Copilot AI and others added 3 commits July 9, 2026 02:34
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>

Copilot AI commented Jul 9, 2026

Copy link
Copy Markdown
Contributor Author

@copilot find the root cause in the gitilhub/gh-aw-firewall sources

Addressed in commit b3d769a. Root cause is in github/gh-aw-firewall: src/commands/validators/config-assembly.ts validates COPILOT_MODEL via validateCopilotModel() and exits before runtime alias resolution. src/copilot-model.ts only checks a hardcoded SUPPORTED_COPILOT_MODELS set (plus retired aliases), so small is rejected before AWF_MODEL_ALIASES is applied by api-proxy.

@pelikhan

pelikhan commented Jul 9, 2026

Copy link
Copy Markdown
Collaborator

@copilot refactor models.json to work around this issue so that the execution path avoids the improper checks. Flatten/expand model names.

Copilot AI and others added 3 commits July 9, 2026 02:57
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>

Copilot AI commented Jul 9, 2026

Copy link
Copy Markdown
Contributor Author

@copilot refactor models.json to work around this issue so that the execution path avoids the improper checks. Flatten/expand model names.

Implemented in 0b3a04e.

models.json is now flattened/expanded for Copilot by adding explicit mini and small model entries (mirrored in both pkg/cli/data/models.json and actions/setup/js/models.json) mapped to the gpt-5-mini profile so this execution path no longer depends on late alias resolution.

@pelikhan pelikhan closed this Jul 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants