Skip to content
Open
Show file tree
Hide file tree
Changes from 2 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
9 changes: 2 additions & 7 deletions .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -65,17 +65,12 @@
# ServiceLabel: %tools-AppService
# ServiceOwners: @ArthurMa1978 @weidongxu-microsoft

# PRLabel: %tools-AIBestPractices
/tools/Azure.Mcp.Tools.AzureAIBestPractices/ @XiaofuHuang @microsoft/azure-mcp

# ServiceLabel: %tools-AIBestPractices
# ServiceOwners: @XiaofuHuang

# PRLabel: %tools-BestPractices
/tools/Azure.Mcp.Tools.AzureBestPractices/ @g2vinay @conniey @fanyang-mono @microsoft/azure-mcp
/tools/Azure.Mcp.Tools.AzureBestPractices/ @g2vinay @conniey @fanyang-mono @XiaofuHuang @microsoft/azure-mcp

# ServiceLabel: %tools-BestPractices
# ServiceOwners: @g2vinay @conniey @fanyang-mono
# ServiceOwners: @g2vinay @conniey @fanyang-mono @XiaofuHuang

# PRLabel: %tools-CloudArchitect
/tools/Azure.Mcp.Tools.CloudArchitect/ @msalaman @microsoft/azure-mcp
Expand Down
38 changes: 0 additions & 38 deletions AzureMcp.sln
Original file line number Diff line number Diff line change
Expand Up @@ -549,15 +549,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Fabric.Mcp.Tools.PublicApi.
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Azure.Mcp.Tools.Postgres.LiveTests", "tools\Azure.Mcp.Tools.Postgres\tests\Azure.Mcp.Tools.Postgres.LiveTests\Azure.Mcp.Tools.Postgres.LiveTests.csproj", "{BF0354AE-3748-A8DC-F79D-B21FDDEDDFAE}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Azure.Mcp.Tools.AzureAIBestPractices", "Azure.Mcp.Tools.AzureAIBestPractices", "{156D9C17-61FD-98D6-32C0-065B406D0434}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{5D760DD8-DBA3-B865-9021-FDE8FD3497A8}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Azure.Mcp.Tools.AzureAIBestPractices", "tools\Azure.Mcp.Tools.AzureAIBestPractices\src\Azure.Mcp.Tools.AzureAIBestPractices.csproj", "{87C51120-6A0A-4D14-B644-1787DB6C6D6E}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{50124EEC-97B0-320E-80D4-8464D7692B22}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Azure.Mcp.Tools.AzureAIBestPractices.UnitTests", "tools\Azure.Mcp.Tools.AzureAIBestPractices\tests\Azure.Mcp.Tools.AzureAIBestPractices.UnitTests\Azure.Mcp.Tools.AzureAIBestPractices.UnitTests.csproj", "{BE8CFF4C-E536-43DB-9D01-001E9A052D37}"
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tests", "tests", "{319B94CD-694C-16E8-9E3A-9577B99158DD}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Azure.Mcp.Server.UnitTests", "servers\Azure.Mcp.Server\tests\Azure.Mcp.Server.UnitTests\Azure.Mcp.Server.UnitTests.csproj", "{ADF14627-FCB5-4BD3-B65F-DDCC3A3F727C}"
Expand Down Expand Up @@ -2096,30 +2087,6 @@ Global
{BF0354AE-3748-A8DC-F79D-B21FDDEDDFAE}.Release|x64.Build.0 = Release|Any CPU
{BF0354AE-3748-A8DC-F79D-B21FDDEDDFAE}.Release|x86.ActiveCfg = Release|Any CPU
{BF0354AE-3748-A8DC-F79D-B21FDDEDDFAE}.Release|x86.Build.0 = Release|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Debug|Any CPU.Build.0 = Debug|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Debug|x64.ActiveCfg = Debug|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Debug|x64.Build.0 = Debug|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Debug|x86.ActiveCfg = Debug|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Debug|x86.Build.0 = Debug|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Release|Any CPU.ActiveCfg = Release|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Release|Any CPU.Build.0 = Release|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Release|x64.ActiveCfg = Release|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Release|x64.Build.0 = Release|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Release|x86.ActiveCfg = Release|Any CPU
{87C51120-6A0A-4D14-B644-1787DB6C6D6E}.Release|x86.Build.0 = Release|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Debug|Any CPU.Build.0 = Debug|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Debug|x64.ActiveCfg = Debug|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Debug|x64.Build.0 = Debug|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Debug|x86.ActiveCfg = Debug|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Debug|x86.Build.0 = Debug|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Release|Any CPU.ActiveCfg = Release|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Release|Any CPU.Build.0 = Release|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Release|x64.ActiveCfg = Release|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Release|x64.Build.0 = Release|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Release|x86.ActiveCfg = Release|Any CPU
{BE8CFF4C-E536-43DB-9D01-001E9A052D37}.Release|x86.Build.0 = Release|Any CPU
{ADF14627-FCB5-4BD3-B65F-DDCC3A3F727C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{ADF14627-FCB5-4BD3-B65F-DDCC3A3F727C}.Debug|Any CPU.Build.0 = Debug|Any CPU
{ADF14627-FCB5-4BD3-B65F-DDCC3A3F727C}.Debug|x64.ActiveCfg = Debug|Any CPU
Expand Down Expand Up @@ -2406,11 +2373,6 @@ Global
{294AC723-70DA-F50A-2C7A-AC6C0AEA0A62} = {9072C7AF-9EB2-E481-3974-77957587AC76}
{D3F46C2D-3AFD-FD9C-9C6A-180B1514DD2F} = {294AC723-70DA-F50A-2C7A-AC6C0AEA0A62}
{BF0354AE-3748-A8DC-F79D-B21FDDEDDFAE} = {37B0CE47-14C8-F5BF-BDDD-13EEBE580A88}
{156D9C17-61FD-98D6-32C0-065B406D0434} = {07C2787E-EAC7-C090-1BA3-A61EC2A24D84}
{5D760DD8-DBA3-B865-9021-FDE8FD3497A8} = {156D9C17-61FD-98D6-32C0-065B406D0434}
{87C51120-6A0A-4D14-B644-1787DB6C6D6E} = {5D760DD8-DBA3-B865-9021-FDE8FD3497A8}
{50124EEC-97B0-320E-80D4-8464D7692B22} = {156D9C17-61FD-98D6-32C0-065B406D0434}
{BE8CFF4C-E536-43DB-9D01-001E9A052D37} = {50124EEC-97B0-320E-80D4-8464D7692B22}
{319B94CD-694C-16E8-9E3A-9577B99158DD} = {F7E192D1-DE6C-42A2-B52F-02849D482450}
{ADF14627-FCB5-4BD3-B65F-DDCC3A3F727C} = {319B94CD-694C-16E8-9E3A-9577B99158DD}
EndGlobalSection
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@ sure the user is discussing Azure Functions; do not call it otherwise.
- Use Azure Functions Deployment Best Practices: When deploying Azure Functions apps to Azure or preparing for
the deployment, invoke your `bestpractices` tool if available. Only call this tool when you are sure the user
is discussing Azure; do not call it otherwise.
- Use Azure AI Code Generation Best Practices: When generating code for AI applications, AI agents, workflows,
or chatbots in Azure, invoke your `azureaibestpractices` tool if available. Only call this tool when you are sure
the user is discussing Azure and code generation; do not call it for Azure resource operations.
- Use Azure AI App Code Generation Best Practices: When generating code for AI applications, AI agents, workflows,
or chatbots, invoke your `get_bestpractices_ai_app` command (under `get_bestpractices` tool) if tool available
Call this tool first before creating any plans, todos or code.

Choose a reason for hiding this comment

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

Should this be a more generic rule for all Azure best practices scoped to Azure related intents - @fanyang-mono

Copy link
Contributor

@fanyang-mono fanyang-mono Dec 5, 2025

Choose a reason for hiding this comment

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

You are right @kvenkatrajan. @XiaofuHuang Can you rephrase it to something like this?

When generating code for AI applications, AI agents, workflows,
or chatbots using Microsoft Foundry.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

For the same reason mentioned above, we want Copilot to trigger this command not only when users mention Microsoft Foundry, but also when they request AI app or code generation in Azure without specifying a technology stack. Therefore, we should not limit this rule to Microsoft Foundry only.

Only call this command when you are sure the user is discussing Microsoft Foundry or AI feature code generation; do not call it for Azure resource operations.
- Use Azure SWA Best Practices: When working with static web apps, invoke your `bestpractices` tool if available.
Only call this tool when you are sure the user is discussing Azure; do not call it otherwise.
- Plan before editing files for Azure web apps: When generating code for Azure Functions and Azure Static Web App,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1010,9 +1010,9 @@
}
},
"mappedToolList": [
"azureaibestpractices_get",
"azureterraformbestpractices_get",
"bicepschema_get",
"get_bestpractices_ai_app",
"get_bestpractices_get",
"foundry_agents_get-sdk-sample"
]
Expand Down
14 changes: 7 additions & 7 deletions eng/tools/ToolDescriptionEvaluator/prompts/prompts.json
Original file line number Diff line number Diff line change
@@ -1,11 +1,4 @@
{
"azureaibestpractices_get": [
"Get best practices for building AI applications in Azure",
"Show me the best practices for Microsoft Foundry agents code generation",
"Get guidance for building agents with Microsoft Foundry",
"Create an AI app that helps me to manage travel queries.",
"Create an AI app that helps me to manage travel queries in Microsoft Foundry"
],
"foundry_agents_connect": [
"Query an agent in my Microsoft Foundry resource"
],
Expand Down Expand Up @@ -560,6 +553,13 @@
"Search for Microsoft products in the marketplace",
"Show me marketplace products from publisher <publisher_name>"
],
"get_bestpractices_ai_app": [
"Get best practices for building AI applications in Azure",
"Show me the best practices for Microsoft Foundry agents code generation",
"Get guidance for building agents with Microsoft Foundry",
"Create an AI app that helps me to manage travel queries.",
"Create an AI app that helps me to manage travel queries in Microsoft Foundry"
],
"get_bestpractices_get": [
"Get the latest Azure code generation best practices",
"Get the latest Azure deployment best practices",
Expand Down
1 change: 1 addition & 0 deletions servers/Azure.Mcp.Server/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ The Azure MCP Server updates automatically by default whenever a new release com
### Other Changes

- Switched to the new `Azure.Monitor.Query.Logs` package to query logs from Azure Monitor. [[#1309](https://github.com/microsoft/mcp/pull/1309)]
- Move Azure AI Best Practices tool into Best Practice namespace [[#1323](https://github.com/microsoft/mcp/pull/1323)]

## 2.0.0-beta.7 (2025-11-25)

Expand Down
1 change: 0 additions & 1 deletion servers/Azure.Mcp.Server/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -539,7 +539,6 @@ The Azure MCP Server provides tools for interacting with **40+ Azure service are
- 🧮 **Microsoft Foundry** - AI model management, AI model deployment, and knowledge index management
- 🔎 **Azure AI Search** - Search engine/vector database operations
- 🎤 **Azure AI Services Speech** - Speech-to-text recognition and text-to-speech synthesis
- 🤖 **Azure AI Best Practices** - AI app development guidance for Microsoft Foundry and Microsoft Agent Framework
- ⚙️ **Azure App Configuration** - Configuration management
- 🕸️ **Azure App Service** - Web app hosting
- 🛡️ **Azure Best Practices** - Secure, production-grade guidance
Expand Down
26 changes: 10 additions & 16 deletions servers/Azure.Mcp.Server/docs/azmcp-commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,22 +204,6 @@ The `azmcp server start` command supports the following options:
azmcp server info
```


### Azure AI Best Practices

```bash
# Get best practices for building AI applications, workflows and agents in Azure
# Call this before generating code for any AI application, building with Microsoft Foundry models,
# working with Microsoft Agent Framework, or implementing AI solutions in Azure.
# ❌ Destructive | ✅ Idempotent | ❌ OpenWorld | ✅ ReadOnly | ❌ Secret | ❌ LocalRequired
azmcp azureaibestpractices get

# Includes guidance on:
# - Microsoft Agent Framework usage and patterns
# - Microsoft Foundry model selection
# - Best practices for ai app / agent development in Azure
```

### Azure AI Search Operations

```bash
Expand Down Expand Up @@ -1286,6 +1270,16 @@ azmcp get bestpractices get --resource <resource> --action <action>
# code-generation - Best practices for code generation (for general and azurefunctions)
# deployment - Best practices for deployment (for general and azurefunctions)

# Get best practices for building AI applications, workflows and agents in Azure
# Call this before generating code for any AI application, building with Microsoft Foundry models,
# working with Microsoft Agent Framework, or implementing AI solutions in Azure.
azmcp get bestpractices ai_app

# AI App Development:
# ai_app - Comprehensive guidance for AI applications including:
# • Microsoft Agent Framework usage and patterns
# • Microsoft Foundry model selection
# • Best practices for AI app/agent development in Azure
```

### Azure MCP Tools
Expand Down
16 changes: 5 additions & 11 deletions servers/Azure.Mcp.Server/docs/e2eTestPrompts.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,6 @@

This file contains prompts used for end-to-end testing to ensure each tool is invoked properly by MCP clients. The tables are organized by Azure MCP Server areas in alphabetical order, with Tool Names sorted alphabetically within each table.

## Azure AI Best Practices

| Tool Name | Test Prompt |
|:----------|:----------|
| azureaibestpractices_get | Get best practices for building AI applications in Azure |
| azureaibestpractices_get | Show me the best practices for Microsoft Foundry agents code generation |
| azureaibestpractices_get | Get guidance for building agents with Microsoft Foundry |
| azureaibestpractices_get | Create an AI app that helps me to manage travel queries. |
| azureaibestpractices_get | Create an AI app that helps me to manage travel queries in Microsoft Foundry |

## Azure AI Search

| Tool Name | Test Prompt |
Expand Down Expand Up @@ -435,7 +425,11 @@ This file contains prompts used for end-to-end testing to ensure each tool is in
| get_bestpractices_get | Get the latest Azure Static Web Apps best practices |
| get_bestpractices_get | What are azure function best practices? |
| get_bestpractices_get | configure azure mcp in coding agent for my repo |

| get_bestpractices_ai_app | Get best practices for building AI applications in Azure |
| get_bestpractices_ai_app | Show me the best practices for Microsoft Foundry agents code generation |
| get_bestpractices_ai_app | Get guidance for building agents with Microsoft Foundry |
| get_bestpractices_ai_app | Create an AI app that helps me to manage travel queries. |
| get_bestpractices_ai_app | Create an AI app that helps me to manage travel queries in Microsoft Foundry |
## Azure Monitor

| Tool Name | Test Prompt |
Expand Down
1 change: 0 additions & 1 deletion servers/Azure.Mcp.Server/src/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,6 @@ private static IAreaSetup[] RegisterAreas()

return [
// Register core areas
new Azure.Mcp.Tools.AzureAIBestPractices.AzureAIBestPracticesSetup(),
new Azure.Mcp.Tools.AzureBestPractices.AzureBestPracticesSetup(),
new Azure.Mcp.Tools.Extension.ExtensionSetup(),
new Azure.Mcp.Core.Areas.Group.GroupSetup(),
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Loading