ChatCompletionSchemaProperties Class

  • java.lang.Object
    • com.azure.search.documents.indexes.models.ChatCompletionSchemaProperties

Implements

public final class ChatCompletionSchemaProperties
implements JsonSerializable<ChatCompletionSchemaProperties>

Properties for JSON schema response format.

Constructor Summary

Constructor Description
ChatCompletionSchemaProperties()

Creates an instance of ChatCompletionSchemaProperties class.

Method Summary

Modifier and Type Method and Description
static ChatCompletionSchemaProperties fromJson(JsonReader jsonReader)

Reads an instance of ChatCompletionSchemaProperties from the JsonReader.

String getDescription()

Get the description property: Description of the json schema the model will adhere to.

String getName()

Get the name property: Name of the json schema the model will adhere to.

ChatCompletionSchema getSchema()

Get the schema property: The schema definition.

Boolean isStrict()

Get the strict property: Whether or not the model's response should use structured outputs.

ChatCompletionSchemaProperties setDescription(String description)

Set the description property: Description of the json schema the model will adhere to.

ChatCompletionSchemaProperties setName(String name)

Set the name property: Name of the json schema the model will adhere to.

ChatCompletionSchemaProperties setSchema(ChatCompletionSchema schema)

Set the schema property: The schema definition.

ChatCompletionSchemaProperties setStrict(Boolean strict)

Set the strict property: Whether or not the model's response should use structured outputs.

JsonWriter toJson(JsonWriter jsonWriter)

Methods inherited from java.lang.Object

Constructor Details

ChatCompletionSchemaProperties

public ChatCompletionSchemaProperties()

Creates an instance of ChatCompletionSchemaProperties class.

Method Details

fromJson

public static ChatCompletionSchemaProperties fromJson(JsonReader jsonReader)

Reads an instance of ChatCompletionSchemaProperties from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of ChatCompletionSchemaProperties if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If an error occurs while reading the ChatCompletionSchemaProperties.

getDescription

public String getDescription()

Get the description property: Description of the json schema the model will adhere to.

Returns:

the description value.

getName

public String getName()

Get the name property: Name of the json schema the model will adhere to.

Returns:

the name value.

getSchema

public ChatCompletionSchema getSchema()

Get the schema property: The schema definition.

Returns:

the schema value.

isStrict

public Boolean isStrict()

Get the strict property: Whether or not the model's response should use structured outputs. Default is true.

Returns:

the strict value.

setDescription

public ChatCompletionSchemaProperties setDescription(String description)

Set the description property: Description of the json schema the model will adhere to.

Parameters:

description - the description value to set.

Returns:

the ChatCompletionSchemaProperties object itself.

setName

public ChatCompletionSchemaProperties setName(String name)

Set the name property: Name of the json schema the model will adhere to.

Parameters:

name - the name value to set.

Returns:

the ChatCompletionSchemaProperties object itself.

setSchema

public ChatCompletionSchemaProperties setSchema(ChatCompletionSchema schema)

Set the schema property: The schema definition.

Parameters:

schema - the schema value to set.

Returns:

the ChatCompletionSchemaProperties object itself.

setStrict

public ChatCompletionSchemaProperties setStrict(Boolean strict)

Set the strict property: Whether or not the model's response should use structured outputs. Default is true.

Parameters:

strict - the strict value to set.

Returns:

the ChatCompletionSchemaProperties object itself.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

Applies to