FunctionCallContent.CreateFromParsedArguments<TEncoding> Method

Definition

Creates a new instance of FunctionCallContent parsing arguments using a specified encoding and parser.

C#
public static Microsoft.Extensions.AI.FunctionCallContent CreateFromParsedArguments<TEncoding>(TEncoding encodedArguments, string callId, string name, Func<TEncoding,System.Collections.Generic.IDictionary<string,object?>?> argumentParser);

Type Parameters

TEncoding

The encoding format from which to parse function call arguments.

Parameters

encodedArguments
TEncoding

The input arguments encoded in TEncoding.

callId
String

The function call ID.

name
String

The function name.

argumentParser
Func<TEncoding,IDictionary<String,Object>>

The parsing implementation converting the encoding to a dictionary of arguments.

Returns

A new instance of FunctionCallContent containing the parse result.

Applies to

Product Versions
.NET 8 (package-provided), 9 (package-provided)
.NET Framework 4.7 (package-provided), 4.7.1 (package-provided), 4.7.2 (package-provided), 4.8 (package-provided)
.NET Standard 2.0 (package-provided)