5 minute setup
Quickstart
Get started with mlcli in under 5 minutes. This guide will walk you through installation and your first training run.
Installation
Install mlcli using pip:
Terminal
pip install mlcli-toolkitOr using pipx for an isolated installation:
Terminal
pipx install mlcli-toolkitVerify the installation:
Terminal
mlcli --version
# mlcli v0.3.1Your First Training Run
Train a Random Forest model on your dataset with a single command:
Terminal
mlcli train \
--data data/train.csv \
--model random_forest \
--target label \
--output models/This command will:
Load and preprocess your data
Train a Random Forest classifier
Evaluate on a validation split
Save the trained model
Log the experiment
Using Config Files
For more control over your training, use a JSON configuration file:
config.json
{
"model_type": "random_forest",
"dataset_path": "data/train.csv",
"target_column": "label",
"test_size": 0.2,
"hyperparameters": {
"n_estimators": 100,
"max_depth": 10,
"min_samples_split": 2
},
"output_dir": "models/"
}Then run training with the config:
Terminal
mlcli train --config config.jsonEvaluate Your Model
Evaluate your trained model on a test set:
Terminal
mlcli eval \
--model models/random_forest_model.pkl \
--data data/test.csvView Experiments
List all your experiment runs:
Terminal
mlcli list-runsView details of a specific run:
Terminal
mlcli show-run --run-id run_abc123