Copilot Model Analyzer
A VS Code extension that recommends the right GitHub Copilot model for your task — helping teams on Copilot Business reduce cost by routing to the most efficient model rather than always defaulting to the most powerful one.
Usage
In Copilot Chat, prefix your prompt with @analyze:
@analyze write integration tests for the auth service
@analyze fix the null pointer error in UserController
@analyze review all our API handlers for security issues
@analyze refactor the payment module to use the new SDK
@analyze design the architecture for a new notifications service
The extension responds with:
- Recommended model — matched to your task type and scope
- Estimated tokens — input + output split
- Estimated cost — in USD, using Copilot Business rates
- Context fit — whether the task fits the model's context window, with an upgrade suggestion if not
How it works
Two-tier classification
- Rules-based (zero cost) — keyword and scope detection covers ~80% of tasks instantly
- LM fallback (~$0.0001/call) — ambiguous prompts are classified by
gpt-5.4-nano via the VS Code Language Model API (no separate API key required — uses your existing Copilot auth)
Model routing
| Task |
Scope |
Recommended model |
| Autocomplete / quick fix |
Single file |
gpt-5.4-nano |
| Bug fix / explain |
Single file |
gpt-5.4-mini |
| Test generation |
Single file |
gpt-5.4-mini |
| Refactor |
Multi-file |
gpt-5.2 |
| Code generation |
Multi-file |
gpt-5.3-codex |
| Analysis / review |
Codebase-wide |
gpt-5.4 |
| Architecture / agentic |
Codebase-wide |
gpt-5.5 |
Supported providers
Model data is sourced from:
- OpenAI — pricing and specs from
models-page-data.react JS bundle on the compare page
- Anthropic — Claude Haiku 4.5, Sonnet 4.6, Opus 4.8
- Google — Gemini 2.5 and 3.x series
Copilot Business billing context
- 1 AI credit = $0.01 USD
- Included: 1,900 credits / user / month (pooled org-wide)
- Promotional: 3,000 credits / user / month until Sep 1 2026
- Code completions and next-edit suggestions are unlimited (no credit cost)
- Chat, CLI, cloud agent, and Spaces interactions are metered
Requirements
- VS Code 1.90 or later
- GitHub Copilot Business subscription
- GitHub Copilot Chat extension
Extension settings
Project-level overrides via .github/copilot-advisor.json:
{
"budget": {
"warn_per_session_usd": 0.50,
"hard_cap_tokens": 350000
},
"defaults": {
"analysis": "gpt-5.4-mini",
"test_generation": "gpt-5.4-mini",
"refactor": "gpt-5.2",
"agentic_wide": "gpt-5.4",
"architecture": "gpt-5.5"
},
"override_allowed": true
}
License
MIT