compare_models
Fit and compare candidate algorithms on a dataset with cross-validation, returning fold metrics and selecting a winner by your chosen metric.
Instructions
Fit and compare candidate algorithms on a dataset using cross-validation (CV). Returns fold metrics and selects a winner by the requested metric. Provide a split_manifest_id to reserve its test rows. Records experiments when possible. Use compare_experiments for saved metrics or automl_run for hyperparameter search.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"name": "<name>",
"target_column": "<target_column>",
"task_type": "<task_type>"
},
"name": "compare_models"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cv | No | Cross-validation folds (default 5). | |
| name | Yes | Dataset filename. | |
| metric | No | Selection metric (default auto). | |
| models | No | Models to compare. | |
| delimiter | No | CSV delimiter (comma, semicolon, tab, pipe). Auto. | |
| task_type | Yes | 'classification' or 'regression'. | |
| test_size | No | Test fraction (default 0.2). | |
| random_state | No | Random seed (default 42). | |
| target_column | Yes | Target variable column. | |
| exclude_columns | No | Feature columns to exclude before preprocessing/training. | |
| split_manifest_id | No | ID of a validated split manifest to enforce indices. |