Package com.openai.models
        Class ResponseFormatTextGrammar
- 
                    
                    
- All Implemented Interfaces:
 
public final class ResponseFormatTextGrammarA custom grammar for the model to follow when generating text. Learn more in the custom grammars guide.
 
- 
                
                    
                    
- 
                                
                            
                                
Nested Class Summary
Nested Classes Modifier and Type Class Description public final classResponseFormatTextGrammar.BuilderA builder for ResponseFormatTextGrammar.
 
- 
                                
                            
                                
Method Summary
Modifier and Type Method Description final Stringgrammar()The custom grammar for the model to follow. final JsonValue_type()The type of response format being defined. final JsonField<String>_grammar()Returns the raw JSON value of grammar. final Map<String, JsonValue>_additionalProperties()final ResponseFormatTextGrammar.BuildertoBuilder()final ResponseFormatTextGrammarvalidate()final BooleanisValid()Booleanequals(Object other)IntegerhashCode()StringtoString()final static ResponseFormatTextGrammar.Builderbuilder()Returns a mutable builder for constructing an instance of ResponseFormatTextGrammar. - 
                    
                    
                    
- 
                                
                            
                                
Method Detail
- 
                                        
_type
final JsonValue _type()
The type of response format being defined. Always
grammar.Expected to always return the following:
JsonValue.from("grammar")However, this method can be useful for debugging and logging (e.g. if the server responded with an unexpected value).
 
- 
                                        
_grammar
final JsonField<String> _grammar()
Returns the raw JSON value of grammar.
Unlike grammar, this method doesn't throw if the JSON field has an unexpected type.
 
- 
                                        
_additionalProperties
final Map<String, JsonValue> _additionalProperties()
 
- 
                                        
toBuilder
final ResponseFormatTextGrammar.Builder toBuilder()
 
- 
                                        
validate
final ResponseFormatTextGrammar validate()
 
- 
                                        
builder
final static ResponseFormatTextGrammar.Builder builder()
Returns a mutable builder for constructing an instance of ResponseFormatTextGrammar.
The following fields are required:
.grammar() 
 - 
                                        
 
 - 
                                
                            
                                
 
 - 
                    
                    
                    
 
 -