Package one.suhas.rmc.entity
Class OpenAIRequest
java.lang.Object
one.suhas.rmc.entity.OpenAIRequest
A class to contain a request to the OpenAI API. All of these parameters are directly taken from the OpenAI response body to allow for it's encoding to JSON.
-
Constructor Summary
ConstructorsConstructorDescriptionOpenAIRequest(String model, String prompt, double temperature, int max_tokens, int top_p, int frequency_penalty, int presence_penalty) -
Method Summary
Modifier and TypeMethodDescriptionintintgetModel()intdoubleintgetTop_p()voidsetFrequency_penalty(int frequency_penalty) voidsetMax_tokens(int max_tokens) voidvoidsetPresence_penalty(int presence_penalty) voidvoidsetTemperature(double temperature) voidsetTop_p(int top_p)
-
Constructor Details
-
OpenAIRequest
-
OpenAIRequest
public OpenAIRequest()
-
-
Method Details
-
getModel
-
setModel
-
getPrompt
-
setPrompt
-
getTemperature
public double getTemperature() -
setTemperature
public void setTemperature(double temperature) -
getMax_tokens
public int getMax_tokens() -
setMax_tokens
public void setMax_tokens(int max_tokens) -
getTop_p
public int getTop_p() -
setTop_p
public void setTop_p(int top_p) -
getFrequency_penalty
public int getFrequency_penalty() -
setFrequency_penalty
public void setFrequency_penalty(int frequency_penalty) -
getPresence_penalty
public int getPresence_penalty() -
setPresence_penalty
public void setPresence_penalty(int presence_penalty)
-