A practical guide to function calling in Semantic Kernel for C#, covering native functions (C# methods with [KernelFunction] attribute) and prompt functions (LLM-executed prompt templates). Explains the full function calling loop, FunctionChoiceBehavior options (Auto, Required, None), parallel function execution, streaming with function calls, and a detailed comparison table of native vs prompt functions to help developers choose the right approach for each scenario.
Table of contents
What Is Function Calling in Semantic Kernel?Native Functions: C# Methods as AI ToolsPrompt Functions: AI-Defined LogicThe Function Calling LoopFunctionChoiceBehavior OptionsParallel Function CallingStreaming and Function CallsComparing Native vs Prompt FunctionsFrequently Asked QuestionsConclusionSort: