Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ ai-usage: ai-assisted

# Best practices for GitHub Copilot modernization

Follow these guidelines to get the best results from GitHub Copilot modernization when upgrading and migrating .NET projects.
Follow these guidelines to get the best results from GitHub Copilot modernization when upgrading .NET projects.

## Before you start

Expand Down Expand Up @@ -77,7 +77,7 @@ The assessment is your best opportunity to catch issues before the agent starts
- Dependencies that you know are problematic.
- Anything unusual about your solution that the agent should know.

If you spot something, tell the agent in chat or add the information to `scenario-instructions.md`. You can also edit `assessment.md` directly to add context, correct misidentified projects, or flag concerns before the agent proceeds to planning.
If you spot something, tell the agent in chat or add the information to `scenario-instructions.md`. Edit `assessment.md` directly to add context, correct misidentified projects, or flag concerns before the agent proceeds to planning.

### Take time with the planning stage

Expand Down Expand Up @@ -107,7 +107,7 @@ Execution isn't hands-off. Before telling the agent to start, review `tasks.md`:
- Are there tasks you want to skip or resequence?
- Are any tasks missing?

Ask the agent to adjust the task list, or edit `tasks.md` directly before execution begins. Once execution starts, if the agent makes a bad call mid-task, tell it immediatelyit applies your correction going forward.
Ask the agent to adjust the task list, or edit `tasks.md` directly before execution begins. Once execution starts, if the agent makes a bad call mid-task, tell it immediatelyit applies your correction going forward.

You know your codebase better than the agent, so use that knowledge at every stage.

Expand Down Expand Up @@ -143,7 +143,7 @@ The more specific you are, the better the agent performs:
|---|---|
| _"Upgrade everything"_ | _"Upgrade the Data.Access project to .NET 10"_ |
| _"Fix the build"_ | _"Fix the build error in CustomerService.cs related to the removed API"_ |
| _"Migrate the database stuff"_ | _"Migrate Entity Framework 6 to EF Core in the Repository project"_ |
| _"Upgrade the database stuff"_ | _"Upgrade Entity Framework 6 to EF Core in the Repository project"_ |

### Share your constraints

Expand Down
16 changes: 8 additions & 8 deletions docs/core/porting/github-copilot-app-modernization/concepts.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ ai-usage: ai-assisted

# GitHub Copilot modernization concepts

GitHub Copilot modernization uses a structured approach to upgrade and migrate .NET projects. Understanding how the agent works, including its scenarios, skills, tasks, and workflow, helps you collaborate with the agent effectively and get the best results.
GitHub Copilot modernization uses a structured approach to upgrade .NET projects. Understanding how the agent works, including its scenarios, skills, tasks, and workflow, helps you collaborate with the agent effectively and get the best results.

> [!TIP]
> Think of the agent as a skilled colleague who understands .NET deeply, follows a structured plan, and adapts to your feedback. The more context you give, the better the agent performs.
Expand All @@ -20,7 +20,7 @@ GitHub Copilot modernization uses a structured approach to upgrade and migrate .

The agent excels at collaboration, not automation in a vacuum:

- **Deep .NET knowledge:** The agent understands project files, NuGet dependencies, breaking changes, and migration patterns across dozens of .NET technologies for both C# and Visual Basic projects.
- **Deep .NET knowledge:** The agent understands project files, NuGet dependencies, breaking changes, and upgrade patterns across dozens of .NET technologies for both C# and Visual Basic projects.
- **Structured workflow:** Every upgrade goes through assessment, planning, and execution. No random changes, no surprises.
- **Learns your preferences:** When you say "always use explicit types instead of `var`," the agent writes that preference to `scenario-instructions.md` and remembers it across sessions.
- **Correctable mid-flight:** Made a wrong call? Tell the agent. It adapts and applies the correction going forward.
Expand Down Expand Up @@ -76,8 +76,8 @@ Based on the assessment, the agent evaluates your solution and identifies which
Options might include:

- **Upgrade strategy:** Bottom-up, top-down, or all-at-once.
- **Project migration approach:** In-place rewrite or side-by-side for web applications; in-place or multi-targeting for libraries.
- **Technology modernization:** Choices for Entity Framework migration, dependency injection, logging, and configuration.
- **Project upgrade approach:** In-place rewrite or side-by-side for web applications; in-place or multi-targeting for libraries.
- **Technology modernization:** Choices for Entity Framework upgrade, dependency injection, logging, and configuration.
- **Package management:** Whether and when to adopt Central Package Management.
- **Compatibility handling:** How to address unsupported APIs and packages.

Expand Down Expand Up @@ -108,15 +108,15 @@ During the assessment stage, the agent evaluates your solution and recommends on
| **All-at-once** | Small, simple solutions | Upgrade everything in one pass. |

> [!TIP]
> The agent only surfaces decisions that are relevant to your project. A simple console app doesn't see web framework choices, and a project without Entity Framework doesn't see database migration options.
> The agent only surfaces decisions that are relevant to your project. A simple console app doesn't see web framework choices, and a project without Entity Framework doesn't see database upgrade options.

## Skills

_Skills_ are smaller, targeted modernization capabilities. When the agent encounters EF6 code during an upgrade, it loads the EF6-to-EF-Core skill with detailed, step-by-step migration instructions. Invoke a skill directly during an upgrade: _"migrate the WCF services in my project to CoreWCF."_
_Skills_ are smaller, targeted modernization capabilities. When the agent encounters EF6 code during an upgrade, it loads the EF6-to-EF-Core skill with detailed, step-by-step upgrade instructions. Invoke a skill directly during an upgrade: _"upgrade the WCF services in my project to CoreWCF."_

The agent ships with 30+ built-in skills organized by domain:

- **Data access:** EF6 to EF Core (code-first and EDMX), LINQ to SQL, and SqlClient migration
- **Data access:** EF6 to EF Core (code-first and EDMX), LINQ to SQL, and SqlClient upgrade
- **Web/ASP.NET:** Identity, Global.asax, OWIN, MVC routing/filters/bundling, and WCF to CoreWCF
- **Serialization:** Newtonsoft.Json to System.Text.Json
- **Cloud:** Azure Functions in-process to isolated worker model
Expand All @@ -128,7 +128,7 @@ For the complete list, see [Scenarios and skills reference](scenarios-and-skills

## Tasks

_Tasks_ are the atomic units of work within a scenario. Each task represents a specific, bounded piece of the upgrade, such as "Upgrade CommonLib from .NET 6 to .NET 10" or "Migrate EF6 usage in DataLayer to EF Core."
_Tasks_ are the atomic units of work within a scenario. Each task represents a specific, bounded piece of the upgrade, such as "Upgrade CommonLib from .NET 6 to .NET 10" or "Upgrade EF6 usage in DataLayer to EF Core."

### Task lifecycle

Expand Down
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
---
title: Customize GitHub Copilot modernization
description: "Learn how to customize GitHub Copilot modernization with custom skills, custom scenarios, scenario artifact edits, and chat instructions to encode your team's migration patterns."
description: "Learn how to customize GitHub Copilot modernization with custom skills, custom scenarios, scenario artifact edits, and chat instructions to encode your team's upgrade patterns."
ms.topic: concept-article
ms.date: 04/06/2026
ai-usage: ai-assisted

#customer intent: As a developer, I want to customize GitHub Copilot modernization so that I can encode my team's migration patterns, enforce coding standards during upgrades, and define custom upgrade workflows.
#customer intent: As a developer, I want to customize GitHub Copilot modernization so that I can encode my team's upgrade patterns, enforce coding standards during upgrades, and define custom upgrade workflows.

---

# Customize GitHub Copilot modernization

GitHub Copilot modernization is extensible. The agent provides multiple customization points to encode your team's migration patterns, enforce coding standards during upgrades, and define new upgrade workflows.
GitHub Copilot modernization is extensible. The agent provides multiple customization points to encode your team's upgrade patterns, enforce coding standards during upgrades, and define new upgrade workflows.

## Customization points overview

Expand Down Expand Up @@ -101,13 +101,13 @@ Each task in `tasks/{taskId}/task.md` contains the task specification and workin

## Create custom skills

Skills are the primary extension point for the agent. A skill is a Markdown file with a metadata header that teaches the agent how to handle a specific migration, pattern, or task.
Skills are the primary extension point for the agent. A skill is a Markdown file with a metadata header that teaches the agent how to handle a specific upgrade, pattern, or task.

### Where to place custom skills

| Location | Scope | Use when |
|---|---|---|
| `.github/skills/my-skill.md` | Repository (shared with team) | Team-wide migration patterns |
| `.github/skills/my-skill.md` | Repository (shared with team) | Team-wide upgrade patterns |
| `.github/upgrades/skills/my-skill.md` | Repository (upgrade-specific) | Skills specific to upgrade scenarios |
| `%UserProfile%/.copilot/skills/my-skill.md` | User profile (personal, all repos) | Personal preferences and patterns |

Expand Down Expand Up @@ -181,7 +181,7 @@ equivalents, updating configuration, and verifying behavior.

| Field | Required | Description |
|---|---|---|
| `name` | Yes | Unique identifier in kebab-case. Start with a gerund verb (for example, `migrating-`, `converting-`). Maximum 64 characters. |
| `name` | Yes | Unique identifier in kebab-case. Start with a gerund verb (for example, `upgrading-`, `converting-`). Maximum 64 characters. |
| `description` | Yes | Determines when the agent loads the skill. Include trigger phrases, such as words and patterns that should activate the skill. |
| `metadata.discovery` | No | Controls when the skill loads: `preload` (always available), `lazy` (on-demand when description matches, default and recommended), or `scenario` (defines a workflow orchestrator). |
| `metadata.traits` | No | Keywords describing the technologies in your project, such as `.NET`, `CSharp`, `VisualBasic`, or `DotNetCore`. |
Expand All @@ -192,8 +192,8 @@ equivalents, updating configuration, and verifying behavior.
- **Include clear, step-by-step workflows:** Number the steps. Be explicit about what files to change and what commands to run.
- **Include success criteria:** Without success criteria, the agent doesn't know when to stop. Use checkboxes or a clear list of verifiable conditions.
- **Include error handling:** Anticipate common failure modes, such as missing packages, build failures, or broken tests.
- **Keep skills focused:** One skill per migration or task type. A skill for "migrating FooBar v2 to v3" is better than "migrating all internal libraries."
- **Name with a gerund verb:** Use `migrating-foobar-v2-to-v3`, not `foobar-migration` or `foobar-v3`.
- **Keep skills focused:** One skill per upgrade or task type. A skill for "upgrading FooBar v2 to v3" is better than "upgrading all internal libraries."
- **Name with a gerund verb:** Use `upgrading-foobar-v2-to-v3`, not `foobar-upgrade` or `foobar-v3`.
- **Use `lazy` discovery:** Use `lazy` discovery for most custom skills to avoid bloating the agent's context window.

## Create custom scenarios
Expand Down
14 changes: 7 additions & 7 deletions docs/core/porting/github-copilot-app-modernization/faq.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ sections:
questions:
- question: What can the agent do?
answer: |
GitHub Copilot modernization helps you upgrade your .NET (.NET, .NET Core, and .NET Framework) projects to newer versions of .NET. It also helps migrate services to Azure, upgrades dependencies, and fixes errors in code after migration. The agent performs the following steps in a Copilot chat session:
GitHub Copilot modernization helps you upgrade your .NET (.NET, .NET Core, and .NET Framework) projects to newer versions of .NET. It also helps modernize services for Azure, upgrades dependencies, and fixes errors in code after the upgrade. The agent performs the following steps in a Copilot chat session:

- Analyzes your projects and proposes a modernization plan.
- Runs a series of tasks to modernize your projects according to the plan.
Expand All @@ -39,7 +39,7 @@ sections:
- question: What limitations are there?
answer: |
- The agent requires a local Git repository.
- The upgrade or migration suggestions aren't guaranteed to follow best practices.
- The upgrade suggestions aren't guaranteed to follow best practices.
- Code fixes and corrections you provide to Copilot during the upgrade process don't persist and aren't remembered for future upgrades.

- question: Which model should I use?
Expand All @@ -58,14 +58,14 @@ sections:

- question: Does the agent store my source code?
answer: |
The agent never stores your codebase or uses your code to train the model. Once an upgrade or migration completes, the agent deletes session data.
The agent never stores your codebase or uses your code to train the model. Once an upgrade completes, the agent deletes session data.

- question: Can I provide feedback?
answer: |
Yes! There are two ways to provide feedback:

- In Visual Studio, use the [Suggest a feature](/visualstudio/ide/suggest-a-feature) and [Report a Problem](/visualstudio/ide/report-a-problem) features.
- File an issue at the [@modernize-dotnet GitHub repository](https://github.com/dotnet/modernize-dotnet).
- File an issue at the [modernize-dotnet GitHub repository](https://github.com/dotnet/modernize-dotnet).

- question: What data is collected?
answer: |
Expand All @@ -79,7 +79,7 @@ sections:
questions:
- question: What can the agent upgrade?
answer: |
GitHub Copilot modernization helps you upgrade your .NET projects or migrate them to Azure. The agent supports multiple scenarios beyond framework upgrades, including Aspire integration, SDK-style conversion, Newtonsoft.Json migration, SqlClient migration, Azure Functions upgrade, and Semantic Kernel to Agents migration. For a full reference, see [Scenarios and skills reference](scenarios-and-skills.md).
GitHub Copilot modernization helps you upgrade your .NET projects or modernize them for Azure. The agent supports multiple scenarios beyond framework upgrades, including Aspire integration, SDK-style conversion, Newtonsoft.Json upgrade, SqlClient upgrade, Azure Functions upgrade, and Semantic Kernel to Microsoft Agent Framework upgrade. For a full reference, see [Scenarios and skills reference](scenarios-and-skills.md).

The agent works with these project types:

Expand Down Expand Up @@ -132,7 +132,7 @@ sections:

The migration scenarios include:

- Modernizing databases
- Migrating databases
- Storage
- Identity
- Messaging
Expand All @@ -145,7 +145,7 @@ sections:

- question: Can I monitor assessment progress?
answer: |
Yes. Monitor the assessment progress through the Visual Studio interface. The agent provides real-time feedback and status updates on the migration process. Other development environments might offer different monitoring options.
Yes. Monitor the assessment progress through the Visual Studio interface. The agent provides real-time feedback and status updates. Other development environments might offer different monitoring options.

In Visual Studio, monitor assessment progress by viewing the command-line output while the assessment runs:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ Before running the instruction during an upgrade, validate it in isolation. Isol
```text
> Getting instructions for 'replace Newtonsoft with System.Text.Json'.
Perfect! I've retrieved the scenario instructions for migrating from Newtonsoft.Json to System.Text.Json. Now I'll begin the analysis following the scenario-specific instructions.
Perfect! I've retrieved the scenario instructions for upgrading from Newtonsoft.Json to System.Text.Json. Now I'll begin the analysis following the scenario-specific instructions.
```

If Copilot doesn't indicate it found the instructions, retry with keywords from the file's name, such as the same verb and noun combinations.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ ai-usage: ai-assisted

GitHub Copilot modernization is an AI-powered agent that upgrades .NET projects to newer versions and migrates applications to Azure. This article walks you through upgrading your .NET applications with a structured three-stage workflow: assessment, planning, and execution.

The modernization agent analyzes your projects and dependencies, creates detailed upgrade documentation at each stage, and helps with code fixes throughout the process. The agent supports upgrading from older .NET versions to the latest, including migrations from .NET Framework to modern .NET.
The modernization agent analyzes your projects and dependencies, creates detailed upgrade documentation at each stage, and helps with code fixes throughout the process. The agent supports upgrading from older .NET versions to the latest, including upgrades from .NET Framework to modern .NET.

## Prerequisites

Expand Down Expand Up @@ -82,7 +82,7 @@ After the assessment, Copilot evaluates your solution and presents upgrade strat
The options typically include:

- **Upgrade strategy.** Bottom-up (leaf projects first), top-down (application first), or all-at-once (all projects in one pass).
- **Project migration approach.** In-place rewrite or side-by-side migration.
- **Project upgrade approach.** In-place rewrite or side-by-side upgrade.
- **Technology modernization.** Whether to upgrade technologies like Entity Framework (EF6 to EF Core), dependency injection, logging, and configuration.
- **Package management.** Whether to adopt Central Package Management.
- **Compatibility handling.** How to address unsupported APIs, incompatible packages, and platform-specific functionality.
Expand Down Expand Up @@ -135,7 +135,7 @@ To review and customize the plan:
1. Edit the plan to adjust upgrade steps or add context as needed.

> [!CAUTION]
> The plan depends on project interdependencies. The upgrade doesn't succeed if you modify the plan in a way that prevents the migration path from completing. For example, if **Project A** depends on **Project B** and you remove **Project B** from the upgrade plan, upgrading **Project A** might fail.
> The plan depends on project interdependencies. The upgrade doesn't succeed if you modify the plan in a way that prevents the upgrade path from completing. For example, if **Project A** depends on **Project B** and you remove **Project B** from the upgrade plan, upgrading **Project A** might fail.

1. Tell Copilot to _move to the execution stage._

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ ms.date: 04/06/2026
ai-usage: ai-assisted
zone_pivot_groups: copilot-modernization-install

#customer intent: As a developer, I want to install GitHub Copilot modernization so that I can upgrade and migrate my .NET applications.
#customer intent: As a developer, I want to install GitHub Copilot modernization so that I can upgrade my .NET applications.

---

Expand Down
Loading
Loading