Skip to content

Conversation

@mdaigle
Copy link
Contributor

@mdaigle mdaigle commented Feb 9, 2026

This pull request introduces several new prompt files to the .github/prompts directory, each designed to streamline and enhance various workflows related to Azure DevOps work items, documentation generation, prompt and skill creation, and test coverage analysis. The additions provide detailed, step-by-step instructions and best practices for Copilot agents, improving clarity, maintainability, and leveraging reusable skills.

Azure DevOps Work Item Management:

  • Added ado-work-item-agent.prompt.md to guide a developer through the full lifecycle of addressing an Azure DevOps work item, including analysis, planning, implementation, testing, and documentation, with references to repository policies and guidelines.
  • Added ado-work-item-clarification.prompt.md to facilitate interactive clarification and updating of Azure DevOps work item descriptions, ensuring comprehensive requirements and actionable acceptance criteria.

Prompt and Skill Generation:

  • Added generate-prompt.prompt.md to automate the creation of high-quality VS Code Copilot prompt files, with explicit instructions for referencing and leveraging skills from the .github/skills/ directory.
  • Added generate-skill.prompt.md to automate the creation of GitHub Copilot Agent Skill files (SKILL.md), including best practices, output structure, and recommendations for directory and supporting files.

Documentation and Test Optimization:

  • Added generate-doc-comments.prompt.md to generate XML documentation comments for C# code, following .NET conventions and repository constraints, while avoiding inline documentation for public APIs.
  • Added refine-test-overlap.prompt.md to analyze test coverage overlap and suggest optimizations, leveraging skills for MSTest filter generation and providing detailed refactoring strategies.

@mdaigle mdaigle marked this pull request as ready for review February 9, 2026 18:57
Copilot AI review requested due to automatic review settings February 9, 2026 18:57
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@cheenamalhotra
Copy link
Member

Could you include .vscode/mcp.json file with common MCP server configurations for tools included in prompt files, Copilot can start them as needed.

@cheenamalhotra
Copy link
Member

@mdaigle PR #3944 should complement your workflows I hope. Please take a look at that PR as well.

@mdaigle mdaigle requested a review from a team as a code owner February 10, 2026 16:33
cheenamalhotra
cheenamalhotra previously approved these changes Feb 10, 2026
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would like to add these new prompts to the Agent.md in my PR as well.

Copy link
Contributor

@paulmedynski paulmedynski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lots of content here, and I'm not sure how to review it. For example, how do I know if the instructions are "correct"? I've added comments to the first prompt file, and I'll hold off reviewing the rest until we can discuss (as a team?)

@paulmedynski paulmedynski self-assigned this Feb 10, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 10 out of 11 changed files in this pull request and generated 5 comments.

Comment on lines +99 to +108
# We use 'dotnet dotnet-coverage' (without 'tool run') as verified to work likely due to path/global install fallback
# Using ~ (Contains) for FullyQualifiedName handles both exact match and parameterized variants
$testFilter = "FullyQualifiedName~$test"
$innerCmd = "dotnet test `"$Project`" --filter `"$testFilter`" --framework $Framework --no-build"
# Note: passing dotnet-coverage as the command to the dotnet driver
$coverageArgs = @("dotnet-coverage", "collect", "-f", "xml", "-o", $coverageFile, $innerCmd)

