KernelPluginCollection Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Provides a collection of KernelPlugins.
public sealed class KernelPluginCollection : Microsoft.SemanticKernel.IReadOnlyKernelPluginCollection, System.Collections.Generic.ICollection<Microsoft.SemanticKernel.KernelPlugin>, System.Collections.Generic.IEnumerable<Microsoft.SemanticKernel.KernelPlugin>, System.Collections.Generic.IReadOnlyCollection<Microsoft.SemanticKernel.KernelPlugin>
type KernelPluginCollection = class
interface ICollection<KernelPlugin>
interface seq<KernelPlugin>
interface IEnumerable
interface IReadOnlyKernelPluginCollection
interface IReadOnlyCollection<KernelPlugin>
Public NotInheritable Class KernelPluginCollection
Implements ICollection(Of KernelPlugin), IEnumerable(Of KernelPlugin), IReadOnlyCollection(Of KernelPlugin), IReadOnlyKernelPluginCollection
- Inheritance
-
KernelPluginCollection
- Implements
Remarks
All plugins stored in the collection must have a unique, ordinal case-insensitive name. All name lookups are performed using ordinal case-insensitive comparisons.
Constructors
KernelPluginCollection() |
Initializes a collection of plugins. |
KernelPluginCollection(IEnumerable<KernelPlugin>) |
Initializes a collection of plugins that contains all of the plugins from the provided collection. |
Properties
Count |
Gets the number of plugins in the collection. |
Item[String] |
Gets a plugin from the collection by name. |
Methods
Add(KernelPlugin) |
Adds the plugin to the plugin collection. |
AddRange(IEnumerable<KernelPlugin>) |
Adds a collection of plugins to this plugin collection. |
Clear() |
Removes all plugins from the collection. |
Contains(KernelPlugin) |
Gets whether the collection contains the specified plugin. |
GetEnumerator() |
Gets an enumerable of all plugins stored in this collection. |
Remove(KernelPlugin) |
Removes the specified plugin from the collection. |
TryGetPlugin(String, KernelPlugin) |
Gets a plugin from the collection by name. |
Explicit Interface Implementations
ICollection<KernelPlugin>.CopyTo(KernelPlugin[], Int32) | |
ICollection<KernelPlugin>.IsReadOnly | |
IEnumerable.GetEnumerator() |
Gets an enumerable of all plugins stored in this collection. |
Extension Methods
TryGetFunctionAndArguments(IReadOnlyKernelPluginCollection, OpenAIFunctionToolCall, KernelFunction, KernelArguments) |
Given an OpenAIFunctionToolCall object, tries to retrieve the corresponding KernelFunction and populate KernelArguments with its parameters. |
TryGetFunctionAndArguments(IReadOnlyKernelPluginCollection, ChatToolCall, KernelFunction, KernelArguments) |
Given an OpenAIFunctionToolCall object, tries to retrieve the corresponding KernelFunction and populate KernelArguments with its parameters. |
Contains(IReadOnlyKernelPluginCollection, String) |
Gets whether the plugins collection contains a plugin with the specified name. |
GetFunction(IReadOnlyKernelPluginCollection, String, String) |
Gets a function from the collection by plugin and function names. |
TryGetFunction(IReadOnlyKernelPluginCollection, String, String, KernelFunction) |
Gets a function from the collection by plugin and function names. |