Hyperparameters and tuning
Automatic and manual parameters, the help tooltips, allowed ranges and the tuning methods.
A hyperparameter is a setting of an algorithm that you choose before training, for example the number of trees in a forest. Parameters such as the weights of a linear model are different: the algorithm learns them from the data.
Automatic or manual
Every algorithm you select in the Models part has a card with two modes.
- Automatic: the algorithm trains with its defaults. The card says "Uses the algorithm's default values."
- Manual: the card shows the algorithm's parameters so you can set them. Frequently used parameters are shown first; the rest are under Advanced parameters. Reset to defaults puts everything back.
Manual values are checked when you save the pipeline. An unknown parameter name, a value outside the allowed options, or a value of the wrong type is rejected with an explanation. A numeric range shown in the tooltip is a hint for searching, not a hard limit.
The same algorithm can be selected only once per pipeline. To compare two settings, duplicate the pipeline and change the parameters in the copy.
Reading a parameter tooltip
Select the information icon next to a parameter to open its tooltip. It is written for people who do not know the theory, and can have these parts:
| Part | What it tells you |
|---|---|
| What it is | The meaning of the parameter. |
| Range | The allowed values, for example "Allowed: integer ≥ 1", and "Suggested search range" when the tuner searches it. |
| Default | The value used in Automatic mode. |
| Effect | What happens when you increase or decrease the value, in terms of accuracy on new data, speed and memory. |
| Options | For a pick-one parameter, what each option does. |
| On / Off | For a switch, what each state does. |
| Note | "Only used when ..." for a parameter that applies only with another setting, such as a particular solver. |
For example, more trees usually make a forest's predictions more stable but slower to train, and a higher learning rate makes boosting converge faster but can overshoot and overfit. A parameter without an effect note shows only its meaning and range. Where the allowed range cannot be fully described, the tooltip says "or other forms" instead of claiming the list is complete.
Tuning methods
Under each algorithm card, the Tuning row searches the algorithm's own parameter ranges after training and keeps the best combination. Parameters you set manually stay fixed and are not searched.
| Method | How it works | Settings |
|---|---|---|
| None | No search. | |
| Random search | Tries a set number of random combinations. | Iterations: 1 to 200, default 10. |
| Grid search | Tries every combination of the algorithm's grid. | Refused when there are more than 500 combinations. |
| Bayesian | Uses earlier scores to choose the next combination (the TPE method). | Trials: 1 to 200, default 20. Timeout (s): 10 to 3600, default 600. |
All methods also have CV folds: 2 to 10, default 5. Each tried combination is one cross-validated fit, so more iterations or trials take proportionally longer.
For Bayesian search the timeout is a wall-clock limit. When it runs out, no new trial starts, the one in progress finishes and the best result so far is kept. The trial page shows how many trials ran.
Limits
- Tuning is available for classification and regression only.
- Bayesian search needs an optional component on the server. When it is missing, the option is disabled and a message says so.
- If an algorithm has no search space, or every searchable parameter is set manually, tuning is disabled with a short reason ("This algorithm has no search space to tune." or "Every searchable parameter is set manually.").
- If a grid search would exceed 500 combinations, saving the pipeline fails. Use random search or fix more parameters manually.
- The metric that tuning optimizes follows the run's configured ranking metric, or the algorithm default if none is set.
You can also tune a model after training. Open the model's page in a run and use the Tune action, choose the Search iterations and an Optimize metric, and select Start tuning. The tuned model appears as a new row in the run's trials. See Improve a model.
When tuning does not help
Tuning squeezes a little more out of a model; it rarely rescues a weak one. Before tuning, check these first:
- The data. Missing values, leakage and wrong column types cost more than any parameter.
- The algorithm. Try several in Automatic mode and tune only the best two.
- The score gap. If cross-validation scores are within the noise of each other (look at the spread between folds), tuning is choosing between equals and may overfit the validation folds.
- Overfitting. A tuned model that scores much higher in cross-validation than on the holdout probably fits the folds, not the world.
Next steps
Learn the theory
Lessons on learning.mlflow.es that explain the ideas behind this page.
Updated 2026-11-22