You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/ide/copilot-chat-context-references.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
---
2
2
title: 'Manage chat context with references'
3
-
description: Use references to set context and get better answers in GitHub Copilot Chat.
3
+
description: Use references to form better questions and get better answers with scoped context in GitHub Copilot Chat.
4
4
ms.date: 7/31/2025
5
5
ms.topic: how-to
6
6
author: anandmeg
@@ -15,7 +15,7 @@ monikerRange: '>= vs-2022'
15
15
---
16
16
# Manage chat context with references
17
17
18
-
Scope your questions to [**GitHub Copilot Chat**](visual-studio-github-copilot-chat.md) by using references to get better answer, in addition to its implicit contextual knowledge.
18
+
Scope your questions to [**GitHub Copilot Chat**](visual-studio-github-copilot-chat.md) by using references to get better answers, in addition to its implicit contextual knowledge.
19
19
20
20
In this article, you learn how to get better answers by providing more information to Copilot Chat:
Copy file name to clipboardExpand all lines: docs/ide/copilot-chat-context.md
+6-5Lines changed: 6 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
---
2
2
title: 'Customize chat responses'
3
-
description: Use slash commands to form better questions and get better answers with scoped context in GitHub Copilot Chat.
3
+
description: Use custom instructions and prompt files to customize responses and use slash commands to set quick context for common tasks.
4
4
ms.date: 7/31/2025
5
5
ms.topic: how-to
6
6
author: anandmeg
@@ -15,11 +15,12 @@ monikerRange: '>= vs-2022'
15
15
---
16
16
# Customize chat responses and set context
17
17
18
-
You can ask [**GitHub Copilot Chat**](visual-studio-github-copilot-chat.md) to give you code suggestions, explain code, generate unit tests, and suggest code fixes. In addition to your prompt, Copilot uses additional context, like the code in your current file, any attached images, and the chat history, to generate a response.
18
+
You can ask [**GitHub Copilot Chat**](visual-studio-github-copilot-chat.md) to give you code suggestions, explain code, generate unit tests, and suggest code fixes. Chat in Visual Studio can give you responses and generate code that matches your coding practices and project requirements, if you give it the right context. Instead of repeatedly adding this information in every chat prompt, you can store this context in files and automatically include it in every chat request.
19
19
20
20
In this article, you learn how to get better answers by providing more information to Copilot Chat:
21
-
+ Use [slash commands](#slash-commands) to quickly specify common tasks like `/explain` to get code explanations.
22
-
+ Use the [guided chat experience](#prompting-guidance) and [custom instructions](#enable-custom-instructions) to refine context.
21
+
+ Use [slash commands](#slash-commands) to quickly specify common tasks like `/explain` to get code explanations
22
+
+ Use the [guided chat experience](#prompting-guidance) to refine context
23
+
+ Use [custom instructions](#enable-custom-instructions) and [prompt files](#use-prompt-files) to customize responses
23
24
24
25
Learn more about [AI-assisted development in Visual Studio](../ide/ai-assisted-development-visual-studio.md) and how to [use Copilot Chat in Visual Studio](../ide/visual-studio-github-copilot-chat.md#use-copilot-chat-in-visual-studio).
25
26
@@ -62,7 +63,7 @@ To use a prompt file:
62
63
63
64
:::image type="content" source="media/vs-2022/copilot-chat-context/prompt-files.png" alt-text="Screenshot of using prompt files in GitHub Copilot Chat.":::
64
65
65
-
## <aname="slash-commands"></a>Use slash commands in Copilot Chat for common tasks
66
+
## <aname="slash-commands"></a>Use slash commands to set context for common tasks
66
67
67
68
Slash commands in Copilot Chat help you set the intent quickly for common development tasks. By using specific slash commands to form your question, you can get better answers without having to write out long questions.
0 commit comments