Describe Copilot Data Handling and Flow
Unlock the complete study guide.
Bundled into the existing GitHub Copilot premium course — no separate purchase.
14-day money-back guarantee — no questions asked.
Included in this chapter:
- What leaves your editor, and where it goes
- Inline suggestions: the prompt around your cursor
- Copilot Chat: your message plus gathered context
- VS Code chat context and how to inspect it
- Prompt builders on other Copilot surfaces
- Inbound checks before the model runs
- Outbound checks and formatting
- Who processes the request: model hosting
- Bring Your Own Key: your provider receives the data
- Training use depends on the plan
- Feedback helps improve future suggestions
- Copilot data flow: misreadings and documented behavior
What each Copilot surface adds to your input
| Surface | Context Copilot adds to the prompt | Output it produces |
|---|---|---|
| Inline suggestions (IDE) | Code before and after the cursor, snippets from open tabs, file name and type, project structure, edit history and cursor position | A code edit proposed in the editor |
| Copilot Chat (IDE) | Open files, repository name, chat history, and in VS Code and Visual Studio an optional .github/copilot-instructions.md file | A formatted answer with code or explanations |
| Copilot Chat (GitHub.com) | Repository data stored on GitHub, chat history, and web search results when enabled | An answer that can link to files, issues or documentation |
| Pull request summary | Code diffs from the changed files | A prose overview plus a list of key changes linked to lines of code |
| Pull request text completion | Pull request title, existing description, commit titles, partial diffs, recently viewed pull request and issue titles | A prose continuation of the description |
| Commit message generation | The code changes selected for the commit | A suggested summary (title) and description |
| Windows Terminal chat | Name of the active shell and the chat history | A suggested command or an explanation of a command |
| Copilot Spaces | A relevant portion of the space's repositories, files, issues, notes, images and uploads | An answer grounded in the space's curated content |
Decision tree
Cheat sheet
Unlock with Premium — includes all practice exams and the complete study guide.
References
- https://docs.github.com/en/copilot/responsible-use/chat
- https://learn.microsoft.com/en-us/credentials/certifications/resources/study-guides/gh-300
- https://docs.github.com/en/copilot/concepts/context/content-exclusion
- https://docs.github.com/en/copilot/how-tos/manage-your-account/manage-policies
- https://docs.github.com/en/copilot/reference/ai-models/model-hosting
- https://learn.microsoft.com/en-us/training/modules/introduction-prompt-engineering-with-github-copilot/3-github-copilot-user-prompt-process-flow
- https://docs.github.com/en/copilot/responsible-use/inline-suggestions
- https://docs.github.com/en/copilot/get-started/best-practices
- https://github.com/microsoft/vscode-docs/blob/main/docs/agents/concepts/context.md
- https://docs.github.com/en/copilot/how-tos/chat-with-copilot/chat-in-ide
- https://github.com/microsoft/vscode-docs/blob/main/docs/chat/copilot-chat-context.md
- https://github.com/microsoft/vscode-docs/blob/main/docs/agents/agent-troubleshooting/chat-debug-view.md
- https://docs.github.com/en/copilot/concepts/completions/code-suggestions
- https://docs.github.com/en/copilot/get-started/plans