try {
& dotnet $coverageArgs | Out-Null
} catch {
Copy link

Copilot AI Feb 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

dotnet-coverage is installed/verified as a local tool via dotnet tool run, but the script later invokes it as dotnet dotnet-coverage ... (via & dotnet $coverageArgs). This doesn’t align with how dotnet tools are executed and will likely fail to run coverage collection. Consider invoking the tool as dotnet tool run dotnet-coverage collect ... (or dotnet-coverage collect ... if you intentionally require a global tool) so the earlier install/restore logic is actually used.

Copilot uses AI. Check for mistakes.
dotnet build $Project --framework $Framework --configuration Debug | Out-Null

Write-Host "Listing tests..."
$tests = dotnet test $Project --list-tests --framework $Framework --filter $Filter | Select-String " " | ForEach-Object { $_.ToString().Trim() }
Copy link

Copilot AI Feb 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The script always passes --filter $Filter when listing tests. When $Filter is the default empty string, dotnet test --filter "" can error or behave unexpectedly. Consider conditionally adding the --filter argument only when a non-empty filter was provided (and treat empty as "no filter").

Suggested change
$tests = dotnet test $Project --list-tests --framework $Framework --filter $Filter | Select-String " " | ForEach-Object { $_.ToString().Trim() }
if ([string]::IsNullOrWhiteSpace($Filter)) {
# No filter specified: list all tests
$tests = dotnet test $Project --list-tests --framework $Framework | Select-String " " | ForEach-Object { $_.ToString().Trim() }
} else {
# Filter specified: pass it through to dotnet test
$tests = dotnet test $Project --list-tests --framework $Framework --filter $Filter | Select-String " " | ForEach-Object { $_.ToString().Trim() }
}

Copilot uses AI. Check for mistakes.
Comment on lines +24 to +26
2. **Run Analysis**:
* Run the script using the filter: `.\scripts\AnalyzeTestOverlap.ps1 -Filter "<filter>"`.
* *Note*: The script produces a console summary and a `test-coverage-analysis.json` file.
Copy link

Copilot AI Feb 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The prompt instructs running \.\scripts\AnalyzeTestOverlap.ps1, but the script is located at .github/prompts/scripts/AnalyzeTestOverlap.ps1. Unless the user’s working directory is .github/prompts, this command won’t resolve. Consider using a repo-root-relative invocation (e.g., pwsh .github/prompts/scripts/AnalyzeTestOverlap.ps1 ...) or explicitly stating the required working directory.

Copilot uses AI. Check for mistakes.
Comment on lines +4 to +10
"url": "https://mcp.bluebird-ai.net/",
"type": "http",
"headers": {
"x-mcp-ec-organization": "SqlClientDrivers",
"x-mcp-ec-project": "ADO.NET",
"x-mcp-ec-repository": "dotnet-sqlclient",
"x-mcp-ec-branch": "internal/main"
Copy link

Copilot AI Feb 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file hard-codes an external MCP endpoint (https://mcp.bluebird-ai.net/) and organization/project/repo/branch headers (including internal/main). Committing this to the repo can leak internal metadata and will not be usable for external contributors. Consider moving this configuration to documentation/a sample file (e.g., mcp.example.json), or gating it behind environment variables/user-local configuration instead of a tracked .vscode file.

Suggested change
"url": "https://mcp.bluebird-ai.net/",
"type": "http",
"headers": {
"x-mcp-ec-organization": "SqlClientDrivers",
"x-mcp-ec-project": "ADO.NET",
"x-mcp-ec-repository": "dotnet-sqlclient",
"x-mcp-ec-branch": "internal/main"
"url": "https://example-mcp-endpoint/",
"type": "http",
"headers": {
"x-mcp-ec-organization": "YOUR_ORGANIZATION",
"x-mcp-ec-project": "YOUR_PROJECT",
"x-mcp-ec-repository": "YOUR_REPOSITORY",
"x-mcp-ec-branch": "YOUR_BRANCH"

Copilot uses AI. Check for mistakes.
**To discover skills:**
1. List the contents of `.github/skills/` to find available skill directories
2. Read the `SKILL.md` file in each relevant skill directory to understand its purpose
3. Reference applicable skills in the generated prompt using the `#skill:` syntax
Copy link

Copilot AI Feb 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The prompt instructs referencing skills using a #skill: syntax, but the rest of the file (and other prompts in this repo) use plain Markdown links to .github/skills/.../SKILL.md. If #skill: isn’t actually supported, this will mislead prompt authors. Consider removing the #skill: mention and consistently documenting the Markdown-link approach used elsewhere in this repo.

Suggested change
3. Reference applicable skills in the generated prompt using the `#skill:` syntax
3. Reference applicable skills in the generated prompt using Markdown links to their `SKILL.md` files (see examples below)

Copilot uses AI. Check for mistakes.
Copy link
Contributor

@paulmedynski paulmedynski left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm generally fine with all of this, despite me not understanding exactly what it all does, or how we will use it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants