From 5e9707d9e3422b77b1995da4a7715f6c58f4dfae Mon Sep 17 00:00:00 2001 From: Nick Trogh <1908215+ntrogh@users.noreply.github.com> Date: Thu, 21 Aug 2025 09:44:28 +0200 Subject: [PATCH] Add provider and restructure --- .../model-provider-quick-pick.png | 4 +-- docs/copilot/language-models.md | 33 ++++++++----------- 2 files changed, 15 insertions(+), 22 deletions(-) diff --git a/docs/copilot/images/language-models/model-provider-quick-pick.png b/docs/copilot/images/language-models/model-provider-quick-pick.png index 3c9d1a3606..03ed537434 100644 --- a/docs/copilot/images/language-models/model-provider-quick-pick.png +++ b/docs/copilot/images/language-models/model-provider-quick-pick.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4c6b7e405e51864e6bd3cbf868d413025b6c75254dbc70911dd780a9ccb7c216 -size 34108 +oid sha256:1a644a02d19486dcf64fc608824101b82ce4f599b7061d1a6728ae94eb29dfda +size 44255 diff --git a/docs/copilot/language-models.md b/docs/copilot/language-models.md index 12f67fd024..0d119ff957 100644 --- a/docs/copilot/language-models.md +++ b/docs/copilot/language-models.md @@ -6,33 +6,19 @@ MetaSocialImage: images/shared/github-copilot-social.png --- # AI language models in VS Code -Copilot in Visual Studio Code offers different built-in language models that are optimized for different tasks. You can also bring your own language model API key to use models from other providers. This article describes how to change the language model for chat or code completions, and how to use your own API key. +Visual Studio Code offers different language models that are optimized for different tasks via GitHub Copilot. You can also bring your own language model API key to use models from other providers. This article describes how to change the language model for chat or code completions, and how to use your own API key. ## Choose the right model for your task By default, chat uses a base model to provide fast, capable responses for a wide range of tasks, such as coding, summarization, knowledge-based questions, reasoning, and more. -However, you are not limited to using only this model. You can choose from a [selection of language models](https://docs.github.com/en/copilot/using-github-copilot/ai-models/changing-the-ai-model-for-copilot-chat#ai-models-for-copilot-chat-1), each with its own particular strengths. You may have a favorite model that you like to use, or you might prefer to use a particular model for inquiring about a specific subject. For a detailed comparison of AI models, see [Choosing the right AI model for your task](https://docs.github.com/en/copilot/using-github-copilot/ai-models/choosing-the-right-ai-model-for-your-task) in the GitHub Copilot documentation. +However, you are not limited to using only this model. You can choose from a [selection of language models](https://docs.github.com/en/copilot/using-github-copilot/ai-models/changing-the-ai-model-for-copilot-chat#ai-models-for-copilot-chat-1), each with its own particular strengths. For a detailed comparison of AI models, see [Choosing the right AI model for your task](https://docs.github.com/en/copilot/using-github-copilot/ai-models/choosing-the-right-ai-model-for-your-task) in the GitHub Copilot documentation. -Depending on the [chat mode](/docs/copilot/chat/copilot-chat.md#chat-mode) you are using, the list of available models might be different. For example, in agent mode, the list of models is limited to those that have good support for tool calling. +Depending on the [chat mode](/docs/copilot/chat/chat-modes.md) you are using, the list of available models might be different. For example, in agent mode, the list of models is limited to those that have good support for tool calling. > [!NOTE] > If you are a Copilot Business or Enterprise user, your administrator needs to enable certain models for your organization by opting in to `Editor Preview Features` in the [Copilot policy settings](https://docs.github.com/en/enterprise-cloud@latest/copilot/managing-copilot/managing-github-copilot-in-your-organization/managing-policies-for-copilot-in-your-organization#enabling-copilot-features-in-your-organization) on GitHub.com. -## Why use your own language model API key? - -In addition to the built-in models, you can access models directly from Anthropic, Azure, Google, Groq, OpenAI, OpenRouter, or Ollama by providing a valid API key. Learn how to [use your own API in VS Code](#bring-your-own-language-model-key). - -Using your own language model API key in VS Code has several advantages: - -- **Model choice**: access hundreds of models from different providers, beyond the built-in models. -- **Experimentation**: experiment with new models or features that are not yet available in the built-in models. -- **Local compute**: use your own compute for one of the models already supported in GitHub Copilot or to run models not yet available. -- **Greater control**: by using your own key, you can bypass the standard rate limits and restrictions imposed on the built-in models. - -> [!IMPORTANT] -> This feature is in preview and is not currently available to Copilot Business or Copilot Enterprise users. - ## Change the model for chat conversations Use the language model picker in the chat input field to change the model that is used for chat conversations and code editing. @@ -67,11 +53,18 @@ To change the language model that is used for generating code completions in the ## Bring your own language model key -If you already have an API key for a language model provider, you can use their models in chat in VS Code, in addition to the built-in models that Copilot provides. You can use models from the following providers: Anthropic, Azure, Google Gemini, Groq, Ollama, OpenAI, and OpenRouter. - > [!IMPORTANT] > This feature is in preview and is not currently available to Copilot Business or Copilot Enterprise users. +If you already have an API key for a language model provider, you can use their models in chat in VS Code, in addition to the built-in models that Copilot provides. You can use models from the following providers: Anthropic, Azure, Google Gemini, Groq, Ollama, OpenAI, OpenRouter, and xAI. + +Using your own language model API key in VS Code has several advantages: + +- **Model choice**: access hundreds of models from different providers, beyond the built-in models. +- **Experimentation**: experiment with new models or features that are not yet available in the built-in models. +- **Local compute**: use your own compute for one of the models already supported in GitHub Copilot or to run models not yet available. +- **Greater control**: by using your own key, you can bypass the standard rate limits and restrictions imposed on the built-in models. + To manage the available models for chat: 1. Select **Manage Models** from the language model picker in the Chat view. @@ -108,7 +101,7 @@ To update the provider details, such as the API key or endpoint URL: 1. Update the provider details, such as the API key or endpoint URL. -### Considerations +## Considerations There are a number of considerations when using your own language model API key in VS Code: