From the course: Azure OpenAI in .NET
Unlock the full course today
Join today to access over 24,900 courses taught by industry experts.
Semantic Kernel: Functions - .NET Tutorial
From the course: Azure OpenAI in .NET
Semantic Kernel: Functions
- [Instructor] Now that we have created an instance of Semantic Kernel using the Microsoft Semantic Kernel NuGet package and the kernel builder functionality or the kernel builder function from the NuGet package, the next step is to define the functions that we want to call. And the first function that we will define is a native function. So a plain, straightforward C# function. And this is what you can see here in step number two. So what I'm doing is I'm defining a class NativeFunction. And in this class NativeFunction, I'm defining a method DownloadContentFromUrl. And this method or function is using the httpClient GetAsync method to download content from a webpage. Because I know that I will download from a Wikipedia site, I can also already parse the response. And this is what I'm doing here with a jsonDocument.Parse. And I'm extracting here just the raw content from the article, and I'm returning this raw…
Contents
-
-
-
-
-
-
Semantic Kernel4m 42s
-
(Locked)
Semantic Kernel: Plugin2m 36s
-
(Locked)
Demo: Kernel plugin7m 11s
-
(Locked)
Semantic Kernel: Functions6m 18s
-
(Locked)
Executing functions3m 58s
-
(Locked)
Semantic Kernel: Memories2m 9s
-
(Locked)
Demo: Kernel memories7m 51s
-
(Locked)
Semantic Kernel: Planner1m 57s
-
(Locked)
Demo: Planner4m 47s
-
(Locked)
Challenge35s
-
(Locked)
Solution1m 23s
-
-