Skip to content
SupportLogin

Recommend hyperparameters

POST/api/v1/autoscientist/recommend-hyperparams

Returns the hyperparameters AutoScientist derives for a model and the dataset’s effective training size (rows plus planned augmentation). Nothing is launched. Omit model to size against the model POST /autoscientist would select for this dataset; the resolved id is returned with the values. POST /autoscientist applies the same values when hyperparams is omitted.

Body ParametersJSONExpand Collapse
dataset_id: string

The dataset the hyperparameters are sized for. Must be a dataset you own that has finished processing.

model: optional string

Base model id from GET /autoscientist/models to tune for. Omit to size the recommendation against the model POST /autoscientist selects for this dataset; the resolved id is returned in the response model field. That pick reads the columns already selected for the dataset, so a create request supplying column_mapping.reasoning_trace can resolve a different model. Pass the returned model back on create to pin it.

augmentation_domain_rows: optional number

Number of synthetic domain-targeted rows you plan to generate. These are additional to your own rows and count toward the effective training size, so the recommendation matches what you will launch. Defaults to 0 (no augmentation).

minimum0
maximum40000
augmentation_general_rows: optional number

Number of synthetic general-diversity rows you plan to generate. These are additional to your own rows and count toward the effective training size. Defaults to 0 (no augmentation).

minimum0
maximum50000
ReturnsExpand Collapse
model: string

Resolved base model id the recommendation is sized for: the value you sent, or the automatically selected model when model was omitted. Pass it back as model on POST /autoscientist to launch against the same model.

hyperparams: object { training_type, n_epochs, learning_rate, 16 more }

Hyperparameters derived for the resolved model and effective dataset size. POST /autoscientist applies the same values when hyperparams is omitted. Overriding is not advised.

training_type: optional "lora" or "full"

Training strategy override. AutoScientist optimizes this by default; set it only when strictly necessary.

One of the following:
"lora"
"full"
n_epochs: optional number
minimum1
maximum20
learning_rate: optional number
minimum1e-8
maximum0.01
batch_size: optional "max" or number

Either the literal ‘max’ or an integer of 1 or more. No fixed upper bound: the ceiling depends on the model and hardware, and a larger value is rejected at launch. Defaults to ‘max’.

One of the following:
"max"
number
lora_r: optional number
minimum1
maximum64
lora_alpha: optional number

Must be 1× or 2× lora_r. Only checked when you supply lora_r in the same request; otherwise it is validated against the platform default.

lora_dropout: optional number

Dropout applied to the LoRA layers. Defaults to 0.

minimum0
maximum1
lora_trainable_modules: optional string

‘all-linear’ or comma-separated module list (e.g. ‘q_proj,v_proj’).

lr_scheduler_type: optional "linear" or "cosine" or "constant"
One of the following:
"linear"
"cosine"
"constant"
min_lr_ratio: optional number
minimum0
maximum1
scheduler_num_cycles: optional number

Number of cosine decay cycles across training. Defaults to 0.5, a single half-cycle decay from the peak learning rate down to the floor.

minimum0
maximum4
warmup_ratio: optional number
minimum0
maximum1
max_grad_norm: optional number
minimum0
weight_decay: optional number

L2 penalty applied to the weights. Defaults to 0.

minimum0
train_on_inputs: optional boolean

Whether training loss is computed over the prompt tokens as well as the completion. true trains on the full sequence, false trains only on the completion. Omit to let the platform decide per example, which is the default.

dpo_beta: optional number

Controls how much the model can deviate from the reference model. Lower = more aggressive updates toward preferred responses; higher = stays closer to reference behavior.

minimum0.05
maximum0.9
dpo_normalize_logratios_by_length: optional boolean

Normalizes log ratios by sample length during DPO loss calculation. Automatically set to true when simpo_gamma > 0.

rpo_alpha: optional number

RPO loss modifier: incorporates the NLL loss on selected samples with this weight. Defaults to 0.0 (standard DPO loss). Mutually exclusive with simpo_gamma — both above 0 is rejected.

formatfloat
minimum0
simpo_gamma: optional number

SimPO loss modifier: adds a margin to the loss, force-enables length normalization, and excludes reference logits. Defaults to 0.0 (off). Raise dpo_beta alongside it. Mutually exclusive with rpo_alpha — both above 0 is rejected.

formatfloat
minimum0

Recommend hyperparameters

curl https://api.prod.adaptionlabs.ai/api/v1/autoscientist/recommend-hyperparams \
    -H 'Content-Type: application/json' \
    -H "Authorization: Bearer $ADAPTION_API_KEY" \
    -d '{
          "dataset_id": "dataset_id"
        }'
{
  "model": "model",
  "hyperparams": {
    "training_type": "lora",
    "n_epochs": 1,
    "learning_rate": 0.00005,
    "batch_size": "max",
    "lora_r": 8,
    "lora_alpha": 0,
    "lora_dropout": 0,
    "lora_trainable_modules": "q_proj,v_proj",
    "lr_scheduler_type": "linear",
    "min_lr_ratio": 0.1,
    "scheduler_num_cycles": 0.5,
    "warmup_ratio": 0.03,
    "max_grad_norm": 2,
    "weight_decay": 0,
    "train_on_inputs": false,
    "dpo_beta": 0.1,
    "dpo_normalize_logratios_by_length": true,
    "rpo_alpha": 0,
    "simpo_gamma": 0
  }
}
Returns Examples
{
  "model": "model",
  "hyperparams": {
    "training_type": "lora",
    "n_epochs": 1,
    "learning_rate": 0.00005,
    "batch_size": "max",
    "lora_r": 8,
    "lora_alpha": 0,
    "lora_dropout": 0,
    "lora_trainable_modules": "q_proj,v_proj",
    "lr_scheduler_type": "linear",
    "min_lr_ratio": 0.1,
    "scheduler_num_cycles": 0.5,
    "warmup_ratio": 0.03,
    "max_grad_norm": 2,
    "weight_decay": 0,
    "train_on_inputs": false,
    "dpo_beta": 0.1,
    "dpo_normalize_logratios_by_length": true,
    "rpo_alpha": 0,
    "simpo_gamma": 0
  }
}