QuestionQ122
VerifiedImplement generative AI and agentic solutionsYou have a Microsoft Foundry project that includes an agent. The agent has a Model Context Protocol (MCP) tool named kbsearch that queries a knowledge base stored in Azure AI Search.
Some agent runs produce answers from the base model without calling the knowledge base, resulting in responses that lack grounded citations.
You are given the following code snippet used to run the agent.

You need to deterministically require the agent to invoke kbsearch on every run.
What should you do?
Community Discussion