Try each technique during the workshop. Click to mark them off. Get a line of five — horizontal, vertical, or diagonal — to win!
How to play: Click a square when you've tried that technique during the workshop. The free space is already marked. Get five in a row (horizontal, vertical, or diagonal) to call Bingo. For the ultimate challenge, try to fill the whole card.
Single, Specific, Short, Surround — the foundation for every good Copilot prompt.
One well-defined task per prompt. Decompose complex requests into atomic tasks.
"Add OAuth, write tests, update README"
"Add OAuth2 login using passport for Express"
Name exact libraries, versions, and patterns. Explicit constraints drive precision.
"Connect to the database"
"Create a PostgreSQL 16 pool via pg-pool, SSL on"
Bullet points over paragraphs. Concise input = focused output. Protect the context window.
"I need a function that filters users by age, sorts by name, limits..."
"Filter users: age > 25, sort name, limit 10"
Copilot reads your active file + open tabs. Open relevant files, close irrelevant ones.
Only target file open — Copilot guesses types
types.ts + config.ts + target.ts all open
| Pattern | Description |
|---|---|
| Zero-shot | No examples — rely on the model's training data |
| One-shot | One example to guide output format and style |
| Few-shot | Multiple examples for maximum precision |
| Role prompt | Assign an expert persona: "Act as a Senior Security Engineer" |
| Chain of thought | Ask for step-by-step reasoning before the answer |
Every command, participant, and context variable at your fingertips.
| Command | Description |
|---|---|
| /explain | Explain how selected code works |
| /fix | Get suggested fixes for problems in code |
| /tests | Generate unit tests for the current code |
| /doc | Add documentation comments to code |
| /new | Scaffold a new project or file |
| /clear | Wipe chat context and start fresh |
| /help | Show available commands and tips |
| /compact | Trim noisy context from the conversation |
| /run | Execute terminal commands directly |
| Participant | Context Provided |
|---|---|
| @workspace | Full project context — files, structure, dependencies |
| @vscode | VS Code commands, settings, and features |
| @terminal | Terminal shell context, recent output |
| @github | Search repos, query GHAS alerts, PR context |
| Variable | What It Includes |
|---|---|
| #file | Include a specific file's content |
| #selection | Currently selected text in editor |
| #block | Current code block around cursor |
| #function | Current function or method |
| #codebase | Broad codebase search across project |
| #git | Git history and recent changes |
| #editor | Visible editor content |
| #fetch | Remote URL or repo content |
@workspace /fix #selection — Fix selected code with full project context @terminal How can I test these changes? /doc #function — Document the current function /tests #file — Generate tests for a specific file
Tip: Type / or # or @ to see all available options. Ctrl+Enter auto-inserts @workspace. Slash commands are clearer than natural language for intent.
| Flag | Purpose |
|---|---|
| --yes / -y | Skip confirmation prompts for automation |
| --json <fields> | Machine-readable JSON output |
| --jq <expr> | Filter JSON output with jq syntax |
| gh variable set | Set non-sensitive configuration variables |
| gh attestation verify | Supply chain verification of artifacts |
Muscle memory for speed. Organised by IDE.
| Ctrl+Alt+I | Open Chat view |
| Ctrl+I | Inline Chat (in editor) |
| Ctrl+N | New chat session |
| Ctrl+L | Clear chat |
| Ctrl+Shift+I | Toggle Copilot panel |
| Tab | Accept suggestion |
| Esc | Dismiss suggestion |
| Alt+] | Next suggestion |
| Alt+[ | Previous suggestion |
| Ctrl+→ | Accept word-by-word |
| Ctrl+Enter | Open completions panel |
Next Edit Suggestions predicts your next likely edit location and jumps you there. Press Tab to accept and continue the flow. Available in VS Code and Visual Studio. Think of it as Copilot anticipating where you need to go next, not just what to type.
The brain of your repo. Stores configs for automation, project management, and how Copilot behaves in your codebase.
.github/ ├── copilot-instructions.md ← Global AI rules for the whole repo ├── prompts/ ← Reusable prompt files (.prompt.md) │ ├── refactor-to-ts.prompt.md │ └── add-tests.prompt.md ├── skills/ ← Operational AI workflows (DevOps, SRE) │ └── deploy-checker/ │ └── SKILL.md ├── workflows/ ← CI/CD pipelines (.yml) │ ├── ci.yml │ └── deploy.yml ├── ISSUE_TEMPLATE/ ← Structured issue forms ├── PULL_REQUEST_TEMPLATE.md ← PR checklist template └── agents/ ← Specialised autonomous AI entities
| Type | Purpose | When It Runs | Use Case |
|---|---|---|---|
| Instructions | Standardise AI behaviour | Always active (passive) | Naming conventions, coding style |
| Prompts | Reusable AI scripts | On demand (invoked) | Specific refactoring tasks |
| Skills | Operational AI workflows | On demand (complex) | DevOps, infrastructure management |
| Workflows | CI/CD automation | On events (push, PR) | Testing, building, deploying |
| Agents | Autonomous task execution | Assigned or triggered | Complex problem-solving |
| Templates | Standardise contributions | On create (issue/PR) | Consistent issue/PR structure |
Start here: The single most impactful file is .github/copilot-instructions.md. It influences every Copilot suggestion without running anything. Add your coding standards, architecture constraints, and naming conventions. See the AI-SDLC site for a starter template.
Autonomous AI pair programming and the Model Context Protocol.
{
"mcpServers": {
"github": {
"command": "npx",
"args": ["@github/mcp"],
"type": "stdio"
},
"postgres": {
"command": "npx",
"args": [
"@modelcontextprotocol/server-postgres",
"${input:pg_url}"
],
"type": "stdio"
},
"sentry": {
"command": "npx",
"args": ["@sentry/mcp"],
"type": "stdio"
}
}
}
| Surface | Agent Mode | MCP | Status |
|---|---|---|---|
| VS Code | ✅ | ✅ | GA |
| JetBrains | ✅ | ✅ | GA |
| Visual Studio | ✅ | ✅ | GA (17.14+) |
| Xcode | ✅ | ✅ | Preview |
| CLI | ✅ | ✅ | GA |
| GitHub.com | Coding Agent | Built-in | GA |
Best practices: Use OAuth over PATs for MCP connections. Limit server permissions (least privilege). Audit connected servers regularly. Push protection blocks secret leaks.
Expression syntax, triggers, secrets, and workflow templates.
| Expression | Purpose |
|---|---|
| ${{ secrets.NAME }} | Repo or environment secrets |
| ${{ env.VAR }} | Workflow-level env vars |
| ${{ vars.CONFIG }} | Repository config variables |
| ${{ github.event_name }} | Trigger context |
| Trigger | When |
|---|---|
| push: | On push to branches/tags |
| pull_request: | PR events (open, sync) |
| workflow_dispatch: | Manual trigger |
| schedule: | Cron-based scheduling |
| release: | On published release |
| workflow_call: | Reusable workflow invocation |
on: [push, pull_request] permissions: contents: read concurrency: group: ${{ github.workflow }}-${{ github.ref }} jobs: build: runs-on: ubuntu-latest timeout-minutes: 15 steps: - uses: actions/checkout@v4 - run: npm ci - run: npm test
| contains() | String/array match |
| startsWith() | Prefix check |
| format() | String interpolation |
| toJSON() | Debug context objects |
| hashFiles() | Cache key generation |
| success() failure() | Status checks |
GitHub Flavored Markdown essentials, from basics to Mermaid diagrams.
| # ## ### | Headings (H1, H2, H3) |
| **bold** *italic* | Text emphasis |
| [text](url) | Hyperlink |
|  | Image |
| `code` | Inline code |
| ```lang``` | Fenced code block |
| - item | Unordered list |
| 1. item | Ordered list |
| > quote | Blockquote |
| --- | Horizontal rule |
| - [x] / - [ ] | Task lists (checkboxes) |
| | H1 | H2 | | Tables with pipe syntax |
| #123 | Auto-links to issues |
| @username | Mentions |
| :emoji: | Emoji shortcodes |
| ~~strike~~ | Strikethrough |
| ```mermaid | Mermaid diagrams |
| $e=mc^2$ | LaTeX math (inline) |
> [!NOTE] — Informational callout > [!TIP] — Helpful suggestion > [!IMPORTANT] — Key information > [!WARNING] — Potential issue > [!CAUTION] — Dangerous action