Semantic Kernel is Microsoft's AI orchestration SDK for .NET, Java, and Python. These exercises focus on the .NET API covering plugins, the [KernelFunction] attribute, the Planner for multi-step task automation, memory vs. plugins distinction, and kernel function invocation.
0 / 5 completed
1 / 5
What is a Semantic Kernel Plugin?
A Plugin in Semantic Kernel is a logical grouping of related functions — either native C# functions decorated with [KernelFunction] or semantic functions defined as prompt templates. The kernel discovers and invokes plugin functions to accomplish tasks, and they appear as tools to AI models.
2 / 5
A developer adds [KernelFunction, Description('Gets the current weather')] to a C# method. What does this enable?
The [KernelFunction] attribute marks a C# method as a Semantic Kernel function that can be invoked by the kernel or exposed to AI models as a tool. Combined with [Description], the method appears in the model's tool list with the description as its documentation, enabling auto-invocation when the model decides to call it.
3 / 5
What is Semantic Kernel's Planner and what problem does it solve?
The Planner uses an LLM to automatically create a multi-step plan from available plugins to accomplish a complex goal. Given a user request and a set of registered plugins, the planner figures out which functions to call and in what order, enabling dynamic task decomposition without hardcoded workflows.
4 / 5
In Semantic Kernel, what is kernel.InvokeAsync() used for?
kernel.InvokeAsync() executes a named function from a registered plugin. For example, kernel.InvokeAsync("WeatherPlugin", "GetWeather", new KernelArguments {{ "city", "London" }}) invokes the GetWeather function with the provided arguments, going through the kernel's middleware pipeline (filters, logging, etc.).
5 / 5
How does Semantic Kernel's memory component differ from its plugin system?
Semantic Kernel memory stores text in a vector store and enables semantic similarity search — it answers 'what do I know about X?' by retrieving relevant stored information. Plugins are callable functions that perform actions. They serve complementary roles: memory retrieves context; plugins execute capabilities.