Skip to content

Add Microsoft Learn MCP integration and update ResearcherAgent to sup… - #25

Merged
JesseLiberty merged 1 commit into
mainfrom
add-microsoft-learn-mcp
Sep 5, 2026
Merged

Add Microsoft Learn MCP integration and update ResearcherAgent to sup…#25
JesseLiberty merged 1 commit into
mainfrom
add-microsoft-learn-mcp

Conversation

@JesseLiberty

Copy link
Copy Markdown
Owner

…port multiple tools

Copilot AI lite review requested due to automatic review settings September 5, 2026 15:39
@JesseLiberty
JesseLiberty merged commit 595df66 into main Sep 5, 2026
1 check passed

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟡 Changes recommended

Startup now hard-depends on a remote MCP endpoint without a fallback, and tool-call logging at Information level risks excessive/sensitive log output.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Pull request overview

This PR expands the research capabilities of the BlogWriter workflow by integrating the Microsoft Learn MCP server and updating ResearcherAgent to support multiple tools during tool-calling runs.

Changes:

  • Updated ResearcherAgent to accept and attach multiple tools (instead of only Tavily) and log tool invocations generically.
  • Added Microsoft Learn MCP client initialization in Program.cs and included its tools alongside Tavily.
  • Added the ModelContextProtocol package and configured the Microsoft Learn MCP server in VS Code settings.
File summaries
File Description
ResearcherAgent.cs Generalizes the agent to accept multiple tools and updates invocation logging accordingly.
Program.cs Creates a Microsoft Learn MCP client, lists its tools, and passes them to ResearcherAgent alongside Tavily.
BlogWriter.csproj Adds the ModelContextProtocol NuGet dependency needed for MCP support.
.vscode/mcp.json Registers the microsoft-learn MCP server for local development tooling.
Review details
  • Files reviewed: 4/4 changed files
  • Comments generated: 2
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread Program.cs
Comment on lines +119 to +130
// Microsoft Learn's remote MCP server exposes docs search/fetch tools the
// Researcher can call alongside Tavily for authoritative Microsoft/Azure content.
await using McpClient microsoftLearnMcp = await McpClient.CreateAsync(
new HttpClientTransport(new HttpClientTransportOptions
{
Endpoint = new Uri("https://learn.microsoft.com/api/mcp"),
Name = "microsoft-learn",
}));
IList<McpClientTool> microsoftLearnTools = await microsoftLearnMcp.ListToolsAsync();

List<AIFunction> researcherTools = [tavilyTool, .. microsoftLearnTools];

Comment thread ResearcherAgent.cs
Comment on lines +60 to +63
_logger.LogInformation(
"Researcher invoking tool '{Tool}' with arguments {Arguments}",
context.Function.Name,
context.Arguments);
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