Issue with running MCP GitHub sample c# #11974
-
Hi team, What I tried:
Is there anything that I missed? See attached for more details. MCP Inspector OutputCode and outputOpenAIPromptExecutionSettings executionSettings = new()
{
Temperature = 0,
FunctionChoiceBehavior = FunctionChoiceBehavior.Auto(options: new() { RetainArgumentTypes = true })
};
// Test using GitHub tools
kernel.Plugins.AddFromFunctions("GitHub", mcpTools.Select(aiFunction => aiFunction.AsKernelFunction()));
var prompt = "Summarize the last four commits to the microsoft/semantic-kernel repository?";
var result = await kernel.InvokePromptAsync(prompt, new(executionSettings)).ConfigureAwait(false);
Console.WriteLine($"\n\n{prompt}\n{result}");
|
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 1 reply
-
Beta Was this translation helpful? Give feedback.
-
Tagging @markwallace-microsoft / @SergeyMenshykh for visibility. |
Beta Was this translation helpful? Give feedback.
-
Which model are you using? Those responses look a lot like responses from a smaller local model. The fact that it's providing the name of the plugin and function with the correct parameters show that the MCP tools are being properly converted to OpenAI tool format by SK. I suspect you'd see similar issues if you used non-MCP tools with the same setup. |
Beta Was this translation helpful? Give feedback.
Which model are you using? Those responses look a lot like responses from a smaller local model. The fact that it's providing the name of the plugin and function with the correct parameters show that the MCP tools are being properly converted to OpenAI tool format by SK. I suspect you'd see similar issues if you used non-MCP tools with the same setup.