AIJsonUtilities.ResolveParameterJsonSchema Method
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.
Determines a JSON schema for the provided parameter metadata.
public static System.Text.Json.JsonElement ResolveParameterJsonSchema (Microsoft.Extensions.AI.AIFunctionParameterMetadata parameterMetadata, Microsoft.Extensions.AI.AIFunctionMetadata functionMetadata, System.Text.Json.JsonSerializerOptions? serializerOptions = default, Microsoft.Extensions.AI.AIJsonSchemaCreateOptions? inferenceOptions = default);
static member ResolveParameterJsonSchema : Microsoft.Extensions.AI.AIFunctionParameterMetadata * Microsoft.Extensions.AI.AIFunctionMetadata * System.Text.Json.JsonSerializerOptions * Microsoft.Extensions.AI.AIJsonSchemaCreateOptions -> System.Text.Json.JsonElement
Public Function ResolveParameterJsonSchema (parameterMetadata As AIFunctionParameterMetadata, functionMetadata As AIFunctionMetadata, Optional serializerOptions As JsonSerializerOptions = Nothing, Optional inferenceOptions As AIJsonSchemaCreateOptions = Nothing) As JsonElement
Parameters
- parameterMetadata
- AIFunctionParameterMetadata
The parameter metadata from which to infer the schema.
- functionMetadata
- AIFunctionMetadata
The containing function metadata.
- serializerOptions
- JsonSerializerOptions
The options used to extract the schema from the specified type.
- inferenceOptions
- AIJsonSchemaCreateOptions
The options controlling schema inference.
Returns
A JSON schema document encoded as a JsonElement.
Applies to
Collaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests. For more information, see our contributor guide.