Skip to content

Domain 2: Use GitHub Copilot Features (25โ€“30%) โ€‹

โ† Domain 1 ยท Next Domain โ†’

Exam Tip

Domain 2 is the largest domain. Know every interaction mode (inline, chat, CLI, Agent Mode, Edit Mode), what each is used for, and the difference between Copilot Individual, Business, and Enterprise plans.


Copilot in the IDE โ€‹

Inline Suggestions โ€‹

  • Trigger: Automatically as you type code, comments, or function signatures
  • Accept: Tab key (full suggestion) or โ†’ (word-by-word)
  • Dismiss: Esc
  • Cycle alternatives: Alt+] / Alt+[
  • Context comes from: open files in the editor, file type, cursor position, comments

Copilot Chat (IDE) โ€‹

  • Conversational AI in the IDE sidebar or inline
  • Ask questions about code, request refactors, generate tests, explain errors
  • @workspace: Searches across your entire project
  • @file: References a specific file
  • /explain: Explains selected code
  • /fix: Suggests a fix for a problem
  • /tests: Generates unit tests for selected code
  • /doc: Generates documentation

Plan Mode โ€‹

  • Shows Copilot's intended approach before making changes
  • Lets you review and approve the plan before execution
  • Useful for complex refactors or multi-step operations

File Exclusions in IDE โ€‹

  • Admins (Copilot Business/Enterprise) configure content exclusions
  • When a file is excluded: Copilot won't suggest from it or use it as context
  • Can be set at the org level or per-repo via settings

GitHub Copilot CLI โ€‹

GitHub Copilot CLI brings AI assistance to the terminal.

Installation โ€‹

bash
gh extension install github/gh-copilot
gh copilot --help

Key Commands โ€‹

CommandWhat it does
gh copilot suggest "how to list files modified in last week"Generates a shell command suggestion
gh copilot explain "find . -name '*.log' -mtime +7 -delete"Explains what a shell command does

Interactive vs Session Mode โ€‹

  • Interactive: Single-turn questions and suggestions
  • Session mode: Multi-turn conversation to refine commands

Generating Scripts โ€‹

  • Use gh copilot suggest to draft shell scripts from natural language descriptions
  • Always review before running โ€” same validation rules as IDE suggestions apply

GitHub Copilot Features and Capabilities โ€‹

Agent Mode โ€‹

  • Copilot acts autonomously to complete multi-step tasks
  • Can read/write files, run terminal commands, and iterate on its own output
  • Sub-Agents: Delegate sub-tasks (e.g., running tests, fixing lint errors) to specialized agents
  • Best for: complex refactors, scaffolding new features, automating repetitive workflows
  • Agent Sessions: Persistent context across an autonomous working session

Trap

Agent Mode can run terminal commands autonomously. Always review what it plans to do in Plan Mode before allowing execution.

Edit Mode โ€‹

  • Copilot proposes cross-file edits based on your request
  • You review each change and selectively accept or reject
  • Unlike Agent Mode, Edit Mode doesn't run commands โ€” it's edit-only
  • Best for: targeted refactors, renaming, updating an interface across files

MCP (Model Context Protocol) โ€‹

  • Connects Copilot to external services and data sources at runtime
  • Examples: connect to a database schema, an API specification, a project management tool
  • Provides grounding without requiring you to copy-paste context manually

Copilot Spaces โ€‹

  • Persistent shared workspaces for collaborative AI interactions
  • Team members can share context, prompts, and Copilot conversations

Copilot Spark โ€‹

  • AI-powered feature for non-developer users to build simple apps and scripts
  • Natural language to working app, with no code required

Pull Request Summaries โ€‹

  • Copilot automatically generates a PR description based on the diff
  • Configurable with custom instructions via review standards files

Code Review with Copilot โ€‹

  • Copilot can act as a code reviewer, flagging issues in PRs
  • Can suggest specific line-level improvements
  • Enable via: Org Settings โ†’ Copilot โ†’ Code Review

Copilot Plans Comparison โ€‹

FeatureIndividualBusinessEnterprise
IDE suggestions & chatโœ…โœ…โœ…
CLIโœ…โœ…โœ…
Org-wide policy managementโŒโœ…โœ…
Content exclusionsโŒโœ…โœ…
Audit log eventsโŒโœ…โœ…
Knowledge BasesโŒโŒโœ…
Copilot Chat on GitHub.comโŒโŒโœ…
Custom fine-tuned modelsโŒโŒโœ…
PR summariesโŒโœ…โœ…

Managing Organization-Wide Settings โ€‹

Available in Copilot Business and Enterprise plans only.

Policy Management โ€‹

  • Configure which Copilot features are available (suggestions, chat, CLI, PR summaries, code review)
  • Restrict which IDEs can use Copilot
  • Enable or disable features per org or per repo

Audit Log Events โ€‹

  • Track who used Copilot, what features they accessed, and when
  • Available via: Org Settings โ†’ Audit log โ†’ filter by copilot
  • Streamable to a SIEM for compliance reporting
  • Common audit events: copilot.suggestion_accepted, copilot.chat_message_sent

Managing Subscriptions via REST API โ€‹

GET /orgs/{org}/copilot/billing
GET /orgs/{org}/copilot/billing/seats
POST /orgs/{org}/copilot/billing/selected_users
DELETE /orgs/{org}/copilot/billing/selected_users

Domain 2 Quick Quiz

1 / 5
โ“

What is the difference between Agent Mode and Edit Mode?

(Click to reveal)
๐Ÿ’ก
Agent Mode: autonomous, can run terminal commands, multi-step tasks. Edit Mode: proposes cross-file edits only, you review and accept each change individually.

โ† Domain 1 ยท Next Domain โ†’

Happy Studying! ๐Ÿš€ โ€ข Privacy-friendly analytics โ€” no cookies, no personal data
Privacy Policy โ€ข AI Disclaimer โ€ข Report an issue