Skip to content

fix: align GitHub Copilot model variants with catalog#3353

Open
divlook wants to merge 5 commits intocode-yeongyu:devfrom
divlook:fix/copilot-variant-alignment
Open

fix: align GitHub Copilot model variants with catalog#3353
divlook wants to merge 5 commits intocode-yeongyu:devfrom
divlook:fix/copilot-variant-alignment

Conversation

@divlook
Copy link
Copy Markdown

@divlook divlook commented Apr 11, 2026

Summary

  • align GitHub Copilot fallback variants with the current opencode models github-copilot --verbose output by splitting Copilot-specific Opus and Gemini entries from shared fallback chains
  • add regression coverage for requirements, compatibility, runtime capability normalization, model-fallback flows, and plugin-entry isolation
  • verify the change with bun run typecheck, bun test, and bun run build

Changes

  • set GitHub Copilot claude-opus-4.6 fallback entries to variant: high because the current opencode models github-copilot --verbose output exposes only low, medium, and high
  • remove explicit variant from GitHub Copilot gemini-3.1-pro-preview fallback entries because the current opencode models github-copilot --verbose output does not expose a Gemini variant set there
  • update snapshot and regression expectations for the new fallback ordering
  • isolate the auto-update plugin-entry test from local user config leakage

Testing

  • bun run typecheck
  • bun test
  • bun run build

Notes

  • target branch: dev
  • communication for review should stay in English
  • please ensure CLA requirements are satisfied before review/merge

Copilot AI review requested due to automatic review settings April 11, 2026 18:37
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 11, 2026

All contributors have signed the CLA. Thank you! ✅
Posted by the CLA Assistant Lite bot.

Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 8 files

Confidence score: 5/5

  • Automated review surfaced no issues in the provided summaries.
  • No files require special attention.

Auto-approved: Aligns GitHub Copilot variants with catalog capabilities, splitting fallback chains to ensure valid variant requests (e.g., high instead of max for Opus), backed by updated regression tests.

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Aligns GitHub Copilot-specific model fallback entries with the models.jsonl catalog by separating Copilot variants from shared fallback chains, and updates regression coverage to lock in the new ordering/normalization behavior.

Changes:

  • Split shared fallback-chain entries into provider-specific siblings for Copilot Claude Opus (forcing variant: "high") and Copilot Gemini (omitting variant).
  • Add/adjust tests covering settings compatibility and Copilot runtime capability normalization edge-cases.
  • Update model-fallback tests/snapshots and isolate the auto-update plugin-entry test from user config leakage via an isolated config dir.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/shared/model-settings-compatibility.test.ts Adds regression tests for Copilot variant handling when metadata limits variants / when variant is omitted.
src/shared/model-requirements.ts Splits Copilot Claude Opus + Gemini entries from shared chains to match catalog expectations.
src/shared/model-requirements.test.ts Updates ordering/length assertions to reflect split fallback entries.
src/shared/model-capabilities.test.ts Adds tests for Copilot runtime metadata edge cases (object-form variants, empty variants object).
src/plugin/event.model-fallback.test.ts Updates model-fallback expectations to prefer the new adjacent Copilot Opus split entry.
src/hooks/model-fallback/hook.test.ts Updates fallback progression assertions to match the new chain ordering and Copilot Opus high variant.
src/hooks/auto-update-checker/checker/plugin-entry.test.ts Prevents local user config contamination by forcing an isolated OPENCODE_CONFIG_DIR in the spawned process.
src/cli/snapshots/model-fallback.test.ts.snap Snapshot updates reflecting new fallback ordering and Copilot variant behavior.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@divlook
Copy link
Copy Markdown
Author

divlook commented Apr 11, 2026

I have read the CLA Document and I hereby sign the CLA

@divlook
Copy link
Copy Markdown
Author

divlook commented Apr 11, 2026

recheck

github-actions bot added a commit that referenced this pull request Apr 11, 2026
@divlook
Copy link
Copy Markdown
Author

divlook commented Apr 12, 2026

Follow-up cleanup for stale GitHub Copilot nano references is tracked separately in #3359. This PR intentionally keeps that work out of scope and only covers the Copilot variant alignment changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants