skills-templates/github-copilot/SKILL.md
AI-powered coding assistant providing inline suggestions, chat interface, code review, and autonomous coding agent across IDEs and GitHub.com
npx skillsauth add enuno/claude-command-and-control github-copilotInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
GitHub Copilot is an AI coding assistant that helps you write code faster with less effort, allowing you to focus more on problem-solving and collaboration. It provides real-time code suggestions, an interactive chat interface, automated code review, and autonomous coding capabilities.
| Environment | Inline Suggestions | Chat | Code Review | |-------------|-------------------|------|-------------| | VS Code | ✅ | ✅ | ✅ | | Visual Studio | ✅ | ✅ | ✅ | | JetBrains IDEs | ✅ | ✅ | ✅ | | Xcode | ✅ | ✅ | ✅ | | Eclipse | ✅ | ✅ | ✅ | | Vim/Neovim | ✅ | ❌ | ❌ | | GitHub.com | ❌ | ✅ | ✅ | | GitHub Mobile | ❌ | ✅ | ✅ | | Windows Terminal | ❌ | ✅ | ❌ |
| Feature | Free | Pro/Pro+ | Business | Enterprise | |---------|------|----------|----------|------------| | Inline suggestions | Limited | ✅ | ✅ | ✅ | | Copilot Chat | Limited | ✅ | ✅ | ✅ | | Code review | ❌ | ✅ | ✅ | ✅ | | Coding agent | ❌ | ✅ | ✅ | ✅ | | PR summaries | ❌ | ✅ | ✅ | ✅ | | Premium AI models | ❌ | ✅ | ✅ | ✅ | | Custom instructions | ❌ | ✅ | ✅ | ✅ | | Organization policies | ❌ | ❌ | ✅ | ✅ | | Audit logs | ❌ | ❌ | ✅ | ✅ |
# Install via Extensions marketplace
# Search for "GitHub Copilot" and "GitHub Copilot Chat"
# Or via command line:
code --install-extension GitHub.copilot
code --install-extension GitHub.copilot-chat
" Using vim-plug
Plug 'github/copilot.vim'
" After installation, run:
:Copilot setup
Option+Command+/ (Mac) / Ctrl+Alt+/ (Windows/Linux)Copilot analyzes your code context and generates completions that match your coding style. Suggestions appear as grayed text. Press Tab to accept.
| Action | Mac | Windows/Linux |
|--------|-----|---------------|
| Accept suggestion | Tab | Tab |
| Reject suggestion | Esc | Esc |
| Next suggestion | Option+] | Alt+] |
| Previous suggestion | Option+[ | Alt+[ |
| Accept next word | Cmd+→ | Ctrl+→ |
| Open suggestions panel | Ctrl+Enter | Ctrl+Enter |
# Write a comment describing what you want
# Copilot will suggest the implementation
# Function to calculate fibonacci sequence
def fibonacci(n):
# Copilot suggests completion here
Next edit suggestions predict where and what edits may be needed based on your ongoing changes:
github.copilot.nextEditSuggestions.enabled{
"github.copilot.nextEditSuggestions.enabled": true
}
VS Code settings.json:
{
"github.copilot.enable": {
"*": true,
"python": true,
"javascript": true,
"yaml": false,
"plaintext": false
}
}
JetBrains (github-copilot.xml):
<component name="github-copilot">
<option name="languageAllowList">
<entry key="Python" value="true" />
<entry key="JavaScript" value="true" />
<entry key="YAML" value="false" />
</option>
</component>
| IDE | Special Feature |
|-----|-----------------|
| VS Code | Next edit suggestions with gutter arrows |
| Visual Studio | Comment suggestions for C#/C++ via /// or /** |
| JetBrains | Multiple suggestions in new tabs via Cmd+Shift+A |
| Xcode | Requires disabling native predictive text |
| Eclipse | Manual trigger via Option+Command+/ |
Cmd+Shift+I (Mac) / Ctrl+Shift+I (Windows)Cmd+I (Mac) / Ctrl+I (Windows)| Mode | Description | Use Case | |------|-------------|----------| | Ask | Answer questions about code | Understanding code, learning | | Edit | Manual file selection for changes | Controlled multi-file edits | | Agent | Autonomous multi-file editing | Complex refactoring, features | | Plan | Create implementation plan first | Large changes requiring review |
Use @ to invoke specialized participants:
@workspace How is authentication implemented in this project?
@github What are the open issues labeled 'bug'?
@terminal How do I run the test suite?
@vscode How do I configure the debugger?
Common commands for quick actions:
| Command | Description |
|---------|-------------|
| /explain | Explain selected code |
| /fix | Fix problems in code |
| /tests | Generate unit tests |
| /doc | Generate documentation |
| /simplify | Simplify complex code |
| /new | Create new file/project |
| /clear | Clear chat history |
Reference specific context with #:
#file:src/auth.py Explain this authentication flow
#selection What does this code do?
#codebase Where is the user model defined?
#terminalLastCommand Why did this command fail?
Explaining Code:
User: @workspace /explain #file:src/api/routes.py
Copilot: This file defines the API routes for your application...
Generating Tests:
User: /tests Generate unit tests for the UserService class
Copilot: Here are comprehensive unit tests for UserService:
[code block with tests]
Debugging:
User: /fix This function throws a TypeError when input is None
Copilot: The issue is that you're not handling None values.
Here's the fix:
[code block with fix]
GitHub Copilot supports three types of custom instructions to guide AI behavior for your repository.
| Type | Location | Scope | Use Case |
|------|----------|-------|----------|
| Repository-wide | .github/copilot-instructions.md | All files | General coding standards |
| Path-specific | .github/instructions/*.instructions.md | Matched files | Language/framework rules |
| Agent-specific | AGENTS.md, CLAUDE.md, GEMINI.md | Model-specific | AI model customization |
Create .github/copilot-instructions.md with natural language instructions:
# Copilot Instructions for This Repository
## High-Level Details
- This is a TypeScript monorepo with React frontend and Node.js backend
- Uses pnpm for package management
- Follows clean architecture patterns
## Build Instructions
- Bootstrap: pnpm install
- Build: pnpm build
- Test: pnpm test
- Lint: pnpm lint
## Project Layout
- /apps/web - React frontend (Next.js 14)
- /apps/api - Express.js backend
- /packages/shared - Shared utilities
- /.github/workflows - CI/CD pipelines
## Code Style
- Use TypeScript strict mode
- Prefer functional components in React
- Use async/await over .then() chains
## Validation Steps
- Run pnpm typecheck before committing
- Ensure all tests pass with pnpm test
- Verify no lint errors with pnpm lint
Content Recommendations (from official docs):
Guidelines:
On GitHub.com, Copilot coding agent can generate .github/copilot-instructions.md automatically:
Create files in .github/instructions/ with frontmatter specifying glob patterns.
File naming: NAME.instructions.md
Single pattern:
---
applyTo: "**/*.ts"
---
# TypeScript Guidelines
- Use strict null checks
- Prefer interfaces over types for object shapes
- Use enums for fixed sets of values
- Document public APIs with JSDoc
Multiple patterns (comma-separated):
---
applyTo: "**/*.ts,**/*.tsx"
---
# TypeScript and React Guidelines
- Use functional components with hooks
- Prefer named exports over default
- Use React.FC for component typing
With agent exclusion:
---
applyTo: "src/api/**/*"
excludeAgent: "code-review"
---
# API Development Guidelines
These instructions apply to coding agent only, not code review.
- Use OpenAPI/Swagger annotations
- Return consistent error responses
- Include rate limiting headers
- Log all requests with correlation IDs
| Pattern | Matches |
|---------|---------|
| * | All files in current directory |
| ** or **/* | All files recursively |
| *.py | Python files in current directory |
| **/*.ts | All TypeScript files recursively |
| **/*.ts,**/*.tsx | TypeScript and TSX files |
| src/**/*.py | Python files in src recursively |
| src/api/**/* | All files in src/api recursively |
| **/subdir/**/*.py | Python files in any subdir at any depth |
| app/models/**/*.rb | Ruby files in app/models |
Use excludeAgent in frontmatter to restrict which Copilot features use the instructions:
---
applyTo: "**"
excludeAgent: "code-review"
---
| Value | Effect |
|-------|--------|
| code-review | Only coding agent uses these instructions |
| coding-agent | Only code review uses these instructions |
| (omitted) | Both coding agent and code review use instructions |
Create model-specific instruction files in repository root:
| File | Purpose |
|------|---------|
| AGENTS.md | General agent instructions (all models) |
| CLAUDE.md | Claude-specific instructions |
| GEMINI.md | Gemini-specific instructions |
Note: In VS Code, agent instructions outside workspace root are disabled by default.
Instructions combine automatically with this priority (highest to lowest):
.github/copilot-instructions.md.instructions.md filesWhen instructions conflict, higher priority wins. All applicable non-conflicting instructions combine.
VS Code:
Cmd+, / Ctrl+,)GitHub.com (Code Review):
Generate summaries for pull request descriptions:
Important: Start with a blank description - Copilot doesn't consider existing content.
Availability: Requires Pro, Business, or Enterprise plan (not in Free).
Copilot can suggest commit messages based on staged changes:
VS Code:
JetBrains:
Visual Studio:
# Copilot suggests:
- Use `const` instead of `let` for immutable values
- Add error handling for network requests
- Extract repeated logic into utility function
# You can:
1. Apply individual suggestions with one click
2. Batch multiple suggestions into single commit
3. Dismiss suggestions you don't agree with
Add to .github/copilot-instructions.md:
## Code Review Focus
When reviewing code, prioritize:
1. Security vulnerabilities (SQL injection, XSS)
2. Performance bottlenecks
3. Error handling completeness
4. API contract compliance
5. Test coverage gaps
The Copilot coding agent can autonomously implement features from issues to pull requests.
Control which repositories the coding agent can access:
| Setting | Description | |---------|-------------| | No repositories | Completely disabled | | All repositories | Enabled everywhere | | Selected repositories | Manual repository selection |
# Write detailed issue descriptions:
## Feature: Add user profile page
### Requirements
- Display user avatar, name, and bio
- Show list of recent posts
- Include edit profile button for own profile
- Responsive design for mobile
### Technical Notes
- Use existing UserService for data
- Follow existing page layout patterns
- Add unit tests for new components
### Acceptance Criteria
- [ ] Profile page renders correctly
- [ ] Edit button only shows for own profile
- [ ] Mobile responsive
- [ ] Tests pass
Control whether Copilot suggests code matching public repositories:
Note: Enterprise Cloud members cannot independently configure this - inherits from organization.
Choose whether GitHub collects prompts and suggestions:
Enable additional AI model options:
| Model | Default | Configurable | |-------|---------|--------------| | GPT-4 | ✅ Enabled | N/A | | Claude | ❌ Disabled | ✅ Yes | | Gemini | ❌ Disabled | ✅ Yes |
Copilot Chat can use Bing for current events:
Model Context Protocol (MCP) is an open standard for connecting AI models with external tools and data sources.
Install and configure the GitHub MCP server:
// VS Code settings.json
{
"github.copilot.chat.mcp.servers": {
"github": {
"command": "npx",
"args": ["-y", "@anthropic/github-mcp-server"],
"env": {
"GITHUB_TOKEN": "${env:GITHUB_TOKEN}"
}
}
}
}
| Toolset | Capabilities |
|---------|--------------|
| repos | Repository operations |
| issues | Issue management |
| pulls | Pull request operations |
| code_security | Security scanning |
| experiments | Experimental features |
User: @github Create an issue for the login bug
Copilot: [Uses MCP to create issue]
Issue #123 created: "Fix login redirect loop"
Inline Suggestions Excel At:
Chat Interface Works Best For:
Be Specific
❌ Write a function
✅ Write a TypeScript function that validates email addresses using regex
Provide Context
❌ Fix this code
✅ Fix the null pointer error on line 45 when user.profile is undefined
Include Examples
Write a function that formats dates
Input: "2024-01-15"
Output: "January 15, 2024"
Break Down Complex Tasks
Instead of: "Build a user authentication system"
Ask step by step:
1. Create user model with email and password hash
2. Add registration endpoint with validation
3. Add login endpoint with JWT generation
4. Add middleware for protected routes
Specify Constraints
Write a sorting function that:
- Handles null values gracefully
- Works with arrays up to 10,000 items
- Maintains stable sort order
Act as a senior security engineer and review this authentication code
for vulnerabilities:
[paste code]
Focus on:
- Input validation
- Token handling
- Session management
- OWASP Top 10 risks
Optimize Response Quality:
Iterative Refinement:
Before accepting suggestions:
{
// Enable/disable Copilot
"github.copilot.enable": {
"*": true
},
// Enable next edit suggestions (preview)
"github.copilot.nextEditSuggestions.enabled": true,
// Custom instructions file
"github.copilot.chat.codeGeneration.useInstructionFiles": true,
// Inline suggestions behavior
"github.copilot.inlineSuggest.enable": true,
// Chat settings
"github.copilot.chat.localeOverride": "en"
}
Navigate to Settings → Tools → GitHub Copilot:
VS Code:
{
"github.copilot.enable": {
"*.env": false,
"*.pem": false,
"*.key": false
}
}
gitignore-style exclusion:
Create .github/copilot-ignore:
# Exclude sensitive files
*.env
secrets/
credentials.json
/clearIf receiving fewer suggestions than expected:
GitHub's ESSP provides a structured approach to measuring Copilot's impact on engineering teams using the SPACE framework:
| SPACE Dimension | Copilot Metrics | |-----------------|-----------------| | Satisfaction | Copilot satisfaction score (1-5 survey), tooling satisfaction | | Performance | Code quality, security maintainability scores | | Activity | PRs merged per developer, suggestion acceptance rates | | Communication | PR review turnaround, collaboration patterns | | Efficiency | Lead time reduction, AI leverage percentage |
Measure developer satisfaction with Copilot through periodic surveys:
Survey Question: "How satisfied are you with GitHub Copilot?"
| Score | Interpretation | |-------|----------------| | 5 | Extremely satisfied - Core part of workflow | | 4 | Satisfied - Regular productive use | | 3 | Neutral - Occasional use | | 2 | Dissatisfied - Limited value | | 1 | Very dissatisfied - Not using |
Measurement Guidelines:
Calculate the ROI of Copilot investment:
AI Leverage = (Time Savings × Staff Salary) / AI Costs × 100
Example Calculation:
Time saved per developer: 10 hours/week
Team size: 50 developers
Average hourly rate: $75
Copilot cost per seat: $19/month
Weekly savings: 10 × 50 × $75 = $37,500
Monthly savings: $37,500 × 4 = $150,000
Monthly cost: 50 × $19 = $950
AI Leverage = ($150,000 / $950) × 100 = 15,789%
Data Collection:
Track Copilot's impact across these key areas:
| Zone | Metrics | Copilot Impact | |------|---------|----------------| | Quality | Change failure rate, code security score | Catches bugs early, security scanning | | Velocity | Lead time, deployment frequency | Faster code writing, reduced review time | | Developer Happiness | Satisfaction scores, flow state | Reduces toil, automates boring tasks | | Business Outcomes | Feature delivery, revenue impact | Faster time-to-market |
Leading Indicators (Early signals):
Lagging Indicators (Outcomes):
Phased Rollout Strategy:
| Phase | Duration | Scope | Success Criteria | |-------|----------|-------|------------------| | Pilot | 4-6 weeks | 1-2 teams (20-50 devs) | 70%+ satisfaction, measurable time savings | | Expansion | 8-12 weeks | 5-10 teams | Consistent metrics across teams | | Full rollout | Ongoing | Organization-wide | Established baselines, continuous improvement |
Success Factors:
Copilot helps teams overcome common engineering antipatterns:
Problem: Large, infrequent releases increase risk and complexity.
Copilot Solutions:
User: Help me add a feature flag for the new checkout flow
Copilot: [Generates feature flag implementation with gradual rollout support]
Problem: Adding unnecessary features beyond requirements.
Copilot Solutions:
User: Review this PR for scope creep. Requirements: [paste requirements]
Copilot: [Identifies code that goes beyond stated requirements]
Problem: Overly complex solutions for simple problems.
Copilot Solutions:
/simplify command on complex codeUser: /simplify This seems overengineered for just caching API responses
Copilot: [Suggests simpler caching approach without unnecessary abstractions]
Problem: Shortcuts that degrade maintainability over time.
Copilot Solutions:
User: Analyze this file for technical debt and suggest improvements
Copilot: [Lists debt items with prioritized refactoring suggestions]
Problem: Insufficient test coverage leading to fragile code.
Copilot Solutions:
/testsUser: /tests Generate comprehensive tests for UserService including edge cases
Copilot: [Creates tests covering happy path, errors, edge cases, and boundary conditions]
Problem: Manual or slow deployment processes.
Copilot Solutions:
User: Create a GitHub Actions workflow for deploying to AWS ECS with staging and production environments
Copilot: [Generates complete CI/CD workflow with environment promotion]
GitHub reports these internal use cases for Copilot:
| Use Case | Impact | |----------|--------| | Test creation | Faster test writing, better coverage | | Code refactoring | Cleaner, more maintainable code | | GitHub Actions workflows | Automated CI/CD setup | | Documentation | API docs, code comments | | Code explanation | Onboarding, knowledge sharing | | Debugging assistance | Faster issue resolution |
tools
MemPalace local-first AI memory system. Use when setting up persistent memory for Claude Code sessions, mining project files or conversation transcripts, querying past context, configuring MCP tools, managing the knowledge graph, or troubleshooting palace operations.
tools
LangSmith Python SDK — trace, evaluate, and monitor LLM applications. Covers @traceable decorator, trace context manager, Client API, evaluate() / aevaluate(), comparative evaluation, custom evaluators, dataset management, prompt caching, ASGI middleware, and pytest plugin.
development
LangGraph (Python) — build stateful, controllable agent graphs with checkpointing, streaming, persistence, interrupts, fault tolerance, and durable execution. Covers both Graph API (StateGraph) and Functional API (@entrypoint/@task).
development
LangGraph Graph API (Python) — build explicit DAG agent workflows with StateGraph, typed state, nodes, edges, Command routing, Send fan-out, checkpointers, interrupts, and streaming. Use when you need explicit control flow and graph topology.