适用于 GitHub Copilot 的 AI 模型的比较
GitHub Copilot 支持具有不同功能的多个 AI 模型。 你选择的模型会影响 Copilot对话 和 Copilot 内联建议的响应质量和相关性。 某些模型提供较低的延迟,而另一些模型则提供更少的幻觉现象或在特定任务上表现更佳。 本指南可帮助你根据任务(而不仅仅是模型名称)选择最佳模型。
注意
- 不同的模型具有不同的请求加成因子,这可能会影响每月使用限额的消耗量。 有关详细信息,请参阅 GitHub Copilot 中的请求。
- 在受支持的 IDE 中使用 Copilot对话 时, 自动 会自动根据可用性为你选择最佳模型。 你可以手动选择其他模型来替代此选择。 请参阅“关于 Copilot 自动模型选择”和“更改 GitHub Copilot Chat 的 AI 模型”。
在受支持的 IDE 中使用 Copilot对话 时, 自动 会自动根据可用性为你选择最佳模型。 你可以手动选择其他模型来替代此选择。 请参阅“关于 Copilot 自动模型选择”和“更改 GitHub Copilot Chat 的 AI 模型”。
按任务推荐的模型
| 使用下表快速查找合适的模型,请在以下部分中查看更多详细信息。 | 型号 | 任务领域 | 在(主要用例)方面表现出色 |
|---|---|---|---|
| GPT-4.1 | General-purpose coding and writing | Fast, accurate code completions and explanations | GPT-4.1 model card |
| GPT-5 mini | General-purpose coding and writing | Fast, accurate code completions and explanations | GPT-5 mini model card |
| GPT-5.1 | Deep reasoning and debugging | Multi-step problem solving and architecture-level code analysis | GPT-5.1 model card |
| GPT-5.1-Codex | Deep reasoning and debugging | Multi-step problem solving and architecture-level code analysis | Not available |
| GPT-5.1 Codex Max | Agentic software development | Agentic tasks | GPT-5.1-Codex-Max model card |
| GPT-5.1-Codex-Mini | Deep reasoning and debugging | Multi-step problem solving and architecture-level code analysis | Not available |
| GPT-5.2 | Deep reasoning and debugging | Multi-step problem solving and architecture-level code analysis | GPT-5.2 model card |
| GPT-5.2-Codex | Agentic software development | Agentic tasks | GPT-5.2-Codex model card |
| GPT-5.3-Codex | Agentic software development | Agentic tasks | GPT-5.3-Codex model card |
| GPT-5.4 | Deep reasoning and debugging | Multi-step problem solving and architecture-level code analysis | GPT-5.4 model card |
| GPT-5.4 mini | Agentic software development | Codebase exploration and is especially effective when using grep-style tools | Not available |
| Claude Haiku 4.5 | Fast help with simple or repetitive tasks | Fast, reliable answers to lightweight coding questions | Claude Haiku 4.5 model card |
| Claude Opus 4.5 | Deep reasoning and debugging | Complex problem-solving challenges, sophisticated reasoning | Claude Opus 4.5 model card |
| Claude Opus 4.6 | Deep reasoning and debugging | Complex problem-solving challenges, sophisticated reasoning | Claude Opus 4.6 model card |
| Claude Opus 4.6 (fast mode) (preview) | Deep reasoning and debugging | Complex problem-solving challenges, sophisticated reasoning | Not available |
| Claude Sonnet 4.0 | Deep reasoning and debugging | Performance and practicality, perfectly balanced for coding workflows | Claude Sonnet 4.0 model card |
| Claude Sonnet 4.5 | General-purpose coding and agent tasks | Complex problem-solving challenges, sophisticated reasoning | Claude Sonnet 4.5 model card |
| Claude Sonnet 4.6 | General-purpose coding and agent tasks | Complex problem-solving challenges, sophisticated reasoning | Claude Sonnet 4.6 model card |
| Gemini 2.5 Pro | Deep reasoning and debugging | Complex code generation, debugging, and research workflows | Gemini 2.5 Pro model card |
| Gemini 3 Flash | Fast help with simple or repetitive tasks | Fast, reliable answers to lightweight coding questions | Gemini 3 Flash model card |
| Gemini 3 Pro | Deep reasoning and debugging | Complex code generation, debugging, and research workflows | Gemini 3 Pro model card |
| Gemini 3.1 Pro | Deep reasoning and debugging | Effective and efficient edit-then-test loops with high tool precision | not applicable |
| Grok Code Fast 1 | General-purpose coding and writing | Fast, accurate code completions and explanations | Grok Code Fast 1 model card |
| Qwen2.5 | General-purpose coding and writing | Code generation, reasoning, and code repair / debugging | Qwen2.5 model card |
| Raptor mini | General-purpose coding and writing | Fast, accurate code completions and explanations | Coming soon |
其他阅读材料
GPT-4.1
| Fast, accurate code completions and explanations | |
|---|---|
| GPT-5.3-Codex | GPT-4.1 model card |
| GPT-5 微型 | GPT-5 mini |
| Fast, accurate code completions and explanations | |
|---|---|
| GPT-5.3-Codex | GPT-5 mini model card |
| GPT-5 微型 | GPT-5.1 |
| Multi-step problem solving and architecture-level code analysis | |
|---|---|
| GPT-5.3-Codex | GPT-5.1 model card |
| GPT-5 微型 | GPT-5.1-Codex |
| Multi-step problem solving and architecture-level code analysis | |
|---|---|
| GPT-5.3-Codex | Not available |
| GPT-5 微型 | GPT-5.1 Codex Max |
| Agentic tasks | |
|---|---|
| GPT-5.3-Codex | GPT-5.1-Codex-Max model card |
| GPT-5 微型 | GPT-5.1-Codex-Mini |
| Multi-step problem solving and architecture-level code analysis | |
|---|---|
| GPT-5.3-Codex | Not available |
| GPT-5 微型 | GPT-5.2 |
| Multi-step problem solving and architecture-level code analysis | |
|---|---|
| GPT-5.3-Codex | GPT-5.2 model card |
| GPT-5 微型 | GPT-5.2-Codex |
| Agentic tasks | |
|---|---|
| GPT-5.3-Codex | GPT-5.2-Codex model card |
| GPT-5 微型 | GPT-5.3-Codex |
| Agentic tasks | |
|---|---|
| GPT-5.3-Codex | GPT-5.3-Codex model card |
| GPT-5 微型 | GPT-5.4 |
| Multi-step problem solving and architecture-level code analysis | |
|---|---|
| GPT-5.3-Codex | GPT-5.4 model card |
| GPT-5 微型 | GPT-5.4 mini |
| Codebase exploration and is especially effective when using grep-style tools | |
|---|---|
| GPT-5.3-Codex | Not available |
| GPT-5 微型 | Claude Haiku 4.5 |
| Fast, reliable answers to lightweight coding questions | |
|---|---|
| GPT-5.3-Codex | Claude Haiku 4.5 model card |
| GPT-5 微型 | Claude Opus 4.5 |
| Complex problem-solving challenges, sophisticated reasoning | |
|---|---|
| GPT-5.3-Codex | Claude Opus 4.5 model card |
| GPT-5 微型 | Claude Opus 4.6 |
| Complex problem-solving challenges, sophisticated reasoning | |
|---|---|
| GPT-5.3-Codex | Claude Opus 4.6 model card |
| GPT-5 微型 | Claude Opus 4.6 (fast mode) (preview) |
| Complex problem-solving challenges, sophisticated reasoning | |
|---|---|
| GPT-5.3-Codex | Not available |
| GPT-5 微型 | Claude Sonnet 4.0 |
| Performance and practicality, perfectly balanced for coding workflows | |
|---|---|
| GPT-5.3-Codex | Claude Sonnet 4.0 model card |
| GPT-5 微型 | Claude Sonnet 4.5 |
| Complex problem-solving challenges, sophisticated reasoning | |
|---|---|
| GPT-5.3-Codex | Claude Sonnet 4.5 model card |
| GPT-5 微型 | Claude Sonnet 4.6 |
| Complex problem-solving challenges, sophisticated reasoning | |
|---|---|
| GPT-5.3-Codex | Claude Sonnet 4.6 model card |
| GPT-5 微型 | Gemini 2.5 Pro |
| Complex code generation, debugging, and research workflows | |
|---|---|
| GPT-5.3-Codex | Gemini 2.5 Pro model card |
| GPT-5 微型 | Gemini 3 Flash |
| Fast, reliable answers to lightweight coding questions | |
|---|---|
| GPT-5.3-Codex | Gemini 3 Flash model card |
| GPT-5 微型 | Gemini 3 Pro |
| Complex code generation, debugging, and research workflows | |
|---|---|
| GPT-5.3-Codex | Gemini 3 Pro model card |
| GPT-5 微型 | Gemini 3.1 Pro |
| Effective and efficient edit-then-test loops with high tool precision | |
|---|---|
| GPT-5.3-Codex | not applicable |
| GPT-5 微型 | Grok Code Fast 1 |
| Fast, accurate code completions and explanations | |
|---|---|
| GPT-5.3-Codex | Grok Code Fast 1 model card |
| GPT-5 微型 | Qwen2.5 |
| Code generation, reasoning, and code repair / debugging | |
|---|---|
| GPT-5.3-Codex | Qwen2.5 model card |
| GPT-5 微型 | Raptor mini |
| Fast, accurate code completions and explanations | |
|---|---|
| GPT-5.3-Codex | Coming soon |
| GPT-5 微型 | 任务:常规用途的编码和编写 |
| Grok Code Fast 1 | 将这些模型用于需要平衡质量、速度和成本效益的常见开发任务。 如果没有特定要求,这些模型是不错的默认方案。 |
| 猛龙迷你 | 型号 |
为什么它很合适
GPT-5.3-Codex
- 在复杂的工程任务(如功能、测试、调试、重构和评审)中,无需冗长指令即可交付更高质量的代码。
- 数据变量.copilot.copilot_gpt_5_mini %}
- 这是适合大多数编码和编写任务的可靠默认方案。
- 快速、准确且跨语言和框架工作良好。
Grok Code Fast 1
专用于编码任务。 在生成代码和跨多种语言调试方面表现出色。
猛龙迷你
专门用于提供快速而准确的内联建议和解释。 何时使用这些模型 如果要执行以下操作,请使用这些模型之一:
编写或查看函数、短文件或代码变更。
| 生成文档、注释或摘要。 | 快速解释错误或意外行为。 |
|---|---|
| 克劳德·海库 4.5 | 在非英语编程环境中工作。 何时使用其他模型 |
如果要处理复杂的重构、体系结构决策或多步骤逻辑,请考虑使用深层推理和调试中的模型。
若要完成更快、更简单的任务(如重复编辑或一次性代码建议),请参阅快速帮助完成简单或重复的任务。
- 任务:快速帮助完成简单或重复的任务
- 这些模型针对速度和响应能力进行了优化。
- 它们非常适合快速编辑、实用工具函数、语法帮助和轻型原型制作。
- 你将获得快速答案,而无需等待不必要的深度或较长的推理链。
建议的模型
型号 为什么它很合适
克劳德·海库 4.5
平衡快速响应与高质量输出。 非常适合小型任务和轻型代码解释。
何时使用这些模型
| 如果要执行以下操作,请使用这些模型之一: | 编写或编辑小型函数或实用工具代码。 |
|---|---|
| GPT-5 微型 | 询问快速语法或语言问题。 以最少的设置建立创意原型。 |
| GPT-5.4 | 获取有关简单提示或编辑的快速反馈。 |
| 克洛德十四行诗 4.6 | 何时使用其他模型 |
| 克洛德作品4.6 | 如果要处理复杂的重构、体系结构决策或多步骤逻辑,请参阅深层推理和调试。 有关需要更强常规用途的推理或更结构化输出的任务,请参阅常规用途的编码和编写。 |
| 双子座 3.1 专业版 | 任务:深层推理和调试 |
| Goldeneye | 这些模型专为需要分步推理、复杂决策或高上下文感知的任务而设计。 |
当你需要结构化分析、深思熟虑的代码生成或多文件理解时,它们就很合适。
建议的模型
- 型号
- 为什么它很合适
- 数据变量.copilot.copilot_gpt_5_mini %}
- 提供深度推理和调试能力,与 GPT-5 相比,响应速度更快,资源使用率更低。
- 非常适合交互式会话和分步代码分析。
GPT-5.4
擅长复杂的推理、代码分析和技术决策。 克洛德十四行诗 4.6
对 Sonnet 4.5 版本进行了改进,在压力下能够更可靠地完成任务并进行更智能的推理。
克洛德作品4.6 Anthropic 的最强模型。
| 对 克洛德作品4.5 进行了改进。 | 双子座 3.1 专业版 |
|---|---|
| GPT-5 微型 | 长篇语境中的高级推理和科学或技术分析。 Goldeneye 复杂的解决问题挑战和复杂的推理。 |
| 克洛德十四行诗 4.6 | 何时使用这些模型 |
| 双子座 3.1 专业版 | 如果要执行以下操作,请使用这些模型之一: |
在跨多个文件的上下文中调试复杂问题。
重构大型或互连的代码库。
- 跨层规划功能或架构。
- 在库、模式或工作流之间进行权衡。
- 分析日志、性能数据或系统行为。
提示
何时使用其他模型 若要完成快速迭代或轻型任务,请参阅快速帮助完成简单或重复的任务。 有关常规开发工作流或内容生成,请参阅常规用途的编码和编写。
任务:使用视觉对象(图表、屏幕截图)
如果要询问有关屏幕截图、图表、UI 组件或其他视觉输入的问题,请使用这些模型。 这些模型支持多模态输入,非常适合前端工作或视觉对象调试。
型号
为什么它很合适 数据变量.copilot.copilot_gpt_5_mini %}
- 这是适合大多数编码和编写任务的可靠默认方案。
- 快速、准确,并支持视觉推理任务的多模式输入。
- 在不同的语言和框架中都能良好运作。
- 克洛德十四行诗 4.6