-
Notifications
You must be signed in to change notification settings - Fork 337
Handle newer Azure AI Search knowledge bases and those set 'minimal' reasoning effort #1422
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR updates the Azure AI Search tool to support newer versions of Azure AI Search knowledge bases, particularly those configured with 'minimal' reasoning effort. The changes migrate from the deprecated KnowledgeAgent* API to the newer KnowledgeBase* API and add logic to detect and handle minimal reasoning mode appropriately.
Key changes:
- Upgrades Azure.Search.Documents from 11.7.0-beta.7 to 11.8.0-beta.1
- Migrates from KnowledgeAgent API to KnowledgeBase API (naming and namespace changes)
- Adds detection of minimal reasoning effort configuration and routes requests accordingly
- Adds comprehensive unit tests for the new BuildKnowledgeBaseRetrievalRequest method
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| Directory.Packages.props | Updates Azure.Search.Documents package version to support new KnowledgeBase API |
| tools/Azure.Mcp.Tools.Search/src/Services/SearchService.cs | Migrates to KnowledgeBase API, adds minimal reasoning detection, and implements request builder method |
| tools/Azure.Mcp.Tools.Search/tests/Azure.Mcp.Tools.Search.UnitTests/Service/SearchServiceTests.cs | Adds unit tests for BuildKnowledgeBaseRetrievalRequest covering minimal and standard reasoning scenarios |
| servers/Azure.Mcp.Server/changelog-entries/1766191976865.yaml | Documents the bug fix for supporting newer knowledge base versions |
What does this PR do?
Updates the Azure AI Search knowledge base retrieve command to handle newer Azure AI Search knowledge bases and those set 'minimal' reasoning effort.
Test note: we need a new live test to catch KB-specific issues. Leaving this for a different PR since there's some coordination needed for live tests.
GitHub issue number?
--
Pre-merge Checklist
servers/Azure.Mcp.Server/CHANGELOG.mdand/orservers/Fabric.Mcp.Server/CHANGELOG.mdfor product changes (features, bug fixes, UI/UX, updated dependencies)servers/Azure.Mcp.Server/README.mdand/orservers/Fabric.Mcp.Server/README.mddocumentationeng/scripts/Process-PackageReadMe.ps1. See Package README/servers/Azure.Mcp.Server/docs/azmcp-commands.mdand/or/docs/fabric-commands.md.\eng\scripts\Update-AzCommandsMetadata.ps1to update tool metadata in azmcp-commands.md (required for CI)ToolDescriptionEvaluatorand obtained a score of0.4or more and a top 3 ranking for all related test promptsconsolidated-tools.json/servers/Azure.Mcp.Server/docs/e2eTestPrompts.mdcrypto mining, spam, data exfiltration, etc.)/azp run mcp - pullrequest - liveto run Live Test Pipeline