Skip to main content
GET
/
fine-tunes
/
models
/
limits
cURL
curl "https://api.together.ai/v1/fine-tunes/models/limits?model_name=meta-llama/Meta-Llama-3.1-8B-Instruct-Reference" \
     -H "Authorization: Bearer $TOGETHER_API_KEY"
import requests

url = "https://api.together.ai/v1/fine-tunes/models/limits"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('https://api.together.ai/v1/fine-tunes/models/limits', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.together.ai/v1/fine-tunes/models/limits",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"net/http"
"io"
)

func main() {

url := "https://api.together.ai/v1/fine-tunes/models/limits"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "Bearer <token>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://api.together.ai/v1/fine-tunes/models/limits")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.together.ai/v1/fine-tunes/models/limits")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
{
  "model_name": "<string>",
  "lora_training": {
    "max_batch_size": 123,
    "max_batch_size_dpo": 123,
    "min_batch_size": 123,
    "max_rank": 123,
    "target_modules": [
      "<string>"
    ]
  },
  "max_num_epochs": 123,
  "max_num_evals": 123,
  "max_learning_rate": 123,
  "min_learning_rate": 123,
  "supports_full_training": true,
  "supports_vision": true,
  "supports_tools": true,
  "supports_reasoning": true,
  "merge_output_lora": true,
  "default_gradient_accumulation_steps": 123,
  "max_num_checkpoints": 123,
  "min_max_seq_length": 123,
  "max_seq_length_sft": 123,
  "max_seq_length_dpo": 123,
  "full_training": {
    "max_batch_size": 123,
    "max_batch_size_dpo": 123,
    "min_batch_size": 123
  }
}
{
"message": "<string>"
}

Authorizations

Authorization
string
header
default:default
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Query Parameters

model_name
string
required

The model name to get limits for.

Response

Model limits.

Model limits for fine-tuning.

model_name
string
required

The name of the model.

lora_training
object
required

Limits for LoRA training.

max_num_epochs
integer
required

Maximum number of training epochs.

max_num_evals
integer
required

Maximum number of evaluations.

max_learning_rate
number
required

Maximum learning rate.

min_learning_rate
number
required

Minimum learning rate.

supports_full_training
boolean
required

Whether the model supports full (non-LoRA) fine-tuning. When false, only LoRA fine-tuning is available and the full_training limits are reported as zero.

supports_vision
boolean
required

Whether the model supports vision/multimodal inputs.

supports_tools
boolean
required

Whether the model supports tool/function calling.

supports_reasoning
boolean
required

Whether the model supports reasoning.

merge_output_lora
boolean
required

Whether a merged checkpoint (the base model with the trained LoRA adapter fused in) is produced for LoRA fine-tunes of this model, in addition to the standalone adapter.

default_gradient_accumulation_steps
integer
required

Default gradient accumulation steps used when a fine-tune request omits the value or sets it to 0.

max_num_checkpoints
integer
required

Maximum number of checkpoints that can be saved during a fine-tuning job.

min_max_seq_length
integer
required

Minimum value allowed for the max_seq_length hyperparameter.

max_seq_length_sft
integer
required

Maximum sequence length supported for SFT training.

max_seq_length_dpo
integer
required

Maximum sequence length supported for DPO training.

full_training
object

Limits for full training.