GeminiPromptExecutionSettings.ResponseSchema Property
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.
Optional. Output schema of the generated candidate text. Schemas must be a subset of the OpenAPI schema and can be objects, primitives or arrays. If set, a compatible responseMimeType must also be set. Compatible MIME types: application/json: Schema for JSON response. Refer to the https://ai.google.dev/gemini-api/docs/json-mode for more information.
[System.Text.Json.Serialization.JsonIgnore(Condition=System.Text.Json.Serialization.JsonIgnoreCondition.WhenWritingNull)]
[System.Text.Json.Serialization.JsonPropertyName("response_schema")]
public object? ResponseSchema { get; set; }
[<System.Text.Json.Serialization.JsonIgnore(Condition=System.Text.Json.Serialization.JsonIgnoreCondition.WhenWritingNull)>]
[<System.Text.Json.Serialization.JsonPropertyName("response_schema")>]
member this.ResponseSchema : obj with get, set
Public Property ResponseSchema As Object
Property Value
- Attributes
Remarks
Possible values are:
- Type which will be used to automatically generate a JSON schema.
- JsonElement schema definition, which will be used as is.
- JsonNode schema definition, which will be used as is.
- JsonDocument schema definition, which will be used as is.
- Object object, where none of the above matches which the type will be used to automatically generate a JSON schema.