Request Parameters
The Arvae AI API supports a variety of parameters that allow you to customize your requests and control the model's output.
This page documents all the available parameters, their types, default values, and descriptions to help you make the most of the API.
Parameter | Type | Required | Default | Description |
---|---|---|---|---|
model | string | Yes | N/A | ID of the model to use for the completion |
messages | array | Yes | [] | A list of messages comprising the conversation so far |
temperature | number | No | 0.7 | Controls randomness: 0 means deterministic, 1 means very random |
max_tokens | integer | No | 1024 | The maximum number of tokens to generate in the chat completion |
top_p | number | No | 1.0 | Controls diversity via nucleus sampling |
stream | boolean | No | false | If set, partial message deltas will be sent |
Key Parameters Explained
model
The model
parameter specifies which AI model to use for generating the response. This is a required parameter for all requests.
Use the model ID format provider/model-name
, e.g., openai/gpt-4
or anthropic/claude-3-opus
. For Hanooman models, use hanooman/hanooman-everest
.
messages
The messages
parameter contains the conversation history as an array of message objects. Each message has a role
and content
.
Supported roles are system
, user
, and assistant
. The model will generate a response as if it were the next message in the conversation.
temperature
The temperature
parameter controls the randomness of the model's output. Lower values make the output more deterministic and focused, while higher values make it more random and creative.
stream
The stream
parameter determines whether the response should be streamed back to you in real-time or returned as a complete response.
When set to true
, the response will be streamed as it's generated, allowing for a more interactive experience. When set to false
(default), the response will be returned only once it's complete.
Example Request
Here's an example request that demonstrates the use of several parameters: