| title | Asking GitHub Copilot questions in your IDE | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| intro | Use {% data variables.copilot.copilot_chat_short %} in your editor to give you code suggestions, explain code, generate unit tests, and suggest code fixes. | ||||||||||
| redirect_from |
|
||||||||||
| defaultTool | vscode | ||||||||||
| versions |
|
||||||||||
| shortTitle | Chat in IDE | ||||||||||
| contentType | how-tos | ||||||||||
| category |
|
This guide describes how to use {% data variables.copilot.copilot_chat_short %} and agents to automate coding tasks by breaking them into steps, using tools to read files, edit code, and run commands, and self-correcting when something goes wrong. You can also ask general questions about software development, or specific questions about the code in your project. For more information, see AUTOTITLE.
{% vscode %}
- Access to {% data variables.product.prodname_copilot %}. {% data reusables.copilot.subscription-prerequisite %} {% data reusables.copilot.vscode-prerequisites %}
{% data reusables.copilot.chat-access-denied %}
Note
If you don’t see the Agent option in the mode selector, your enterprise or organization administrator may have disabled agent mode for your IDE.
You can use {% data variables.copilot.copilot_chat_short %} in the following modes:
- Agent mode: to get {% data variables.product.prodname_copilot_short %} to autonomously accomplish a set task.
- Plan mode: to get {% data variables.product.prodname_copilot_short %} to create detailed implementation plans to ensure all requirements are met.
- Ask mode: to get answers to coding questions and get {% data variables.product.prodname_copilot_short %} to provide code suggestions.
To switch between modes, use the agents dropdown at the bottom of the chat view.
{% data reusables.copilot.copilot-edits.agent-mode-description %}
- If the chat view is not already displayed, select Open Chat from the {% data variables.copilot.copilot_chat_short %} menu.
- At the bottom of the chat view, ensure Agent is selected from the agents dropdown.
- Submit a prompt. In response to your prompt, {% data variables.product.prodname_copilot_short %} streams the edits in the editor, updates the working set, and if necessary, runs terminal commands, if necessary.
- Review and iterate on changes or run a code review.
You can also click this link to go directly to agent mode in {% data variables.product.prodname_vscode_shortname %}.
For more information, see Chat overview in the {% data variables.product.prodname_vscode %} documentation.
{% data reusables.copilot.copilot-edits.agent-mode-requests %}
{% data reusables.copilot.subagent-intro %}
- In the {% data variables.copilot.copilot_chat_short %} window, click the tools icon.
- Enable the
runSubagenttool.
If you use custom prompt files or {% data variables.copilot.custom_agents_short %}, ensure you specify the runSubagent tool in the tools frontmatter property. See AUTOTITLE, and Use prompt files in VS Code in the {% data variables.product.prodname_vscode %} documentation.
{% data reusables.copilot.using-subagents %}
-
Calling the #runSubagent tool.
Evaluate the #file:databaseSchema using #runSubagent and generate an optimized data-migration plan.
When the {% data variables.copilot.subagent_short %} completes its task, its results appear back in the main chat session, ready for follow-up questions or next steps.
Plan mode helps you to create detailed implementation plans before executing them. This ensures that all requirements are considered and addressed before any code changes are made. The plan agent does not make any code changes until the plan is reviewed and approved by you. Once approved, you can hand off the plan to the default agent or save it for further refinement, review, or team discussions.
The plan agent is designed to:
- Research the task comprehensively using read-only tools and codebase analysis to identify requirements and constraints.
- Break down the task into manageable, actionable steps and include open questions about ambiguous requirements.
- Present a concise plan draft, based on a standardized plan format, for user review and iteration.
-
If the chat view is not already displayed, select Open Chat from the {% data variables.copilot.copilot_chat_short %} menu.
-
At the bottom of the chat view, select Plan from the agents dropdown.
-
Type a prompt that describes a task, such as adding a feature to an existing application, refactoring code, fixing a bug, or creating an initial version of a new application.
For example:
Create a simple to-do web app with HTML, CSS, and JS files.After a few moments, the plan agent outputs a plan in the chat view. The plan provides a high-level summary and a breakdown of steps, including any open questions for clarification.
{% data reusables.copilot.plan-agent-steps %}
For more information, see Planning with agents in VS Code in the {% data variables.product.prodname_vscode %} documentation.
Ask mode is optimized for answering questions about your codebase, coding, and general technology concepts. Use ask mode when you want to understand how something works, explore ideas, or get help with coding tasks.
- If the chat view is not already displayed, select Open Chat from the {% data variables.copilot.copilot_chat_short %} menu.
- At the bottom of the chat view, select Ask from the agents dropdown.
- Type a prompt in the prompt box and press Enter.
You can give the agent a high-level description of what you want to build and it gets to work. Each task runs inside an agent session, a persistent conversation you can track, pause, resume, or hand off to another agent.
-
To open the chat view, click the chat icon in the title bar of {% data variables.product.prodname_vscode %}. If the chat icon is not displayed, right-click the title bar and make sure that Command Center is selected.
-
Enter a prompt in the prompt box. For an introduction to the kinds of prompts you can use, see AUTOTITLE.
-
Evaluate {% data variables.product.prodname_copilot_short %}'s response, and make a follow-up request if needed.
The response may contain text, code blocks, buttons, images, URIs, and file trees. The response often includes interactive elements. For example, the response may include a menu to insert a code block, or a button to invoke a {% data variables.product.prodname_vscode %} command.
To see the files that {% data variables.copilot.copilot_chat_short %} used to generate the response, select the Used n references dropdown at the top of the response. The references may include a link to a custom instructions file for your repository. This file contains additional information that is automatically added to all of your chat questions to improve the quality of the responses. For more information, see AUTOTITLE.
You can use special keywords to help {% data variables.product.prodname_copilot_short %} understand your prompt. For examples, see AUTOTITLE.
Chat participants are like domain experts who have a specialty that they can help you with.
{% data variables.copilot.copilot_chat_short %} can infer relevant chat participants based on your natural language prompt, improving discovery of advanced capabilities without you having to explicitly specify the participant you want to use in your prompt.
[!NOTE] Automatic inference for chat participants is currently in {% data variables.release-phases.public_preview %} and is subject to change.
Alternatively, you can manually specify a chat participant to scope your prompt to a specific domain. To do this, type @ in the chat prompt box, followed by a chat participant name.
For a list of available chat participants, type @ in the chat prompt box. See also AUTOTITLE or Chat participants in the {% data variables.product.prodname_vscode %} documentation.
Use slash commands to avoid writing complex prompts for common scenarios. To use a slash command, type / in the chat prompt box, followed by a command.
To see all available slash commands, type / in the chat prompt box. See also AUTOTITLE or Slash commands in the {% data variables.product.prodname_vscode %} documentation.
Use chat variables to include specific context in your prompt. To use a chat variable, type # in the chat prompt box, followed by a chat variable.
To see all available chat variables, type # in the chat prompt box. See also AUTOTITLE.
Using {% data variables.product.prodname_dotcom %} skills for {% data variables.product.prodname_copilot_short %}
{% data reusables.copilot.using-skills %}
{% data reusables.copilot.mcp.mcp-chat-in-ide %}
{% data reusables.copilot.change-the-ai-model %}
In addition to submitting prompts through the chat view, you can submit prompts in other ways:
- Quick chat: To open the quick chat dropdown, enter Shift+Optin+Command+L (Mac) / Ctrl+Shift+Alt+L (Windows/Linux).
- Inline: To start an inline chat directly in the editor or integrated terminal, enter Command+i (Mac) / Ctrl+i (Windows/Linux).
- Smart actions: To submit prompts via the context menu, right click in your editor, select {% data variables.product.prodname_copilot_short %} in the menu that appears, then select one of the actions. Smart actions can also be accessed via the sparkle icon that sometimes appears when you select a line of code.
See inline chat, quick chat, and chat smart actions in the {% data variables.product.prodname_vscode %} documentation for more details.
{% data reusables.copilot.using-images-in-chat %}
-
Do one of the following:
- Copy an image and paste it into the chat view.
- Drag and drop one or more image file from your operating system's file explorer—or from the Explorer in {% data variables.product.prodname_vscode_shortname %}—into the chat view.
- Right-click an image file in the {% data variables.product.prodname_vscode_shortname %} Explorer and click {% data variables.product.prodname_copilot_short %} then Add File to Chat.
{% data reusables.copilot.type-prompt-for-image %}
To indicate whether a response was helpful, use the thumbs up and thumbs down icons that appear next to the response.
To leave feedback about the {% data variables.copilot.copilot_chat %} extension, open an issue in the microsoft/vscode-copilot-release repository.
- AUTOTITLE
- Using {% data variables.copilot.copilot_chat_short %} in {% data variables.product.prodname_vscode_shortname %} and Getting started with {% data variables.product.prodname_copilot %} in {% data variables.product.prodname_vscode_shortname %} in the {% data variables.product.prodname_vscode %} documentation
- AUTOTITLE
- AUTOTITLE
- AUTOTITLE
- {% data variables.product.prodname_copilot %} Trust Center
- {% data variables.product.prodname_copilot %} FAQ
{% endvscode %}
{% visualstudio %}
-
Access to {% data variables.product.prodname_copilot %}. {% data reusables.copilot.subscription-prerequisite %}
-
{% data variables.product.prodname_vs %} 2022 version 17.8 or later. See Install {% data variables.product.prodname_vs %} in the {% data variables.product.prodname_vs %} documentation.
- For {% data variables.product.prodname_vs %} 17.8 and 17.9:
- {% data variables.product.prodname_copilot %} extension. See Install {% data variables.product.prodname_copilot %} in {% data variables.product.prodname_vs %} in the {% data variables.product.prodname_vs %} documentation.
- {% data variables.copilot.copilot_chat %} extension. See Install {% data variables.product.prodname_copilot %} in {% data variables.product.prodname_vs %} in the {% data variables.product.prodname_vs %} documentation.
{% data variables.product.prodname_vs %} 17.10 and later have the {% data variables.product.prodname_copilot %} and {% data variables.copilot.copilot_chat %} extensions built in. You don't need to install them separately.
- For {% data variables.product.prodname_vs %} 17.8 and 17.9:
-
Sign in to {% data variables.product.company_short %} in {% data variables.product.prodname_vs %}. If you experience authentication issues, see AUTOTITLE.
{% data reusables.copilot.chat-access-denied %}
You can ask {% data variables.copilot.copilot_chat_short %} to give you code suggestions, explain code, generate unit tests, and suggest code fixes.
-
In the {% data variables.product.prodname_vs %} menu bar, click View, then click {% data variables.copilot.copilot_chat %}.
-
In the {% data variables.copilot.copilot_chat_short %} window, enter a prompt, then press Enter. For example prompts, see AUTOTITLE.
-
Evaluate {% data variables.product.prodname_copilot_short %}'s response, and submit a follow up prompt if needed.
The response often includes interactive elements. For example, the response may include buttons to copy, insert, or preview the result of a code block.
To see the files that {% data variables.copilot.copilot_chat_short %} used to generate the response, click the References link below the response. The references may include a link to a custom instructions file for your repository. This file contains additional information that is automatically added to all of your chat questions to improve the quality of the responses. For more information, see AUTOTITLE.
You can use special keywords to help {% data variables.product.prodname_copilot_short %} understand your prompt.
Use slash commands to avoid writing complex prompts for common scenarios. To use a slash command, type / in the chat prompt box, followed by a command.
To see all available slash commands, type / in the chat prompt box. See also AUTOTITLE or Slash commands in the {% data variables.product.prodname_vs %} documentation.
By default, {% data variables.copilot.copilot_chat_short %} will reference the file that you have open or the code that you have selected. You can also use # followed by a file name, file name and line numbers, or solution to reference a specific file, lines, or solution.
See also AUTOTITLE or Reference in the {% data variables.product.prodname_vs %} documentation.
Using {% data variables.product.prodname_dotcom %} skills for {% data variables.product.prodname_copilot_short %} (preview)
Note
The @github chat participant is currently in preview, and only available in {% data variables.product.prodname_vs %} 2022 Preview 2 onwards.
{% data variables.product.prodname_copilot_short %}'s {% data variables.product.prodname_dotcom %}-specific skills expand the type of information {% data variables.product.prodname_copilot_short %} can provide. To access these skills in {% data variables.copilot.copilot_chat_short %} in {% data variables.product.prodname_vs %}, include @github in your question.
When you add @github to a question, {% data variables.product.prodname_copilot_short %} dynamically selects an appropriate skill, based on the content of your question. You can also explicitly ask {% data variables.copilot.copilot_chat_short %} to use a particular skill. For example, @github Search the web to find the latest GPT4 model from OpenAI.
You can generate a list of currently available skills by asking {% data variables.product.prodname_copilot_short %}: @github What skills are available?
{% data reusables.copilot.mcp.mcp-chat-in-ide %}
{% data reusables.copilot.change-the-ai-model %}
In addition to submitting prompts through the chat window, you can submit prompts inline. To start an inline chat, right click in your editor window and select Ask {% data variables.product.prodname_copilot_short %}.
See Ask questions in the inline chat view in the {% data variables.product.prodname_vs %} documentation for more details.
Note
- This feature is currently in {% data variables.release-phases.public_preview %} and subject to change.
- Available in {% data variables.product.prodname_vs %} 17.14 and later.
{% data variables.copilot.copilot_edits_short %} lets you make changes across multiple files from a single {% data variables.copilot.copilot_chat_short %} prompt
Use agent mode when you have a specific task in mind and want to enable {% data variables.product.prodname_copilot_short %} to autonomously edit your code. In agent mode, {% data variables.product.prodname_copilot_short %} determines which files to make changes to, offers code changes and terminal commands to complete the task, and iterates to remediate issues until the original task is complete.
- In the {% data variables.product.prodname_vs %} menu bar, click View, then click {% data variables.copilot.copilot_chat %}.
- At the bottom of the chat panel, select Agent from the agents dropdown.
- Submit a prompt. In response to your prompt, {% data variables.product.prodname_copilot_short %} streams the edits in the editor, updates the working set, and if necessary, suggests terminal commands to run.
- Review the changes. If {% data variables.product.prodname_copilot_short %} suggested terminal commands, confirm whether or not {% data variables.product.prodname_copilot_short %} can run them. In response, {% data variables.product.prodname_copilot_short %} iterates and performs additional actions to complete the task in your original prompt.
When you use {% data variables.copilot.copilot_agent_short %} mode, each prompt you enter counts as one premium request, multiplied by the model’s multiplier. For example, if you're using the included model—which has a multiplier of 0—your prompts won’t consume any premium requests. {% data variables.product.prodname_copilot_short %} may take several follow-up actions to complete your task, but these follow-up actions do not count toward your premium request usage. Only the prompts you enter are billed—tool calls or background steps taken by the agent are not charged.
{% data reusables.copilot.using-images-in-chat %}
-
If you see the AI model picker at the bottom right of the chat view, select one of the models that supports adding images to prompts:
-
Do one of the following:
- Copy an image and paste it into the chat view.
- Click the paperclip icon at the bottom right of the chat view, click Upload Image, browse to the image file you want to attach, select it and click Open.
You can add multiple images if required.
-
Type your prompt into the chat view to accompany the image. For example,
explain this image, ordescribe each of these images in detail.
To share feedback about {% data variables.copilot.copilot_chat_short %}, you can use the Send feedback button in {% data variables.product.prodname_vs %}. For more information on providing feedback for {% data variables.product.prodname_vs %}, see the {% data variables.product.prodname_vs %} Feedback documentation.
-
In the top right corner of the {% data variables.product.prodname_vs %} window, click the Send feedback button.
-
Choose the option that best describes your feedback.
- To report a bug, click Report a problem.
- To request a feature, click Suggest a feature.
- AUTOTITLE
- Using {% data variables.copilot.copilot_chat %} in {% data variables.product.prodname_vs %} in the Microsoft Learn documentation
- Tips to improve {% data variables.copilot.copilot_chat %} results in the Microsoft Learn documentation
- AUTOTITLE
- AUTOTITLE
- AUTOTITLE
- {% data variables.product.prodname_copilot %} Trust Center
- {% data variables.product.prodname_copilot %} FAQ
{% endvisualstudio %}
{% jetbrains %}
-
Access to {% data variables.product.prodname_copilot %}. {% data reusables.copilot.subscription-prerequisite %}
-
Compatible JetBrains IDE. {% data variables.product.prodname_copilot %} is compatible with the following IDEs:
{% data reusables.copilot.jetbrains-compatible-ides %} {% data reusables.copilot.jetbrains-plugin-prerequisites %}
{% data reusables.copilot.chat-access-denied %}
You can ask {% data variables.copilot.copilot_chat_short %} to give you code suggestions, explain code, generate unit tests, and suggest code fixes.
-
Open the {% data variables.copilot.copilot_chat_short %} window by clicking the {% data variables.copilot.copilot_chat %} icon at the right side of the JetBrains IDE window.
-
Enter a prompt in the prompt box. For example prompts, see AUTOTITLE.
-
Evaluate {% data variables.product.prodname_copilot_short %}'s response, and submit a follow up prompt if needed.
The response often includes interactive elements. For example, the response may include buttons to copy or insert a code block.
To see the files that {% data variables.copilot.copilot_chat_short %} used to generate the response, click the References link below the response. The references may include a link to a custom instructions file for your repository. This file contains additional information that is automatically added to all of your chat questions to improve the quality of the responses. For more information, see AUTOTITLE.
You can use slash commands and file references to help {% data variables.product.prodname_copilot_short %} understand your what you are asking it to do.
Use slash commands to avoid writing complex prompts for common scenarios. To use a slash command, type / in the chat prompt box, followed by a command.
To see all available slash commands, type / in the chat prompt box. See also AUTOTITLE.
By default, {% data variables.copilot.copilot_chat_short %} will reference the file that you have open or the code that you have selected. You can also tell {% data variables.copilot.copilot_chat_short %} which files to reference by dragging a file into the chat prompt box. Alternatively, you can right click on a file, select GitHub Copilot, then select Reference File in Chat.
Using {% data variables.product.prodname_dotcom %} skills for {% data variables.product.prodname_copilot_short %}
{% data reusables.copilot.using-skills %}
{% data reusables.copilot.mcp.mcp-chat-in-ide %}
{% data reusables.copilot.change-the-ai-model %}
- Built-in requests. In addition to submitting prompts through the chat window, you can submit built-in requests by right clicking in a file, selecting {% data variables.product.prodname_copilot %}, then selecting one of the options.
- Inline. You can submit a chat prompt inline, and scope it to a highlighted code block or your current file.
- To start an inline chat, right click on a code block or anywhere in your current file, hover over {% data variables.product.prodname_copilot %}, then select {% octicon "plus" aria-hidden="true" aria-label="plus" %} {% data variables.product.prodname_copilot_short %}: Inline Chat, or enter Ctrl+Shift+I.
Use {% data variables.copilot.copilot_edits_short %} to make changes across multiple files directly from a single {% data variables.copilot.copilot_chat_short %} prompt. {% data variables.copilot.copilot_edits_short %} has the following modes:
- Edit mode lets {% data variables.product.prodname_copilot_short %} make controlled edits to multiple files.
- Agent mode lets {% data variables.product.prodname_copilot_short %} autonomously accomplish a set task.
{% data reusables.copilot.copilot-edits.edit-mode-description %}
- To start an edit session, click {% octicon "copilot" aria-hidden="true" aria-label="copilot" %} {% data variables.product.prodname_copilot_short %} in the menu bar, then select Open {% data variables.copilot.copilot_chat %}.
- At the top of the chat panel, click {% data variables.copilot.copilot_edits_short %}.
- Add relevant files to the working set to indicate to {% data variables.product.prodname_copilot %} which files you want to work on. You can add all open files by clicking Add all open files or individually search for single files.
- Submit a prompt. In response to your prompt, {% data variables.copilot.copilot_edits_short %} determines which files in your working set to change and adds a short description of the change.
- Review the changes and Accept or Discard the edits for each file.
{% data reusables.copilot.copilot-edits.agent-mode-description %}
- To start an edit session using agent mode, click {% octicon "copilot" aria-hidden="true" aria-label="copilot" %} {% data variables.product.prodname_copilot_short %} in the menu bar, then select Open {% data variables.copilot.copilot_chat %}.
- At the top of the chat panel, click the Agent tab.
- Submit a prompt. In response to your prompt, {% data variables.product.prodname_copilot_short %} streams the edits in the editor, updates the working set, and if necessary, suggests terminal commands to run.
- Review the changes. If {% data variables.product.prodname_copilot_short %} suggested terminal commands, confirm whether or not {% data variables.product.prodname_copilot_short %} can run them. In response, {% data variables.product.prodname_copilot_short %} iterates and performs additional actions to complete the task in your original prompt.
{% data reusables.copilot.copilot-edits.agent-mode-requests %}
{% data reusables.copilot.subagent-intro %}
To use {% data variables.copilot.subagents_short %}, you must have {% data variables.copilot.custom_agents_short %} configured in your environment. See AUTOTITLE.
To enable {% data variables.copilot.subagents_short %}:
- Click Tools in the menu bar, then click {% data variables.product.prodname_copilot %}, then Edit Settings.
- In the popup menu, click Chat, then click the Enable {% data variables.copilot.subagent_caps_short %} checkbox.
{% data reusables.copilot.using-subagents %}
When the {% data variables.copilot.subagent_short %} completes its task, its results appear back in the main chat session, ready for follow-up questions or next steps.
{% data reusables.copilot.plan-agent-intro %}
To use plan mode:
-
If it is not already displayed, open the {% data variables.copilot.copilot_chat_short %} panel by clicking the {% data variables.copilot.copilot_chat %} icon at the right side of the JetBrains IDE window.
-
At the bottom of the {% data variables.copilot.copilot_chat_short %} panel, select Plan from the agents dropdown.
-
Type a prompt that describes a task, such as adding a feature to an existing application, refactoring code, fixing a bug, or creating an initial version of a new application.
For example:
Create a simple to-do web app with HTML, CSS, and JS files. -
Submit the prompt.
After a few moments, the plan agent outputs a plan in the chat panel. The plan provides a high-level summary and a breakdown of steps, including any open questions for clarification.
{% data reusables.copilot.plan-agent-steps %}
To share feedback about {% data variables.copilot.copilot_chat_short %}, you can use the share feedback link in JetBrains.
-
At the right side of the JetBrains IDE window, click the {% data variables.copilot.copilot_chat_short %} icon to open the {% data variables.copilot.copilot_chat_short %} window.
-
At the top of the {% data variables.copilot.copilot_chat_short %} window, click the share feedback link.
- AUTOTITLE
- AUTOTITLE
- AUTOTITLE
- AUTOTITLE
- AUTOTITLE
- {% data variables.product.prodname_copilot %} Trust Center
- {% data variables.product.prodname_copilot %} FAQ
{% endjetbrains %}
{% xcode %}
- Access to {% data variables.product.prodname_copilot %}. {% data reusables.copilot.subscription-prerequisite %}
- Latest version of the {% data variables.product.prodname_copilot %} extension. For installation instructions, see AUTOTITLE.
- Sign in to {% data variables.product.company_short %} in Xcode. If you experience authentication issues, see AUTOTITLE.
{% data reusables.copilot.chat-access-denied %}
You can ask {% data variables.copilot.copilot_chat_short %} to give you code suggestions, explain code, generate unit tests, and suggest code fixes.
-
To open the chat window, click Editor in the menu bar, then click {% data variables.product.prodname_copilot %} then Open Chat. {% data variables.copilot.copilot_chat_short %} opens in a new window.
-
Enter a prompt in the prompt box. For example prompts, see AUTOTITLE.
-
Evaluate {% data variables.product.prodname_copilot_short %}'s response, and submit a follow up prompt if needed.
The response often includes interactive elements. For example, the response may include buttons to copy or insert a code block.
To see the files that {% data variables.copilot.copilot_chat_short %} used to generate the response, click the References link below the response. The references may include a link to a custom instructions file for your repository. This file contains additional information that is automatically added to all of your chat questions to improve the quality of the responses. For more information, see AUTOTITLE.
{% data reusables.copilot.mcp.mcp-chat-in-ide %}
{% data reusables.copilot.change-the-ai-model %}
You can use special keywords to help {% data variables.product.prodname_copilot_short %} understand your prompt.
Use slash commands to avoid writing complex prompts for common scenarios. To use a slash command, type / in the chat prompt box, followed by a command.
To see all available slash commands, type / in the chat prompt box. For more information, see AUTOTITLE.
Note
Plan mode is currently in {% data variables.release-phases.public_preview %} and subject to change.
{% data reusables.copilot.plan-agent-intro %}
To use plan mode:
-
If it is not already displayed, open the {% data variables.copilot.copilot_chat_short %} window by clicking Editor in the menu bar, then clicking {% data variables.product.prodname_copilot %} then Open Chat.
-
At the bottom of the {% data variables.copilot.copilot_chat_short %} window, select Plan from the agents dropdown.
-
Type a prompt that describes a task, such as adding a feature to an existing application, refactoring code, fixing a bug, or creating an initial version of a new application.
For example:
Create a simple to-do app with Swift files. -
Submit the prompt.
After a few moments, the plan agent outputs a plan in the chat panel. The plan provides a high-level summary and a breakdown of steps, including any open questions for clarification.
{% data reusables.copilot.plan-agent-steps %}
{% data reusables.copilot.copilot-edits.agent-mode-description %}
- If it is not already displayed, open the {% data variables.copilot.copilot_chat_short %} window by clicking Editor in the menu bar, then clicking {% data variables.product.prodname_copilot %} then Open Chat.
- At the bottom of the chat panel, select Agent from the agents dropdown.
- Optionally, add relevant files to the working set view to indicate to {% data variables.product.prodname_copilot_short %} which files you want to work on.
- Submit a prompt. In response to your prompt, {% data variables.product.prodname_copilot_short %} streams the edits in the editor, updates the working set, and if necessary, suggests terminal commands to run.
- Review the changes. If {% data variables.product.prodname_copilot_short %} suggested terminal commands, confirm whether or not {% data variables.product.prodname_copilot_short %} can run them. In response, {% data variables.product.prodname_copilot_short %} iterates and performs additional actions to complete the task in your original prompt.
{% data reusables.copilot.copilot-edits.agent-mode-requests %}
{% data reusables.copilot.subagent-intro %}
To use {% data variables.copilot.subagents_short %}, you must have {% data variables.copilot.custom_agents_short %} configured in your environment. See AUTOTITLE.
- Click Editor in the menu bar, then click {% data variables.product.prodname_copilot %} then Open GitHub Copilot for Xcode Settings.
- Click Advanced in the chat panel, then under Chat Settings click the Enable {% data variables.copilot.subagents_caps_short %} toggle.
{% data reusables.copilot.using-subagents %}
When the {% data variables.copilot.subagent_short %} completes its task, its results appear back in the main chat session, ready for follow-up questions or next steps.
By default, {% data variables.copilot.copilot_chat_short %} will reference the file that you have open or the code that you have selected. To attach a specific file as reference, click {% octicon "paperclip" aria-label="Add attachments" %} in the chat prompt box.
You can open a conversation thread for each Xcode IDE to keep discussions organized across different contexts. You can also revisit previous conversations and reference past suggestions through the chat history.
To indicate whether a response was helpful, use {% octicon "thumbsup" aria-label="Thumbs up" %} or {% octicon "thumbsdown" aria-label="Thumbs down" %} that appear next to the response.
- AUTOTITLE
- AUTOTITLE
- AUTOTITLE
- AUTOTITLE
- AUTOTITLE
- {% data variables.product.prodname_copilot %} Trust Center
- {% data variables.product.prodname_copilot %} FAQ
{% endxcode %}
{% eclipse %}
{% data reusables.copilot.eclipse-prerequisites %}
- Latest version of the {% data variables.product.prodname_copilot %} extension. Download this from the Eclipse Marketplace. For more information, see AUTOTITLE.
- Sign in to {% data variables.product.company_short %} in Eclipse. If you experience authentication issues, see AUTOTITLE.
{% data reusables.copilot.chat-access-denied %}
You can ask {% data variables.copilot.copilot_chat_short %} to give you code suggestions, explain code, generate unit tests, and suggest code fixes.
-
To open the {% data variables.copilot.copilot_chat_short %} panel, click the {% data variables.product.prodname_copilot_short %} icon ({% octicon "copilot" aria-hidden="true" aria-label="copilot" %}) in the status bar at the bottom of Eclipse, then click Open Chat.
-
Enter a prompt in the prompt box, then press Enter.
For an introduction to the kinds of prompts you can use, see AUTOTITLE.
-
Evaluate {% data variables.product.prodname_copilot_short %}'s response, and make a follow up request if needed.
You can use special keywords to help {% data variables.product.prodname_copilot_short %} understand your prompt. For examples, see AUTOTITLE.
Use slash commands to avoid writing complex prompts for common scenarios. To use a slash command, type / in the chat prompt box, followed by a command. For example, use /explain to ask {% data variables.product.prodname_copilot_short %} to explain the code in the file currently displayed in the editor.
To see all available slash commands, type / in the chat prompt box.
{% data reusables.copilot.mcp.mcp-chat-in-ide %}
{% data reusables.copilot.change-the-ai-model %}
Note
Plan mode is currently in {% data variables.release-phases.public_preview %} and subject to change.
{% data reusables.copilot.plan-agent-intro %}
To use plan mode:
-
If it is not already displayed, open the {% data variables.copilot.copilot_chat_short %} panel by clicking the {% data variables.product.prodname_copilot_short %} icon ({% octicon "copilot" aria-hidden="true" aria-label="copilot" %}) in the status bar at the bottom of Eclipse, then clicking Open Chat.
-
At the bottom of the chat panel, select Plan from the agents dropdown.
-
Type a prompt that describes a task, such as adding a feature to an existing application, refactoring code, fixing a bug, or creating an initial version of a new application.
For example:
Create a simple to-do app using JavaFX. -
Submit the prompt.
After a few moments, the plan agent outputs a plan in the chat panel. The plan provides a high-level summary and a breakdown of steps, including any open questions for clarification.
{% data reusables.copilot.plan-agent-steps %}
{% data reusables.copilot.copilot-edits.agent-mode-description %}
To use agent mode:
- Open the {% data variables.copilot.copilot_chat_short %} panel by clicking the {% data variables.product.prodname_copilot_short %} icon ({% octicon "copilot" aria-hidden="true" aria-label="copilot" %}) in the status bar at the bottom of Eclipse, then clicking Open Chat.
- At the bottom of the chat panel, select Agent from the agents dropdown.
- Submit a prompt. In response to your prompt, {% data variables.product.prodname_copilot_short %} streams the edits in the editor, updates the working set, and if necessary, suggests terminal commands to run.
- Review the changes. If {% data variables.product.prodname_copilot_short %} suggested terminal commands, confirm whether or not {% data variables.product.prodname_copilot_short %} can run them. In response, {% data variables.product.prodname_copilot_short %} iterates and performs additional actions to complete the task in your original prompt.
{% data reusables.copilot.copilot-edits.agent-mode-requests %}
{% data reusables.copilot.subagent-intro %}
To use {% data variables.copilot.subagents_short %}, you must have {% data variables.copilot.custom_agents_short %} configured in your environment. See AUTOTITLE.
- Click the {% octicon "copilot" aria-hidden="true" aria-label="copilot" %} icon in the status bar.
- In the popup menu, click Edit Preferences.
- Under Chat, click the Enable sub-agent check box
{% data reusables.copilot.using-subagents %}
When the {% data variables.copilot.subagent_short %} completes its task, its results appear back in the main chat session, ready for follow-up questions or next steps.
- AUTOTITLE
- AUTOTITLE
- AUTOTITLE
- AUTOTITLE
- {% data variables.product.prodname_copilot %} Trust Center
- {% data variables.product.prodname_copilot %} FAQ
{% endeclipse %}

