daily-model-inventory: add Copilot artifact fallback when Copilot API is unavailable#31623
Closed
Copilot wants to merge 3 commits into
Closed
daily-model-inventory: add Copilot artifact fallback when Copilot API is unavailable#31623Copilot wants to merge 3 commits into
Copilot wants to merge 3 commits into
Conversation
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Update model alias inventory for 2026-05-12
daily-model-inventory: add Copilot artifact fallback when Copilot API is unavailable
May 12, 2026
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Contributor
Author
Enabled |
pelikhan
approved these changes
May 12, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the daily model inventory workflow to better handle Copilot API outages by enabling the agentic-workflows tool and adding prompt guidance to fall back to mining model IDs from GitHub Actions artifacts.
Changes:
- Added
actions: readpermission to support reading workflow artifacts/runs for fallback scenarios. - Enabled the
agentic-workflowstool in the daily-model-inventory workflow. - Updated the workflow prompt to instruct artifact-based fallback when Copilot
/modelsreturns HTTP errors or empty results.
Show a summary per file
| File | Description |
|---|---|
| .github/workflows/daily-model-inventory.md | Adds permissions, enables agentic-workflows, and documents Copilot artifact fallback behavior in the agent prompt. |
| .github/workflows/daily-model-inventory.lock.yml | Recompiled lockfile reflecting the new tool and permissions; includes additional runtime steps and MCP configuration updates. |
Copilot's findings
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 2/2 changed files
- Comments generated: 2
Comment on lines
421
to
+427
| empty `models` array. Skip providers with errors or empty model lists. | ||
|
|
||
| If the Copilot provider returns an HTTP error (for example HTTP 400) or an empty model list, use | ||
| GitHub Actions artifacts from a recent successful run that used `engine: copilot` as a fallback | ||
| source for Copilot model IDs. Mine model IDs from the run artifacts, then include those IDs in your | ||
| analysis as artifact-derived Copilot inventory (and call out that source explicitly in the issue). | ||
|
|
Comment on lines
+519
to
+544
| - name: Install gh-aw extension | ||
| env: | ||
| GH_TOKEN: ${{ secrets.GH_AW_GITHUB_MCP_SERVER_TOKEN || secrets.GH_AW_GITHUB_TOKEN || secrets.GITHUB_TOKEN }} | ||
| run: | | ||
| # Check if gh-aw extension is already installed | ||
| if gh extension list | grep -q "github/gh-aw"; then | ||
| echo "gh-aw extension already installed, upgrading..." | ||
| gh extension upgrade gh-aw || true | ||
| else | ||
| echo "Installing gh-aw extension..." | ||
| gh extension install github/gh-aw | ||
| fi | ||
| gh aw --version | ||
| # Copy the gh-aw binary to ${RUNNER_TEMP}/gh-aw for MCP server containerization | ||
| mkdir -p "${RUNNER_TEMP}/gh-aw" | ||
| GH_AW_BIN="" | ||
| GH_AW_BIN=$(command -v gh-aw 2>/dev/null) || true | ||
| if [ -z "$GH_AW_BIN" ]; then | ||
| GH_AW_BIN=$(find "${HOME}/.local/share/gh/extensions/gh-aw" -name 'gh-aw' -type f 2>/dev/null | head -1) || true | ||
| fi | ||
| if [ -n "$GH_AW_BIN" ] && [ -f "$GH_AW_BIN" ]; then | ||
| cp "$GH_AW_BIN" "${RUNNER_TEMP}/gh-aw/gh-aw" | ||
| chmod +x "${RUNNER_TEMP}/gh-aw/gh-aw" | ||
| echo "Copied gh-aw binary to ${RUNNER_TEMP}/gh-aw/gh-aw" | ||
| else | ||
| echo "::error::Failed to find gh-aw binary for MCP server" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
tools.agentic-workflowsto daily-model-inventory workflow