ChatResponseFormat.ForJsonSchema(String, String, String) 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.
Creates a ChatResponseFormatJson representing structured JSON data with the specified schema.
public static Microsoft.Extensions.AI.ChatResponseFormatJson ForJsonSchema (string schema, string? schemaName = default, string? schemaDescription = default);
static member ForJsonSchema : string * string * string -> Microsoft.Extensions.AI.ChatResponseFormatJson
Public Shared Function ForJsonSchema (schema As String, Optional schemaName As String = Nothing, Optional schemaDescription As String = Nothing) As ChatResponseFormatJson
Parameters
- schema
- String
The JSON schema.
- schemaName
- String
An optional name of the schema, e.g. if the schema represents a particular class, this could be the name of the class.
- schemaDescription
- String
An optional description of the schema.
Returns
The ChatResponseFormatJson instance.
Applies to
Collaborer avec nous sur GitHub
La source de ce contenu se trouve sur GitHub, où vous pouvez également créer et examiner les problèmes et les demandes de tirage. Pour plus d’informations, consultez notre guide du contributeur.