Create a model response.
Create a model response.
Request body
The underlying LLM used for completions.
Whether to run the model response in the background. When true, returns immediately with status 'queued'.
Instructions to guide the model's behavior.
Whether to enable parallel tool calls.
Optional ID of a previous response to continue from.
A key to use when reading from or writing to the prompt cache.
Optional ID of a conversation to add the response to.
Whether to store the response in the database.
Whether to stream the response.
Sampling temperature.
Nucleus sampling parameter that controls response diversity (lower values increase focus).
Penalizes new tokens based on their frequency in the text so far.
Additional fields to include in the response.
Maximum number of inference iterations.
Max number of total calls to built-in tools that can be processed in a response.
Upper bound for the number of tokens that can be generated for a response.
The service tier for the request.
Dictionary of metadata key-value pairs to attach to the response.
A stable identifier used to associate the request with an end user, for safety monitoring. Echoed back on the response.
Controls how the service truncates input when it exceeds the model context window.
The number of most likely tokens to return at each position, along with their log probabilities.
Penalizes new tokens based on whether they appear in the text so far.
Response
An OpenAIResponseObject or a stream of OpenAIResponseObjectStream.
Controls how the service truncates input when it exceeds the model context window.